Section: Visualization Toolkit Widget Classes
Note that vtkAbstractWidget provides access to the vtkWidgetEventTranslator. This class is responsible for translating VTK events (defined in vtkCommand.h) into widget events (defined in vtkWidgetEvent.h). This class can be manipulated so that different VTK events can be mapped into widget events, thereby allowing the modification of event bindings. Each subclass of vtkAbstractWidget defines the events to which it responds.
To create an instance of class vtkAbstractWidget, simply invoke its constructor as follows
obj = vtkAbstractWidget
obj
is an instance of the vtkAbstractWidget class.
string = obj.GetClassName ()
- Standard macros implementing standard VTK methods.
int = obj.IsA (string name)
- Standard macros implementing standard VTK methods.
vtkAbstractWidget = obj.NewInstance ()
- Standard macros implementing standard VTK methods.
vtkAbstractWidget = obj.SafeDownCast (vtkObject o)
- Standard macros implementing standard VTK methods.
obj.SetEnabled (int )
- Methods for activating this widget. Note that the widget representation
must be specified or the widget will not appear.
ProcessEvents (On by default) must be On for Enabled widget to respond
to interaction. If ProcessEvents is Off, enabling/disabling a widget
merely affects the visibility of the representation.
obj.SetProcessEvents (int )
- Methods to change the whether the widget responds to interaction.
Set this to Off to disable interaction. On by default.
Subclasses must overide SetProcessEvents() to make sure
that they pass on the flag to all component widgets.
int = obj.GetProcessEventsMinValue ()
- Methods to change the whether the widget responds to interaction.
Set this to Off to disable interaction. On by default.
Subclasses must overide SetProcessEvents() to make sure
that they pass on the flag to all component widgets.
int = obj.GetProcessEventsMaxValue ()
- Methods to change the whether the widget responds to interaction.
Set this to Off to disable interaction. On by default.
Subclasses must overide SetProcessEvents() to make sure
that they pass on the flag to all component widgets.
int = obj.GetProcessEvents ()
- Methods to change the whether the widget responds to interaction.
Set this to Off to disable interaction. On by default.
Subclasses must overide SetProcessEvents() to make sure
that they pass on the flag to all component widgets.
obj.ProcessEventsOn ()
- Methods to change the whether the widget responds to interaction.
Set this to Off to disable interaction. On by default.
Subclasses must overide SetProcessEvents() to make sure
that they pass on the flag to all component widgets.
obj.ProcessEventsOff ()
- Methods to change the whether the widget responds to interaction.
Set this to Off to disable interaction. On by default.
Subclasses must overide SetProcessEvents() to make sure
that they pass on the flag to all component widgets.
vtkWidgetEventTranslator = obj.GetEventTranslator ()
- Create the default widget representation if one is not set. The
representation defines the geometry of the widget (i.e., how it appears)
as well as providing special methods for manipulting the state and
appearance of the widget.
obj.CreateDefaultRepresentation ()
- Create the default widget representation if one is not set. The
representation defines the geometry of the widget (i.e., how it appears)
as well as providing special methods for manipulting the state and
appearance of the widget.
obj.Render ()
- This method is called by subclasses when a render method is to be
invoked on the vtkRenderWindowInteractor. This method should be called
(instead of vtkRenderWindow::Render() because it has built into it
optimizations for minimizing renders and/or speeding renders.
obj.SetParent (vtkAbstractWidget parent)
- Specifying a parent to this widget is used when creating composite
widgets. It is an internal method not meant to be used by the public.
When a widget has a parent, it defers the rendering to the parent. It
may also defer managing the cursor (see ManagesCursor ivar).
vtkAbstractWidget = obj.GetParent ()
- Specifying a parent to this widget is used when creating composite
widgets. It is an internal method not meant to be used by the public.
When a widget has a parent, it defers the rendering to the parent. It
may also defer managing the cursor (see ManagesCursor ivar).
vtkWidgetRepresentation = obj.GetRepresentation ()
- Turn on or off the management of the cursor. Cursor management is
typically disabled for subclasses when composite widgets are
created. For example, vtkHandleWidgets are often used to create
composite widgets, and the parent widget takes over the cursor
management.
obj.SetManagesCursor (int )
- Turn on or off the management of the cursor. Cursor management is
typically disabled for subclasses when composite widgets are
created. For example, vtkHandleWidgets are often used to create
composite widgets, and the parent widget takes over the cursor
management.
int = obj.GetManagesCursor ()
- Turn on or off the management of the cursor. Cursor management is
typically disabled for subclasses when composite widgets are
created. For example, vtkHandleWidgets are often used to create
composite widgets, and the parent widget takes over the cursor
management.
obj.ManagesCursorOn ()
- Turn on or off the management of the cursor. Cursor management is
typically disabled for subclasses when composite widgets are
created. For example, vtkHandleWidgets are often used to create
composite widgets, and the parent widget takes over the cursor
management.
obj.ManagesCursorOff ()
- Turn on or off the management of the cursor. Cursor management is
typically disabled for subclasses when composite widgets are
created. For example, vtkHandleWidgets are often used to create
composite widgets, and the parent widget takes over the cursor
management.
obj.SetPriority (float )
- Override the superclass method. This will automatically change the
priority of the widget. Unlike the superclass documentation, no
methods such as SetInteractor to null and reset it etc. are necessary