chaco.plots.text_plot module

A plot that renders text values in two dimensions

class chaco.plots.text_plot.TextPlot(**kwtraits)

Bases: chaco.base_xy_plot.BaseXYPlot

A plot that positions textual labels in 2D

h_position = Enum("center", "left", "right")

horizontal position of text relative to target point

text = Instance(ArrayDataSource)

text values corresponding to indices

text_color = black_color_trait

The color of the tick labels.

text_font = KivaFont("modern 10")

The font of the tick labels.

text_margin = Int(2)

The margin around the label.

text_offset = Tuple(Float, Float)

offset of text relative to non-index direction in pixels

text_rotate_angle = Float(0)

The rotation of the tick labels.

v_position = Enum("center", "top", "bottom")

vertical position of text relative to target point