Page Contents

This Page

Stack

class enaml.widgets.stack.Stack(parent=None, **kwargs)[source]

Bases: enaml.widgets.constraints_widget.ConstraintsWidget

A component which displays its children as a stack of widgets, only one of which is visible at a time.

index = None

The index of the visible widget in the stack. The widget itself does not provide a means to changing this index. That control must be supplied externally. If the given index falls outside of the range of stack items, no widget will be visible.

transition = None

The transition to use when change between stack items. XXX Document the supported transitions.

stack_items = None

A read only property which returns the stack’s StackItems

snapshot()[source]

Returns the snapshot for the control.

bind()[source]

Bind the change handlers for the control.

on_action_index_changed(content)[source]

Handle the index_changed action from the client widget.

__implements__

alias of __NoInterface__

Backends

Qt

digraph inheritance746406144d { rankdir=LR; width=8.0; ratio=compress; fontsize=14; size="8.0, 12.0"; "QtConstraintsWidget" [style="setlinewidth(0.5)",URL="enaml.widgets.constraints_widget.ConstraintsWidget.html#enaml.qt.qt_constraints_widget.QtConstraintsWidget",fontname=Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans,height=0.25,shape=box,fontsize=10]; "QtWidget" -> "QtConstraintsWidget" [arrowsize=0.5,style="setlinewidth(0.5)"]; "QtStack" [style="setlinewidth(0.5)",URL="#enaml.qt.qt_stack.QtStack",fontname=Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans,height=0.25,shape=box,fontsize=10]; "QtConstraintsWidget" -> "QtStack" [arrowsize=0.5,style="setlinewidth(0.5)"]; "QtWidget" [style="setlinewidth(0.5)",URL="enaml.widgets.widget.Widget.html#enaml.qt.qt_widget.QtWidget",fontname=Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans,height=0.25,shape=box,fontsize=10]; "QtObject" -> "QtWidget" [arrowsize=0.5,style="setlinewidth(0.5)"]; "QtObject" [shape=box,style="setlinewidth(0.5)",fontsize=10,fontname=Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans,height=0.25]; }

class enaml.qt.qt_stack.QtStack(object_id, parent, session)[source]

Bases: enaml.qt.qt_constraints_widget.QtConstraintsWidget

A Qt implementation of an Enaml Stack.

create_widget(parent, tree)[source]

Create the underlying QStack widget.

create(tree)[source]

Create and initialize the underlying control.

init_layout()[source]

Initialize the layout of the underlying control.

child_removed(child)[source]

Handle the child removed event for a QtStack.

child_added(child)[source]

Handle the child added event for a QtStack.

on_layout_requested()[source]

Handle the layoutRequested signal from the QStack.

on_current_changed()[source]

Handle the currentChanged signal from the QStack.

on_action_set_index(content)[source]

Handle the ‘set_index’ action from the Enaml widget.

on_action_set_transition(content)[source]

Handle the ‘set_transition’ action from the Enaml widget.

set_index(index)[source]

Set the current index of the underlying widget.

set_transition(transition)[source]

Set the transition on the underlying widget.

Wx