schRegisterPopUpMenu
schRegisterPopUpMenu(t_category r_menuHandlet_mode) => t / nil
Description
Replaces the object-sensitive menus (OSMs) of the schematic canvas with a specific object category and edit mode. This function should only be called after a schematic cellview has been opened and the schematic editor has been initialized. To ensure this, call schRegisterPopUpMenu() from a callback registered using deRegUserTriggers().
schRegisterPopUpMenu(
t_category
r_menuHandle
t_mode
)
=> t / nil
Arguments
Value Returned
|
Registered r_menuHandle for a specific object type to customize the OSMs. |
|
Examples
Registers newInstanceMenu as the OSM to display when the cursor is over an instance when the current cellview is opened in read mode.
schRegisterPopUpMenu( "instance" newInstanceMenu "view" )
Registers newInstanceMenu as the OSM to display when the cursor is over an instance when the current cellview is opened in edit mode.
schRegisterPopUpMenu( "instance" newInstanceMenu "edit" )
The following table shows object type selections.
| ObjType (Category) | Selection |
|---|---|
procedure( CDNCreateAndRegisterObjectMenus()
let((item1 item2 menu)
item1 = hiCreateMenuItem(
?name 'itemOne
?itemText "One"
?callback "println(1111)"
)
item2 = hiCreateMenuItem(
?name 'itemTwo
?itemText "Two"
?callback "println(2222)"
)
menu = hiCreateMenu(
'MyInstanceMenu
"My Instance Menu"
list(item1 item2))
schRegisterPopUpMenu("instance" menu "edit")
)
)
deRegUserTriggers("schematic" nil nil 'CDNCreateAndRegisterObjectMenus)
Related Topics
Cadence SKILL Language Reference
Return to top