• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC SKILL
  3. Help on skill code for unselecting/selcting objects like...

Stats

  • Locked Locked
  • Replies 23
  • Subscribers 143
  • Views 13866
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Help on skill code for unselecting/selcting objects like path/wire, rectangle/polygon etc.

zeroskills
zeroskills over 15 years ago

Hi All,

First of all, i have no talent doing skill code, i have very very basic knowledge of it. here's my request, and i think it's possible because if did some reseach on it, i just don't know how to do it.

Problem:

For example, i have a wire/path and a rectangle/polygon overlapping each other, i would like to select "only" the wire/path and not the rectangle/polygon. it would be nice if there's a skill code that can turn off or on wire/path or rectangle/polygon selection like the instance button on the LSW window.

So basically i would like to have something like the intance turning on or off selection, like this...

--->leSetObjectSelectable("inst" t) instance is selectable or

--->leSetObjectSelectable("inst" nil) instance is unselectable

But i would like something like this for other objects, like wire/path, rectabgle/polygon etc. not necessarily a button but i would like it to toggle, like "shift+w" to turn it on or off using if statements.

Thanks in advance, I hope someone could help me. 

 

 

  • Cancel
Parents
  • Andrew Beckett
    Andrew Beckett over 15 years ago

    Derek,

    Er, whoops. Thanks for spotting that. I'd neglected those functions - which are wrappers around leRegUserObjectSelectionFilter. My internal XML file which I use to generate my SKILL Library web page didn't mention the reference to that file (my bad) and so I missed it out.

    Here's the missing code:

    /* abLeMultiSelectionFilter.ils
    
    Author     A.D.Beckett
    Group      Custom IC (UK), Cadence Design Systems Ltd.
    Language   SKILL
    Date       Dec 02, 2008 
    Modified   
    By         
    
    A mechanism to allow multiple filters to be registered
    for leRegUserLayerSelectionFilter and leRegUserObjectSelectionFilter
    
    Defines:
    
    abLeRegUserLayerSelectionFilter(t_funcName)
    abLeUnregUserLayerSelectionFilter(t_funcName)
    abLeRegUserObjectSelectionFilter(t_funcName)
    abLeUnregUserObjectSelectionFilter(t_funcName)
    
    These are similar to the original functions with prefix le instead of
    abLe, but note that the original unreg functions don't need a function
    name (this does, because it needs to know which function is
    being unregistered)
    
    ***************************************************
    
    SCCS Info: @(#) abLeMultiSelectionFilter.ils 12/02/08.11:51:17 1.1
    
    */
    
    (let ()
      /******************************************************************
      *                                                                 *
      *    (defineFilterWrapper regFunc unregFunc filterName "uut")     *
      *                                                                 *
      *   Closure which returns a list of three functions - one to be   *
      *   the registration function, one the unregistration function,   *
      *  and one the filter itself. Needs to know the function objects  *
      *   to perform the single registration, unregistration, and the   *
      *              ultimate (global) name of the filter.              *
      *                                                                 *
      *  The idea is that this keeps track of multiple registrations,   *
      *  and then calls all the registered filter functions sequence,   *
      * so turns with a single registered filter function, can actually *
      *                 call several functions instead.                 *
      *                                                                 *
      ******************************************************************/
      (defun defineFilterWrapper (regFunc unregFunc filterName "uut")
        (let (filterList registered)
          ;------------------------------------------------------------------
          ; local function to register the selection filter
          ;------------------------------------------------------------------
          (defun register (func)
    	(when (stringp func) (setq func (stringToSymbol func)))
    	(unless (member func (car filterList))
    	  (setq filterList (tconc filterList func)))
    	(unless registered
    	  (setq registered t)
    	  (regFunc filterName)
    	  )
    	t
    	)
          ;------------------------------------------------------------------
          ; local function to unregister the selection filter
          ;------------------------------------------------------------------
          (defun unregister (func)
    	(when (stringp func) (setq func (stringToSymbol func)))
    	(setq filterList 
    	      (lconc nil (remove func (car filterList))))
    	(unless (car filterList)
    	  (setq registered nil)
    	  (unregFunc)
    	  )
    	t
    	)
          ;------------------------------------------------------------------
          ; local function to actually be the selection filter
          ;------------------------------------------------------------------
          (defun filter (obj)
    	(forall func (car filterList)
    		(funcall func obj))
    	)
          (list register unregister filter)
          )
        )
    
      ;----------------------------------------------------------------------
      ; Use the closure to define the multi-version of 
      ; leRegUserLayerSelectionFilter and leUnregUserSelectionFilter
      ;----------------------------------------------------------------------
      (let (funcs)
        (setq funcs (defineFilterWrapper leRegUserLayerSelectionFilter
    				     leUnregUserLayerSelectionFilter
    				     "abMultiLayerSelectionFilter"))
        (setq abLeRegUserLayerSelectionFilter (car funcs))
        (setq abLeUnregUserLayerSelectionFilter (cadr funcs))
        (setq abMultiLayerSelectionFilter (caddr funcs))
        )
    
      ;----------------------------------------------------------------------
      ; Use the closure to define the multi-version of
      ; leRegUserObjectSelectionFilter and leUnregUserObjectSelectionFilter
      ;----------------------------------------------------------------------
      (let (funcs)
        (setq funcs (defineFilterWrapper leRegUserObjectSelectionFilter
    				     leUnregUserObjectSelectionFilter
    				     "abMultiObjectSelectionFilter"))
        (setq abLeRegUserObjectSelectionFilter (car funcs))
        (setq abLeUnregUserObjectSelectionFilter (cadr funcs))
        (setq abMultiObjectSelectionFilter (caddr funcs))
        )
      t
      )
    
    

    With this code, you can use the original unmodified.

    Regards,

    Andrew.

     

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 15 years ago

    Derek,

    Er, whoops. Thanks for spotting that. I'd neglected those functions - which are wrappers around leRegUserObjectSelectionFilter. My internal XML file which I use to generate my SKILL Library web page didn't mention the reference to that file (my bad) and so I missed it out.

    Here's the missing code:

    /* abLeMultiSelectionFilter.ils
    
    Author     A.D.Beckett
    Group      Custom IC (UK), Cadence Design Systems Ltd.
    Language   SKILL
    Date       Dec 02, 2008 
    Modified   
    By         
    
    A mechanism to allow multiple filters to be registered
    for leRegUserLayerSelectionFilter and leRegUserObjectSelectionFilter
    
    Defines:
    
    abLeRegUserLayerSelectionFilter(t_funcName)
    abLeUnregUserLayerSelectionFilter(t_funcName)
    abLeRegUserObjectSelectionFilter(t_funcName)
    abLeUnregUserObjectSelectionFilter(t_funcName)
    
    These are similar to the original functions with prefix le instead of
    abLe, but note that the original unreg functions don't need a function
    name (this does, because it needs to know which function is
    being unregistered)
    
    ***************************************************
    
    SCCS Info: @(#) abLeMultiSelectionFilter.ils 12/02/08.11:51:17 1.1
    
    */
    
    (let ()
      /******************************************************************
      *                                                                 *
      *    (defineFilterWrapper regFunc unregFunc filterName "uut")     *
      *                                                                 *
      *   Closure which returns a list of three functions - one to be   *
      *   the registration function, one the unregistration function,   *
      *  and one the filter itself. Needs to know the function objects  *
      *   to perform the single registration, unregistration, and the   *
      *              ultimate (global) name of the filter.              *
      *                                                                 *
      *  The idea is that this keeps track of multiple registrations,   *
      *  and then calls all the registered filter functions sequence,   *
      * so turns with a single registered filter function, can actually *
      *                 call several functions instead.                 *
      *                                                                 *
      ******************************************************************/
      (defun defineFilterWrapper (regFunc unregFunc filterName "uut")
        (let (filterList registered)
          ;------------------------------------------------------------------
          ; local function to register the selection filter
          ;------------------------------------------------------------------
          (defun register (func)
    	(when (stringp func) (setq func (stringToSymbol func)))
    	(unless (member func (car filterList))
    	  (setq filterList (tconc filterList func)))
    	(unless registered
    	  (setq registered t)
    	  (regFunc filterName)
    	  )
    	t
    	)
          ;------------------------------------------------------------------
          ; local function to unregister the selection filter
          ;------------------------------------------------------------------
          (defun unregister (func)
    	(when (stringp func) (setq func (stringToSymbol func)))
    	(setq filterList 
    	      (lconc nil (remove func (car filterList))))
    	(unless (car filterList)
    	  (setq registered nil)
    	  (unregFunc)
    	  )
    	t
    	)
          ;------------------------------------------------------------------
          ; local function to actually be the selection filter
          ;------------------------------------------------------------------
          (defun filter (obj)
    	(forall func (car filterList)
    		(funcall func obj))
    	)
          (list register unregister filter)
          )
        )
    
      ;----------------------------------------------------------------------
      ; Use the closure to define the multi-version of 
      ; leRegUserLayerSelectionFilter and leUnregUserSelectionFilter
      ;----------------------------------------------------------------------
      (let (funcs)
        (setq funcs (defineFilterWrapper leRegUserLayerSelectionFilter
    				     leUnregUserLayerSelectionFilter
    				     "abMultiLayerSelectionFilter"))
        (setq abLeRegUserLayerSelectionFilter (car funcs))
        (setq abLeUnregUserLayerSelectionFilter (cadr funcs))
        (setq abMultiLayerSelectionFilter (caddr funcs))
        )
    
      ;----------------------------------------------------------------------
      ; Use the closure to define the multi-version of
      ; leRegUserObjectSelectionFilter and leUnregUserObjectSelectionFilter
      ;----------------------------------------------------------------------
      (let (funcs)
        (setq funcs (defineFilterWrapper leRegUserObjectSelectionFilter
    				     leUnregUserObjectSelectionFilter
    				     "abMultiObjectSelectionFilter"))
        (setq abLeRegUserObjectSelectionFilter (car funcs))
        (setq abLeUnregUserObjectSelectionFilter (cadr funcs))
        (setq abMultiObjectSelectionFilter (caddr funcs))
        )
      t
      )
    
    

    With this code, you can use the original unmodified.

    Regards,

    Andrew.

     

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information