Wnck.Pager

g Atk.ImplementorIface Atk.ImplementorIface Gtk.Widget Gtk.Widget Atk.ImplementorIface->Gtk.Widget GObject.GInterface GObject.GInterface GObject.GInterface->Atk.ImplementorIface Gtk.Buildable Gtk.Buildable GObject.GInterface->Gtk.Buildable GObject.InitiallyUnowned GObject.InitiallyUnowned GObject.InitiallyUnowned->Gtk.Widget GObject.Object GObject.Object GObject.Object->GObject.InitiallyUnowned Gtk.Buildable->Gtk.Widget Wnck.Pager Wnck.Pager Gtk.Widget->Wnck.Pager

Subclasses:

None

Methods

Inherited:

Gtk.Widget (278), GObject.Object (37), Gtk.Buildable (10)

Structs:

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

class

new ()

class

new_with_handle (handle)

get_wrap_on_scroll ()

set_display_mode (mode)

set_n_rows (n_rows)

set_orientation (orientation)

set_scroll_mode (scroll_mode)

set_shadow_type (shadow_type)

set_show_all (show_all_workspaces)

set_wrap_on_scroll (wrap_on_scroll)

Virtual Methods

Inherited:

Gtk.Widget (82), GObject.Object (7), Gtk.Buildable (10)

Properties

Inherited:

Gtk.Widget (39)

Name

Type

Flags

Short Description

handle

Wnck.Handle

r/w/co/en

handle

Style Properties

Inherited:

Gtk.Widget (17)

Signals

Inherited:

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

Fields

Inherited:

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

Name

Type

Access

Description

parent_instance

Gtk.Container

r

Class Details

class Wnck.Pager(**kwargs)
Bases:

Gtk.Widget

Abstract:

No

Structure:

Wnck.PagerClass

The Wnck.Pager struct contains only private fields and should not be directly accessed.

classmethod new()
Returns:

a newly created Wnck.Pager.

Return type:

Gtk.Widget

Creates a new Wnck.Pager. The Wnck.Pager will show the Wnck.Workspace of the Wnck.Screen it is on.

classmethod new_with_handle(handle)
Parameters:

handle (Wnck.Handle) – a Wnck.Handle

Returns:

a newly created Wnck.Pager.

Return type:

Gtk.Widget

Creates a new Wnck.Pager. The Wnck.Pager will show the Wnck.Workspace of the Wnck.Screen it is on.

get_wrap_on_scroll()
Returns:

True if the self wraps workspaces on a scroll event that hits a border, False otherwise.

Return type:

bool

New in version 3.24.0.

set_display_mode(mode)
Parameters:

mode (Wnck.PagerDisplayMode) – a display mode.

Sets the display mode for self to mode.

set_n_rows(n_rows)
Parameters:

n_rows (int) – the number of rows to use for the layout of Wnck.Workspace on the Wnck.Screen self is watching.

Returns:

True if the layout of Wnck.Workspace has been successfully changed or did not need to be changed, False otherwise.

Return type:

bool

Tries to change the number of rows in the layout of Wnck.Workspace on the Wnck.Screen self is watching. Since no more than one application should set this property of a Wnck.Screen at a time, setting the layout is not guaranteed to work.

If self has not been added to a widget hierarchy, the call will fail because self can’t know the screen on which to modify the layout.

set_orientation(orientation)
Parameters:

orientation (Gtk.Orientation) – orientation to use for the layout of Wnck.Workspace on the Wnck.Screen self is watching.

Returns:

True if the layout of Wnck.Workspace has been successfully changed or did not need to be changed, False otherwise.

Return type:

bool

Tries to change the orientation of the layout of Wnck.Workspace on the Wnck.Screen self is watching. Since no more than one application should set this property of a Wnck.Screen at a time, setting the layout is not guaranteed to work.

If orientation is Gtk.Orientation.HORIZONTAL, the Wnck.Workspace will be laid out in rows, with the first Wnck.Workspace in the top left corner.

If orientation is Gtk.Orientation.VERTICAL, the Wnck.Workspace will be laid out in columns, with the first Wnck.Workspace in the top left corner.

For example, if the layout contains one row, but the orientation of the layout is vertical, the Wnck.Pager will display a column of Wnck.Workspace.

Note that setting the orientation will have an effect on the geometry management: if orientation is Gtk.Orientation.HORIZONTAL, Gtk.SizeRequestMode.WIDTH_FOR_HEIGHT will be used as request mode; if orientation is Gtk.Orientation.VERTICAL, Gtk.SizeRequestMode.HEIGHT_FOR_WIDTH will be used instead.

If self has not been added to a widget hierarchy, the call will fail because self can’t know the screen on which to modify the orientation.

set_scroll_mode(scroll_mode)
Parameters:

scroll_mode (Wnck.PagerScrollMode) – a scroll mode.

Sets self to react to input device scrolling in one of the available scroll modes.

New in version 3.36.

set_shadow_type(shadow_type)
Parameters:

shadow_type (Gtk.ShadowType) – a shadow type.

Sets the shadow type for self to shadow_type. The main use of this function is proper integration of Wnck.Pager in panels with non-system backgrounds.

New in version 2.2.

set_show_all(show_all_workspaces)
Parameters:

show_all_workspaces (bool) – whether to display all Wnck.Workspace in self.

Sets self to display all Wnck.Workspace or not, according to show_all_workspaces.

set_wrap_on_scroll(wrap_on_scroll)
Parameters:

wrap_on_scroll (bool) – a boolean.

Sets the wrapping behavior of the self. Setting it to True will wrap arround to the start when scrolling over the end and vice versa. By default it is set to False.

New in version 3.24.0.

Property Details

Wnck.Pager.props.handle
Name:

handle

Type:

Wnck.Handle

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY, EXPLICIT_NOTIFY

handle