Page Contents

This Page

Splitter

class enaml.widgets.splitter.Splitter(parent=None, **kwargs)[source]

Bases: enaml.widgets.constraints_widget.ConstraintsWidget

A widget which displays its children in separate resizable compartements that are connected with a resizing bar.

A Splitter can have an arbitrary number of Container children.

orientation = None

The orientation of the Splitter. ‘horizontal’ means the children are laid out left to right, ‘vertical’ means top to bottom.

live_drag = None

Whether the child widgets resize as a splitter is being dragged (True), or if a simple indicator is drawn until the drag handle is released (False). The default is True.

split_items = None

A read only property which returns the split items being managed by the splitter.

hug_width = None

How strongly a component hugs it’s contents’ width. A Splitter container ignores its width hug by default, so it expands freely in width.

hug_height = None

How strongly a component hugs it’s contents’ height. A Splitter container ignores its height hug by default, so it expands freely in height.

snapshot()[source]

Return the dict of creation attributes for the control.

bind()[source]

Bind the change handlers for the widget.

__implements__

alias of __NoInterface__

Backends

Qt

Inheritance diagram of enaml.qt.qt_splitter.QtSplitter

class enaml.qt.qt_splitter.QtSplitter(object_id, parent, session)[source]

Bases: enaml.qt.qt_constraints_widget.QtConstraintsWidget

A Qt implementation of an Enaml Splitter.

create_widget(parent, tree)[source]

Creates the underlying QSplitter control.

create(tree)[source]

Create and initialize the underlying control.

init_layout()[source]

Handle the layout initialization for the splitter.

child_added(child)[source]

Handle the child added event for a QtSplitter.

on_layout_requested()[source]

Handle the layoutRequested signal from the QSplitter.

on_win32_slider_moved()[source]

Handle the ‘sliderMoved’ signal from the QSplitter.

This handler is only connected when running on Windows and it serves to make sure paint events get generated during heavy resize events when opaque resizing is turned on.

on_action_set_orientation(content)[source]

Handle the ‘set_orientation’ action from the Enaml widget.

on_action_set_live_drag(content)[source]

Handle the ‘set_live_drag’ action from the Enaml widget.

set_orientation(orientation)[source]

Update the orientation of the QSplitter.

set_live_drag(live_drag)[source]

Update the dragging mode of the QSplitter.

Wx

Inheritance diagram of enaml.wx.wx_splitter.WxSplitter

class enaml.wx.wx_splitter.WxSplitter(object_id, parent, session)[source]

Bases: enaml.wx.wx_constraints_widget.WxConstraintsWidget

A Wx implementation of an Enaml Splitter.

create_widget(parent, tree)[source]

Creates the underlying wxSplitter widget.

create(tree)[source]

Create and initialize the splitter control.

init_layout()[source]

Handle the layout initialization for the splitter.

child_removed(child)[source]

Handle the child removed event for a WxSplitter.

child_added(child)[source]

Handle the child added event for a WxSplitter.

on_action_set_orientation(content)[source]

Handle the ‘set_orientation’ action from the Enaml widget.

on_action_set_live_drag(content)[source]

Handle the ‘set_live_drag’ action from the Enaml widget.

set_orientation(orientation)[source]

Update the orientation of the splitter.

set_live_drag(live_drag)[source]

Updates the drag state of the splitter.