pyface.viewer.label_provider module

Abstract base class for label providers.

class pyface.viewer.label_provider.LabelProvider[source]

Bases: traits.has_traits.HasTraits

Abstract base class for label providers.

By default an element has no label image, and ‘str’ is used to generate its label text.

get_image(viewer, element)[source]

Returns the label image for an element.

get_text(viewer, element)[source]

Returns the label text for an element.

set_text(tree, element, text)[source]

Sets the text representation of a node.

Returns True if setting the text succeeded, otherwise False.

is_editable(viewer, element)[source]

Can the label text be changed via the viewer?