honeybee_vtk.text_actor module

Honeybee-vtk TextActor object.

class honeybee_vtk.text_actor.TextActor(text: str, height: int = 15, color: Tuple[int, int, int] = (0, 0, 0), position: Tuple[float, float] = (0.45, 0.0), bold: bool = False)[source]

Bases: object

Use this object to create a vtk text actor.

This text actor can be used to add text to a vtk scene.

Parameters
  • text – Text to be added to the Scene.

  • height – Text height in pixels. Default is 15.

  • color – Text color as a tuple of RGB values. Defaults to (0,0,0) which will give the text black color.

  • position – The text position of the text in the image as a tuple of (x, y). The setting is applied at the lower left point of the text. (0,0) will give you the lower left corner of the image. (1,1) will give you the upper right corner of the image. Defaults to (0.45, 0.0) which will put the text at the bottom center of the image.

  • bold – Boolean to decide whether to make the text bold. Defaults to False.

to_vtk() → vtkmodules.vtkRenderingCore.vtkTextActor[source]

Create a vtk text actor.

property color

Get the text color.

property height

Get the text height.

property position

Get the text position.

property text

Get the text.