pyface.tasks.task_layout module

class pyface.tasks.task_layout.LayoutItem[source]

Bases: HasStrictTraits

The base class for all Task-related layout objects.

iterleaves()[source]
pargs()[source]
pformat(indent=0, multiline=False)[source]

Pretty-format the layout item. Returns a string.

pprint(indent=0, multiline=False)[source]

Pretty-prints the layout item.

pstream(stream, indent=0, multiline=False)[source]

Pretty-formats the layout item to a stream.

class pyface.tasks.task_layout.LayoutContainer(*items, **traits)[source]

Bases: LayoutItem

The base class for all layout items that contain other layout items.

iterleaves()[source]
pargs()[source]
class pyface.tasks.task_layout.PaneItem(id='', **traits)[source]

Bases: LayoutItem

A pane in a Task layout.

width = Int(-1)

The width of the pane in pixels. If not specified, the pane will be sized according to its size hint.

height = Int(-1)

The height of the pane in pixels. If not specified, the pane will be sized according to its size hint.

id = Union(Str, Int, default_value="", pretty_skip=True)

The ID of the item. If the item refers to a TaskPane, this is the ID of that TaskPane.

pargs()[source]
class pyface.tasks.task_layout.Tabbed(*items, **traits)[source]

Bases: LayoutContainer

A tab area in a Task layout.

items = List(PaneItem, pretty_skip=True)

A tabbed layout can only contain PaneItems as sub-items. Splitters and other Tabbed layouts are not allowed.

active_tab = Union(Str, Int, default_value="")

The ID of the TaskPane which is active in layout. If not specified, the first pane is active.

class pyface.tasks.task_layout.Splitter(*items, **traits)[source]

Bases: LayoutContainer

A split area in a Task layout.

orientation = Enum("horizontal", "vertical")

The orientation of the splitter.

items = List(

The sub-items of the splitter, which are PaneItems, Tabbed layouts, and other Splitters.

class pyface.tasks.task_layout.HSplitter(*items, **traits)[source]

Bases: Splitter

A convenience class for horizontal splitters.

class pyface.tasks.task_layout.VSplitter(*items, **traits)[source]

Bases: Splitter

A convenience class for vertical splitters.

class pyface.tasks.task_layout.DockLayout[source]

Bases: LayoutItem

The layout for a main window’s dock area.

top_left_corner = Enum("top", "left")

Assignments of dock areas to the window’s corners. By default, the top and bottom dock areas extend into both of the top and both of the bottom corners, respectively.

class pyface.tasks.task_layout.TaskLayout[source]

Bases: DockLayout

The layout for a Task.

id = Str()

The ID of the task for which this is a layout.