| On this page | |
| Inheritance | 
 | 
Overview ¶
A hou.ViewerStateContext holds the contextual information related to the running viewer state such as 
the gadget drawable bindings. 
¶
Methods from hou.GadgetContext ¶
name()
  → string
        
Returns the name of the active drawable. A drawable is active when it is picked or when the mouse moves over its visuals (located).
label()
  → string
        
The active drawable label name.
gadget()
  → string
        
Similar to name().
gadgetLabel()
  → string
        
Similar to label().
component1()
  → int
        
A component id of the active gadget geometry. The id refers to either a polygon, a polygon vertex or the start point of a line geometry. Returns -1 if no gadget is active.
Note
This method does not apply to hou.Drawable2D objects.
component2()
  → int
        
A component id of the active gadget geometry. The returned id typically identifies the end point of a line geometry. Returns -1 if no line geometry is picked or located, or no gadget is active.
Note
This method does not apply to hou.Drawable2D objects.
isDrawing()
  → bool
        
Returns True if the handle is in a drawing state which means no drawable is being picked or located.
isPicking()
  → bool
        
Returns True if any drawable is being picked.
isLocating()
  → bool
        
Returns True if any drawable is being located.
isLocated(drawable_name)
  → bool
        
Returns True if a given drawable is located.
drawable_name
        
Name of the drawable to test.
isPicked(drawable_name)
  → bool
        
Returns True if a given drawable is picked.
drawable_name
        
Name of the drawable to test.
| See also |