70 #ifndef vtkAxisActor2D_h
71 #define vtkAxisActor2D_h
74 #include "vtkRenderingAnnotationModule.h"
122 vtkGetVectorMacro(
Range,
double, 2);
142 vtkGetMacro(RulerDistance,
double);
156 vtkSetClampMacro(NumberOfLabels,
int, 2, VTK_MAX_LABELS);
157 vtkGetMacro(NumberOfLabels,
int);
165 vtkSetStringMacro(LabelFormat);
166 vtkGetStringMacro(LabelFormat);
183 this->UpdateAdjustedRange();
184 return this->AdjustedRange;
188 this->UpdateAdjustedRange();
189 _arg1 = this->AdjustedRange[0];
190 _arg2 = this->AdjustedRange[1];
195 this->UpdateAdjustedRange();
196 return this->AdjustedNumberOfLabels;
204 vtkSetStringMacro(Title);
205 vtkGetStringMacro(Title);
229 vtkSetClampMacro(TickLength,
int, 0, 100);
230 vtkGetMacro(TickLength,
int);
238 vtkSetClampMacro(NumberOfMinorTicks,
int, 0, 20);
239 vtkGetMacro(NumberOfMinorTicks,
int);
247 vtkSetClampMacro(MinorTickLength,
int, 0, 100);
248 vtkGetMacro(MinorTickLength,
int);
257 vtkSetClampMacro(TickOffset,
int, 0, 100);
258 vtkGetMacro(TickOffset,
int);
302 vtkSetMacro(TitlePosition,
double);
303 vtkGetMacro(TitlePosition,
double);
312 vtkSetClampMacro(FontFactor,
double, 0.1, 2.0);
313 vtkGetMacro(FontFactor,
double);
321 vtkSetClampMacro(LabelFactor,
double, 0.1, 2.0);
322 vtkGetMacro(LabelFactor,
double);
357 double inRange[2],
double outRange[2],
int inNumTicks,
int& outNumTicks,
double& interval);
368 int nbOfMappers,
int* targetSize,
double factor,
int* stringSize);
418 double AdjustedRange[2];
428 int LastPosition2[2];
431 int LastMaxLabelSize[2];
a actor that draws 2D data
virtual vtkCoordinate * GetPositionCoordinate()
Get the PositionCoordinate instance of vtkCoordinate.
virtual void SetPosition2(float x[2])
Access the Position2 instance variable.
virtual vtkCoordinate * GetPosition2Coordinate()
Access the Position2 instance variable.
virtual float * GetPosition2()
Access the Position2 instance variable.
virtual void SetPosition(float x[2])
Get the PositionCoordinate instance of vtkCoordinate.
virtual float * GetPosition()
Get the PositionCoordinate instance of vtkCoordinate.
Create an axis with tick marks and labels.
int RenderTranslucentPolygonalGeometry(vtkViewport *) override
Draw the axis.
virtual void SetPoint1(double x[2])
Specify the position of the first point defining the axis.
vtkPolyDataMapper2D * AxisMapper
vtkTextMapper * TitleMapper
vtkTypeBool HasTranslucentPolygonalGeometry() override
Does this prop have some translucent polygonal geometry?
vtkTypeBool TickVisibility
virtual void SetTitleTextProperty(vtkTextProperty *p)
Set/Get the title text property.
virtual double * GetPoint2()
Specify the position of the second point defining the axis.
vtkActor2D ** LabelActors
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkTypeBool LabelVisibility
int AdjustedNumberOfLabels
static void SetOffsetPosition(double xTick[3], double theta, int stringWidth, int stringHeight, int offset, vtkActor2D *actor)
virtual void BuildAxis(vtkViewport *viewport)
static int SetMultipleFontSize(vtkViewport *viewport, vtkTextMapper **textMappers, int nbOfMappers, int *targetSize, double factor, int *stringSize)
General method to computes font size from a representative size on the viewport (given by size[2]).
vtkTextProperty * TitleTextProperty
virtual void SetPoint1(double x, double y)
Specify the position of the first point defining the axis.
static vtkAxisActor2D * New()
Instantiate object.
static void ComputeRange(double inRange[2], double outRange[2], int inNumTicks, int &outNumTicks, double &interval)
This method computes the range of the axis given an input range.
virtual vtkCoordinate * GetPoint1Coordinate()
Specify the position of the first point defining the axis.
virtual double * GetPoint1()
Specify the position of the first point defining the axis.
int RenderOpaqueGeometry(vtkViewport *viewport) override
Draw the axis.
vtkTimeStamp AdjustedRangeBuildTime
virtual void GetAdjustedRange(double _arg[2])
Set/Get the flag that controls whether the labels and ticks are adjusted for "nice" numerical values ...
virtual double * GetAdjustedRange()
Set/Get the flag that controls whether the labels and ticks are adjusted for "nice" numerical values ...
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this actor.
vtkTextMapper ** LabelMappers
vtkTypeBool UseFontSizeFromProperty
vtkTypeBool AxisVisibility
static double ComputeStringOffset(double width, double height, double theta)
int RenderOverlay(vtkViewport *viewport) override
Draw the axis.
int SizeFontRelativeToAxis
void ShallowCopy(vtkProp *prop) override
Shallow copy of an axis actor.
virtual void SetPoint2(double x[2])
Specify the position of the second point defining the axis.
virtual void SetLabelTextProperty(vtkTextProperty *p)
Set/Get the labels text property.
virtual vtkCoordinate * GetPoint2Coordinate()
Specify the position of the second point defining the axis.
vtkTextProperty * LabelTextProperty
virtual int GetAdjustedNumberOfLabels()
Set/Get the flag that controls whether the labels and ticks are adjusted for "nice" numerical values ...
virtual void GetAdjustedRange(double &_arg1, double &_arg2)
Set/Get the flag that controls whether the labels and ticks are adjusted for "nice" numerical values ...
~vtkAxisActor2D() override
virtual void SetPoint2(double x, double y)
Specify the position of the second point defining the axis.
vtkTypeBool TitleVisibility
virtual void UpdateAdjustedRange()
perform coordinate transformation, and represent position, in a variety of vtk coordinate systems
a simple class to control print indentation
draw vtkPolyData onto the image plane
concrete dataset represents vertices, lines, polygons, and triangle strips
abstract superclass for all actors, volumes and annotations
represent text properties.
record modification and/or execution time
abstract specification for Viewports
window superclass for vtkRenderWindow
auto Range(IterablePtr iterable, Options &&... opts) -> typename detail::IterableTraits< typename detail::StripPointers< IterablePtr >::type >::RangeType
Generate an iterable STL proxy object for a VTK container.