exopy.utils.widgets.list_editor module

Template widget allowing to edit a list member from an Atom object.

The list should be composed of Atom object itself, and should be paired with a Signal used to notify listeners about internal changes of the list. It is the responsability of the model to signal internal changes to the list.

2015-2018-04-09 To work correctly this requires the latest master of enaml (>0.9.8)

class exopy.utils.widgets.list_editor.ListContainer(parent=None, **kwargs)

Bases: enaml.widgets.container.Container

Custom container handling the layout for the list editor.

The user specifies which widget to use to edit the list and this container takes care of correctly laying out the PushButton used to edit the list content.

alignment

A value of type unicode.

By default, plain strings will be promoted to unicode strings. Pass strict=True to the constructor to enable strict unicode checking.

layout_constraints()

Layout the push buttons used to edit the list content.

class exopy.utils.widgets.list_editor.PopupListMenu(parent=None, **kwargs)

Bases: enaml.widgets.menu.Menu

Popup menu used to alter add, delete or move elements in the list.

index

A value which allows objects of a given type or types.

Values will be tested using the PyObject_IsInstance C API call. This call is equivalent to isinstance(value, kind) and all the same rules apply.

The value of an Instance may be set to None.

model

A value which allows objects of a given type or types.

Values will be tested using the PyObject_IsInstance C API call. This call is equivalent to isinstance(value, kind) and all the same rules apply.

The value of an Instance may be set to None.

operations

A value which allows objects of a given type or types.

Values will be tested using the PyObject_IsInstance C API call. This call is equivalent to isinstance(value, kind) and all the same rules apply.

The value of an Instance may be set to None.