Gdk.Seat

g GObject.Object GObject.Object Gdk.Seat Gdk.Seat GObject.Object->Gdk.Seat

Subclasses:

None

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

get_capabilities ()

get_devices (capabilities)

get_display ()

get_keyboard ()

get_pointer ()

get_tools ()

Virtual Methods

Inherited:

GObject.Object (7)

Properties

Name

Type

Flags

Short Description

display

Gdk.Display

r/w/co

Signals

Inherited:

GObject.Object (1)

Name

Short Description

device-added

Emitted when a new input device is related to this seat.

device-removed

Emitted when an input device is removed (e.g.

tool-added

Emitted whenever a new tool is made known to the seat.

tool-removed

Emitted whenever a tool is no longer known to this seat.

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent_instance

GObject.Object

r

Class Details

class Gdk.Seat(**kwargs)
Bases:

GObject.Object

Abstract:

Yes

The GdkSeat object represents a collection of input devices that belong to a user.

get_capabilities()[source]
Returns:

the seat capabilities

Return type:

Gdk.SeatCapabilities

Returns the capabilities this GdkSeat currently has.

get_devices(capabilities)[source]
Parameters:

capabilities (Gdk.SeatCapabilities) – capabilities to get devices for

Returns:

A list of GdkDevices. The list must be freed with g_list_free(), the elements are owned by GTK and must not be freed.

Return type:

[Gdk.Device]

Returns the devices that match the given capabilities.

get_display()[source]
Returns:

a GdkDisplay. This object is owned by GTK and must not be freed.

Return type:

Gdk.Display

Returns the GdkDisplay this seat belongs to.

get_keyboard()[source]
Returns:

a GdkDevice with keyboard capabilities. This object is owned by GTK and must not be freed.

Return type:

Gdk.Device or None

Returns the device that routes keyboard events.

get_pointer()[source]
Returns:

a GdkDevice with pointer capabilities. This object is owned by GTK and must not be freed.

Return type:

Gdk.Device or None

Returns the device that routes pointer events.

get_tools()[source]
Returns:

A list of tools. Free with g_list_free().

Return type:

[Gdk.DeviceTool]

Returns all GdkDeviceTools that are known to the application.

Signal Details

Gdk.Seat.signals.device_added(seat, device)
Signal Name:

device-added

Flags:

RUN_LAST

Parameters:
  • seat (Gdk.Seat) – The object which received the signal

  • device (Gdk.Device) – the newly added GdkDevice.

Emitted when a new input device is related to this seat.

Gdk.Seat.signals.device_removed(seat, device)
Signal Name:

device-removed

Flags:

RUN_LAST

Parameters:
  • seat (Gdk.Seat) – The object which received the signal

  • device (Gdk.Device) – the just removed GdkDevice.

Emitted when an input device is removed (e.g. unplugged).

Gdk.Seat.signals.tool_added(seat, tool)
Signal Name:

tool-added

Flags:

RUN_LAST

Parameters:
  • seat (Gdk.Seat) – The object which received the signal

  • tool (Gdk.DeviceTool) – the new GdkDeviceTool known to the seat

Emitted whenever a new tool is made known to the seat.

The tool may later be assigned to a device (i.e. on proximity with a tablet). The device will emit the [signal`Gdk`.Device::tool-changed] signal accordingly.

A same tool may be used by several devices.

Gdk.Seat.signals.tool_removed(seat, tool)
Signal Name:

tool-removed

Flags:

RUN_LAST

Parameters:
  • seat (Gdk.Seat) – The object which received the signal

  • tool (Gdk.DeviceTool) – the just removed GdkDeviceTool

Emitted whenever a tool is no longer known to this seat.

Property Details

Gdk.Seat.props.display
Name:

display

Type:

Gdk.Display

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

GdkDisplay of this seat.