--- /srv/reproducible-results/rbuild-debian/r-b-build.TGgUitIc/b1/pywayland_0.4.18-1_amd64.changes +++ /srv/reproducible-results/rbuild-debian/r-b-build.TGgUitIc/b2/pywayland_0.4.18-1_amd64.changes ├── Files │ @@ -1,4 +1,4 @@ │ │ 2eae7c678b9d2734648c45465ca534b3 47416 debug optional python3-pywayland-dbgsym_0.4.18-1_amd64.deb │ - a6b3ee4e3bc004c987b08cbf0f9776ad 51368 doc optional python3-pywayland-doc_0.4.18-1_all.deb │ - 35a0f8384ddebb3268c9c3cc334a9d66 120232 python optional python3-pywayland_0.4.18-1_amd64.deb │ + 9fe901e9a499a39416410bbedbc6ba68 51624 doc optional python3-pywayland-doc_0.4.18-1_all.deb │ + 7630e99045d069a6689f25fd92688b5e 120652 python optional python3-pywayland_0.4.18-1_amd64.deb ├── python3-pywayland-doc_0.4.18-1_all.deb │ ├── file list │ │ @@ -1,3 +1,3 @@ │ │ -rw-r--r-- 0 0 0 4 2024-10-11 20:38:19.000000 debian-binary │ │ -rw-r--r-- 0 0 0 1304 2024-10-11 20:38:19.000000 control.tar.xz │ │ --rw-r--r-- 0 0 0 49872 2024-10-11 20:38:19.000000 data.tar.xz │ │ +-rw-r--r-- 0 0 0 50128 2024-10-11 20:38:19.000000 data.tar.xz │ ├── control.tar.xz │ │ ├── control.tar │ │ │ ├── ./md5sums │ │ │ │ ├── ./md5sums │ │ │ │ │┄ Files differ │ ├── data.tar.xz │ │ ├── data.tar │ │ │ ├── file list │ │ │ │ @@ -12,15 +12,15 @@ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 1092 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/index.txt │ │ │ │ -rw-r--r-- 0 root (0) root (0) 1693 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/install.txt.gz │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 2629 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/client.txt.gz │ │ │ │ -rw-r--r-- 0 root (0) root (0) 515 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/index.txt │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/protocol/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 482 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/protocol/index.txt │ │ │ │ --rw-r--r-- 0 root (0) root (0) 29986 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/protocol/wayland.txt.gz │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 30273 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/protocol/wayland.txt.gz │ │ │ │ -rw-r--r-- 0 root (0) root (0) 1839 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/protocol_core.txt.gz │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/scanner/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 1018 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/scanner/argument.txt │ │ │ │ -rw-r--r-- 0 root (0) root (0) 405 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/scanner/entry.txt │ │ │ │ -rw-r--r-- 0 root (0) root (0) 358 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/scanner/enum.txt │ │ │ │ -rw-r--r-- 0 root (0) root (0) 688 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/scanner/event.txt │ │ │ │ -rw-r--r-- 0 root (0) root (0) 296 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/scanner/index.txt │ │ │ ├── ./usr/share/doc/python3-pywayland/text/module/protocol/index.txt │ │ │ │┄ Ordering differences only │ │ │ │ @@ -2,50 +2,50 @@ │ │ │ │ **************** │ │ │ │ │ │ │ │ Wayland protocols built against Wayland 1.21.0 and Wayland Protocols │ │ │ │ 1.25. │ │ │ │ │ │ │ │ * wayland Module │ │ │ │ │ │ │ │ - * WlCallback │ │ │ │ + * WlDataDevice │ │ │ │ │ │ │ │ - * WlDataDeviceManager │ │ │ │ + * WlTouch │ │ │ │ + │ │ │ │ + * WlRegistry │ │ │ │ │ │ │ │ * WlSubcompositor │ │ │ │ │ │ │ │ + * WlShm │ │ │ │ + │ │ │ │ * WlShmPool │ │ │ │ │ │ │ │ * WlSurface │ │ │ │ │ │ │ │ - * WlRegion │ │ │ │ + * WlOutput │ │ │ │ │ │ │ │ - * WlDataSource │ │ │ │ + * WlKeyboard │ │ │ │ + │ │ │ │ + * WlCompositor │ │ │ │ + │ │ │ │ + * WlSeat │ │ │ │ │ │ │ │ * WlDataOffer │ │ │ │ │ │ │ │ - * WlShellSurface │ │ │ │ + * WlBuffer │ │ │ │ │ │ │ │ - * WlSubsurface │ │ │ │ + * WlDataSource │ │ │ │ │ │ │ │ - * WlShm │ │ │ │ + * WlCallback │ │ │ │ │ │ │ │ - * WlKeyboard │ │ │ │ + * WlRegion │ │ │ │ │ │ │ │ - * WlTouch │ │ │ │ + * WlDataDeviceManager │ │ │ │ │ │ │ │ - * WlDataDevice │ │ │ │ + * WlShellSurface │ │ │ │ │ │ │ │ - * WlPointer │ │ │ │ + * WlSubsurface │ │ │ │ │ │ │ │ - * WlCompositor │ │ │ │ + * WlPointer │ │ │ │ │ │ │ │ * WlShell │ │ │ │ │ │ │ │ * WlDisplay │ │ │ │ - │ │ │ │ - * WlOutput │ │ │ │ - │ │ │ │ - * WlBuffer │ │ │ │ - │ │ │ │ - * WlSeat │ │ │ │ - │ │ │ │ - * WlRegistry │ │ │ ├── ./usr/share/doc/python3-pywayland/text/module/protocol/wayland.txt.gz │ │ │ │ ├── wayland.txt │ │ │ │ │┄ Ordering differences only │ │ │ │ │ @@ -1,80 +1,506 @@ │ │ │ │ │ wayland Module │ │ │ │ │ ************** │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -WlCallback │ │ │ │ │ -========== │ │ │ │ │ +WlDataDevice │ │ │ │ │ +============ │ │ │ │ │ │ │ │ │ │ -class pywayland.protocol.wayland.WlCallback │ │ │ │ │ +class pywayland.protocol.wayland.WlDataDevice │ │ │ │ │ │ │ │ │ │ - Callback object │ │ │ │ │ + Data transfer device │ │ │ │ │ │ │ │ │ │ - Clients can handle the 'done' event to get notified when the │ │ │ │ │ - related request is done. │ │ │ │ │ + There is one "WlDataDevice" per seat which can be obtained from the │ │ │ │ │ + global "WlDataDeviceManager" singleton. │ │ │ │ │ │ │ │ │ │ - Note, because "WlCallback" objects are created from multiple │ │ │ │ │ - independent factory interfaces, the "WlCallback" interface is │ │ │ │ │ - frozen at version 1. │ │ │ │ │ + A "WlDataDevice" provides access to inter-client data transfer │ │ │ │ │ + mechanisms such as copy-and-paste and drag-and-drop. │ │ │ │ │ │ │ │ │ │ - done(callback_data: 'int') -> 'None' │ │ │ │ │ + start_drag(source: 'WlDataSource | None', origin: 'WlSurface', icon: 'WlSurface | None', serial: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Start drag-and-drop operation │ │ │ │ │ + │ │ │ │ │ + This request asks the compositor to start a drag-and-drop │ │ │ │ │ + operation on behalf of the client. │ │ │ │ │ + │ │ │ │ │ + The source argument is the data source that provides the data │ │ │ │ │ + for the eventual data transfer. If source is NULL, enter, leave │ │ │ │ │ + and motion events are sent only to the client that initiated the │ │ │ │ │ + drag and the client is expected to handle the data passing │ │ │ │ │ + internally. If source is destroyed, the drag-and-drop session │ │ │ │ │ + will be cancelled. │ │ │ │ │ + │ │ │ │ │ + The origin surface is the surface where the drag originates and │ │ │ │ │ + the client must have an active implicit grab that matches the │ │ │ │ │ + serial. │ │ │ │ │ + │ │ │ │ │ + The icon surface is an optional (can be NULL) surface that │ │ │ │ │ + provides an icon to be moved around with the cursor. Initially, │ │ │ │ │ + the top-left corner of the icon surface is placed at the cursor │ │ │ │ │ + hotspot, but subsequent "WlSurface.offset()" requests can move │ │ │ │ │ + the relative position. Attach requests must be confirmed with │ │ │ │ │ + "WlSurface.commit()" as usual. The icon surface is given the │ │ │ │ │ + role of a drag-and-drop icon. If the icon surface already has │ │ │ │ │ + another role, it raises a protocol error. │ │ │ │ │ + │ │ │ │ │ + The input region is ignored for wl_surfaces with the role of a │ │ │ │ │ + drag- and-drop icon. │ │ │ │ │ + │ │ │ │ │ + The given source may not be used in any further set_selection or │ │ │ │ │ + start_drag requests. Attempting to reuse a previously-used │ │ │ │ │ + source may send a used_source error. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **source** ("WlDataSource" or *None*) -- data source for │ │ │ │ │ + the eventual transfer │ │ │ │ │ + │ │ │ │ │ + * **origin** ("WlSurface") -- surface where the drag │ │ │ │ │ + originates │ │ │ │ │ + │ │ │ │ │ + * **icon** ("WlSurface" or *None*) -- drag-and-drop icon │ │ │ │ │ + surface │ │ │ │ │ + │ │ │ │ │ + * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ + implicit grab on the origin │ │ │ │ │ + │ │ │ │ │ + set_selection(source: 'WlDataSource | None', serial: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Copy data to the selection │ │ │ │ │ + │ │ │ │ │ + This request asks the compositor to set the selection to the │ │ │ │ │ + data from the source on behalf of the client. │ │ │ │ │ + │ │ │ │ │ + To unset the selection, set the source to NULL. │ │ │ │ │ + │ │ │ │ │ + The given source may not be used in any further set_selection or │ │ │ │ │ + start_drag requests. Attempting to reuse a previously-used │ │ │ │ │ + source may send a used_source error. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **source** ("WlDataSource" or *None*) -- data source for │ │ │ │ │ + the selection │ │ │ │ │ + │ │ │ │ │ + * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ + event that triggered this request │ │ │ │ │ + │ │ │ │ │ + release() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 2 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Destroy data device │ │ │ │ │ + │ │ │ │ │ + This request destroys the data device. │ │ │ │ │ + │ │ │ │ │ + data_offer(id: 'WlDataOffer') -> 'None' │ │ │ │ │ │ │ │ │ │ -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - Done event │ │ │ │ │ + Introduce a new "WlDataOffer" │ │ │ │ │ │ │ │ │ │ - Notify the client when the related request is done. │ │ │ │ │ + The data_offer event introduces a new "WlDataOffer" object, │ │ │ │ │ + which will subsequently be used in either the data_device.enter │ │ │ │ │ + event (for drag- and-drop) or the data_device.selection event │ │ │ │ │ + (for selections). Immediately following the │ │ │ │ │ + data_device.data_offer event, the new data_offer object will │ │ │ │ │ + send out data_offer.offer events to describe the mime types it │ │ │ │ │ + offers. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ - **callback_data** (*ArgumentType.Uint*) -- request-specific │ │ │ │ │ - data for the callback │ │ │ │ │ + **id** ("WlDataOffer") -- the new data_offer object │ │ │ │ │ │ │ │ │ │ + enter(serial: 'int', surface: 'WlSurface', x: 'float', y: 'float', id: 'WlDataOffer | None') -> 'None' │ │ │ │ │ │ │ │ │ │ -WlDataDeviceManager │ │ │ │ │ -=================== │ │ │ │ │ + -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ -class pywayland.protocol.wayland.WlDataDeviceManager │ │ │ │ │ + Initiate drag-and-drop session │ │ │ │ │ │ │ │ │ │ - Data transfer interface │ │ │ │ │ + This event is sent when an active drag-and-drop pointer enters a │ │ │ │ │ + surface owned by the client. The position of the pointer at │ │ │ │ │ + enter time is provided by the x and y arguments, in surface- │ │ │ │ │ + local coordinates. │ │ │ │ │ │ │ │ │ │ - The "WlDataDeviceManager" is a singleton global object that │ │ │ │ │ - provides access to inter-client data transfer mechanisms such as │ │ │ │ │ - copy-and-paste and drag-and-drop. These mechanisms are tied to a │ │ │ │ │ - "WlSeat" and this interface lets a client get a "WlDataDevice" │ │ │ │ │ - corresponding to a "WlSeat". │ │ │ │ │ + Parameters: │ │ │ │ │ + * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ + enter event │ │ │ │ │ │ │ │ │ │ - Depending on the version bound, the objects created from the bound │ │ │ │ │ - "WlDataDeviceManager" object will have different requirements for │ │ │ │ │ - functioning properly. See "WlDataSource.set_actions()", │ │ │ │ │ - "WlDataOffer.accept()" and "WlDataOffer.finish()" for details. │ │ │ │ │ + * **surface** ("WlSurface") -- client surface entered │ │ │ │ │ │ │ │ │ │ - create_data_source() -> 'Proxy[WlDataSource]' │ │ │ │ │ + * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate │ │ │ │ │ + │ │ │ │ │ + * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate │ │ │ │ │ + │ │ │ │ │ + * **id** ("WlDataOffer" or *None*) -- source data_offer │ │ │ │ │ + object │ │ │ │ │ + │ │ │ │ │ + leave() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 2 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + End drag-and-drop session │ │ │ │ │ + │ │ │ │ │ + This event is sent when the drag-and-drop pointer leaves the │ │ │ │ │ + surface and the session ends. The client must destroy the │ │ │ │ │ + "WlDataOffer" introduced at enter time at this point. │ │ │ │ │ + │ │ │ │ │ + motion(time: 'int', x: 'float', y: 'float') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Drag-and-drop session motion │ │ │ │ │ + │ │ │ │ │ + This event is sent when the drag-and-drop pointer moves within │ │ │ │ │ + the currently focused surface. The new position of the pointer │ │ │ │ │ + is provided by the x and y arguments, in surface-local │ │ │ │ │ + coordinates. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ + millisecond granularity │ │ │ │ │ + │ │ │ │ │ + * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate │ │ │ │ │ + │ │ │ │ │ + * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate │ │ │ │ │ + │ │ │ │ │ + drop() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 4 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + End drag-and-drop session successfully │ │ │ │ │ + │ │ │ │ │ + The event is sent when a drag-and-drop operation is ended │ │ │ │ │ + because the implicit grab is removed. │ │ │ │ │ + │ │ │ │ │ + The drag-and-drop destination is expected to honor the last │ │ │ │ │ + action received through "WlDataOffer.action()", if the resulting │ │ │ │ │ + action is "copy" or "move", the destination can still perform │ │ │ │ │ + "WlDataOffer.receive()" requests, and is expected to end all │ │ │ │ │ + transfers with a "WlDataOffer.finish()" request. │ │ │ │ │ + │ │ │ │ │ + If the resulting action is "ask", the action will not be │ │ │ │ │ + considered final. The drag-and-drop destination is expected to │ │ │ │ │ + perform one last "WlDataOffer.set_actions()" request, or │ │ │ │ │ + "WlDataOffer.destroy()" in order to cancel the operation. │ │ │ │ │ + │ │ │ │ │ + selection(id: 'WlDataOffer | None') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 5 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Advertise new selection │ │ │ │ │ + │ │ │ │ │ + The selection event is sent out to notify the client of a new │ │ │ │ │ + "WlDataOffer" for the selection for this device. The │ │ │ │ │ + data_device.data_offer and the data_offer.offer events are sent │ │ │ │ │ + out immediately before this event to introduce the data offer │ │ │ │ │ + object. The selection event is sent to a client immediately │ │ │ │ │ + before receiving keyboard focus and when a new selection is set │ │ │ │ │ + while the client has keyboard focus. The data_offer is valid │ │ │ │ │ + until a new data_offer or NULL is received or until the client │ │ │ │ │ + loses keyboard focus. Switching surface with keyboard focus │ │ │ │ │ + within the same client doesn't mean a new selection will be │ │ │ │ │ + sent. The client must destroy the previous selection │ │ │ │ │ + data_offer, if any, upon receiving this event. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **id** ("WlDataOffer" or *None*) -- selection data_offer │ │ │ │ │ + object │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ +WlTouch │ │ │ │ │ +======= │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlTouch │ │ │ │ │ + │ │ │ │ │ + Touchscreen input device │ │ │ │ │ + │ │ │ │ │ + The "WlTouch" interface represents a touchscreen associated with a │ │ │ │ │ + seat. │ │ │ │ │ + │ │ │ │ │ + Touch interactions can consist of one or more contacts. For each │ │ │ │ │ + contact, a series of events is generated, starting with a down │ │ │ │ │ + event, followed by zero or more motion events, and ending with an │ │ │ │ │ + up event. Events relating to the same contact point can be │ │ │ │ │ + identified by the ID of the sequence. │ │ │ │ │ + │ │ │ │ │ + release() -> 'None' │ │ │ │ │ │ │ │ │ │ -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ │ │ │ │ │ - Create a new data source │ │ │ │ │ + Release the touch object │ │ │ │ │ │ │ │ │ │ - Create a new data source. │ │ │ │ │ + down(serial: 'int', time: 'int', surface: 'WlSurface', id: 'int', x: 'float', y: 'float') -> 'None' │ │ │ │ │ │ │ │ │ │ - Returns: │ │ │ │ │ - "WlDataSource" -- data source to create │ │ │ │ │ + -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - get_data_device(seat: 'WlSeat') -> 'Proxy[WlDataDevice]' │ │ │ │ │ + Touch down event and beginning of a touch sequence │ │ │ │ │ │ │ │ │ │ - -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + A new touch point has appeared on the surface. This touch point │ │ │ │ │ + is assigned a unique ID. Future events from this touch point │ │ │ │ │ + reference this ID. The ID ceases to be valid after a touch up │ │ │ │ │ + event and may be reused in the future. │ │ │ │ │ │ │ │ │ │ - Create a new data device │ │ │ │ │ + Parameters: │ │ │ │ │ + * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ + touch down event │ │ │ │ │ │ │ │ │ │ - Create a new data device for a given seat. │ │ │ │ │ + * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ + millisecond granularity │ │ │ │ │ + │ │ │ │ │ + * **surface** ("WlSurface") -- surface touched │ │ │ │ │ + │ │ │ │ │ + * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ + point │ │ │ │ │ + │ │ │ │ │ + * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate │ │ │ │ │ + │ │ │ │ │ + * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate │ │ │ │ │ + │ │ │ │ │ + up(serial: 'int', time: 'int', id: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + End of a touch event sequence │ │ │ │ │ + │ │ │ │ │ + The touch point has disappeared. No further events will be sent │ │ │ │ │ + for this touch point and the touch point's ID is released and │ │ │ │ │ + may be reused in a future touch down event. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ - **seat** ("WlSeat") -- seat associated with the data device │ │ │ │ │ + * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ + touch up event │ │ │ │ │ + │ │ │ │ │ + * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ + millisecond granularity │ │ │ │ │ + │ │ │ │ │ + * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ + point │ │ │ │ │ + │ │ │ │ │ + motion(time: 'int', id: 'int', x: 'float', y: 'float') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 2 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Update of touch point coordinates │ │ │ │ │ + │ │ │ │ │ + A touch point has changed coordinates. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ + millisecond granularity │ │ │ │ │ + │ │ │ │ │ + * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ + point │ │ │ │ │ + │ │ │ │ │ + * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate │ │ │ │ │ + │ │ │ │ │ + * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate │ │ │ │ │ + │ │ │ │ │ + frame() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + End of touch frame event │ │ │ │ │ + │ │ │ │ │ + Indicates the end of a set of events that logically belong │ │ │ │ │ + together. A client is expected to accumulate the data in all │ │ │ │ │ + events within the frame before proceeding. │ │ │ │ │ + │ │ │ │ │ + A "WlTouch.frame()" terminates at least one event but otherwise │ │ │ │ │ + no guarantee is provided about the set of events within a frame. │ │ │ │ │ + A client must assume that any state not updated in a frame is │ │ │ │ │ + unchanged from the previously known state. │ │ │ │ │ + │ │ │ │ │ + cancel() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 4 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Touch session cancelled │ │ │ │ │ + │ │ │ │ │ + Sent if the compositor decides the touch stream is a global │ │ │ │ │ + gesture. No further events are sent to the clients from that │ │ │ │ │ + particular gesture. Touch cancellation applies to all touch │ │ │ │ │ + points currently active on this client's surface. The client is │ │ │ │ │ + responsible for finalizing the touch points, future touch points │ │ │ │ │ + on this surface may reuse the touch point ID. │ │ │ │ │ + │ │ │ │ │ + No frame event is required after the cancel event. │ │ │ │ │ + │ │ │ │ │ + shape(id: 'int', major: 'float', minor: 'float') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 5 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Update shape of touch point │ │ │ │ │ + │ │ │ │ │ + Sent when a touchpoint has changed its shape. │ │ │ │ │ + │ │ │ │ │ + This event does not occur on its own. It is sent before a │ │ │ │ │ + "WlTouch.frame()" event and carries the new shape information │ │ │ │ │ + for any previously reported, or new touch points of that frame. │ │ │ │ │ + │ │ │ │ │ + Other events describing the touch point such as │ │ │ │ │ + "WlTouch.down()", "WlTouch.motion()" or "WlTouch.orientation()" │ │ │ │ │ + may be sent within the same "WlTouch.frame()". A client should │ │ │ │ │ + treat these events as a single logical touch point update. The │ │ │ │ │ + order of "WlTouch.shape()", "WlTouch.orientation()" and │ │ │ │ │ + "WlTouch.motion()" is not guaranteed. A "WlTouch.down()" event │ │ │ │ │ + is guaranteed to occur before the first "WlTouch.shape()" event │ │ │ │ │ + for this touch ID but both events may occur within the same │ │ │ │ │ + "WlTouch.frame()". │ │ │ │ │ + │ │ │ │ │ + A touchpoint shape is approximated by an ellipse through the │ │ │ │ │ + major and minor axis length. The major axis length describes the │ │ │ │ │ + longer diameter of the ellipse, while the minor axis length │ │ │ │ │ + describes the shorter diameter. Major and minor are orthogonal │ │ │ │ │ + and both are specified in surface-local coordinates. The center │ │ │ │ │ + of the ellipse is always at the touchpoint location as reported │ │ │ │ │ + by "WlTouch.down()" or "WlTouch.move()". │ │ │ │ │ + │ │ │ │ │ + This event is only sent by the compositor if the touch device │ │ │ │ │ + supports shape reports. The client has to make reasonable │ │ │ │ │ + assumptions about the shape if it did not receive this event. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ + point │ │ │ │ │ + │ │ │ │ │ + * **major** (*ArgumentType.Fixed*) -- length of the major │ │ │ │ │ + axis in surface-local coordinates │ │ │ │ │ + │ │ │ │ │ + * **minor** (*ArgumentType.Fixed*) -- length of the minor │ │ │ │ │ + axis in surface-local coordinates │ │ │ │ │ + │ │ │ │ │ + orientation(id: 'int', orientation: 'float') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 6 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Update orientation of touch point │ │ │ │ │ + │ │ │ │ │ + Sent when a touchpoint has changed its orientation. │ │ │ │ │ + │ │ │ │ │ + This event does not occur on its own. It is sent before a │ │ │ │ │ + "WlTouch.frame()" event and carries the new shape information │ │ │ │ │ + for any previously reported, or new touch points of that frame. │ │ │ │ │ + │ │ │ │ │ + Other events describing the touch point such as │ │ │ │ │ + "WlTouch.down()", "WlTouch.motion()" or "WlTouch.shape()" may be │ │ │ │ │ + sent within the same "WlTouch.frame()". A client should treat │ │ │ │ │ + these events as a single logical touch point update. The order │ │ │ │ │ + of "WlTouch.shape()", "WlTouch.orientation()" and │ │ │ │ │ + "WlTouch.motion()" is not guaranteed. A "WlTouch.down()" event │ │ │ │ │ + is guaranteed to occur before the first "WlTouch.orientation()" │ │ │ │ │ + event for this touch ID but both events may occur within the │ │ │ │ │ + same "WlTouch.frame()". │ │ │ │ │ + │ │ │ │ │ + The orientation describes the clockwise angle of a touchpoint's │ │ │ │ │ + major axis to the positive surface y-axis and is normalized to │ │ │ │ │ + the -180 to +180 degree range. The granularity of orientation │ │ │ │ │ + depends on the touch device, some devices only support binary │ │ │ │ │ + rotation values between 0 and 90 degrees. │ │ │ │ │ + │ │ │ │ │ + This event is only sent by the compositor if the touch device │ │ │ │ │ + supports orientation reports. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ + point │ │ │ │ │ + │ │ │ │ │ + * **orientation** (*ArgumentType.Fixed*) -- angle between │ │ │ │ │ + major axis and positive surface y-axis in degrees │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ +WlRegistry │ │ │ │ │ +========== │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlRegistry │ │ │ │ │ + │ │ │ │ │ + Global registry object │ │ │ │ │ + │ │ │ │ │ + The singleton global registry object. The server has a number of │ │ │ │ │ + global objects that are available to all clients. These objects │ │ │ │ │ + typically represent an actual object in the server (for example, an │ │ │ │ │ + input device) or they are singleton objects that provide extension │ │ │ │ │ + functionality. │ │ │ │ │ + │ │ │ │ │ + When a client creates a registry object, the registry object will │ │ │ │ │ + emit a global event for each global currently in the registry. │ │ │ │ │ + Globals come and go as a result of device or monitor hotplugs, │ │ │ │ │ + reconfiguration or other events, and the registry will send out │ │ │ │ │ + global and global_remove events to keep the client up to date with │ │ │ │ │ + the changes. To mark the end of the initial burst of events, the │ │ │ │ │ + client can use the "WlDisplay.sync()" request immediately after │ │ │ │ │ + calling "WlDisplay.get_registry()". │ │ │ │ │ + │ │ │ │ │ + A client can bind to a global object by using the bind request. │ │ │ │ │ + This creates a client-side handle that lets the object emit events │ │ │ │ │ + to the client and lets the client invoke requests on the object. │ │ │ │ │ + │ │ │ │ │ + bind(name: 'int', interface: 'type[T]', version: 'int') -> 'Proxy[T]' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Bind an object to the display │ │ │ │ │ + │ │ │ │ │ + Binds a new, client-created object to the server using the │ │ │ │ │ + specified name as the identifier. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **name** (*ArgumentType.Uint*) -- unique numeric name of │ │ │ │ │ + the object │ │ │ │ │ + │ │ │ │ │ + * **interface** (*string*) -- Interface name │ │ │ │ │ + │ │ │ │ │ + * **version** (*int*) -- Interface version │ │ │ │ │ │ │ │ │ │ Returns: │ │ │ │ │ - "WlDataDevice" -- data device to create │ │ │ │ │ + "pywayland.client.proxy.Proxy" of specified Interface -- │ │ │ │ │ + bounded object │ │ │ │ │ + │ │ │ │ │ + global_(name: 'int', interface: 'str', version: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Announce global object │ │ │ │ │ + │ │ │ │ │ + Notify the client of global objects. │ │ │ │ │ + │ │ │ │ │ + The event notifies the client that a global object with the │ │ │ │ │ + given name is now available, and it implements the given version │ │ │ │ │ + of the given interface. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **name** (*ArgumentType.Uint*) -- numeric name of the │ │ │ │ │ + global object │ │ │ │ │ + │ │ │ │ │ + * **interface** (*ArgumentType.String*) -- interface │ │ │ │ │ + implemented by the object │ │ │ │ │ + │ │ │ │ │ + * **version** (*ArgumentType.Uint*) -- interface version │ │ │ │ │ + │ │ │ │ │ + global_remove(name: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Announce removal of global object │ │ │ │ │ + │ │ │ │ │ + Notify the client of removed global objects. │ │ │ │ │ + │ │ │ │ │ + This event notifies the client that the global identified by │ │ │ │ │ + name is no longer available. If the client bound to the global │ │ │ │ │ + using the bind request, the client should now destroy that │ │ │ │ │ + object. │ │ │ │ │ + │ │ │ │ │ + The object remains valid and requests to the object will be │ │ │ │ │ + ignored until the client destroys it, to avoid races between the │ │ │ │ │ + global going away and a client sending a request to it. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **name** (*ArgumentType.Uint*) -- numeric name of the global │ │ │ │ │ + object │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ WlSubcompositor │ │ │ │ │ =============== │ │ │ │ │ │ │ │ │ │ class pywayland.protocol.wayland.WlSubcompositor │ │ │ │ │ │ │ │ │ │ @@ -143,14 +569,75 @@ │ │ │ │ │ │ │ │ │ │ * **parent** ("WlSurface") -- the parent surface │ │ │ │ │ │ │ │ │ │ Returns: │ │ │ │ │ "WlSubsurface" -- the new sub- surface object ID │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ +WlShm │ │ │ │ │ +===== │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlShm │ │ │ │ │ + │ │ │ │ │ + Shared memory support │ │ │ │ │ + │ │ │ │ │ + A singleton global object that provides support for shared memory. │ │ │ │ │ + │ │ │ │ │ + Clients can create "WlShmPool" objects using the create_pool │ │ │ │ │ + request. │ │ │ │ │ + │ │ │ │ │ + On binding the "WlShm" object one or more format events are emitted │ │ │ │ │ + to inform clients about the valid pixel formats that can be used │ │ │ │ │ + for buffers. │ │ │ │ │ + │ │ │ │ │ + create_pool(fd: 'int', size: 'int') -> 'Proxy[WlShmPool]' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Create a shm pool │ │ │ │ │ + │ │ │ │ │ + Create a new "WlShmPool" object. │ │ │ │ │ + │ │ │ │ │ + The pool can be used to create shared memory based buffer │ │ │ │ │ + objects. The server will mmap size bytes of the passed file │ │ │ │ │ + descriptor, to use as backing memory for the pool. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **fd** (*ArgumentType.FileDescriptor*) -- file descriptor │ │ │ │ │ + for the pool │ │ │ │ │ + │ │ │ │ │ + * **size** (*ArgumentType.Int*) -- pool size, in bytes │ │ │ │ │ + │ │ │ │ │ + Returns: │ │ │ │ │ + "WlShmPool" -- pool to create │ │ │ │ │ + │ │ │ │ │ + release() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Release the shm object │ │ │ │ │ + │ │ │ │ │ + Using this request a client can tell the server that it is not │ │ │ │ │ + going to use the shm object anymore. │ │ │ │ │ + │ │ │ │ │ + Objects created via this interface remain unaffected. │ │ │ │ │ + │ │ │ │ │ + format(format: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Pixel format description │ │ │ │ │ + │ │ │ │ │ + Informs the client about a valid pixel format that can be used │ │ │ │ │ + for buffers. Known formats include argb8888 and xrgb8888. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **format** (*ArgumentType.Uint*) -- buffer pixel format │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ WlShmPool │ │ │ │ │ ========= │ │ │ │ │ │ │ │ │ │ class pywayland.protocol.wayland.WlShmPool │ │ │ │ │ │ │ │ │ │ A shared memory pool │ │ │ │ │ │ │ │ │ │ @@ -789,259 +1276,623 @@ │ │ │ │ │ using "WlSurface.set_buffer_transform()" might allow the │ │ │ │ │ compositor to use the surface buffer more efficiently. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ **transform** (*ArgumentType.Uint*) -- preferred transform │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -WlRegion │ │ │ │ │ +WlOutput │ │ │ │ │ ======== │ │ │ │ │ │ │ │ │ │ -class pywayland.protocol.wayland.WlRegion │ │ │ │ │ - │ │ │ │ │ - Region interface │ │ │ │ │ +class pywayland.protocol.wayland.WlOutput │ │ │ │ │ │ │ │ │ │ - A region object describes an area. │ │ │ │ │ + Compositor output region │ │ │ │ │ │ │ │ │ │ - Region objects are used to describe the opaque and input regions of │ │ │ │ │ - a surface. │ │ │ │ │ + An output describes part of the compositor geometry. The │ │ │ │ │ + compositor works in the 'compositor coordinate system' and an │ │ │ │ │ + output corresponds to a rectangular area in that space that is │ │ │ │ │ + actually visible. This typically corresponds to a monitor that │ │ │ │ │ + displays part of the compositor space. This object is published as │ │ │ │ │ + global during start up, or when a monitor is hotplugged. │ │ │ │ │ │ │ │ │ │ - destroy() -> 'None' │ │ │ │ │ + release() -> 'None' │ │ │ │ │ │ │ │ │ │ -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ │ │ │ │ │ - Destroy region │ │ │ │ │ + Release the output object │ │ │ │ │ │ │ │ │ │ - Destroy the region. This will invalidate the object ID. │ │ │ │ │ + Using this request a client can tell the server that it is not │ │ │ │ │ + going to use the output object anymore. │ │ │ │ │ │ │ │ │ │ - add(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None' │ │ │ │ │ + geometry(x: 'int', y: 'int', physical_width: 'int', physical_height: 'int', subpixel: 'int', make: 'str', model: 'str', transform: 'int') -> 'None' │ │ │ │ │ │ │ │ │ │ - -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - Add rectangle to region │ │ │ │ │ + Properties of the output │ │ │ │ │ │ │ │ │ │ - Add the specified rectangle to the region. │ │ │ │ │ + The geometry event describes geometric properties of the output. │ │ │ │ │ + The event is sent when binding to the output object and whenever │ │ │ │ │ + any of the properties change. │ │ │ │ │ + │ │ │ │ │ + The physical size can be set to zero if it doesn't make sense │ │ │ │ │ + for this output (e.g. for projectors or virtual outputs). │ │ │ │ │ + │ │ │ │ │ + The geometry event will be followed by a done event (starting │ │ │ │ │ + from version 2). │ │ │ │ │ + │ │ │ │ │ + Clients should use "WlSurface.preferred_buffer_transform()" │ │ │ │ │ + instead of the transform advertised by this event to find the │ │ │ │ │ + preferred buffer transform to use for a surface. │ │ │ │ │ + │ │ │ │ │ + Note: "WlOutput" only advertises partial information about the │ │ │ │ │ + output position and identification. Some compositors, for │ │ │ │ │ + instance those not implementing a desktop-style output layout or │ │ │ │ │ + those exposing virtual outputs, might fake this information. │ │ │ │ │ + Instead of using x and y, clients should use │ │ │ │ │ + xdg_output.logical_position. Instead of using make and model, │ │ │ │ │ + clients should use name and description. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ - * **x** (*ArgumentType.Int*) -- region-local x coordinate │ │ │ │ │ + * **x** (*ArgumentType.Int*) -- x position within the global │ │ │ │ │ + compositor space │ │ │ │ │ │ │ │ │ │ - * **y** (*ArgumentType.Int*) -- region-local y coordinate │ │ │ │ │ + * **y** (*ArgumentType.Int*) -- y position within the global │ │ │ │ │ + compositor space │ │ │ │ │ │ │ │ │ │ - * **width** (*ArgumentType.Int*) -- rectangle width │ │ │ │ │ + * **physical_width** (*ArgumentType.Int*) -- width in │ │ │ │ │ + millimeters of the output │ │ │ │ │ │ │ │ │ │ - * **height** (*ArgumentType.Int*) -- rectangle height │ │ │ │ │ + * **physical_height** (*ArgumentType.Int*) -- height in │ │ │ │ │ + millimeters of the output │ │ │ │ │ │ │ │ │ │ - subtract(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None' │ │ │ │ │ + * **subpixel** (*ArgumentType.Int*) -- subpixel orientation │ │ │ │ │ + of the output │ │ │ │ │ │ │ │ │ │ - -[ Request -- opcode 2 (attached to "Resource" instance) ]- │ │ │ │ │ + * **make** (*ArgumentType.String*) -- textual description of │ │ │ │ │ + the manufacturer │ │ │ │ │ │ │ │ │ │ - Subtract rectangle from region │ │ │ │ │ + * **model** (*ArgumentType.String*) -- textual description of │ │ │ │ │ + the model │ │ │ │ │ │ │ │ │ │ - Subtract the specified rectangle from the region. │ │ │ │ │ + * **transform** (*ArgumentType.Int*) -- additional │ │ │ │ │ + transformation applied to buffer contents during │ │ │ │ │ + presentation │ │ │ │ │ + │ │ │ │ │ + mode(flags: 'int', width: 'int', height: 'int', refresh: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Advertise available modes for the output │ │ │ │ │ + │ │ │ │ │ + The mode event describes an available mode for the output. │ │ │ │ │ + │ │ │ │ │ + The event is sent when binding to the output object and there │ │ │ │ │ + will always be one mode, the current mode. The event is sent │ │ │ │ │ + again if an output changes mode, for the mode that is now │ │ │ │ │ + current. In other words, the current mode is always the last │ │ │ │ │ + mode that was received with the current flag set. │ │ │ │ │ + │ │ │ │ │ + Non-current modes are deprecated. A compositor can decide to │ │ │ │ │ + only advertise the current mode and never send other modes. │ │ │ │ │ + Clients should not rely on non-current modes. │ │ │ │ │ + │ │ │ │ │ + The size of a mode is given in physical hardware units of the │ │ │ │ │ + output device. This is not necessarily the same as the output │ │ │ │ │ + size in the global compositor space. For instance, the output │ │ │ │ │ + may be scaled, as described in "WlOutput.scale()", or │ │ │ │ │ + transformed, as described in "WlOutput.transform()". Clients │ │ │ │ │ + willing to retrieve the output size in the global compositor │ │ │ │ │ + space should use xdg_output.logical_size instead. │ │ │ │ │ + │ │ │ │ │ + The vertical refresh rate can be set to zero if it doesn't make │ │ │ │ │ + sense for this output (e.g. for virtual outputs). │ │ │ │ │ + │ │ │ │ │ + The mode event will be followed by a done event (starting from │ │ │ │ │ + version 2). │ │ │ │ │ + │ │ │ │ │ + Clients should not use the refresh rate to schedule frames. │ │ │ │ │ + Instead, they should use the "WlSurface.frame()" event or the │ │ │ │ │ + presentation-time protocol. │ │ │ │ │ + │ │ │ │ │ + Note: this information is not always meaningful for all outputs. │ │ │ │ │ + Some compositors, such as those exposing virtual outputs, might │ │ │ │ │ + fake the refresh rate or the size. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ - * **x** (*ArgumentType.Int*) -- region-local x coordinate │ │ │ │ │ + * **flags** (*ArgumentType.Uint*) -- bitfield of mode flags │ │ │ │ │ │ │ │ │ │ - * **y** (*ArgumentType.Int*) -- region-local y coordinate │ │ │ │ │ + * **width** (*ArgumentType.Int*) -- width of the mode in │ │ │ │ │ + hardware units │ │ │ │ │ │ │ │ │ │ - * **width** (*ArgumentType.Int*) -- rectangle width │ │ │ │ │ + * **height** (*ArgumentType.Int*) -- height of the mode in │ │ │ │ │ + hardware units │ │ │ │ │ │ │ │ │ │ - * **height** (*ArgumentType.Int*) -- rectangle height │ │ │ │ │ + * **refresh** (*ArgumentType.Int*) -- vertical refresh rate │ │ │ │ │ + in mHz │ │ │ │ │ │ │ │ │ │ + done() -> 'None' │ │ │ │ │ │ │ │ │ │ -WlDataSource │ │ │ │ │ -============ │ │ │ │ │ + -[ Event -- opcode 2 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ -class pywayland.protocol.wayland.WlDataSource │ │ │ │ │ + Sent all information about output │ │ │ │ │ │ │ │ │ │ - Offer to transfer data │ │ │ │ │ + This event is sent after all other properties have been sent │ │ │ │ │ + after binding to the output object and after any other property │ │ │ │ │ + changes done after that. This allows changes to the output │ │ │ │ │ + properties to be seen as atomic, even if they happen via │ │ │ │ │ + multiple events. │ │ │ │ │ │ │ │ │ │ - The "WlDataSource" object is the source side of a "WlDataOffer". It │ │ │ │ │ - is created by the source client in a data transfer and provides a │ │ │ │ │ - way to describe the offered data and a way to respond to requests │ │ │ │ │ - to transfer the data. │ │ │ │ │ + scale(factor: 'int') -> 'None' │ │ │ │ │ │ │ │ │ │ - offer(mime_type: 'str') -> 'None' │ │ │ │ │ + -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + Output scaling properties │ │ │ │ │ │ │ │ │ │ - Add an offered mime type │ │ │ │ │ + This event contains scaling geometry information that is not in │ │ │ │ │ + the geometry event. It may be sent after binding the output │ │ │ │ │ + object or if the output scale changes later. The compositor will │ │ │ │ │ + emit a non-zero, positive value for scale. If it is not sent, │ │ │ │ │ + the client should assume a scale of 1. │ │ │ │ │ │ │ │ │ │ - This request adds a mime type to the set of mime types │ │ │ │ │ - advertised to targets. Can be called several times to offer │ │ │ │ │ - multiple types. │ │ │ │ │ + A scale larger than 1 means that the compositor will │ │ │ │ │ + automatically scale surface buffers by this amount when │ │ │ │ │ + rendering. This is used for very high resolution displays where │ │ │ │ │ + applications rendering at the native resolution would be too │ │ │ │ │ + small to be legible. │ │ │ │ │ + │ │ │ │ │ + Clients should use "WlSurface.preferred_buffer_scale()" instead │ │ │ │ │ + of this event to find the preferred buffer scale to use for a │ │ │ │ │ + surface. │ │ │ │ │ + │ │ │ │ │ + The scale event will be followed by a done event. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ - **mime_type** (*ArgumentType.String*) -- mime type offered by │ │ │ │ │ - the data source │ │ │ │ │ + **factor** (*ArgumentType.Int*) -- scaling factor of output │ │ │ │ │ │ │ │ │ │ - destroy() -> 'None' │ │ │ │ │ + name(name: 'str') -> 'None' │ │ │ │ │ │ │ │ │ │ - -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + -[ Event -- opcode 4 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - Destroy the data source │ │ │ │ │ + Name of this output │ │ │ │ │ │ │ │ │ │ - Destroy the data source. │ │ │ │ │ + Many compositors will assign user-friendly names to their │ │ │ │ │ + outputs, show them to the user, allow the user to refer to an │ │ │ │ │ + output, etc. The client may wish to know this name as well to │ │ │ │ │ + offer the user similar behaviors. │ │ │ │ │ │ │ │ │ │ - set_actions(dnd_actions: 'int') -> 'None' │ │ │ │ │ + The name is a UTF-8 string with no convention defined for its │ │ │ │ │ + contents. Each name is unique among all "WlOutput" globals. The │ │ │ │ │ + name is only guaranteed to be unique for the compositor │ │ │ │ │ + instance. │ │ │ │ │ │ │ │ │ │ - -[ Request -- opcode 2 (attached to "Resource" instance) ]- │ │ │ │ │ + The same output name is used for all clients for a given │ │ │ │ │ + "WlOutput" global. Thus, the name can be shared across processes │ │ │ │ │ + to refer to a specific "WlOutput" global. │ │ │ │ │ │ │ │ │ │ - Set the available drag-and-drop actions │ │ │ │ │ + The name is not guaranteed to be persistent across sessions, │ │ │ │ │ + thus cannot be used to reliably identify an output in e.g. │ │ │ │ │ + configuration files. │ │ │ │ │ │ │ │ │ │ - Sets the actions that the source side client supports for this │ │ │ │ │ - operation. This request may trigger "WlDataSource.action()" and │ │ │ │ │ - "WlDataOffer.action()" events if the compositor needs to change │ │ │ │ │ - the selected action. │ │ │ │ │ + Examples of names include 'HDMI-A-1', 'WL-1', 'X11-1', etc. │ │ │ │ │ + However, do not assume that the name is a reflection of an │ │ │ │ │ + underlying DRM connector, X11 connection, etc. │ │ │ │ │ │ │ │ │ │ - The dnd_actions argument must contain only values expressed in │ │ │ │ │ - the "WlDataDeviceManager.dnd_actions()" enum, otherwise it will │ │ │ │ │ - result in a protocol error. │ │ │ │ │ + The name event is sent after binding the output object. This │ │ │ │ │ + event is only sent once per output object, and the name does not │ │ │ │ │ + change over the lifetime of the "WlOutput" global. │ │ │ │ │ │ │ │ │ │ - This request must be made once only, and can only be made on │ │ │ │ │ - sources used in drag-and-drop, so it must be performed before │ │ │ │ │ - "WlDataDevice.start_drag()". Attempting to use the source other │ │ │ │ │ - than for drag-and-drop will raise a protocol error. │ │ │ │ │ + Compositors may re-use the same output name if the "WlOutput" │ │ │ │ │ + global is destroyed and re-created later. Compositors should │ │ │ │ │ + avoid re- using the same name if possible. │ │ │ │ │ + │ │ │ │ │ + The name event will be followed by a done event. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ - **dnd_actions** (*ArgumentType.Uint*) -- actions supported by │ │ │ │ │ - the data source │ │ │ │ │ + **name** (*ArgumentType.String*) -- output name │ │ │ │ │ │ │ │ │ │ - target(mime_type: 'str | None') -> 'None' │ │ │ │ │ + description(description: 'str') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 5 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Human-readable description of this output │ │ │ │ │ + │ │ │ │ │ + Many compositors can produce human-readable descriptions of │ │ │ │ │ + their outputs. The client may wish to know this description as │ │ │ │ │ + well, e.g. for output selection purposes. │ │ │ │ │ + │ │ │ │ │ + The description is a UTF-8 string with no convention defined for │ │ │ │ │ + its contents. The description is not guaranteed to be unique │ │ │ │ │ + among all "WlOutput" globals. Examples might include 'Foocorp │ │ │ │ │ + 11" Display' or 'Virtual X11 output via :1'. │ │ │ │ │ + │ │ │ │ │ + The description event is sent after binding the output object │ │ │ │ │ + and whenever the description changes. The description is │ │ │ │ │ + optional, and may not be sent at all. │ │ │ │ │ + │ │ │ │ │ + The description event will be followed by a done event. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **description** (*ArgumentType.String*) -- output description │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ +WlKeyboard │ │ │ │ │ +========== │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlKeyboard │ │ │ │ │ + │ │ │ │ │ + Keyboard input device │ │ │ │ │ + │ │ │ │ │ + The "WlKeyboard" interface represents one or more keyboards │ │ │ │ │ + associated with a seat. │ │ │ │ │ + │ │ │ │ │ + Each "WlKeyboard" has the following logical state: │ │ │ │ │ + │ │ │ │ │ + * an active surface (possibly null), │ │ │ │ │ + │ │ │ │ │ + * the keys currently logically down, │ │ │ │ │ + │ │ │ │ │ + * the active modifiers, │ │ │ │ │ + │ │ │ │ │ + * the active group. │ │ │ │ │ + │ │ │ │ │ + By default, the active surface is null, the keys currently │ │ │ │ │ + logically down are empty, the active modifiers and the active group │ │ │ │ │ + are 0. │ │ │ │ │ + │ │ │ │ │ + release() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Release the keyboard object │ │ │ │ │ + │ │ │ │ │ + keymap(format: 'int', fd: 'int', size: 'int') -> 'None' │ │ │ │ │ │ │ │ │ │ -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - A target accepts an offered mime type │ │ │ │ │ + Keyboard mapping │ │ │ │ │ │ │ │ │ │ - Sent when a target accepts pointer_focus or motion events. If a │ │ │ │ │ - target does not accept any of the offered types, type is NULL. │ │ │ │ │ + This event provides a file descriptor to the client which can be │ │ │ │ │ + memory-mapped in read-only mode to provide a keyboard mapping │ │ │ │ │ + description. │ │ │ │ │ │ │ │ │ │ - Used for feedback during drag-and-drop. │ │ │ │ │ + From version 7 onwards, the fd must be mapped with MAP_PRIVATE │ │ │ │ │ + by the recipient, as MAP_SHARED may fail. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ - **mime_type** (*ArgumentType.String* or *None*) -- mime type │ │ │ │ │ - accepted by the target │ │ │ │ │ + * **format** (*ArgumentType.Uint*) -- keymap format │ │ │ │ │ │ │ │ │ │ - send(mime_type: 'str', fd: 'int') -> 'None' │ │ │ │ │ + * **fd** (*ArgumentType.FileDescriptor*) -- keymap file │ │ │ │ │ + descriptor │ │ │ │ │ + │ │ │ │ │ + * **size** (*ArgumentType.Uint*) -- keymap size, in bytes │ │ │ │ │ + │ │ │ │ │ + enter(serial: 'int', surface: 'WlSurface', keys: 'list') -> 'None' │ │ │ │ │ │ │ │ │ │ -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - Send the data │ │ │ │ │ + Enter event │ │ │ │ │ │ │ │ │ │ - Request for data from the client. Send the data as the │ │ │ │ │ - specified mime type over the passed file descriptor, then close │ │ │ │ │ - it. │ │ │ │ │ + Notification that this seat's keyboard focus is on a certain │ │ │ │ │ + surface. │ │ │ │ │ + │ │ │ │ │ + The compositor must send the "WlKeyboard.modifiers()" event │ │ │ │ │ + after this event. │ │ │ │ │ + │ │ │ │ │ + In the "WlKeyboard" logical state, this event sets the active │ │ │ │ │ + surface to the surface argument and the keys currently logically │ │ │ │ │ + down to the keys in the keys argument. The compositor must not │ │ │ │ │ + send this event if the "WlKeyboard" already had an active │ │ │ │ │ + surface immediately before this event. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ - * **mime_type** (*ArgumentType.String*) -- mime type for the │ │ │ │ │ - data │ │ │ │ │ + * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ + enter event │ │ │ │ │ │ │ │ │ │ - * **fd** (*ArgumentType.FileDescriptor*) -- file descriptor │ │ │ │ │ - for the data │ │ │ │ │ + * **surface** ("WlSurface") -- surface gaining keyboard focus │ │ │ │ │ │ │ │ │ │ - cancelled() -> 'None' │ │ │ │ │ + * **keys** (*ArgumentType.Array*) -- the keys currently │ │ │ │ │ + logically down │ │ │ │ │ + │ │ │ │ │ + leave(serial: 'int', surface: 'WlSurface') -> 'None' │ │ │ │ │ │ │ │ │ │ -[ Event -- opcode 2 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - Selection was cancelled │ │ │ │ │ + Leave event │ │ │ │ │ │ │ │ │ │ - This data source is no longer valid. There are several reasons │ │ │ │ │ - why this could happen: │ │ │ │ │ + Notification that this seat's keyboard focus is no longer on a │ │ │ │ │ + certain surface. │ │ │ │ │ │ │ │ │ │ - * The data source has been replaced by another data source. │ │ │ │ │ + The leave notification is sent before the enter notification for │ │ │ │ │ + the new focus. │ │ │ │ │ │ │ │ │ │ - * The drag-and-drop operation was performed, but the drop │ │ │ │ │ - destination did not accept any of the mime types offered │ │ │ │ │ - through "WlDataSource.target()". │ │ │ │ │ + In the "WlKeyboard" logical state, this event resets all values │ │ │ │ │ + to their defaults. The compositor must not send this event if │ │ │ │ │ + the active surface of the "WlKeyboard" was not equal to the │ │ │ │ │ + surface argument immediately before this event. │ │ │ │ │ │ │ │ │ │ - * The drag-and-drop operation was performed, but the drop │ │ │ │ │ - destination did not select any of the actions present in the │ │ │ │ │ - mask offered through "WlDataSource.action()". │ │ │ │ │ + Parameters: │ │ │ │ │ + * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ + leave event │ │ │ │ │ │ │ │ │ │ - * The drag-and-drop operation was performed but didn't happen │ │ │ │ │ - over a surface. │ │ │ │ │ + * **surface** ("WlSurface") -- surface that lost keyboard │ │ │ │ │ + focus │ │ │ │ │ │ │ │ │ │ - * The compositor cancelled the drag-and-drop operation (e.g. │ │ │ │ │ - compositor dependent timeouts to avoid stale drag-and-drop │ │ │ │ │ - transfers). │ │ │ │ │ + key(serial: 'int', time: 'int', key: 'int', state: 'int') -> 'None' │ │ │ │ │ │ │ │ │ │ - The client should clean up and destroy this data source. │ │ │ │ │ + -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - For objects of version 2 or older, "WlDataSource.cancelled()" │ │ │ │ │ - will only be emitted if the data source was replaced by another │ │ │ │ │ - data source. │ │ │ │ │ + Key event │ │ │ │ │ │ │ │ │ │ - dnd_drop_performed() -> 'None' │ │ │ │ │ + A key was pressed or released. The time argument is a timestamp │ │ │ │ │ + with millisecond granularity, with an undefined base. │ │ │ │ │ │ │ │ │ │ - -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ + The key is a platform-specific key code that can be interpreted │ │ │ │ │ + by feeding it to the keyboard mapping (see the keymap event). │ │ │ │ │ │ │ │ │ │ - The drag-and-drop operation physically finished │ │ │ │ │ + If this event produces a change in modifiers, then the resulting │ │ │ │ │ + "WlKeyboard.modifiers()" event must be sent after this event. │ │ │ │ │ │ │ │ │ │ - The user performed the drop action. This event does not indicate │ │ │ │ │ - acceptance, "WlDataSource.cancelled()" may still be emitted │ │ │ │ │ - afterwards if the drop destination does not accept any mime │ │ │ │ │ - type. │ │ │ │ │ + In the "WlKeyboard" logical state, this event adds the key to │ │ │ │ │ + the keys currently logically down (if the state argument is │ │ │ │ │ + pressed) or removes the key from the keys currently logically │ │ │ │ │ + down (if the state argument is released). The compositor must │ │ │ │ │ + not send this event if the "WlKeyboard" did not have an active │ │ │ │ │ + surface immediately before this event. The compositor must not │ │ │ │ │ + send this event if state is pressed (resp. released) and the key │ │ │ │ │ + was already logically down (resp. was not logically down) │ │ │ │ │ + immediately before this event. │ │ │ │ │ │ │ │ │ │ - However, this event might however not be received if the │ │ │ │ │ - compositor cancelled the drag-and-drop operation before this │ │ │ │ │ - event could happen. │ │ │ │ │ + Parameters: │ │ │ │ │ + * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ + key event │ │ │ │ │ │ │ │ │ │ - Note that the data_source may still be used in the future and │ │ │ │ │ - should not be destroyed here. │ │ │ │ │ + * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ + millisecond granularity │ │ │ │ │ │ │ │ │ │ - dnd_finished() -> 'None' │ │ │ │ │ + * **key** (*ArgumentType.Uint*) -- key that produced the │ │ │ │ │ + event │ │ │ │ │ + │ │ │ │ │ + * **state** (*ArgumentType.Uint*) -- physical state of the │ │ │ │ │ + key │ │ │ │ │ + │ │ │ │ │ + modifiers(serial: 'int', mods_depressed: 'int', mods_latched: 'int', mods_locked: 'int', group: 'int') -> 'None' │ │ │ │ │ │ │ │ │ │ -[ Event -- opcode 4 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - The drag-and-drop operation concluded │ │ │ │ │ + Modifier and group state │ │ │ │ │ │ │ │ │ │ - The drop destination finished interoperating with this data │ │ │ │ │ - source, so the client is now free to destroy this data source │ │ │ │ │ - and free all associated data. │ │ │ │ │ + Notifies clients that the modifier and/or group state has │ │ │ │ │ + changed, and it should update its local state. │ │ │ │ │ │ │ │ │ │ - If the action used to perform the operation was "move", the │ │ │ │ │ - source can now delete the transferred data. │ │ │ │ │ + The compositor may send this event without a surface of the │ │ │ │ │ + client having keyboard focus, for example to tie modifier │ │ │ │ │ + information to pointer focus instead. If a modifier event with │ │ │ │ │ + pressed modifiers is sent without a prior enter event, the │ │ │ │ │ + client can assume the modifier state is valid until it receives │ │ │ │ │ + the next "WlKeyboard.modifiers()" event. In order to reset the │ │ │ │ │ + modifier state again, the compositor can send a │ │ │ │ │ + "WlKeyboard.modifiers()" event with no pressed modifiers. │ │ │ │ │ │ │ │ │ │ - action(dnd_action: 'int') -> 'None' │ │ │ │ │ + In the "WlKeyboard" logical state, this event updates the │ │ │ │ │ + modifiers and group. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ + modifiers event │ │ │ │ │ + │ │ │ │ │ + * **mods_depressed** (*ArgumentType.Uint*) -- depressed │ │ │ │ │ + modifiers │ │ │ │ │ + │ │ │ │ │ + * **mods_latched** (*ArgumentType.Uint*) -- latched modifiers │ │ │ │ │ + │ │ │ │ │ + * **mods_locked** (*ArgumentType.Uint*) -- locked modifiers │ │ │ │ │ + │ │ │ │ │ + * **group** (*ArgumentType.Uint*) -- keyboard layout │ │ │ │ │ + │ │ │ │ │ + repeat_info(rate: 'int', delay: 'int') -> 'None' │ │ │ │ │ │ │ │ │ │ -[ Event -- opcode 5 (attached to "Proxy" instance) ]- │ │ │ │ │ │ │ │ │ │ - Notify the selected action │ │ │ │ │ + Repeat rate and delay │ │ │ │ │ │ │ │ │ │ - This event indicates the action selected by the compositor after │ │ │ │ │ - matching the source/destination side actions. Only one action │ │ │ │ │ - (or none) will be offered here. │ │ │ │ │ + Informs the client about the keyboard's repeat rate and delay. │ │ │ │ │ │ │ │ │ │ - This event can be emitted multiple times during the drag-and- │ │ │ │ │ - drop operation, mainly in response to destination side changes │ │ │ │ │ - through "WlDataOffer.set_actions()", and as the data device │ │ │ │ │ - enters/leaves surfaces. │ │ │ │ │ + This event is sent as soon as the "WlKeyboard" object has been │ │ │ │ │ + created, and is guaranteed to be received by the client before │ │ │ │ │ + any key press event. │ │ │ │ │ │ │ │ │ │ - It is only possible to receive this event after │ │ │ │ │ - "WlDataSource.dnd_drop_performed()" if the drag-and-drop │ │ │ │ │ - operation ended in an "ask" action, in which case the final │ │ │ │ │ - "WlDataSource.action()" event will happen immediately before │ │ │ │ │ - "WlDataSource.dnd_finished()". │ │ │ │ │ + Negative values for either rate or delay are illegal. A rate of │ │ │ │ │ + zero will disable any repeating (regardless of the value of │ │ │ │ │ + delay). │ │ │ │ │ │ │ │ │ │ - Compositors may also change the selected action on the fly, │ │ │ │ │ - mainly in response to keyboard modifier changes during the drag- │ │ │ │ │ - and-drop operation. │ │ │ │ │ + This event can be sent later on as well with a new value if │ │ │ │ │ + necessary, so clients should continue listening for the event │ │ │ │ │ + past the creation of "WlKeyboard". │ │ │ │ │ │ │ │ │ │ - The most recent action received is always the valid one. The │ │ │ │ │ - chosen action may change alongside negotiation (e.g. an "ask" │ │ │ │ │ - action can turn into a "move" operation), so the effects of the │ │ │ │ │ - final action must always be applied in │ │ │ │ │ - "WlDataOffer.dnd_finished()". │ │ │ │ │ + Parameters: │ │ │ │ │ + * **rate** (*ArgumentType.Int*) -- the rate of repeating keys │ │ │ │ │ + in characters per second │ │ │ │ │ │ │ │ │ │ - Clients can trigger cursor surface changes from this point, so │ │ │ │ │ - they reflect the current action. │ │ │ │ │ + * **delay** (*ArgumentType.Int*) -- delay in milliseconds │ │ │ │ │ + since key down until repeating starts │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ +WlCompositor │ │ │ │ │ +============ │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlCompositor │ │ │ │ │ + │ │ │ │ │ + The compositor singleton │ │ │ │ │ + │ │ │ │ │ + A compositor. This object is a singleton global. The compositor │ │ │ │ │ + is in charge of combining the contents of multiple surfaces into │ │ │ │ │ + one displayable output. │ │ │ │ │ + │ │ │ │ │ + create_surface() -> 'Proxy[WlSurface]' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Create new surface │ │ │ │ │ + │ │ │ │ │ + Ask the compositor to create a new surface. │ │ │ │ │ + │ │ │ │ │ + Returns: │ │ │ │ │ + "WlSurface" -- the new surface │ │ │ │ │ + │ │ │ │ │ + create_region() -> 'Proxy[WlRegion]' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Create new region │ │ │ │ │ + │ │ │ │ │ + Ask the compositor to create a new region. │ │ │ │ │ + │ │ │ │ │ + Returns: │ │ │ │ │ + "WlRegion" -- the new region │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ +WlSeat │ │ │ │ │ +====== │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlSeat │ │ │ │ │ + │ │ │ │ │ + Group of input devices │ │ │ │ │ + │ │ │ │ │ + A seat is a group of keyboards, pointer and touch devices. This │ │ │ │ │ + object is published as a global during start up, or when such a │ │ │ │ │ + device is hot plugged. A seat typically has a pointer and │ │ │ │ │ + maintains a keyboard focus and a pointer focus. │ │ │ │ │ + │ │ │ │ │ + get_pointer() -> 'Proxy[WlPointer]' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Return pointer object │ │ │ │ │ + │ │ │ │ │ + The ID provided will be initialized to the "WlPointer" interface │ │ │ │ │ + for this seat. │ │ │ │ │ + │ │ │ │ │ + This request only takes effect if the seat has the pointer │ │ │ │ │ + capability, or has had the pointer capability in the past. It is │ │ │ │ │ + a protocol violation to issue this request on a seat that has │ │ │ │ │ + never had the pointer capability. The missing_capability error │ │ │ │ │ + will be sent in this case. │ │ │ │ │ + │ │ │ │ │ + Returns: │ │ │ │ │ + "WlPointer" -- seat pointer │ │ │ │ │ + │ │ │ │ │ + get_keyboard() -> 'Proxy[WlKeyboard]' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Return keyboard object │ │ │ │ │ + │ │ │ │ │ + The ID provided will be initialized to the "WlKeyboard" │ │ │ │ │ + interface for this seat. │ │ │ │ │ + │ │ │ │ │ + This request only takes effect if the seat has the keyboard │ │ │ │ │ + capability, or has had the keyboard capability in the past. It │ │ │ │ │ + is a protocol violation to issue this request on a seat that has │ │ │ │ │ + never had the keyboard capability. The missing_capability error │ │ │ │ │ + will be sent in this case. │ │ │ │ │ + │ │ │ │ │ + Returns: │ │ │ │ │ + "WlKeyboard" -- seat keyboard │ │ │ │ │ + │ │ │ │ │ + get_touch() -> 'Proxy[WlTouch]' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 2 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Return touch object │ │ │ │ │ + │ │ │ │ │ + The ID provided will be initialized to the "WlTouch" interface │ │ │ │ │ + for this seat. │ │ │ │ │ + │ │ │ │ │ + This request only takes effect if the seat has the touch │ │ │ │ │ + capability, or has had the touch capability in the past. It is a │ │ │ │ │ + protocol violation to issue this request on a seat that has │ │ │ │ │ + never had the touch capability. The missing_capability error │ │ │ │ │ + will be sent in this case. │ │ │ │ │ + │ │ │ │ │ + Returns: │ │ │ │ │ + "WlTouch" -- seat touch interface │ │ │ │ │ + │ │ │ │ │ + release() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 3 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Release the seat object │ │ │ │ │ + │ │ │ │ │ + Using this request a client can tell the server that it is not │ │ │ │ │ + going to use the seat object anymore. │ │ │ │ │ + │ │ │ │ │ + capabilities(capabilities: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Seat capabilities changed │ │ │ │ │ + │ │ │ │ │ + This is emitted whenever a seat gains or loses the pointer, │ │ │ │ │ + keyboard or touch capabilities. The argument is a capability │ │ │ │ │ + enum containing the complete set of capabilities this seat has. │ │ │ │ │ + │ │ │ │ │ + When the pointer capability is added, a client may create a │ │ │ │ │ + "WlPointer" object using the "WlSeat.get_pointer()" request. │ │ │ │ │ + This object will receive pointer events until the capability is │ │ │ │ │ + removed in the future. │ │ │ │ │ + │ │ │ │ │ + When the pointer capability is removed, a client should destroy │ │ │ │ │ + the "WlPointer" objects associated with the seat where the │ │ │ │ │ + capability was removed, using the "WlPointer.release()" request. │ │ │ │ │ + No further pointer events will be received on these objects. │ │ │ │ │ + │ │ │ │ │ + In some compositors, if a seat regains the pointer capability │ │ │ │ │ + and a client has a previously obtained "WlPointer" object of │ │ │ │ │ + version 4 or less, that object may start sending pointer events │ │ │ │ │ + again. This behavior is considered a misinterpretation of the │ │ │ │ │ + intended behavior and must not be relied upon by the client. │ │ │ │ │ + "WlPointer" objects of version 5 or later must not send events │ │ │ │ │ + if created before the most recent event notifying the client of │ │ │ │ │ + an added pointer capability. │ │ │ │ │ + │ │ │ │ │ + The above behavior also applies to "WlKeyboard" and "WlTouch" │ │ │ │ │ + with the keyboard and touch capabilities, respectively. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ - **dnd_action** (*ArgumentType.Uint*) -- action selected by │ │ │ │ │ - the compositor │ │ │ │ │ + **capabilities** (*ArgumentType.Uint*) -- capabilities of the │ │ │ │ │ + seat │ │ │ │ │ + │ │ │ │ │ + name(name: 'str') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Unique identifier for this seat │ │ │ │ │ + │ │ │ │ │ + In a multi-seat configuration the seat name can be used by │ │ │ │ │ + clients to help identify which physical devices the seat │ │ │ │ │ + represents. │ │ │ │ │ + │ │ │ │ │ + The seat name is a UTF-8 string with no convention defined for │ │ │ │ │ + its contents. Each name is unique among all "WlSeat" globals. │ │ │ │ │ + The name is only guaranteed to be unique for the current │ │ │ │ │ + compositor instance. │ │ │ │ │ + │ │ │ │ │ + The same seat names are used for all clients. Thus, the name can │ │ │ │ │ + be shared across processes to refer to a specific "WlSeat" │ │ │ │ │ + global. │ │ │ │ │ + │ │ │ │ │ + The name event is sent after binding to the seat global. This │ │ │ │ │ + event is only sent once per seat object, and the name does not │ │ │ │ │ + change over the lifetime of the "WlSeat" global. │ │ │ │ │ + │ │ │ │ │ + Compositors may re-use the same seat name if the "WlSeat" global │ │ │ │ │ + is destroyed and re-created later. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **name** (*ArgumentType.String*) -- seat identifier │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ WlDataOffer │ │ │ │ │ =========== │ │ │ │ │ │ │ │ │ │ class pywayland.protocol.wayland.WlDataOffer │ │ │ │ │ │ │ │ │ │ @@ -1260,14 +2111,389 @@ │ │ │ │ │ "WlDataOffer.finish()". │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ **dnd_action** (*ArgumentType.Uint*) -- action selected by │ │ │ │ │ the compositor │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ +WlBuffer │ │ │ │ │ +======== │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlBuffer │ │ │ │ │ + │ │ │ │ │ + Content for a "WlSurface" │ │ │ │ │ + │ │ │ │ │ + A buffer provides the content for a "WlSurface". Buffers are │ │ │ │ │ + created through factory interfaces such as "WlShm", │ │ │ │ │ + wp_linux_buffer_params (from the linux-dmabuf protocol extension) │ │ │ │ │ + or similar. It has a width and a height and can be attached to a │ │ │ │ │ + "WlSurface", but the mechanism by which a client provides and │ │ │ │ │ + updates the contents is defined by the buffer factory interface. │ │ │ │ │ + │ │ │ │ │ + Color channels are assumed to be electrical rather than optical (in │ │ │ │ │ + other words, encoded with a transfer function) unless otherwise │ │ │ │ │ + specified. If the buffer uses a format that has an alpha channel, │ │ │ │ │ + the alpha channel is assumed to be premultiplied into the │ │ │ │ │ + electrical color channel values (after transfer function encoding) │ │ │ │ │ + unless otherwise specified. │ │ │ │ │ + │ │ │ │ │ + Note, because "WlBuffer" objects are created from multiple │ │ │ │ │ + independent factory interfaces, the "WlBuffer" interface is frozen │ │ │ │ │ + at version 1. │ │ │ │ │ + │ │ │ │ │ + destroy() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Destroy a buffer │ │ │ │ │ + │ │ │ │ │ + Destroy a buffer. If and how you need to release the backing │ │ │ │ │ + storage is defined by the buffer factory interface. │ │ │ │ │ + │ │ │ │ │ + For possible side-effects to a surface, see │ │ │ │ │ + "WlSurface.attach()". │ │ │ │ │ + │ │ │ │ │ + release() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Compositor releases buffer │ │ │ │ │ + │ │ │ │ │ + Sent when this "WlBuffer" is no longer used by the compositor. │ │ │ │ │ + The client is now free to reuse or destroy this buffer and its │ │ │ │ │ + backing storage. │ │ │ │ │ + │ │ │ │ │ + If a client receives a release event before the frame callback │ │ │ │ │ + requested in the same "WlSurface.commit()" that attaches this │ │ │ │ │ + "WlBuffer" to a surface, then the client is immediately free to │ │ │ │ │ + reuse the buffer and its backing storage, and does not need a │ │ │ │ │ + second buffer for the next surface content update. Typically │ │ │ │ │ + this is possible, when the compositor maintains a copy of the │ │ │ │ │ + "WlSurface" contents, e.g. as a GL texture. This is an important │ │ │ │ │ + optimization for GL(ES) compositors with "WlShm" clients. │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ +WlDataSource │ │ │ │ │ +============ │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlDataSource │ │ │ │ │ + │ │ │ │ │ + Offer to transfer data │ │ │ │ │ + │ │ │ │ │ + The "WlDataSource" object is the source side of a "WlDataOffer". It │ │ │ │ │ + is created by the source client in a data transfer and provides a │ │ │ │ │ + way to describe the offered data and a way to respond to requests │ │ │ │ │ + to transfer the data. │ │ │ │ │ + │ │ │ │ │ + offer(mime_type: 'str') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Add an offered mime type │ │ │ │ │ + │ │ │ │ │ + This request adds a mime type to the set of mime types │ │ │ │ │ + advertised to targets. Can be called several times to offer │ │ │ │ │ + multiple types. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **mime_type** (*ArgumentType.String*) -- mime type offered by │ │ │ │ │ + the data source │ │ │ │ │ + │ │ │ │ │ + destroy() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Destroy the data source │ │ │ │ │ + │ │ │ │ │ + Destroy the data source. │ │ │ │ │ + │ │ │ │ │ + set_actions(dnd_actions: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 2 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Set the available drag-and-drop actions │ │ │ │ │ + │ │ │ │ │ + Sets the actions that the source side client supports for this │ │ │ │ │ + operation. This request may trigger "WlDataSource.action()" and │ │ │ │ │ + "WlDataOffer.action()" events if the compositor needs to change │ │ │ │ │ + the selected action. │ │ │ │ │ + │ │ │ │ │ + The dnd_actions argument must contain only values expressed in │ │ │ │ │ + the "WlDataDeviceManager.dnd_actions()" enum, otherwise it will │ │ │ │ │ + result in a protocol error. │ │ │ │ │ + │ │ │ │ │ + This request must be made once only, and can only be made on │ │ │ │ │ + sources used in drag-and-drop, so it must be performed before │ │ │ │ │ + "WlDataDevice.start_drag()". Attempting to use the source other │ │ │ │ │ + than for drag-and-drop will raise a protocol error. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **dnd_actions** (*ArgumentType.Uint*) -- actions supported by │ │ │ │ │ + the data source │ │ │ │ │ + │ │ │ │ │ + target(mime_type: 'str | None') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + A target accepts an offered mime type │ │ │ │ │ + │ │ │ │ │ + Sent when a target accepts pointer_focus or motion events. If a │ │ │ │ │ + target does not accept any of the offered types, type is NULL. │ │ │ │ │ + │ │ │ │ │ + Used for feedback during drag-and-drop. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **mime_type** (*ArgumentType.String* or *None*) -- mime type │ │ │ │ │ + accepted by the target │ │ │ │ │ + │ │ │ │ │ + send(mime_type: 'str', fd: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Send the data │ │ │ │ │ + │ │ │ │ │ + Request for data from the client. Send the data as the │ │ │ │ │ + specified mime type over the passed file descriptor, then close │ │ │ │ │ + it. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **mime_type** (*ArgumentType.String*) -- mime type for the │ │ │ │ │ + data │ │ │ │ │ + │ │ │ │ │ + * **fd** (*ArgumentType.FileDescriptor*) -- file descriptor │ │ │ │ │ + for the data │ │ │ │ │ + │ │ │ │ │ + cancelled() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 2 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Selection was cancelled │ │ │ │ │ + │ │ │ │ │ + This data source is no longer valid. There are several reasons │ │ │ │ │ + why this could happen: │ │ │ │ │ + │ │ │ │ │ + * The data source has been replaced by another data source. │ │ │ │ │ + │ │ │ │ │ + * The drag-and-drop operation was performed, but the drop │ │ │ │ │ + destination did not accept any of the mime types offered │ │ │ │ │ + through "WlDataSource.target()". │ │ │ │ │ + │ │ │ │ │ + * The drag-and-drop operation was performed, but the drop │ │ │ │ │ + destination did not select any of the actions present in the │ │ │ │ │ + mask offered through "WlDataSource.action()". │ │ │ │ │ + │ │ │ │ │ + * The drag-and-drop operation was performed but didn't happen │ │ │ │ │ + over a surface. │ │ │ │ │ + │ │ │ │ │ + * The compositor cancelled the drag-and-drop operation (e.g. │ │ │ │ │ + compositor dependent timeouts to avoid stale drag-and-drop │ │ │ │ │ + transfers). │ │ │ │ │ + │ │ │ │ │ + The client should clean up and destroy this data source. │ │ │ │ │ + │ │ │ │ │ + For objects of version 2 or older, "WlDataSource.cancelled()" │ │ │ │ │ + will only be emitted if the data source was replaced by another │ │ │ │ │ + data source. │ │ │ │ │ + │ │ │ │ │ + dnd_drop_performed() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + The drag-and-drop operation physically finished │ │ │ │ │ + │ │ │ │ │ + The user performed the drop action. This event does not indicate │ │ │ │ │ + acceptance, "WlDataSource.cancelled()" may still be emitted │ │ │ │ │ + afterwards if the drop destination does not accept any mime │ │ │ │ │ + type. │ │ │ │ │ + │ │ │ │ │ + However, this event might however not be received if the │ │ │ │ │ + compositor cancelled the drag-and-drop operation before this │ │ │ │ │ + event could happen. │ │ │ │ │ + │ │ │ │ │ + Note that the data_source may still be used in the future and │ │ │ │ │ + should not be destroyed here. │ │ │ │ │ + │ │ │ │ │ + dnd_finished() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 4 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + The drag-and-drop operation concluded │ │ │ │ │ + │ │ │ │ │ + The drop destination finished interoperating with this data │ │ │ │ │ + source, so the client is now free to destroy this data source │ │ │ │ │ + and free all associated data. │ │ │ │ │ + │ │ │ │ │ + If the action used to perform the operation was "move", the │ │ │ │ │ + source can now delete the transferred data. │ │ │ │ │ + │ │ │ │ │ + action(dnd_action: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 5 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Notify the selected action │ │ │ │ │ + │ │ │ │ │ + This event indicates the action selected by the compositor after │ │ │ │ │ + matching the source/destination side actions. Only one action │ │ │ │ │ + (or none) will be offered here. │ │ │ │ │ + │ │ │ │ │ + This event can be emitted multiple times during the drag-and- │ │ │ │ │ + drop operation, mainly in response to destination side changes │ │ │ │ │ + through "WlDataOffer.set_actions()", and as the data device │ │ │ │ │ + enters/leaves surfaces. │ │ │ │ │ + │ │ │ │ │ + It is only possible to receive this event after │ │ │ │ │ + "WlDataSource.dnd_drop_performed()" if the drag-and-drop │ │ │ │ │ + operation ended in an "ask" action, in which case the final │ │ │ │ │ + "WlDataSource.action()" event will happen immediately before │ │ │ │ │ + "WlDataSource.dnd_finished()". │ │ │ │ │ + │ │ │ │ │ + Compositors may also change the selected action on the fly, │ │ │ │ │ + mainly in response to keyboard modifier changes during the drag- │ │ │ │ │ + and-drop operation. │ │ │ │ │ + │ │ │ │ │ + The most recent action received is always the valid one. The │ │ │ │ │ + chosen action may change alongside negotiation (e.g. an "ask" │ │ │ │ │ + action can turn into a "move" operation), so the effects of the │ │ │ │ │ + final action must always be applied in │ │ │ │ │ + "WlDataOffer.dnd_finished()". │ │ │ │ │ + │ │ │ │ │ + Clients can trigger cursor surface changes from this point, so │ │ │ │ │ + they reflect the current action. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **dnd_action** (*ArgumentType.Uint*) -- action selected by │ │ │ │ │ + the compositor │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ +WlCallback │ │ │ │ │ +========== │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlCallback │ │ │ │ │ + │ │ │ │ │ + Callback object │ │ │ │ │ + │ │ │ │ │ + Clients can handle the 'done' event to get notified when the │ │ │ │ │ + related request is done. │ │ │ │ │ + │ │ │ │ │ + Note, because "WlCallback" objects are created from multiple │ │ │ │ │ + independent factory interfaces, the "WlCallback" interface is │ │ │ │ │ + frozen at version 1. │ │ │ │ │ + │ │ │ │ │ + done(callback_data: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Done event │ │ │ │ │ + │ │ │ │ │ + Notify the client when the related request is done. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **callback_data** (*ArgumentType.Uint*) -- request-specific │ │ │ │ │ + data for the callback │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ +WlRegion │ │ │ │ │ +======== │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlRegion │ │ │ │ │ + │ │ │ │ │ + Region interface │ │ │ │ │ + │ │ │ │ │ + A region object describes an area. │ │ │ │ │ + │ │ │ │ │ + Region objects are used to describe the opaque and input regions of │ │ │ │ │ + a surface. │ │ │ │ │ + │ │ │ │ │ + destroy() -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Destroy region │ │ │ │ │ + │ │ │ │ │ + Destroy the region. This will invalidate the object ID. │ │ │ │ │ + │ │ │ │ │ + add(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Add rectangle to region │ │ │ │ │ + │ │ │ │ │ + Add the specified rectangle to the region. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **x** (*ArgumentType.Int*) -- region-local x coordinate │ │ │ │ │ + │ │ │ │ │ + * **y** (*ArgumentType.Int*) -- region-local y coordinate │ │ │ │ │ + │ │ │ │ │ + * **width** (*ArgumentType.Int*) -- rectangle width │ │ │ │ │ + │ │ │ │ │ + * **height** (*ArgumentType.Int*) -- rectangle height │ │ │ │ │ + │ │ │ │ │ + subtract(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 2 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Subtract rectangle from region │ │ │ │ │ + │ │ │ │ │ + Subtract the specified rectangle from the region. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + * **x** (*ArgumentType.Int*) -- region-local x coordinate │ │ │ │ │ + │ │ │ │ │ + * **y** (*ArgumentType.Int*) -- region-local y coordinate │ │ │ │ │ + │ │ │ │ │ + * **width** (*ArgumentType.Int*) -- rectangle width │ │ │ │ │ + │ │ │ │ │ + * **height** (*ArgumentType.Int*) -- rectangle height │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ +WlDataDeviceManager │ │ │ │ │ +=================== │ │ │ │ │ + │ │ │ │ │ +class pywayland.protocol.wayland.WlDataDeviceManager │ │ │ │ │ + │ │ │ │ │ + Data transfer interface │ │ │ │ │ + │ │ │ │ │ + The "WlDataDeviceManager" is a singleton global object that │ │ │ │ │ + provides access to inter-client data transfer mechanisms such as │ │ │ │ │ + copy-and-paste and drag-and-drop. These mechanisms are tied to a │ │ │ │ │ + "WlSeat" and this interface lets a client get a "WlDataDevice" │ │ │ │ │ + corresponding to a "WlSeat". │ │ │ │ │ + │ │ │ │ │ + Depending on the version bound, the objects created from the bound │ │ │ │ │ + "WlDataDeviceManager" object will have different requirements for │ │ │ │ │ + functioning properly. See "WlDataSource.set_actions()", │ │ │ │ │ + "WlDataOffer.accept()" and "WlDataOffer.finish()" for details. │ │ │ │ │ + │ │ │ │ │ + create_data_source() -> 'Proxy[WlDataSource]' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Create a new data source │ │ │ │ │ + │ │ │ │ │ + Create a new data source. │ │ │ │ │ + │ │ │ │ │ + Returns: │ │ │ │ │ + "WlDataSource" -- data source to create │ │ │ │ │ + │ │ │ │ │ + get_data_device(seat: 'WlSeat') -> 'Proxy[WlDataDevice]' │ │ │ │ │ + │ │ │ │ │ + -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ + │ │ │ │ │ + Create a new data device │ │ │ │ │ + │ │ │ │ │ + Create a new data device for a given seat. │ │ │ │ │ + │ │ │ │ │ + Parameters: │ │ │ │ │ + **seat** ("WlSeat") -- seat associated with the data device │ │ │ │ │ + │ │ │ │ │ + Returns: │ │ │ │ │ + "WlDataDevice" -- data device to create │ │ │ │ │ + │ │ │ │ │ + │ │ │ │ │ WlShellSurface │ │ │ │ │ ============== │ │ │ │ │ │ │ │ │ │ class pywayland.protocol.wayland.WlShellSurface │ │ │ │ │ │ │ │ │ │ Desktop-style metadata interface │ │ │ │ │ │ │ │ │ │ @@ -1760,684 +2986,14 @@ │ │ │ │ │ sub- surface may override it to behave as synchronized. For │ │ │ │ │ details, see "WlSubsurface". │ │ │ │ │ │ │ │ │ │ If a surface's parent surface behaves as desynchronized, then │ │ │ │ │ the cached state is applied on set_desync. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -WlShm │ │ │ │ │ -===== │ │ │ │ │ - │ │ │ │ │ -class pywayland.protocol.wayland.WlShm │ │ │ │ │ - │ │ │ │ │ - Shared memory support │ │ │ │ │ - │ │ │ │ │ - A singleton global object that provides support for shared memory. │ │ │ │ │ - │ │ │ │ │ - Clients can create "WlShmPool" objects using the create_pool │ │ │ │ │ - request. │ │ │ │ │ - │ │ │ │ │ - On binding the "WlShm" object one or more format events are emitted │ │ │ │ │ - to inform clients about the valid pixel formats that can be used │ │ │ │ │ - for buffers. │ │ │ │ │ - │ │ │ │ │ - create_pool(fd: 'int', size: 'int') -> 'Proxy[WlShmPool]' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Create a shm pool │ │ │ │ │ - │ │ │ │ │ - Create a new "WlShmPool" object. │ │ │ │ │ - │ │ │ │ │ - The pool can be used to create shared memory based buffer │ │ │ │ │ - objects. The server will mmap size bytes of the passed file │ │ │ │ │ - descriptor, to use as backing memory for the pool. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **fd** (*ArgumentType.FileDescriptor*) -- file descriptor │ │ │ │ │ - for the pool │ │ │ │ │ - │ │ │ │ │ - * **size** (*ArgumentType.Int*) -- pool size, in bytes │ │ │ │ │ - │ │ │ │ │ - Returns: │ │ │ │ │ - "WlShmPool" -- pool to create │ │ │ │ │ - │ │ │ │ │ - release() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Release the shm object │ │ │ │ │ - │ │ │ │ │ - Using this request a client can tell the server that it is not │ │ │ │ │ - going to use the shm object anymore. │ │ │ │ │ - │ │ │ │ │ - Objects created via this interface remain unaffected. │ │ │ │ │ - │ │ │ │ │ - format(format: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Pixel format description │ │ │ │ │ - │ │ │ │ │ - Informs the client about a valid pixel format that can be used │ │ │ │ │ - for buffers. Known formats include argb8888 and xrgb8888. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - **format** (*ArgumentType.Uint*) -- buffer pixel format │ │ │ │ │ - │ │ │ │ │ - │ │ │ │ │ -WlKeyboard │ │ │ │ │ -========== │ │ │ │ │ - │ │ │ │ │ -class pywayland.protocol.wayland.WlKeyboard │ │ │ │ │ - │ │ │ │ │ - Keyboard input device │ │ │ │ │ - │ │ │ │ │ - The "WlKeyboard" interface represents one or more keyboards │ │ │ │ │ - associated with a seat. │ │ │ │ │ - │ │ │ │ │ - Each "WlKeyboard" has the following logical state: │ │ │ │ │ - │ │ │ │ │ - * an active surface (possibly null), │ │ │ │ │ - │ │ │ │ │ - * the keys currently logically down, │ │ │ │ │ - │ │ │ │ │ - * the active modifiers, │ │ │ │ │ - │ │ │ │ │ - * the active group. │ │ │ │ │ - │ │ │ │ │ - By default, the active surface is null, the keys currently │ │ │ │ │ - logically down are empty, the active modifiers and the active group │ │ │ │ │ - are 0. │ │ │ │ │ - │ │ │ │ │ - release() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Release the keyboard object │ │ │ │ │ - │ │ │ │ │ - keymap(format: 'int', fd: 'int', size: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Keyboard mapping │ │ │ │ │ - │ │ │ │ │ - This event provides a file descriptor to the client which can be │ │ │ │ │ - memory-mapped in read-only mode to provide a keyboard mapping │ │ │ │ │ - description. │ │ │ │ │ - │ │ │ │ │ - From version 7 onwards, the fd must be mapped with MAP_PRIVATE │ │ │ │ │ - by the recipient, as MAP_SHARED may fail. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **format** (*ArgumentType.Uint*) -- keymap format │ │ │ │ │ - │ │ │ │ │ - * **fd** (*ArgumentType.FileDescriptor*) -- keymap file │ │ │ │ │ - descriptor │ │ │ │ │ - │ │ │ │ │ - * **size** (*ArgumentType.Uint*) -- keymap size, in bytes │ │ │ │ │ - │ │ │ │ │ - enter(serial: 'int', surface: 'WlSurface', keys: 'list') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Enter event │ │ │ │ │ - │ │ │ │ │ - Notification that this seat's keyboard focus is on a certain │ │ │ │ │ - surface. │ │ │ │ │ - │ │ │ │ │ - The compositor must send the "WlKeyboard.modifiers()" event │ │ │ │ │ - after this event. │ │ │ │ │ - │ │ │ │ │ - In the "WlKeyboard" logical state, this event sets the active │ │ │ │ │ - surface to the surface argument and the keys currently logically │ │ │ │ │ - down to the keys in the keys argument. The compositor must not │ │ │ │ │ - send this event if the "WlKeyboard" already had an active │ │ │ │ │ - surface immediately before this event. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ - enter event │ │ │ │ │ - │ │ │ │ │ - * **surface** ("WlSurface") -- surface gaining keyboard focus │ │ │ │ │ - │ │ │ │ │ - * **keys** (*ArgumentType.Array*) -- the keys currently │ │ │ │ │ - logically down │ │ │ │ │ - │ │ │ │ │ - leave(serial: 'int', surface: 'WlSurface') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 2 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Leave event │ │ │ │ │ - │ │ │ │ │ - Notification that this seat's keyboard focus is no longer on a │ │ │ │ │ - certain surface. │ │ │ │ │ - │ │ │ │ │ - The leave notification is sent before the enter notification for │ │ │ │ │ - the new focus. │ │ │ │ │ - │ │ │ │ │ - In the "WlKeyboard" logical state, this event resets all values │ │ │ │ │ - to their defaults. The compositor must not send this event if │ │ │ │ │ - the active surface of the "WlKeyboard" was not equal to the │ │ │ │ │ - surface argument immediately before this event. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ - leave event │ │ │ │ │ - │ │ │ │ │ - * **surface** ("WlSurface") -- surface that lost keyboard │ │ │ │ │ - focus │ │ │ │ │ - │ │ │ │ │ - key(serial: 'int', time: 'int', key: 'int', state: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Key event │ │ │ │ │ - │ │ │ │ │ - A key was pressed or released. The time argument is a timestamp │ │ │ │ │ - with millisecond granularity, with an undefined base. │ │ │ │ │ - │ │ │ │ │ - The key is a platform-specific key code that can be interpreted │ │ │ │ │ - by feeding it to the keyboard mapping (see the keymap event). │ │ │ │ │ - │ │ │ │ │ - If this event produces a change in modifiers, then the resulting │ │ │ │ │ - "WlKeyboard.modifiers()" event must be sent after this event. │ │ │ │ │ - │ │ │ │ │ - In the "WlKeyboard" logical state, this event adds the key to │ │ │ │ │ - the keys currently logically down (if the state argument is │ │ │ │ │ - pressed) or removes the key from the keys currently logically │ │ │ │ │ - down (if the state argument is released). The compositor must │ │ │ │ │ - not send this event if the "WlKeyboard" did not have an active │ │ │ │ │ - surface immediately before this event. The compositor must not │ │ │ │ │ - send this event if state is pressed (resp. released) and the key │ │ │ │ │ - was already logically down (resp. was not logically down) │ │ │ │ │ - immediately before this event. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ - key event │ │ │ │ │ - │ │ │ │ │ - * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ - millisecond granularity │ │ │ │ │ - │ │ │ │ │ - * **key** (*ArgumentType.Uint*) -- key that produced the │ │ │ │ │ - event │ │ │ │ │ - │ │ │ │ │ - * **state** (*ArgumentType.Uint*) -- physical state of the │ │ │ │ │ - key │ │ │ │ │ - │ │ │ │ │ - modifiers(serial: 'int', mods_depressed: 'int', mods_latched: 'int', mods_locked: 'int', group: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 4 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Modifier and group state │ │ │ │ │ - │ │ │ │ │ - Notifies clients that the modifier and/or group state has │ │ │ │ │ - changed, and it should update its local state. │ │ │ │ │ - │ │ │ │ │ - The compositor may send this event without a surface of the │ │ │ │ │ - client having keyboard focus, for example to tie modifier │ │ │ │ │ - information to pointer focus instead. If a modifier event with │ │ │ │ │ - pressed modifiers is sent without a prior enter event, the │ │ │ │ │ - client can assume the modifier state is valid until it receives │ │ │ │ │ - the next "WlKeyboard.modifiers()" event. In order to reset the │ │ │ │ │ - modifier state again, the compositor can send a │ │ │ │ │ - "WlKeyboard.modifiers()" event with no pressed modifiers. │ │ │ │ │ - │ │ │ │ │ - In the "WlKeyboard" logical state, this event updates the │ │ │ │ │ - modifiers and group. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ - modifiers event │ │ │ │ │ - │ │ │ │ │ - * **mods_depressed** (*ArgumentType.Uint*) -- depressed │ │ │ │ │ - modifiers │ │ │ │ │ - │ │ │ │ │ - * **mods_latched** (*ArgumentType.Uint*) -- latched modifiers │ │ │ │ │ - │ │ │ │ │ - * **mods_locked** (*ArgumentType.Uint*) -- locked modifiers │ │ │ │ │ - │ │ │ │ │ - * **group** (*ArgumentType.Uint*) -- keyboard layout │ │ │ │ │ - │ │ │ │ │ - repeat_info(rate: 'int', delay: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 5 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Repeat rate and delay │ │ │ │ │ - │ │ │ │ │ - Informs the client about the keyboard's repeat rate and delay. │ │ │ │ │ - │ │ │ │ │ - This event is sent as soon as the "WlKeyboard" object has been │ │ │ │ │ - created, and is guaranteed to be received by the client before │ │ │ │ │ - any key press event. │ │ │ │ │ - │ │ │ │ │ - Negative values for either rate or delay are illegal. A rate of │ │ │ │ │ - zero will disable any repeating (regardless of the value of │ │ │ │ │ - delay). │ │ │ │ │ - │ │ │ │ │ - This event can be sent later on as well with a new value if │ │ │ │ │ - necessary, so clients should continue listening for the event │ │ │ │ │ - past the creation of "WlKeyboard". │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **rate** (*ArgumentType.Int*) -- the rate of repeating keys │ │ │ │ │ - in characters per second │ │ │ │ │ - │ │ │ │ │ - * **delay** (*ArgumentType.Int*) -- delay in milliseconds │ │ │ │ │ - since key down until repeating starts │ │ │ │ │ - │ │ │ │ │ - │ │ │ │ │ -WlTouch │ │ │ │ │ -======= │ │ │ │ │ - │ │ │ │ │ -class pywayland.protocol.wayland.WlTouch │ │ │ │ │ - │ │ │ │ │ - Touchscreen input device │ │ │ │ │ - │ │ │ │ │ - The "WlTouch" interface represents a touchscreen associated with a │ │ │ │ │ - seat. │ │ │ │ │ - │ │ │ │ │ - Touch interactions can consist of one or more contacts. For each │ │ │ │ │ - contact, a series of events is generated, starting with a down │ │ │ │ │ - event, followed by zero or more motion events, and ending with an │ │ │ │ │ - up event. Events relating to the same contact point can be │ │ │ │ │ - identified by the ID of the sequence. │ │ │ │ │ - │ │ │ │ │ - release() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Release the touch object │ │ │ │ │ - │ │ │ │ │ - down(serial: 'int', time: 'int', surface: 'WlSurface', id: 'int', x: 'float', y: 'float') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Touch down event and beginning of a touch sequence │ │ │ │ │ - │ │ │ │ │ - A new touch point has appeared on the surface. This touch point │ │ │ │ │ - is assigned a unique ID. Future events from this touch point │ │ │ │ │ - reference this ID. The ID ceases to be valid after a touch up │ │ │ │ │ - event and may be reused in the future. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ - touch down event │ │ │ │ │ - │ │ │ │ │ - * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ - millisecond granularity │ │ │ │ │ - │ │ │ │ │ - * **surface** ("WlSurface") -- surface touched │ │ │ │ │ - │ │ │ │ │ - * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ - point │ │ │ │ │ - │ │ │ │ │ - * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate │ │ │ │ │ - │ │ │ │ │ - * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate │ │ │ │ │ - │ │ │ │ │ - up(serial: 'int', time: 'int', id: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - End of a touch event sequence │ │ │ │ │ - │ │ │ │ │ - The touch point has disappeared. No further events will be sent │ │ │ │ │ - for this touch point and the touch point's ID is released and │ │ │ │ │ - may be reused in a future touch down event. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ - touch up event │ │ │ │ │ - │ │ │ │ │ - * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ - millisecond granularity │ │ │ │ │ - │ │ │ │ │ - * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ - point │ │ │ │ │ - │ │ │ │ │ - motion(time: 'int', id: 'int', x: 'float', y: 'float') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 2 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Update of touch point coordinates │ │ │ │ │ - │ │ │ │ │ - A touch point has changed coordinates. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ - millisecond granularity │ │ │ │ │ - │ │ │ │ │ - * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ - point │ │ │ │ │ - │ │ │ │ │ - * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate │ │ │ │ │ - │ │ │ │ │ - * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate │ │ │ │ │ - │ │ │ │ │ - frame() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - End of touch frame event │ │ │ │ │ - │ │ │ │ │ - Indicates the end of a set of events that logically belong │ │ │ │ │ - together. A client is expected to accumulate the data in all │ │ │ │ │ - events within the frame before proceeding. │ │ │ │ │ - │ │ │ │ │ - A "WlTouch.frame()" terminates at least one event but otherwise │ │ │ │ │ - no guarantee is provided about the set of events within a frame. │ │ │ │ │ - A client must assume that any state not updated in a frame is │ │ │ │ │ - unchanged from the previously known state. │ │ │ │ │ - │ │ │ │ │ - cancel() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 4 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Touch session cancelled │ │ │ │ │ - │ │ │ │ │ - Sent if the compositor decides the touch stream is a global │ │ │ │ │ - gesture. No further events are sent to the clients from that │ │ │ │ │ - particular gesture. Touch cancellation applies to all touch │ │ │ │ │ - points currently active on this client's surface. The client is │ │ │ │ │ - responsible for finalizing the touch points, future touch points │ │ │ │ │ - on this surface may reuse the touch point ID. │ │ │ │ │ - │ │ │ │ │ - No frame event is required after the cancel event. │ │ │ │ │ - │ │ │ │ │ - shape(id: 'int', major: 'float', minor: 'float') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 5 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Update shape of touch point │ │ │ │ │ - │ │ │ │ │ - Sent when a touchpoint has changed its shape. │ │ │ │ │ - │ │ │ │ │ - This event does not occur on its own. It is sent before a │ │ │ │ │ - "WlTouch.frame()" event and carries the new shape information │ │ │ │ │ - for any previously reported, or new touch points of that frame. │ │ │ │ │ - │ │ │ │ │ - Other events describing the touch point such as │ │ │ │ │ - "WlTouch.down()", "WlTouch.motion()" or "WlTouch.orientation()" │ │ │ │ │ - may be sent within the same "WlTouch.frame()". A client should │ │ │ │ │ - treat these events as a single logical touch point update. The │ │ │ │ │ - order of "WlTouch.shape()", "WlTouch.orientation()" and │ │ │ │ │ - "WlTouch.motion()" is not guaranteed. A "WlTouch.down()" event │ │ │ │ │ - is guaranteed to occur before the first "WlTouch.shape()" event │ │ │ │ │ - for this touch ID but both events may occur within the same │ │ │ │ │ - "WlTouch.frame()". │ │ │ │ │ - │ │ │ │ │ - A touchpoint shape is approximated by an ellipse through the │ │ │ │ │ - major and minor axis length. The major axis length describes the │ │ │ │ │ - longer diameter of the ellipse, while the minor axis length │ │ │ │ │ - describes the shorter diameter. Major and minor are orthogonal │ │ │ │ │ - and both are specified in surface-local coordinates. The center │ │ │ │ │ - of the ellipse is always at the touchpoint location as reported │ │ │ │ │ - by "WlTouch.down()" or "WlTouch.move()". │ │ │ │ │ - │ │ │ │ │ - This event is only sent by the compositor if the touch device │ │ │ │ │ - supports shape reports. The client has to make reasonable │ │ │ │ │ - assumptions about the shape if it did not receive this event. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ - point │ │ │ │ │ - │ │ │ │ │ - * **major** (*ArgumentType.Fixed*) -- length of the major │ │ │ │ │ - axis in surface-local coordinates │ │ │ │ │ - │ │ │ │ │ - * **minor** (*ArgumentType.Fixed*) -- length of the minor │ │ │ │ │ - axis in surface-local coordinates │ │ │ │ │ - │ │ │ │ │ - orientation(id: 'int', orientation: 'float') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 6 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Update orientation of touch point │ │ │ │ │ - │ │ │ │ │ - Sent when a touchpoint has changed its orientation. │ │ │ │ │ - │ │ │ │ │ - This event does not occur on its own. It is sent before a │ │ │ │ │ - "WlTouch.frame()" event and carries the new shape information │ │ │ │ │ - for any previously reported, or new touch points of that frame. │ │ │ │ │ - │ │ │ │ │ - Other events describing the touch point such as │ │ │ │ │ - "WlTouch.down()", "WlTouch.motion()" or "WlTouch.shape()" may be │ │ │ │ │ - sent within the same "WlTouch.frame()". A client should treat │ │ │ │ │ - these events as a single logical touch point update. The order │ │ │ │ │ - of "WlTouch.shape()", "WlTouch.orientation()" and │ │ │ │ │ - "WlTouch.motion()" is not guaranteed. A "WlTouch.down()" event │ │ │ │ │ - is guaranteed to occur before the first "WlTouch.orientation()" │ │ │ │ │ - event for this touch ID but both events may occur within the │ │ │ │ │ - same "WlTouch.frame()". │ │ │ │ │ - │ │ │ │ │ - The orientation describes the clockwise angle of a touchpoint's │ │ │ │ │ - major axis to the positive surface y-axis and is normalized to │ │ │ │ │ - the -180 to +180 degree range. The granularity of orientation │ │ │ │ │ - depends on the touch device, some devices only support binary │ │ │ │ │ - rotation values between 0 and 90 degrees. │ │ │ │ │ - │ │ │ │ │ - This event is only sent by the compositor if the touch device │ │ │ │ │ - supports orientation reports. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **id** (*ArgumentType.Int*) -- the unique ID of this touch │ │ │ │ │ - point │ │ │ │ │ - │ │ │ │ │ - * **orientation** (*ArgumentType.Fixed*) -- angle between │ │ │ │ │ - major axis and positive surface y-axis in degrees │ │ │ │ │ - │ │ │ │ │ - │ │ │ │ │ -WlDataDevice │ │ │ │ │ -============ │ │ │ │ │ - │ │ │ │ │ -class pywayland.protocol.wayland.WlDataDevice │ │ │ │ │ - │ │ │ │ │ - Data transfer device │ │ │ │ │ - │ │ │ │ │ - There is one "WlDataDevice" per seat which can be obtained from the │ │ │ │ │ - global "WlDataDeviceManager" singleton. │ │ │ │ │ - │ │ │ │ │ - A "WlDataDevice" provides access to inter-client data transfer │ │ │ │ │ - mechanisms such as copy-and-paste and drag-and-drop. │ │ │ │ │ - │ │ │ │ │ - start_drag(source: 'WlDataSource | None', origin: 'WlSurface', icon: 'WlSurface | None', serial: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Start drag-and-drop operation │ │ │ │ │ - │ │ │ │ │ - This request asks the compositor to start a drag-and-drop │ │ │ │ │ - operation on behalf of the client. │ │ │ │ │ - │ │ │ │ │ - The source argument is the data source that provides the data │ │ │ │ │ - for the eventual data transfer. If source is NULL, enter, leave │ │ │ │ │ - and motion events are sent only to the client that initiated the │ │ │ │ │ - drag and the client is expected to handle the data passing │ │ │ │ │ - internally. If source is destroyed, the drag-and-drop session │ │ │ │ │ - will be cancelled. │ │ │ │ │ - │ │ │ │ │ - The origin surface is the surface where the drag originates and │ │ │ │ │ - the client must have an active implicit grab that matches the │ │ │ │ │ - serial. │ │ │ │ │ - │ │ │ │ │ - The icon surface is an optional (can be NULL) surface that │ │ │ │ │ - provides an icon to be moved around with the cursor. Initially, │ │ │ │ │ - the top-left corner of the icon surface is placed at the cursor │ │ │ │ │ - hotspot, but subsequent "WlSurface.offset()" requests can move │ │ │ │ │ - the relative position. Attach requests must be confirmed with │ │ │ │ │ - "WlSurface.commit()" as usual. The icon surface is given the │ │ │ │ │ - role of a drag-and-drop icon. If the icon surface already has │ │ │ │ │ - another role, it raises a protocol error. │ │ │ │ │ - │ │ │ │ │ - The input region is ignored for wl_surfaces with the role of a │ │ │ │ │ - drag- and-drop icon. │ │ │ │ │ - │ │ │ │ │ - The given source may not be used in any further set_selection or │ │ │ │ │ - start_drag requests. Attempting to reuse a previously-used │ │ │ │ │ - source may send a used_source error. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **source** ("WlDataSource" or *None*) -- data source for │ │ │ │ │ - the eventual transfer │ │ │ │ │ - │ │ │ │ │ - * **origin** ("WlSurface") -- surface where the drag │ │ │ │ │ - originates │ │ │ │ │ - │ │ │ │ │ - * **icon** ("WlSurface" or *None*) -- drag-and-drop icon │ │ │ │ │ - surface │ │ │ │ │ - │ │ │ │ │ - * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ - implicit grab on the origin │ │ │ │ │ - │ │ │ │ │ - set_selection(source: 'WlDataSource | None', serial: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Copy data to the selection │ │ │ │ │ - │ │ │ │ │ - This request asks the compositor to set the selection to the │ │ │ │ │ - data from the source on behalf of the client. │ │ │ │ │ - │ │ │ │ │ - To unset the selection, set the source to NULL. │ │ │ │ │ - │ │ │ │ │ - The given source may not be used in any further set_selection or │ │ │ │ │ - start_drag requests. Attempting to reuse a previously-used │ │ │ │ │ - source may send a used_source error. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **source** ("WlDataSource" or *None*) -- data source for │ │ │ │ │ - the selection │ │ │ │ │ - │ │ │ │ │ - * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ - event that triggered this request │ │ │ │ │ - │ │ │ │ │ - release() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 2 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Destroy data device │ │ │ │ │ - │ │ │ │ │ - This request destroys the data device. │ │ │ │ │ - │ │ │ │ │ - data_offer(id: 'WlDataOffer') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Introduce a new "WlDataOffer" │ │ │ │ │ - │ │ │ │ │ - The data_offer event introduces a new "WlDataOffer" object, │ │ │ │ │ - which will subsequently be used in either the data_device.enter │ │ │ │ │ - event (for drag- and-drop) or the data_device.selection event │ │ │ │ │ - (for selections). Immediately following the │ │ │ │ │ - data_device.data_offer event, the new data_offer object will │ │ │ │ │ - send out data_offer.offer events to describe the mime types it │ │ │ │ │ - offers. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - **id** ("WlDataOffer") -- the new data_offer object │ │ │ │ │ - │ │ │ │ │ - enter(serial: 'int', surface: 'WlSurface', x: 'float', y: 'float', id: 'WlDataOffer | None') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Initiate drag-and-drop session │ │ │ │ │ - │ │ │ │ │ - This event is sent when an active drag-and-drop pointer enters a │ │ │ │ │ - surface owned by the client. The position of the pointer at │ │ │ │ │ - enter time is provided by the x and y arguments, in surface- │ │ │ │ │ - local coordinates. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **serial** (*ArgumentType.Uint*) -- serial number of the │ │ │ │ │ - enter event │ │ │ │ │ - │ │ │ │ │ - * **surface** ("WlSurface") -- client surface entered │ │ │ │ │ - │ │ │ │ │ - * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate │ │ │ │ │ - │ │ │ │ │ - * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate │ │ │ │ │ - │ │ │ │ │ - * **id** ("WlDataOffer" or *None*) -- source data_offer │ │ │ │ │ - object │ │ │ │ │ - │ │ │ │ │ - leave() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 2 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - End drag-and-drop session │ │ │ │ │ - │ │ │ │ │ - This event is sent when the drag-and-drop pointer leaves the │ │ │ │ │ - surface and the session ends. The client must destroy the │ │ │ │ │ - "WlDataOffer" introduced at enter time at this point. │ │ │ │ │ - │ │ │ │ │ - motion(time: 'int', x: 'float', y: 'float') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Drag-and-drop session motion │ │ │ │ │ - │ │ │ │ │ - This event is sent when the drag-and-drop pointer moves within │ │ │ │ │ - the currently focused surface. The new position of the pointer │ │ │ │ │ - is provided by the x and y arguments, in surface-local │ │ │ │ │ - coordinates. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **time** (*ArgumentType.Uint*) -- timestamp with │ │ │ │ │ - millisecond granularity │ │ │ │ │ - │ │ │ │ │ - * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate │ │ │ │ │ - │ │ │ │ │ - * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate │ │ │ │ │ - │ │ │ │ │ - drop() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 4 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - End drag-and-drop session successfully │ │ │ │ │ - │ │ │ │ │ - The event is sent when a drag-and-drop operation is ended │ │ │ │ │ - because the implicit grab is removed. │ │ │ │ │ - │ │ │ │ │ - The drag-and-drop destination is expected to honor the last │ │ │ │ │ - action received through "WlDataOffer.action()", if the resulting │ │ │ │ │ - action is "copy" or "move", the destination can still perform │ │ │ │ │ - "WlDataOffer.receive()" requests, and is expected to end all │ │ │ │ │ - transfers with a "WlDataOffer.finish()" request. │ │ │ │ │ - │ │ │ │ │ - If the resulting action is "ask", the action will not be │ │ │ │ │ - considered final. The drag-and-drop destination is expected to │ │ │ │ │ - perform one last "WlDataOffer.set_actions()" request, or │ │ │ │ │ - "WlDataOffer.destroy()" in order to cancel the operation. │ │ │ │ │ - │ │ │ │ │ - selection(id: 'WlDataOffer | None') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 5 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Advertise new selection │ │ │ │ │ - │ │ │ │ │ - The selection event is sent out to notify the client of a new │ │ │ │ │ - "WlDataOffer" for the selection for this device. The │ │ │ │ │ - data_device.data_offer and the data_offer.offer events are sent │ │ │ │ │ - out immediately before this event to introduce the data offer │ │ │ │ │ - object. The selection event is sent to a client immediately │ │ │ │ │ - before receiving keyboard focus and when a new selection is set │ │ │ │ │ - while the client has keyboard focus. The data_offer is valid │ │ │ │ │ - until a new data_offer or NULL is received or until the client │ │ │ │ │ - loses keyboard focus. Switching surface with keyboard focus │ │ │ │ │ - within the same client doesn't mean a new selection will be │ │ │ │ │ - sent. The client must destroy the previous selection │ │ │ │ │ - data_offer, if any, upon receiving this event. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - **id** ("WlDataOffer" or *None*) -- selection data_offer │ │ │ │ │ - object │ │ │ │ │ - │ │ │ │ │ - │ │ │ │ │ WlPointer │ │ │ │ │ ========= │ │ │ │ │ │ │ │ │ │ class pywayland.protocol.wayland.WlPointer │ │ │ │ │ │ │ │ │ │ Pointer input device │ │ │ │ │ │ │ │ │ │ @@ -2871,48 +3427,14 @@ │ │ │ │ │ Parameters: │ │ │ │ │ * **axis** (*ArgumentType.Uint*) -- axis type │ │ │ │ │ │ │ │ │ │ * **direction** (*ArgumentType.Uint*) -- physical direction │ │ │ │ │ relative to axis motion │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -WlCompositor │ │ │ │ │ -============ │ │ │ │ │ - │ │ │ │ │ -class pywayland.protocol.wayland.WlCompositor │ │ │ │ │ - │ │ │ │ │ - The compositor singleton │ │ │ │ │ - │ │ │ │ │ - A compositor. This object is a singleton global. The compositor │ │ │ │ │ - is in charge of combining the contents of multiple surfaces into │ │ │ │ │ - one displayable output. │ │ │ │ │ - │ │ │ │ │ - create_surface() -> 'Proxy[WlSurface]' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Create new surface │ │ │ │ │ - │ │ │ │ │ - Ask the compositor to create a new surface. │ │ │ │ │ - │ │ │ │ │ - Returns: │ │ │ │ │ - "WlSurface" -- the new surface │ │ │ │ │ - │ │ │ │ │ - create_region() -> 'Proxy[WlRegion]' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Create new region │ │ │ │ │ - │ │ │ │ │ - Ask the compositor to create a new region. │ │ │ │ │ - │ │ │ │ │ - Returns: │ │ │ │ │ - "WlRegion" -- the new region │ │ │ │ │ - │ │ │ │ │ - │ │ │ │ │ WlShell │ │ │ │ │ ======= │ │ │ │ │ │ │ │ │ │ class pywayland.protocol.wayland.WlShell │ │ │ │ │ │ │ │ │ │ Create desktop-style surfaces │ │ │ │ │ │ │ │ │ │ @@ -3028,529 +3550,7 @@ │ │ │ │ │ When a client deletes an object that it had created, the server │ │ │ │ │ will send this event to acknowledge that it has seen the delete │ │ │ │ │ request. When the client receives this event, it will know that │ │ │ │ │ it can safely reuse the object ID. │ │ │ │ │ │ │ │ │ │ Parameters: │ │ │ │ │ **id** (*ArgumentType.Uint*) -- deleted object ID │ │ │ │ │ - │ │ │ │ │ - │ │ │ │ │ -WlOutput │ │ │ │ │ -======== │ │ │ │ │ - │ │ │ │ │ -class pywayland.protocol.wayland.WlOutput │ │ │ │ │ - │ │ │ │ │ - Compositor output region │ │ │ │ │ - │ │ │ │ │ - An output describes part of the compositor geometry. The │ │ │ │ │ - compositor works in the 'compositor coordinate system' and an │ │ │ │ │ - output corresponds to a rectangular area in that space that is │ │ │ │ │ - actually visible. This typically corresponds to a monitor that │ │ │ │ │ - displays part of the compositor space. This object is published as │ │ │ │ │ - global during start up, or when a monitor is hotplugged. │ │ │ │ │ - │ │ │ │ │ - release() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Release the output object │ │ │ │ │ - │ │ │ │ │ - Using this request a client can tell the server that it is not │ │ │ │ │ - going to use the output object anymore. │ │ │ │ │ - │ │ │ │ │ - geometry(x: 'int', y: 'int', physical_width: 'int', physical_height: 'int', subpixel: 'int', make: 'str', model: 'str', transform: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Properties of the output │ │ │ │ │ - │ │ │ │ │ - The geometry event describes geometric properties of the output. │ │ │ │ │ - The event is sent when binding to the output object and whenever │ │ │ │ │ - any of the properties change. │ │ │ │ │ - │ │ │ │ │ - The physical size can be set to zero if it doesn't make sense │ │ │ │ │ - for this output (e.g. for projectors or virtual outputs). │ │ │ │ │ - │ │ │ │ │ - The geometry event will be followed by a done event (starting │ │ │ │ │ - from version 2). │ │ │ │ │ - │ │ │ │ │ - Clients should use "WlSurface.preferred_buffer_transform()" │ │ │ │ │ - instead of the transform advertised by this event to find the │ │ │ │ │ - preferred buffer transform to use for a surface. │ │ │ │ │ - │ │ │ │ │ - Note: "WlOutput" only advertises partial information about the │ │ │ │ │ - output position and identification. Some compositors, for │ │ │ │ │ - instance those not implementing a desktop-style output layout or │ │ │ │ │ - those exposing virtual outputs, might fake this information. │ │ │ │ │ - Instead of using x and y, clients should use │ │ │ │ │ - xdg_output.logical_position. Instead of using make and model, │ │ │ │ │ - clients should use name and description. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **x** (*ArgumentType.Int*) -- x position within the global │ │ │ │ │ - compositor space │ │ │ │ │ - │ │ │ │ │ - * **y** (*ArgumentType.Int*) -- y position within the global │ │ │ │ │ - compositor space │ │ │ │ │ - │ │ │ │ │ - * **physical_width** (*ArgumentType.Int*) -- width in │ │ │ │ │ - millimeters of the output │ │ │ │ │ - │ │ │ │ │ - * **physical_height** (*ArgumentType.Int*) -- height in │ │ │ │ │ - millimeters of the output │ │ │ │ │ - │ │ │ │ │ - * **subpixel** (*ArgumentType.Int*) -- subpixel orientation │ │ │ │ │ - of the output │ │ │ │ │ - │ │ │ │ │ - * **make** (*ArgumentType.String*) -- textual description of │ │ │ │ │ - the manufacturer │ │ │ │ │ - │ │ │ │ │ - * **model** (*ArgumentType.String*) -- textual description of │ │ │ │ │ - the model │ │ │ │ │ - │ │ │ │ │ - * **transform** (*ArgumentType.Int*) -- additional │ │ │ │ │ - transformation applied to buffer contents during │ │ │ │ │ - presentation │ │ │ │ │ - │ │ │ │ │ - mode(flags: 'int', width: 'int', height: 'int', refresh: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Advertise available modes for the output │ │ │ │ │ - │ │ │ │ │ - The mode event describes an available mode for the output. │ │ │ │ │ - │ │ │ │ │ - The event is sent when binding to the output object and there │ │ │ │ │ - will always be one mode, the current mode. The event is sent │ │ │ │ │ - again if an output changes mode, for the mode that is now │ │ │ │ │ - current. In other words, the current mode is always the last │ │ │ │ │ - mode that was received with the current flag set. │ │ │ │ │ - │ │ │ │ │ - Non-current modes are deprecated. A compositor can decide to │ │ │ │ │ - only advertise the current mode and never send other modes. │ │ │ │ │ - Clients should not rely on non-current modes. │ │ │ │ │ - │ │ │ │ │ - The size of a mode is given in physical hardware units of the │ │ │ │ │ - output device. This is not necessarily the same as the output │ │ │ │ │ - size in the global compositor space. For instance, the output │ │ │ │ │ - may be scaled, as described in "WlOutput.scale()", or │ │ │ │ │ - transformed, as described in "WlOutput.transform()". Clients │ │ │ │ │ - willing to retrieve the output size in the global compositor │ │ │ │ │ - space should use xdg_output.logical_size instead. │ │ │ │ │ - │ │ │ │ │ - The vertical refresh rate can be set to zero if it doesn't make │ │ │ │ │ - sense for this output (e.g. for virtual outputs). │ │ │ │ │ - │ │ │ │ │ - The mode event will be followed by a done event (starting from │ │ │ │ │ - version 2). │ │ │ │ │ - │ │ │ │ │ - Clients should not use the refresh rate to schedule frames. │ │ │ │ │ - Instead, they should use the "WlSurface.frame()" event or the │ │ │ │ │ - presentation-time protocol. │ │ │ │ │ - │ │ │ │ │ - Note: this information is not always meaningful for all outputs. │ │ │ │ │ - Some compositors, such as those exposing virtual outputs, might │ │ │ │ │ - fake the refresh rate or the size. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **flags** (*ArgumentType.Uint*) -- bitfield of mode flags │ │ │ │ │ - │ │ │ │ │ - * **width** (*ArgumentType.Int*) -- width of the mode in │ │ │ │ │ - hardware units │ │ │ │ │ - │ │ │ │ │ - * **height** (*ArgumentType.Int*) -- height of the mode in │ │ │ │ │ - hardware units │ │ │ │ │ - │ │ │ │ │ - * **refresh** (*ArgumentType.Int*) -- vertical refresh rate │ │ │ │ │ - in mHz │ │ │ │ │ - │ │ │ │ │ - done() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 2 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Sent all information about output │ │ │ │ │ - │ │ │ │ │ - This event is sent after all other properties have been sent │ │ │ │ │ - after binding to the output object and after any other property │ │ │ │ │ - changes done after that. This allows changes to the output │ │ │ │ │ - properties to be seen as atomic, even if they happen via │ │ │ │ │ - multiple events. │ │ │ │ │ - │ │ │ │ │ - scale(factor: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 3 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Output scaling properties │ │ │ │ │ - │ │ │ │ │ - This event contains scaling geometry information that is not in │ │ │ │ │ - the geometry event. It may be sent after binding the output │ │ │ │ │ - object or if the output scale changes later. The compositor will │ │ │ │ │ - emit a non-zero, positive value for scale. If it is not sent, │ │ │ │ │ - the client should assume a scale of 1. │ │ │ │ │ - │ │ │ │ │ - A scale larger than 1 means that the compositor will │ │ │ │ │ - automatically scale surface buffers by this amount when │ │ │ │ │ - rendering. This is used for very high resolution displays where │ │ │ │ │ - applications rendering at the native resolution would be too │ │ │ │ │ - small to be legible. │ │ │ │ │ - │ │ │ │ │ - Clients should use "WlSurface.preferred_buffer_scale()" instead │ │ │ │ │ - of this event to find the preferred buffer scale to use for a │ │ │ │ │ - surface. │ │ │ │ │ - │ │ │ │ │ - The scale event will be followed by a done event. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - **factor** (*ArgumentType.Int*) -- scaling factor of output │ │ │ │ │ - │ │ │ │ │ - name(name: 'str') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 4 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Name of this output │ │ │ │ │ - │ │ │ │ │ - Many compositors will assign user-friendly names to their │ │ │ │ │ - outputs, show them to the user, allow the user to refer to an │ │ │ │ │ - output, etc. The client may wish to know this name as well to │ │ │ │ │ - offer the user similar behaviors. │ │ │ │ │ - │ │ │ │ │ - The name is a UTF-8 string with no convention defined for its │ │ │ │ │ - contents. Each name is unique among all "WlOutput" globals. The │ │ │ │ │ - name is only guaranteed to be unique for the compositor │ │ │ │ │ - instance. │ │ │ │ │ - │ │ │ │ │ - The same output name is used for all clients for a given │ │ │ │ │ - "WlOutput" global. Thus, the name can be shared across processes │ │ │ │ │ - to refer to a specific "WlOutput" global. │ │ │ │ │ - │ │ │ │ │ - The name is not guaranteed to be persistent across sessions, │ │ │ │ │ - thus cannot be used to reliably identify an output in e.g. │ │ │ │ │ - configuration files. │ │ │ │ │ - │ │ │ │ │ - Examples of names include 'HDMI-A-1', 'WL-1', 'X11-1', etc. │ │ │ │ │ - However, do not assume that the name is a reflection of an │ │ │ │ │ - underlying DRM connector, X11 connection, etc. │ │ │ │ │ - │ │ │ │ │ - The name event is sent after binding the output object. This │ │ │ │ │ - event is only sent once per output object, and the name does not │ │ │ │ │ - change over the lifetime of the "WlOutput" global. │ │ │ │ │ - │ │ │ │ │ - Compositors may re-use the same output name if the "WlOutput" │ │ │ │ │ - global is destroyed and re-created later. Compositors should │ │ │ │ │ - avoid re- using the same name if possible. │ │ │ │ │ - │ │ │ │ │ - The name event will be followed by a done event. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - **name** (*ArgumentType.String*) -- output name │ │ │ │ │ - │ │ │ │ │ - description(description: 'str') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 5 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Human-readable description of this output │ │ │ │ │ - │ │ │ │ │ - Many compositors can produce human-readable descriptions of │ │ │ │ │ - their outputs. The client may wish to know this description as │ │ │ │ │ - well, e.g. for output selection purposes. │ │ │ │ │ - │ │ │ │ │ - The description is a UTF-8 string with no convention defined for │ │ │ │ │ - its contents. The description is not guaranteed to be unique │ │ │ │ │ - among all "WlOutput" globals. Examples might include 'Foocorp │ │ │ │ │ - 11" Display' or 'Virtual X11 output via :1'. │ │ │ │ │ - │ │ │ │ │ - The description event is sent after binding the output object │ │ │ │ │ - and whenever the description changes. The description is │ │ │ │ │ - optional, and may not be sent at all. │ │ │ │ │ - │ │ │ │ │ - The description event will be followed by a done event. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - **description** (*ArgumentType.String*) -- output description │ │ │ │ │ - │ │ │ │ │ - │ │ │ │ │ -WlBuffer │ │ │ │ │ -======== │ │ │ │ │ - │ │ │ │ │ -class pywayland.protocol.wayland.WlBuffer │ │ │ │ │ - │ │ │ │ │ - Content for a "WlSurface" │ │ │ │ │ - │ │ │ │ │ - A buffer provides the content for a "WlSurface". Buffers are │ │ │ │ │ - created through factory interfaces such as "WlShm", │ │ │ │ │ - wp_linux_buffer_params (from the linux-dmabuf protocol extension) │ │ │ │ │ - or similar. It has a width and a height and can be attached to a │ │ │ │ │ - "WlSurface", but the mechanism by which a client provides and │ │ │ │ │ - updates the contents is defined by the buffer factory interface. │ │ │ │ │ - │ │ │ │ │ - Color channels are assumed to be electrical rather than optical (in │ │ │ │ │ - other words, encoded with a transfer function) unless otherwise │ │ │ │ │ - specified. If the buffer uses a format that has an alpha channel, │ │ │ │ │ - the alpha channel is assumed to be premultiplied into the │ │ │ │ │ - electrical color channel values (after transfer function encoding) │ │ │ │ │ - unless otherwise specified. │ │ │ │ │ - │ │ │ │ │ - Note, because "WlBuffer" objects are created from multiple │ │ │ │ │ - independent factory interfaces, the "WlBuffer" interface is frozen │ │ │ │ │ - at version 1. │ │ │ │ │ - │ │ │ │ │ - destroy() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Destroy a buffer │ │ │ │ │ - │ │ │ │ │ - Destroy a buffer. If and how you need to release the backing │ │ │ │ │ - storage is defined by the buffer factory interface. │ │ │ │ │ - │ │ │ │ │ - For possible side-effects to a surface, see │ │ │ │ │ - "WlSurface.attach()". │ │ │ │ │ - │ │ │ │ │ - release() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Compositor releases buffer │ │ │ │ │ - │ │ │ │ │ - Sent when this "WlBuffer" is no longer used by the compositor. │ │ │ │ │ - The client is now free to reuse or destroy this buffer and its │ │ │ │ │ - backing storage. │ │ │ │ │ - │ │ │ │ │ - If a client receives a release event before the frame callback │ │ │ │ │ - requested in the same "WlSurface.commit()" that attaches this │ │ │ │ │ - "WlBuffer" to a surface, then the client is immediately free to │ │ │ │ │ - reuse the buffer and its backing storage, and does not need a │ │ │ │ │ - second buffer for the next surface content update. Typically │ │ │ │ │ - this is possible, when the compositor maintains a copy of the │ │ │ │ │ - "WlSurface" contents, e.g. as a GL texture. This is an important │ │ │ │ │ - optimization for GL(ES) compositors with "WlShm" clients. │ │ │ │ │ - │ │ │ │ │ - │ │ │ │ │ -WlSeat │ │ │ │ │ -====== │ │ │ │ │ - │ │ │ │ │ -class pywayland.protocol.wayland.WlSeat │ │ │ │ │ - │ │ │ │ │ - Group of input devices │ │ │ │ │ - │ │ │ │ │ - A seat is a group of keyboards, pointer and touch devices. This │ │ │ │ │ - object is published as a global during start up, or when such a │ │ │ │ │ - device is hot plugged. A seat typically has a pointer and │ │ │ │ │ - maintains a keyboard focus and a pointer focus. │ │ │ │ │ - │ │ │ │ │ - get_pointer() -> 'Proxy[WlPointer]' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Return pointer object │ │ │ │ │ - │ │ │ │ │ - The ID provided will be initialized to the "WlPointer" interface │ │ │ │ │ - for this seat. │ │ │ │ │ - │ │ │ │ │ - This request only takes effect if the seat has the pointer │ │ │ │ │ - capability, or has had the pointer capability in the past. It is │ │ │ │ │ - a protocol violation to issue this request on a seat that has │ │ │ │ │ - never had the pointer capability. The missing_capability error │ │ │ │ │ - will be sent in this case. │ │ │ │ │ - │ │ │ │ │ - Returns: │ │ │ │ │ - "WlPointer" -- seat pointer │ │ │ │ │ - │ │ │ │ │ - get_keyboard() -> 'Proxy[WlKeyboard]' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 1 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Return keyboard object │ │ │ │ │ - │ │ │ │ │ - The ID provided will be initialized to the "WlKeyboard" │ │ │ │ │ - interface for this seat. │ │ │ │ │ - │ │ │ │ │ - This request only takes effect if the seat has the keyboard │ │ │ │ │ - capability, or has had the keyboard capability in the past. It │ │ │ │ │ - is a protocol violation to issue this request on a seat that has │ │ │ │ │ - never had the keyboard capability. The missing_capability error │ │ │ │ │ - will be sent in this case. │ │ │ │ │ - │ │ │ │ │ - Returns: │ │ │ │ │ - "WlKeyboard" -- seat keyboard │ │ │ │ │ - │ │ │ │ │ - get_touch() -> 'Proxy[WlTouch]' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 2 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Return touch object │ │ │ │ │ - │ │ │ │ │ - The ID provided will be initialized to the "WlTouch" interface │ │ │ │ │ - for this seat. │ │ │ │ │ - │ │ │ │ │ - This request only takes effect if the seat has the touch │ │ │ │ │ - capability, or has had the touch capability in the past. It is a │ │ │ │ │ - protocol violation to issue this request on a seat that has │ │ │ │ │ - never had the touch capability. The missing_capability error │ │ │ │ │ - will be sent in this case. │ │ │ │ │ - │ │ │ │ │ - Returns: │ │ │ │ │ - "WlTouch" -- seat touch interface │ │ │ │ │ - │ │ │ │ │ - release() -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 3 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Release the seat object │ │ │ │ │ - │ │ │ │ │ - Using this request a client can tell the server that it is not │ │ │ │ │ - going to use the seat object anymore. │ │ │ │ │ - │ │ │ │ │ - capabilities(capabilities: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Seat capabilities changed │ │ │ │ │ - │ │ │ │ │ - This is emitted whenever a seat gains or loses the pointer, │ │ │ │ │ - keyboard or touch capabilities. The argument is a capability │ │ │ │ │ - enum containing the complete set of capabilities this seat has. │ │ │ │ │ - │ │ │ │ │ - When the pointer capability is added, a client may create a │ │ │ │ │ - "WlPointer" object using the "WlSeat.get_pointer()" request. │ │ │ │ │ - This object will receive pointer events until the capability is │ │ │ │ │ - removed in the future. │ │ │ │ │ - │ │ │ │ │ - When the pointer capability is removed, a client should destroy │ │ │ │ │ - the "WlPointer" objects associated with the seat where the │ │ │ │ │ - capability was removed, using the "WlPointer.release()" request. │ │ │ │ │ - No further pointer events will be received on these objects. │ │ │ │ │ - │ │ │ │ │ - In some compositors, if a seat regains the pointer capability │ │ │ │ │ - and a client has a previously obtained "WlPointer" object of │ │ │ │ │ - version 4 or less, that object may start sending pointer events │ │ │ │ │ - again. This behavior is considered a misinterpretation of the │ │ │ │ │ - intended behavior and must not be relied upon by the client. │ │ │ │ │ - "WlPointer" objects of version 5 or later must not send events │ │ │ │ │ - if created before the most recent event notifying the client of │ │ │ │ │ - an added pointer capability. │ │ │ │ │ - │ │ │ │ │ - The above behavior also applies to "WlKeyboard" and "WlTouch" │ │ │ │ │ - with the keyboard and touch capabilities, respectively. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - **capabilities** (*ArgumentType.Uint*) -- capabilities of the │ │ │ │ │ - seat │ │ │ │ │ - │ │ │ │ │ - name(name: 'str') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Unique identifier for this seat │ │ │ │ │ - │ │ │ │ │ - In a multi-seat configuration the seat name can be used by │ │ │ │ │ - clients to help identify which physical devices the seat │ │ │ │ │ - represents. │ │ │ │ │ - │ │ │ │ │ - The seat name is a UTF-8 string with no convention defined for │ │ │ │ │ - its contents. Each name is unique among all "WlSeat" globals. │ │ │ │ │ - The name is only guaranteed to be unique for the current │ │ │ │ │ - compositor instance. │ │ │ │ │ - │ │ │ │ │ - The same seat names are used for all clients. Thus, the name can │ │ │ │ │ - be shared across processes to refer to a specific "WlSeat" │ │ │ │ │ - global. │ │ │ │ │ - │ │ │ │ │ - The name event is sent after binding to the seat global. This │ │ │ │ │ - event is only sent once per seat object, and the name does not │ │ │ │ │ - change over the lifetime of the "WlSeat" global. │ │ │ │ │ - │ │ │ │ │ - Compositors may re-use the same seat name if the "WlSeat" global │ │ │ │ │ - is destroyed and re-created later. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - **name** (*ArgumentType.String*) -- seat identifier │ │ │ │ │ - │ │ │ │ │ - │ │ │ │ │ -WlRegistry │ │ │ │ │ -========== │ │ │ │ │ - │ │ │ │ │ -class pywayland.protocol.wayland.WlRegistry │ │ │ │ │ - │ │ │ │ │ - Global registry object │ │ │ │ │ - │ │ │ │ │ - The singleton global registry object. The server has a number of │ │ │ │ │ - global objects that are available to all clients. These objects │ │ │ │ │ - typically represent an actual object in the server (for example, an │ │ │ │ │ - input device) or they are singleton objects that provide extension │ │ │ │ │ - functionality. │ │ │ │ │ - │ │ │ │ │ - When a client creates a registry object, the registry object will │ │ │ │ │ - emit a global event for each global currently in the registry. │ │ │ │ │ - Globals come and go as a result of device or monitor hotplugs, │ │ │ │ │ - reconfiguration or other events, and the registry will send out │ │ │ │ │ - global and global_remove events to keep the client up to date with │ │ │ │ │ - the changes. To mark the end of the initial burst of events, the │ │ │ │ │ - client can use the "WlDisplay.sync()" request immediately after │ │ │ │ │ - calling "WlDisplay.get_registry()". │ │ │ │ │ - │ │ │ │ │ - A client can bind to a global object by using the bind request. │ │ │ │ │ - This creates a client-side handle that lets the object emit events │ │ │ │ │ - to the client and lets the client invoke requests on the object. │ │ │ │ │ - │ │ │ │ │ - bind(name: 'int', interface: 'type[T]', version: 'int') -> 'Proxy[T]' │ │ │ │ │ - │ │ │ │ │ - -[ Request -- opcode 0 (attached to "Resource" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Bind an object to the display │ │ │ │ │ - │ │ │ │ │ - Binds a new, client-created object to the server using the │ │ │ │ │ - specified name as the identifier. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **name** (*ArgumentType.Uint*) -- unique numeric name of │ │ │ │ │ - the object │ │ │ │ │ - │ │ │ │ │ - * **interface** (*string*) -- Interface name │ │ │ │ │ - │ │ │ │ │ - * **version** (*int*) -- Interface version │ │ │ │ │ - │ │ │ │ │ - Returns: │ │ │ │ │ - "pywayland.client.proxy.Proxy" of specified Interface -- │ │ │ │ │ - bounded object │ │ │ │ │ - │ │ │ │ │ - global_(name: 'int', interface: 'str', version: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 0 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Announce global object │ │ │ │ │ - │ │ │ │ │ - Notify the client of global objects. │ │ │ │ │ - │ │ │ │ │ - The event notifies the client that a global object with the │ │ │ │ │ - given name is now available, and it implements the given version │ │ │ │ │ - of the given interface. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - * **name** (*ArgumentType.Uint*) -- numeric name of the │ │ │ │ │ - global object │ │ │ │ │ - │ │ │ │ │ - * **interface** (*ArgumentType.String*) -- interface │ │ │ │ │ - implemented by the object │ │ │ │ │ - │ │ │ │ │ - * **version** (*ArgumentType.Uint*) -- interface version │ │ │ │ │ - │ │ │ │ │ - global_remove(name: 'int') -> 'None' │ │ │ │ │ - │ │ │ │ │ - -[ Event -- opcode 1 (attached to "Proxy" instance) ]- │ │ │ │ │ - │ │ │ │ │ - Announce removal of global object │ │ │ │ │ - │ │ │ │ │ - Notify the client of removed global objects. │ │ │ │ │ - │ │ │ │ │ - This event notifies the client that the global identified by │ │ │ │ │ - name is no longer available. If the client bound to the global │ │ │ │ │ - using the bind request, the client should now destroy that │ │ │ │ │ - object. │ │ │ │ │ - │ │ │ │ │ - The object remains valid and requests to the object will be │ │ │ │ │ - ignored until the client destroys it, to avoid races between the │ │ │ │ │ - global going away and a client sending a request to it. │ │ │ │ │ - │ │ │ │ │ - Parameters: │ │ │ │ │ - **name** (*ArgumentType.Uint*) -- numeric name of the global │ │ │ │ │ - object ├── python3-pywayland_0.4.18-1_amd64.deb │ ├── file list │ │ @@ -1,3 +1,3 @@ │ │ -rw-r--r-- 0 0 0 4 2024-10-11 20:38:19.000000 debian-binary │ │ -rw-r--r-- 0 0 0 2920 2024-10-11 20:38:19.000000 control.tar.xz │ │ --rw-r--r-- 0 0 0 117120 2024-10-11 20:38:19.000000 data.tar.xz │ │ +-rw-r--r-- 0 0 0 117540 2024-10-11 20:38:19.000000 data.tar.xz │ ├── control.tar.xz │ │ ├── control.tar │ │ │ ├── ./control │ │ │ │ @@ -1,13 +1,13 @@ │ │ │ │ Package: python3-pywayland │ │ │ │ Source: pywayland │ │ │ │ Version: 0.4.18-1 │ │ │ │ Architecture: amd64 │ │ │ │ Maintainer: Daniel Echeverri │ │ │ │ -Installed-Size: 545 │ │ │ │ +Installed-Size: 546 │ │ │ │ Depends: python3 (>= 3~), python3:any, libc6 (>= 2.28), libwayland-client0 (>= 1.5.91), libwayland-server0 (>= 1.14.91) │ │ │ │ Suggests: python3-pywayland-doc │ │ │ │ Section: python │ │ │ │ Priority: optional │ │ │ │ Homepage: https://github.com/flacjacket/pywayland │ │ │ │ Description: Provides Python bindings to the Wayland library │ │ │ │ PyWayland provides a wrapper to the libwayland library using │ │ │ ├── ./md5sums │ │ │ │ ├── ./md5sums │ │ │ │ │┄ Files differ │ ├── data.tar.xz │ │ ├── data.tar │ │ │ ├── file list │ │ │ │ @@ -88,8 +88,8 @@ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 170 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/changelog.Debian.gz │ │ │ │ -rw-r--r-- 0 root (0) root (0) 4446 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/copyright │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/lintian/ │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/lintian/overrides/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 170 2024-10-11 20:38:19.000000 ./usr/share/lintian/overrides/python3-pywayland │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/man/ │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/man/man1/ │ │ │ │ --rw-r--r-- 0 root (0) root (0) 40628 2024-10-11 20:38:19.000000 ./usr/share/man/man1/pywayland-scanner.1.gz │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 41017 2024-10-11 20:38:19.000000 ./usr/share/man/man1/pywayland-scanner.1.gz │ │ │ ├── ./usr/share/man/man1/pywayland-scanner.1.gz │ │ │ │ ├── pywayland-scanner.1 │ │ │ │ │┄ Ordering differences only │ │ │ │ │ @@ -1095,93 +1095,569 @@ │ │ │ │ │ .TP │ │ │ │ │ .B class pywayland.protocol_core.argument.ArgumentType(value, names=, *values, module=None, qualname=None, type=None, start=1, boundary=None) │ │ │ │ │ .UNINDENT │ │ │ │ │ .SS Protocol Modules │ │ │ │ │ .sp │ │ │ │ │ Wayland protocols built against Wayland 1.21.0 and Wayland Protocols 1.25. │ │ │ │ │ .SS wayland Module │ │ │ │ │ -.SS WlCallback │ │ │ │ │ +.SS WlDataDevice │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlCallback │ │ │ │ │ -Callback object │ │ │ │ │ +.B class pywayland.protocol.wayland.WlDataDevice │ │ │ │ │ +Data transfer device │ │ │ │ │ .sp │ │ │ │ │ -Clients can handle the \(aqdone\(aq event to get notified when the related │ │ │ │ │ -request is done. │ │ │ │ │ +There is one \fI\%WlDataDevice\fP per seat which can be obtained from the │ │ │ │ │ +global \fI\%WlDataDeviceManager\fP singleton. │ │ │ │ │ .sp │ │ │ │ │ -Note, because \fI\%WlCallback\fP objects are created from multiple │ │ │ │ │ -independent factory interfaces, the \fI\%WlCallback\fP interface is frozen │ │ │ │ │ -at version 1. │ │ │ │ │ +A \fI\%WlDataDevice\fP provides access to inter\-client data transfer │ │ │ │ │ +mechanisms such as copy\-and\-paste and drag\-and\-drop. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B done(callback_data: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.B start_drag(source: \(aqWlDataSource | None\(aq, origin: \(aqWlSurface\(aq, icon: \(aqWlSurface | None\(aq, serial: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Start drag\-and\-drop operation │ │ │ │ │ +.sp │ │ │ │ │ +This request asks the compositor to start a drag\-and\-drop operation on │ │ │ │ │ +behalf of the client. │ │ │ │ │ +.sp │ │ │ │ │ +The source argument is the data source that provides the data for the │ │ │ │ │ +eventual data transfer. If source is NULL, enter, leave and motion │ │ │ │ │ +events are sent only to the client that initiated the drag and the │ │ │ │ │ +client is expected to handle the data passing internally. If source is │ │ │ │ │ +destroyed, the drag\-and\-drop session will be cancelled. │ │ │ │ │ +.sp │ │ │ │ │ +The origin surface is the surface where the drag originates and the │ │ │ │ │ +client must have an active implicit grab that matches the serial. │ │ │ │ │ +.sp │ │ │ │ │ +The icon surface is an optional (can be NULL) surface that provides an │ │ │ │ │ +icon to be moved around with the cursor. Initially, the top\-left │ │ │ │ │ +corner of the icon surface is placed at the cursor hotspot, but │ │ │ │ │ +subsequent \fI\%WlSurface.offset()\fP requests can move the │ │ │ │ │ +relative position. Attach requests must be confirmed with │ │ │ │ │ +\fI\%WlSurface.commit()\fP as usual. The icon │ │ │ │ │ +surface is given the role of a drag\-and\-drop icon. If the icon surface │ │ │ │ │ +already has another role, it raises a protocol error. │ │ │ │ │ +.sp │ │ │ │ │ +The input region is ignored for wl_surfaces with the role of a drag\- │ │ │ │ │ +and\-drop icon. │ │ │ │ │ +.sp │ │ │ │ │ +The given source may not be used in any further set_selection or │ │ │ │ │ +start_drag requests. Attempting to reuse a previously\-used source may │ │ │ │ │ +send a used_source error. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBsource\fP (\fI\%WlDataSource\fP or \fINone\fP) \-\- data source for the eventual transfer │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBorigin\fP (\fI\%WlSurface\fP) \-\- surface where the drag originates │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBicon\fP (\fI\%WlSurface\fP or \fINone\fP) \-\- drag\-and\-drop icon surface │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the implicit grab on the origin │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B set_selection(source: \(aqWlDataSource | None\(aq, serial: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Copy data to the selection │ │ │ │ │ +.sp │ │ │ │ │ +This request asks the compositor to set the selection to the data from │ │ │ │ │ +the source on behalf of the client. │ │ │ │ │ +.sp │ │ │ │ │ +To unset the selection, set the source to NULL. │ │ │ │ │ +.sp │ │ │ │ │ +The given source may not be used in any further set_selection or │ │ │ │ │ +start_drag requests. Attempting to reuse a previously\-used source may │ │ │ │ │ +send a used_source error. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBsource\fP (\fI\%WlDataSource\fP or \fINone\fP) \-\- data source for the selection │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the event that triggered this request │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B release() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 2 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Destroy data device │ │ │ │ │ +.sp │ │ │ │ │ +This request destroys the data device. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B data_offer(id: \(aqWlDataOffer\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Done event │ │ │ │ │ +Introduce a new \fI\%WlDataOffer\fP │ │ │ │ │ .sp │ │ │ │ │ -Notify the client when the related request is done. │ │ │ │ │ +The data_offer event introduces a new │ │ │ │ │ +\fI\%WlDataOffer\fP object, which will │ │ │ │ │ +subsequently be used in either the data_device.enter event (for drag\- │ │ │ │ │ +and\-drop) or the data_device.selection event (for selections). │ │ │ │ │ +Immediately following the data_device.data_offer event, the new │ │ │ │ │ +data_offer object will send out data_offer.offer events to describe the │ │ │ │ │ +mime types it offers. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ -\fBcallback_data\fP (\fIArgumentType.Uint\fP) \-\- request\-specific data for the callback │ │ │ │ │ +\fBid\fP (\fI\%WlDataOffer\fP) \-\- the new data_offer object │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B enter(serial: \(aqint\(aq, surface: \(aqWlSurface\(aq, x: \(aqfloat\(aq, y: \(aqfloat\(aq, id: \(aqWlDataOffer | None\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Initiate drag\-and\-drop session │ │ │ │ │ +.sp │ │ │ │ │ +This event is sent when an active drag\-and\-drop pointer enters a │ │ │ │ │ +surface owned by the client. The position of the pointer at enter time │ │ │ │ │ +is provided by the x and y arguments, in surface\-local coordinates. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the enter event │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBsurface\fP (\fI\%WlSurface\fP) \-\- client surface entered │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBx\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local x coordinate │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBy\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local y coordinate │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBid\fP (\fI\%WlDataOffer\fP or \fINone\fP) \-\- source data_offer object │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ -.SS WlDataDeviceManager │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B leave() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 2 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +End drag\-and\-drop session │ │ │ │ │ +.sp │ │ │ │ │ +This event is sent when the drag\-and\-drop pointer leaves the surface │ │ │ │ │ +and the session ends. The client must destroy the │ │ │ │ │ +\fI\%WlDataOffer\fP introduced at enter │ │ │ │ │ +time at this point. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B motion(time: \(aqint\(aq, x: \(aqfloat\(aq, y: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Drag\-and\-drop session motion │ │ │ │ │ +.sp │ │ │ │ │ +This event is sent when the drag\-and\-drop pointer moves within the │ │ │ │ │ +currently focused surface. The new position of the pointer is provided │ │ │ │ │ +by the x and y arguments, in surface\-local coordinates. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBx\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local x coordinate │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBy\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local y coordinate │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B drop() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +End drag\-and\-drop session successfully │ │ │ │ │ +.sp │ │ │ │ │ +The event is sent when a drag\-and\-drop operation is ended because the │ │ │ │ │ +implicit grab is removed. │ │ │ │ │ +.sp │ │ │ │ │ +The drag\-and\-drop destination is expected to honor the last action │ │ │ │ │ +received through \fI\%WlDataOffer.action()\fP, if the resulting │ │ │ │ │ +action is \(dqcopy\(dq or \(dqmove\(dq, the destination can still perform │ │ │ │ │ +\fI\%WlDataOffer.receive()\fP requests, and is │ │ │ │ │ +expected to end all transfers with a \fI\%WlDataOffer.finish()\fP request. │ │ │ │ │ +.sp │ │ │ │ │ +If the resulting action is \(dqask\(dq, the action will not be considered │ │ │ │ │ +final. The drag\-and\-drop destination is expected to perform one last │ │ │ │ │ +\fI\%WlDataOffer.set_actions()\fP request, or │ │ │ │ │ +\fI\%WlDataOffer.destroy()\fP in order to cancel │ │ │ │ │ +the operation. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B selection(id: \(aqWlDataOffer | None\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Advertise new selection │ │ │ │ │ +.sp │ │ │ │ │ +The selection event is sent out to notify the client of a new │ │ │ │ │ +\fI\%WlDataOffer\fP for the selection for │ │ │ │ │ +this device. The data_device.data_offer and the data_offer.offer │ │ │ │ │ +events are sent out immediately before this event to introduce the data │ │ │ │ │ +offer object. The selection event is sent to a client immediately │ │ │ │ │ +before receiving keyboard focus and when a new selection is set while │ │ │ │ │ +the client has keyboard focus. The data_offer is valid until a new │ │ │ │ │ +data_offer or NULL is received or until the client loses keyboard │ │ │ │ │ +focus. Switching surface with keyboard focus within the same client │ │ │ │ │ +doesn\(aqt mean a new selection will be sent. The client must destroy the │ │ │ │ │ +previous selection data_offer, if any, upon receiving this event. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBid\fP (\fI\%WlDataOffer\fP or \fINone\fP) \-\- selection data_offer object │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.SS WlTouch │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlDataDeviceManager │ │ │ │ │ -Data transfer interface │ │ │ │ │ +.B class pywayland.protocol.wayland.WlTouch │ │ │ │ │ +Touchscreen input device │ │ │ │ │ .sp │ │ │ │ │ -The \fI\%WlDataDeviceManager\fP is a singleton global object that provides │ │ │ │ │ -access to inter\-client data transfer mechanisms such as copy\-and\-paste and │ │ │ │ │ -drag\-and\-drop. These mechanisms are tied to a │ │ │ │ │ -\fI\%WlSeat\fP and this interface lets a │ │ │ │ │ -client get a \fI\%WlDataDevice\fP │ │ │ │ │ -corresponding to a \fI\%WlSeat\fP\&. │ │ │ │ │ +The \fI\%WlTouch\fP interface represents a touchscreen associated with a │ │ │ │ │ +seat. │ │ │ │ │ .sp │ │ │ │ │ -Depending on the version bound, the objects created from the bound │ │ │ │ │ -\fI\%WlDataDeviceManager\fP object will have different requirements for │ │ │ │ │ -functioning properly. See \fI\%WlDataSource.set_actions()\fP, │ │ │ │ │ -\fI\%WlDataOffer.accept()\fP and │ │ │ │ │ -\fI\%WlDataOffer.finish()\fP for details. │ │ │ │ │ +Touch interactions can consist of one or more contacts. For each contact, a │ │ │ │ │ +series of events is generated, starting with a down event, followed by zero │ │ │ │ │ +or more motion events, and ending with an up event. Events relating to the │ │ │ │ │ +same contact point can be identified by the ID of the sequence. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B create_data_source() -> \(aqProxy[WlDataSource]\(aq │ │ │ │ │ +.B release() -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Create a new data source │ │ │ │ │ +Release the touch object │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B down(serial: \(aqint\(aq, time: \(aqint\(aq, surface: \(aqWlSurface\(aq, id: \(aqint\(aq, x: \(aqfloat\(aq, y: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -Create a new data source. │ │ │ │ │ +Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Touch down event and beginning of a touch sequence │ │ │ │ │ +.sp │ │ │ │ │ +A new touch point has appeared on the surface. This touch point is │ │ │ │ │ +assigned a unique ID. Future events from this touch point reference │ │ │ │ │ +this ID. The ID ceases to be valid after a touch up event and may be │ │ │ │ │ +reused in the future. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B Returns │ │ │ │ │ -\fI\%WlDataSource\fP \-\- data source to │ │ │ │ │ -create │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the touch down event │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBsurface\fP (\fI\%WlSurface\fP) \-\- surface touched │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBx\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local x coordinate │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBy\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local y coordinate │ │ │ │ │ +.UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B get_data_device(seat: \(aqWlSeat\(aq) -> \(aqProxy[WlDataDevice]\(aq │ │ │ │ │ +.B up(serial: \(aqint\(aq, time: \(aqint\(aq, id: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ +Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Create a new data device │ │ │ │ │ +End of a touch event sequence │ │ │ │ │ .sp │ │ │ │ │ -Create a new data device for a given seat. │ │ │ │ │ +The touch point has disappeared. No further events will be sent for │ │ │ │ │ +this touch point and the touch point\(aqs ID is released and may be reused │ │ │ │ │ +in a future touch down event. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ -\fBseat\fP (\fI\%WlSeat\fP) \-\- seat associated with the data device │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the touch up event │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B motion(time: \(aqint\(aq, id: \(aqint\(aq, x: \(aqfloat\(aq, y: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 2 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Update of touch point coordinates │ │ │ │ │ +.sp │ │ │ │ │ +A touch point has changed coordinates. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBx\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local x coordinate │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBy\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local y coordinate │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B frame() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +End of touch frame event │ │ │ │ │ +.sp │ │ │ │ │ +Indicates the end of a set of events that logically belong together. A │ │ │ │ │ +client is expected to accumulate the data in all events within the │ │ │ │ │ +frame before proceeding. │ │ │ │ │ +.sp │ │ │ │ │ +A \fI\%WlTouch.frame()\fP terminates at least one event but otherwise │ │ │ │ │ +no guarantee is provided about the set of events within a frame. A │ │ │ │ │ +client must assume that any state not updated in a frame is unchanged │ │ │ │ │ +from the previously known state. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B cancel() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Touch session cancelled │ │ │ │ │ +.sp │ │ │ │ │ +Sent if the compositor decides the touch stream is a global gesture. No │ │ │ │ │ +further events are sent to the clients from that particular gesture. │ │ │ │ │ +Touch cancellation applies to all touch points currently active on this │ │ │ │ │ +client\(aqs surface. The client is responsible for finalizing the touch │ │ │ │ │ +points, future touch points on this surface may reuse the touch point │ │ │ │ │ +ID. │ │ │ │ │ +.sp │ │ │ │ │ +No frame event is required after the cancel event. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B shape(id: \(aqint\(aq, major: \(aqfloat\(aq, minor: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Update shape of touch point │ │ │ │ │ +.sp │ │ │ │ │ +Sent when a touchpoint has changed its shape. │ │ │ │ │ +.sp │ │ │ │ │ +This event does not occur on its own. It is sent before a │ │ │ │ │ +\fI\%WlTouch.frame()\fP event and carries the new shape information for │ │ │ │ │ +any previously reported, or new touch points of that frame. │ │ │ │ │ +.sp │ │ │ │ │ +Other events describing the touch point such as \fI\%WlTouch.down()\fP, │ │ │ │ │ +\fI\%WlTouch.motion()\fP or \fI\%WlTouch.orientation()\fP may be sent │ │ │ │ │ +within the same \fI\%WlTouch.frame()\fP\&. A client should treat these │ │ │ │ │ +events as a single logical touch point update. The order of │ │ │ │ │ +\fI\%WlTouch.shape()\fP, \fI\%WlTouch.orientation()\fP and │ │ │ │ │ +\fI\%WlTouch.motion()\fP is not guaranteed. A \fI\%WlTouch.down()\fP │ │ │ │ │ +event is guaranteed to occur before the first \fI\%WlTouch.shape()\fP │ │ │ │ │ +event for this touch ID but both events may occur within the same │ │ │ │ │ +\fI\%WlTouch.frame()\fP\&. │ │ │ │ │ +.sp │ │ │ │ │ +A touchpoint shape is approximated by an ellipse through the major and │ │ │ │ │ +minor axis length. The major axis length describes the longer diameter │ │ │ │ │ +of the ellipse, while the minor axis length describes the shorter │ │ │ │ │ +diameter. Major and minor are orthogonal and both are specified in │ │ │ │ │ +surface\-local coordinates. The center of the ellipse is always at the │ │ │ │ │ +touchpoint location as reported by \fI\%WlTouch.down()\fP or │ │ │ │ │ +\fBWlTouch.move()\fP\&. │ │ │ │ │ +.sp │ │ │ │ │ +This event is only sent by the compositor if the touch device supports │ │ │ │ │ +shape reports. The client has to make reasonable assumptions about the │ │ │ │ │ +shape if it did not receive this event. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBmajor\fP (\fIArgumentType.Fixed\fP) \-\- length of the major axis in surface\-local coordinates │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBminor\fP (\fIArgumentType.Fixed\fP) \-\- length of the minor axis in surface\-local coordinates │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B orientation(id: \(aqint\(aq, orientation: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 6 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Update orientation of touch point │ │ │ │ │ +.sp │ │ │ │ │ +Sent when a touchpoint has changed its orientation. │ │ │ │ │ +.sp │ │ │ │ │ +This event does not occur on its own. It is sent before a │ │ │ │ │ +\fI\%WlTouch.frame()\fP event and carries the new shape information for │ │ │ │ │ +any previously reported, or new touch points of that frame. │ │ │ │ │ +.sp │ │ │ │ │ +Other events describing the touch point such as \fI\%WlTouch.down()\fP, │ │ │ │ │ +\fI\%WlTouch.motion()\fP or \fI\%WlTouch.shape()\fP may be sent within │ │ │ │ │ +the same \fI\%WlTouch.frame()\fP\&. A client should treat these events as │ │ │ │ │ +a single logical touch point update. The order of │ │ │ │ │ +\fI\%WlTouch.shape()\fP, \fI\%WlTouch.orientation()\fP and │ │ │ │ │ +\fI\%WlTouch.motion()\fP is not guaranteed. A \fI\%WlTouch.down()\fP │ │ │ │ │ +event is guaranteed to occur before the first │ │ │ │ │ +\fI\%WlTouch.orientation()\fP event for this touch ID but both events │ │ │ │ │ +may occur within the same \fI\%WlTouch.frame()\fP\&. │ │ │ │ │ +.sp │ │ │ │ │ +The orientation describes the clockwise angle of a touchpoint\(aqs major │ │ │ │ │ +axis to the positive surface y\-axis and is normalized to the \-180 to │ │ │ │ │ ++180 degree range. The granularity of orientation depends on the touch │ │ │ │ │ +device, some devices only support binary rotation values between 0 and │ │ │ │ │ +90 degrees. │ │ │ │ │ +.sp │ │ │ │ │ +This event is only sent by the compositor if the touch device supports │ │ │ │ │ +orientation reports. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBorientation\fP (\fIArgumentType.Fixed\fP) \-\- angle between major axis and positive surface y\-axis in degrees │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.SS WlRegistry │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlRegistry │ │ │ │ │ +Global registry object │ │ │ │ │ +.sp │ │ │ │ │ +The singleton global registry object. The server has a number of global │ │ │ │ │ +objects that are available to all clients. These objects typically │ │ │ │ │ +represent an actual object in the server (for example, an input device) or │ │ │ │ │ +they are singleton objects that provide extension functionality. │ │ │ │ │ +.sp │ │ │ │ │ +When a client creates a registry object, the registry object will emit a │ │ │ │ │ +global event for each global currently in the registry. Globals come and │ │ │ │ │ +go as a result of device or monitor hotplugs, reconfiguration or other │ │ │ │ │ +events, and the registry will send out global and global_remove events to │ │ │ │ │ +keep the client up to date with the changes. To mark the end of the │ │ │ │ │ +initial burst of events, the client can use the \fI\%WlDisplay.sync()\fP request immediately after │ │ │ │ │ +calling \fI\%WlDisplay.get_registry()\fP\&. │ │ │ │ │ +.sp │ │ │ │ │ +A client can bind to a global object by using the bind request. This │ │ │ │ │ +creates a client\-side handle that lets the object emit events to the client │ │ │ │ │ +and lets the client invoke requests on the object. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B bind(name: \(aqint\(aq, interface: \(aqtype[T]\(aq, version: \(aqint\(aq) -> \(aqProxy[T]\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Bind an object to the display │ │ │ │ │ +.sp │ │ │ │ │ +Binds a new, client\-created object to the server using the specified │ │ │ │ │ +name as the identifier. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBname\fP (\fIArgumentType.Uint\fP) \-\- unique numeric name of the object │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBinterface\fP (\fIstring\fP) \-\- Interface name │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBversion\fP (\fIint\fP) \-\- Interface version │ │ │ │ │ +.UNINDENT │ │ │ │ │ .TP │ │ │ │ │ .B Returns │ │ │ │ │ -\fI\%WlDataDevice\fP \-\- data device to │ │ │ │ │ -create │ │ │ │ │ +\fBpywayland.client.proxy.Proxy\fP of specified Interface \-\- │ │ │ │ │ +bounded object │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B global_(name: \(aqint\(aq, interface: \(aqstr\(aq, version: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Announce global object │ │ │ │ │ +.sp │ │ │ │ │ +Notify the client of global objects. │ │ │ │ │ +.sp │ │ │ │ │ +The event notifies the client that a global object with the given name │ │ │ │ │ +is now available, and it implements the given version of the given │ │ │ │ │ +interface. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBname\fP (\fIArgumentType.Uint\fP) \-\- numeric name of the global object │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBinterface\fP (\fIArgumentType.String\fP) \-\- interface implemented by the object │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBversion\fP (\fIArgumentType.Uint\fP) \-\- interface version │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B global_remove(name: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Announce removal of global object │ │ │ │ │ +.sp │ │ │ │ │ +Notify the client of removed global objects. │ │ │ │ │ +.sp │ │ │ │ │ +This event notifies the client that the global identified by name is no │ │ │ │ │ +longer available. If the client bound to the global using the bind │ │ │ │ │ +request, the client should now destroy that object. │ │ │ │ │ +.sp │ │ │ │ │ +The object remains valid and requests to the object will be ignored │ │ │ │ │ +until the client destroys it, to avoid races between the global going │ │ │ │ │ +away and a client sending a request to it. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBname\fP (\fIArgumentType.Uint\fP) \-\- numeric name of the global object │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .SS WlSubcompositor │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ .B class pywayland.protocol.wayland.WlSubcompositor │ │ │ │ │ @@ -1259,14 +1735,85 @@ │ │ │ │ │ .TP │ │ │ │ │ .B Returns │ │ │ │ │ \fI\%WlSubsurface\fP \-\- the new sub\- │ │ │ │ │ surface object ID │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ +.SS WlShm │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlShm │ │ │ │ │ +Shared memory support │ │ │ │ │ +.sp │ │ │ │ │ +A singleton global object that provides support for shared memory. │ │ │ │ │ +.sp │ │ │ │ │ +Clients can create \fI\%WlShmPool\fP objects │ │ │ │ │ +using the create_pool request. │ │ │ │ │ +.sp │ │ │ │ │ +On binding the \fI\%WlShm\fP object one or more format events are emitted │ │ │ │ │ +to inform clients about the valid pixel formats that can be used for │ │ │ │ │ +buffers. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B create_pool(fd: \(aqint\(aq, size: \(aqint\(aq) -> \(aqProxy[WlShmPool]\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Create a shm pool │ │ │ │ │ +.sp │ │ │ │ │ +Create a new \fI\%WlShmPool\fP object. │ │ │ │ │ +.sp │ │ │ │ │ +The pool can be used to create shared memory based buffer objects. The │ │ │ │ │ +server will mmap size bytes of the passed file descriptor, to use as │ │ │ │ │ +backing memory for the pool. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBfd\fP (\fIArgumentType.FileDescriptor\fP) \-\- file descriptor for the pool │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBsize\fP (\fIArgumentType.Int\fP) \-\- pool size, in bytes │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.TP │ │ │ │ │ +.B Returns │ │ │ │ │ +\fI\%WlShmPool\fP \-\- pool to create │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B release() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Release the shm object │ │ │ │ │ +.sp │ │ │ │ │ +Using this request a client can tell the server that it is not going to │ │ │ │ │ +use the shm object anymore. │ │ │ │ │ +.sp │ │ │ │ │ +Objects created via this interface remain unaffected. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B format(format: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Pixel format description │ │ │ │ │ +.sp │ │ │ │ │ +Informs the client about a valid pixel format that can be used for │ │ │ │ │ +buffers. Known formats include argb8888 and xrgb8888. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBformat\fP (\fIArgumentType.Uint\fP) \-\- buffer pixel format │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ .SS WlShmPool │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ .B class pywayland.protocol.wayland.WlShmPool │ │ │ │ │ A shared memory pool │ │ │ │ │ .sp │ │ │ │ │ The \fI\%WlShmPool\fP object encapsulates a piece of memory shared between │ │ │ │ │ @@ -1969,292 +2516,688 @@ │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ \fBtransform\fP (\fIArgumentType.Uint\fP) \-\- preferred transform │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ -.SS WlRegion │ │ │ │ │ +.SS WlOutput │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlRegion │ │ │ │ │ -Region interface │ │ │ │ │ -.sp │ │ │ │ │ -A region object describes an area. │ │ │ │ │ +.B class pywayland.protocol.wayland.WlOutput │ │ │ │ │ +Compositor output region │ │ │ │ │ .sp │ │ │ │ │ -Region objects are used to describe the opaque and input regions of a │ │ │ │ │ -surface. │ │ │ │ │ +An output describes part of the compositor geometry. The compositor works │ │ │ │ │ +in the \(aqcompositor coordinate system\(aq and an output corresponds to a │ │ │ │ │ +rectangular area in that space that is actually visible. This typically │ │ │ │ │ +corresponds to a monitor that displays part of the compositor space. This │ │ │ │ │ +object is published as global during start up, or when a monitor is │ │ │ │ │ +hotplugged. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B destroy() -> \(aqNone\(aq │ │ │ │ │ +.B release() -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Destroy region │ │ │ │ │ +Release the output object │ │ │ │ │ .sp │ │ │ │ │ -Destroy the region. This will invalidate the object ID. │ │ │ │ │ +Using this request a client can tell the server that it is not going to │ │ │ │ │ +use the output object anymore. │ │ │ │ │ .UNINDENT │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B add(x: \(aqint\(aq, y: \(aqint\(aq, width: \(aqint\(aq, height: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.B geometry(x: \(aqint\(aq, y: \(aqint\(aq, physical_width: \(aqint\(aq, physical_height: \(aqint\(aq, subpixel: \(aqint\(aq, make: \(aqstr\(aq, model: \(aqstr\(aq, transform: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ +Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Add rectangle to region │ │ │ │ │ +Properties of the output │ │ │ │ │ .sp │ │ │ │ │ -Add the specified rectangle to the region. │ │ │ │ │ +The geometry event describes geometric properties of the output. The │ │ │ │ │ +event is sent when binding to the output object and whenever any of the │ │ │ │ │ +properties change. │ │ │ │ │ +.sp │ │ │ │ │ +The physical size can be set to zero if it doesn\(aqt make sense for this │ │ │ │ │ +output (e.g. for projectors or virtual outputs). │ │ │ │ │ +.sp │ │ │ │ │ +The geometry event will be followed by a done event (starting from │ │ │ │ │ +version 2). │ │ │ │ │ +.sp │ │ │ │ │ +Clients should use \fI\%WlSurface.preferred_buffer_transform()\fP │ │ │ │ │ +instead of the transform advertised by this event to find the preferred │ │ │ │ │ +buffer transform to use for a surface. │ │ │ │ │ +.sp │ │ │ │ │ +Note: \fI\%WlOutput\fP only advertises partial information about the │ │ │ │ │ +output position and identification. Some compositors, for instance │ │ │ │ │ +those not implementing a desktop\-style output layout or those exposing │ │ │ │ │ +virtual outputs, might fake this information. Instead of using x and y, │ │ │ │ │ +clients should use xdg_output.logical_position. Instead of using make │ │ │ │ │ +and model, clients should use name and description. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBx\fP (\fIArgumentType.Int\fP) \-\- region\-local x coordinate │ │ │ │ │ +\fBx\fP (\fIArgumentType.Int\fP) \-\- x position within the global compositor space │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBy\fP (\fIArgumentType.Int\fP) \-\- region\-local y coordinate │ │ │ │ │ +\fBy\fP (\fIArgumentType.Int\fP) \-\- y position within the global compositor space │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBwidth\fP (\fIArgumentType.Int\fP) \-\- rectangle width │ │ │ │ │ +\fBphysical_width\fP (\fIArgumentType.Int\fP) \-\- width in millimeters of the output │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBheight\fP (\fIArgumentType.Int\fP) \-\- rectangle height │ │ │ │ │ +\fBphysical_height\fP (\fIArgumentType.Int\fP) \-\- height in millimeters of the output │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBsubpixel\fP (\fIArgumentType.Int\fP) \-\- subpixel orientation of the output │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBmake\fP (\fIArgumentType.String\fP) \-\- textual description of the manufacturer │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBmodel\fP (\fIArgumentType.String\fP) \-\- textual description of the model │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBtransform\fP (\fIArgumentType.Int\fP) \-\- additional transformation applied to buffer contents during │ │ │ │ │ +presentation │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B subtract(x: \(aqint\(aq, y: \(aqint\(aq, width: \(aqint\(aq, height: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.B mode(flags: \(aqint\(aq, width: \(aqint\(aq, height: \(aqint\(aq, refresh: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -Request \-\- opcode 2 (attached to \fBResource\fP instance) │ │ │ │ │ +Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Subtract rectangle from region │ │ │ │ │ +Advertise available modes for the output │ │ │ │ │ .sp │ │ │ │ │ -Subtract the specified rectangle from the region. │ │ │ │ │ +The mode event describes an available mode for the output. │ │ │ │ │ +.sp │ │ │ │ │ +The event is sent when binding to the output object and there will │ │ │ │ │ +always be one mode, the current mode. The event is sent again if an │ │ │ │ │ +output changes mode, for the mode that is now current. In other words, │ │ │ │ │ +the current mode is always the last mode that was received with the │ │ │ │ │ +current flag set. │ │ │ │ │ +.sp │ │ │ │ │ +Non\-current modes are deprecated. A compositor can decide to only │ │ │ │ │ +advertise the current mode and never send other modes. Clients should │ │ │ │ │ +not rely on non\-current modes. │ │ │ │ │ +.sp │ │ │ │ │ +The size of a mode is given in physical hardware units of the output │ │ │ │ │ +device. This is not necessarily the same as the output size in the │ │ │ │ │ +global compositor space. For instance, the output may be scaled, as │ │ │ │ │ +described in \fI\%WlOutput.scale()\fP, or transformed, as described in │ │ │ │ │ +\fBWlOutput.transform()\fP\&. Clients willing to retrieve the output │ │ │ │ │ +size in the global compositor space should use xdg_output.logical_size │ │ │ │ │ +instead. │ │ │ │ │ +.sp │ │ │ │ │ +The vertical refresh rate can be set to zero if it doesn\(aqt make sense │ │ │ │ │ +for this output (e.g. for virtual outputs). │ │ │ │ │ +.sp │ │ │ │ │ +The mode event will be followed by a done event (starting from version │ │ │ │ │ +2). │ │ │ │ │ +.sp │ │ │ │ │ +Clients should not use the refresh rate to schedule frames. Instead, │ │ │ │ │ +they should use the \fI\%WlSurface.frame()\fP event or the │ │ │ │ │ +presentation\-time protocol. │ │ │ │ │ +.sp │ │ │ │ │ +Note: this information is not always meaningful for all outputs. Some │ │ │ │ │ +compositors, such as those exposing virtual outputs, might fake the │ │ │ │ │ +refresh rate or the size. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBx\fP (\fIArgumentType.Int\fP) \-\- region\-local x coordinate │ │ │ │ │ +\fBflags\fP (\fIArgumentType.Uint\fP) \-\- bitfield of mode flags │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBy\fP (\fIArgumentType.Int\fP) \-\- region\-local y coordinate │ │ │ │ │ +\fBwidth\fP (\fIArgumentType.Int\fP) \-\- width of the mode in hardware units │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBwidth\fP (\fIArgumentType.Int\fP) \-\- rectangle width │ │ │ │ │ +\fBheight\fP (\fIArgumentType.Int\fP) \-\- height of the mode in hardware units │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBheight\fP (\fIArgumentType.Int\fP) \-\- rectangle height │ │ │ │ │ -.UNINDENT │ │ │ │ │ +\fBrefresh\fP (\fIArgumentType.Int\fP) \-\- vertical refresh rate in mHz │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ -.SS WlDataSource │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlDataSource │ │ │ │ │ -Offer to transfer data │ │ │ │ │ +.B done() -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -The \fI\%WlDataSource\fP object is the source side of a │ │ │ │ │ -\fI\%WlDataOffer\fP\&. It is created by the │ │ │ │ │ -source client in a data transfer and provides a way to describe the offered │ │ │ │ │ -data and a way to respond to requests to transfer the data. │ │ │ │ │ +Event \-\- opcode 2 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Sent all information about output │ │ │ │ │ +.sp │ │ │ │ │ +This event is sent after all other properties have been sent after │ │ │ │ │ +binding to the output object and after any other property changes done │ │ │ │ │ +after that. This allows changes to the output properties to be seen as │ │ │ │ │ +atomic, even if they happen via multiple events. │ │ │ │ │ +.UNINDENT │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B offer(mime_type: \(aqstr\(aq) -> \(aqNone\(aq │ │ │ │ │ +.B scale(factor: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ +Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Add an offered mime type │ │ │ │ │ +Output scaling properties │ │ │ │ │ .sp │ │ │ │ │ -This request adds a mime type to the set of mime types advertised to │ │ │ │ │ -targets. Can be called several times to offer multiple types. │ │ │ │ │ +This event contains scaling geometry information that is not in the │ │ │ │ │ +geometry event. It may be sent after binding the output object or if │ │ │ │ │ +the output scale changes later. The compositor will emit a non\-zero, │ │ │ │ │ +positive value for scale. If it is not sent, the client should assume a │ │ │ │ │ +scale of 1. │ │ │ │ │ +.sp │ │ │ │ │ +A scale larger than 1 means that the compositor will automatically │ │ │ │ │ +scale surface buffers by this amount when rendering. This is used for │ │ │ │ │ +very high resolution displays where applications rendering at the │ │ │ │ │ +native resolution would be too small to be legible. │ │ │ │ │ +.sp │ │ │ │ │ +Clients should use \fI\%WlSurface.preferred_buffer_scale()\fP instead │ │ │ │ │ +of this event to find the preferred buffer scale to use for a surface. │ │ │ │ │ +.sp │ │ │ │ │ +The scale event will be followed by a done event. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ -\fBmime_type\fP (\fIArgumentType.String\fP) \-\- mime type offered by the data source │ │ │ │ │ +\fBfactor\fP (\fIArgumentType.Int\fP) \-\- scaling factor of output │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B destroy() -> \(aqNone\(aq │ │ │ │ │ +.B name(name: \(aqstr\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ +Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Destroy the data source │ │ │ │ │ +Name of this output │ │ │ │ │ .sp │ │ │ │ │ -Destroy the data source. │ │ │ │ │ +Many compositors will assign user\-friendly names to their outputs, show │ │ │ │ │ +them to the user, allow the user to refer to an output, etc. The client │ │ │ │ │ +may wish to know this name as well to offer the user similar behaviors. │ │ │ │ │ +.sp │ │ │ │ │ +The name is a UTF\-8 string with no convention defined for its contents. │ │ │ │ │ +Each name is unique among all \fI\%WlOutput\fP globals. The name is │ │ │ │ │ +only guaranteed to be unique for the compositor instance. │ │ │ │ │ +.sp │ │ │ │ │ +The same output name is used for all clients for a given │ │ │ │ │ +\fI\%WlOutput\fP global. Thus, the name can be shared across processes │ │ │ │ │ +to refer to a specific \fI\%WlOutput\fP global. │ │ │ │ │ +.sp │ │ │ │ │ +The name is not guaranteed to be persistent across sessions, thus │ │ │ │ │ +cannot be used to reliably identify an output in e.g. configuration │ │ │ │ │ +files. │ │ │ │ │ +.sp │ │ │ │ │ +Examples of names include \(aqHDMI\-A\-1\(aq, \(aqWL\-1\(aq, \(aqX11\-1\(aq, etc. However, do │ │ │ │ │ +not assume that the name is a reflection of an underlying DRM │ │ │ │ │ +connector, X11 connection, etc. │ │ │ │ │ +.sp │ │ │ │ │ +The name event is sent after binding the output object. This event is │ │ │ │ │ +only sent once per output object, and the name does not change over the │ │ │ │ │ +lifetime of the \fI\%WlOutput\fP global. │ │ │ │ │ +.sp │ │ │ │ │ +Compositors may re\-use the same output name if the \fI\%WlOutput\fP │ │ │ │ │ +global is destroyed and re\-created later. Compositors should avoid re\- │ │ │ │ │ +using the same name if possible. │ │ │ │ │ +.sp │ │ │ │ │ +The name event will be followed by a done event. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBname\fP (\fIArgumentType.String\fP) \-\- output name │ │ │ │ │ +.UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B set_actions(dnd_actions: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.B description(description: \(aqstr\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -Request \-\- opcode 2 (attached to \fBResource\fP instance) │ │ │ │ │ +Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Set the available drag\-and\-drop actions │ │ │ │ │ +Human\-readable description of this output │ │ │ │ │ .sp │ │ │ │ │ -Sets the actions that the source side client supports for this │ │ │ │ │ -operation. This request may trigger \fI\%WlDataSource.action()\fP and │ │ │ │ │ -\fI\%WlDataOffer.action()\fP events if the │ │ │ │ │ -compositor needs to change the selected action. │ │ │ │ │ +Many compositors can produce human\-readable descriptions of their │ │ │ │ │ +outputs. The client may wish to know this description as well, e.g. for │ │ │ │ │ +output selection purposes. │ │ │ │ │ .sp │ │ │ │ │ -The dnd_actions argument must contain only values expressed in the │ │ │ │ │ -\fBWlDataDeviceManager.dnd_actions()\fP enum, │ │ │ │ │ -otherwise it will result in a protocol error. │ │ │ │ │ +The description is a UTF\-8 string with no convention defined for its │ │ │ │ │ +contents. The description is not guaranteed to be unique among all │ │ │ │ │ +\fI\%WlOutput\fP globals. Examples might include \(aqFoocorp 11\(dq Display\(aq │ │ │ │ │ +or \(aqVirtual X11 output via :1\(aq. │ │ │ │ │ .sp │ │ │ │ │ -This request must be made once only, and can only be made on sources │ │ │ │ │ -used in drag\-and\-drop, so it must be performed before │ │ │ │ │ -\fI\%WlDataDevice.start_drag()\fP\&. Attempting to │ │ │ │ │ -use the source other than for drag\-and\-drop will raise a protocol │ │ │ │ │ -error. │ │ │ │ │ +The description event is sent after binding the output object and │ │ │ │ │ +whenever the description changes. The description is optional, and may │ │ │ │ │ +not be sent at all. │ │ │ │ │ +.sp │ │ │ │ │ +The description event will be followed by a done event. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ -\fBdnd_actions\fP (\fIArgumentType.Uint\fP) \-\- actions supported by the data source │ │ │ │ │ +\fBdescription\fP (\fIArgumentType.String\fP) \-\- output description │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.SS WlKeyboard │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlKeyboard │ │ │ │ │ +Keyboard input device │ │ │ │ │ +.sp │ │ │ │ │ +The \fI\%WlKeyboard\fP interface represents one or more keyboards │ │ │ │ │ +associated with a seat. │ │ │ │ │ +.sp │ │ │ │ │ +Each \fI\%WlKeyboard\fP has the following logical state: │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +an active surface (possibly null), │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +the keys currently logically down, │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +the active modifiers, │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +the active group. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.sp │ │ │ │ │ +By default, the active surface is null, the keys currently logically down │ │ │ │ │ +are empty, the active modifiers and the active group are 0. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B target(mime_type: \(aqstr | None\(aq) -> \(aqNone\(aq │ │ │ │ │ +.B release() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Release the keyboard object │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B keymap(format: \(aqint\(aq, fd: \(aqint\(aq, size: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -A target accepts an offered mime type │ │ │ │ │ +Keyboard mapping │ │ │ │ │ .sp │ │ │ │ │ -Sent when a target accepts pointer_focus or motion events. If a target │ │ │ │ │ -does not accept any of the offered types, type is NULL. │ │ │ │ │ +This event provides a file descriptor to the client which can be │ │ │ │ │ +memory\-mapped in read\-only mode to provide a keyboard mapping │ │ │ │ │ +description. │ │ │ │ │ .sp │ │ │ │ │ -Used for feedback during drag\-and\-drop. │ │ │ │ │ +From version 7 onwards, the fd must be mapped with MAP_PRIVATE by the │ │ │ │ │ +recipient, as MAP_SHARED may fail. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ -\fBmime_type\fP (\fIArgumentType.String\fP or \fINone\fP) \-\- mime type accepted by the target │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBformat\fP (\fIArgumentType.Uint\fP) \-\- keymap format │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBfd\fP (\fIArgumentType.FileDescriptor\fP) \-\- keymap file descriptor │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBsize\fP (\fIArgumentType.Uint\fP) \-\- keymap size, in bytes │ │ │ │ │ +.UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B send(mime_type: \(aqstr\(aq, fd: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.B enter(serial: \(aqint\(aq, surface: \(aqWlSurface\(aq, keys: \(aqlist\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Send the data │ │ │ │ │ +Enter event │ │ │ │ │ .sp │ │ │ │ │ -Request for data from the client. Send the data as the specified mime │ │ │ │ │ -type over the passed file descriptor, then close it. │ │ │ │ │ +Notification that this seat\(aqs keyboard focus is on a certain surface. │ │ │ │ │ +.sp │ │ │ │ │ +The compositor must send the \fI\%WlKeyboard.modifiers()\fP event after │ │ │ │ │ +this event. │ │ │ │ │ +.sp │ │ │ │ │ +In the \fI\%WlKeyboard\fP logical state, this event sets the active │ │ │ │ │ +surface to the surface argument and the keys currently logically down │ │ │ │ │ +to the keys in the keys argument. The compositor must not send this │ │ │ │ │ +event if the \fI\%WlKeyboard\fP already had an active surface │ │ │ │ │ +immediately before this event. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBmime_type\fP (\fIArgumentType.String\fP) \-\- mime type for the data │ │ │ │ │ +\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the enter event │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -\fBfd\fP (\fIArgumentType.FileDescriptor\fP) \-\- file descriptor for the data │ │ │ │ │ +\fBsurface\fP (\fI\%WlSurface\fP) \-\- surface gaining keyboard focus │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBkeys\fP (\fIArgumentType.Array\fP) \-\- the keys currently logically down │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B cancelled() -> \(aqNone\(aq │ │ │ │ │ +.B leave(serial: \(aqint\(aq, surface: \(aqWlSurface\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ Event \-\- opcode 2 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Selection was cancelled │ │ │ │ │ +Leave event │ │ │ │ │ .sp │ │ │ │ │ -This data source is no longer valid. There are several reasons why this │ │ │ │ │ -could happen: │ │ │ │ │ +Notification that this seat\(aqs keyboard focus is no longer on a certain │ │ │ │ │ +surface. │ │ │ │ │ +.sp │ │ │ │ │ +The leave notification is sent before the enter notification for the │ │ │ │ │ +new focus. │ │ │ │ │ +.sp │ │ │ │ │ +In the \fI\%WlKeyboard\fP logical state, this event resets all values │ │ │ │ │ +to their defaults. The compositor must not send this event if the │ │ │ │ │ +active surface of the \fI\%WlKeyboard\fP was not equal to the surface │ │ │ │ │ +argument immediately before this event. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -The data source has been replaced by another data source. │ │ │ │ │ +\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the leave event │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -The drag\-and\-drop operation was performed, but the drop destination │ │ │ │ │ -did not accept any of the mime types offered through │ │ │ │ │ -\fI\%WlDataSource.target()\fP\&. │ │ │ │ │ +\fBsurface\fP (\fI\%WlSurface\fP) \-\- surface that lost keyboard focus │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B key(serial: \(aqint\(aq, time: \(aqint\(aq, key: \(aqint\(aq, state: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Key event │ │ │ │ │ +.sp │ │ │ │ │ +A key was pressed or released. The time argument is a timestamp with │ │ │ │ │ +millisecond granularity, with an undefined base. │ │ │ │ │ +.sp │ │ │ │ │ +The key is a platform\-specific key code that can be interpreted by │ │ │ │ │ +feeding it to the keyboard mapping (see the keymap event). │ │ │ │ │ +.sp │ │ │ │ │ +If this event produces a change in modifiers, then the resulting │ │ │ │ │ +\fI\%WlKeyboard.modifiers()\fP event must be sent after this event. │ │ │ │ │ +.sp │ │ │ │ │ +In the \fI\%WlKeyboard\fP logical state, this event adds the key to │ │ │ │ │ +the keys currently logically down (if the state argument is pressed) or │ │ │ │ │ +removes the key from the keys currently logically down (if the state │ │ │ │ │ +argument is released). The compositor must not send this event if the │ │ │ │ │ +\fI\%WlKeyboard\fP did not have an active surface immediately before │ │ │ │ │ +this event. The compositor must not send this event if state is pressed │ │ │ │ │ +(resp. released) and the key was already logically down (resp. was not │ │ │ │ │ +logically down) immediately before this event. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -The drag\-and\-drop operation was performed, but the drop destination │ │ │ │ │ -did not select any of the actions present in the mask offered through │ │ │ │ │ -\fI\%WlDataSource.action()\fP\&. │ │ │ │ │ +\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the key event │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -The drag\-and\-drop operation was performed but didn\(aqt happen over a │ │ │ │ │ -surface. │ │ │ │ │ +\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ -The compositor cancelled the drag\-and\-drop operation (e.g. compositor │ │ │ │ │ -dependent timeouts to avoid stale drag\-and\-drop transfers). │ │ │ │ │ +\fBkey\fP (\fIArgumentType.Uint\fP) \-\- key that produced the event │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBstate\fP (\fIArgumentType.Uint\fP) \-\- physical state of the key │ │ │ │ │ .UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B modifiers(serial: \(aqint\(aq, mods_depressed: \(aqint\(aq, mods_latched: \(aqint\(aq, mods_locked: \(aqint\(aq, group: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -The client should clean up and destroy this data source. │ │ │ │ │ +Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -For objects of version 2 or older, \fI\%WlDataSource.cancelled()\fP │ │ │ │ │ -will only be emitted if the data source was replaced by another data │ │ │ │ │ -source. │ │ │ │ │ +Modifier and group state │ │ │ │ │ +.sp │ │ │ │ │ +Notifies clients that the modifier and/or group state has changed, and │ │ │ │ │ +it should update its local state. │ │ │ │ │ +.sp │ │ │ │ │ +The compositor may send this event without a surface of the client │ │ │ │ │ +having keyboard focus, for example to tie modifier information to │ │ │ │ │ +pointer focus instead. If a modifier event with pressed modifiers is │ │ │ │ │ +sent without a prior enter event, the client can assume the modifier │ │ │ │ │ +state is valid until it receives the next │ │ │ │ │ +\fI\%WlKeyboard.modifiers()\fP event. In order to reset the modifier │ │ │ │ │ +state again, the compositor can send a \fI\%WlKeyboard.modifiers()\fP │ │ │ │ │ +event with no pressed modifiers. │ │ │ │ │ +.sp │ │ │ │ │ +In the \fI\%WlKeyboard\fP logical state, this event updates the │ │ │ │ │ +modifiers and group. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the modifiers event │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBmods_depressed\fP (\fIArgumentType.Uint\fP) \-\- depressed modifiers │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBmods_latched\fP (\fIArgumentType.Uint\fP) \-\- latched modifiers │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBmods_locked\fP (\fIArgumentType.Uint\fP) \-\- locked modifiers │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBgroup\fP (\fIArgumentType.Uint\fP) \-\- keyboard layout │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B dnd_drop_performed() -> \(aqNone\(aq │ │ │ │ │ +.B repeat_info(rate: \(aqint\(aq, delay: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ .sp │ │ │ │ │ -Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ +Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -The drag\-and\-drop operation physically finished │ │ │ │ │ +Repeat rate and delay │ │ │ │ │ .sp │ │ │ │ │ -The user performed the drop action. This event does not indicate │ │ │ │ │ -acceptance, \fI\%WlDataSource.cancelled()\fP may still be emitted │ │ │ │ │ -afterwards if the drop destination does not accept any mime type. │ │ │ │ │ +Informs the client about the keyboard\(aqs repeat rate and delay. │ │ │ │ │ .sp │ │ │ │ │ -However, this event might however not be received if the compositor │ │ │ │ │ -cancelled the drag\-and\-drop operation before this event could happen. │ │ │ │ │ +This event is sent as soon as the \fI\%WlKeyboard\fP object has been │ │ │ │ │ +created, and is guaranteed to be received by the client before any key │ │ │ │ │ +press event. │ │ │ │ │ .sp │ │ │ │ │ -Note that the data_source may still be used in the future and should │ │ │ │ │ -not be destroyed here. │ │ │ │ │ +Negative values for either rate or delay are illegal. A rate of zero │ │ │ │ │ +will disable any repeating (regardless of the value of delay). │ │ │ │ │ +.sp │ │ │ │ │ +This event can be sent later on as well with a new value if necessary, │ │ │ │ │ +so clients should continue listening for the event past the creation of │ │ │ │ │ +\fI\%WlKeyboard\fP\&. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBrate\fP (\fIArgumentType.Int\fP) \-\- the rate of repeating keys in characters per second │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBdelay\fP (\fIArgumentType.Int\fP) \-\- delay in milliseconds since key down until repeating starts │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.SS WlCompositor │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlCompositor │ │ │ │ │ +The compositor singleton │ │ │ │ │ +.sp │ │ │ │ │ +A compositor. This object is a singleton global. The compositor is in │ │ │ │ │ +charge of combining the contents of multiple surfaces into one displayable │ │ │ │ │ +output. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B dnd_finished() -> \(aqNone\(aq │ │ │ │ │ +.B create_surface() -> \(aqProxy[WlSurface]\(aq │ │ │ │ │ .sp │ │ │ │ │ -Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -The drag\-and\-drop operation concluded │ │ │ │ │ +Create new surface │ │ │ │ │ .sp │ │ │ │ │ -The drop destination finished interoperating with this data source, so │ │ │ │ │ -the client is now free to destroy this data source and free all │ │ │ │ │ -associated data. │ │ │ │ │ +Ask the compositor to create a new surface. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Returns │ │ │ │ │ +\fI\%WlSurface\fP \-\- the new surface │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B create_region() -> \(aqProxy[WlRegion]\(aq │ │ │ │ │ .sp │ │ │ │ │ -If the action used to perform the operation was \(dqmove\(dq, the source can │ │ │ │ │ -now delete the transferred data. │ │ │ │ │ +Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Create new region │ │ │ │ │ +.sp │ │ │ │ │ +Ask the compositor to create a new region. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Returns │ │ │ │ │ +\fI\%WlRegion\fP \-\- the new region │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ +.SS WlSeat │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlSeat │ │ │ │ │ +Group of input devices │ │ │ │ │ +.sp │ │ │ │ │ +A seat is a group of keyboards, pointer and touch devices. This object is │ │ │ │ │ +published as a global during start up, or when such a device is hot │ │ │ │ │ +plugged. A seat typically has a pointer and maintains a keyboard focus and │ │ │ │ │ +a pointer focus. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ -.B action(dnd_action: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.B get_pointer() -> \(aqProxy[WlPointer]\(aq │ │ │ │ │ .sp │ │ │ │ │ -Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Notify the selected action │ │ │ │ │ +Return pointer object │ │ │ │ │ .sp │ │ │ │ │ -This event indicates the action selected by the compositor after │ │ │ │ │ -matching the source/destination side actions. Only one action (or none) │ │ │ │ │ -will be offered here. │ │ │ │ │ +The ID provided will be initialized to the │ │ │ │ │ +\fI\%WlPointer\fP interface for this seat. │ │ │ │ │ .sp │ │ │ │ │ -This event can be emitted multiple times during the drag\-and\-drop │ │ │ │ │ -operation, mainly in response to destination side changes through │ │ │ │ │ -\fI\%WlDataOffer.set_actions()\fP, and as the data │ │ │ │ │ -device enters/leaves surfaces. │ │ │ │ │ +This request only takes effect if the seat has the pointer capability, │ │ │ │ │ +or has had the pointer capability in the past. It is a protocol │ │ │ │ │ +violation to issue this request on a seat that has never had the │ │ │ │ │ +pointer capability. The missing_capability error will be sent in this │ │ │ │ │ +case. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Returns │ │ │ │ │ +\fI\%WlPointer\fP \-\- seat pointer │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B get_keyboard() -> \(aqProxy[WlKeyboard]\(aq │ │ │ │ │ .sp │ │ │ │ │ -It is only possible to receive this event after │ │ │ │ │ -\fI\%WlDataSource.dnd_drop_performed()\fP if the drag\-and\-drop │ │ │ │ │ -operation ended in an \(dqask\(dq action, in which case the final │ │ │ │ │ -\fI\%WlDataSource.action()\fP event will happen immediately before │ │ │ │ │ -\fI\%WlDataSource.dnd_finished()\fP\&. │ │ │ │ │ +Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ .sp │ │ │ │ │ -Compositors may also change the selected action on the fly, mainly in │ │ │ │ │ -response to keyboard modifier changes during the drag\-and\-drop │ │ │ │ │ -operation. │ │ │ │ │ +Return keyboard object │ │ │ │ │ .sp │ │ │ │ │ -The most recent action received is always the valid one. The chosen │ │ │ │ │ -action may change alongside negotiation (e.g. an \(dqask\(dq action can turn │ │ │ │ │ -into a \(dqmove\(dq operation), so the effects of the final action must │ │ │ │ │ -always be applied in \fBWlDataOffer.dnd_finished()\fP\&. │ │ │ │ │ +The ID provided will be initialized to the │ │ │ │ │ +\fI\%WlKeyboard\fP interface for this │ │ │ │ │ +seat. │ │ │ │ │ .sp │ │ │ │ │ -Clients can trigger cursor surface changes from this point, so they │ │ │ │ │ -reflect the current action. │ │ │ │ │ +This request only takes effect if the seat has the keyboard capability, │ │ │ │ │ +or has had the keyboard capability in the past. It is a protocol │ │ │ │ │ +violation to issue this request on a seat that has never had the │ │ │ │ │ +keyboard capability. The missing_capability error will be sent in this │ │ │ │ │ +case. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Returns │ │ │ │ │ +\fI\%WlKeyboard\fP \-\- seat keyboard │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B get_touch() -> \(aqProxy[WlTouch]\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 2 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Return touch object │ │ │ │ │ +.sp │ │ │ │ │ +The ID provided will be initialized to the │ │ │ │ │ +\fI\%WlTouch\fP interface for this seat. │ │ │ │ │ +.sp │ │ │ │ │ +This request only takes effect if the seat has the touch capability, or │ │ │ │ │ +has had the touch capability in the past. It is a protocol violation to │ │ │ │ │ +issue this request on a seat that has never had the touch capability. │ │ │ │ │ +The missing_capability error will be sent in this case. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Returns │ │ │ │ │ +\fI\%WlTouch\fP \-\- seat touch │ │ │ │ │ +interface │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B release() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 3 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Release the seat object │ │ │ │ │ +.sp │ │ │ │ │ +Using this request a client can tell the server that it is not going to │ │ │ │ │ +use the seat object anymore. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B capabilities(capabilities: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Seat capabilities changed │ │ │ │ │ +.sp │ │ │ │ │ +This is emitted whenever a seat gains or loses the pointer, keyboard or │ │ │ │ │ +touch capabilities. The argument is a capability enum containing the │ │ │ │ │ +complete set of capabilities this seat has. │ │ │ │ │ +.sp │ │ │ │ │ +When the pointer capability is added, a client may create a │ │ │ │ │ +\fI\%WlPointer\fP object using the │ │ │ │ │ +\fI\%WlSeat.get_pointer()\fP request. This object will receive pointer │ │ │ │ │ +events until the capability is removed in the future. │ │ │ │ │ +.sp │ │ │ │ │ +When the pointer capability is removed, a client should destroy the │ │ │ │ │ +\fI\%WlPointer\fP objects associated with │ │ │ │ │ +the seat where the capability was removed, using the │ │ │ │ │ +\fI\%WlPointer.release()\fP request. No further │ │ │ │ │ +pointer events will be received on these objects. │ │ │ │ │ +.sp │ │ │ │ │ +In some compositors, if a seat regains the pointer capability and a │ │ │ │ │ +client has a previously obtained │ │ │ │ │ +\fI\%WlPointer\fP object of version 4 or │ │ │ │ │ +less, that object may start sending pointer events again. This behavior │ │ │ │ │ +is considered a misinterpretation of the intended behavior and must not │ │ │ │ │ +be relied upon by the client. │ │ │ │ │ +\fI\%WlPointer\fP objects of version 5 or │ │ │ │ │ +later must not send events if created before the most recent event │ │ │ │ │ +notifying the client of an added pointer capability. │ │ │ │ │ +.sp │ │ │ │ │ +The above behavior also applies to │ │ │ │ │ +\fI\%WlKeyboard\fP and │ │ │ │ │ +\fI\%WlTouch\fP with the keyboard and │ │ │ │ │ +touch capabilities, respectively. │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ -\fBdnd_action\fP (\fIArgumentType.Uint\fP) \-\- action selected by the compositor │ │ │ │ │ +\fBcapabilities\fP (\fIArgumentType.Uint\fP) \-\- capabilities of the seat │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B name(name: \(aqstr\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Unique identifier for this seat │ │ │ │ │ +.sp │ │ │ │ │ +In a multi\-seat configuration the seat name can be used by clients to │ │ │ │ │ +help identify which physical devices the seat represents. │ │ │ │ │ +.sp │ │ │ │ │ +The seat name is a UTF\-8 string with no convention defined for its │ │ │ │ │ +contents. Each name is unique among all \fI\%WlSeat\fP globals. The │ │ │ │ │ +name is only guaranteed to be unique for the current compositor │ │ │ │ │ +instance. │ │ │ │ │ +.sp │ │ │ │ │ +The same seat names are used for all clients. Thus, the name can be │ │ │ │ │ +shared across processes to refer to a specific \fI\%WlSeat\fP global. │ │ │ │ │ +.sp │ │ │ │ │ +The name event is sent after binding to the seat global. This event is │ │ │ │ │ +only sent once per seat object, and the name does not change over the │ │ │ │ │ +lifetime of the \fI\%WlSeat\fP global. │ │ │ │ │ +.sp │ │ │ │ │ +Compositors may re\-use the same seat name if the \fI\%WlSeat\fP global │ │ │ │ │ +is destroyed and re\-created later. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBname\fP (\fIArgumentType.String\fP) \-\- seat identifier │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .SS WlDataOffer │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ .B class pywayland.protocol.wayland.WlDataOffer │ │ │ │ │ @@ -2496,14 +3439,437 @@ │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ \fBdnd_action\fP (\fIArgumentType.Uint\fP) \-\- action selected by the compositor │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ +.SS WlBuffer │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlBuffer │ │ │ │ │ +Content for a \fI\%WlSurface\fP │ │ │ │ │ +.sp │ │ │ │ │ +A buffer provides the content for a │ │ │ │ │ +\fI\%WlSurface\fP\&. Buffers are created through │ │ │ │ │ +factory interfaces such as \fI\%WlShm\fP, │ │ │ │ │ +wp_linux_buffer_params (from the linux\-dmabuf protocol extension) or │ │ │ │ │ +similar. It has a width and a height and can be attached to a │ │ │ │ │ +\fI\%WlSurface\fP, but the mechanism by which │ │ │ │ │ +a client provides and updates the contents is defined by the buffer factory │ │ │ │ │ +interface. │ │ │ │ │ +.sp │ │ │ │ │ +Color channels are assumed to be electrical rather than optical (in other │ │ │ │ │ +words, encoded with a transfer function) unless otherwise specified. If the │ │ │ │ │ +buffer uses a format that has an alpha channel, the alpha channel is │ │ │ │ │ +assumed to be premultiplied into the electrical color channel values (after │ │ │ │ │ +transfer function encoding) unless otherwise specified. │ │ │ │ │ +.sp │ │ │ │ │ +Note, because \fI\%WlBuffer\fP objects are created from multiple │ │ │ │ │ +independent factory interfaces, the \fI\%WlBuffer\fP interface is frozen │ │ │ │ │ +at version 1. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B destroy() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Destroy a buffer │ │ │ │ │ +.sp │ │ │ │ │ +Destroy a buffer. If and how you need to release the backing storage is │ │ │ │ │ +defined by the buffer factory interface. │ │ │ │ │ +.sp │ │ │ │ │ +For possible side\-effects to a surface, see \fI\%WlSurface.attach()\fP\&. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B release() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Compositor releases buffer │ │ │ │ │ +.sp │ │ │ │ │ +Sent when this \fI\%WlBuffer\fP is no longer used by the compositor. │ │ │ │ │ +The client is now free to reuse or destroy this buffer and its backing │ │ │ │ │ +storage. │ │ │ │ │ +.sp │ │ │ │ │ +If a client receives a release event before the frame callback │ │ │ │ │ +requested in the same \fI\%WlSurface.commit()\fP that attaches this │ │ │ │ │ +\fI\%WlBuffer\fP to a surface, then the client is immediately free to │ │ │ │ │ +reuse the buffer and its backing storage, and does not need a second │ │ │ │ │ +buffer for the next surface content update. Typically this is possible, │ │ │ │ │ +when the compositor maintains a copy of the │ │ │ │ │ +\fI\%WlSurface\fP contents, e.g. as a GL │ │ │ │ │ +texture. This is an important optimization for GL(ES) compositors with │ │ │ │ │ +\fI\%WlShm\fP clients. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.SS WlDataSource │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlDataSource │ │ │ │ │ +Offer to transfer data │ │ │ │ │ +.sp │ │ │ │ │ +The \fI\%WlDataSource\fP object is the source side of a │ │ │ │ │ +\fI\%WlDataOffer\fP\&. It is created by the │ │ │ │ │ +source client in a data transfer and provides a way to describe the offered │ │ │ │ │ +data and a way to respond to requests to transfer the data. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B offer(mime_type: \(aqstr\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Add an offered mime type │ │ │ │ │ +.sp │ │ │ │ │ +This request adds a mime type to the set of mime types advertised to │ │ │ │ │ +targets. Can be called several times to offer multiple types. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBmime_type\fP (\fIArgumentType.String\fP) \-\- mime type offered by the data source │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B destroy() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Destroy the data source │ │ │ │ │ +.sp │ │ │ │ │ +Destroy the data source. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B set_actions(dnd_actions: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 2 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Set the available drag\-and\-drop actions │ │ │ │ │ +.sp │ │ │ │ │ +Sets the actions that the source side client supports for this │ │ │ │ │ +operation. This request may trigger \fI\%WlDataSource.action()\fP and │ │ │ │ │ +\fI\%WlDataOffer.action()\fP events if the │ │ │ │ │ +compositor needs to change the selected action. │ │ │ │ │ +.sp │ │ │ │ │ +The dnd_actions argument must contain only values expressed in the │ │ │ │ │ +\fBWlDataDeviceManager.dnd_actions()\fP enum, │ │ │ │ │ +otherwise it will result in a protocol error. │ │ │ │ │ +.sp │ │ │ │ │ +This request must be made once only, and can only be made on sources │ │ │ │ │ +used in drag\-and\-drop, so it must be performed before │ │ │ │ │ +\fI\%WlDataDevice.start_drag()\fP\&. Attempting to │ │ │ │ │ +use the source other than for drag\-and\-drop will raise a protocol │ │ │ │ │ +error. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBdnd_actions\fP (\fIArgumentType.Uint\fP) \-\- actions supported by the data source │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B target(mime_type: \(aqstr | None\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +A target accepts an offered mime type │ │ │ │ │ +.sp │ │ │ │ │ +Sent when a target accepts pointer_focus or motion events. If a target │ │ │ │ │ +does not accept any of the offered types, type is NULL. │ │ │ │ │ +.sp │ │ │ │ │ +Used for feedback during drag\-and\-drop. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBmime_type\fP (\fIArgumentType.String\fP or \fINone\fP) \-\- mime type accepted by the target │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B send(mime_type: \(aqstr\(aq, fd: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Send the data │ │ │ │ │ +.sp │ │ │ │ │ +Request for data from the client. Send the data as the specified mime │ │ │ │ │ +type over the passed file descriptor, then close it. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBmime_type\fP (\fIArgumentType.String\fP) \-\- mime type for the data │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBfd\fP (\fIArgumentType.FileDescriptor\fP) \-\- file descriptor for the data │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B cancelled() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 2 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Selection was cancelled │ │ │ │ │ +.sp │ │ │ │ │ +This data source is no longer valid. There are several reasons why this │ │ │ │ │ +could happen: │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +The data source has been replaced by another data source. │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +The drag\-and\-drop operation was performed, but the drop destination │ │ │ │ │ +did not accept any of the mime types offered through │ │ │ │ │ +\fI\%WlDataSource.target()\fP\&. │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +The drag\-and\-drop operation was performed, but the drop destination │ │ │ │ │ +did not select any of the actions present in the mask offered through │ │ │ │ │ +\fI\%WlDataSource.action()\fP\&. │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +The drag\-and\-drop operation was performed but didn\(aqt happen over a │ │ │ │ │ +surface. │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +The compositor cancelled the drag\-and\-drop operation (e.g. compositor │ │ │ │ │ +dependent timeouts to avoid stale drag\-and\-drop transfers). │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.sp │ │ │ │ │ +The client should clean up and destroy this data source. │ │ │ │ │ +.sp │ │ │ │ │ +For objects of version 2 or older, \fI\%WlDataSource.cancelled()\fP │ │ │ │ │ +will only be emitted if the data source was replaced by another data │ │ │ │ │ +source. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B dnd_drop_performed() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +The drag\-and\-drop operation physically finished │ │ │ │ │ +.sp │ │ │ │ │ +The user performed the drop action. This event does not indicate │ │ │ │ │ +acceptance, \fI\%WlDataSource.cancelled()\fP may still be emitted │ │ │ │ │ +afterwards if the drop destination does not accept any mime type. │ │ │ │ │ +.sp │ │ │ │ │ +However, this event might however not be received if the compositor │ │ │ │ │ +cancelled the drag\-and\-drop operation before this event could happen. │ │ │ │ │ +.sp │ │ │ │ │ +Note that the data_source may still be used in the future and should │ │ │ │ │ +not be destroyed here. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B dnd_finished() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +The drag\-and\-drop operation concluded │ │ │ │ │ +.sp │ │ │ │ │ +The drop destination finished interoperating with this data source, so │ │ │ │ │ +the client is now free to destroy this data source and free all │ │ │ │ │ +associated data. │ │ │ │ │ +.sp │ │ │ │ │ +If the action used to perform the operation was \(dqmove\(dq, the source can │ │ │ │ │ +now delete the transferred data. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B action(dnd_action: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Notify the selected action │ │ │ │ │ +.sp │ │ │ │ │ +This event indicates the action selected by the compositor after │ │ │ │ │ +matching the source/destination side actions. Only one action (or none) │ │ │ │ │ +will be offered here. │ │ │ │ │ +.sp │ │ │ │ │ +This event can be emitted multiple times during the drag\-and\-drop │ │ │ │ │ +operation, mainly in response to destination side changes through │ │ │ │ │ +\fI\%WlDataOffer.set_actions()\fP, and as the data │ │ │ │ │ +device enters/leaves surfaces. │ │ │ │ │ +.sp │ │ │ │ │ +It is only possible to receive this event after │ │ │ │ │ +\fI\%WlDataSource.dnd_drop_performed()\fP if the drag\-and\-drop │ │ │ │ │ +operation ended in an \(dqask\(dq action, in which case the final │ │ │ │ │ +\fI\%WlDataSource.action()\fP event will happen immediately before │ │ │ │ │ +\fI\%WlDataSource.dnd_finished()\fP\&. │ │ │ │ │ +.sp │ │ │ │ │ +Compositors may also change the selected action on the fly, mainly in │ │ │ │ │ +response to keyboard modifier changes during the drag\-and\-drop │ │ │ │ │ +operation. │ │ │ │ │ +.sp │ │ │ │ │ +The most recent action received is always the valid one. The chosen │ │ │ │ │ +action may change alongside negotiation (e.g. an \(dqask\(dq action can turn │ │ │ │ │ +into a \(dqmove\(dq operation), so the effects of the final action must │ │ │ │ │ +always be applied in \fBWlDataOffer.dnd_finished()\fP\&. │ │ │ │ │ +.sp │ │ │ │ │ +Clients can trigger cursor surface changes from this point, so they │ │ │ │ │ +reflect the current action. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBdnd_action\fP (\fIArgumentType.Uint\fP) \-\- action selected by the compositor │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.SS WlCallback │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlCallback │ │ │ │ │ +Callback object │ │ │ │ │ +.sp │ │ │ │ │ +Clients can handle the \(aqdone\(aq event to get notified when the related │ │ │ │ │ +request is done. │ │ │ │ │ +.sp │ │ │ │ │ +Note, because \fI\%WlCallback\fP objects are created from multiple │ │ │ │ │ +independent factory interfaces, the \fI\%WlCallback\fP interface is frozen │ │ │ │ │ +at version 1. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B done(callback_data: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Done event │ │ │ │ │ +.sp │ │ │ │ │ +Notify the client when the related request is done. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBcallback_data\fP (\fIArgumentType.Uint\fP) \-\- request\-specific data for the callback │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.SS WlRegion │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlRegion │ │ │ │ │ +Region interface │ │ │ │ │ +.sp │ │ │ │ │ +A region object describes an area. │ │ │ │ │ +.sp │ │ │ │ │ +Region objects are used to describe the opaque and input regions of a │ │ │ │ │ +surface. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B destroy() -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Destroy region │ │ │ │ │ +.sp │ │ │ │ │ +Destroy the region. This will invalidate the object ID. │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B add(x: \(aqint\(aq, y: \(aqint\(aq, width: \(aqint\(aq, height: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Add rectangle to region │ │ │ │ │ +.sp │ │ │ │ │ +Add the specified rectangle to the region. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBx\fP (\fIArgumentType.Int\fP) \-\- region\-local x coordinate │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBy\fP (\fIArgumentType.Int\fP) \-\- region\-local y coordinate │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBwidth\fP (\fIArgumentType.Int\fP) \-\- rectangle width │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBheight\fP (\fIArgumentType.Int\fP) \-\- rectangle height │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B subtract(x: \(aqint\(aq, y: \(aqint\(aq, width: \(aqint\(aq, height: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 2 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Subtract rectangle from region │ │ │ │ │ +.sp │ │ │ │ │ +Subtract the specified rectangle from the region. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBx\fP (\fIArgumentType.Int\fP) \-\- region\-local x coordinate │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBy\fP (\fIArgumentType.Int\fP) \-\- region\-local y coordinate │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBwidth\fP (\fIArgumentType.Int\fP) \-\- rectangle width │ │ │ │ │ +.IP \(bu 2 │ │ │ │ │ +\fBheight\fP (\fIArgumentType.Int\fP) \-\- rectangle height │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.SS WlDataDeviceManager │ │ │ │ │ +.INDENT 0.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B class pywayland.protocol.wayland.WlDataDeviceManager │ │ │ │ │ +Data transfer interface │ │ │ │ │ +.sp │ │ │ │ │ +The \fI\%WlDataDeviceManager\fP is a singleton global object that provides │ │ │ │ │ +access to inter\-client data transfer mechanisms such as copy\-and\-paste and │ │ │ │ │ +drag\-and\-drop. These mechanisms are tied to a │ │ │ │ │ +\fI\%WlSeat\fP and this interface lets a │ │ │ │ │ +client get a \fI\%WlDataDevice\fP │ │ │ │ │ +corresponding to a \fI\%WlSeat\fP\&. │ │ │ │ │ +.sp │ │ │ │ │ +Depending on the version bound, the objects created from the bound │ │ │ │ │ +\fI\%WlDataDeviceManager\fP object will have different requirements for │ │ │ │ │ +functioning properly. See \fI\%WlDataSource.set_actions()\fP, │ │ │ │ │ +\fI\%WlDataOffer.accept()\fP and │ │ │ │ │ +\fI\%WlDataOffer.finish()\fP for details. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B create_data_source() -> \(aqProxy[WlDataSource]\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Create a new data source │ │ │ │ │ +.sp │ │ │ │ │ +Create a new data source. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Returns │ │ │ │ │ +\fI\%WlDataSource\fP \-\- data source to │ │ │ │ │ +create │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B get_data_device(seat: \(aqWlSeat\(aq) -> \(aqProxy[WlDataDevice]\(aq │ │ │ │ │ +.sp │ │ │ │ │ +Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ +.sp │ │ │ │ │ +Create a new data device │ │ │ │ │ +.sp │ │ │ │ │ +Create a new data device for a given seat. │ │ │ │ │ +.INDENT 7.0 │ │ │ │ │ +.TP │ │ │ │ │ +.B Parameters │ │ │ │ │ +\fBseat\fP (\fI\%WlSeat\fP) \-\- seat associated with the data device │ │ │ │ │ +.TP │ │ │ │ │ +.B Returns │ │ │ │ │ +\fI\%WlDataDevice\fP \-\- data device to │ │ │ │ │ +create │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ +.UNINDENT │ │ │ │ │ .SS WlShellSurface │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ .B class pywayland.protocol.wayland.WlShellSurface │ │ │ │ │ Desktop\-style metadata interface │ │ │ │ │ .sp │ │ │ │ │ An interface that may be implemented by a │ │ │ │ │ @@ -3058,773 +4424,14 @@ │ │ │ │ │ surface may override it to behave as synchronized. For details, see │ │ │ │ │ \fI\%WlSubsurface\fP\&. │ │ │ │ │ .sp │ │ │ │ │ If a surface\(aqs parent surface behaves as desynchronized, then the │ │ │ │ │ cached state is applied on set_desync. │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ -.SS WlShm │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlShm │ │ │ │ │ -Shared memory support │ │ │ │ │ -.sp │ │ │ │ │ -A singleton global object that provides support for shared memory. │ │ │ │ │ -.sp │ │ │ │ │ -Clients can create \fI\%WlShmPool\fP objects │ │ │ │ │ -using the create_pool request. │ │ │ │ │ -.sp │ │ │ │ │ -On binding the \fI\%WlShm\fP object one or more format events are emitted │ │ │ │ │ -to inform clients about the valid pixel formats that can be used for │ │ │ │ │ -buffers. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B create_pool(fd: \(aqint\(aq, size: \(aqint\(aq) -> \(aqProxy[WlShmPool]\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Create a shm pool │ │ │ │ │ -.sp │ │ │ │ │ -Create a new \fI\%WlShmPool\fP object. │ │ │ │ │ -.sp │ │ │ │ │ -The pool can be used to create shared memory based buffer objects. The │ │ │ │ │ -server will mmap size bytes of the passed file descriptor, to use as │ │ │ │ │ -backing memory for the pool. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBfd\fP (\fIArgumentType.FileDescriptor\fP) \-\- file descriptor for the pool │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBsize\fP (\fIArgumentType.Int\fP) \-\- pool size, in bytes │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.TP │ │ │ │ │ -.B Returns │ │ │ │ │ -\fI\%WlShmPool\fP \-\- pool to create │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B release() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Release the shm object │ │ │ │ │ -.sp │ │ │ │ │ -Using this request a client can tell the server that it is not going to │ │ │ │ │ -use the shm object anymore. │ │ │ │ │ -.sp │ │ │ │ │ -Objects created via this interface remain unaffected. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B format(format: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Pixel format description │ │ │ │ │ -.sp │ │ │ │ │ -Informs the client about a valid pixel format that can be used for │ │ │ │ │ -buffers. Known formats include argb8888 and xrgb8888. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -\fBformat\fP (\fIArgumentType.Uint\fP) \-\- buffer pixel format │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.SS WlKeyboard │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlKeyboard │ │ │ │ │ -Keyboard input device │ │ │ │ │ -.sp │ │ │ │ │ -The \fI\%WlKeyboard\fP interface represents one or more keyboards │ │ │ │ │ -associated with a seat. │ │ │ │ │ -.sp │ │ │ │ │ -Each \fI\%WlKeyboard\fP has the following logical state: │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -an active surface (possibly null), │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -the keys currently logically down, │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -the active modifiers, │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -the active group. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.sp │ │ │ │ │ -By default, the active surface is null, the keys currently logically down │ │ │ │ │ -are empty, the active modifiers and the active group are 0. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B release() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Release the keyboard object │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B keymap(format: \(aqint\(aq, fd: \(aqint\(aq, size: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Keyboard mapping │ │ │ │ │ -.sp │ │ │ │ │ -This event provides a file descriptor to the client which can be │ │ │ │ │ -memory\-mapped in read\-only mode to provide a keyboard mapping │ │ │ │ │ -description. │ │ │ │ │ -.sp │ │ │ │ │ -From version 7 onwards, the fd must be mapped with MAP_PRIVATE by the │ │ │ │ │ -recipient, as MAP_SHARED may fail. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBformat\fP (\fIArgumentType.Uint\fP) \-\- keymap format │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBfd\fP (\fIArgumentType.FileDescriptor\fP) \-\- keymap file descriptor │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBsize\fP (\fIArgumentType.Uint\fP) \-\- keymap size, in bytes │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B enter(serial: \(aqint\(aq, surface: \(aqWlSurface\(aq, keys: \(aqlist\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Enter event │ │ │ │ │ -.sp │ │ │ │ │ -Notification that this seat\(aqs keyboard focus is on a certain surface. │ │ │ │ │ -.sp │ │ │ │ │ -The compositor must send the \fI\%WlKeyboard.modifiers()\fP event after │ │ │ │ │ -this event. │ │ │ │ │ -.sp │ │ │ │ │ -In the \fI\%WlKeyboard\fP logical state, this event sets the active │ │ │ │ │ -surface to the surface argument and the keys currently logically down │ │ │ │ │ -to the keys in the keys argument. The compositor must not send this │ │ │ │ │ -event if the \fI\%WlKeyboard\fP already had an active surface │ │ │ │ │ -immediately before this event. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the enter event │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBsurface\fP (\fI\%WlSurface\fP) \-\- surface gaining keyboard focus │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBkeys\fP (\fIArgumentType.Array\fP) \-\- the keys currently logically down │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B leave(serial: \(aqint\(aq, surface: \(aqWlSurface\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 2 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Leave event │ │ │ │ │ -.sp │ │ │ │ │ -Notification that this seat\(aqs keyboard focus is no longer on a certain │ │ │ │ │ -surface. │ │ │ │ │ -.sp │ │ │ │ │ -The leave notification is sent before the enter notification for the │ │ │ │ │ -new focus. │ │ │ │ │ -.sp │ │ │ │ │ -In the \fI\%WlKeyboard\fP logical state, this event resets all values │ │ │ │ │ -to their defaults. The compositor must not send this event if the │ │ │ │ │ -active surface of the \fI\%WlKeyboard\fP was not equal to the surface │ │ │ │ │ -argument immediately before this event. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the leave event │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBsurface\fP (\fI\%WlSurface\fP) \-\- surface that lost keyboard focus │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B key(serial: \(aqint\(aq, time: \(aqint\(aq, key: \(aqint\(aq, state: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Key event │ │ │ │ │ -.sp │ │ │ │ │ -A key was pressed or released. The time argument is a timestamp with │ │ │ │ │ -millisecond granularity, with an undefined base. │ │ │ │ │ -.sp │ │ │ │ │ -The key is a platform\-specific key code that can be interpreted by │ │ │ │ │ -feeding it to the keyboard mapping (see the keymap event). │ │ │ │ │ -.sp │ │ │ │ │ -If this event produces a change in modifiers, then the resulting │ │ │ │ │ -\fI\%WlKeyboard.modifiers()\fP event must be sent after this event. │ │ │ │ │ -.sp │ │ │ │ │ -In the \fI\%WlKeyboard\fP logical state, this event adds the key to │ │ │ │ │ -the keys currently logically down (if the state argument is pressed) or │ │ │ │ │ -removes the key from the keys currently logically down (if the state │ │ │ │ │ -argument is released). The compositor must not send this event if the │ │ │ │ │ -\fI\%WlKeyboard\fP did not have an active surface immediately before │ │ │ │ │ -this event. The compositor must not send this event if state is pressed │ │ │ │ │ -(resp. released) and the key was already logically down (resp. was not │ │ │ │ │ -logically down) immediately before this event. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the key event │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBkey\fP (\fIArgumentType.Uint\fP) \-\- key that produced the event │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBstate\fP (\fIArgumentType.Uint\fP) \-\- physical state of the key │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B modifiers(serial: \(aqint\(aq, mods_depressed: \(aqint\(aq, mods_latched: \(aqint\(aq, mods_locked: \(aqint\(aq, group: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Modifier and group state │ │ │ │ │ -.sp │ │ │ │ │ -Notifies clients that the modifier and/or group state has changed, and │ │ │ │ │ -it should update its local state. │ │ │ │ │ -.sp │ │ │ │ │ -The compositor may send this event without a surface of the client │ │ │ │ │ -having keyboard focus, for example to tie modifier information to │ │ │ │ │ -pointer focus instead. If a modifier event with pressed modifiers is │ │ │ │ │ -sent without a prior enter event, the client can assume the modifier │ │ │ │ │ -state is valid until it receives the next │ │ │ │ │ -\fI\%WlKeyboard.modifiers()\fP event. In order to reset the modifier │ │ │ │ │ -state again, the compositor can send a \fI\%WlKeyboard.modifiers()\fP │ │ │ │ │ -event with no pressed modifiers. │ │ │ │ │ -.sp │ │ │ │ │ -In the \fI\%WlKeyboard\fP logical state, this event updates the │ │ │ │ │ -modifiers and group. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the modifiers event │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBmods_depressed\fP (\fIArgumentType.Uint\fP) \-\- depressed modifiers │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBmods_latched\fP (\fIArgumentType.Uint\fP) \-\- latched modifiers │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBmods_locked\fP (\fIArgumentType.Uint\fP) \-\- locked modifiers │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBgroup\fP (\fIArgumentType.Uint\fP) \-\- keyboard layout │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B repeat_info(rate: \(aqint\(aq, delay: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Repeat rate and delay │ │ │ │ │ -.sp │ │ │ │ │ -Informs the client about the keyboard\(aqs repeat rate and delay. │ │ │ │ │ -.sp │ │ │ │ │ -This event is sent as soon as the \fI\%WlKeyboard\fP object has been │ │ │ │ │ -created, and is guaranteed to be received by the client before any key │ │ │ │ │ -press event. │ │ │ │ │ -.sp │ │ │ │ │ -Negative values for either rate or delay are illegal. A rate of zero │ │ │ │ │ -will disable any repeating (regardless of the value of delay). │ │ │ │ │ -.sp │ │ │ │ │ -This event can be sent later on as well with a new value if necessary, │ │ │ │ │ -so clients should continue listening for the event past the creation of │ │ │ │ │ -\fI\%WlKeyboard\fP\&. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBrate\fP (\fIArgumentType.Int\fP) \-\- the rate of repeating keys in characters per second │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBdelay\fP (\fIArgumentType.Int\fP) \-\- delay in milliseconds since key down until repeating starts │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.SS WlTouch │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlTouch │ │ │ │ │ -Touchscreen input device │ │ │ │ │ -.sp │ │ │ │ │ -The \fI\%WlTouch\fP interface represents a touchscreen associated with a │ │ │ │ │ -seat. │ │ │ │ │ -.sp │ │ │ │ │ -Touch interactions can consist of one or more contacts. For each contact, a │ │ │ │ │ -series of events is generated, starting with a down event, followed by zero │ │ │ │ │ -or more motion events, and ending with an up event. Events relating to the │ │ │ │ │ -same contact point can be identified by the ID of the sequence. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B release() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Release the touch object │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B down(serial: \(aqint\(aq, time: \(aqint\(aq, surface: \(aqWlSurface\(aq, id: \(aqint\(aq, x: \(aqfloat\(aq, y: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Touch down event and beginning of a touch sequence │ │ │ │ │ -.sp │ │ │ │ │ -A new touch point has appeared on the surface. This touch point is │ │ │ │ │ -assigned a unique ID. Future events from this touch point reference │ │ │ │ │ -this ID. The ID ceases to be valid after a touch up event and may be │ │ │ │ │ -reused in the future. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the touch down event │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBsurface\fP (\fI\%WlSurface\fP) \-\- surface touched │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBx\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local x coordinate │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBy\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local y coordinate │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B up(serial: \(aqint\(aq, time: \(aqint\(aq, id: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -End of a touch event sequence │ │ │ │ │ -.sp │ │ │ │ │ -The touch point has disappeared. No further events will be sent for │ │ │ │ │ -this touch point and the touch point\(aqs ID is released and may be reused │ │ │ │ │ -in a future touch down event. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the touch up event │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B motion(time: \(aqint\(aq, id: \(aqint\(aq, x: \(aqfloat\(aq, y: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 2 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Update of touch point coordinates │ │ │ │ │ -.sp │ │ │ │ │ -A touch point has changed coordinates. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBx\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local x coordinate │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBy\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local y coordinate │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B frame() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -End of touch frame event │ │ │ │ │ -.sp │ │ │ │ │ -Indicates the end of a set of events that logically belong together. A │ │ │ │ │ -client is expected to accumulate the data in all events within the │ │ │ │ │ -frame before proceeding. │ │ │ │ │ -.sp │ │ │ │ │ -A \fI\%WlTouch.frame()\fP terminates at least one event but otherwise │ │ │ │ │ -no guarantee is provided about the set of events within a frame. A │ │ │ │ │ -client must assume that any state not updated in a frame is unchanged │ │ │ │ │ -from the previously known state. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B cancel() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Touch session cancelled │ │ │ │ │ -.sp │ │ │ │ │ -Sent if the compositor decides the touch stream is a global gesture. No │ │ │ │ │ -further events are sent to the clients from that particular gesture. │ │ │ │ │ -Touch cancellation applies to all touch points currently active on this │ │ │ │ │ -client\(aqs surface. The client is responsible for finalizing the touch │ │ │ │ │ -points, future touch points on this surface may reuse the touch point │ │ │ │ │ -ID. │ │ │ │ │ -.sp │ │ │ │ │ -No frame event is required after the cancel event. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B shape(id: \(aqint\(aq, major: \(aqfloat\(aq, minor: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Update shape of touch point │ │ │ │ │ -.sp │ │ │ │ │ -Sent when a touchpoint has changed its shape. │ │ │ │ │ -.sp │ │ │ │ │ -This event does not occur on its own. It is sent before a │ │ │ │ │ -\fI\%WlTouch.frame()\fP event and carries the new shape information for │ │ │ │ │ -any previously reported, or new touch points of that frame. │ │ │ │ │ -.sp │ │ │ │ │ -Other events describing the touch point such as \fI\%WlTouch.down()\fP, │ │ │ │ │ -\fI\%WlTouch.motion()\fP or \fI\%WlTouch.orientation()\fP may be sent │ │ │ │ │ -within the same \fI\%WlTouch.frame()\fP\&. A client should treat these │ │ │ │ │ -events as a single logical touch point update. The order of │ │ │ │ │ -\fI\%WlTouch.shape()\fP, \fI\%WlTouch.orientation()\fP and │ │ │ │ │ -\fI\%WlTouch.motion()\fP is not guaranteed. A \fI\%WlTouch.down()\fP │ │ │ │ │ -event is guaranteed to occur before the first \fI\%WlTouch.shape()\fP │ │ │ │ │ -event for this touch ID but both events may occur within the same │ │ │ │ │ -\fI\%WlTouch.frame()\fP\&. │ │ │ │ │ -.sp │ │ │ │ │ -A touchpoint shape is approximated by an ellipse through the major and │ │ │ │ │ -minor axis length. The major axis length describes the longer diameter │ │ │ │ │ -of the ellipse, while the minor axis length describes the shorter │ │ │ │ │ -diameter. Major and minor are orthogonal and both are specified in │ │ │ │ │ -surface\-local coordinates. The center of the ellipse is always at the │ │ │ │ │ -touchpoint location as reported by \fI\%WlTouch.down()\fP or │ │ │ │ │ -\fBWlTouch.move()\fP\&. │ │ │ │ │ -.sp │ │ │ │ │ -This event is only sent by the compositor if the touch device supports │ │ │ │ │ -shape reports. The client has to make reasonable assumptions about the │ │ │ │ │ -shape if it did not receive this event. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBmajor\fP (\fIArgumentType.Fixed\fP) \-\- length of the major axis in surface\-local coordinates │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBminor\fP (\fIArgumentType.Fixed\fP) \-\- length of the minor axis in surface\-local coordinates │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B orientation(id: \(aqint\(aq, orientation: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 6 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Update orientation of touch point │ │ │ │ │ -.sp │ │ │ │ │ -Sent when a touchpoint has changed its orientation. │ │ │ │ │ -.sp │ │ │ │ │ -This event does not occur on its own. It is sent before a │ │ │ │ │ -\fI\%WlTouch.frame()\fP event and carries the new shape information for │ │ │ │ │ -any previously reported, or new touch points of that frame. │ │ │ │ │ -.sp │ │ │ │ │ -Other events describing the touch point such as \fI\%WlTouch.down()\fP, │ │ │ │ │ -\fI\%WlTouch.motion()\fP or \fI\%WlTouch.shape()\fP may be sent within │ │ │ │ │ -the same \fI\%WlTouch.frame()\fP\&. A client should treat these events as │ │ │ │ │ -a single logical touch point update. The order of │ │ │ │ │ -\fI\%WlTouch.shape()\fP, \fI\%WlTouch.orientation()\fP and │ │ │ │ │ -\fI\%WlTouch.motion()\fP is not guaranteed. A \fI\%WlTouch.down()\fP │ │ │ │ │ -event is guaranteed to occur before the first │ │ │ │ │ -\fI\%WlTouch.orientation()\fP event for this touch ID but both events │ │ │ │ │ -may occur within the same \fI\%WlTouch.frame()\fP\&. │ │ │ │ │ -.sp │ │ │ │ │ -The orientation describes the clockwise angle of a touchpoint\(aqs major │ │ │ │ │ -axis to the positive surface y\-axis and is normalized to the \-180 to │ │ │ │ │ -+180 degree range. The granularity of orientation depends on the touch │ │ │ │ │ -device, some devices only support binary rotation values between 0 and │ │ │ │ │ -90 degrees. │ │ │ │ │ -.sp │ │ │ │ │ -This event is only sent by the compositor if the touch device supports │ │ │ │ │ -orientation reports. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBid\fP (\fIArgumentType.Int\fP) \-\- the unique ID of this touch point │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBorientation\fP (\fIArgumentType.Fixed\fP) \-\- angle between major axis and positive surface y\-axis in degrees │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.SS WlDataDevice │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlDataDevice │ │ │ │ │ -Data transfer device │ │ │ │ │ -.sp │ │ │ │ │ -There is one \fI\%WlDataDevice\fP per seat which can be obtained from the │ │ │ │ │ -global \fI\%WlDataDeviceManager\fP singleton. │ │ │ │ │ -.sp │ │ │ │ │ -A \fI\%WlDataDevice\fP provides access to inter\-client data transfer │ │ │ │ │ -mechanisms such as copy\-and\-paste and drag\-and\-drop. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B start_drag(source: \(aqWlDataSource | None\(aq, origin: \(aqWlSurface\(aq, icon: \(aqWlSurface | None\(aq, serial: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Start drag\-and\-drop operation │ │ │ │ │ -.sp │ │ │ │ │ -This request asks the compositor to start a drag\-and\-drop operation on │ │ │ │ │ -behalf of the client. │ │ │ │ │ -.sp │ │ │ │ │ -The source argument is the data source that provides the data for the │ │ │ │ │ -eventual data transfer. If source is NULL, enter, leave and motion │ │ │ │ │ -events are sent only to the client that initiated the drag and the │ │ │ │ │ -client is expected to handle the data passing internally. If source is │ │ │ │ │ -destroyed, the drag\-and\-drop session will be cancelled. │ │ │ │ │ -.sp │ │ │ │ │ -The origin surface is the surface where the drag originates and the │ │ │ │ │ -client must have an active implicit grab that matches the serial. │ │ │ │ │ -.sp │ │ │ │ │ -The icon surface is an optional (can be NULL) surface that provides an │ │ │ │ │ -icon to be moved around with the cursor. Initially, the top\-left │ │ │ │ │ -corner of the icon surface is placed at the cursor hotspot, but │ │ │ │ │ -subsequent \fI\%WlSurface.offset()\fP requests can move the │ │ │ │ │ -relative position. Attach requests must be confirmed with │ │ │ │ │ -\fI\%WlSurface.commit()\fP as usual. The icon │ │ │ │ │ -surface is given the role of a drag\-and\-drop icon. If the icon surface │ │ │ │ │ -already has another role, it raises a protocol error. │ │ │ │ │ -.sp │ │ │ │ │ -The input region is ignored for wl_surfaces with the role of a drag\- │ │ │ │ │ -and\-drop icon. │ │ │ │ │ -.sp │ │ │ │ │ -The given source may not be used in any further set_selection or │ │ │ │ │ -start_drag requests. Attempting to reuse a previously\-used source may │ │ │ │ │ -send a used_source error. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBsource\fP (\fI\%WlDataSource\fP or \fINone\fP) \-\- data source for the eventual transfer │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBorigin\fP (\fI\%WlSurface\fP) \-\- surface where the drag originates │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBicon\fP (\fI\%WlSurface\fP or \fINone\fP) \-\- drag\-and\-drop icon surface │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the implicit grab on the origin │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B set_selection(source: \(aqWlDataSource | None\(aq, serial: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Copy data to the selection │ │ │ │ │ -.sp │ │ │ │ │ -This request asks the compositor to set the selection to the data from │ │ │ │ │ -the source on behalf of the client. │ │ │ │ │ -.sp │ │ │ │ │ -To unset the selection, set the source to NULL. │ │ │ │ │ -.sp │ │ │ │ │ -The given source may not be used in any further set_selection or │ │ │ │ │ -start_drag requests. Attempting to reuse a previously\-used source may │ │ │ │ │ -send a used_source error. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBsource\fP (\fI\%WlDataSource\fP or \fINone\fP) \-\- data source for the selection │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the event that triggered this request │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B release() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 2 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Destroy data device │ │ │ │ │ -.sp │ │ │ │ │ -This request destroys the data device. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B data_offer(id: \(aqWlDataOffer\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Introduce a new \fI\%WlDataOffer\fP │ │ │ │ │ -.sp │ │ │ │ │ -The data_offer event introduces a new │ │ │ │ │ -\fI\%WlDataOffer\fP object, which will │ │ │ │ │ -subsequently be used in either the data_device.enter event (for drag\- │ │ │ │ │ -and\-drop) or the data_device.selection event (for selections). │ │ │ │ │ -Immediately following the data_device.data_offer event, the new │ │ │ │ │ -data_offer object will send out data_offer.offer events to describe the │ │ │ │ │ -mime types it offers. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -\fBid\fP (\fI\%WlDataOffer\fP) \-\- the new data_offer object │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B enter(serial: \(aqint\(aq, surface: \(aqWlSurface\(aq, x: \(aqfloat\(aq, y: \(aqfloat\(aq, id: \(aqWlDataOffer | None\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Initiate drag\-and\-drop session │ │ │ │ │ -.sp │ │ │ │ │ -This event is sent when an active drag\-and\-drop pointer enters a │ │ │ │ │ -surface owned by the client. The position of the pointer at enter time │ │ │ │ │ -is provided by the x and y arguments, in surface\-local coordinates. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBserial\fP (\fIArgumentType.Uint\fP) \-\- serial number of the enter event │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBsurface\fP (\fI\%WlSurface\fP) \-\- client surface entered │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBx\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local x coordinate │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBy\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local y coordinate │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBid\fP (\fI\%WlDataOffer\fP or \fINone\fP) \-\- source data_offer object │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B leave() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 2 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -End drag\-and\-drop session │ │ │ │ │ -.sp │ │ │ │ │ -This event is sent when the drag\-and\-drop pointer leaves the surface │ │ │ │ │ -and the session ends. The client must destroy the │ │ │ │ │ -\fI\%WlDataOffer\fP introduced at enter │ │ │ │ │ -time at this point. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B motion(time: \(aqint\(aq, x: \(aqfloat\(aq, y: \(aqfloat\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Drag\-and\-drop session motion │ │ │ │ │ -.sp │ │ │ │ │ -This event is sent when the drag\-and\-drop pointer moves within the │ │ │ │ │ -currently focused surface. The new position of the pointer is provided │ │ │ │ │ -by the x and y arguments, in surface\-local coordinates. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBtime\fP (\fIArgumentType.Uint\fP) \-\- timestamp with millisecond granularity │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBx\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local x coordinate │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBy\fP (\fIArgumentType.Fixed\fP) \-\- surface\-local y coordinate │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B drop() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -End drag\-and\-drop session successfully │ │ │ │ │ -.sp │ │ │ │ │ -The event is sent when a drag\-and\-drop operation is ended because the │ │ │ │ │ -implicit grab is removed. │ │ │ │ │ -.sp │ │ │ │ │ -The drag\-and\-drop destination is expected to honor the last action │ │ │ │ │ -received through \fI\%WlDataOffer.action()\fP, if the resulting │ │ │ │ │ -action is \(dqcopy\(dq or \(dqmove\(dq, the destination can still perform │ │ │ │ │ -\fI\%WlDataOffer.receive()\fP requests, and is │ │ │ │ │ -expected to end all transfers with a \fI\%WlDataOffer.finish()\fP request. │ │ │ │ │ -.sp │ │ │ │ │ -If the resulting action is \(dqask\(dq, the action will not be considered │ │ │ │ │ -final. The drag\-and\-drop destination is expected to perform one last │ │ │ │ │ -\fI\%WlDataOffer.set_actions()\fP request, or │ │ │ │ │ -\fI\%WlDataOffer.destroy()\fP in order to cancel │ │ │ │ │ -the operation. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B selection(id: \(aqWlDataOffer | None\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Advertise new selection │ │ │ │ │ -.sp │ │ │ │ │ -The selection event is sent out to notify the client of a new │ │ │ │ │ -\fI\%WlDataOffer\fP for the selection for │ │ │ │ │ -this device. The data_device.data_offer and the data_offer.offer │ │ │ │ │ -events are sent out immediately before this event to introduce the data │ │ │ │ │ -offer object. The selection event is sent to a client immediately │ │ │ │ │ -before receiving keyboard focus and when a new selection is set while │ │ │ │ │ -the client has keyboard focus. The data_offer is valid until a new │ │ │ │ │ -data_offer or NULL is received or until the client loses keyboard │ │ │ │ │ -focus. Switching surface with keyboard focus within the same client │ │ │ │ │ -doesn\(aqt mean a new selection will be sent. The client must destroy the │ │ │ │ │ -previous selection data_offer, if any, upon receiving this event. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -\fBid\fP (\fI\%WlDataOffer\fP or \fINone\fP) \-\- selection data_offer object │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ .SS WlPointer │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ .B class pywayland.protocol.wayland.WlPointer │ │ │ │ │ Pointer input device │ │ │ │ │ .sp │ │ │ │ │ The \fI\%WlPointer\fP interface represents one or more input devices, such │ │ │ │ │ @@ -4301,54 +4908,14 @@ │ │ │ │ │ \fBaxis\fP (\fIArgumentType.Uint\fP) \-\- axis type │ │ │ │ │ .IP \(bu 2 │ │ │ │ │ \fBdirection\fP (\fIArgumentType.Uint\fP) \-\- physical direction relative to axis motion │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ -.SS WlCompositor │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlCompositor │ │ │ │ │ -The compositor singleton │ │ │ │ │ -.sp │ │ │ │ │ -A compositor. This object is a singleton global. The compositor is in │ │ │ │ │ -charge of combining the contents of multiple surfaces into one displayable │ │ │ │ │ -output. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B create_surface() -> \(aqProxy[WlSurface]\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Create new surface │ │ │ │ │ -.sp │ │ │ │ │ -Ask the compositor to create a new surface. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Returns │ │ │ │ │ -\fI\%WlSurface\fP \-\- the new surface │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B create_region() -> \(aqProxy[WlRegion]\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Create new region │ │ │ │ │ -.sp │ │ │ │ │ -Ask the compositor to create a new region. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Returns │ │ │ │ │ -\fI\%WlRegion\fP \-\- the new region │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ .SS WlShell │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ .B class pywayland.protocol.wayland.WlShell │ │ │ │ │ Create desktop\-style surfaces │ │ │ │ │ .sp │ │ │ │ │ This interface is implemented by servers that provide desktop\-style user │ │ │ │ │ @@ -4486,581 +5053,14 @@ │ │ │ │ │ .INDENT 7.0 │ │ │ │ │ .TP │ │ │ │ │ .B Parameters │ │ │ │ │ \fBid\fP (\fIArgumentType.Uint\fP) \-\- deleted object ID │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ .UNINDENT │ │ │ │ │ -.SS WlOutput │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlOutput │ │ │ │ │ -Compositor output region │ │ │ │ │ -.sp │ │ │ │ │ -An output describes part of the compositor geometry. The compositor works │ │ │ │ │ -in the \(aqcompositor coordinate system\(aq and an output corresponds to a │ │ │ │ │ -rectangular area in that space that is actually visible. This typically │ │ │ │ │ -corresponds to a monitor that displays part of the compositor space. This │ │ │ │ │ -object is published as global during start up, or when a monitor is │ │ │ │ │ -hotplugged. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B release() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Release the output object │ │ │ │ │ -.sp │ │ │ │ │ -Using this request a client can tell the server that it is not going to │ │ │ │ │ -use the output object anymore. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B geometry(x: \(aqint\(aq, y: \(aqint\(aq, physical_width: \(aqint\(aq, physical_height: \(aqint\(aq, subpixel: \(aqint\(aq, make: \(aqstr\(aq, model: \(aqstr\(aq, transform: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Properties of the output │ │ │ │ │ -.sp │ │ │ │ │ -The geometry event describes geometric properties of the output. The │ │ │ │ │ -event is sent when binding to the output object and whenever any of the │ │ │ │ │ -properties change. │ │ │ │ │ -.sp │ │ │ │ │ -The physical size can be set to zero if it doesn\(aqt make sense for this │ │ │ │ │ -output (e.g. for projectors or virtual outputs). │ │ │ │ │ -.sp │ │ │ │ │ -The geometry event will be followed by a done event (starting from │ │ │ │ │ -version 2). │ │ │ │ │ -.sp │ │ │ │ │ -Clients should use \fI\%WlSurface.preferred_buffer_transform()\fP │ │ │ │ │ -instead of the transform advertised by this event to find the preferred │ │ │ │ │ -buffer transform to use for a surface. │ │ │ │ │ -.sp │ │ │ │ │ -Note: \fI\%WlOutput\fP only advertises partial information about the │ │ │ │ │ -output position and identification. Some compositors, for instance │ │ │ │ │ -those not implementing a desktop\-style output layout or those exposing │ │ │ │ │ -virtual outputs, might fake this information. Instead of using x and y, │ │ │ │ │ -clients should use xdg_output.logical_position. Instead of using make │ │ │ │ │ -and model, clients should use name and description. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBx\fP (\fIArgumentType.Int\fP) \-\- x position within the global compositor space │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBy\fP (\fIArgumentType.Int\fP) \-\- y position within the global compositor space │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBphysical_width\fP (\fIArgumentType.Int\fP) \-\- width in millimeters of the output │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBphysical_height\fP (\fIArgumentType.Int\fP) \-\- height in millimeters of the output │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBsubpixel\fP (\fIArgumentType.Int\fP) \-\- subpixel orientation of the output │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBmake\fP (\fIArgumentType.String\fP) \-\- textual description of the manufacturer │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBmodel\fP (\fIArgumentType.String\fP) \-\- textual description of the model │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBtransform\fP (\fIArgumentType.Int\fP) \-\- additional transformation applied to buffer contents during │ │ │ │ │ -presentation │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B mode(flags: \(aqint\(aq, width: \(aqint\(aq, height: \(aqint\(aq, refresh: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Advertise available modes for the output │ │ │ │ │ -.sp │ │ │ │ │ -The mode event describes an available mode for the output. │ │ │ │ │ -.sp │ │ │ │ │ -The event is sent when binding to the output object and there will │ │ │ │ │ -always be one mode, the current mode. The event is sent again if an │ │ │ │ │ -output changes mode, for the mode that is now current. In other words, │ │ │ │ │ -the current mode is always the last mode that was received with the │ │ │ │ │ -current flag set. │ │ │ │ │ -.sp │ │ │ │ │ -Non\-current modes are deprecated. A compositor can decide to only │ │ │ │ │ -advertise the current mode and never send other modes. Clients should │ │ │ │ │ -not rely on non\-current modes. │ │ │ │ │ -.sp │ │ │ │ │ -The size of a mode is given in physical hardware units of the output │ │ │ │ │ -device. This is not necessarily the same as the output size in the │ │ │ │ │ -global compositor space. For instance, the output may be scaled, as │ │ │ │ │ -described in \fI\%WlOutput.scale()\fP, or transformed, as described in │ │ │ │ │ -\fBWlOutput.transform()\fP\&. Clients willing to retrieve the output │ │ │ │ │ -size in the global compositor space should use xdg_output.logical_size │ │ │ │ │ -instead. │ │ │ │ │ -.sp │ │ │ │ │ -The vertical refresh rate can be set to zero if it doesn\(aqt make sense │ │ │ │ │ -for this output (e.g. for virtual outputs). │ │ │ │ │ -.sp │ │ │ │ │ -The mode event will be followed by a done event (starting from version │ │ │ │ │ -2). │ │ │ │ │ -.sp │ │ │ │ │ -Clients should not use the refresh rate to schedule frames. Instead, │ │ │ │ │ -they should use the \fI\%WlSurface.frame()\fP event or the │ │ │ │ │ -presentation\-time protocol. │ │ │ │ │ -.sp │ │ │ │ │ -Note: this information is not always meaningful for all outputs. Some │ │ │ │ │ -compositors, such as those exposing virtual outputs, might fake the │ │ │ │ │ -refresh rate or the size. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBflags\fP (\fIArgumentType.Uint\fP) \-\- bitfield of mode flags │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBwidth\fP (\fIArgumentType.Int\fP) \-\- width of the mode in hardware units │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBheight\fP (\fIArgumentType.Int\fP) \-\- height of the mode in hardware units │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBrefresh\fP (\fIArgumentType.Int\fP) \-\- vertical refresh rate in mHz │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B done() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 2 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Sent all information about output │ │ │ │ │ -.sp │ │ │ │ │ -This event is sent after all other properties have been sent after │ │ │ │ │ -binding to the output object and after any other property changes done │ │ │ │ │ -after that. This allows changes to the output properties to be seen as │ │ │ │ │ -atomic, even if they happen via multiple events. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B scale(factor: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 3 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Output scaling properties │ │ │ │ │ -.sp │ │ │ │ │ -This event contains scaling geometry information that is not in the │ │ │ │ │ -geometry event. It may be sent after binding the output object or if │ │ │ │ │ -the output scale changes later. The compositor will emit a non\-zero, │ │ │ │ │ -positive value for scale. If it is not sent, the client should assume a │ │ │ │ │ -scale of 1. │ │ │ │ │ -.sp │ │ │ │ │ -A scale larger than 1 means that the compositor will automatically │ │ │ │ │ -scale surface buffers by this amount when rendering. This is used for │ │ │ │ │ -very high resolution displays where applications rendering at the │ │ │ │ │ -native resolution would be too small to be legible. │ │ │ │ │ -.sp │ │ │ │ │ -Clients should use \fI\%WlSurface.preferred_buffer_scale()\fP instead │ │ │ │ │ -of this event to find the preferred buffer scale to use for a surface. │ │ │ │ │ -.sp │ │ │ │ │ -The scale event will be followed by a done event. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -\fBfactor\fP (\fIArgumentType.Int\fP) \-\- scaling factor of output │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B name(name: \(aqstr\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 4 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Name of this output │ │ │ │ │ -.sp │ │ │ │ │ -Many compositors will assign user\-friendly names to their outputs, show │ │ │ │ │ -them to the user, allow the user to refer to an output, etc. The client │ │ │ │ │ -may wish to know this name as well to offer the user similar behaviors. │ │ │ │ │ -.sp │ │ │ │ │ -The name is a UTF\-8 string with no convention defined for its contents. │ │ │ │ │ -Each name is unique among all \fI\%WlOutput\fP globals. The name is │ │ │ │ │ -only guaranteed to be unique for the compositor instance. │ │ │ │ │ -.sp │ │ │ │ │ -The same output name is used for all clients for a given │ │ │ │ │ -\fI\%WlOutput\fP global. Thus, the name can be shared across processes │ │ │ │ │ -to refer to a specific \fI\%WlOutput\fP global. │ │ │ │ │ -.sp │ │ │ │ │ -The name is not guaranteed to be persistent across sessions, thus │ │ │ │ │ -cannot be used to reliably identify an output in e.g. configuration │ │ │ │ │ -files. │ │ │ │ │ -.sp │ │ │ │ │ -Examples of names include \(aqHDMI\-A\-1\(aq, \(aqWL\-1\(aq, \(aqX11\-1\(aq, etc. However, do │ │ │ │ │ -not assume that the name is a reflection of an underlying DRM │ │ │ │ │ -connector, X11 connection, etc. │ │ │ │ │ -.sp │ │ │ │ │ -The name event is sent after binding the output object. This event is │ │ │ │ │ -only sent once per output object, and the name does not change over the │ │ │ │ │ -lifetime of the \fI\%WlOutput\fP global. │ │ │ │ │ -.sp │ │ │ │ │ -Compositors may re\-use the same output name if the \fI\%WlOutput\fP │ │ │ │ │ -global is destroyed and re\-created later. Compositors should avoid re\- │ │ │ │ │ -using the same name if possible. │ │ │ │ │ -.sp │ │ │ │ │ -The name event will be followed by a done event. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -\fBname\fP (\fIArgumentType.String\fP) \-\- output name │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B description(description: \(aqstr\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 5 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Human\-readable description of this output │ │ │ │ │ -.sp │ │ │ │ │ -Many compositors can produce human\-readable descriptions of their │ │ │ │ │ -outputs. The client may wish to know this description as well, e.g. for │ │ │ │ │ -output selection purposes. │ │ │ │ │ -.sp │ │ │ │ │ -The description is a UTF\-8 string with no convention defined for its │ │ │ │ │ -contents. The description is not guaranteed to be unique among all │ │ │ │ │ -\fI\%WlOutput\fP globals. Examples might include \(aqFoocorp 11\(dq Display\(aq │ │ │ │ │ -or \(aqVirtual X11 output via :1\(aq. │ │ │ │ │ -.sp │ │ │ │ │ -The description event is sent after binding the output object and │ │ │ │ │ -whenever the description changes. The description is optional, and may │ │ │ │ │ -not be sent at all. │ │ │ │ │ -.sp │ │ │ │ │ -The description event will be followed by a done event. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -\fBdescription\fP (\fIArgumentType.String\fP) \-\- output description │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.SS WlBuffer │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlBuffer │ │ │ │ │ -Content for a \fI\%WlSurface\fP │ │ │ │ │ -.sp │ │ │ │ │ -A buffer provides the content for a │ │ │ │ │ -\fI\%WlSurface\fP\&. Buffers are created through │ │ │ │ │ -factory interfaces such as \fI\%WlShm\fP, │ │ │ │ │ -wp_linux_buffer_params (from the linux\-dmabuf protocol extension) or │ │ │ │ │ -similar. It has a width and a height and can be attached to a │ │ │ │ │ -\fI\%WlSurface\fP, but the mechanism by which │ │ │ │ │ -a client provides and updates the contents is defined by the buffer factory │ │ │ │ │ -interface. │ │ │ │ │ -.sp │ │ │ │ │ -Color channels are assumed to be electrical rather than optical (in other │ │ │ │ │ -words, encoded with a transfer function) unless otherwise specified. If the │ │ │ │ │ -buffer uses a format that has an alpha channel, the alpha channel is │ │ │ │ │ -assumed to be premultiplied into the electrical color channel values (after │ │ │ │ │ -transfer function encoding) unless otherwise specified. │ │ │ │ │ -.sp │ │ │ │ │ -Note, because \fI\%WlBuffer\fP objects are created from multiple │ │ │ │ │ -independent factory interfaces, the \fI\%WlBuffer\fP interface is frozen │ │ │ │ │ -at version 1. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B destroy() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Destroy a buffer │ │ │ │ │ -.sp │ │ │ │ │ -Destroy a buffer. If and how you need to release the backing storage is │ │ │ │ │ -defined by the buffer factory interface. │ │ │ │ │ -.sp │ │ │ │ │ -For possible side\-effects to a surface, see \fI\%WlSurface.attach()\fP\&. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B release() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Compositor releases buffer │ │ │ │ │ -.sp │ │ │ │ │ -Sent when this \fI\%WlBuffer\fP is no longer used by the compositor. │ │ │ │ │ -The client is now free to reuse or destroy this buffer and its backing │ │ │ │ │ -storage. │ │ │ │ │ -.sp │ │ │ │ │ -If a client receives a release event before the frame callback │ │ │ │ │ -requested in the same \fI\%WlSurface.commit()\fP that attaches this │ │ │ │ │ -\fI\%WlBuffer\fP to a surface, then the client is immediately free to │ │ │ │ │ -reuse the buffer and its backing storage, and does not need a second │ │ │ │ │ -buffer for the next surface content update. Typically this is possible, │ │ │ │ │ -when the compositor maintains a copy of the │ │ │ │ │ -\fI\%WlSurface\fP contents, e.g. as a GL │ │ │ │ │ -texture. This is an important optimization for GL(ES) compositors with │ │ │ │ │ -\fI\%WlShm\fP clients. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.SS WlSeat │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlSeat │ │ │ │ │ -Group of input devices │ │ │ │ │ -.sp │ │ │ │ │ -A seat is a group of keyboards, pointer and touch devices. This object is │ │ │ │ │ -published as a global during start up, or when such a device is hot │ │ │ │ │ -plugged. A seat typically has a pointer and maintains a keyboard focus and │ │ │ │ │ -a pointer focus. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B get_pointer() -> \(aqProxy[WlPointer]\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Return pointer object │ │ │ │ │ -.sp │ │ │ │ │ -The ID provided will be initialized to the │ │ │ │ │ -\fI\%WlPointer\fP interface for this seat. │ │ │ │ │ -.sp │ │ │ │ │ -This request only takes effect if the seat has the pointer capability, │ │ │ │ │ -or has had the pointer capability in the past. It is a protocol │ │ │ │ │ -violation to issue this request on a seat that has never had the │ │ │ │ │ -pointer capability. The missing_capability error will be sent in this │ │ │ │ │ -case. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Returns │ │ │ │ │ -\fI\%WlPointer\fP \-\- seat pointer │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B get_keyboard() -> \(aqProxy[WlKeyboard]\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 1 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Return keyboard object │ │ │ │ │ -.sp │ │ │ │ │ -The ID provided will be initialized to the │ │ │ │ │ -\fI\%WlKeyboard\fP interface for this │ │ │ │ │ -seat. │ │ │ │ │ -.sp │ │ │ │ │ -This request only takes effect if the seat has the keyboard capability, │ │ │ │ │ -or has had the keyboard capability in the past. It is a protocol │ │ │ │ │ -violation to issue this request on a seat that has never had the │ │ │ │ │ -keyboard capability. The missing_capability error will be sent in this │ │ │ │ │ -case. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Returns │ │ │ │ │ -\fI\%WlKeyboard\fP \-\- seat keyboard │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B get_touch() -> \(aqProxy[WlTouch]\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 2 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Return touch object │ │ │ │ │ -.sp │ │ │ │ │ -The ID provided will be initialized to the │ │ │ │ │ -\fI\%WlTouch\fP interface for this seat. │ │ │ │ │ -.sp │ │ │ │ │ -This request only takes effect if the seat has the touch capability, or │ │ │ │ │ -has had the touch capability in the past. It is a protocol violation to │ │ │ │ │ -issue this request on a seat that has never had the touch capability. │ │ │ │ │ -The missing_capability error will be sent in this case. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Returns │ │ │ │ │ -\fI\%WlTouch\fP \-\- seat touch │ │ │ │ │ -interface │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B release() -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 3 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Release the seat object │ │ │ │ │ -.sp │ │ │ │ │ -Using this request a client can tell the server that it is not going to │ │ │ │ │ -use the seat object anymore. │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B capabilities(capabilities: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Seat capabilities changed │ │ │ │ │ -.sp │ │ │ │ │ -This is emitted whenever a seat gains or loses the pointer, keyboard or │ │ │ │ │ -touch capabilities. The argument is a capability enum containing the │ │ │ │ │ -complete set of capabilities this seat has. │ │ │ │ │ -.sp │ │ │ │ │ -When the pointer capability is added, a client may create a │ │ │ │ │ -\fI\%WlPointer\fP object using the │ │ │ │ │ -\fI\%WlSeat.get_pointer()\fP request. This object will receive pointer │ │ │ │ │ -events until the capability is removed in the future. │ │ │ │ │ -.sp │ │ │ │ │ -When the pointer capability is removed, a client should destroy the │ │ │ │ │ -\fI\%WlPointer\fP objects associated with │ │ │ │ │ -the seat where the capability was removed, using the │ │ │ │ │ -\fI\%WlPointer.release()\fP request. No further │ │ │ │ │ -pointer events will be received on these objects. │ │ │ │ │ -.sp │ │ │ │ │ -In some compositors, if a seat regains the pointer capability and a │ │ │ │ │ -client has a previously obtained │ │ │ │ │ -\fI\%WlPointer\fP object of version 4 or │ │ │ │ │ -less, that object may start sending pointer events again. This behavior │ │ │ │ │ -is considered a misinterpretation of the intended behavior and must not │ │ │ │ │ -be relied upon by the client. │ │ │ │ │ -\fI\%WlPointer\fP objects of version 5 or │ │ │ │ │ -later must not send events if created before the most recent event │ │ │ │ │ -notifying the client of an added pointer capability. │ │ │ │ │ -.sp │ │ │ │ │ -The above behavior also applies to │ │ │ │ │ -\fI\%WlKeyboard\fP and │ │ │ │ │ -\fI\%WlTouch\fP with the keyboard and │ │ │ │ │ -touch capabilities, respectively. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -\fBcapabilities\fP (\fIArgumentType.Uint\fP) \-\- capabilities of the seat │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B name(name: \(aqstr\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Unique identifier for this seat │ │ │ │ │ -.sp │ │ │ │ │ -In a multi\-seat configuration the seat name can be used by clients to │ │ │ │ │ -help identify which physical devices the seat represents. │ │ │ │ │ -.sp │ │ │ │ │ -The seat name is a UTF\-8 string with no convention defined for its │ │ │ │ │ -contents. Each name is unique among all \fI\%WlSeat\fP globals. The │ │ │ │ │ -name is only guaranteed to be unique for the current compositor │ │ │ │ │ -instance. │ │ │ │ │ -.sp │ │ │ │ │ -The same seat names are used for all clients. Thus, the name can be │ │ │ │ │ -shared across processes to refer to a specific \fI\%WlSeat\fP global. │ │ │ │ │ -.sp │ │ │ │ │ -The name event is sent after binding to the seat global. This event is │ │ │ │ │ -only sent once per seat object, and the name does not change over the │ │ │ │ │ -lifetime of the \fI\%WlSeat\fP global. │ │ │ │ │ -.sp │ │ │ │ │ -Compositors may re\-use the same seat name if the \fI\%WlSeat\fP global │ │ │ │ │ -is destroyed and re\-created later. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -\fBname\fP (\fIArgumentType.String\fP) \-\- seat identifier │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.SS WlRegistry │ │ │ │ │ -.INDENT 0.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B class pywayland.protocol.wayland.WlRegistry │ │ │ │ │ -Global registry object │ │ │ │ │ -.sp │ │ │ │ │ -The singleton global registry object. The server has a number of global │ │ │ │ │ -objects that are available to all clients. These objects typically │ │ │ │ │ -represent an actual object in the server (for example, an input device) or │ │ │ │ │ -they are singleton objects that provide extension functionality. │ │ │ │ │ -.sp │ │ │ │ │ -When a client creates a registry object, the registry object will emit a │ │ │ │ │ -global event for each global currently in the registry. Globals come and │ │ │ │ │ -go as a result of device or monitor hotplugs, reconfiguration or other │ │ │ │ │ -events, and the registry will send out global and global_remove events to │ │ │ │ │ -keep the client up to date with the changes. To mark the end of the │ │ │ │ │ -initial burst of events, the client can use the \fI\%WlDisplay.sync()\fP request immediately after │ │ │ │ │ -calling \fI\%WlDisplay.get_registry()\fP\&. │ │ │ │ │ -.sp │ │ │ │ │ -A client can bind to a global object by using the bind request. This │ │ │ │ │ -creates a client\-side handle that lets the object emit events to the client │ │ │ │ │ -and lets the client invoke requests on the object. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B bind(name: \(aqint\(aq, interface: \(aqtype[T]\(aq, version: \(aqint\(aq) -> \(aqProxy[T]\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Request \-\- opcode 0 (attached to \fBResource\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Bind an object to the display │ │ │ │ │ -.sp │ │ │ │ │ -Binds a new, client\-created object to the server using the specified │ │ │ │ │ -name as the identifier. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBname\fP (\fIArgumentType.Uint\fP) \-\- unique numeric name of the object │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBinterface\fP (\fIstring\fP) \-\- Interface name │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBversion\fP (\fIint\fP) \-\- Interface version │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.TP │ │ │ │ │ -.B Returns │ │ │ │ │ -\fBpywayland.client.proxy.Proxy\fP of specified Interface \-\- │ │ │ │ │ -bounded object │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B global_(name: \(aqint\(aq, interface: \(aqstr\(aq, version: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 0 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Announce global object │ │ │ │ │ -.sp │ │ │ │ │ -Notify the client of global objects. │ │ │ │ │ -.sp │ │ │ │ │ -The event notifies the client that a global object with the given name │ │ │ │ │ -is now available, and it implements the given version of the given │ │ │ │ │ -interface. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBname\fP (\fIArgumentType.Uint\fP) \-\- numeric name of the global object │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBinterface\fP (\fIArgumentType.String\fP) \-\- interface implemented by the object │ │ │ │ │ -.IP \(bu 2 │ │ │ │ │ -\fBversion\fP (\fIArgumentType.Uint\fP) \-\- interface version │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B global_remove(name: \(aqint\(aq) -> \(aqNone\(aq │ │ │ │ │ -.sp │ │ │ │ │ -Event \-\- opcode 1 (attached to \fBProxy\fP instance) │ │ │ │ │ -.sp │ │ │ │ │ -Announce removal of global object │ │ │ │ │ -.sp │ │ │ │ │ -Notify the client of removed global objects. │ │ │ │ │ -.sp │ │ │ │ │ -This event notifies the client that the global identified by name is no │ │ │ │ │ -longer available. If the client bound to the global using the bind │ │ │ │ │ -request, the client should now destroy that object. │ │ │ │ │ -.sp │ │ │ │ │ -The object remains valid and requests to the object will be ignored │ │ │ │ │ -until the client destroys it, to avoid races between the global going │ │ │ │ │ -away and a client sending a request to it. │ │ │ │ │ -.INDENT 7.0 │ │ │ │ │ -.TP │ │ │ │ │ -.B Parameters │ │ │ │ │ -\fBname\fP (\fIArgumentType.Uint\fP) \-\- numeric name of the global object │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ -.UNINDENT │ │ │ │ │ .SS Scanner Modules │ │ │ │ │ .SS Argumet │ │ │ │ │ .INDENT 0.0 │ │ │ │ │ .TP │ │ │ │ │ .B class pywayland.scanner.argument.Argument(name: str, type: \fI\%ArgumentType\fP, summary: str | None, interface: str | None, allow_null: bool, enum: str | None, description: Description | None) │ │ │ │ │ Argument to a request or event method │ │ │ │ │ .sp