pyvista.CornerAnnotation#

class CornerAnnotation(position, text, prop=None, linear_font_scale_factor=None)[source]#

Text annotation in four corners.

This is an annotation object that manages four text actors / mappers to provide annotation in the four corners of a viewport.

Parameters:
positionstr | bool

Position of the text.

textstr

Text input.

proppyvista.TextProperty, optional

Text property.

linear_font_scale_factorfloat, optional

Linear font scale factor.

Examples

Create text annotation in four corners.

>>> from pyvista import CornerAnnotation
>>> text = CornerAnnotation(0, 'text')
>>> prop = text.prop

Methods

CornerAnnotation.get_text(position)

Get the text to be displayed for each corner.

CornerAnnotation.set_text(position, text)

Set the text to be displayed for each corner.

Attributes

CornerAnnotation.linear_font_scale_factor

Font scaling factors.

CornerAnnotation.prop

Property of this actor.