1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67
|
Usage
This class provides support for interactively placing a
caption on the 2D overlay plane. A caption is defined by
some text with a leader (e.g., arrow) that points from the
text to a point in the scene. The caption is represented by
a vtkCaptionRepresentation. It uses the event bindings of
its superclass (vtkBorderWidget) to control the placement of
the text, and adds the ability to move the attachment point
around. In addition, when the caption text is selected, the
widget emits a ActivateEvent that observers can watch for.
This is useful for opening GUI dialogoues to adjust font
characteristics, etc. (Please see the superclass for a
description of event bindings.)
Note that this widget extends the behavior of its superclass
vtkBorderWidget. The end point of the leader can be selected
and moved around with an internal vtkHandleWidget.
To create an instance of class vtkCaptionWidget, simply
invoke its constructor as follows
obj = vtkCaptionWidget
Methods
The class vtkCaptionWidget has several methods that can be
used. They are listed below. Note that the documentation is
translated automatically from the VTK sources, and may not
be completely intelligible. When in doubt, consult the VTK
website. In the methods listed below, obj is an instance of
the vtkCaptionWidget class.
* string = obj.GetClassName () - Standard VTK class methods.
* int = obj.IsA (string name) - Standard VTK class methods.
* vtkCaptionWidget = obj.NewInstance () - Standard VTK class
methods.
* vtkCaptionWidget = obj.SafeDownCast (vtkObject o) -
Standard VTK class methods.
* obj.SetEnabled (int enabling) - Override superclasses'
SetEnabled() method because the caption leader has its own
dedicated widget.
* obj.SetRepresentation (vtkCaptionRepresentation r) -
Specify a vtkCaptionActor2D to manage. This is convenient,
alternative method to SetRepresentation(). It internally
create a vtkCaptionRepresentation and then invokes
vtkCaptionRepresentation::SetCaptionActor2D().
* obj.SetCaptionActor2D (vtkCaptionActor2D capActor) -
Specify a vtkCaptionActor2D to manage. This is convenient,
alternative method to SetRepresentation(). It internally
create a vtkCaptionRepresentation and then invokes
vtkCaptionRepresentation::SetCaptionActor2D().
* vtkCaptionActor2D = obj.GetCaptionActor2D () - Specify a
vtkCaptionActor2D to manage. This is convenient,
alternative method to SetRepresentation(). It internally
create a vtkCaptionRepresentation and then invokes
vtkCaptionRepresentation::SetCaptionActor2D().
* obj.CreateDefaultRepresentation () - Create the default
widget representation if one is not set.
* FreeMat_Documentation
* Visualization_Toolkit_Widget_Classes
* Generated on Thu Jul 25 2013 17:18:36 for FreeMat by
doxygen_ 1.8.1.1
|