NorMIT-nav  22.09
An IGT application
cx::TextDisplay Class Reference

Helper for drawing text in 2D. More...

#include <cxVtkHelperClasses.h>

Public Member Functions

 TextDisplay (const QString &text, const QColor &color, int fontsize)
 
 ~TextDisplay ()
 
void setRenderer (vtkRendererPtr renderer)
 
void setPosition (float x, float y)
 
void setPosition (const Vector3D &pos)
 
void setCentered ()
 
void updateText (const QString &text)
 
void setColor (QColor color)
 
vtkTextProperty * textProperty ()
 
vtkActor2DPtr getActor ()
 
void setMaxWidth (int width, vtkViewport *vp)
 
int getMaxWidth ()
 
int getWidth (vtkViewport *vp)
 
vtkTextMapperPtr getMapper ()
 

Static Public Member Functions

static void forceUseVtkTextMapper ()
 

Detailed Description

Helper for drawing text in 2D.

Definition at line 111 of file cxVtkHelperClasses.h.

Constructor & Destructor Documentation

◆ TextDisplay()

cx::TextDisplay::TextDisplay ( const QString &  text,
const QColor &  color,
int  fontsize 
)

Definition at line 293 of file cxVtkHelperClasses.cpp.

◆ ~TextDisplay()

cx::TextDisplay::~TextDisplay ( )

Definition at line 352 of file cxVtkHelperClasses.cpp.

Member Function Documentation

◆ forceUseVtkTextMapper()

void cx::TextDisplay::forceUseVtkTextMapper ( )
static

Definition at line 308 of file cxVtkHelperClasses.cpp.

◆ getActor()

vtkActor2DPtr cx::TextDisplay::getActor ( )

Definition at line 423 of file cxVtkHelperClasses.cpp.

◆ getMapper()

vtkTextMapperPtr cx::TextDisplay::getMapper ( )
inline

Definition at line 127 of file cxVtkHelperClasses.h.

◆ getMaxWidth()

int cx::TextDisplay::getMaxWidth ( )

Definition at line 383 of file cxVtkHelperClasses.cpp.

◆ getWidth()

int cx::TextDisplay::getWidth ( vtkViewport *  vp)

Definition at line 388 of file cxVtkHelperClasses.cpp.

◆ setCentered()

void cx::TextDisplay::setCentered ( )

Definition at line 428 of file cxVtkHelperClasses.cpp.

◆ setColor()

void cx::TextDisplay::setColor ( QColor  color)

Definition at line 338 of file cxVtkHelperClasses.cpp.

◆ setMaxWidth()

void cx::TextDisplay::setMaxWidth ( int  width,
vtkViewport *  vp 
)

Definition at line 357 of file cxVtkHelperClasses.cpp.

◆ setPosition() [1/2]

void cx::TextDisplay::setPosition ( const Vector3D pos)

Definition at line 393 of file cxVtkHelperClasses.cpp.

◆ setPosition() [2/2]

void cx::TextDisplay::setPosition ( float  x,
float  y 
)

Definition at line 398 of file cxVtkHelperClasses.cpp.

◆ setRenderer()

void cx::TextDisplay::setRenderer ( vtkRendererPtr  renderer)

Definition at line 343 of file cxVtkHelperClasses.cpp.

◆ textProperty()

vtkTextProperty * cx::TextDisplay::textProperty ( )

Definition at line 418 of file cxVtkHelperClasses.cpp.

◆ updateText()

void cx::TextDisplay::updateText ( const QString &  text)

Definition at line 403 of file cxVtkHelperClasses.cpp.


The documentation for this class was generated from the following files: