FreeMat: vtkLeaderActor2D

FreeMat

- Main Page
- Related Pages

vtkLeaderActor2D

Section: Visualization Toolkit Rendering Classes

# Usage

vtkLeaderActor2D creates a leader with an optional label and arrows. (A leader is typically used to indicate distance between points.) vtkLeaderActor2D is a type of vtkActor2D; that is, it is drawn on the overlay plane and is not occluded by 3D geometry. To use this class, you typically specify two points defining the start and end points of the line (x-y definition using vtkCoordinate class), whether to place arrows on one or both end points, and whether to label the leader. Also, this class has a special feature that allows curved leaders to be created by specifying a radius.

Use the vtkLeaderActor2D uses its superclass vtkActor2D instance variables Position and Position2 vtkCoordinates to place an instance of vtkLeaderActor2D (i.e., these two data members represent the start and end points of the leader). Using these vtkCoordinates you can specify the position of the leader in a variety of coordinate systems.

To control the appearance of the actor, use the superclasses vtkActor2D::vtkProperty2D and the vtkTextProperty objects associated with this actor.

To create an instance of class vtkLeaderActor2D, simply invoke its constructor as follows

      obj = vtkLeaderActor2D

# Methods

The class vtkLeaderActor2D 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 vtkLeaderActor2D class.

- `string = obj.GetClassName ()`
- `int = obj.IsA (string name)`
- `vtkLeaderActor2D = obj.NewInstance ()`
- `vtkLeaderActor2D = obj.SafeDownCast (vtkObject o)`
- `obj.SetRadius (double )` - Set/Get a radius which can be used to curve the leader. If a radius is specified whose absolute value is greater than one half the distance between the two points defined by the superclasses' Position and Position2 ivars, then the leader will be curved. A positive radius will produce a curve such that the center is to the right of the line from Position and Position2; a negative radius will produce a curve in the opposite sense. By default, the radius is set to zero and thus there is no curvature. Note that the radius is expresses as a multiple of the distance between (Position,Position2); this avoids issues relative to coordinate system transformations.
- `double = obj.GetRadius ()` - Set/Get a radius which can be used to curve the leader. If a radius is specified whose absolute value is greater than one half the distance between the two points defined by the superclasses' Position and Position2 ivars, then the leader will be curved. A positive radius will produce a curve such that the center is to the right of the line from Position and Position2; a negative radius will produce a curve in the opposite sense. By default, the radius is set to zero and thus there is no curvature. Note that the radius is expresses as a multiple of the distance between (Position,Position2); this avoids issues relative to coordinate system transformations.
- `obj.SetLabel (string )` - Set/Get the label for the leader. If the label is an empty string, then it will not be drawn.
- `string = obj.GetLabel ()` - Set/Get the label for the leader. If the label is an empty string, then it will not be drawn.
- `obj.SetLabelTextProperty (vtkTextProperty p)` - Set/Get the text property of the label.
- `vtkTextProperty = obj.GetLabelTextProperty ()` - Set/Get the text property of the label.
- `obj.SetLabelFactor (double )` - Set/Get the factor that controls the overall size of the fonts used to label the leader.
- `double = obj.GetLabelFactorMinValue ()` - Set/Get the factor that controls the overall size of the fonts used to label the leader.
- `double = obj.GetLabelFactorMaxValue ()` - Set/Get the factor that controls the overall size of the fonts used to label the leader.
- `double = obj.GetLabelFactor ()` - Set/Get the factor that controls the overall size of the fonts used to label the leader.
- `obj.SetArrowPlacement (int )` - Control whether arrow heads are drawn on the leader. Arrows may be drawn on one end, both ends, or not at all.
- `int = obj.GetArrowPlacementMinValue ()` - Control whether arrow heads are drawn on the leader. Arrows may be drawn on one end, both ends, or not at all.
- `int = obj.GetArrowPlacementMaxValue ()` - Control whether arrow heads are drawn on the leader. Arrows may be drawn on one end, both ends, or not at all.
- `int = obj.GetArrowPlacement ()` - Control whether arrow heads are drawn on the leader. Arrows may be drawn on one end, both ends, or not at all.
- `obj.SetArrowPlacementToNone ()` - Control whether arrow heads are drawn on the leader. Arrows may be drawn on one end, both ends, or not at all.
- `obj.SetArrowPlacementToPoint1 ()` - Control whether arrow heads are drawn on the leader. Arrows may be drawn on one end, both ends, or not at all.
- `obj.SetArrowPlacementToPoint2 ()` - Control whether arrow heads are drawn on the leader. Arrows may be drawn on one end, both ends, or not at all.
- `obj.SetArrowPlacementToBoth ()` - Control the appearance of the arrow heads. A solid arrow head is a filled triangle; a open arrow looks like a "V"; and a hollow arrow looks like a non-filled triangle.
- `obj.SetArrowStyle (int )` - Control the appearance of the arrow heads. A solid arrow head is a filled triangle; a open arrow looks like a "V"; and a hollow arrow looks like a non-filled triangle.
- `int = obj.GetArrowStyleMinValue ()` - Control the appearance of the arrow heads. A solid arrow head is a filled triangle; a open arrow looks like a "V"; and a hollow arrow looks like a non-filled triangle.
- `int = obj.GetArrowStyleMaxValue ()` - Control the appearance of the arrow heads. A solid arrow head is a filled triangle; a open arrow looks like a "V"; and a hollow arrow looks like a non-filled triangle.
- `int = obj.GetArrowStyle ()` - Control the appearance of the arrow heads. A solid arrow head is a filled triangle; a open arrow looks like a "V"; and a hollow arrow looks like a non-filled triangle.
- `obj.SetArrowStyleToFilled ()` - Control the appearance of the arrow heads. A solid arrow head is a filled triangle; a open arrow looks like a "V"; and a hollow arrow looks like a non-filled triangle.
- `obj.SetArrowStyleToOpen ()` - Control the appearance of the arrow heads. A solid arrow head is a filled triangle; a open arrow looks like a "V"; and a hollow arrow looks like a non-filled triangle.
- `obj.SetArrowStyleToHollow ()` - Specify the arrow length and base width (in normalized viewport coordinates).
- `obj.SetArrowLength (double )` - Specify the arrow length and base width (in normalized viewport coordinates).
- `double = obj.GetArrowLengthMinValue ()` - Specify the arrow length and base width (in normalized viewport coordinates).
- `double = obj.GetArrowLengthMaxValue ()` - Specify the arrow length and base width (in normalized viewport coordinates).
- `double = obj.GetArrowLength ()` - Specify the arrow length and base width (in normalized viewport coordinates).
- `obj.SetArrowWidth (double )` - Specify the arrow length and base width (in normalized viewport coordinates).
- `double = obj.GetArrowWidthMinValue ()` - Specify the arrow length and base width (in normalized viewport coordinates).
- `double = obj.GetArrowWidthMaxValue ()` - Specify the arrow length and base width (in normalized viewport coordinates).
- `double = obj.GetArrowWidth ()` - Specify the arrow length and base width (in normalized viewport coordinates).
- `obj.SetMinimumArrowSize (double )` - Limit the minimum and maximum size of the arrows. These values are expressed in pixels and clamp the minimum/maximum possible size for the width/length of the arrow head. (When clamped, the ratio between length and width is preserved.)
- `double = obj.GetMinimumArrowSizeMinValue ()` - Limit the minimum and maximum size of the arrows. These values are expressed in pixels and clamp the minimum/maximum possible size for the width/length of the arrow head. (When clamped, the ratio between length and width is preserved.)
- `double = obj.GetMinimumArrowSizeMaxValue ()` - Limit the minimum and maximum size of the arrows. These values are expressed in pixels and clamp the minimum/maximum possible size for the width/length of the arrow head. (When clamped, the ratio between length and width is preserved.)
- `double = obj.GetMinimumArrowSize ()` - Limit the minimum and maximum size of the arrows. These values are expressed in pixels and clamp the minimum/maximum possible size for the width/length of the arrow head. (When clamped, the ratio between length and width is preserved.)
- `obj.SetMaximumArrowSize (double )` - Limit the minimum and maximum size of the arrows. These values are expressed in pixels and clamp the minimum/maximum possible size for the width/length of the arrow head. (When clamped, the ratio between length and width is preserved.)
- `double = obj.GetMaximumArrowSizeMinValue ()` - Limit the minimum and maximum size of the arrows. These values are expressed in pixels and clamp the minimum/maximum possible size for the width/length of the arrow head. (When clamped, the ratio between length and width is preserved.)
- `double = obj.GetMaximumArrowSizeMaxValue ()` - Limit the minimum and maximum size of the arrows. These values are expressed in pixels and clamp the minimum/maximum possible size for the width/length of the arrow head. (When clamped, the ratio between length and width is preserved.)
- `double = obj.GetMaximumArrowSize ()` - Limit the minimum and maximum size of the arrows. These values are expressed in pixels and clamp the minimum/maximum possible size for the width/length of the arrow head. (When clamped, the ratio between length and width is preserved.)
- `obj.SetAutoLabel (int )` - Enable auto-labelling. In this mode, the label is automatically updated based on distance (in world coordinates) between the two end points; or if a curved leader is being generated, the angle in degrees between the two points.
- `int = obj.GetAutoLabel ()` - Enable auto-labelling. In this mode, the label is automatically updated based on distance (in world coordinates) between the two end points; or if a curved leader is being generated, the angle in degrees between the two points.
- `obj.AutoLabelOn ()` - Enable auto-labelling. In this mode, the label is automatically updated based on distance (in world coordinates) between the two end points; or if a curved leader is being generated, the angle in degrees between the two points.
- `obj.AutoLabelOff ()` - Enable auto-labelling. In this mode, the label is automatically updated based on distance (in world coordinates) between the two end points; or if a curved leader is being generated, the angle in degrees between the two points.
- `obj.SetLabelFormat (string )` - Specify the format to use for auto-labelling.
- `string = obj.GetLabelFormat ()` - Specify the format to use for auto-labelling.
- `double = obj.GetLength ()` - Obtain the length of the leader if the leader is not curved, otherwise obtain the angle that the leader circumscribes.
- `double = obj.GetAngle ()` - Obtain the length of the leader if the leader is not curved, otherwise obtain the angle that the leader circumscribes.
- `int = obj.RenderOverlay (vtkViewport viewport)` - Methods required by vtkProp and vtkActor2D superclasses.
- `int = obj.RenderOpaqueGeometry (vtkViewport viewport)` - Methods required by vtkProp and vtkActor2D superclasses.
- `int = obj.RenderTranslucentPolygonalGeometry (vtkViewport )` - Does this prop have some translucent polygonal geometry?
- `int = obj.HasTranslucentPolygonalGeometry ()` - Does this prop have some translucent polygonal geometry?
- `obj.ReleaseGraphicsResources (vtkWindow )`
- `obj.ShallowCopy (vtkProp prop)`