You are reading an old version of the documentation (v3.1.0). For the latest version see
Version 3.1.0
Fork me on GitHub


class mpl_toolkits.mplot3d.art3d.Text3D(x=0, y=0, z=0, text='', zdir='z', **kwargs)[source]

Bases: matplotlib.text.Text

Text object with 3D position and direction.

x, y, z

The position of the text.

text : str

The text string to display.

zdir : {'x', 'y', 'z', None, 3-tuple}

The direction of the text. See get_dir_vector for a description of the values.

Other Parameters:

All other parameters are passed on to Text.

draw(self, renderer)[source]

Draws the Text object to the given renderer.

get_tightbbox(self, renderer)[source]

Like Artist.get_window_extent, but includes any clipping.

renderer : RendererBase instance

renderer that will be used to draw the figures (i.e. fig.canvas.get_renderer())

bbox : BBox

The enclosing bounding box (in figure pixel co-ordinates).

set_3d_properties(self, z=0, zdir='z')[source]