vtkTextMapper Class Reference
#include <vtkTextMapper.h>
Inheritance diagram for vtkTextMapper:
[legend]Collaboration diagram for vtkTextMapper:
[legend]List of all members.
Detailed Description
2D text annotation
vtkTextMapper provides 2D text annotation support for vtk. It is a vtkMapper2D that can be associated with a vtkActor2D and placed into a vtkRenderer.
To use vtkTextMapper, specify an input text string.
- See also:
- vtkMapper2D vtkActor2D vtkLegendBoxActor vtkCaptionActor2D vtkVectorText vtkTextProperty
- Created by:
-
- CVS contributions (if > 5%):
- Barre, Sebastien (42%)
- Martin, Ken (33%)
- Schroeder, Will (14%)
- CVS logs (CVSweb):
.cxx (/Rendering/vtkTextMapper
.cxx)
.h (/Rendering/vtkTextMapper
.h)
- Examples:
- vtkTextMapper (Examples)
- Tests:
- vtkTextMapper (Tests)
Definition at line 55 of file vtkTextMapper.h.
|
Public Types |
typedef vtkMapper2D | Superclass |
Public Member Functions |
virtual const char * | GetClassName () |
virtual int | IsA (const char *type) |
void | PrintSelf (ostream &os, vtkIndent indent) |
virtual int | GetNumberOfLines () |
void | ShallowCopy (vtkTextMapper *tm) |
int | GetNumberOfLines (const char *input) |
|
virtual void | GetSize (vtkViewport *, int size[2]) |
virtual int | GetWidth (vtkViewport *v) |
virtual int | GetHeight (vtkViewport *v) |
|
virtual void | SetInput (const char *inputString) |
virtual char * | GetInput () |
|
virtual void | SetTextProperty (vtkTextProperty *p) |
virtual vtkTextProperty * | GetTextProperty () |
|
virtual int | SetConstrainedFontSize (vtkViewport *, int targetWidth, int targetHeight) |
|
virtual int | GetSystemFontSize (int size) |
Static Public Member Functions |
int | IsTypeOf (const char *type) |
vtkTextMapper * | SafeDownCast (vtkObject *o) |
vtkTextMapper * | New () |
|
int | SetMultipleConstrainedFontSize (vtkViewport *, int targetWidth, int targetHeight, vtkTextMapper **mappers, int nbOfMappers, int *maxResultingSize) |
Protected Member Functions |
| vtkTextMapper () |
| ~vtkTextMapper () |
char * | NextLine (const char *input, int lineNum) |
void | GetMultiLineSize (vtkViewport *viewport, int size[2]) |
void | RenderOverlayMultipleLines (vtkViewport *viewport, vtkActor2D *actor) |
Protected Attributes |
char * | Input |
vtkTextProperty * | TextProperty |
int | LineSize |
int | NumberOfLines |
int | NumberOfLinesAllocated |
vtkTextMapper ** | TextLines |
Member Typedef Documentation
Constructor & Destructor Documentation
vtkTextMapper::vtkTextMapper |
( |
|
) |
[protected] |
|
Member Function Documentation
virtual const char* vtkTextMapper::GetClassName |
( |
|
) |
[virtual] |
|
int vtkTextMapper::IsTypeOf |
( |
const char * |
type |
) |
[static] |
|
virtual int vtkTextMapper::IsA |
( |
const char * |
type |
) |
[virtual] |
|
void vtkTextMapper::PrintSelf |
( |
ostream & |
os, |
|
|
vtkIndent |
indent |
|
) |
[virtual] |
|
virtual void vtkTextMapper::GetSize |
( |
vtkViewport * |
, |
|
|
int |
size[2] |
|
) |
[inline, virtual] |
|
virtual int vtkTextMapper::GetWidth |
( |
vtkViewport * |
v |
) |
[virtual] |
|
|
Return the size[2]/width/height of the rectangle required to draw this mapper (in pixels). |
virtual int vtkTextMapper::GetHeight |
( |
vtkViewport * |
v |
) |
[virtual] |
|
|
Return the size[2]/width/height of the rectangle required to draw this mapper (in pixels). |
virtual void vtkTextMapper::SetInput |
( |
const char * |
inputString |
) |
[virtual] |
|
|
Set the input text string to the mapper. The mapper recognizes "\n" as a carriage return/linefeed (line separator). |
virtual char* vtkTextMapper::GetInput |
( |
|
) |
[virtual] |
|
|
Set the input text string to the mapper. The mapper recognizes "\n" as a carriage return/linefeed (line separator). |
virtual void vtkTextMapper::SetTextProperty |
( |
vtkTextProperty * |
p |
) |
[virtual] |
|
|
Set/Get the text property. |
|
Set/Get the text property. |
virtual int vtkTextMapper::GetNumberOfLines |
( |
|
) |
[virtual] |
|
|
Shallow copy of an actor. |
int vtkTextMapper::GetNumberOfLines |
( |
const char * |
input |
) |
|
|
|
Determine the number of lines in the Input string (delimited by "\n"). |
virtual int vtkTextMapper::SetConstrainedFontSize |
( |
vtkViewport * |
, |
|
|
int |
targetWidth, |
|
|
int |
targetHeight |
|
) |
[virtual] |
|
|
Set and return the font size required to make this mapper fit in a given target rectangle (width * height, in pixels). |
int vtkTextMapper::SetMultipleConstrainedFontSize |
( |
vtkViewport * |
, |
|
|
int |
targetWidth, |
|
|
int |
targetHeight, |
|
|
vtkTextMapper ** |
mappers, |
|
|
int |
nbOfMappers, |
|
|
int * |
maxResultingSize |
|
) |
[static] |
|
|
Set and return the font size required to make each element of an array of mappers fit in a given rectangle (width * height, in pixels). This font size is the smallest size that was required to fit the largest mapper in this constraint. The resulting maximum area of the mappers is also returned. |
virtual int vtkTextMapper::GetSystemFontSize |
( |
int |
size |
) |
[inline, virtual] |
|
|
Get the available system font size matching a font size.
Definition at line 116 of file vtkTextMapper.h. |
char* vtkTextMapper::NextLine |
( |
const char * |
input, |
|
|
int |
lineNum |
|
) |
[protected] |
|
void vtkTextMapper::GetMultiLineSize |
( |
vtkViewport * |
viewport, |
|
|
int |
size[2] |
|
) |
[protected] |
|
void vtkTextMapper::RenderOverlayMultipleLines |
( |
vtkViewport * |
viewport, |
|
|
vtkActor2D * |
actor |
|
) |
[protected] |
|
Member Data Documentation
The documentation for this class was generated from the following file: