KDE plasma window management

Application windows management

This interface manages application windows. It provides requests to show and hide the desktop and emits an event every time a window is created so that the client can use it to manage the window.

Only one client can bind this interface at a time.

show_desktop(state: uint)
Argument
Type
Description
stateuint
requested state
Show/hide the desktop

Tell the compositor to show/hide the desktop.

get_window(id: new_id<org_kde_plasma_window>, internal_window_id: uint)
Argument
Type
Description
idnew_id<org_kde_plasma_window>
internal_window_iduint
The internal window id of the window to create
Deprecated

Deprecated: use get_window_by_uuid

get_window_by_uuid(id: new_id<org_kde_plasma_window>, internal_window_uuid: string)
Argument
Type
Description
idnew_id<org_kde_plasma_window>
internal_window_uuidstring
The internal window uuiid of the window to create
show_desktop_changed(state: uint)
Argument
Type
Description
stateuint
new state
Notify the client when the show desktop mode is entered/left

This event will be sent whenever the show desktop mode changes. E.g. when it is entered or left.

On binding the interface the current state is sent.

window(id: uint)
Argument
Type
Description
iduint
Deprecated: internal window Id
Notify the client that a window was mapped

This event will be sent immediately after a window is mapped.

stacking_order_changed(ids: array)
Argument
Type
Description
idsarray
internal windows id array
Notify the client when stacking order changed

This event will be sent when stacking order changed and on bind

stacking_order_uuid_changed(uuids: string)
Argument
Type
Description
uuidsstring
internal windows id ;-separated
Notify the client when stacking order changed

This event will be sent when stacking order changed and on bind

window_with_uuid(id: uint, uuid: string)
Argument
Type
Description
iduint
Deprecated: internal window Id
uuidstring
internal window uuid
Notify the client that a window was mapped

This event will be sent immediately after a window is mapped.

Argument
Value
Description
active1 &lt;&lt; 0
minimized1 &lt;&lt; 1
maximized1 &lt;&lt; 2
fullscreen1 &lt;&lt; 3
keep_above1 &lt;&lt; 4
keep_below1 &lt;&lt; 5
on_all_desktops1 &lt;&lt; 6
demands_attention1 &lt;&lt; 7
closeable1 &lt;&lt; 8
minimizable1 &lt;&lt; 9
maximizable1 &lt;&lt; 10
fullscreenable1 &lt;&lt; 11
skiptaskbarsince 21 &lt;&lt; 12
shadeablesince 31 &lt;&lt; 13
shadedsince 31 &lt;&lt; 14
movablesince 31 &lt;&lt; 15
resizablesince 31 &lt;&lt; 16
virtual_desktop_changeablesince 31 &lt;&lt; 17
skipswitchersince 91 &lt;&lt; 18

Interface to control application windows

Manages and control an application window.

Only one client can bind this interface at a time.

set_state(flags: uint, state: uint)
Argument
Type
Description
flagsuint
bitfield of set state flags
stateuint
bitfield of state flags
Set window state

Set window state.

Values for state argument are described by org_kde_plasma_window_management.state and can be used together in a bitfield. The flags bitfield describes which flags are supposed to be set, the state bitfield the value for the set flags

set_virtual_desktop(number: uint)
Argument
Type
Description
numberuint
zero based virtual desktop number
Map window on a virtual desktop

Deprecated: use enter_virtual_desktop Maps the window to a different virtual desktop.

To show the window on all virtual desktops, call the org_kde_plasma_window.set_state request and specify a on_all_desktops state in the bitfield.

set_minimized_geometry(panel: object<wl_surface>, x: uint, y: uint, width: uint, height: uint)
Argument
Type
Description
panelobject<wl_surface>
xuint
yuint
widthuint
heightuint
Set the geometry for a taskbar entry

Sets the geometry of the taskbar entry for this window. The geometry is relative to a panel in particular.

unset_minimized_geometry(panel: object<wl_surface>)
Argument
Type
Description
panelobject<wl_surface>
Set the geometry for a taskbar entry

Remove the task geometry information for a particular panel.

close()
Close window

Close this window.

request_move()
Request move

Request an interactive move for this window.

request_resize()
Request resize

Request an interactive resize for this window.

destroy
Type: destructorsince 4
destroy()
Remove resource for the org_kde_plasma_window

Removes the resource bound for this org_kde_plasma_window.

get_icon(fd: fd)
Argument
Type
Description
fdfd
file descriptor for the icon
Requests to get the window icon

The compositor will write the window icon into the provided file descriptor. The data is a serialized QIcon with QDataStream.

request_enter_virtual_desktop(id: string)
Argument
Type
Description
idstring
desktop id
Map window on a virtual desktop

Make the window enter a virtual desktop. A window can enter more than one virtual desktop. if the id is empty or invalid, no action will be performed.

request_enter_new_virtual_desktop()
Map window on a virtual desktop

RFC: do this with an empty id to request_enter_virtual_desktop? Make the window enter a new virtual desktop. If the server consents the request, it will create a new virtual desktop and assign the window to it.

request_leave_virtual_desktop(id: string)
Argument
Type
Description
idstring
desktop id
Remove a window from a virtual desktop

Make the window exit a virtual desktop. If it exits all desktops it will be considered on all of them.

request_enter_activity(id: string)
Argument
Type
Description
idstring
activity id
Map window on an activity

Make the window enter an activity. A window can enter more activity. If the id is empty or invalid, no action will be performed.

request_leave_activity(id: string)
Argument
Type
Description
idstring
activity id
Remove a window from an activity

Make the window exit a an activity. If it exits all activities it will be considered on all of them.

title_changed(title: string)
Argument
Type
Description
titlestring
window title
Window title has been changed

This event will be sent as soon as the window title is changed.

app_id_changed(app_id: string)
Argument
Type
Description
app_idstring
Application identifier has been changed

This event will be sent as soon as the application identifier is changed.

state_changed(flags: uint)
Argument
Type
Description
flagsuint
bitfield of state flags
Window state has been changed

This event will be sent as soon as the window state changes.

Values for state argument are described by org_kde_plasma_window_management.state.

virtual_desktop_changed(number: int)
Argument
Type
Description
numberint
zero based virtual desktop number
Window was moved to another workspace

DEPRECATED: use virtual_desktop_entered and virtual_desktop_left instead This event will be sent when a window is moved to another virtual desktop.

It is not sent if it becomes visible on all virtual desktops though.

themed_icon_name_changed(name: string)
Argument
Type
Description
namestring
the new themed icon name
Window's icon name changed

This event will be sent whenever the themed icon name changes. May be null.

unmapped()
Window's surface was unmapped

This event will be sent immediately after the window is closed and its surface is unmapped.

initial_state()
All initial known state is submitted

This event will be sent immediately after all initial state been sent to the client. If the Plasma window is already unmapped, the unmapped event will be sent before the initial_state event.

parent_window(parent: object<org_kde_plasma_window>)
Argument
Type
Description
parentobject<org_kde_plasma_window>allow null
The parent window
The parent window changed

This event will be sent whenever the parent window of this org_kde_plasma_window changes. The passed parent is another org_kde_plasma_window and this org_kde_plasma_window is a transient window to the parent window. If the parent argument is null, this org_kde_plasma_window does not have a parent window.

geometry(x: int, y: int, width: uint, height: uint)
Argument
Type
Description
xint
x position of the org_kde_plasma_window
yint
y position of the org_kde_plasma_window
widthuint
width of the org_kde_plasma_window
heightuint
height of the org_kde_plasma_window
The geometry of this window in absolute coordinates

This event will be sent whenever the window geometry of this org_kde_plasma_window changes. The coordinates are in absolute coordinates of the windowing system.

icon_changed()
The icon of the window changed

This event will be sent whenever the icon of the window changes, but there is no themed icon name. Common examples are Xwayland windows which have a pixmap based icon.

The client can request the icon using get_icon.

pid_changed(pid: uint)
Argument
Type
Description
piduint
process id
Process id of application owning the window has changed

This event will be sent when the compositor has set the process id this window belongs to. This should be set once before the initial_state is sent.

virtual_desktop_entered(id: string)
Argument
Type
Description
idstring
desktop id
The window entered a new virtual desktop

This event will be sent when the window has entered a new virtual desktop. The window can be on more than one desktop, or none: then is considered on all of them.

virtual_desktop_left(is: string)
Argument
Type
Description
isstring
desktop id
The window left a virtual desktop

This event will be sent when the window left a virtual desktop. If the window leaves all desktops, it can be considered on all. If the window gets manually added on all desktops, the server has to send virtual_desktop_left for every previous desktop it was in for the window to be really considered on all desktops.

application_menu(service_name: string, object_path: string)
Argument
Type
Description
service_namestring
object_pathstring
Notify the client that the current appmenu changed

This event will be sent after the application menu for the window has changed.

activity_entered(id: string)
Argument
Type
Description
idstring
activity id
The window entered an activity

This event will be sent when the window has entered an activity. The window can be on more than one activity, or none: then is considered on all of them.

activity_left(id: string)
Argument
Type
Description
idstring
activity id
The window left an activity

This event will be sent when the window left an activity. If the window leaves all activities, it will be considered on all. If the window gets manually added on all activities, the server has to send activity_left for every previous activity it was in for the window to be really considered on all activities.


SPDX-FileCopyrightText: 2013-2014 Pier Luigi Fiorini

SPDX-License-Identifier: LGPL-2.1-or-later