Panel.Dock

g GObject.GInterface GObject.GInterface Gtk.Accessible Gtk.Accessible GObject.GInterface->Gtk.Accessible Gtk.Buildable Gtk.Buildable GObject.GInterface->Gtk.Buildable Gtk.ConstraintTarget Gtk.ConstraintTarget GObject.GInterface->Gtk.ConstraintTarget GObject.InitiallyUnowned GObject.InitiallyUnowned Gtk.Widget Gtk.Widget GObject.InitiallyUnowned->Gtk.Widget GObject.Object GObject.Object GObject.Object->GObject.InitiallyUnowned Gtk.Accessible->Gtk.Widget Gtk.Buildable->Gtk.Widget Gtk.ConstraintTarget->Gtk.Widget Panel.Dock Panel.Dock Gtk.Widget->Panel.Dock

Subclasses:

None

Methods

Inherited:

Gtk.Widget (181), GObject.Object (37), Gtk.Accessible (15), Gtk.Buildable (1)

Structs:

Gtk.WidgetClass (18), GObject.ObjectClass (5)

class

new ()

foreach_frame (callback, *user_data)

get_can_reveal_area (area)

get_can_reveal_bottom ()

get_can_reveal_end ()

get_can_reveal_start ()

get_can_reveal_top ()

get_reveal_area (area)

get_reveal_bottom ()

get_reveal_end ()

get_reveal_start ()

get_reveal_top ()

remove (widget)

set_bottom_height (height)

set_end_width (width)

set_reveal_area (area, reveal)

set_reveal_bottom (reveal_bottom)

set_reveal_end (reveal_end)

set_reveal_start (reveal_start)

set_reveal_top (reveal_top)

set_start_width (width)

set_top_height (height)

Virtual Methods

Inherited:

Gtk.Widget (25), GObject.Object (7), Gtk.Accessible (6), Gtk.Buildable (9)

do_panel_drag_begin (widget)

do_panel_drag_end (widget)

Properties

Inherited:

Gtk.Widget (34), Gtk.Accessible (1)

Name

Type

Flags

Short Description

bottom-height

int

r/w

Bottom Height

can-reveal-bottom

bool

r

Can reveal bottom

can-reveal-end

bool

r

Can reveal end

can-reveal-start

bool

r

Can reveal start

can-reveal-top

bool

r

Can reveal top

end-width

int

r/w

End Width

reveal-bottom

bool

r/w/en

Reveal bottom

reveal-end

bool

r/w/en

Reveal end

reveal-start

bool

r/w/en

Reveal start

reveal-top

bool

r/w/en

Reveal top

start-width

int

r/w

Start Width

top-height

int

r/w

Top Height

Signals

Inherited:

Gtk.Widget (13), GObject.Object (1)

Name

Short Description

adopt-widget

Signal is emitted when a widget is requesting to be added via a drag-n-drop event.

create-frame

This signal is emitted when a new frame is needed.

panel-drag-begin

This signal is emitted when dragging of a panel begins.

panel-drag-end

This signal is emitted when dragging of a panel either completes or was cancelled.

Fields

Inherited:

Gtk.Widget (13), GObject.Object (1)

Name

Type

Access

Description

parent_instance

Gtk.Widget

r

Class Details

class Panel.Dock(**kwargs)
Bases:

Gtk.Widget

Abstract:

No

Structure:

Panel.DockClass

The Panel.Dock is a widget designed to contain widgets that can be docked. Use the Panel.Dock as the top widget of your dockable UI.

A Panel.Dock is divided in 5 areas: Panel.Area.TOP, Panel.Area.BOTTOM, Panel.Area.START, Panel.Area.END represent the surrounding areas that can revealed. Panel.Area.CENTER represent the main area, that is always displayed and resized depending on the reveal state of the surrounding areas.

It will contain a #PanelDockChild for each of the areas in use, albeit this is done by the widget.

classmethod new()
Returns:

a newly created Panel.Dock

Return type:

Gtk.Widget

Create a new Panel.Dock.

foreach_frame(callback, *user_data)
Parameters:

Invokes a callback for each frame in the dock.

get_can_reveal_area(area)
Parameters:

area (Panel.Area) – the panel area to check.

Returns:

whether it can reveal the area or not. If the is no child or the child is empty, will return False.

Return type:

bool

Tells if the panel area can be revealed.

get_can_reveal_bottom()
Returns:

whether it can reveal the bottom area or not. If the is no child or the child is empty, will return False.

Return type:

bool

Tells if the bottom panel area can be revealed.

get_can_reveal_end()
Returns:

whether it can reveal the end area or not. If the is no child or the child is empty, will return False.

Return type:

bool

Tells if the end panel area can be revealed.

get_can_reveal_start()
Returns:

whether it can reveal the start area or not. If the is no child or the child is empty, will return False.

Return type:

bool

Tells if the start panel area can be revealed.

get_can_reveal_top()
Returns:

whether it can reveal the top area or not. If the is no child or the child is empty, will return False.

Return type:

bool

Tells if the top panel area can be revealed.

get_reveal_area(area)
Parameters:

area (Panel.Area) – the Panel.Area to return the reveal status of.

Returns:

The reveal state.

Return type:

bool

Tells if an area if revealed.

get_reveal_bottom()
Returns:

The reveal state of the bottom area.

Return type:

bool

Tells if the bottom area is revealed.

get_reveal_end()
Returns:

The reveal state of the end area.

Return type:

bool

Tells if the end area is revealed.

get_reveal_start()
Returns:

The reveal state of the start area.

Return type:

bool

Tells if the start area is revealed.

get_reveal_top()
Returns:

The reveal state of the top area.

Return type:

bool

Tells if the top area is revealed.

remove(widget)
Parameters:

widget (Gtk.Widget) – a Gtk.Widget to remove

Removes a widget from the dock. If widget is not a #DockChild, then the closest #DockChild parent is removed.

set_bottom_height(height)
Parameters:

height (int) – the height

Set the height of the bottom area.

set_end_width(width)
Parameters:

width (int) – the width

Set the width of the end area.

set_reveal_area(area, reveal)
Parameters:

Sets the reveal status of the area.

set_reveal_bottom(reveal_bottom)
Parameters:

reveal_bottom (bool) – reveal the bottom area.

Sets the reveal status of the bottom area.

set_reveal_end(reveal_end)
Parameters:

reveal_end (bool) – reveal the end area.

Sets the reveal status of the end area.

set_reveal_start(reveal_start)
Parameters:

reveal_start (bool) – reveal the start area.

Sets the reveal status of the start area.

set_reveal_top(reveal_top)
Parameters:

reveal_top (bool) – reveal the top area.

Sets the reveal status of the top area.

set_start_width(width)
Parameters:

width (int) – the width

Set the width of the start area.

set_top_height(height)
Parameters:

height (int) – the height

Set the height of the top area.

do_panel_drag_begin(widget) virtual
Parameters:

widget (Panel.Widget) –

do_panel_drag_end(widget) virtual
Parameters:

widget (Panel.Widget) –

Signal Details

Panel.Dock.signals.adopt_widget(dock, widget)
Signal Name:

adopt-widget

Flags:

RUN_LAST

Parameters:
Returns:

Gdk.EVENT_STOP to prevent dropping, otherwise Gdk.EVENT_PROPAGATE to allow adopting the widget.

Return type:

bool

Signal is emitted when a widget is requesting to be added via a drag-n-drop event.

This is generally propagated via Panel.Frame ::adopt-widget to the dock so that applications do not need to attach signal handlers to every Panel.Frame.

New in version 1.2.

Panel.Dock.signals.create_frame(dock, position)
Signal Name:

create-frame

Flags:

RUN_LAST

Parameters:
Returns:

a Panel.Frame

Return type:

Panel.Frame

This signal is emitted when a new frame is needed.

New in version 1.2.

Panel.Dock.signals.panel_drag_begin(dock, panel)
Signal Name:

panel-drag-begin

Flags:

RUN_LAST

Parameters:

This signal is emitted when dragging of a panel begins.

Panel.Dock.signals.panel_drag_end(dock, panel)
Signal Name:

panel-drag-end

Flags:

RUN_LAST

Parameters:

This signal is emitted when dragging of a panel either completes or was cancelled.

Property Details

Panel.Dock.props.bottom_height
Name:

bottom-height

Type:

int

Default Value:

-1

Flags:

READABLE, WRITABLE

Bottom Height

Panel.Dock.props.can_reveal_bottom
Name:

can-reveal-bottom

Type:

bool

Default Value:

False

Flags:

READABLE

Can reveal bottom

Panel.Dock.props.can_reveal_end
Name:

can-reveal-end

Type:

bool

Default Value:

False

Flags:

READABLE

Can reveal end

Panel.Dock.props.can_reveal_start
Name:

can-reveal-start

Type:

bool

Default Value:

False

Flags:

READABLE

Can reveal start

Panel.Dock.props.can_reveal_top
Name:

can-reveal-top

Type:

bool

Default Value:

False

Flags:

READABLE

Can reveal top

Panel.Dock.props.end_width
Name:

end-width

Type:

int

Default Value:

-1

Flags:

READABLE, WRITABLE

End Width

Panel.Dock.props.reveal_bottom
Name:

reveal-bottom

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

Reveal bottom

Panel.Dock.props.reveal_end
Name:

reveal-end

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

Reveal end

Panel.Dock.props.reveal_start
Name:

reveal-start

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

Reveal start

Panel.Dock.props.reveal_top
Name:

reveal-top

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

Reveal top

Panel.Dock.props.start_width
Name:

start-width

Type:

int

Default Value:

-1

Flags:

READABLE, WRITABLE

Start Width

Panel.Dock.props.top_height
Name:

top-height

Type:

int

Default Value:

-1

Flags:

READABLE, WRITABLE

Top Height