{"diffoscope-json-version": 1, "source1": "/srv/reproducible-results/rbuild-debian/r-b-build.WrDOrgL9/b1/pywayland_0.4.18-1_i386.changes", "source2": "/srv/reproducible-results/rbuild-debian/r-b-build.WrDOrgL9/b2/pywayland_0.4.18-1_i386.changes", "unified_diff": null, "details": [{"source1": "Files", "source2": "Files", "unified_diff": "@@ -1,4 +1,4 @@\n \n 7b7337a70f90f24cade7bcfd19981e72 38912 debug optional python3-pywayland-dbgsym_0.4.18-1_i386.deb\n- d10e4e77ceb112321a70d3695d71d8d2 51644 doc optional python3-pywayland-doc_0.4.18-1_all.deb\n- c067e7a12cba61a3840d5f58ee6dd187 119436 python optional python3-pywayland_0.4.18-1_i386.deb\n+ ed30936179ad036fe6973f65cc2525a7 51980 doc optional python3-pywayland-doc_0.4.18-1_all.deb\n+ 75f203e8379ba77d4f71439b91e472ed 119752 python optional python3-pywayland_0.4.18-1_i386.deb\n"}, {"source1": "python3-pywayland-doc_0.4.18-1_all.deb", "source2": "python3-pywayland-doc_0.4.18-1_all.deb", "unified_diff": null, "details": [{"source1": "file list", "source2": "file list", "unified_diff": "@@ -1,3 +1,3 @@\n -rw-r--r-- 0 0 0 4 2024-10-11 20:38:19.000000 debian-binary\n -rw-r--r-- 0 0 0 1304 2024-10-11 20:38:19.000000 control.tar.xz\n--rw-r--r-- 0 0 0 50148 2024-10-11 20:38:19.000000 data.tar.xz\n+-rw-r--r-- 0 0 0 50484 2024-10-11 20:38:19.000000 data.tar.xz\n"}, {"source1": "control.tar.xz", "source2": "control.tar.xz", "unified_diff": null, "details": [{"source1": "control.tar", "source2": "control.tar", "unified_diff": null, "details": [{"source1": "./md5sums", "source2": "./md5sums", "unified_diff": null, "details": [{"source1": "./md5sums", "source2": "./md5sums", "comments": ["Files differ"], "unified_diff": null}]}]}]}, {"source1": "data.tar.xz", "source2": "data.tar.xz", "unified_diff": null, "details": [{"source1": "data.tar", "source2": "data.tar", "unified_diff": null, "details": [{"source1": "file list", "source2": "file list", "unified_diff": "@@ -12,15 +12,15 @@\n -rw-r--r-- 0 root (0) root (0) 1092 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/index.txt\n -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\n drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/\n -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\n -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\n drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/protocol/\n -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\n--rw-r--r-- 0 root (0) root (0) 30286 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/protocol/wayland.txt.gz\n+-rw-r--r-- 0 root (0) root (0) 30610 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/protocol/wayland.txt.gz\n -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\n drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/text/module/scanner/\n -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\n -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\n -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\n -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\n -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\n"}, {"source1": "./usr/share/doc/python3-pywayland/text/module/protocol/index.txt", "source2": "./usr/share/doc/python3-pywayland/text/module/protocol/index.txt", "comments": ["Ordering differences only"], "unified_diff": "@@ -2,50 +2,50 @@\n ****************\n \n Wayland protocols built against Wayland 1.21.0 and Wayland Protocols\n 1.25.\n \n * wayland Module\n \n- * WlDataSource\n+ * WlDisplay\n \n- * WlSubsurface\n+ * WlCallback\n+\n+ * WlDataOffer\n+\n+ * WlTouch\n+\n+ * WlCompositor\n \n * WlDataDevice\n \n- * WlShellSurface\n+ * WlShmPool\n \n- * WlSurface\n+ * WlShellSurface\n \n- * WlTouch\n+ * WlOutput\n \n- * WlRegion\n+ * WlRegistry\n \n- * WlSubcompositor\n+ * WlDataSource\n \n * WlPointer\n \n- * WlDataOffer\n+ * WlDataDeviceManager\n \n- * WlSeat\n+ * WlShm\n \n * WlBuffer\n \n- * WlCompositor\n+ * WlSurface\n \n- * WlCallback\n+ * WlSubsurface\n \n * WlKeyboard\n \n- * WlOutput\n-\n- * WlRegistry\n-\n- * WlDataDeviceManager\n+ * WlSeat\n \n * WlShell\n \n- * WlShm\n-\n- * WlDisplay\n+ * WlRegion\n \n- * WlShmPool\n+ * WlSubcompositor\n"}, {"source1": "./usr/share/doc/python3-pywayland/text/module/protocol/wayland.txt.gz", "source2": "./usr/share/doc/python3-pywayland/text/module/protocol/wayland.txt.gz", "unified_diff": null, "details": [{"source1": "wayland.txt", "source2": "wayland.txt", "comments": ["Ordering differences only"], "unified_diff": "@@ -1,387 +1,583 @@\n wayland Module\n **************\n \n \n-WlDataSource\n-============\n+WlDisplay\n+=========\n \n-class pywayland.protocol.wayland.WlDataSource\n+class pywayland.protocol.wayland.WlDisplay\n \n- Offer to transfer data\n+ Core global object\n \n- The \"WlDataSource\" object is the source side of a \"WlDataOffer\". It\n- is created by the source client in a data transfer and provides a\n- way to describe the offered data and a way to respond to requests\n- to transfer the data.\n+ The core global object. This is a special singleton object. It is\n+ used for internal Wayland protocol features.\n \n- offer(mime_type: 'str') -> 'None'\n+ sync() -> 'Proxy[WlCallback]'\n \n -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Add an offered mime type\n+ Asynchronous roundtrip\n \n- This request adds a mime type to the set of mime types\n- advertised to targets. Can be called several times to offer\n- multiple types.\n+ The sync request asks the server to emit the 'done' event on the\n+ returned \"WlCallback\" object. Since requests are handled in-\n+ order and events are delivered in-order, this can be used as a\n+ barrier to ensure all previous requests and the resulting events\n+ have been handled.\n \n- Parameters:\n- **mime_type** (*ArgumentType.String*) -- mime type offered by\n- the data source\n+ The object returned by this request will be destroyed by the\n+ compositor after the callback is fired and as such the client\n+ must not attempt to use it after that point.\n \n- destroy() -> 'None'\n+ The callback_data passed in the callback is undefined and should\n+ be ignored.\n+\n+ Returns:\n+ \"WlCallback\" -- callback object for the sync request\n+\n+ get_registry() -> 'Proxy[WlRegistry]'\n \n -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n \n- Destroy the data source\n+ Get global registry object\n \n- Destroy the data source.\n+ This request creates a registry object that allows the client to\n+ list and bind the global objects available from the compositor.\n \n- set_actions(dnd_actions: 'int') -> 'None'\n+ It should be noted that the server side resources consumed in\n+ response to a get_registry request can only be released when the\n+ client disconnects, not when the client side proxy is destroyed.\n+ Therefore, clients should invoke get_registry as infrequently as\n+ possible to avoid wasting memory.\n \n- -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n+ Returns:\n+ \"WlRegistry\" -- global registry object\n \n- Set the available drag-and-drop actions\n+ error(object_id: 'Any', code: 'int', message: 'str') -> 'None'\n \n- Sets the actions that the source side client supports for this\n- operation. This request may trigger \"WlDataSource.action()\" and\n- \"WlDataOffer.action()\" events if the compositor needs to change\n- the selected action.\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n \n- The dnd_actions argument must contain only values expressed in\n- the \"WlDataDeviceManager.dnd_actions()\" enum, otherwise it will\n- result in a protocol error.\n+ Fatal error event\n \n- This request must be made once only, and can only be made on\n- sources used in drag-and-drop, so it must be performed before\n- \"WlDataDevice.start_drag()\". Attempting to use the source other\n- than for drag-and-drop will raise a protocol error.\n+ The error event is sent out when a fatal (non-recoverable) error\n+ has occurred. The object_id argument is the object where the\n+ error occurred, most often in response to a request to that\n+ object. The code identifies the error and is defined by the\n+ object interface. As such, each interface defines its own set\n+ of error codes. The message is a brief description of the\n+ error, for (debugging) convenience.\n \n Parameters:\n- **dnd_actions** (*ArgumentType.Uint*) -- actions supported by\n- the data source\n+ * **object_id** (*ArgumentType.Object*) -- object where the\n+ error occurred\n \n- target(mime_type: 'str | None') -> 'None'\n+ * **code** (*ArgumentType.Uint*) -- error code\n+\n+ * **message** (*ArgumentType.String*) -- error description\n+\n+ delete_id(id: 'int') -> 'None'\n+\n+ -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n+\n+ Acknowledge object id deletion\n+\n+ This event is used internally by the object ID management logic.\n+ When a client deletes an object that it had created, the server\n+ will send this event to acknowledge that it has seen the delete\n+ request. When the client receives this event, it will know that\n+ it can safely reuse the object ID.\n+\n+ Parameters:\n+ **id** (*ArgumentType.Uint*) -- deleted object ID\n+\n+\n+WlCallback\n+==========\n+\n+class pywayland.protocol.wayland.WlCallback\n+\n+ Callback object\n+\n+ Clients can handle the 'done' event to get notified when the\n+ related request is done.\n+\n+ Note, because \"WlCallback\" objects are created from multiple\n+ independent factory interfaces, the \"WlCallback\" interface is\n+ frozen at version 1.\n+\n+ done(callback_data: 'int') -> 'None'\n \n -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n \n- A target accepts an offered mime type\n+ Done event\n \n- Sent when a target accepts pointer_focus or motion events. If a\n- target does not accept any of the offered types, type is NULL.\n+ Notify the client when the related request is done.\n \n- Used for feedback during drag-and-drop.\n+ Parameters:\n+ **callback_data** (*ArgumentType.Uint*) -- request-specific\n+ data for the callback\n+\n+\n+WlDataOffer\n+===========\n+\n+class pywayland.protocol.wayland.WlDataOffer\n+\n+ Offer to transfer data\n+\n+ A \"WlDataOffer\" represents a piece of data offered for transfer by\n+ another client (the source client). It is used by the copy-and-\n+ paste and drag-and-drop mechanisms. The offer describes the\n+ different mime types that the data can be converted to and provides\n+ the mechanism for transferring the data directly from the source\n+ client.\n+\n+ accept(serial: 'int', mime_type: 'str | None') -> 'None'\n+\n+ -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n+\n+ Accept one of the offered mime types\n+\n+ Indicate that the client can accept the given mime type, or NULL\n+ for not accepted.\n+\n+ For objects of version 2 or older, this request is used by the\n+ client to give feedback whether the client can receive the given\n+ mime type, or NULL if none is accepted; the feedback does not\n+ determine whether the drag-and-drop operation succeeds or not.\n+\n+ For objects of version 3 or newer, this request determines the\n+ final result of the drag-and-drop operation. If the end result\n+ is that no mime types were accepted, the drag-and-drop operation\n+ will be cancelled and the corresponding drag source will receive\n+ \"WlDataSource.cancelled()\". Clients may still use this event in\n+ conjunction with \"WlDataSource.action()\" for feedback.\n \n Parameters:\n- **mime_type** (*ArgumentType.String* or *None*) -- mime type\n- accepted by the target\n+ * **serial** (*ArgumentType.Uint*) -- serial number of the\n+ accept request\n \n- send(mime_type: 'str', fd: 'int') -> 'None'\n+ * **mime_type** (*ArgumentType.String* or *None*) -- mime\n+ type accepted by the client\n \n- -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n+ receive(mime_type: 'str', fd: 'int') -> 'None'\n \n- Send the data\n+ -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n \n- Request for data from the client. Send the data as the\n- specified mime type over the passed file descriptor, then close\n- it.\n+ Request that the data is transferred\n+\n+ To transfer the offered data, the client issues this request and\n+ indicates the mime type it wants to receive. The transfer\n+ happens through the passed file descriptor (typically created\n+ with the pipe system call). The source client writes the data\n+ in the mime type representation requested and then closes the\n+ file descriptor.\n+\n+ The receiving client reads from the read end of the pipe until\n+ EOF and then closes its end, at which point the transfer is\n+ complete.\n+\n+ This request may happen multiple times for different mime types,\n+ both before and after \"WlDataDevice.drop()\". Drag-and-drop\n+ destination clients may preemptively fetch data or examine it\n+ more closely to determine acceptance.\n \n Parameters:\n- * **mime_type** (*ArgumentType.String*) -- mime type for the\n- data\n+ * **mime_type** (*ArgumentType.String*) -- mime type desired\n+ by receiver\n \n * **fd** (*ArgumentType.FileDescriptor*) -- file descriptor\n- for the data\n+ for data transfer\n \n- cancelled() -> 'None'\n+ destroy() -> 'None'\n \n- -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n+ -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n \n- Selection was cancelled\n+ Destroy data offer\n \n- This data source is no longer valid. There are several reasons\n- why this could happen:\n+ Destroy the data offer.\n \n- * The data source has been replaced by another data source.\n+ finish() -> 'None'\n \n- * The drag-and-drop operation was performed, but the drop\n- destination did not accept any of the mime types offered\n- through \"WlDataSource.target()\".\n+ -[ Request -- opcode 3 (attached to \"Resource\" instance) ]-\n \n- * The drag-and-drop operation was performed, but the drop\n- destination did not select any of the actions present in the\n- mask offered through \"WlDataSource.action()\".\n+ The offer will no longer be used\n \n- * The drag-and-drop operation was performed but didn't happen\n- over a surface.\n+ Notifies the compositor that the drag destination successfully\n+ finished the drag-and-drop operation.\n \n- * The compositor cancelled the drag-and-drop operation (e.g.\n- compositor dependent timeouts to avoid stale drag-and-drop\n- transfers).\n+ Upon receiving this request, the compositor will emit\n+ \"WlDataSource.dnd_finished()\" on the drag source client.\n \n- The client should clean up and destroy this data source.\n+ It is a client error to perform other requests than\n+ \"WlDataOffer.destroy()\" after this one. It is also an error to\n+ perform this request after a NULL mime type has been set in\n+ \"WlDataOffer.accept()\" or no action was received through\n+ \"WlDataOffer.action()\".\n \n- For objects of version 2 or older, \"WlDataSource.cancelled()\"\n- will only be emitted if the data source was replaced by another\n- data source.\n+ If \"WlDataOffer.finish()\" request is received for a non drag and\n+ drop operation, the invalid_finish protocol error is raised.\n \n- dnd_drop_performed() -> 'None'\n+ set_actions(dnd_actions: 'int', preferred_action: 'int') -> 'None'\n \n- -[ Event -- opcode 3 (attached to \"Proxy\" instance) ]-\n+ -[ Request -- opcode 4 (attached to \"Resource\" instance) ]-\n \n- The drag-and-drop operation physically finished\n+ Set the available/preferred drag-and-drop actions\n \n- The user performed the drop action. This event does not indicate\n- acceptance, \"WlDataSource.cancelled()\" may still be emitted\n- afterwards if the drop destination does not accept any mime\n- type.\n+ Sets the actions that the destination side client supports for\n+ this operation. This request may trigger the emission of\n+ \"WlDataSource.action()\" and \"WlDataOffer.action()\" events if the\n+ compositor needs to change the selected action.\n \n- However, this event might however not be received if the\n- compositor cancelled the drag-and-drop operation before this\n- event could happen.\n+ This request can be called multiple times throughout the drag-\n+ and-drop operation, typically in response to\n+ \"WlDataDevice.enter()\" or \"WlDataDevice.motion()\" events.\n \n- Note that the data_source may still be used in the future and\n- should not be destroyed here.\n+ This request determines the final result of the drag-and-drop\n+ operation. If the end result is that no action is accepted, the\n+ drag source will receive \"WlDataSource.cancelled()\".\n \n- dnd_finished() -> 'None'\n+ The dnd_actions argument must contain only values expressed in\n+ the \"WlDataDeviceManager.dnd_actions()\" enum, and the\n+ preferred_action argument must only contain one of those values\n+ set, otherwise it will result in a protocol error.\n \n- -[ Event -- opcode 4 (attached to \"Proxy\" instance) ]-\n+ While managing an \"ask\" action, the destination drag-and-drop\n+ client may perform further \"WlDataOffer.receive()\" requests, and\n+ is expected to perform one last \"WlDataOffer.set_actions()\"\n+ request with a preferred action other than \"ask\" (and optionally\n+ \"WlDataOffer.accept()\") before requesting\n+ \"WlDataOffer.finish()\", in order to convey the action selected\n+ by the user. If the preferred action is not in the\n+ \"WlDataOffer.source_actions()\" mask, an error will be raised.\n \n- The drag-and-drop operation concluded\n+ If the \"ask\" action is dismissed (e.g. user cancellation), the\n+ client is expected to perform \"WlDataOffer.destroy()\" right\n+ away.\n \n- The drop destination finished interoperating with this data\n- source, so the client is now free to destroy this data source\n- and free all associated data.\n+ This request can only be made on drag-and-drop offers, a\n+ protocol error will be raised otherwise.\n \n- If the action used to perform the operation was \"move\", the\n- source can now delete the transferred data.\n+ Parameters:\n+ * **dnd_actions** (*ArgumentType.Uint*) -- actions supported\n+ by the destination client\n+\n+ * **preferred_action** (*ArgumentType.Uint*) -- action\n+ preferred by the destination client\n+\n+ offer(mime_type: 'str') -> 'None'\n+\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n+\n+ Advertise offered mime type\n+\n+ Sent immediately after creating the \"WlDataOffer\" object. One\n+ event per offered mime type.\n+\n+ Parameters:\n+ **mime_type** (*ArgumentType.String*) -- offered mime type\n+\n+ source_actions(source_actions: 'int') -> 'None'\n+\n+ -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n+\n+ Notify the source-side available actions\n+\n+ This event indicates the actions offered by the data source. It\n+ will be sent immediately after creating the \"WlDataOffer\"\n+ object, or anytime the source side changes its offered actions\n+ through \"WlDataSource.set_actions()\".\n+\n+ Parameters:\n+ **source_actions** (*ArgumentType.Uint*) -- actions offered\n+ by the data source\n \n action(dnd_action: 'int') -> 'None'\n \n- -[ Event -- opcode 5 (attached to \"Proxy\" instance) ]-\n+ -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n \n Notify the selected action\n \n This event indicates the action selected by the compositor after\n matching the source/destination side actions. Only one action\n (or none) will be offered here.\n \n This event can be emitted multiple times during the drag-and-\n- drop operation, mainly in response to destination side changes\n- through \"WlDataOffer.set_actions()\", and as the data device\n- enters/leaves surfaces.\n+ drop operation in response to destination side action changes\n+ through \"WlDataOffer.set_actions()\".\n \n- It is only possible to receive this event after\n- \"WlDataSource.dnd_drop_performed()\" if the drag-and-drop\n- operation ended in an \"ask\" action, in which case the final\n- \"WlDataSource.action()\" event will happen immediately before\n- \"WlDataSource.dnd_finished()\".\n+ This event will no longer be emitted after \"WlDataDevice.drop()\"\n+ happened on the drag- and-drop destination, the client must\n+ honor the last action received, or the last preferred one set\n+ through \"WlDataOffer.set_actions()\" when handling an \"ask\"\n+ action.\n \n Compositors may also change the selected action on the fly,\n mainly in response to keyboard modifier changes during the drag-\n and-drop operation.\n \n- The most recent action received is always the valid one. The\n- chosen action may change alongside negotiation (e.g. an \"ask\"\n- action can turn into a \"move\" operation), so the effects of the\n- final action must always be applied in\n- \"WlDataOffer.dnd_finished()\".\n+ The most recent action received is always the valid one. Prior\n+ to receiving \"WlDataDevice.drop()\", the chosen action may change\n+ (e.g. due to keyboard modifiers being pressed). At the time of\n+ receiving \"WlDataDevice.drop()\" the drag-and-drop destination\n+ must honor the last action received.\n \n- Clients can trigger cursor surface changes from this point, so\n- they reflect the current action.\n+ Action changes may still happen after \"WlDataDevice.drop()\",\n+ especially on \"ask\" actions, where the drag-and-drop destination\n+ may choose another action afterwards. Action changes happening\n+ at this stage are always the result of inter-client negotiation,\n+ the compositor shall no longer be able to induce a different\n+ action.\n+\n+ Upon \"ask\" actions, it is expected that the drag-and-drop\n+ destination may potentially choose a different action and/or\n+ mime type, based on \"WlDataOffer.source_actions()\" and finally\n+ chosen by the user (e.g. popping up a menu with the available\n+ options). The final \"WlDataOffer.set_actions()\" and\n+ \"WlDataOffer.accept()\" requests must happen before the call to\n+ \"WlDataOffer.finish()\".\n \n Parameters:\n **dnd_action** (*ArgumentType.Uint*) -- action selected by\n the compositor\n \n \n-WlSubsurface\n-============\n+WlTouch\n+=======\n \n-class pywayland.protocol.wayland.WlSubsurface\n+class pywayland.protocol.wayland.WlTouch\n \n- Sub-surface interface to a \"WlSurface\"\n+ Touchscreen input device\n \n- An additional interface to a \"WlSurface\" object, which has been\n- made a sub-surface. A sub-surface has one parent surface. A sub-\n- surface's size and position are not limited to that of the parent.\n- Particularly, a sub-surface is not automatically clipped to its\n- parent's area.\n+ The \"WlTouch\" interface represents a touchscreen associated with a\n+ seat.\n \n- A sub-surface becomes mapped, when a non-NULL \"WlBuffer\" is applied\n- and the parent surface is mapped. The order of which one happens\n- first is irrelevant. A sub-surface is hidden if the parent becomes\n- hidden, or if a NULL \"WlBuffer\" is applied. These rules apply\n- recursively through the tree of surfaces.\n+ Touch interactions can consist of one or more contacts. For each\n+ contact, a series of events is generated, starting with a down\n+ event, followed by zero or more motion events, and ending with an\n+ up event. Events relating to the same contact point can be\n+ identified by the ID of the sequence.\n \n- The behaviour of a \"WlSurface.commit()\" request on a sub-surface\n- depends on the sub-surface's mode. The possible modes are\n- synchronized and desynchronized, see methods\n- \"WlSubsurface.set_sync()\" and \"WlSubsurface.set_desync()\".\n- Synchronized mode caches the \"WlSurface\" state to be applied when\n- the parent's state gets applied, and desynchronized mode applies\n- the pending \"WlSurface\" state directly. A sub- surface is initially\n- in the synchronized mode.\n+ release() -> 'None'\n \n- Sub-surfaces also have another kind of state, which is managed by\n- \"WlSubsurface\" requests, as opposed to \"WlSurface\" requests. This\n- state includes the sub-surface position relative to the parent\n- surface (\"WlSubsurface.set_position()\"), and the stacking order of\n- the parent and its sub-surfaces (\"WlSubsurface.place_above()\" and\n- .place_below). This state is applied when the parent surface's\n- \"WlSurface\" state is applied, regardless of the sub-surface's mode.\n- As the exception, set_sync and set_desync are effective\n- immediately.\n+ -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- The main surface can be thought to be always in desynchronized\n- mode, since it does not have a parent in the sub-surfaces sense.\n+ Release the touch object\n \n- Even if a sub-surface is in desynchronized mode, it will behave as\n- in synchronized mode, if its parent surface behaves as in\n- synchronized mode. This rule is applied recursively throughout the\n- tree of surfaces. This means, that one can set a sub-surface into\n- synchronized mode, and then assume that all its child and grand-\n- child sub-surfaces are synchronized, too, without explicitly\n- setting them.\n+ down(serial: 'int', time: 'int', surface: 'WlSurface', id: 'int', x: 'float', y: 'float') -> 'None'\n \n- Destroying a sub-surface takes effect immediately. If you need to\n- synchronize the removal of a sub-surface to the parent surface\n- update, unmap the sub-surface first by attaching a NULL \"WlBuffer\",\n- update parent, and then destroy the sub-surface.\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n \n- If the parent \"WlSurface\" object is destroyed, the sub-surface is\n- unmapped.\n+ Touch down event and beginning of a touch sequence\n \n- A sub-surface never has the keyboard focus of any seat.\n+ A new touch point has appeared on the surface. This touch point\n+ is assigned a unique ID. Future events from this touch point\n+ reference this ID. The ID ceases to be valid after a touch up\n+ event and may be reused in the future.\n \n- The \"WlSurface.offset()\" request is ignored: clients must use\n- set_position instead to move the sub-surface.\n+ Parameters:\n+ * **serial** (*ArgumentType.Uint*) -- serial number of the\n+ touch down event\n \n- destroy() -> 'None'\n+ * **time** (*ArgumentType.Uint*) -- timestamp with\n+ millisecond granularity\n \n- -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n+ * **surface** (\"WlSurface\") -- surface touched\n \n- Remove sub-surface interface\n+ * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n+ point\n \n- The sub-surface interface is removed from the \"WlSurface\" object\n- that was turned into a sub-surface with a\n- \"WlSubcompositor.get_subsurface()\" request. The wl_surface's\n- association to the parent is deleted. The \"WlSurface\" is\n- unmapped immediately.\n+ * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate\n \n- set_position(x: 'int', y: 'int') -> 'None'\n+ * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate\n \n- -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n+ up(serial: 'int', time: 'int', id: 'int') -> 'None'\n \n- Reposition the sub-surface\n+ -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n \n- This schedules a sub-surface position change. The sub-surface\n- will be moved so that its origin (top left corner pixel) will be\n- at the location x, y of the parent surface coordinate system.\n- The coordinates are not restricted to the parent surface area.\n- Negative values are allowed.\n+ End of a touch event sequence\n \n- The scheduled coordinates will take effect whenever the state of\n- the parent surface is applied.\n+ The touch point has disappeared. No further events will be sent\n+ for this touch point and the touch point's ID is released and\n+ may be reused in a future touch down event.\n \n- If more than one set_position request is invoked by the client\n- before the commit of the parent surface, the position of a new\n- request always replaces the scheduled position from any previous\n- request.\n+ Parameters:\n+ * **serial** (*ArgumentType.Uint*) -- serial number of the\n+ touch up event\n \n- The initial position is 0, 0.\n+ * **time** (*ArgumentType.Uint*) -- timestamp with\n+ millisecond granularity\n+\n+ * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n+ point\n+\n+ motion(time: 'int', id: 'int', x: 'float', y: 'float') -> 'None'\n+\n+ -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n+\n+ Update of touch point coordinates\n+\n+ A touch point has changed coordinates.\n \n Parameters:\n- * **x** (*ArgumentType.Int*) -- x coordinate in the parent\n- surface\n+ * **time** (*ArgumentType.Uint*) -- timestamp with\n+ millisecond granularity\n \n- * **y** (*ArgumentType.Int*) -- y coordinate in the parent\n- surface\n+ * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n+ point\n \n- place_above(sibling: 'WlSurface') -> 'None'\n+ * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate\n \n- -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n+ * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate\n \n- Restack the sub-surface\n+ frame() -> 'None'\n \n- This sub-surface is taken from the stack, and put back just\n- above the reference surface, changing the z-order of the sub-\n- surfaces. The reference surface must be one of the sibling\n- surfaces, or the parent surface. Using any other surface,\n- including this sub-surface, will cause a protocol error.\n+ -[ Event -- opcode 3 (attached to \"Proxy\" instance) ]-\n \n- The z-order is double-buffered. Requests are handled in order\n- and applied immediately to a pending state. The final pending\n- state is copied to the active state the next time the state of\n- the parent surface is applied.\n+ End of touch frame event\n \n- A new sub-surface is initially added as the top-most in the\n- stack of its siblings and parent.\n+ Indicates the end of a set of events that logically belong\n+ together. A client is expected to accumulate the data in all\n+ events within the frame before proceeding.\n+\n+ A \"WlTouch.frame()\" terminates at least one event but otherwise\n+ no guarantee is provided about the set of events within a frame.\n+ A client must assume that any state not updated in a frame is\n+ unchanged from the previously known state.\n+\n+ cancel() -> 'None'\n+\n+ -[ Event -- opcode 4 (attached to \"Proxy\" instance) ]-\n+\n+ Touch session cancelled\n+\n+ Sent if the compositor decides the touch stream is a global\n+ gesture. No further events are sent to the clients from that\n+ particular gesture. Touch cancellation applies to all touch\n+ points currently active on this client's surface. The client is\n+ responsible for finalizing the touch points, future touch points\n+ on this surface may reuse the touch point ID.\n+\n+ No frame event is required after the cancel event.\n+\n+ shape(id: 'int', major: 'float', minor: 'float') -> 'None'\n+\n+ -[ Event -- opcode 5 (attached to \"Proxy\" instance) ]-\n+\n+ Update shape of touch point\n+\n+ Sent when a touchpoint has changed its shape.\n+\n+ This event does not occur on its own. It is sent before a\n+ \"WlTouch.frame()\" event and carries the new shape information\n+ for any previously reported, or new touch points of that frame.\n+\n+ Other events describing the touch point such as\n+ \"WlTouch.down()\", \"WlTouch.motion()\" or \"WlTouch.orientation()\"\n+ may be sent within the same \"WlTouch.frame()\". A client should\n+ treat these events as a single logical touch point update. The\n+ order of \"WlTouch.shape()\", \"WlTouch.orientation()\" and\n+ \"WlTouch.motion()\" is not guaranteed. A \"WlTouch.down()\" event\n+ is guaranteed to occur before the first \"WlTouch.shape()\" event\n+ for this touch ID but both events may occur within the same\n+ \"WlTouch.frame()\".\n+\n+ A touchpoint shape is approximated by an ellipse through the\n+ major and minor axis length. The major axis length describes the\n+ longer diameter of the ellipse, while the minor axis length\n+ describes the shorter diameter. Major and minor are orthogonal\n+ and both are specified in surface-local coordinates. The center\n+ of the ellipse is always at the touchpoint location as reported\n+ by \"WlTouch.down()\" or \"WlTouch.move()\".\n+\n+ This event is only sent by the compositor if the touch device\n+ supports shape reports. The client has to make reasonable\n+ assumptions about the shape if it did not receive this event.\n \n Parameters:\n- **sibling** (\"WlSurface\") -- the reference surface\n+ * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n+ point\n \n- place_below(sibling: 'WlSurface') -> 'None'\n+ * **major** (*ArgumentType.Fixed*) -- length of the major\n+ axis in surface-local coordinates\n \n- -[ Request -- opcode 3 (attached to \"Resource\" instance) ]-\n+ * **minor** (*ArgumentType.Fixed*) -- length of the minor\n+ axis in surface-local coordinates\n \n- Restack the sub-surface\n+ orientation(id: 'int', orientation: 'float') -> 'None'\n \n- The sub-surface is placed just below the reference surface. See\n- \"WlSubsurface.place_above()\".\n+ -[ Event -- opcode 6 (attached to \"Proxy\" instance) ]-\n+\n+ Update orientation of touch point\n+\n+ Sent when a touchpoint has changed its orientation.\n+\n+ This event does not occur on its own. It is sent before a\n+ \"WlTouch.frame()\" event and carries the new shape information\n+ for any previously reported, or new touch points of that frame.\n+\n+ Other events describing the touch point such as\n+ \"WlTouch.down()\", \"WlTouch.motion()\" or \"WlTouch.shape()\" may be\n+ sent within the same \"WlTouch.frame()\". A client should treat\n+ these events as a single logical touch point update. The order\n+ of \"WlTouch.shape()\", \"WlTouch.orientation()\" and\n+ \"WlTouch.motion()\" is not guaranteed. A \"WlTouch.down()\" event\n+ is guaranteed to occur before the first \"WlTouch.orientation()\"\n+ event for this touch ID but both events may occur within the\n+ same \"WlTouch.frame()\".\n+\n+ The orientation describes the clockwise angle of a touchpoint's\n+ major axis to the positive surface y-axis and is normalized to\n+ the -180 to +180 degree range. The granularity of orientation\n+ depends on the touch device, some devices only support binary\n+ rotation values between 0 and 90 degrees.\n+\n+ This event is only sent by the compositor if the touch device\n+ supports orientation reports.\n \n Parameters:\n- **sibling** (\"WlSurface\") -- the reference surface\n+ * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n+ point\n \n- set_sync() -> 'None'\n+ * **orientation** (*ArgumentType.Fixed*) -- angle between\n+ major axis and positive surface y-axis in degrees\n \n- -[ Request -- opcode 4 (attached to \"Resource\" instance) ]-\n \n- Set sub-surface to synchronized mode\n+WlCompositor\n+============\n \n- Change the commit behaviour of the sub-surface to synchronized\n- mode, also described as the parent dependent mode.\n+class pywayland.protocol.wayland.WlCompositor\n \n- In synchronized mode, \"WlSurface.commit()\" on a sub-surface will\n- accumulate the committed state in a cache, but the state will\n- not be applied and hence will not change the compositor output.\n- The cached state is applied to the sub-surface immediately after\n- the parent surface's state is applied. This ensures atomic\n- updates of the parent and all its synchronized sub-surfaces.\n- Applying the cached state will invalidate the cache, so further\n- parent surface commits do not (re-)apply old state.\n+ The compositor singleton\n \n- See \"WlSubsurface\" for the recursive effect of this mode.\n+ A compositor. This object is a singleton global. The compositor\n+ is in charge of combining the contents of multiple surfaces into\n+ one displayable output.\n \n- set_desync() -> 'None'\n+ create_surface() -> 'Proxy[WlSurface]'\n \n- -[ Request -- opcode 5 (attached to \"Resource\" instance) ]-\n+ -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Set sub-surface to desynchronized mode\n+ Create new surface\n \n- Change the commit behaviour of the sub-surface to desynchronized\n- mode, also described as independent or freely running mode.\n+ Ask the compositor to create a new surface.\n \n- In desynchronized mode, \"WlSurface.commit()\" on a sub-surface\n- will apply the pending state directly, without caching, as\n- happens normally with a \"WlSurface\". Calling\n- \"WlSurface.commit()\" on the parent surface has no effect on the\n- sub-surface's \"WlSurface\" state. This mode allows a sub-surface\n- to be updated on its own.\n+ Returns:\n+ \"WlSurface\" -- the new surface\n \n- If cached state exists when \"WlSurface.commit()\" is called in\n- desynchronized mode, the pending state is added to the cached\n- state, and applied as a whole. This invalidates the cache.\n+ create_region() -> 'Proxy[WlRegion]'\n \n- Note: even if a sub-surface is set to desynchronized, a parent\n- sub- surface may override it to behave as synchronized. For\n- details, see \"WlSubsurface\".\n+ -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n \n- If a surface's parent surface behaves as desynchronized, then\n- the cached state is applied on set_desync.\n+ Create new region\n+\n+ Ask the compositor to create a new region.\n+\n+ Returns:\n+ \"WlRegion\" -- the new region\n \n \n WlDataDevice\n ============\n \n class pywayland.protocol.wayland.WlDataDevice\n \n@@ -582,14 +778,97 @@\n data_offer, if any, upon receiving this event.\n \n Parameters:\n **id** (\"WlDataOffer\" or *None*) -- selection data_offer\n object\n \n \n+WlShmPool\n+=========\n+\n+class pywayland.protocol.wayland.WlShmPool\n+\n+ A shared memory pool\n+\n+ The \"WlShmPool\" object encapsulates a piece of memory shared\n+ between the compositor and client. Through the \"WlShmPool\" object,\n+ the client can allocate shared memory \"WlBuffer\" objects. All\n+ objects created through the same pool share the same underlying\n+ mapped memory. Reusing the mapped memory avoids the setup/teardown\n+ overhead and is useful when interactively resizing a surface or for\n+ many small buffers.\n+\n+ create_buffer(offset: 'int', width: 'int', height: 'int', stride: 'int', format: 'int') -> 'Proxy[WlBuffer]'\n+\n+ -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n+\n+ Create a buffer from the pool\n+\n+ Create a \"WlBuffer\" object from the pool.\n+\n+ The buffer is created offset bytes into the pool and has width\n+ and height as specified. The stride argument specifies the\n+ number of bytes from the beginning of one row to the beginning\n+ of the next. The format is the pixel format of the buffer and\n+ must be one of those advertised through the \"WlShm.format()\"\n+ event.\n+\n+ A buffer will keep a reference to the pool it was created from\n+ so it is valid to destroy the pool immediately after creating a\n+ buffer from it.\n+\n+ Parameters:\n+ * **offset** (*ArgumentType.Int*) -- buffer byte offset\n+ within the pool\n+\n+ * **width** (*ArgumentType.Int*) -- buffer width, in pixels\n+\n+ * **height** (*ArgumentType.Int*) -- buffer height, in pixels\n+\n+ * **stride** (*ArgumentType.Int*) -- number of bytes from the\n+ beginning of one row to the beginning of the next row\n+\n+ * **format** (*ArgumentType.Uint*) -- buffer pixel format\n+\n+ Returns:\n+ \"WlBuffer\" -- buffer to create\n+\n+ destroy() -> 'None'\n+\n+ -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n+\n+ Destroy the pool\n+\n+ Destroy the shared memory pool.\n+\n+ The mmapped memory will be released when all buffers that have\n+ been created from this pool are gone.\n+\n+ resize(size: 'int') -> 'None'\n+\n+ -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n+\n+ Change the size of the pool mapping\n+\n+ This request will cause the server to remap the backing memory\n+ for the pool from the file descriptor passed when the pool was\n+ created, but using the new size. This request can only be used\n+ to make the pool bigger.\n+\n+ This request only changes the amount of bytes that are mmapped\n+ by the server and does not touch the file corresponding to the\n+ file descriptor passed at creation time. It is the client's\n+ responsibility to ensure that the file is at least as big as the\n+ new pool size.\n+\n+ Parameters:\n+ **size** (*ArgumentType.Int*) -- new size of the pool, in\n+ bytes\n+\n+\n WlShellSurface\n ==============\n \n class pywayland.protocol.wayland.WlShellSurface\n \n Desktop-style metadata interface\n \n@@ -896,905 +1175,528 @@\n Popup interaction is done\n \n The popup_done event is sent out when a popup grab is broken,\n that is, when the user clicks a surface that doesn't belong to\n the client owning the popup surface.\n \n \n-WlSurface\n-=========\n-\n-class pywayland.protocol.wayland.WlSurface\n-\n- An onscreen surface\n-\n- A surface is a rectangular area that may be displayed on zero or\n- more outputs, and shown any number of times at the compositor's\n- discretion. They can present wl_buffers, receive user input, and\n- define a local coordinate system.\n-\n- The size of a surface (and relative positions on it) is described\n- in surface-local coordinates, which may differ from the buffer\n- coordinates of the pixel content, in case a buffer_transform or a\n- buffer_scale is used.\n-\n- A surface without a \"role\" is fairly useless: a compositor does not\n- know where, when or how to present it. The role is the purpose of a\n- \"WlSurface\". Examples of roles are a cursor for a pointer (as set\n- by \"WlPointer.set_cursor()\"), a drag icon\n- (\"WlDataDevice.start_drag()\"), a sub-surface\n- (\"WlSubcompositor.get_subsurface()\"), and a window as defined by a\n- shell protocol (e.g. \"WlShell.get_shell_surface()\").\n+WlOutput\n+========\n \n- A surface can have only one role at a time. Initially a \"WlSurface\"\n- does not have a role. Once a \"WlSurface\" is given a role, it is set\n- permanently for the whole lifetime of the \"WlSurface\" object.\n- Giving the current role again is allowed, unless explicitly\n- forbidden by the relevant interface specification.\n+class pywayland.protocol.wayland.WlOutput\n \n- Surface roles are given by requests in other interfaces such as\n- \"WlPointer.set_cursor()\". The request should explicitly mention\n- that this request gives a role to a \"WlSurface\". Often, this\n- request also creates a new protocol object that represents the role\n- and adds additional functionality to \"WlSurface\". When a client\n- wants to destroy a \"WlSurface\", they must destroy this role object\n- before the \"WlSurface\", otherwise a defunct_role_object error is\n- sent.\n+ Compositor output region\n \n- Destroying the role object does not remove the role from the\n- \"WlSurface\", but it may stop the \"WlSurface\" from \"playing the\n- role\". For instance, if a \"WlSubsurface\" object is destroyed, the\n- \"WlSurface\" it was created for will be unmapped and forget its\n- position and z-order. It is allowed to create a \"WlSubsurface\" for\n- the same \"WlSurface\" again, but it is not allowed to use the\n- \"WlSurface\" as a cursor (cursor is a different role than sub-\n- surface, and role switching is not allowed).\n+ An output describes part of the compositor geometry. The\n+ compositor works in the 'compositor coordinate system' and an\n+ output corresponds to a rectangular area in that space that is\n+ actually visible. This typically corresponds to a monitor that\n+ displays part of the compositor space. This object is published as\n+ global during start up, or when a monitor is hotplugged.\n \n- destroy() -> 'None'\n+ release() -> 'None'\n \n -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Delete surface\n-\n- Deletes the surface and invalidates its object ID.\n-\n- attach(buffer: 'WlBuffer | None', x: 'int', y: 'int') -> 'None'\n-\n- -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n-\n- Set the surface contents\n-\n- Set a buffer as the content of this surface.\n-\n- The new size of the surface is calculated based on the buffer\n- size transformed by the inverse buffer_transform and the inverse\n- buffer_scale. This means that at commit time the supplied buffer\n- size must be an integer multiple of the buffer_scale. If that's\n- not the case, an invalid_size error is sent.\n-\n- The x and y arguments specify the location of the new pending\n- buffer's upper left corner, relative to the current buffer's\n- upper left corner, in surface-local coordinates. In other words,\n- the x and y, combined with the new surface size define in which\n- directions the surface's size changes. Setting anything other\n- than 0 as x and y arguments is discouraged, and should instead\n- be replaced with using the separate \"WlSurface.offset()\"\n- request.\n-\n- When the bound \"WlSurface\" version is 5 or higher, passing any\n- non-zero x or y is a protocol violation, and will result in an\n- 'invalid_offset' error being raised. The x and y arguments are\n- ignored and do not change the pending state. To achieve\n- equivalent semantics, use \"WlSurface.offset()\".\n-\n- Surface contents are double-buffered state, see\n- \"WlSurface.commit()\".\n-\n- The initial surface contents are void; there is no content.\n- \"WlSurface.attach()\" assigns the given \"WlBuffer\" as the pending\n- \"WlBuffer\". \"WlSurface.commit()\" makes the pending \"WlBuffer\"\n- the new surface contents, and the size of the surface becomes\n- the size calculated from the \"WlBuffer\", as described above.\n- After commit, there is no pending buffer until the next attach.\n-\n- Committing a pending \"WlBuffer\" allows the compositor to read\n- the pixels in the \"WlBuffer\". The compositor may access the\n- pixels at any time after the \"WlSurface.commit()\" request. When\n- the compositor will not access the pixels anymore, it will send\n- the \"WlBuffer.release()\" event. Only after receiving\n- \"WlBuffer.release()\", the client may reuse the \"WlBuffer\". A\n- \"WlBuffer\" that has been attached and then replaced by another\n- attach instead of committed will not receive a release event,\n- and is not used by the compositor.\n-\n- If a pending \"WlBuffer\" has been committed to more than one\n- \"WlSurface\", the delivery of \"WlBuffer.release()\" events becomes\n- undefined. A well behaved client should not rely on\n- \"WlBuffer.release()\" events in this case. Alternatively, a\n- client could create multiple \"WlBuffer\" objects from the same\n- backing storage or use wp_linux_buffer_release.\n-\n- Destroying the \"WlBuffer\" after \"WlBuffer.release()\" does not\n- change the surface contents. Destroying the \"WlBuffer\" before\n- \"WlBuffer.release()\" is allowed as long as the underlying buffer\n- storage isn't re-used (this can happen e.g. on client process\n- termination). However, if the client destroys the \"WlBuffer\"\n- before receiving the \"WlBuffer.release()\" event and mutates the\n- underlying buffer storage, the surface contents become undefined\n- immediately.\n-\n- If \"WlSurface.attach()\" is sent with a NULL \"WlBuffer\", the\n- following \"WlSurface.commit()\" will remove the surface content.\n-\n- If a pending \"WlBuffer\" has been destroyed, the result is not\n- specified. Many compositors are known to remove the surface\n- content on the following \"WlSurface.commit()\", but this\n- behaviour is not universal. Clients seeking to maximise\n- compatibility should not destroy pending buffers and should\n- ensure that they explicitly remove content from surfaces, even\n- after destroying buffers.\n-\n- Parameters:\n- * **buffer** (\"WlBuffer\" or *None*) -- buffer of surface\n- contents\n-\n- * **x** (*ArgumentType.Int*) -- surface-local x coordinate\n-\n- * **y** (*ArgumentType.Int*) -- surface-local y coordinate\n+ Release the output object\n \n- damage(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None'\n+ Using this request a client can tell the server that it is not\n+ going to use the output object anymore.\n \n- -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n+ geometry(x: 'int', y: 'int', physical_width: 'int', physical_height: 'int', subpixel: 'int', make: 'str', model: 'str', transform: 'int') -> 'None'\n \n- Mark part of the surface damaged\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n \n- This request is used to describe the regions where the pending\n- buffer is different from the current surface contents, and where\n- the surface therefore needs to be repainted. The compositor\n- ignores the parts of the damage that fall outside of the\n- surface.\n+ Properties of the output\n \n- Damage is double-buffered state, see \"WlSurface.commit()\".\n+ The geometry event describes geometric properties of the output.\n+ The event is sent when binding to the output object and whenever\n+ any of the properties change.\n \n- The damage rectangle is specified in surface-local coordinates,\n- where x and y specify the upper left corner of the damage\n- rectangle.\n+ The physical size can be set to zero if it doesn't make sense\n+ for this output (e.g. for projectors or virtual outputs).\n \n- The initial value for pending damage is empty: no damage.\n- \"WlSurface.damage()\" adds pending damage: the new pending damage\n- is the union of old pending damage and the given rectangle.\n+ The geometry event will be followed by a done event (starting\n+ from version 2).\n \n- \"WlSurface.commit()\" assigns pending damage as the current\n- damage, and clears pending damage. The server will clear the\n- current damage as it repaints the surface.\n+ Clients should use \"WlSurface.preferred_buffer_transform()\"\n+ instead of the transform advertised by this event to find the\n+ preferred buffer transform to use for a surface.\n \n- Note! New clients should not use this request. Instead damage\n- can be posted with \"WlSurface.damage_buffer()\" which uses buffer\n- coordinates instead of surface coordinates.\n+ Note: \"WlOutput\" only advertises partial information about the\n+ output position and identification. Some compositors, for\n+ instance those not implementing a desktop-style output layout or\n+ those exposing virtual outputs, might fake this information.\n+ Instead of using x and y, clients should use\n+ xdg_output.logical_position. Instead of using make and model,\n+ clients should use name and description.\n \n Parameters:\n- * **x** (*ArgumentType.Int*) -- surface-local x coordinate\n-\n- * **y** (*ArgumentType.Int*) -- surface-local y coordinate\n-\n- * **width** (*ArgumentType.Int*) -- width of damage rectangle\n-\n- * **height** (*ArgumentType.Int*) -- height of damage\n- rectangle\n-\n- frame() -> 'Proxy[WlCallback]'\n-\n- -[ Request -- opcode 3 (attached to \"Resource\" instance) ]-\n-\n- Request a frame throttling hint\n+ * **x** (*ArgumentType.Int*) -- x position within the global\n+ compositor space\n \n- Request a notification when it is a good time to start drawing a\n- new frame, by creating a frame callback. This is useful for\n- throttling redrawing operations, and driving animations.\n+ * **y** (*ArgumentType.Int*) -- y position within the global\n+ compositor space\n \n- When a client is animating on a \"WlSurface\", it can use the\n- 'frame' request to get notified when it is a good time to draw\n- and commit the next frame of animation. If the client commits an\n- update earlier than that, it is likely that some updates will\n- not make it to the display, and the client is wasting resources\n- by drawing too often.\n+ * **physical_width** (*ArgumentType.Int*) -- width in\n+ millimeters of the output\n \n- The frame request will take effect on the next\n- \"WlSurface.commit()\". The notification will only be posted for\n- one frame unless requested again. For a \"WlSurface\", the\n- notifications are posted in the order the frame requests were\n- committed.\n+ * **physical_height** (*ArgumentType.Int*) -- height in\n+ millimeters of the output\n \n- The server must send the notifications so that a client will not\n- send excessive updates, while still allowing the highest\n- possible update rate for clients that wait for the reply before\n- drawing again. The server should give some time for the client\n- to draw and commit after sending the frame callback events to\n- let it hit the next output refresh.\n+ * **subpixel** (*ArgumentType.Int*) -- subpixel orientation\n+ of the output\n \n- A server should avoid signaling the frame callbacks if the\n- surface is not visible in any way, e.g. the surface is off-\n- screen, or completely obscured by other opaque surfaces.\n+ * **make** (*ArgumentType.String*) -- textual description of\n+ the manufacturer\n \n- The object returned by this request will be destroyed by the\n- compositor after the callback is fired and as such the client\n- must not attempt to use it after that point.\n+ * **model** (*ArgumentType.String*) -- textual description of\n+ the model\n \n- The callback_data passed in the callback is the current time, in\n- milliseconds, with an undefined base.\n+ * **transform** (*ArgumentType.Int*) -- additional\n+ transformation applied to buffer contents during\n+ presentation\n \n- Returns:\n- \"WlCallback\" -- callback object for the frame request\n+ mode(flags: 'int', width: 'int', height: 'int', refresh: 'int') -> 'None'\n \n- set_opaque_region(region: 'WlRegion | None') -> 'None'\n+ -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n \n- -[ Request -- opcode 4 (attached to \"Resource\" instance) ]-\n+ Advertise available modes for the output\n \n- Set opaque region\n+ The mode event describes an available mode for the output.\n \n- This request sets the region of the surface that contains opaque\n- content.\n+ The event is sent when binding to the output object and there\n+ will always be one mode, the current mode. The event is sent\n+ again if an output changes mode, for the mode that is now\n+ current. In other words, the current mode is always the last\n+ mode that was received with the current flag set.\n \n- The opaque region is an optimization hint for the compositor\n- that lets it optimize the redrawing of content behind opaque\n- regions. Setting an opaque region is not required for correct\n- behaviour, but marking transparent content as opaque will result\n- in repaint artifacts.\n+ Non-current modes are deprecated. A compositor can decide to\n+ only advertise the current mode and never send other modes.\n+ Clients should not rely on non-current modes.\n \n- The opaque region is specified in surface-local coordinates.\n+ The size of a mode is given in physical hardware units of the\n+ output device. This is not necessarily the same as the output\n+ size in the global compositor space. For instance, the output\n+ may be scaled, as described in \"WlOutput.scale()\", or\n+ transformed, as described in \"WlOutput.transform()\". Clients\n+ willing to retrieve the output size in the global compositor\n+ space should use xdg_output.logical_size instead.\n \n- The compositor ignores the parts of the opaque region that fall\n- outside of the surface.\n+ The vertical refresh rate can be set to zero if it doesn't make\n+ sense for this output (e.g. for virtual outputs).\n \n- Opaque region is double-buffered state, see\n- \"WlSurface.commit()\".\n+ The mode event will be followed by a done event (starting from\n+ version 2).\n \n- \"WlSurface.set_opaque_region()\" changes the pending opaque\n- region. \"WlSurface.commit()\" copies the pending region to the\n- current region. Otherwise, the pending and current regions are\n- never changed.\n+ Clients should not use the refresh rate to schedule frames.\n+ Instead, they should use the \"WlSurface.frame()\" event or the\n+ presentation-time protocol.\n \n- The initial value for an opaque region is empty. Setting the\n- pending opaque region has copy semantics, and the \"WlRegion\"\n- object can be destroyed immediately. A NULL \"WlRegion\" causes\n- the pending opaque region to be set to empty.\n+ Note: this information is not always meaningful for all outputs.\n+ Some compositors, such as those exposing virtual outputs, might\n+ fake the refresh rate or the size.\n \n Parameters:\n- **region** (\"WlRegion\" or *None*) -- opaque region of the\n- surface\n-\n- set_input_region(region: 'WlRegion | None') -> 'None'\n-\n- -[ Request -- opcode 5 (attached to \"Resource\" instance) ]-\n-\n- Set input region\n+ * **flags** (*ArgumentType.Uint*) -- bitfield of mode flags\n \n- This request sets the region of the surface that can receive\n- pointer and touch events.\n+ * **width** (*ArgumentType.Int*) -- width of the mode in\n+ hardware units\n \n- Input events happening outside of this region will try the next\n- surface in the server surface stack. The compositor ignores the\n- parts of the input region that fall outside of the surface.\n+ * **height** (*ArgumentType.Int*) -- height of the mode in\n+ hardware units\n \n- The input region is specified in surface-local coordinates.\n+ * **refresh** (*ArgumentType.Int*) -- vertical refresh rate\n+ in mHz\n \n- Input region is double-buffered state, see \"WlSurface.commit()\".\n+ done() -> 'None'\n \n- \"WlSurface.set_input_region()\" changes the pending input region.\n- \"WlSurface.commit()\" copies the pending region to the current\n- region. Otherwise the pending and current regions are never\n- changed, except cursor and icon surfaces are special cases, see\n- \"WlPointer.set_cursor()\" and \"WlDataDevice.start_drag()\".\n+ -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n \n- The initial value for an input region is infinite. That means\n- the whole surface will accept input. Setting the pending input\n- region has copy semantics, and the \"WlRegion\" object can be\n- destroyed immediately. A NULL \"WlRegion\" causes the input region\n- to be set to infinite.\n+ Sent all information about output\n \n- Parameters:\n- **region** (\"WlRegion\" or *None*) -- input region of the\n- surface\n+ This event is sent after all other properties have been sent\n+ after binding to the output object and after any other property\n+ changes done after that. This allows changes to the output\n+ properties to be seen as atomic, even if they happen via\n+ multiple events.\n \n- commit() -> 'None'\n+ scale(factor: 'int') -> 'None'\n \n- -[ Request -- opcode 6 (attached to \"Resource\" instance) ]-\n+ -[ Event -- opcode 3 (attached to \"Proxy\" instance) ]-\n \n- Commit pending surface state\n+ Output scaling properties\n \n- Surface state (input, opaque, and damage regions, attached\n- buffers, etc.) is double-buffered. Protocol requests modify the\n- pending state, as opposed to the active state in use by the\n- compositor.\n+ This event contains scaling geometry information that is not in\n+ the geometry event. It may be sent after binding the output\n+ object or if the output scale changes later. The compositor will\n+ emit a non-zero, positive value for scale. If it is not sent,\n+ the client should assume a scale of 1.\n \n- A commit request atomically creates a content update from the\n- pending state, even if the pending state has not been touched.\n- The content update is placed in a queue until it becomes active.\n- After commit, the new pending state is as documented for each\n- related request.\n+ A scale larger than 1 means that the compositor will\n+ automatically scale surface buffers by this amount when\n+ rendering. This is used for very high resolution displays where\n+ applications rendering at the native resolution would be too\n+ small to be legible.\n \n- When the content update is applied, the \"WlBuffer\" is applied\n- before all other state. This means that all coordinates in\n- double-buffered state are relative to the newly attached\n- wl_buffers, except for \"WlSurface.attach()\" itself. If there is\n- no newly attached \"WlBuffer\", the coordinates are relative to\n- the previous content update.\n+ Clients should use \"WlSurface.preferred_buffer_scale()\" instead\n+ of this event to find the preferred buffer scale to use for a\n+ surface.\n \n- All requests that need a commit to become effective are\n- documented to affect double-buffered state.\n+ The scale event will be followed by a done event.\n \n- Other interfaces may add further double-buffered surface state.\n+ Parameters:\n+ **factor** (*ArgumentType.Int*) -- scaling factor of output\n \n- set_buffer_transform(transform: 'int') -> 'None'\n+ name(name: 'str') -> 'None'\n \n- -[ Request -- opcode 7 (attached to \"Resource\" instance) ]-\n+ -[ Event -- opcode 4 (attached to \"Proxy\" instance) ]-\n \n- Sets the buffer transformation\n+ Name of this output\n \n- This request sets the transformation that the client has already\n- applied to the content of the buffer. The accepted values for\n- the transform parameter are the values for\n- \"WlOutput.transform()\".\n+ Many compositors will assign user-friendly names to their\n+ outputs, show them to the user, allow the user to refer to an\n+ output, etc. The client may wish to know this name as well to\n+ offer the user similar behaviors.\n \n- The compositor applies the inverse of this transformation\n- whenever it uses the buffer contents.\n+ The name is a UTF-8 string with no convention defined for its\n+ contents. Each name is unique among all \"WlOutput\" globals. The\n+ name is only guaranteed to be unique for the compositor\n+ instance.\n \n- Buffer transform is double-buffered state, see\n- \"WlSurface.commit()\".\n+ The same output name is used for all clients for a given\n+ \"WlOutput\" global. Thus, the name can be shared across processes\n+ to refer to a specific \"WlOutput\" global.\n \n- A newly created surface has its buffer transformation set to\n- normal.\n+ The name is not guaranteed to be persistent across sessions,\n+ thus cannot be used to reliably identify an output in e.g.\n+ configuration files.\n \n- \"WlSurface.set_buffer_transform()\" changes the pending buffer\n- transformation. \"WlSurface.commit()\" copies the pending buffer\n- transformation to the current one. Otherwise, the pending and\n- current values are never changed.\n+ Examples of names include 'HDMI-A-1', 'WL-1', 'X11-1', etc.\n+ However, do not assume that the name is a reflection of an\n+ underlying DRM connector, X11 connection, etc.\n \n- The purpose of this request is to allow clients to render\n- content according to the output transform, thus permitting the\n- compositor to use certain optimizations even if the display is\n- rotated. Using hardware overlays and scanning out a client\n- buffer for fullscreen surfaces are examples of such\n- optimizations. Those optimizations are highly dependent on the\n- compositor implementation, so the use of this request should be\n- considered on a case-by-case basis.\n+ The name event is sent after binding the output object. This\n+ event is only sent once per output object, and the name does not\n+ change over the lifetime of the \"WlOutput\" global.\n \n- Note that if the transform value includes 90 or 270 degree\n- rotation, the width of the buffer will become the surface height\n- and the height of the buffer will become the surface width.\n+ Compositors may re-use the same output name if the \"WlOutput\"\n+ global is destroyed and re-created later. Compositors should\n+ avoid re- using the same name if possible.\n \n- If transform is not one of the values from the\n- \"WlOutput.transform()\" enum the invalid_transform protocol error\n- is raised.\n+ The name event will be followed by a done event.\n \n Parameters:\n- **transform** (*ArgumentType.Int*) -- transform for\n- interpreting buffer contents\n-\n- set_buffer_scale(scale: 'int') -> 'None'\n-\n- -[ Request -- opcode 8 (attached to \"Resource\" instance) ]-\n-\n- Sets the buffer scaling factor\n+ **name** (*ArgumentType.String*) -- output name\n \n- This request sets an optional scaling factor on how the\n- compositor interprets the contents of the buffer attached to the\n- window.\n+ description(description: 'str') -> 'None'\n \n- Buffer scale is double-buffered state, see \"WlSurface.commit()\".\n+ -[ Event -- opcode 5 (attached to \"Proxy\" instance) ]-\n \n- A newly created surface has its buffer scale set to 1.\n+ Human-readable description of this output\n \n- \"WlSurface.set_buffer_scale()\" changes the pending buffer scale.\n- \"WlSurface.commit()\" copies the pending buffer scale to the\n- current one. Otherwise, the pending and current values are never\n- changed.\n+ Many compositors can produce human-readable descriptions of\n+ their outputs. The client may wish to know this description as\n+ well, e.g. for output selection purposes.\n \n- The purpose of this request is to allow clients to supply higher\n- resolution buffer data for use on high resolution outputs. It is\n- intended that you pick the same buffer scale as the scale of the\n- output that the surface is displayed on. This means the\n- compositor can avoid scaling when rendering the surface on that\n- output.\n+ The description is a UTF-8 string with no convention defined for\n+ its contents. The description is not guaranteed to be unique\n+ among all \"WlOutput\" globals. Examples might include 'Foocorp\n+ 11\" Display' or 'Virtual X11 output via :1'.\n \n- Note that if the scale is larger than 1, then you have to attach\n- a buffer that is larger (by a factor of scale in each dimension)\n- than the desired surface size.\n+ The description event is sent after binding the output object\n+ and whenever the description changes. The description is\n+ optional, and may not be sent at all.\n \n- If scale is not greater than 0 the invalid_scale protocol error\n- is raised.\n+ The description event will be followed by a done event.\n \n Parameters:\n- **scale** (*ArgumentType.Int*) -- scale for interpreting\n- buffer contents\n-\n- damage_buffer(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None'\n-\n- -[ Request -- opcode 9 (attached to \"Resource\" instance) ]-\n-\n- Mark part of the surface damaged using buffer coordinates\n-\n- This request is used to describe the regions where the pending\n- buffer is different from the current surface contents, and where\n- the surface therefore needs to be repainted. The compositor\n- ignores the parts of the damage that fall outside of the\n- surface.\n-\n- Damage is double-buffered state, see \"WlSurface.commit()\".\n-\n- The damage rectangle is specified in buffer coordinates, where x\n- and y specify the upper left corner of the damage rectangle.\n-\n- The initial value for pending damage is empty: no damage.\n- \"WlSurface.damage_buffer()\" adds pending damage: the new pending\n- damage is the union of old pending damage and the given\n- rectangle.\n-\n- \"WlSurface.commit()\" assigns pending damage as the current\n- damage, and clears pending damage. The server will clear the\n- current damage as it repaints the surface.\n-\n- This request differs from \"WlSurface.damage()\" in only one way -\n- it takes damage in buffer coordinates instead of surface-local\n- coordinates. While this generally is more intuitive than surface\n- coordinates, it is especially desirable when using wp_viewport\n- or when a drawing library (like EGL) is unaware of buffer scale\n- and buffer transform.\n+ **description** (*ArgumentType.String*) -- output description\n \n- Note: Because buffer transformation changes and damage requests\n- may be interleaved in the protocol stream, it is impossible to\n- determine the actual mapping between surface and buffer damage\n- until \"WlSurface.commit()\" time. Therefore, compositors wishing\n- to take both kinds of damage into account will have to\n- accumulate damage from the two requests separately and only\n- transform from one to the other after receiving the\n- \"WlSurface.commit()\".\n \n- Parameters:\n- * **x** (*ArgumentType.Int*) -- buffer-local x coordinate\n+WlRegistry\n+==========\n \n- * **y** (*ArgumentType.Int*) -- buffer-local y coordinate\n+class pywayland.protocol.wayland.WlRegistry\n \n- * **width** (*ArgumentType.Int*) -- width of damage rectangle\n+ Global registry object\n \n- * **height** (*ArgumentType.Int*) -- height of damage\n- rectangle\n+ The singleton global registry object. The server has a number of\n+ global objects that are available to all clients. These objects\n+ typically represent an actual object in the server (for example, an\n+ input device) or they are singleton objects that provide extension\n+ functionality.\n \n- offset(x: 'int', y: 'int') -> 'None'\n+ When a client creates a registry object, the registry object will\n+ emit a global event for each global currently in the registry.\n+ Globals come and go as a result of device or monitor hotplugs,\n+ reconfiguration or other events, and the registry will send out\n+ global and global_remove events to keep the client up to date with\n+ the changes. To mark the end of the initial burst of events, the\n+ client can use the \"WlDisplay.sync()\" request immediately after\n+ calling \"WlDisplay.get_registry()\".\n \n- -[ Request -- opcode 10 (attached to \"Resource\" instance) ]-\n+ A client can bind to a global object by using the bind request.\n+ This creates a client-side handle that lets the object emit events\n+ to the client and lets the client invoke requests on the object.\n \n- Set the surface contents offset\n+ bind(name: 'int', interface: 'type[T]', version: 'int') -> 'Proxy[T]'\n \n- The x and y arguments specify the location of the new pending\n- buffer's upper left corner, relative to the current buffer's\n- upper left corner, in surface-local coordinates. In other words,\n- the x and y, combined with the new surface size define in which\n- directions the surface's size changes.\n+ -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Surface location offset is double-buffered state, see\n- \"WlSurface.commit()\".\n+ Bind an object to the display\n \n- This request is semantically equivalent to and the replaces the\n- x and y arguments in the \"WlSurface.attach()\" request in\n- \"WlSurface\" versions prior to 5. See \"WlSurface.attach()\" for\n- details.\n+ Binds a new, client-created object to the server using the\n+ specified name as the identifier.\n \n Parameters:\n- * **x** (*ArgumentType.Int*) -- surface-local x coordinate\n-\n- * **y** (*ArgumentType.Int*) -- surface-local y coordinate\n-\n- enter(output: 'WlOutput') -> 'None'\n-\n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n-\n- Surface enters an output\n+ * **name** (*ArgumentType.Uint*) -- unique numeric name of\n+ the object\n \n- This is emitted whenever a surface's creation, movement, or\n- resizing results in some part of it being within the scanout\n- region of an output.\n+ * **interface** (*string*) -- Interface name\n \n- Note that a surface may be overlapping with zero or more\n- outputs.\n+ * **version** (*int*) -- Interface version\n \n- Parameters:\n- **output** (\"WlOutput\") -- output entered by the surface\n+ Returns:\n+ \"pywayland.client.proxy.Proxy\" of specified Interface --\n+ bounded object\n \n- leave(output: 'WlOutput') -> 'None'\n+ global_(name: 'int', interface: 'str', version: 'int') -> 'None'\n \n- -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n \n- Surface leaves an output\n+ Announce global object\n \n- This is emitted whenever a surface's creation, movement, or\n- resizing results in it no longer having any part of it within\n- the scanout region of an output.\n+ Notify the client of global objects.\n \n- Clients should not use the number of outputs the surface is on\n- for frame throttling purposes. The surface might be hidden even\n- if no leave event has been sent, and the compositor might expect\n- new surface content updates even if no enter event has been\n- sent. The frame event should be used instead.\n+ The event notifies the client that a global object with the\n+ given name is now available, and it implements the given version\n+ of the given interface.\n \n Parameters:\n- **output** (\"WlOutput\") -- output left by the surface\n-\n- preferred_buffer_scale(factor: 'int') -> 'None'\n-\n- -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n-\n- Preferred buffer scale for the surface\n-\n- This event indicates the preferred buffer scale for this\n- surface. It is sent whenever the compositor's preference\n- changes.\n-\n- Before receiving this event the preferred buffer scale for this\n- surface is 1.\n-\n- It is intended that scaling aware clients use this event to\n- scale their content and use \"WlSurface.set_buffer_scale()\" to\n- indicate the scale they have rendered with. This allows clients\n- to supply a higher detail buffer.\n+ * **name** (*ArgumentType.Uint*) -- numeric name of the\n+ global object\n \n- The compositor shall emit a scale value greater than 0.\n+ * **interface** (*ArgumentType.String*) -- interface\n+ implemented by the object\n \n- Parameters:\n- **factor** (*ArgumentType.Int*) -- preferred scaling factor\n+ * **version** (*ArgumentType.Uint*) -- interface version\n \n- preferred_buffer_transform(transform: 'int') -> 'None'\n+ global_remove(name: 'int') -> 'None'\n \n- -[ Event -- opcode 3 (attached to \"Proxy\" instance) ]-\n+ -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n \n- Preferred buffer transform for the surface\n+ Announce removal of global object\n \n- This event indicates the preferred buffer transform for this\n- surface. It is sent whenever the compositor's preference\n- changes.\n+ Notify the client of removed global objects.\n \n- Before receiving this event the preferred buffer transform for\n- this surface is normal.\n+ This event notifies the client that the global identified by\n+ name is no longer available. If the client bound to the global\n+ using the bind request, the client should now destroy that\n+ object.\n \n- Applying this transformation to the surface buffer contents and\n- using \"WlSurface.set_buffer_transform()\" might allow the\n- compositor to use the surface buffer more efficiently.\n+ The object remains valid and requests to the object will be\n+ ignored until the client destroys it, to avoid races between the\n+ global going away and a client sending a request to it.\n \n Parameters:\n- **transform** (*ArgumentType.Uint*) -- preferred transform\n+ **name** (*ArgumentType.Uint*) -- numeric name of the global\n+ object\n \n \n-WlTouch\n-=======\n-\n-class pywayland.protocol.wayland.WlTouch\n+WlDataSource\n+============\n \n- Touchscreen input device\n+class pywayland.protocol.wayland.WlDataSource\n \n- The \"WlTouch\" interface represents a touchscreen associated with a\n- seat.\n+ Offer to transfer data\n \n- Touch interactions can consist of one or more contacts. For each\n- contact, a series of events is generated, starting with a down\n- event, followed by zero or more motion events, and ending with an\n- up event. Events relating to the same contact point can be\n- identified by the ID of the sequence.\n+ The \"WlDataSource\" object is the source side of a \"WlDataOffer\". It\n+ is created by the source client in a data transfer and provides a\n+ way to describe the offered data and a way to respond to requests\n+ to transfer the data.\n \n- release() -> 'None'\n+ offer(mime_type: 'str') -> 'None'\n \n -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Release the touch object\n-\n- down(serial: 'int', time: 'int', surface: 'WlSurface', id: 'int', x: 'float', y: 'float') -> 'None'\n-\n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n-\n- Touch down event and beginning of a touch sequence\n+ Add an offered mime type\n \n- A new touch point has appeared on the surface. This touch point\n- is assigned a unique ID. Future events from this touch point\n- reference this ID. The ID ceases to be valid after a touch up\n- event and may be reused in the future.\n+ This request adds a mime type to the set of mime types\n+ advertised to targets. Can be called several times to offer\n+ multiple types.\n \n Parameters:\n- * **serial** (*ArgumentType.Uint*) -- serial number of the\n- touch down event\n-\n- * **time** (*ArgumentType.Uint*) -- timestamp with\n- millisecond granularity\n-\n- * **surface** (\"WlSurface\") -- surface touched\n-\n- * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n- point\n-\n- * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate\n-\n- * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate\n-\n- up(serial: 'int', time: 'int', id: 'int') -> 'None'\n+ **mime_type** (*ArgumentType.String*) -- mime type offered by\n+ the data source\n \n- -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n+ destroy() -> 'None'\n \n- End of a touch event sequence\n+ -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n \n- The touch point has disappeared. No further events will be sent\n- for this touch point and the touch point's ID is released and\n- may be reused in a future touch down event.\n+ Destroy the data source\n \n- Parameters:\n- * **serial** (*ArgumentType.Uint*) -- serial number of the\n- touch up event\n+ Destroy the data source.\n \n- * **time** (*ArgumentType.Uint*) -- timestamp with\n- millisecond granularity\n+ set_actions(dnd_actions: 'int') -> 'None'\n \n- * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n- point\n+ -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n \n- motion(time: 'int', id: 'int', x: 'float', y: 'float') -> 'None'\n+ Set the available drag-and-drop actions\n \n- -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n+ Sets the actions that the source side client supports for this\n+ operation. This request may trigger \"WlDataSource.action()\" and\n+ \"WlDataOffer.action()\" events if the compositor needs to change\n+ the selected action.\n \n- Update of touch point coordinates\n+ The dnd_actions argument must contain only values expressed in\n+ the \"WlDataDeviceManager.dnd_actions()\" enum, otherwise it will\n+ result in a protocol error.\n \n- A touch point has changed coordinates.\n+ This request must be made once only, and can only be made on\n+ sources used in drag-and-drop, so it must be performed before\n+ \"WlDataDevice.start_drag()\". Attempting to use the source other\n+ than for drag-and-drop will raise a protocol error.\n \n Parameters:\n- * **time** (*ArgumentType.Uint*) -- timestamp with\n- millisecond granularity\n-\n- * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n- point\n-\n- * **x** (*ArgumentType.Fixed*) -- surface-local x coordinate\n-\n- * **y** (*ArgumentType.Fixed*) -- surface-local y coordinate\n-\n- frame() -> 'None'\n-\n- -[ Event -- opcode 3 (attached to \"Proxy\" instance) ]-\n-\n- End of touch frame event\n-\n- Indicates the end of a set of events that logically belong\n- together. A client is expected to accumulate the data in all\n- events within the frame before proceeding.\n-\n- A \"WlTouch.frame()\" terminates at least one event but otherwise\n- no guarantee is provided about the set of events within a frame.\n- A client must assume that any state not updated in a frame is\n- unchanged from the previously known state.\n-\n- cancel() -> 'None'\n-\n- -[ Event -- opcode 4 (attached to \"Proxy\" instance) ]-\n-\n- Touch session cancelled\n-\n- Sent if the compositor decides the touch stream is a global\n- gesture. No further events are sent to the clients from that\n- particular gesture. Touch cancellation applies to all touch\n- points currently active on this client's surface. The client is\n- responsible for finalizing the touch points, future touch points\n- on this surface may reuse the touch point ID.\n-\n- No frame event is required after the cancel event.\n-\n- shape(id: 'int', major: 'float', minor: 'float') -> 'None'\n-\n- -[ Event -- opcode 5 (attached to \"Proxy\" instance) ]-\n-\n- Update shape of touch point\n+ **dnd_actions** (*ArgumentType.Uint*) -- actions supported by\n+ the data source\n \n- Sent when a touchpoint has changed its shape.\n+ target(mime_type: 'str | None') -> 'None'\n \n- This event does not occur on its own. It is sent before a\n- \"WlTouch.frame()\" event and carries the new shape information\n- for any previously reported, or new touch points of that frame.\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n \n- Other events describing the touch point such as\n- \"WlTouch.down()\", \"WlTouch.motion()\" or \"WlTouch.orientation()\"\n- may be sent within the same \"WlTouch.frame()\". A client should\n- treat these events as a single logical touch point update. The\n- order of \"WlTouch.shape()\", \"WlTouch.orientation()\" and\n- \"WlTouch.motion()\" is not guaranteed. A \"WlTouch.down()\" event\n- is guaranteed to occur before the first \"WlTouch.shape()\" event\n- for this touch ID but both events may occur within the same\n- \"WlTouch.frame()\".\n+ A target accepts an offered mime type\n \n- A touchpoint shape is approximated by an ellipse through the\n- major and minor axis length. The major axis length describes the\n- longer diameter of the ellipse, while the minor axis length\n- describes the shorter diameter. Major and minor are orthogonal\n- and both are specified in surface-local coordinates. The center\n- of the ellipse is always at the touchpoint location as reported\n- by \"WlTouch.down()\" or \"WlTouch.move()\".\n+ Sent when a target accepts pointer_focus or motion events. If a\n+ target does not accept any of the offered types, type is NULL.\n \n- This event is only sent by the compositor if the touch device\n- supports shape reports. The client has to make reasonable\n- assumptions about the shape if it did not receive this event.\n+ Used for feedback during drag-and-drop.\n \n Parameters:\n- * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n- point\n-\n- * **major** (*ArgumentType.Fixed*) -- length of the major\n- axis in surface-local coordinates\n-\n- * **minor** (*ArgumentType.Fixed*) -- length of the minor\n- axis in surface-local coordinates\n-\n- orientation(id: 'int', orientation: 'float') -> 'None'\n-\n- -[ Event -- opcode 6 (attached to \"Proxy\" instance) ]-\n-\n- Update orientation of touch point\n-\n- Sent when a touchpoint has changed its orientation.\n+ **mime_type** (*ArgumentType.String* or *None*) -- mime type\n+ accepted by the target\n \n- This event does not occur on its own. It is sent before a\n- \"WlTouch.frame()\" event and carries the new shape information\n- for any previously reported, or new touch points of that frame.\n+ send(mime_type: 'str', fd: 'int') -> 'None'\n \n- Other events describing the touch point such as\n- \"WlTouch.down()\", \"WlTouch.motion()\" or \"WlTouch.shape()\" may be\n- sent within the same \"WlTouch.frame()\". A client should treat\n- these events as a single logical touch point update. The order\n- of \"WlTouch.shape()\", \"WlTouch.orientation()\" and\n- \"WlTouch.motion()\" is not guaranteed. A \"WlTouch.down()\" event\n- is guaranteed to occur before the first \"WlTouch.orientation()\"\n- event for this touch ID but both events may occur within the\n- same \"WlTouch.frame()\".\n+ -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n \n- The orientation describes the clockwise angle of a touchpoint's\n- major axis to the positive surface y-axis and is normalized to\n- the -180 to +180 degree range. The granularity of orientation\n- depends on the touch device, some devices only support binary\n- rotation values between 0 and 90 degrees.\n+ Send the data\n \n- This event is only sent by the compositor if the touch device\n- supports orientation reports.\n+ Request for data from the client. Send the data as the\n+ specified mime type over the passed file descriptor, then close\n+ it.\n \n Parameters:\n- * **id** (*ArgumentType.Int*) -- the unique ID of this touch\n- point\n-\n- * **orientation** (*ArgumentType.Fixed*) -- angle between\n- major axis and positive surface y-axis in degrees\n-\n-\n-WlRegion\n-========\n-\n-class pywayland.protocol.wayland.WlRegion\n-\n- Region interface\n-\n- A region object describes an area.\n-\n- Region objects are used to describe the opaque and input regions of\n- a surface.\n-\n- destroy() -> 'None'\n-\n- -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n-\n- Destroy region\n-\n- Destroy the region. This will invalidate the object ID.\n-\n- add(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None'\n-\n- -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n-\n- Add rectangle to region\n-\n- Add the specified rectangle to the region.\n+ * **mime_type** (*ArgumentType.String*) -- mime type for the\n+ data\n \n- Parameters:\n- * **x** (*ArgumentType.Int*) -- region-local x coordinate\n+ * **fd** (*ArgumentType.FileDescriptor*) -- file descriptor\n+ for the data\n \n- * **y** (*ArgumentType.Int*) -- region-local y coordinate\n+ cancelled() -> 'None'\n \n- * **width** (*ArgumentType.Int*) -- rectangle width\n+ -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n \n- * **height** (*ArgumentType.Int*) -- rectangle height\n+ Selection was cancelled\n \n- subtract(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None'\n+ This data source is no longer valid. There are several reasons\n+ why this could happen:\n \n- -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n+ * The data source has been replaced by another data source.\n \n- Subtract rectangle from region\n+ * The drag-and-drop operation was performed, but the drop\n+ destination did not accept any of the mime types offered\n+ through \"WlDataSource.target()\".\n \n- Subtract the specified rectangle from the region.\n+ * The drag-and-drop operation was performed, but the drop\n+ destination did not select any of the actions present in the\n+ mask offered through \"WlDataSource.action()\".\n \n- Parameters:\n- * **x** (*ArgumentType.Int*) -- region-local x coordinate\n+ * The drag-and-drop operation was performed but didn't happen\n+ over a surface.\n \n- * **y** (*ArgumentType.Int*) -- region-local y coordinate\n+ * The compositor cancelled the drag-and-drop operation (e.g.\n+ compositor dependent timeouts to avoid stale drag-and-drop\n+ transfers).\n \n- * **width** (*ArgumentType.Int*) -- rectangle width\n+ The client should clean up and destroy this data source.\n \n- * **height** (*ArgumentType.Int*) -- rectangle height\n+ For objects of version 2 or older, \"WlDataSource.cancelled()\"\n+ will only be emitted if the data source was replaced by another\n+ data source.\n \n+ dnd_drop_performed() -> 'None'\n \n-WlSubcompositor\n-===============\n+ -[ Event -- opcode 3 (attached to \"Proxy\" instance) ]-\n \n-class pywayland.protocol.wayland.WlSubcompositor\n+ The drag-and-drop operation physically finished\n \n- Sub-surface compositing\n+ The user performed the drop action. This event does not indicate\n+ acceptance, \"WlDataSource.cancelled()\" may still be emitted\n+ afterwards if the drop destination does not accept any mime\n+ type.\n \n- The global interface exposing sub-surface compositing capabilities.\n- A \"WlSurface\", that has sub-surfaces associated, is called the\n- parent surface. Sub-surfaces can be arbitrarily nested and create a\n- tree of sub-surfaces.\n+ However, this event might however not be received if the\n+ compositor cancelled the drag-and-drop operation before this\n+ event could happen.\n \n- The root surface in a tree of sub-surfaces is the main surface. The\n- main surface cannot be a sub-surface, because sub-surfaces must\n- always have a parent.\n+ Note that the data_source may still be used in the future and\n+ should not be destroyed here.\n \n- A main surface with its sub-surfaces forms a (compound) window. For\n- window management purposes, this set of \"WlSurface\" objects is to\n- be considered as a single window, and it should also behave as\n- such.\n+ dnd_finished() -> 'None'\n \n- The aim of sub-surfaces is to offload some of the compositing work\n- within a window from clients to the compositor. A prime example is\n- a video player with decorations and video in separate \"WlSurface\"\n- objects. This should allow the compositor to pass YUV video buffer\n- processing to dedicated overlay hardware when possible.\n+ -[ Event -- opcode 4 (attached to \"Proxy\" instance) ]-\n \n- destroy() -> 'None'\n+ The drag-and-drop operation concluded\n \n- -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n+ The drop destination finished interoperating with this data\n+ source, so the client is now free to destroy this data source\n+ and free all associated data.\n \n- Unbind from the subcompositor interface\n+ If the action used to perform the operation was \"move\", the\n+ source can now delete the transferred data.\n \n- Informs the server that the client will not be using this\n- protocol object anymore. This does not affect any other objects,\n- \"WlSubsurface\" objects included.\n+ action(dnd_action: 'int') -> 'None'\n \n- get_subsurface(surface: 'WlSurface', parent: 'WlSurface') -> 'Proxy[WlSubsurface]'\n+ -[ Event -- opcode 5 (attached to \"Proxy\" instance) ]-\n \n- -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n+ Notify the selected action\n \n- Give a surface the role sub-surface\n+ This event indicates the action selected by the compositor after\n+ matching the source/destination side actions. Only one action\n+ (or none) will be offered here.\n \n- Create a sub-surface interface for the given surface, and\n- associate it with the given parent surface. This turns a plain\n- \"WlSurface\" into a sub-surface.\n+ This event can be emitted multiple times during the drag-and-\n+ drop operation, mainly in response to destination side changes\n+ through \"WlDataOffer.set_actions()\", and as the data device\n+ enters/leaves surfaces.\n \n- The to-be sub-surface must not already have another role, and it\n- must not have an existing \"WlSubsurface\" object. Otherwise the\n- bad_surface protocol error is raised.\n+ It is only possible to receive this event after\n+ \"WlDataSource.dnd_drop_performed()\" if the drag-and-drop\n+ operation ended in an \"ask\" action, in which case the final\n+ \"WlDataSource.action()\" event will happen immediately before\n+ \"WlDataSource.dnd_finished()\".\n \n- Adding sub-surfaces to a parent is a double-buffered operation\n- on the parent (see \"WlSurface.commit()\"). The effect of adding a\n- sub-surface becomes visible on the next time the state of the\n- parent surface is applied.\n+ Compositors may also change the selected action on the fly,\n+ mainly in response to keyboard modifier changes during the drag-\n+ and-drop operation.\n \n- The parent surface must not be one of the child surface's\n- descendants, and the parent must be different from the child\n- surface, otherwise the bad_parent protocol error is raised.\n+ The most recent action received is always the valid one. The\n+ chosen action may change alongside negotiation (e.g. an \"ask\"\n+ action can turn into a \"move\" operation), so the effects of the\n+ final action must always be applied in\n+ \"WlDataOffer.dnd_finished()\".\n \n- This request modifies the behaviour of \"WlSurface.commit()\"\n- request on the sub- surface, see the documentation on\n- \"WlSubsurface\" interface.\n+ Clients can trigger cursor surface changes from this point, so\n+ they reflect the current action.\n \n Parameters:\n- * **surface** (\"WlSurface\") -- the surface to be turned into\n- a sub-surface\n-\n- * **parent** (\"WlSurface\") -- the parent surface\n-\n- Returns:\n- \"WlSubsurface\" -- the new sub- surface object ID\n+ **dnd_action** (*ArgumentType.Uint*) -- action selected by\n+ the compositor\n \n \n WlPointer\n =========\n \n class pywayland.protocol.wayland.WlPointer\n \n@@ -2230,495 +2132,923 @@\n Parameters:\n * **axis** (*ArgumentType.Uint*) -- axis type\n \n * **direction** (*ArgumentType.Uint*) -- physical direction\n relative to axis motion\n \n \n-WlDataOffer\n-===========\n+WlDataDeviceManager\n+===================\n \n-class pywayland.protocol.wayland.WlDataOffer\n+class pywayland.protocol.wayland.WlDataDeviceManager\n \n- Offer to transfer data\n+ Data transfer interface\n \n- A \"WlDataOffer\" represents a piece of data offered for transfer by\n- another client (the source client). It is used by the copy-and-\n- paste and drag-and-drop mechanisms. The offer describes the\n- different mime types that the data can be converted to and provides\n- the mechanism for transferring the data directly from the source\n- client.\n+ The \"WlDataDeviceManager\" is a singleton global object that\n+ provides access to inter-client data transfer mechanisms such as\n+ copy-and-paste and drag-and-drop. These mechanisms are tied to a\n+ \"WlSeat\" and this interface lets a client get a \"WlDataDevice\"\n+ corresponding to a \"WlSeat\".\n \n- accept(serial: 'int', mime_type: 'str | None') -> 'None'\n+ Depending on the version bound, the objects created from the bound\n+ \"WlDataDeviceManager\" object will have different requirements for\n+ functioning properly. See \"WlDataSource.set_actions()\",\n+ \"WlDataOffer.accept()\" and \"WlDataOffer.finish()\" for details.\n+\n+ create_data_source() -> 'Proxy[WlDataSource]'\n \n -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Accept one of the offered mime types\n+ Create a new data source\n \n- Indicate that the client can accept the given mime type, or NULL\n- for not accepted.\n+ Create a new data source.\n \n- For objects of version 2 or older, this request is used by the\n- client to give feedback whether the client can receive the given\n- mime type, or NULL if none is accepted; the feedback does not\n- determine whether the drag-and-drop operation succeeds or not.\n+ Returns:\n+ \"WlDataSource\" -- data source to create\n \n- For objects of version 3 or newer, this request determines the\n- final result of the drag-and-drop operation. If the end result\n- is that no mime types were accepted, the drag-and-drop operation\n- will be cancelled and the corresponding drag source will receive\n- \"WlDataSource.cancelled()\". Clients may still use this event in\n- conjunction with \"WlDataSource.action()\" for feedback.\n+ get_data_device(seat: 'WlSeat') -> 'Proxy[WlDataDevice]'\n+\n+ -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n+\n+ Create a new data device\n+\n+ Create a new data device for a given seat.\n \n Parameters:\n- * **serial** (*ArgumentType.Uint*) -- serial number of the\n- accept request\n+ **seat** (\"WlSeat\") -- seat associated with the data device\n \n- * **mime_type** (*ArgumentType.String* or *None*) -- mime\n- type accepted by the client\n+ Returns:\n+ \"WlDataDevice\" -- data device to create\n \n- receive(mime_type: 'str', fd: 'int') -> 'None'\n+\n+WlShm\n+=====\n+\n+class pywayland.protocol.wayland.WlShm\n+\n+ Shared memory support\n+\n+ A singleton global object that provides support for shared memory.\n+\n+ Clients can create \"WlShmPool\" objects using the create_pool\n+ request.\n+\n+ On binding the \"WlShm\" object one or more format events are emitted\n+ to inform clients about the valid pixel formats that can be used\n+ for buffers.\n+\n+ create_pool(fd: 'int', size: 'int') -> 'Proxy[WlShmPool]'\n+\n+ -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n+\n+ Create a shm pool\n+\n+ Create a new \"WlShmPool\" object.\n+\n+ The pool can be used to create shared memory based buffer\n+ objects. The server will mmap size bytes of the passed file\n+ descriptor, to use as backing memory for the pool.\n+\n+ Parameters:\n+ * **fd** (*ArgumentType.FileDescriptor*) -- file descriptor\n+ for the pool\n+\n+ * **size** (*ArgumentType.Int*) -- pool size, in bytes\n+\n+ Returns:\n+ \"WlShmPool\" -- pool to create\n+\n+ release() -> 'None'\n \n -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n \n- Request that the data is transferred\n+ Release the shm object\n \n- To transfer the offered data, the client issues this request and\n- indicates the mime type it wants to receive. The transfer\n- happens through the passed file descriptor (typically created\n- with the pipe system call). The source client writes the data\n- in the mime type representation requested and then closes the\n- file descriptor.\n+ Using this request a client can tell the server that it is not\n+ going to use the shm object anymore.\n \n- The receiving client reads from the read end of the pipe until\n- EOF and then closes its end, at which point the transfer is\n- complete.\n+ Objects created via this interface remain unaffected.\n \n- This request may happen multiple times for different mime types,\n- both before and after \"WlDataDevice.drop()\". Drag-and-drop\n- destination clients may preemptively fetch data or examine it\n- more closely to determine acceptance.\n+ format(format: 'int') -> 'None'\n+\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n+\n+ Pixel format description\n+\n+ Informs the client about a valid pixel format that can be used\n+ for buffers. Known formats include argb8888 and xrgb8888.\n \n Parameters:\n- * **mime_type** (*ArgumentType.String*) -- mime type desired\n- by receiver\n+ **format** (*ArgumentType.Uint*) -- buffer pixel format\n \n- * **fd** (*ArgumentType.FileDescriptor*) -- file descriptor\n- for data transfer\n+\n+WlBuffer\n+========\n+\n+class pywayland.protocol.wayland.WlBuffer\n+\n+ Content for a \"WlSurface\"\n+\n+ A buffer provides the content for a \"WlSurface\". Buffers are\n+ created through factory interfaces such as \"WlShm\",\n+ wp_linux_buffer_params (from the linux-dmabuf protocol extension)\n+ or similar. It has a width and a height and can be attached to a\n+ \"WlSurface\", but the mechanism by which a client provides and\n+ updates the contents is defined by the buffer factory interface.\n+\n+ Color channels are assumed to be electrical rather than optical (in\n+ other words, encoded with a transfer function) unless otherwise\n+ specified. If the buffer uses a format that has an alpha channel,\n+ the alpha channel is assumed to be premultiplied into the\n+ electrical color channel values (after transfer function encoding)\n+ unless otherwise specified.\n+\n+ Note, because \"WlBuffer\" objects are created from multiple\n+ independent factory interfaces, the \"WlBuffer\" interface is frozen\n+ at version 1.\n+\n+ destroy() -> 'None'\n+\n+ -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n+\n+ Destroy a buffer\n+\n+ Destroy a buffer. If and how you need to release the backing\n+ storage is defined by the buffer factory interface.\n+\n+ For possible side-effects to a surface, see\n+ \"WlSurface.attach()\".\n+\n+ release() -> 'None'\n+\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n+\n+ Compositor releases buffer\n+\n+ Sent when this \"WlBuffer\" is no longer used by the compositor.\n+ The client is now free to reuse or destroy this buffer and its\n+ backing storage.\n+\n+ If a client receives a release event before the frame callback\n+ requested in the same \"WlSurface.commit()\" that attaches this\n+ \"WlBuffer\" to a surface, then the client is immediately free to\n+ reuse the buffer and its backing storage, and does not need a\n+ second buffer for the next surface content update. Typically\n+ this is possible, when the compositor maintains a copy of the\n+ \"WlSurface\" contents, e.g. as a GL texture. This is an important\n+ optimization for GL(ES) compositors with \"WlShm\" clients.\n+\n+\n+WlSurface\n+=========\n+\n+class pywayland.protocol.wayland.WlSurface\n+\n+ An onscreen surface\n+\n+ A surface is a rectangular area that may be displayed on zero or\n+ more outputs, and shown any number of times at the compositor's\n+ discretion. They can present wl_buffers, receive user input, and\n+ define a local coordinate system.\n+\n+ The size of a surface (and relative positions on it) is described\n+ in surface-local coordinates, which may differ from the buffer\n+ coordinates of the pixel content, in case a buffer_transform or a\n+ buffer_scale is used.\n+\n+ A surface without a \"role\" is fairly useless: a compositor does not\n+ know where, when or how to present it. The role is the purpose of a\n+ \"WlSurface\". Examples of roles are a cursor for a pointer (as set\n+ by \"WlPointer.set_cursor()\"), a drag icon\n+ (\"WlDataDevice.start_drag()\"), a sub-surface\n+ (\"WlSubcompositor.get_subsurface()\"), and a window as defined by a\n+ shell protocol (e.g. \"WlShell.get_shell_surface()\").\n+\n+ A surface can have only one role at a time. Initially a \"WlSurface\"\n+ does not have a role. Once a \"WlSurface\" is given a role, it is set\n+ permanently for the whole lifetime of the \"WlSurface\" object.\n+ Giving the current role again is allowed, unless explicitly\n+ forbidden by the relevant interface specification.\n+\n+ Surface roles are given by requests in other interfaces such as\n+ \"WlPointer.set_cursor()\". The request should explicitly mention\n+ that this request gives a role to a \"WlSurface\". Often, this\n+ request also creates a new protocol object that represents the role\n+ and adds additional functionality to \"WlSurface\". When a client\n+ wants to destroy a \"WlSurface\", they must destroy this role object\n+ before the \"WlSurface\", otherwise a defunct_role_object error is\n+ sent.\n+\n+ Destroying the role object does not remove the role from the\n+ \"WlSurface\", but it may stop the \"WlSurface\" from \"playing the\n+ role\". For instance, if a \"WlSubsurface\" object is destroyed, the\n+ \"WlSurface\" it was created for will be unmapped and forget its\n+ position and z-order. It is allowed to create a \"WlSubsurface\" for\n+ the same \"WlSurface\" again, but it is not allowed to use the\n+ \"WlSurface\" as a cursor (cursor is a different role than sub-\n+ surface, and role switching is not allowed).\n \n destroy() -> 'None'\n \n+ -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n+\n+ Delete surface\n+\n+ Deletes the surface and invalidates its object ID.\n+\n+ attach(buffer: 'WlBuffer | None', x: 'int', y: 'int') -> 'None'\n+\n+ -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n+\n+ Set the surface contents\n+\n+ Set a buffer as the content of this surface.\n+\n+ The new size of the surface is calculated based on the buffer\n+ size transformed by the inverse buffer_transform and the inverse\n+ buffer_scale. This means that at commit time the supplied buffer\n+ size must be an integer multiple of the buffer_scale. If that's\n+ not the case, an invalid_size error is sent.\n+\n+ The x and y arguments specify the location of the new pending\n+ buffer's upper left corner, relative to the current buffer's\n+ upper left corner, in surface-local coordinates. In other words,\n+ the x and y, combined with the new surface size define in which\n+ directions the surface's size changes. Setting anything other\n+ than 0 as x and y arguments is discouraged, and should instead\n+ be replaced with using the separate \"WlSurface.offset()\"\n+ request.\n+\n+ When the bound \"WlSurface\" version is 5 or higher, passing any\n+ non-zero x or y is a protocol violation, and will result in an\n+ 'invalid_offset' error being raised. The x and y arguments are\n+ ignored and do not change the pending state. To achieve\n+ equivalent semantics, use \"WlSurface.offset()\".\n+\n+ Surface contents are double-buffered state, see\n+ \"WlSurface.commit()\".\n+\n+ The initial surface contents are void; there is no content.\n+ \"WlSurface.attach()\" assigns the given \"WlBuffer\" as the pending\n+ \"WlBuffer\". \"WlSurface.commit()\" makes the pending \"WlBuffer\"\n+ the new surface contents, and the size of the surface becomes\n+ the size calculated from the \"WlBuffer\", as described above.\n+ After commit, there is no pending buffer until the next attach.\n+\n+ Committing a pending \"WlBuffer\" allows the compositor to read\n+ the pixels in the \"WlBuffer\". The compositor may access the\n+ pixels at any time after the \"WlSurface.commit()\" request. When\n+ the compositor will not access the pixels anymore, it will send\n+ the \"WlBuffer.release()\" event. Only after receiving\n+ \"WlBuffer.release()\", the client may reuse the \"WlBuffer\". A\n+ \"WlBuffer\" that has been attached and then replaced by another\n+ attach instead of committed will not receive a release event,\n+ and is not used by the compositor.\n+\n+ If a pending \"WlBuffer\" has been committed to more than one\n+ \"WlSurface\", the delivery of \"WlBuffer.release()\" events becomes\n+ undefined. A well behaved client should not rely on\n+ \"WlBuffer.release()\" events in this case. Alternatively, a\n+ client could create multiple \"WlBuffer\" objects from the same\n+ backing storage or use wp_linux_buffer_release.\n+\n+ Destroying the \"WlBuffer\" after \"WlBuffer.release()\" does not\n+ change the surface contents. Destroying the \"WlBuffer\" before\n+ \"WlBuffer.release()\" is allowed as long as the underlying buffer\n+ storage isn't re-used (this can happen e.g. on client process\n+ termination). However, if the client destroys the \"WlBuffer\"\n+ before receiving the \"WlBuffer.release()\" event and mutates the\n+ underlying buffer storage, the surface contents become undefined\n+ immediately.\n+\n+ If \"WlSurface.attach()\" is sent with a NULL \"WlBuffer\", the\n+ following \"WlSurface.commit()\" will remove the surface content.\n+\n+ If a pending \"WlBuffer\" has been destroyed, the result is not\n+ specified. Many compositors are known to remove the surface\n+ content on the following \"WlSurface.commit()\", but this\n+ behaviour is not universal. Clients seeking to maximise\n+ compatibility should not destroy pending buffers and should\n+ ensure that they explicitly remove content from surfaces, even\n+ after destroying buffers.\n+\n+ Parameters:\n+ * **buffer** (\"WlBuffer\" or *None*) -- buffer of surface\n+ contents\n+\n+ * **x** (*ArgumentType.Int*) -- surface-local x coordinate\n+\n+ * **y** (*ArgumentType.Int*) -- surface-local y coordinate\n+\n+ damage(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None'\n+\n -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n \n- Destroy data offer\n+ Mark part of the surface damaged\n \n- Destroy the data offer.\n+ This request is used to describe the regions where the pending\n+ buffer is different from the current surface contents, and where\n+ the surface therefore needs to be repainted. The compositor\n+ ignores the parts of the damage that fall outside of the\n+ surface.\n \n- finish() -> 'None'\n+ Damage is double-buffered state, see \"WlSurface.commit()\".\n+\n+ The damage rectangle is specified in surface-local coordinates,\n+ where x and y specify the upper left corner of the damage\n+ rectangle.\n+\n+ The initial value for pending damage is empty: no damage.\n+ \"WlSurface.damage()\" adds pending damage: the new pending damage\n+ is the union of old pending damage and the given rectangle.\n+\n+ \"WlSurface.commit()\" assigns pending damage as the current\n+ damage, and clears pending damage. The server will clear the\n+ current damage as it repaints the surface.\n+\n+ Note! New clients should not use this request. Instead damage\n+ can be posted with \"WlSurface.damage_buffer()\" which uses buffer\n+ coordinates instead of surface coordinates.\n+\n+ Parameters:\n+ * **x** (*ArgumentType.Int*) -- surface-local x coordinate\n+\n+ * **y** (*ArgumentType.Int*) -- surface-local y coordinate\n+\n+ * **width** (*ArgumentType.Int*) -- width of damage rectangle\n+\n+ * **height** (*ArgumentType.Int*) -- height of damage\n+ rectangle\n+\n+ frame() -> 'Proxy[WlCallback]'\n \n -[ Request -- opcode 3 (attached to \"Resource\" instance) ]-\n \n- The offer will no longer be used\n+ Request a frame throttling hint\n \n- Notifies the compositor that the drag destination successfully\n- finished the drag-and-drop operation.\n+ Request a notification when it is a good time to start drawing a\n+ new frame, by creating a frame callback. This is useful for\n+ throttling redrawing operations, and driving animations.\n \n- Upon receiving this request, the compositor will emit\n- \"WlDataSource.dnd_finished()\" on the drag source client.\n+ When a client is animating on a \"WlSurface\", it can use the\n+ 'frame' request to get notified when it is a good time to draw\n+ and commit the next frame of animation. If the client commits an\n+ update earlier than that, it is likely that some updates will\n+ not make it to the display, and the client is wasting resources\n+ by drawing too often.\n \n- It is a client error to perform other requests than\n- \"WlDataOffer.destroy()\" after this one. It is also an error to\n- perform this request after a NULL mime type has been set in\n- \"WlDataOffer.accept()\" or no action was received through\n- \"WlDataOffer.action()\".\n+ The frame request will take effect on the next\n+ \"WlSurface.commit()\". The notification will only be posted for\n+ one frame unless requested again. For a \"WlSurface\", the\n+ notifications are posted in the order the frame requests were\n+ committed.\n \n- If \"WlDataOffer.finish()\" request is received for a non drag and\n- drop operation, the invalid_finish protocol error is raised.\n+ The server must send the notifications so that a client will not\n+ send excessive updates, while still allowing the highest\n+ possible update rate for clients that wait for the reply before\n+ drawing again. The server should give some time for the client\n+ to draw and commit after sending the frame callback events to\n+ let it hit the next output refresh.\n \n- set_actions(dnd_actions: 'int', preferred_action: 'int') -> 'None'\n+ A server should avoid signaling the frame callbacks if the\n+ surface is not visible in any way, e.g. the surface is off-\n+ screen, or completely obscured by other opaque surfaces.\n+\n+ The object returned by this request will be destroyed by the\n+ compositor after the callback is fired and as such the client\n+ must not attempt to use it after that point.\n+\n+ The callback_data passed in the callback is the current time, in\n+ milliseconds, with an undefined base.\n+\n+ Returns:\n+ \"WlCallback\" -- callback object for the frame request\n+\n+ set_opaque_region(region: 'WlRegion | None') -> 'None'\n \n -[ Request -- opcode 4 (attached to \"Resource\" instance) ]-\n \n- Set the available/preferred drag-and-drop actions\n+ Set opaque region\n \n- Sets the actions that the destination side client supports for\n- this operation. This request may trigger the emission of\n- \"WlDataSource.action()\" and \"WlDataOffer.action()\" events if the\n- compositor needs to change the selected action.\n+ This request sets the region of the surface that contains opaque\n+ content.\n \n- This request can be called multiple times throughout the drag-\n- and-drop operation, typically in response to\n- \"WlDataDevice.enter()\" or \"WlDataDevice.motion()\" events.\n+ The opaque region is an optimization hint for the compositor\n+ that lets it optimize the redrawing of content behind opaque\n+ regions. Setting an opaque region is not required for correct\n+ behaviour, but marking transparent content as opaque will result\n+ in repaint artifacts.\n \n- This request determines the final result of the drag-and-drop\n- operation. If the end result is that no action is accepted, the\n- drag source will receive \"WlDataSource.cancelled()\".\n+ The opaque region is specified in surface-local coordinates.\n \n- The dnd_actions argument must contain only values expressed in\n- the \"WlDataDeviceManager.dnd_actions()\" enum, and the\n- preferred_action argument must only contain one of those values\n- set, otherwise it will result in a protocol error.\n+ The compositor ignores the parts of the opaque region that fall\n+ outside of the surface.\n \n- While managing an \"ask\" action, the destination drag-and-drop\n- client may perform further \"WlDataOffer.receive()\" requests, and\n- is expected to perform one last \"WlDataOffer.set_actions()\"\n- request with a preferred action other than \"ask\" (and optionally\n- \"WlDataOffer.accept()\") before requesting\n- \"WlDataOffer.finish()\", in order to convey the action selected\n- by the user. If the preferred action is not in the\n- \"WlDataOffer.source_actions()\" mask, an error will be raised.\n+ Opaque region is double-buffered state, see\n+ \"WlSurface.commit()\".\n \n- If the \"ask\" action is dismissed (e.g. user cancellation), the\n- client is expected to perform \"WlDataOffer.destroy()\" right\n- away.\n+ \"WlSurface.set_opaque_region()\" changes the pending opaque\n+ region. \"WlSurface.commit()\" copies the pending region to the\n+ current region. Otherwise, the pending and current regions are\n+ never changed.\n \n- This request can only be made on drag-and-drop offers, a\n- protocol error will be raised otherwise.\n+ The initial value for an opaque region is empty. Setting the\n+ pending opaque region has copy semantics, and the \"WlRegion\"\n+ object can be destroyed immediately. A NULL \"WlRegion\" causes\n+ the pending opaque region to be set to empty.\n \n Parameters:\n- * **dnd_actions** (*ArgumentType.Uint*) -- actions supported\n- by the destination client\n+ **region** (\"WlRegion\" or *None*) -- opaque region of the\n+ surface\n \n- * **preferred_action** (*ArgumentType.Uint*) -- action\n- preferred by the destination client\n+ set_input_region(region: 'WlRegion | None') -> 'None'\n \n- offer(mime_type: 'str') -> 'None'\n+ -[ Request -- opcode 5 (attached to \"Resource\" instance) ]-\n \n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n+ Set input region\n \n- Advertise offered mime type\n+ This request sets the region of the surface that can receive\n+ pointer and touch events.\n \n- Sent immediately after creating the \"WlDataOffer\" object. One\n- event per offered mime type.\n+ Input events happening outside of this region will try the next\n+ surface in the server surface stack. The compositor ignores the\n+ parts of the input region that fall outside of the surface.\n+\n+ The input region is specified in surface-local coordinates.\n+\n+ Input region is double-buffered state, see \"WlSurface.commit()\".\n+\n+ \"WlSurface.set_input_region()\" changes the pending input region.\n+ \"WlSurface.commit()\" copies the pending region to the current\n+ region. Otherwise the pending and current regions are never\n+ changed, except cursor and icon surfaces are special cases, see\n+ \"WlPointer.set_cursor()\" and \"WlDataDevice.start_drag()\".\n+\n+ The initial value for an input region is infinite. That means\n+ the whole surface will accept input. Setting the pending input\n+ region has copy semantics, and the \"WlRegion\" object can be\n+ destroyed immediately. A NULL \"WlRegion\" causes the input region\n+ to be set to infinite.\n \n Parameters:\n- **mime_type** (*ArgumentType.String*) -- offered mime type\n+ **region** (\"WlRegion\" or *None*) -- input region of the\n+ surface\n \n- source_actions(source_actions: 'int') -> 'None'\n+ commit() -> 'None'\n \n- -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n+ -[ Request -- opcode 6 (attached to \"Resource\" instance) ]-\n \n- Notify the source-side available actions\n+ Commit pending surface state\n \n- This event indicates the actions offered by the data source. It\n- will be sent immediately after creating the \"WlDataOffer\"\n- object, or anytime the source side changes its offered actions\n- through \"WlDataSource.set_actions()\".\n+ Surface state (input, opaque, and damage regions, attached\n+ buffers, etc.) is double-buffered. Protocol requests modify the\n+ pending state, as opposed to the active state in use by the\n+ compositor.\n \n- Parameters:\n- **source_actions** (*ArgumentType.Uint*) -- actions offered\n- by the data source\n+ A commit request atomically creates a content update from the\n+ pending state, even if the pending state has not been touched.\n+ The content update is placed in a queue until it becomes active.\n+ After commit, the new pending state is as documented for each\n+ related request.\n \n- action(dnd_action: 'int') -> 'None'\n+ When the content update is applied, the \"WlBuffer\" is applied\n+ before all other state. This means that all coordinates in\n+ double-buffered state are relative to the newly attached\n+ wl_buffers, except for \"WlSurface.attach()\" itself. If there is\n+ no newly attached \"WlBuffer\", the coordinates are relative to\n+ the previous content update.\n \n- -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n+ All requests that need a commit to become effective are\n+ documented to affect double-buffered state.\n \n- Notify the selected action\n+ Other interfaces may add further double-buffered surface state.\n \n- This event indicates the action selected by the compositor after\n- matching the source/destination side actions. Only one action\n- (or none) will be offered here.\n+ set_buffer_transform(transform: 'int') -> 'None'\n \n- This event can be emitted multiple times during the drag-and-\n- drop operation in response to destination side action changes\n- through \"WlDataOffer.set_actions()\".\n+ -[ Request -- opcode 7 (attached to \"Resource\" instance) ]-\n \n- This event will no longer be emitted after \"WlDataDevice.drop()\"\n- happened on the drag- and-drop destination, the client must\n- honor the last action received, or the last preferred one set\n- through \"WlDataOffer.set_actions()\" when handling an \"ask\"\n- action.\n+ Sets the buffer transformation\n \n- Compositors may also change the selected action on the fly,\n- mainly in response to keyboard modifier changes during the drag-\n- and-drop operation.\n+ This request sets the transformation that the client has already\n+ applied to the content of the buffer. The accepted values for\n+ the transform parameter are the values for\n+ \"WlOutput.transform()\".\n \n- The most recent action received is always the valid one. Prior\n- to receiving \"WlDataDevice.drop()\", the chosen action may change\n- (e.g. due to keyboard modifiers being pressed). At the time of\n- receiving \"WlDataDevice.drop()\" the drag-and-drop destination\n- must honor the last action received.\n+ The compositor applies the inverse of this transformation\n+ whenever it uses the buffer contents.\n \n- Action changes may still happen after \"WlDataDevice.drop()\",\n- especially on \"ask\" actions, where the drag-and-drop destination\n- may choose another action afterwards. Action changes happening\n- at this stage are always the result of inter-client negotiation,\n- the compositor shall no longer be able to induce a different\n- action.\n+ Buffer transform is double-buffered state, see\n+ \"WlSurface.commit()\".\n \n- Upon \"ask\" actions, it is expected that the drag-and-drop\n- destination may potentially choose a different action and/or\n- mime type, based on \"WlDataOffer.source_actions()\" and finally\n- chosen by the user (e.g. popping up a menu with the available\n- options). The final \"WlDataOffer.set_actions()\" and\n- \"WlDataOffer.accept()\" requests must happen before the call to\n- \"WlDataOffer.finish()\".\n+ A newly created surface has its buffer transformation set to\n+ normal.\n+\n+ \"WlSurface.set_buffer_transform()\" changes the pending buffer\n+ transformation. \"WlSurface.commit()\" copies the pending buffer\n+ transformation to the current one. Otherwise, the pending and\n+ current values are never changed.\n+\n+ The purpose of this request is to allow clients to render\n+ content according to the output transform, thus permitting the\n+ compositor to use certain optimizations even if the display is\n+ rotated. Using hardware overlays and scanning out a client\n+ buffer for fullscreen surfaces are examples of such\n+ optimizations. Those optimizations are highly dependent on the\n+ compositor implementation, so the use of this request should be\n+ considered on a case-by-case basis.\n+\n+ Note that if the transform value includes 90 or 270 degree\n+ rotation, the width of the buffer will become the surface height\n+ and the height of the buffer will become the surface width.\n+\n+ If transform is not one of the values from the\n+ \"WlOutput.transform()\" enum the invalid_transform protocol error\n+ is raised.\n \n Parameters:\n- **dnd_action** (*ArgumentType.Uint*) -- action selected by\n- the compositor\n+ **transform** (*ArgumentType.Int*) -- transform for\n+ interpreting buffer contents\n \n+ set_buffer_scale(scale: 'int') -> 'None'\n \n-WlSeat\n-======\n+ -[ Request -- opcode 8 (attached to \"Resource\" instance) ]-\n \n-class pywayland.protocol.wayland.WlSeat\n+ Sets the buffer scaling factor\n \n- Group of input devices\n+ This request sets an optional scaling factor on how the\n+ compositor interprets the contents of the buffer attached to the\n+ window.\n \n- A seat is a group of keyboards, pointer and touch devices. This\n- object is published as a global during start up, or when such a\n- device is hot plugged. A seat typically has a pointer and\n- maintains a keyboard focus and a pointer focus.\n+ Buffer scale is double-buffered state, see \"WlSurface.commit()\".\n \n- get_pointer() -> 'Proxy[WlPointer]'\n+ A newly created surface has its buffer scale set to 1.\n \n- -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n+ \"WlSurface.set_buffer_scale()\" changes the pending buffer scale.\n+ \"WlSurface.commit()\" copies the pending buffer scale to the\n+ current one. Otherwise, the pending and current values are never\n+ changed.\n \n- Return pointer object\n+ The purpose of this request is to allow clients to supply higher\n+ resolution buffer data for use on high resolution outputs. It is\n+ intended that you pick the same buffer scale as the scale of the\n+ output that the surface is displayed on. This means the\n+ compositor can avoid scaling when rendering the surface on that\n+ output.\n \n- The ID provided will be initialized to the \"WlPointer\" interface\n- for this seat.\n+ Note that if the scale is larger than 1, then you have to attach\n+ a buffer that is larger (by a factor of scale in each dimension)\n+ than the desired surface size.\n \n- This request only takes effect if the seat has the pointer\n- capability, or has had the pointer capability in the past. It is\n- a protocol violation to issue this request on a seat that has\n- never had the pointer capability. The missing_capability error\n- will be sent in this case.\n+ If scale is not greater than 0 the invalid_scale protocol error\n+ is raised.\n \n- Returns:\n- \"WlPointer\" -- seat pointer\n+ Parameters:\n+ **scale** (*ArgumentType.Int*) -- scale for interpreting\n+ buffer contents\n \n- get_keyboard() -> 'Proxy[WlKeyboard]'\n+ damage_buffer(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None'\n \n- -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n+ -[ Request -- opcode 9 (attached to \"Resource\" instance) ]-\n \n- Return keyboard object\n+ Mark part of the surface damaged using buffer coordinates\n \n- The ID provided will be initialized to the \"WlKeyboard\"\n- interface for this seat.\n+ This request is used to describe the regions where the pending\n+ buffer is different from the current surface contents, and where\n+ the surface therefore needs to be repainted. The compositor\n+ ignores the parts of the damage that fall outside of the\n+ surface.\n \n- This request only takes effect if the seat has the keyboard\n- capability, or has had the keyboard capability in the past. It\n- is a protocol violation to issue this request on a seat that has\n- never had the keyboard capability. The missing_capability error\n- will be sent in this case.\n+ Damage is double-buffered state, see \"WlSurface.commit()\".\n \n- Returns:\n- \"WlKeyboard\" -- seat keyboard\n+ The damage rectangle is specified in buffer coordinates, where x\n+ and y specify the upper left corner of the damage rectangle.\n \n- get_touch() -> 'Proxy[WlTouch]'\n+ The initial value for pending damage is empty: no damage.\n+ \"WlSurface.damage_buffer()\" adds pending damage: the new pending\n+ damage is the union of old pending damage and the given\n+ rectangle.\n \n- -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n+ \"WlSurface.commit()\" assigns pending damage as the current\n+ damage, and clears pending damage. The server will clear the\n+ current damage as it repaints the surface.\n \n- Return touch object\n+ This request differs from \"WlSurface.damage()\" in only one way -\n+ it takes damage in buffer coordinates instead of surface-local\n+ coordinates. While this generally is more intuitive than surface\n+ coordinates, it is especially desirable when using wp_viewport\n+ or when a drawing library (like EGL) is unaware of buffer scale\n+ and buffer transform.\n \n- The ID provided will be initialized to the \"WlTouch\" interface\n- for this seat.\n+ Note: Because buffer transformation changes and damage requests\n+ may be interleaved in the protocol stream, it is impossible to\n+ determine the actual mapping between surface and buffer damage\n+ until \"WlSurface.commit()\" time. Therefore, compositors wishing\n+ to take both kinds of damage into account will have to\n+ accumulate damage from the two requests separately and only\n+ transform from one to the other after receiving the\n+ \"WlSurface.commit()\".\n \n- This request only takes effect if the seat has the touch\n- capability, or has had the touch capability in the past. It is a\n- protocol violation to issue this request on a seat that has\n- never had the touch capability. The missing_capability error\n- will be sent in this case.\n+ Parameters:\n+ * **x** (*ArgumentType.Int*) -- buffer-local x coordinate\n \n- Returns:\n- \"WlTouch\" -- seat touch interface\n+ * **y** (*ArgumentType.Int*) -- buffer-local y coordinate\n \n- release() -> 'None'\n+ * **width** (*ArgumentType.Int*) -- width of damage rectangle\n \n- -[ Request -- opcode 3 (attached to \"Resource\" instance) ]-\n+ * **height** (*ArgumentType.Int*) -- height of damage\n+ rectangle\n \n- Release the seat object\n+ offset(x: 'int', y: 'int') -> 'None'\n \n- Using this request a client can tell the server that it is not\n- going to use the seat object anymore.\n+ -[ Request -- opcode 10 (attached to \"Resource\" instance) ]-\n \n- capabilities(capabilities: 'int') -> 'None'\n+ Set the surface contents offset\n \n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n+ The x and y arguments specify the location of the new pending\n+ buffer's upper left corner, relative to the current buffer's\n+ upper left corner, in surface-local coordinates. In other words,\n+ the x and y, combined with the new surface size define in which\n+ directions the surface's size changes.\n \n- Seat capabilities changed\n+ Surface location offset is double-buffered state, see\n+ \"WlSurface.commit()\".\n \n- This is emitted whenever a seat gains or loses the pointer,\n- keyboard or touch capabilities. The argument is a capability\n- enum containing the complete set of capabilities this seat has.\n+ This request is semantically equivalent to and the replaces the\n+ x and y arguments in the \"WlSurface.attach()\" request in\n+ \"WlSurface\" versions prior to 5. See \"WlSurface.attach()\" for\n+ details.\n \n- When the pointer capability is added, a client may create a\n- \"WlPointer\" object using the \"WlSeat.get_pointer()\" request.\n- This object will receive pointer events until the capability is\n- removed in the future.\n+ Parameters:\n+ * **x** (*ArgumentType.Int*) -- surface-local x coordinate\n \n- When the pointer capability is removed, a client should destroy\n- the \"WlPointer\" objects associated with the seat where the\n- capability was removed, using the \"WlPointer.release()\" request.\n- No further pointer events will be received on these objects.\n+ * **y** (*ArgumentType.Int*) -- surface-local y coordinate\n \n- In some compositors, if a seat regains the pointer capability\n- and a client has a previously obtained \"WlPointer\" object of\n- version 4 or less, that object may start sending pointer events\n- again. This behavior is considered a misinterpretation of the\n- intended behavior and must not be relied upon by the client.\n- \"WlPointer\" objects of version 5 or later must not send events\n- if created before the most recent event notifying the client of\n- an added pointer capability.\n+ enter(output: 'WlOutput') -> 'None'\n \n- The above behavior also applies to \"WlKeyboard\" and \"WlTouch\"\n- with the keyboard and touch capabilities, respectively.\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n+\n+ Surface enters an output\n+\n+ This is emitted whenever a surface's creation, movement, or\n+ resizing results in some part of it being within the scanout\n+ region of an output.\n+\n+ Note that a surface may be overlapping with zero or more\n+ outputs.\n \n Parameters:\n- **capabilities** (*ArgumentType.Uint*) -- capabilities of the\n- seat\n+ **output** (\"WlOutput\") -- output entered by the surface\n \n- name(name: 'str') -> 'None'\n+ leave(output: 'WlOutput') -> 'None'\n \n -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n \n- Unique identifier for this seat\n+ Surface leaves an output\n \n- In a multi-seat configuration the seat name can be used by\n- clients to help identify which physical devices the seat\n- represents.\n+ This is emitted whenever a surface's creation, movement, or\n+ resizing results in it no longer having any part of it within\n+ the scanout region of an output.\n \n- The seat name is a UTF-8 string with no convention defined for\n- its contents. Each name is unique among all \"WlSeat\" globals.\n- The name is only guaranteed to be unique for the current\n- compositor instance.\n+ Clients should not use the number of outputs the surface is on\n+ for frame throttling purposes. The surface might be hidden even\n+ if no leave event has been sent, and the compositor might expect\n+ new surface content updates even if no enter event has been\n+ sent. The frame event should be used instead.\n \n- The same seat names are used for all clients. Thus, the name can\n- be shared across processes to refer to a specific \"WlSeat\"\n- global.\n+ Parameters:\n+ **output** (\"WlOutput\") -- output left by the surface\n \n- The name event is sent after binding to the seat global. This\n- event is only sent once per seat object, and the name does not\n- change over the lifetime of the \"WlSeat\" global.\n+ preferred_buffer_scale(factor: 'int') -> 'None'\n \n- Compositors may re-use the same seat name if the \"WlSeat\" global\n- is destroyed and re-created later.\n+ -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n+\n+ Preferred buffer scale for the surface\n+\n+ This event indicates the preferred buffer scale for this\n+ surface. It is sent whenever the compositor's preference\n+ changes.\n+\n+ Before receiving this event the preferred buffer scale for this\n+ surface is 1.\n+\n+ It is intended that scaling aware clients use this event to\n+ scale their content and use \"WlSurface.set_buffer_scale()\" to\n+ indicate the scale they have rendered with. This allows clients\n+ to supply a higher detail buffer.\n+\n+ The compositor shall emit a scale value greater than 0.\n \n Parameters:\n- **name** (*ArgumentType.String*) -- seat identifier\n+ **factor** (*ArgumentType.Int*) -- preferred scaling factor\n \n+ preferred_buffer_transform(transform: 'int') -> 'None'\n \n-WlBuffer\n-========\n+ -[ Event -- opcode 3 (attached to \"Proxy\" instance) ]-\n \n-class pywayland.protocol.wayland.WlBuffer\n+ Preferred buffer transform for the surface\n \n- Content for a \"WlSurface\"\n+ This event indicates the preferred buffer transform for this\n+ surface. It is sent whenever the compositor's preference\n+ changes.\n \n- A buffer provides the content for a \"WlSurface\". Buffers are\n- created through factory interfaces such as \"WlShm\",\n- wp_linux_buffer_params (from the linux-dmabuf protocol extension)\n- or similar. It has a width and a height and can be attached to a\n- \"WlSurface\", but the mechanism by which a client provides and\n- updates the contents is defined by the buffer factory interface.\n+ Before receiving this event the preferred buffer transform for\n+ this surface is normal.\n \n- Color channels are assumed to be electrical rather than optical (in\n- other words, encoded with a transfer function) unless otherwise\n- specified. If the buffer uses a format that has an alpha channel,\n- the alpha channel is assumed to be premultiplied into the\n- electrical color channel values (after transfer function encoding)\n- unless otherwise specified.\n+ Applying this transformation to the surface buffer contents and\n+ using \"WlSurface.set_buffer_transform()\" might allow the\n+ compositor to use the surface buffer more efficiently.\n \n- Note, because \"WlBuffer\" objects are created from multiple\n- independent factory interfaces, the \"WlBuffer\" interface is frozen\n- at version 1.\n+ Parameters:\n+ **transform** (*ArgumentType.Uint*) -- preferred transform\n+\n+\n+WlSubsurface\n+============\n+\n+class pywayland.protocol.wayland.WlSubsurface\n+\n+ Sub-surface interface to a \"WlSurface\"\n+\n+ An additional interface to a \"WlSurface\" object, which has been\n+ made a sub-surface. A sub-surface has one parent surface. A sub-\n+ surface's size and position are not limited to that of the parent.\n+ Particularly, a sub-surface is not automatically clipped to its\n+ parent's area.\n+\n+ A sub-surface becomes mapped, when a non-NULL \"WlBuffer\" is applied\n+ and the parent surface is mapped. The order of which one happens\n+ first is irrelevant. A sub-surface is hidden if the parent becomes\n+ hidden, or if a NULL \"WlBuffer\" is applied. These rules apply\n+ recursively through the tree of surfaces.\n+\n+ The behaviour of a \"WlSurface.commit()\" request on a sub-surface\n+ depends on the sub-surface's mode. The possible modes are\n+ synchronized and desynchronized, see methods\n+ \"WlSubsurface.set_sync()\" and \"WlSubsurface.set_desync()\".\n+ Synchronized mode caches the \"WlSurface\" state to be applied when\n+ the parent's state gets applied, and desynchronized mode applies\n+ the pending \"WlSurface\" state directly. A sub- surface is initially\n+ in the synchronized mode.\n+\n+ Sub-surfaces also have another kind of state, which is managed by\n+ \"WlSubsurface\" requests, as opposed to \"WlSurface\" requests. This\n+ state includes the sub-surface position relative to the parent\n+ surface (\"WlSubsurface.set_position()\"), and the stacking order of\n+ the parent and its sub-surfaces (\"WlSubsurface.place_above()\" and\n+ .place_below). This state is applied when the parent surface's\n+ \"WlSurface\" state is applied, regardless of the sub-surface's mode.\n+ As the exception, set_sync and set_desync are effective\n+ immediately.\n+\n+ The main surface can be thought to be always in desynchronized\n+ mode, since it does not have a parent in the sub-surfaces sense.\n+\n+ Even if a sub-surface is in desynchronized mode, it will behave as\n+ in synchronized mode, if its parent surface behaves as in\n+ synchronized mode. This rule is applied recursively throughout the\n+ tree of surfaces. This means, that one can set a sub-surface into\n+ synchronized mode, and then assume that all its child and grand-\n+ child sub-surfaces are synchronized, too, without explicitly\n+ setting them.\n+\n+ Destroying a sub-surface takes effect immediately. If you need to\n+ synchronize the removal of a sub-surface to the parent surface\n+ update, unmap the sub-surface first by attaching a NULL \"WlBuffer\",\n+ update parent, and then destroy the sub-surface.\n+\n+ If the parent \"WlSurface\" object is destroyed, the sub-surface is\n+ unmapped.\n+\n+ A sub-surface never has the keyboard focus of any seat.\n+\n+ The \"WlSurface.offset()\" request is ignored: clients must use\n+ set_position instead to move the sub-surface.\n \n destroy() -> 'None'\n \n -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Destroy a buffer\n+ Remove sub-surface interface\n \n- Destroy a buffer. If and how you need to release the backing\n- storage is defined by the buffer factory interface.\n+ The sub-surface interface is removed from the \"WlSurface\" object\n+ that was turned into a sub-surface with a\n+ \"WlSubcompositor.get_subsurface()\" request. The wl_surface's\n+ association to the parent is deleted. The \"WlSurface\" is\n+ unmapped immediately.\n \n- For possible side-effects to a surface, see\n- \"WlSurface.attach()\".\n+ set_position(x: 'int', y: 'int') -> 'None'\n \n- release() -> 'None'\n+ -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n \n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n+ Reposition the sub-surface\n \n- Compositor releases buffer\n+ This schedules a sub-surface position change. The sub-surface\n+ will be moved so that its origin (top left corner pixel) will be\n+ at the location x, y of the parent surface coordinate system.\n+ The coordinates are not restricted to the parent surface area.\n+ Negative values are allowed.\n \n- Sent when this \"WlBuffer\" is no longer used by the compositor.\n- The client is now free to reuse or destroy this buffer and its\n- backing storage.\n+ The scheduled coordinates will take effect whenever the state of\n+ the parent surface is applied.\n \n- If a client receives a release event before the frame callback\n- requested in the same \"WlSurface.commit()\" that attaches this\n- \"WlBuffer\" to a surface, then the client is immediately free to\n- reuse the buffer and its backing storage, and does not need a\n- second buffer for the next surface content update. Typically\n- this is possible, when the compositor maintains a copy of the\n- \"WlSurface\" contents, e.g. as a GL texture. This is an important\n- optimization for GL(ES) compositors with \"WlShm\" clients.\n+ If more than one set_position request is invoked by the client\n+ before the commit of the parent surface, the position of a new\n+ request always replaces the scheduled position from any previous\n+ request.\n \n+ The initial position is 0, 0.\n \n-WlCompositor\n-============\n+ Parameters:\n+ * **x** (*ArgumentType.Int*) -- x coordinate in the parent\n+ surface\n \n-class pywayland.protocol.wayland.WlCompositor\n+ * **y** (*ArgumentType.Int*) -- y coordinate in the parent\n+ surface\n \n- The compositor singleton\n+ place_above(sibling: 'WlSurface') -> 'None'\n \n- A compositor. This object is a singleton global. The compositor\n- is in charge of combining the contents of multiple surfaces into\n- one displayable output.\n+ -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n \n- create_surface() -> 'Proxy[WlSurface]'\n+ Restack the sub-surface\n \n- -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n+ This sub-surface is taken from the stack, and put back just\n+ above the reference surface, changing the z-order of the sub-\n+ surfaces. The reference surface must be one of the sibling\n+ surfaces, or the parent surface. Using any other surface,\n+ including this sub-surface, will cause a protocol error.\n \n- Create new surface\n+ The z-order is double-buffered. Requests are handled in order\n+ and applied immediately to a pending state. The final pending\n+ state is copied to the active state the next time the state of\n+ the parent surface is applied.\n \n- Ask the compositor to create a new surface.\n+ A new sub-surface is initially added as the top-most in the\n+ stack of its siblings and parent.\n \n- Returns:\n- \"WlSurface\" -- the new surface\n+ Parameters:\n+ **sibling** (\"WlSurface\") -- the reference surface\n \n- create_region() -> 'Proxy[WlRegion]'\n+ place_below(sibling: 'WlSurface') -> 'None'\n \n- -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n+ -[ Request -- opcode 3 (attached to \"Resource\" instance) ]-\n \n- Create new region\n+ Restack the sub-surface\n \n- Ask the compositor to create a new region.\n+ The sub-surface is placed just below the reference surface. See\n+ \"WlSubsurface.place_above()\".\n \n- Returns:\n- \"WlRegion\" -- the new region\n+ Parameters:\n+ **sibling** (\"WlSurface\") -- the reference surface\n \n+ set_sync() -> 'None'\n \n-WlCallback\n-==========\n+ -[ Request -- opcode 4 (attached to \"Resource\" instance) ]-\n \n-class pywayland.protocol.wayland.WlCallback\n+ Set sub-surface to synchronized mode\n \n- Callback object\n+ Change the commit behaviour of the sub-surface to synchronized\n+ mode, also described as the parent dependent mode.\n \n- Clients can handle the 'done' event to get notified when the\n- related request is done.\n+ In synchronized mode, \"WlSurface.commit()\" on a sub-surface will\n+ accumulate the committed state in a cache, but the state will\n+ not be applied and hence will not change the compositor output.\n+ The cached state is applied to the sub-surface immediately after\n+ the parent surface's state is applied. This ensures atomic\n+ updates of the parent and all its synchronized sub-surfaces.\n+ Applying the cached state will invalidate the cache, so further\n+ parent surface commits do not (re-)apply old state.\n \n- Note, because \"WlCallback\" objects are created from multiple\n- independent factory interfaces, the \"WlCallback\" interface is\n- frozen at version 1.\n+ See \"WlSubsurface\" for the recursive effect of this mode.\n \n- done(callback_data: 'int') -> 'None'\n+ set_desync() -> 'None'\n \n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n+ -[ Request -- opcode 5 (attached to \"Resource\" instance) ]-\n \n- Done event\n+ Set sub-surface to desynchronized mode\n \n- Notify the client when the related request is done.\n+ Change the commit behaviour of the sub-surface to desynchronized\n+ mode, also described as independent or freely running mode.\n \n- Parameters:\n- **callback_data** (*ArgumentType.Uint*) -- request-specific\n- data for the callback\n+ In desynchronized mode, \"WlSurface.commit()\" on a sub-surface\n+ will apply the pending state directly, without caching, as\n+ happens normally with a \"WlSurface\". Calling\n+ \"WlSurface.commit()\" on the parent surface has no effect on the\n+ sub-surface's \"WlSurface\" state. This mode allows a sub-surface\n+ to be updated on its own.\n+\n+ If cached state exists when \"WlSurface.commit()\" is called in\n+ desynchronized mode, the pending state is added to the cached\n+ state, and applied as a whole. This invalidates the cache.\n+\n+ Note: even if a sub-surface is set to desynchronized, a parent\n+ sub- surface may override it to behave as synchronized. For\n+ details, see \"WlSubsurface\".\n+\n+ If a surface's parent surface behaves as desynchronized, then\n+ the cached state is applied on set_desync.\n \n \n WlKeyboard\n ==========\n \n class pywayland.protocol.wayland.WlKeyboard\n \n@@ -2915,380 +3245,153 @@\n * **rate** (*ArgumentType.Int*) -- the rate of repeating keys\n in characters per second\n \n * **delay** (*ArgumentType.Int*) -- delay in milliseconds\n since key down until repeating starts\n \n \n-WlOutput\n-========\n+WlSeat\n+======\n \n-class pywayland.protocol.wayland.WlOutput\n+class pywayland.protocol.wayland.WlSeat\n \n- Compositor output region\n+ Group of input devices\n \n- An output describes part of the compositor geometry. The\n- compositor works in the 'compositor coordinate system' and an\n- output corresponds to a rectangular area in that space that is\n- actually visible. This typically corresponds to a monitor that\n- displays part of the compositor space. This object is published as\n- global during start up, or when a monitor is hotplugged.\n+ A seat is a group of keyboards, pointer and touch devices. This\n+ object is published as a global during start up, or when such a\n+ device is hot plugged. A seat typically has a pointer and\n+ maintains a keyboard focus and a pointer focus.\n \n- release() -> 'None'\n+ get_pointer() -> 'Proxy[WlPointer]'\n \n -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Release the output object\n-\n- Using this request a client can tell the server that it is not\n- going to use the output object anymore.\n-\n- geometry(x: 'int', y: 'int', physical_width: 'int', physical_height: 'int', subpixel: 'int', make: 'str', model: 'str', transform: 'int') -> 'None'\n-\n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n-\n- Properties of the output\n-\n- The geometry event describes geometric properties of the output.\n- The event is sent when binding to the output object and whenever\n- any of the properties change.\n-\n- The physical size can be set to zero if it doesn't make sense\n- for this output (e.g. for projectors or virtual outputs).\n-\n- The geometry event will be followed by a done event (starting\n- from version 2).\n-\n- Clients should use \"WlSurface.preferred_buffer_transform()\"\n- instead of the transform advertised by this event to find the\n- preferred buffer transform to use for a surface.\n-\n- Note: \"WlOutput\" only advertises partial information about the\n- output position and identification. Some compositors, for\n- instance those not implementing a desktop-style output layout or\n- those exposing virtual outputs, might fake this information.\n- Instead of using x and y, clients should use\n- xdg_output.logical_position. Instead of using make and model,\n- clients should use name and description.\n-\n- Parameters:\n- * **x** (*ArgumentType.Int*) -- x position within the global\n- compositor space\n-\n- * **y** (*ArgumentType.Int*) -- y position within the global\n- compositor space\n-\n- * **physical_width** (*ArgumentType.Int*) -- width in\n- millimeters of the output\n-\n- * **physical_height** (*ArgumentType.Int*) -- height in\n- millimeters of the output\n-\n- * **subpixel** (*ArgumentType.Int*) -- subpixel orientation\n- of the output\n-\n- * **make** (*ArgumentType.String*) -- textual description of\n- the manufacturer\n-\n- * **model** (*ArgumentType.String*) -- textual description of\n- the model\n+ Return pointer object\n \n- * **transform** (*ArgumentType.Int*) -- additional\n- transformation applied to buffer contents during\n- presentation\n+ The ID provided will be initialized to the \"WlPointer\" interface\n+ for this seat.\n \n- mode(flags: 'int', width: 'int', height: 'int', refresh: 'int') -> 'None'\n+ This request only takes effect if the seat has the pointer\n+ capability, or has had the pointer capability in the past. It is\n+ a protocol violation to issue this request on a seat that has\n+ never had the pointer capability. The missing_capability error\n+ will be sent in this case.\n \n- -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n+ Returns:\n+ \"WlPointer\" -- seat pointer\n \n- Advertise available modes for the output\n+ get_keyboard() -> 'Proxy[WlKeyboard]'\n \n- The mode event describes an available mode for the output.\n+ -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n \n- The event is sent when binding to the output object and there\n- will always be one mode, the current mode. The event is sent\n- again if an output changes mode, for the mode that is now\n- current. In other words, the current mode is always the last\n- mode that was received with the current flag set.\n+ Return keyboard object\n \n- Non-current modes are deprecated. A compositor can decide to\n- only advertise the current mode and never send other modes.\n- Clients should not rely on non-current modes.\n+ The ID provided will be initialized to the \"WlKeyboard\"\n+ interface for this seat.\n \n- The size of a mode is given in physical hardware units of the\n- output device. This is not necessarily the same as the output\n- size in the global compositor space. For instance, the output\n- may be scaled, as described in \"WlOutput.scale()\", or\n- transformed, as described in \"WlOutput.transform()\". Clients\n- willing to retrieve the output size in the global compositor\n- space should use xdg_output.logical_size instead.\n+ This request only takes effect if the seat has the keyboard\n+ capability, or has had the keyboard capability in the past. It\n+ is a protocol violation to issue this request on a seat that has\n+ never had the keyboard capability. The missing_capability error\n+ will be sent in this case.\n \n- The vertical refresh rate can be set to zero if it doesn't make\n- sense for this output (e.g. for virtual outputs).\n+ Returns:\n+ \"WlKeyboard\" -- seat keyboard\n \n- The mode event will be followed by a done event (starting from\n- version 2).\n+ get_touch() -> 'Proxy[WlTouch]'\n \n- Clients should not use the refresh rate to schedule frames.\n- Instead, they should use the \"WlSurface.frame()\" event or the\n- presentation-time protocol.\n+ -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n \n- Note: this information is not always meaningful for all outputs.\n- Some compositors, such as those exposing virtual outputs, might\n- fake the refresh rate or the size.\n+ Return touch object\n \n- Parameters:\n- * **flags** (*ArgumentType.Uint*) -- bitfield of mode flags\n+ The ID provided will be initialized to the \"WlTouch\" interface\n+ for this seat.\n \n- * **width** (*ArgumentType.Int*) -- width of the mode in\n- hardware units\n+ This request only takes effect if the seat has the touch\n+ capability, or has had the touch capability in the past. It is a\n+ protocol violation to issue this request on a seat that has\n+ never had the touch capability. The missing_capability error\n+ will be sent in this case.\n \n- * **height** (*ArgumentType.Int*) -- height of the mode in\n- hardware units\n+ Returns:\n+ \"WlTouch\" -- seat touch interface\n \n- * **refresh** (*ArgumentType.Int*) -- vertical refresh rate\n- in mHz\n+ release() -> 'None'\n \n- done() -> 'None'\n+ -[ Request -- opcode 3 (attached to \"Resource\" instance) ]-\n \n- -[ Event -- opcode 2 (attached to \"Proxy\" instance) ]-\n+ Release the seat object\n \n- Sent all information about output\n+ Using this request a client can tell the server that it is not\n+ going to use the seat object anymore.\n \n- This event is sent after all other properties have been sent\n- after binding to the output object and after any other property\n- changes done after that. This allows changes to the output\n- properties to be seen as atomic, even if they happen via\n- multiple events.\n+ capabilities(capabilities: 'int') -> 'None'\n \n- scale(factor: 'int') -> 'None'\n+ -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n \n- -[ Event -- opcode 3 (attached to \"Proxy\" instance) ]-\n+ Seat capabilities changed\n \n- Output scaling properties\n+ This is emitted whenever a seat gains or loses the pointer,\n+ keyboard or touch capabilities. The argument is a capability\n+ enum containing the complete set of capabilities this seat has.\n \n- This event contains scaling geometry information that is not in\n- the geometry event. It may be sent after binding the output\n- object or if the output scale changes later. The compositor will\n- emit a non-zero, positive value for scale. If it is not sent,\n- the client should assume a scale of 1.\n+ When the pointer capability is added, a client may create a\n+ \"WlPointer\" object using the \"WlSeat.get_pointer()\" request.\n+ This object will receive pointer events until the capability is\n+ removed in the future.\n \n- A scale larger than 1 means that the compositor will\n- automatically scale surface buffers by this amount when\n- rendering. This is used for very high resolution displays where\n- applications rendering at the native resolution would be too\n- small to be legible.\n+ When the pointer capability is removed, a client should destroy\n+ the \"WlPointer\" objects associated with the seat where the\n+ capability was removed, using the \"WlPointer.release()\" request.\n+ No further pointer events will be received on these objects.\n \n- Clients should use \"WlSurface.preferred_buffer_scale()\" instead\n- of this event to find the preferred buffer scale to use for a\n- surface.\n+ In some compositors, if a seat regains the pointer capability\n+ and a client has a previously obtained \"WlPointer\" object of\n+ version 4 or less, that object may start sending pointer events\n+ again. This behavior is considered a misinterpretation of the\n+ intended behavior and must not be relied upon by the client.\n+ \"WlPointer\" objects of version 5 or later must not send events\n+ if created before the most recent event notifying the client of\n+ an added pointer capability.\n \n- The scale event will be followed by a done event.\n+ The above behavior also applies to \"WlKeyboard\" and \"WlTouch\"\n+ with the keyboard and touch capabilities, respectively.\n \n Parameters:\n- **factor** (*ArgumentType.Int*) -- scaling factor of output\n+ **capabilities** (*ArgumentType.Uint*) -- capabilities of the\n+ seat\n \n name(name: 'str') -> 'None'\n \n- -[ Event -- opcode 4 (attached to \"Proxy\" instance) ]-\n-\n- Name of this output\n-\n- Many compositors will assign user-friendly names to their\n- outputs, show them to the user, allow the user to refer to an\n- output, etc. The client may wish to know this name as well to\n- offer the user similar behaviors.\n-\n- The name is a UTF-8 string with no convention defined for its\n- contents. Each name is unique among all \"WlOutput\" globals. The\n- name is only guaranteed to be unique for the compositor\n- instance.\n-\n- The same output name is used for all clients for a given\n- \"WlOutput\" global. Thus, the name can be shared across processes\n- to refer to a specific \"WlOutput\" global.\n-\n- The name is not guaranteed to be persistent across sessions,\n- thus cannot be used to reliably identify an output in e.g.\n- configuration files.\n-\n- Examples of names include 'HDMI-A-1', 'WL-1', 'X11-1', etc.\n- However, do not assume that the name is a reflection of an\n- underlying DRM connector, X11 connection, etc.\n-\n- The name event is sent after binding the output object. This\n- event is only sent once per output object, and the name does not\n- change over the lifetime of the \"WlOutput\" global.\n-\n- Compositors may re-use the same output name if the \"WlOutput\"\n- global is destroyed and re-created later. Compositors should\n- avoid re- using the same name if possible.\n-\n- The name event will be followed by a done event.\n-\n- Parameters:\n- **name** (*ArgumentType.String*) -- output name\n-\n- description(description: 'str') -> 'None'\n-\n- -[ Event -- opcode 5 (attached to \"Proxy\" instance) ]-\n-\n- Human-readable description of this output\n-\n- Many compositors can produce human-readable descriptions of\n- their outputs. The client may wish to know this description as\n- well, e.g. for output selection purposes.\n-\n- The description is a UTF-8 string with no convention defined for\n- its contents. The description is not guaranteed to be unique\n- among all \"WlOutput\" globals. Examples might include 'Foocorp\n- 11\" Display' or 'Virtual X11 output via :1'.\n-\n- The description event is sent after binding the output object\n- and whenever the description changes. The description is\n- optional, and may not be sent at all.\n-\n- The description event will be followed by a done event.\n-\n- Parameters:\n- **description** (*ArgumentType.String*) -- output description\n-\n-\n-WlRegistry\n-==========\n-\n-class pywayland.protocol.wayland.WlRegistry\n-\n- Global registry object\n-\n- The singleton global registry object. The server has a number of\n- global objects that are available to all clients. These objects\n- typically represent an actual object in the server (for example, an\n- input device) or they are singleton objects that provide extension\n- functionality.\n-\n- When a client creates a registry object, the registry object will\n- emit a global event for each global currently in the registry.\n- Globals come and go as a result of device or monitor hotplugs,\n- reconfiguration or other events, and the registry will send out\n- global and global_remove events to keep the client up to date with\n- the changes. To mark the end of the initial burst of events, the\n- client can use the \"WlDisplay.sync()\" request immediately after\n- calling \"WlDisplay.get_registry()\".\n-\n- A client can bind to a global object by using the bind request.\n- This creates a client-side handle that lets the object emit events\n- to the client and lets the client invoke requests on the object.\n-\n- bind(name: 'int', interface: 'type[T]', version: 'int') -> 'Proxy[T]'\n-\n- -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n-\n- Bind an object to the display\n-\n- Binds a new, client-created object to the server using the\n- specified name as the identifier.\n-\n- Parameters:\n- * **name** (*ArgumentType.Uint*) -- unique numeric name of\n- the object\n-\n- * **interface** (*string*) -- Interface name\n-\n- * **version** (*int*) -- Interface version\n-\n- Returns:\n- \"pywayland.client.proxy.Proxy\" of specified Interface --\n- bounded object\n-\n- global_(name: 'int', interface: 'str', version: 'int') -> 'None'\n-\n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n-\n- Announce global object\n-\n- Notify the client of global objects.\n-\n- The event notifies the client that a global object with the\n- given name is now available, and it implements the given version\n- of the given interface.\n-\n- Parameters:\n- * **name** (*ArgumentType.Uint*) -- numeric name of the\n- global object\n-\n- * **interface** (*ArgumentType.String*) -- interface\n- implemented by the object\n-\n- * **version** (*ArgumentType.Uint*) -- interface version\n-\n- global_remove(name: 'int') -> 'None'\n-\n -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n \n- Announce removal of global object\n-\n- Notify the client of removed global objects.\n-\n- This event notifies the client that the global identified by\n- name is no longer available. If the client bound to the global\n- using the bind request, the client should now destroy that\n- object.\n-\n- The object remains valid and requests to the object will be\n- ignored until the client destroys it, to avoid races between the\n- global going away and a client sending a request to it.\n-\n- Parameters:\n- **name** (*ArgumentType.Uint*) -- numeric name of the global\n- object\n-\n-\n-WlDataDeviceManager\n-===================\n-\n-class pywayland.protocol.wayland.WlDataDeviceManager\n-\n- Data transfer interface\n-\n- The \"WlDataDeviceManager\" is a singleton global object that\n- provides access to inter-client data transfer mechanisms such as\n- copy-and-paste and drag-and-drop. These mechanisms are tied to a\n- \"WlSeat\" and this interface lets a client get a \"WlDataDevice\"\n- corresponding to a \"WlSeat\".\n-\n- Depending on the version bound, the objects created from the bound\n- \"WlDataDeviceManager\" object will have different requirements for\n- functioning properly. See \"WlDataSource.set_actions()\",\n- \"WlDataOffer.accept()\" and \"WlDataOffer.finish()\" for details.\n-\n- create_data_source() -> 'Proxy[WlDataSource]'\n-\n- -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n-\n- Create a new data source\n-\n- Create a new data source.\n+ Unique identifier for this seat\n \n- Returns:\n- \"WlDataSource\" -- data source to create\n+ In a multi-seat configuration the seat name can be used by\n+ clients to help identify which physical devices the seat\n+ represents.\n \n- get_data_device(seat: 'WlSeat') -> 'Proxy[WlDataDevice]'\n+ The seat name is a UTF-8 string with no convention defined for\n+ its contents. Each name is unique among all \"WlSeat\" globals.\n+ The name is only guaranteed to be unique for the current\n+ compositor instance.\n \n- -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n+ The same seat names are used for all clients. Thus, the name can\n+ be shared across processes to refer to a specific \"WlSeat\"\n+ global.\n \n- Create a new data device\n+ The name event is sent after binding to the seat global. This\n+ event is only sent once per seat object, and the name does not\n+ change over the lifetime of the \"WlSeat\" global.\n \n- Create a new data device for a given seat.\n+ Compositors may re-use the same seat name if the \"WlSeat\" global\n+ is destroyed and re-created later.\n \n Parameters:\n- **seat** (\"WlSeat\") -- seat associated with the data device\n-\n- Returns:\n- \"WlDataDevice\" -- data device to create\n+ **name** (*ArgumentType.String*) -- seat identifier\n \n \n WlShell\n =======\n \n class pywayland.protocol.wayland.WlShell\n \n@@ -3320,237 +3423,134 @@\n **surface** (\"WlSurface\") -- surface to be given the shell\n surface role\n \n Returns:\n \"WlShellSurface\" -- shell surface to create\n \n \n-WlShm\n-=====\n-\n-class pywayland.protocol.wayland.WlShm\n+WlRegion\n+========\n \n- Shared memory support\n+class pywayland.protocol.wayland.WlRegion\n \n- A singleton global object that provides support for shared memory.\n+ Region interface\n \n- Clients can create \"WlShmPool\" objects using the create_pool\n- request.\n+ A region object describes an area.\n \n- On binding the \"WlShm\" object one or more format events are emitted\n- to inform clients about the valid pixel formats that can be used\n- for buffers.\n+ Region objects are used to describe the opaque and input regions of\n+ a surface.\n \n- create_pool(fd: 'int', size: 'int') -> 'Proxy[WlShmPool]'\n+ destroy() -> 'None'\n \n -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Create a shm pool\n-\n- Create a new \"WlShmPool\" object.\n-\n- The pool can be used to create shared memory based buffer\n- objects. The server will mmap size bytes of the passed file\n- descriptor, to use as backing memory for the pool.\n-\n- Parameters:\n- * **fd** (*ArgumentType.FileDescriptor*) -- file descriptor\n- for the pool\n-\n- * **size** (*ArgumentType.Int*) -- pool size, in bytes\n+ Destroy region\n \n- Returns:\n- \"WlShmPool\" -- pool to create\n+ Destroy the region. This will invalidate the object ID.\n \n- release() -> 'None'\n+ add(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None'\n \n -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n \n- Release the shm object\n-\n- Using this request a client can tell the server that it is not\n- going to use the shm object anymore.\n-\n- Objects created via this interface remain unaffected.\n-\n- format(format: 'int') -> 'None'\n-\n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n-\n- Pixel format description\n+ Add rectangle to region\n \n- Informs the client about a valid pixel format that can be used\n- for buffers. Known formats include argb8888 and xrgb8888.\n+ Add the specified rectangle to the region.\n \n Parameters:\n- **format** (*ArgumentType.Uint*) -- buffer pixel format\n-\n-\n-WlDisplay\n-=========\n-\n-class pywayland.protocol.wayland.WlDisplay\n-\n- Core global object\n-\n- The core global object. This is a special singleton object. It is\n- used for internal Wayland protocol features.\n-\n- sync() -> 'Proxy[WlCallback]'\n-\n- -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n-\n- Asynchronous roundtrip\n-\n- The sync request asks the server to emit the 'done' event on the\n- returned \"WlCallback\" object. Since requests are handled in-\n- order and events are delivered in-order, this can be used as a\n- barrier to ensure all previous requests and the resulting events\n- have been handled.\n-\n- The object returned by this request will be destroyed by the\n- compositor after the callback is fired and as such the client\n- must not attempt to use it after that point.\n-\n- The callback_data passed in the callback is undefined and should\n- be ignored.\n-\n- Returns:\n- \"WlCallback\" -- callback object for the sync request\n-\n- get_registry() -> 'Proxy[WlRegistry]'\n-\n- -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n-\n- Get global registry object\n+ * **x** (*ArgumentType.Int*) -- region-local x coordinate\n \n- This request creates a registry object that allows the client to\n- list and bind the global objects available from the compositor.\n+ * **y** (*ArgumentType.Int*) -- region-local y coordinate\n \n- It should be noted that the server side resources consumed in\n- response to a get_registry request can only be released when the\n- client disconnects, not when the client side proxy is destroyed.\n- Therefore, clients should invoke get_registry as infrequently as\n- possible to avoid wasting memory.\n+ * **width** (*ArgumentType.Int*) -- rectangle width\n \n- Returns:\n- \"WlRegistry\" -- global registry object\n+ * **height** (*ArgumentType.Int*) -- rectangle height\n \n- error(object_id: 'Any', code: 'int', message: 'str') -> 'None'\n+ subtract(x: 'int', y: 'int', width: 'int', height: 'int') -> 'None'\n \n- -[ Event -- opcode 0 (attached to \"Proxy\" instance) ]-\n+ -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n \n- Fatal error event\n+ Subtract rectangle from region\n \n- The error event is sent out when a fatal (non-recoverable) error\n- has occurred. The object_id argument is the object where the\n- error occurred, most often in response to a request to that\n- object. The code identifies the error and is defined by the\n- object interface. As such, each interface defines its own set\n- of error codes. The message is a brief description of the\n- error, for (debugging) convenience.\n+ Subtract the specified rectangle from the region.\n \n Parameters:\n- * **object_id** (*ArgumentType.Object*) -- object where the\n- error occurred\n-\n- * **code** (*ArgumentType.Uint*) -- error code\n+ * **x** (*ArgumentType.Int*) -- region-local x coordinate\n \n- * **message** (*ArgumentType.String*) -- error description\n+ * **y** (*ArgumentType.Int*) -- region-local y coordinate\n \n- delete_id(id: 'int') -> 'None'\n+ * **width** (*ArgumentType.Int*) -- rectangle width\n \n- -[ Event -- opcode 1 (attached to \"Proxy\" instance) ]-\n+ * **height** (*ArgumentType.Int*) -- rectangle height\n \n- Acknowledge object id deletion\n \n- This event is used internally by the object ID management logic.\n- When a client deletes an object that it had created, the server\n- will send this event to acknowledge that it has seen the delete\n- request. When the client receives this event, it will know that\n- it can safely reuse the object ID.\n+WlSubcompositor\n+===============\n \n- Parameters:\n- **id** (*ArgumentType.Uint*) -- deleted object ID\n+class pywayland.protocol.wayland.WlSubcompositor\n \n+ Sub-surface compositing\n \n-WlShmPool\n-=========\n+ The global interface exposing sub-surface compositing capabilities.\n+ A \"WlSurface\", that has sub-surfaces associated, is called the\n+ parent surface. Sub-surfaces can be arbitrarily nested and create a\n+ tree of sub-surfaces.\n \n-class pywayland.protocol.wayland.WlShmPool\n+ The root surface in a tree of sub-surfaces is the main surface. The\n+ main surface cannot be a sub-surface, because sub-surfaces must\n+ always have a parent.\n \n- A shared memory pool\n+ A main surface with its sub-surfaces forms a (compound) window. For\n+ window management purposes, this set of \"WlSurface\" objects is to\n+ be considered as a single window, and it should also behave as\n+ such.\n \n- The \"WlShmPool\" object encapsulates a piece of memory shared\n- between the compositor and client. Through the \"WlShmPool\" object,\n- the client can allocate shared memory \"WlBuffer\" objects. All\n- objects created through the same pool share the same underlying\n- mapped memory. Reusing the mapped memory avoids the setup/teardown\n- overhead and is useful when interactively resizing a surface or for\n- many small buffers.\n+ The aim of sub-surfaces is to offload some of the compositing work\n+ within a window from clients to the compositor. A prime example is\n+ a video player with decorations and video in separate \"WlSurface\"\n+ objects. This should allow the compositor to pass YUV video buffer\n+ processing to dedicated overlay hardware when possible.\n \n- create_buffer(offset: 'int', width: 'int', height: 'int', stride: 'int', format: 'int') -> 'Proxy[WlBuffer]'\n+ destroy() -> 'None'\n \n -[ Request -- opcode 0 (attached to \"Resource\" instance) ]-\n \n- Create a buffer from the pool\n-\n- Create a \"WlBuffer\" object from the pool.\n-\n- The buffer is created offset bytes into the pool and has width\n- and height as specified. The stride argument specifies the\n- number of bytes from the beginning of one row to the beginning\n- of the next. The format is the pixel format of the buffer and\n- must be one of those advertised through the \"WlShm.format()\"\n- event.\n-\n- A buffer will keep a reference to the pool it was created from\n- so it is valid to destroy the pool immediately after creating a\n- buffer from it.\n-\n- Parameters:\n- * **offset** (*ArgumentType.Int*) -- buffer byte offset\n- within the pool\n-\n- * **width** (*ArgumentType.Int*) -- buffer width, in pixels\n-\n- * **height** (*ArgumentType.Int*) -- buffer height, in pixels\n-\n- * **stride** (*ArgumentType.Int*) -- number of bytes from the\n- beginning of one row to the beginning of the next row\n-\n- * **format** (*ArgumentType.Uint*) -- buffer pixel format\n+ Unbind from the subcompositor interface\n \n- Returns:\n- \"WlBuffer\" -- buffer to create\n+ Informs the server that the client will not be using this\n+ protocol object anymore. This does not affect any other objects,\n+ \"WlSubsurface\" objects included.\n \n- destroy() -> 'None'\n+ get_subsurface(surface: 'WlSurface', parent: 'WlSurface') -> 'Proxy[WlSubsurface]'\n \n -[ Request -- opcode 1 (attached to \"Resource\" instance) ]-\n \n- Destroy the pool\n+ Give a surface the role sub-surface\n \n- Destroy the shared memory pool.\n+ Create a sub-surface interface for the given surface, and\n+ associate it with the given parent surface. This turns a plain\n+ \"WlSurface\" into a sub-surface.\n \n- The mmapped memory will be released when all buffers that have\n- been created from this pool are gone.\n+ The to-be sub-surface must not already have another role, and it\n+ must not have an existing \"WlSubsurface\" object. Otherwise the\n+ bad_surface protocol error is raised.\n \n- resize(size: 'int') -> 'None'\n+ Adding sub-surfaces to a parent is a double-buffered operation\n+ on the parent (see \"WlSurface.commit()\"). The effect of adding a\n+ sub-surface becomes visible on the next time the state of the\n+ parent surface is applied.\n \n- -[ Request -- opcode 2 (attached to \"Resource\" instance) ]-\n+ The parent surface must not be one of the child surface's\n+ descendants, and the parent must be different from the child\n+ surface, otherwise the bad_parent protocol error is raised.\n \n- Change the size of the pool mapping\n+ This request modifies the behaviour of \"WlSurface.commit()\"\n+ request on the sub- surface, see the documentation on\n+ \"WlSubsurface\" interface.\n \n- This request will cause the server to remap the backing memory\n- for the pool from the file descriptor passed when the pool was\n- created, but using the new size. This request can only be used\n- to make the pool bigger.\n+ Parameters:\n+ * **surface** (\"WlSurface\") -- the surface to be turned into\n+ a sub-surface\n \n- This request only changes the amount of bytes that are mmapped\n- by the server and does not touch the file corresponding to the\n- file descriptor passed at creation time. It is the client's\n- responsibility to ensure that the file is at least as big as the\n- new pool size.\n+ * **parent** (\"WlSurface\") -- the parent surface\n \n- Parameters:\n- **size** (*ArgumentType.Int*) -- new size of the pool, in\n- bytes\n+ Returns:\n+ \"WlSubsurface\" -- the new sub- surface object ID\n"}]}]}]}]}, {"source1": "python3-pywayland_0.4.18-1_i386.deb", "source2": "python3-pywayland_0.4.18-1_i386.deb", "unified_diff": null, "details": [{"source1": "file list", "source2": "file list", "unified_diff": "@@ -1,3 +1,3 @@\n -rw-r--r-- 0 0 0 4 2024-10-11 20:38:19.000000 debian-binary\n -rw-r--r-- 0 0 0 2916 2024-10-11 20:38:19.000000 control.tar.xz\n--rw-r--r-- 0 0 0 116328 2024-10-11 20:38:19.000000 data.tar.xz\n+-rw-r--r-- 0 0 0 116644 2024-10-11 20:38:19.000000 data.tar.xz\n"}, {"source1": "control.tar.xz", "source2": "control.tar.xz", "unified_diff": null, "details": [{"source1": "control.tar", "source2": "control.tar", "unified_diff": null, "details": [{"source1": "./md5sums", "source2": "./md5sums", "unified_diff": null, "details": [{"source1": "./md5sums", "source2": "./md5sums", "comments": ["Files differ"], "unified_diff": null}]}]}]}, {"source1": "data.tar.xz", "source2": "data.tar.xz", "unified_diff": null, "details": [{"source1": "data.tar", "source2": "data.tar", "unified_diff": null, "details": [{"source1": "file list", "source2": "file list", "unified_diff": "@@ -88,8 +88,8 @@\n -rw-r--r-- 0 root (0) root (0) 170 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/changelog.Debian.gz\n -rw-r--r-- 0 root (0) root (0) 4446 2024-10-11 20:38:19.000000 ./usr/share/doc/python3-pywayland/copyright\n drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/lintian/\n drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/lintian/overrides/\n -rw-r--r-- 0 root (0) root (0) 170 2024-10-11 20:38:19.000000 ./usr/share/lintian/overrides/python3-pywayland\n drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/man/\n drwxr-xr-x 0 root (0) root (0) 0 2024-10-11 20:38:19.000000 ./usr/share/man/man1/\n--rw-r--r-- 0 root (0) root (0) 40992 2024-10-11 20:38:19.000000 ./usr/share/man/man1/pywayland-scanner.1.gz\n+-rw-r--r-- 0 root (0) root (0) 41309 2024-10-11 20:38:19.000000 ./usr/share/man/man1/pywayland-scanner.1.gz\n"}, {"source1": "./usr/share/man/man1/pywayland-scanner.1.gz", "source2": "./usr/share/man/man1/pywayland-scanner.1.gz", "unified_diff": null, "details": [{"source1": "pywayland-scanner.1", "source2": "pywayland-scanner.1", "comments": ["Ordering differences only"], "unified_diff": "@@ -1095,429 +1095,657 @@\n .TP\n .B class pywayland.protocol_core.argument.ArgumentType(value, names=, *values, module=None, qualname=None, type=None, start=1, boundary=None)\n .UNINDENT\n .SS Protocol Modules\n .sp\n Wayland protocols built against Wayland 1.21.0 and Wayland Protocols 1.25.\n .SS wayland Module\n-.SS WlDataSource\n+.SS WlDisplay\n .INDENT 0.0\n .TP\n-.B class pywayland.protocol.wayland.WlDataSource\n-Offer to transfer data\n+.B class pywayland.protocol.wayland.WlDisplay\n+Core global object\n .sp\n-The \\fI\\%WlDataSource\\fP object is the source side of a\n-\\fI\\%WlDataOffer\\fP\\&. It is created by the\n-source client in a data transfer and provides a way to describe the offered\n-data and a way to respond to requests to transfer the data.\n+The core global object. This is a special singleton object. It is used\n+for internal Wayland protocol features.\n .INDENT 7.0\n .TP\n-.B offer(mime_type: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n+.B sync() -> \\(aqProxy[WlCallback]\\(aq\n .sp\n Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Add an offered mime type\n+Asynchronous roundtrip\n .sp\n-This request adds a mime type to the set of mime types advertised to\n-targets. Can be called several times to offer multiple types.\n+The sync request asks the server to emit the \\(aqdone\\(aq event on the\n+returned \\fI\\%WlCallback\\fP object. Since\n+requests are handled in\\-order and events are delivered in\\-order, this\n+can be used as a barrier to ensure all previous requests and the\n+resulting events have been handled.\n+.sp\n+The object returned by this request will be destroyed by the compositor\n+after the callback is fired and as such the client must not attempt to\n+use it after that point.\n+.sp\n+The callback_data passed in the callback is undefined and should be\n+ignored.\n .INDENT 7.0\n .TP\n-.B Parameters\n-\\fBmime_type\\fP (\\fIArgumentType.String\\fP) \\-\\- mime type offered by the data source\n+.B Returns\n+\\fI\\%WlCallback\\fP \\-\\- callback object\n+for the sync request\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B destroy() -> \\(aqNone\\(aq\n+.B get_registry() -> \\(aqProxy[WlRegistry]\\(aq\n .sp\n Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-Destroy the data source\n+Get global registry object\n .sp\n-Destroy the data source.\n+This request creates a registry object that allows the client to list\n+and bind the global objects available from the compositor.\n+.sp\n+It should be noted that the server side resources consumed in response\n+to a get_registry request can only be released when the client\n+disconnects, not when the client side proxy is destroyed. Therefore,\n+clients should invoke get_registry as infrequently as possible to avoid\n+wasting memory.\n+.INDENT 7.0\n+.TP\n+.B Returns\n+\\fI\\%WlRegistry\\fP \\-\\- global registry\n+object\n+.UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B set_actions(dnd_actions: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B error(object_id: \\(aqAny\\(aq, code: \\(aqint\\(aq, message: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n .sp\n-Set the available drag\\-and\\-drop actions\n+Fatal error event\n .sp\n-Sets the actions that the source side client supports for this\n-operation. This request may trigger \\fI\\%WlDataSource.action()\\fP and\n-\\fI\\%WlDataOffer.action()\\fP events if the\n-compositor needs to change the selected action.\n+The error event is sent out when a fatal (non\\-recoverable) error has\n+occurred. The object_id argument is the object where the error\n+occurred, most often in response to a request to that object. The code\n+identifies the error and is defined by the object interface. As such,\n+each interface defines its own set of error codes. The message is a\n+brief description of the error, for (debugging) convenience.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBobject_id\\fP (\\fIArgumentType.Object\\fP) \\-\\- object where the error occurred\n+.IP \\(bu 2\n+\\fBcode\\fP (\\fIArgumentType.Uint\\fP) \\-\\- error code\n+.IP \\(bu 2\n+\\fBmessage\\fP (\\fIArgumentType.String\\fP) \\-\\- error description\n+.UNINDENT\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B delete_id(id: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-The dnd_actions argument must contain only values expressed in the\n-\\fBWlDataDeviceManager.dnd_actions()\\fP enum,\n-otherwise it will result in a protocol error.\n+Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n .sp\n-This request must be made once only, and can only be made on sources\n-used in drag\\-and\\-drop, so it must be performed before\n-\\fI\\%WlDataDevice.start_drag()\\fP\\&. Attempting to\n-use the source other than for drag\\-and\\-drop will raise a protocol\n-error.\n+Acknowledge object id deletion\n+.sp\n+This event is used internally by the object ID management logic. When a\n+client deletes an object that it had created, the server will send this\n+event to acknowledge that it has seen the delete request. When the\n+client receives this event, it will know that it can safely reuse the\n+object ID.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBdnd_actions\\fP (\\fIArgumentType.Uint\\fP) \\-\\- actions supported by the data source\n+\\fBid\\fP (\\fIArgumentType.Uint\\fP) \\-\\- deleted object ID\n+.UNINDENT\n .UNINDENT\n .UNINDENT\n+.SS WlCallback\n+.INDENT 0.0\n+.TP\n+.B class pywayland.protocol.wayland.WlCallback\n+Callback object\n+.sp\n+Clients can handle the \\(aqdone\\(aq event to get notified when the related\n+request is done.\n+.sp\n+Note, because \\fI\\%WlCallback\\fP objects are created from multiple\n+independent factory interfaces, the \\fI\\%WlCallback\\fP interface is frozen\n+at version 1.\n .INDENT 7.0\n .TP\n-.B target(mime_type: \\(aqstr | None\\(aq) -> \\(aqNone\\(aq\n+.B done(callback_data: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n .sp\n-A target accepts an offered mime type\n-.sp\n-Sent when a target accepts pointer_focus or motion events. If a target\n-does not accept any of the offered types, type is NULL.\n+Done event\n .sp\n-Used for feedback during drag\\-and\\-drop.\n+Notify the client when the related request is done.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBmime_type\\fP (\\fIArgumentType.String\\fP or \\fINone\\fP) \\-\\- mime type accepted by the target\n+\\fBcallback_data\\fP (\\fIArgumentType.Uint\\fP) \\-\\- request\\-specific data for the callback\n+.UNINDENT\n .UNINDENT\n .UNINDENT\n+.SS WlDataOffer\n+.INDENT 0.0\n+.TP\n+.B class pywayland.protocol.wayland.WlDataOffer\n+Offer to transfer data\n+.sp\n+A \\fI\\%WlDataOffer\\fP represents a piece of data offered for transfer by\n+another client (the source client). It is used by the copy\\-and\\-paste and\n+drag\\-and\\-drop mechanisms. The offer describes the different mime types\n+that the data can be converted to and provides the mechanism for\n+transferring the data directly from the source client.\n .INDENT 7.0\n .TP\n-.B send(mime_type: \\(aqstr\\(aq, fd: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B accept(serial: \\(aqint\\(aq, mime_type: \\(aqstr | None\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Send the data\n+Accept one of the offered mime types\n .sp\n-Request for data from the client. Send the data as the specified mime\n-type over the passed file descriptor, then close it.\n+Indicate that the client can accept the given mime type, or NULL for\n+not accepted.\n+.sp\n+For objects of version 2 or older, this request is used by the client\n+to give feedback whether the client can receive the given mime type, or\n+NULL if none is accepted; the feedback does not determine whether the\n+drag\\-and\\-drop operation succeeds or not.\n+.sp\n+For objects of version 3 or newer, this request determines the final\n+result of the drag\\-and\\-drop operation. If the end result is that no\n+mime types were accepted, the drag\\-and\\-drop operation will be cancelled\n+and the corresponding drag source will receive\n+\\fI\\%WlDataSource.cancelled()\\fP\\&. Clients may still\n+use this event in conjunction with \\fI\\%WlDataSource.action()\\fP for feedback.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBmime_type\\fP (\\fIArgumentType.String\\fP) \\-\\- mime type for the data\n+\\fBserial\\fP (\\fIArgumentType.Uint\\fP) \\-\\- serial number of the accept request\n .IP \\(bu 2\n-\\fBfd\\fP (\\fIArgumentType.FileDescriptor\\fP) \\-\\- file descriptor for the data\n+\\fBmime_type\\fP (\\fIArgumentType.String\\fP or \\fINone\\fP) \\-\\- mime type accepted by the client\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B cancelled() -> \\(aqNone\\(aq\n+.B receive(mime_type: \\(aqstr\\(aq, fd: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 2 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-Selection was cancelled\n+Request that the data is transferred\n .sp\n-This data source is no longer valid. There are several reasons why this\n-could happen:\n+To transfer the offered data, the client issues this request and\n+indicates the mime type it wants to receive. The transfer happens\n+through the passed file descriptor (typically created with the pipe\n+system call). The source client writes the data in the mime type\n+representation requested and then closes the file descriptor.\n+.sp\n+The receiving client reads from the read end of the pipe until EOF and\n+then closes its end, at which point the transfer is complete.\n+.sp\n+This request may happen multiple times for different mime types, both\n+before and after \\fI\\%WlDataDevice.drop()\\fP\\&. Drag\\-and\\-drop\n+destination clients may preemptively fetch data or examine it more\n+closely to determine acceptance.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-The data source has been replaced by another data source.\n-.IP \\(bu 2\n-The drag\\-and\\-drop operation was performed, but the drop destination\n-did not accept any of the mime types offered through\n-\\fI\\%WlDataSource.target()\\fP\\&.\n-.IP \\(bu 2\n-The drag\\-and\\-drop operation was performed, but the drop destination\n-did not select any of the actions present in the mask offered through\n-\\fI\\%WlDataSource.action()\\fP\\&.\n-.IP \\(bu 2\n-The drag\\-and\\-drop operation was performed but didn\\(aqt happen over a\n-surface.\n+\\fBmime_type\\fP (\\fIArgumentType.String\\fP) \\-\\- mime type desired by receiver\n .IP \\(bu 2\n-The compositor cancelled the drag\\-and\\-drop operation (e.g. compositor\n-dependent timeouts to avoid stale drag\\-and\\-drop transfers).\n+\\fBfd\\fP (\\fIArgumentType.FileDescriptor\\fP) \\-\\- file descriptor for data transfer\n .UNINDENT\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B destroy() -> \\(aqNone\\(aq\n .sp\n-The client should clean up and destroy this data source.\n+Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n .sp\n-For objects of version 2 or older, \\fI\\%WlDataSource.cancelled()\\fP\n-will only be emitted if the data source was replaced by another data\n-source.\n+Destroy data offer\n+.sp\n+Destroy the data offer.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B dnd_drop_performed() -> \\(aqNone\\(aq\n+.B finish() -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 3 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 3 (attached to \\fBResource\\fP instance)\n .sp\n-The drag\\-and\\-drop operation physically finished\n+The offer will no longer be used\n .sp\n-The user performed the drop action. This event does not indicate\n-acceptance, \\fI\\%WlDataSource.cancelled()\\fP may still be emitted\n-afterwards if the drop destination does not accept any mime type.\n+Notifies the compositor that the drag destination successfully finished\n+the drag\\-and\\-drop operation.\n .sp\n-However, this event might however not be received if the compositor\n-cancelled the drag\\-and\\-drop operation before this event could happen.\n+Upon receiving this request, the compositor will emit\n+\\fI\\%WlDataSource.dnd_finished()\\fP on the drag\n+source client.\n .sp\n-Note that the data_source may still be used in the future and should\n-not be destroyed here.\n+It is a client error to perform other requests than\n+\\fI\\%WlDataOffer.destroy()\\fP after this one. It is also an error to\n+perform this request after a NULL mime type has been set in\n+\\fI\\%WlDataOffer.accept()\\fP or no action was received through\n+\\fI\\%WlDataOffer.action()\\fP\\&.\n+.sp\n+If \\fI\\%WlDataOffer.finish()\\fP request is received for a non drag and\n+drop operation, the invalid_finish protocol error is raised.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B dnd_finished() -> \\(aqNone\\(aq\n+.B set_actions(dnd_actions: \\(aqint\\(aq, preferred_action: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 4 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 4 (attached to \\fBResource\\fP instance)\n .sp\n-The drag\\-and\\-drop operation concluded\n+Set the available/preferred drag\\-and\\-drop actions\n .sp\n-The drop destination finished interoperating with this data source, so\n-the client is now free to destroy this data source and free all\n-associated data.\n+Sets the actions that the destination side client supports for this\n+operation. This request may trigger the emission of\n+\\fI\\%WlDataSource.action()\\fP and\n+\\fI\\%WlDataOffer.action()\\fP events if the compositor needs to change\n+the selected action.\n .sp\n-If the action used to perform the operation was \\(dqmove\\(dq, the source can\n-now delete the transferred data.\n+This request can be called multiple times throughout the drag\\-and\\-drop\n+operation, typically in response to \\fI\\%WlDataDevice.enter()\\fP or\n+\\fI\\%WlDataDevice.motion()\\fP events.\n+.sp\n+This request determines the final result of the drag\\-and\\-drop\n+operation. If the end result is that no action is accepted, the drag\n+source will receive \\fI\\%WlDataSource.cancelled()\\fP\\&.\n+.sp\n+The dnd_actions argument must contain only values expressed in the\n+\\fBWlDataDeviceManager.dnd_actions()\\fP enum, and\n+the preferred_action argument must only contain one of those values\n+set, otherwise it will result in a protocol error.\n+.sp\n+While managing an \\(dqask\\(dq action, the destination drag\\-and\\-drop client\n+may perform further \\fI\\%WlDataOffer.receive()\\fP requests, and is\n+expected to perform one last \\fI\\%WlDataOffer.set_actions()\\fP request\n+with a preferred action other than \\(dqask\\(dq (and optionally\n+\\fI\\%WlDataOffer.accept()\\fP) before requesting\n+\\fI\\%WlDataOffer.finish()\\fP, in order to convey the action selected by\n+the user. If the preferred action is not in the\n+\\fI\\%WlDataOffer.source_actions()\\fP mask, an error will be raised.\n+.sp\n+If the \\(dqask\\(dq action is dismissed (e.g. user cancellation), the client\n+is expected to perform \\fI\\%WlDataOffer.destroy()\\fP right away.\n+.sp\n+This request can only be made on drag\\-and\\-drop offers, a protocol error\n+will be raised otherwise.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBdnd_actions\\fP (\\fIArgumentType.Uint\\fP) \\-\\- actions supported by the destination client\n+.IP \\(bu 2\n+\\fBpreferred_action\\fP (\\fIArgumentType.Uint\\fP) \\-\\- action preferred by the destination client\n+.UNINDENT\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B offer(mime_type: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n+.sp\n+Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n+.sp\n+Advertise offered mime type\n+.sp\n+Sent immediately after creating the \\fI\\%WlDataOffer\\fP object. One\n+event per offered mime type.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+\\fBmime_type\\fP (\\fIArgumentType.String\\fP) \\-\\- offered mime type\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B source_actions(source_actions: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.sp\n+Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n+.sp\n+Notify the source\\-side available actions\n+.sp\n+This event indicates the actions offered by the data source. It will be\n+sent immediately after creating the \\fI\\%WlDataOffer\\fP object, or\n+anytime the source side changes its offered actions through\n+\\fI\\%WlDataSource.set_actions()\\fP\\&.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+\\fBsource_actions\\fP (\\fIArgumentType.Uint\\fP) \\-\\- actions offered by the data source\n+.UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n .B action(dnd_action: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 5 (attached to \\fBProxy\\fP instance)\n+Event \\-\\- opcode 2 (attached to \\fBProxy\\fP instance)\n .sp\n Notify the selected action\n .sp\n This event indicates the action selected by the compositor after\n matching the source/destination side actions. Only one action (or none)\n will be offered here.\n .sp\n This event can be emitted multiple times during the drag\\-and\\-drop\n-operation, mainly in response to destination side changes through\n-\\fI\\%WlDataOffer.set_actions()\\fP, and as the data\n-device enters/leaves surfaces.\n+operation in response to destination side action changes through\n+\\fI\\%WlDataOffer.set_actions()\\fP\\&.\n .sp\n-It is only possible to receive this event after\n-\\fI\\%WlDataSource.dnd_drop_performed()\\fP if the drag\\-and\\-drop\n-operation ended in an \\(dqask\\(dq action, in which case the final\n-\\fI\\%WlDataSource.action()\\fP event will happen immediately before\n-\\fI\\%WlDataSource.dnd_finished()\\fP\\&.\n+This event will no longer be emitted after \\fI\\%WlDataDevice.drop()\\fP happened on the drag\\-\n+and\\-drop destination, the client must honor the last action received,\n+or the last preferred one set through \\fI\\%WlDataOffer.set_actions()\\fP\n+when handling an \\(dqask\\(dq action.\n .sp\n Compositors may also change the selected action on the fly, mainly in\n response to keyboard modifier changes during the drag\\-and\\-drop\n operation.\n .sp\n-The most recent action received is always the valid one. The chosen\n-action may change alongside negotiation (e.g. an \\(dqask\\(dq action can turn\n-into a \\(dqmove\\(dq operation), so the effects of the final action must\n-always be applied in \\fBWlDataOffer.dnd_finished()\\fP\\&.\n+The most recent action received is always the valid one. Prior to\n+receiving \\fI\\%WlDataDevice.drop()\\fP, the chosen action may\n+change (e.g. due to keyboard modifiers being pressed). At the time of\n+receiving \\fI\\%WlDataDevice.drop()\\fP the drag\\-and\\-drop\n+destination must honor the last action received.\n .sp\n-Clients can trigger cursor surface changes from this point, so they\n-reflect the current action.\n+Action changes may still happen after \\fI\\%WlDataDevice.drop()\\fP, especially on \\(dqask\\(dq\n+actions, where the drag\\-and\\-drop destination may choose another action\n+afterwards. Action changes happening at this stage are always the\n+result of inter\\-client negotiation, the compositor shall no longer be\n+able to induce a different action.\n+.sp\n+Upon \\(dqask\\(dq actions, it is expected that the drag\\-and\\-drop destination\n+may potentially choose a different action and/or mime type, based on\n+\\fI\\%WlDataOffer.source_actions()\\fP and finally chosen by the user\n+(e.g. popping up a menu with the available options). The final\n+\\fI\\%WlDataOffer.set_actions()\\fP and \\fI\\%WlDataOffer.accept()\\fP\n+requests must happen before the call to \\fI\\%WlDataOffer.finish()\\fP\\&.\n .INDENT 7.0\n .TP\n .B Parameters\n \\fBdnd_action\\fP (\\fIArgumentType.Uint\\fP) \\-\\- action selected by the compositor\n .UNINDENT\n .UNINDENT\n .UNINDENT\n-.SS WlSubsurface\n+.SS WlTouch\n .INDENT 0.0\n .TP\n-.B class pywayland.protocol.wayland.WlSubsurface\n-Sub\\-surface interface to a \\fI\\%WlSurface\\fP\n-.sp\n-An additional interface to a \\fI\\%WlSurface\\fP\n-object, which has been made a sub\\-surface. A sub\\-surface has one parent\n-surface. A sub\\-surface\\(aqs size and position are not limited to that of the\n-parent. Particularly, a sub\\-surface is not automatically clipped to its\n-parent\\(aqs area.\n-.sp\n-A sub\\-surface becomes mapped, when a non\\-NULL\n-\\fI\\%WlBuffer\\fP is applied and the parent\n-surface is mapped. The order of which one happens first is irrelevant. A\n-sub\\-surface is hidden if the parent becomes hidden, or if a NULL\n-\\fI\\%WlBuffer\\fP is applied. These rules apply\n-recursively through the tree of surfaces.\n-.sp\n-The behaviour of a \\fI\\%WlSurface.commit()\\fP request on a sub\\-surface\n-depends on the sub\\-surface\\(aqs mode. The possible modes are synchronized and\n-desynchronized, see methods \\fI\\%WlSubsurface.set_sync()\\fP and\n-\\fI\\%WlSubsurface.set_desync()\\fP\\&. Synchronized mode caches the\n-\\fI\\%WlSurface\\fP state to be applied when the\n-parent\\(aqs state gets applied, and desynchronized mode applies the pending\n-\\fI\\%WlSurface\\fP state directly. A sub\\-\n-surface is initially in the synchronized mode.\n-.sp\n-Sub\\-surfaces also have another kind of state, which is managed by\n-\\fI\\%WlSubsurface\\fP requests, as opposed to\n-\\fI\\%WlSurface\\fP requests. This state\n-includes the sub\\-surface position relative to the parent surface\n-(\\fI\\%WlSubsurface.set_position()\\fP), and the stacking order of the parent\n-and its sub\\-surfaces (\\fI\\%WlSubsurface.place_above()\\fP and .place_below).\n-This state is applied when the parent surface\\(aqs\n-\\fI\\%WlSurface\\fP state is applied, regardless\n-of the sub\\-surface\\(aqs mode. As the exception, set_sync and set_desync are\n-effective immediately.\n-.sp\n-The main surface can be thought to be always in desynchronized mode, since\n-it does not have a parent in the sub\\-surfaces sense.\n-.sp\n-Even if a sub\\-surface is in desynchronized mode, it will behave as in\n-synchronized mode, if its parent surface behaves as in synchronized mode.\n-This rule is applied recursively throughout the tree of surfaces. This\n-means, that one can set a sub\\-surface into synchronized mode, and then\n-assume that all its child and grand\\-child sub\\-surfaces are synchronized,\n-too, without explicitly setting them.\n+.B class pywayland.protocol.wayland.WlTouch\n+Touchscreen input device\n .sp\n-Destroying a sub\\-surface takes effect immediately. If you need to\n-synchronize the removal of a sub\\-surface to the parent surface update,\n-unmap the sub\\-surface first by attaching a NULL\n-\\fI\\%WlBuffer\\fP, update parent, and then\n-destroy the sub\\-surface.\n+The \\fI\\%WlTouch\\fP interface represents a touchscreen associated with a\n+seat.\n .sp\n-If the parent \\fI\\%WlSurface\\fP object is\n-destroyed, the sub\\-surface is unmapped.\n+Touch interactions can consist of one or more contacts. For each contact, a\n+series of events is generated, starting with a down event, followed by zero\n+or more motion events, and ending with an up event. Events relating to the\n+same contact point can be identified by the ID of the sequence.\n+.INDENT 7.0\n+.TP\n+.B release() -> \\(aqNone\\(aq\n .sp\n-A sub\\-surface never has the keyboard focus of any seat.\n+Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-The \\fI\\%WlSurface.offset()\\fP request is ignored: clients\n-must use set_position instead to move the sub\\-surface.\n+Release the touch object\n+.UNINDENT\n .INDENT 7.0\n .TP\n-.B destroy() -> \\(aqNone\\(aq\n+.B down(serial: \\(aqint\\(aq, time: \\(aqint\\(aq, surface: \\(aqWlSurface\\(aq, id: \\(aqint\\(aq, x: \\(aqfloat\\(aq, y: \\(aqfloat\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n .sp\n-Remove sub\\-surface interface\n+Touch down event and beginning of a touch sequence\n .sp\n-The sub\\-surface interface is removed from the\n-\\fI\\%WlSurface\\fP object that was turned\n-into a sub\\-surface with a \\fI\\%WlSubcompositor.get_subsurface()\\fP request.\n-The wl_surface\\(aqs association to the parent is deleted. The\n-\\fI\\%WlSurface\\fP is unmapped immediately.\n+A new touch point has appeared on the surface. This touch point is\n+assigned a unique ID. Future events from this touch point reference\n+this ID. The ID ceases to be valid after a touch up event and may be\n+reused in the future.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBserial\\fP (\\fIArgumentType.Uint\\fP) \\-\\- serial number of the touch down event\n+.IP \\(bu 2\n+\\fBtime\\fP (\\fIArgumentType.Uint\\fP) \\-\\- timestamp with millisecond granularity\n+.IP \\(bu 2\n+\\fBsurface\\fP (\\fI\\%WlSurface\\fP) \\-\\- surface touched\n+.IP \\(bu 2\n+\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n+.IP \\(bu 2\n+\\fBx\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- surface\\-local x coordinate\n+.IP \\(bu 2\n+\\fBy\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- surface\\-local y coordinate\n+.UNINDENT\n+.UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B set_position(x: \\(aqint\\(aq, y: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B up(serial: \\(aqint\\(aq, time: \\(aqint\\(aq, id: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n .sp\n-Reposition the sub\\-surface\n+End of a touch event sequence\n .sp\n-This schedules a sub\\-surface position change. The sub\\-surface will be\n-moved so that its origin (top left corner pixel) will be at the\n-location x, y of the parent surface coordinate system. The coordinates\n-are not restricted to the parent surface area. Negative values are\n-allowed.\n+The touch point has disappeared. No further events will be sent for\n+this touch point and the touch point\\(aqs ID is released and may be reused\n+in a future touch down event.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBserial\\fP (\\fIArgumentType.Uint\\fP) \\-\\- serial number of the touch up event\n+.IP \\(bu 2\n+\\fBtime\\fP (\\fIArgumentType.Uint\\fP) \\-\\- timestamp with millisecond granularity\n+.IP \\(bu 2\n+\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n+.UNINDENT\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B motion(time: \\(aqint\\(aq, id: \\(aqint\\(aq, x: \\(aqfloat\\(aq, y: \\(aqfloat\\(aq) -> \\(aqNone\\(aq\n .sp\n-The scheduled coordinates will take effect whenever the state of the\n-parent surface is applied.\n+Event \\-\\- opcode 2 (attached to \\fBProxy\\fP instance)\n .sp\n-If more than one set_position request is invoked by the client before\n-the commit of the parent surface, the position of a new request always\n-replaces the scheduled position from any previous request.\n+Update of touch point coordinates\n .sp\n-The initial position is 0, 0.\n+A touch point has changed coordinates.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- x coordinate in the parent surface\n+\\fBtime\\fP (\\fIArgumentType.Uint\\fP) \\-\\- timestamp with millisecond granularity\n .IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- y coordinate in the parent surface\n+\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n+.IP \\(bu 2\n+\\fBx\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- surface\\-local x coordinate\n+.IP \\(bu 2\n+\\fBy\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- surface\\-local y coordinate\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B place_above(sibling: \\(aqWlSurface\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n+.B frame() -> \\(aqNone\\(aq\n .sp\n-Restack the sub\\-surface\n+Event \\-\\- opcode 3 (attached to \\fBProxy\\fP instance)\n .sp\n-This sub\\-surface is taken from the stack, and put back just above the\n-reference surface, changing the z\\-order of the sub\\-surfaces. The\n-reference surface must be one of the sibling surfaces, or the parent\n-surface. Using any other surface, including this sub\\-surface, will\n-cause a protocol error.\n+End of touch frame event\n .sp\n-The z\\-order is double\\-buffered. Requests are handled in order and\n-applied immediately to a pending state. The final pending state is\n-copied to the active state the next time the state of the parent\n-surface is applied.\n+Indicates the end of a set of events that logically belong together. A\n+client is expected to accumulate the data in all events within the\n+frame before proceeding.\n .sp\n-A new sub\\-surface is initially added as the top\\-most in the stack of\n-its siblings and parent.\n+A \\fI\\%WlTouch.frame()\\fP terminates at least one event but otherwise\n+no guarantee is provided about the set of events within a frame. A\n+client must assume that any state not updated in a frame is unchanged\n+from the previously known state.\n+.UNINDENT\n .INDENT 7.0\n .TP\n-.B Parameters\n-\\fBsibling\\fP (\\fI\\%WlSurface\\fP) \\-\\- the reference surface\n-.UNINDENT\n+.B cancel() -> \\(aqNone\\(aq\n+.sp\n+Event \\-\\- opcode 4 (attached to \\fBProxy\\fP instance)\n+.sp\n+Touch session cancelled\n+.sp\n+Sent if the compositor decides the touch stream is a global gesture. No\n+further events are sent to the clients from that particular gesture.\n+Touch cancellation applies to all touch points currently active on this\n+client\\(aqs surface. The client is responsible for finalizing the touch\n+points, future touch points on this surface may reuse the touch point\n+ID.\n+.sp\n+No frame event is required after the cancel event.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B place_below(sibling: \\(aqWlSurface\\(aq) -> \\(aqNone\\(aq\n+.B shape(id: \\(aqint\\(aq, major: \\(aqfloat\\(aq, minor: \\(aqfloat\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 3 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 5 (attached to \\fBProxy\\fP instance)\n .sp\n-Restack the sub\\-surface\n+Update shape of touch point\n .sp\n-The sub\\-surface is placed just below the reference surface. See\n-\\fI\\%WlSubsurface.place_above()\\fP\\&.\n+Sent when a touchpoint has changed its shape.\n+.sp\n+This event does not occur on its own. It is sent before a\n+\\fI\\%WlTouch.frame()\\fP event and carries the new shape information for\n+any previously reported, or new touch points of that frame.\n+.sp\n+Other events describing the touch point such as \\fI\\%WlTouch.down()\\fP,\n+\\fI\\%WlTouch.motion()\\fP or \\fI\\%WlTouch.orientation()\\fP may be sent\n+within the same \\fI\\%WlTouch.frame()\\fP\\&. A client should treat these\n+events as a single logical touch point update. The order of\n+\\fI\\%WlTouch.shape()\\fP, \\fI\\%WlTouch.orientation()\\fP and\n+\\fI\\%WlTouch.motion()\\fP is not guaranteed. A \\fI\\%WlTouch.down()\\fP\n+event is guaranteed to occur before the first \\fI\\%WlTouch.shape()\\fP\n+event for this touch ID but both events may occur within the same\n+\\fI\\%WlTouch.frame()\\fP\\&.\n+.sp\n+A touchpoint shape is approximated by an ellipse through the major and\n+minor axis length. The major axis length describes the longer diameter\n+of the ellipse, while the minor axis length describes the shorter\n+diameter. Major and minor are orthogonal and both are specified in\n+surface\\-local coordinates. The center of the ellipse is always at the\n+touchpoint location as reported by \\fI\\%WlTouch.down()\\fP or\n+\\fBWlTouch.move()\\fP\\&.\n+.sp\n+This event is only sent by the compositor if the touch device supports\n+shape reports. The client has to make reasonable assumptions about the\n+shape if it did not receive this event.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBsibling\\fP (\\fI\\%WlSurface\\fP) \\-\\- the reference surface\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n+.IP \\(bu 2\n+\\fBmajor\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- length of the major axis in surface\\-local coordinates\n+.IP \\(bu 2\n+\\fBminor\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- length of the minor axis in surface\\-local coordinates\n+.UNINDENT\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B set_sync() -> \\(aqNone\\(aq\n+.B orientation(id: \\(aqint\\(aq, orientation: \\(aqfloat\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 4 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 6 (attached to \\fBProxy\\fP instance)\n .sp\n-Set sub\\-surface to synchronized mode\n+Update orientation of touch point\n .sp\n-Change the commit behaviour of the sub\\-surface to synchronized mode,\n-also described as the parent dependent mode.\n+Sent when a touchpoint has changed its orientation.\n .sp\n-In synchronized mode, \\fI\\%WlSurface.commit()\\fP on a sub\\-surface will\n-accumulate the committed state in a cache, but the state will not be\n-applied and hence will not change the compositor output. The cached\n-state is applied to the sub\\-surface immediately after the parent\n-surface\\(aqs state is applied. This ensures atomic updates of the parent\n-and all its synchronized sub\\-surfaces. Applying the cached state will\n-invalidate the cache, so further parent surface commits do not\n-(re\\-)apply old state.\n+This event does not occur on its own. It is sent before a\n+\\fI\\%WlTouch.frame()\\fP event and carries the new shape information for\n+any previously reported, or new touch points of that frame.\n .sp\n-See \\fI\\%WlSubsurface\\fP for the recursive effect of this mode.\n-.UNINDENT\n+Other events describing the touch point such as \\fI\\%WlTouch.down()\\fP,\n+\\fI\\%WlTouch.motion()\\fP or \\fI\\%WlTouch.shape()\\fP may be sent within\n+the same \\fI\\%WlTouch.frame()\\fP\\&. A client should treat these events as\n+a single logical touch point update. The order of\n+\\fI\\%WlTouch.shape()\\fP, \\fI\\%WlTouch.orientation()\\fP and\n+\\fI\\%WlTouch.motion()\\fP is not guaranteed. A \\fI\\%WlTouch.down()\\fP\n+event is guaranteed to occur before the first\n+\\fI\\%WlTouch.orientation()\\fP event for this touch ID but both events\n+may occur within the same \\fI\\%WlTouch.frame()\\fP\\&.\n+.sp\n+The orientation describes the clockwise angle of a touchpoint\\(aqs major\n+axis to the positive surface y\\-axis and is normalized to the \\-180 to\n++180 degree range. The granularity of orientation depends on the touch\n+device, some devices only support binary rotation values between 0 and\n+90 degrees.\n+.sp\n+This event is only sent by the compositor if the touch device supports\n+orientation reports.\n .INDENT 7.0\n .TP\n-.B set_desync() -> \\(aqNone\\(aq\n+.B Parameters\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n+.IP \\(bu 2\n+\\fBorientation\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- angle between major axis and positive surface y\\-axis in degrees\n+.UNINDENT\n+.UNINDENT\n+.UNINDENT\n+.UNINDENT\n+.SS WlCompositor\n+.INDENT 0.0\n+.TP\n+.B class pywayland.protocol.wayland.WlCompositor\n+The compositor singleton\n .sp\n-Request \\-\\- opcode 5 (attached to \\fBResource\\fP instance)\n+A compositor. This object is a singleton global. The compositor is in\n+charge of combining the contents of multiple surfaces into one displayable\n+output.\n+.INDENT 7.0\n+.TP\n+.B create_surface() -> \\(aqProxy[WlSurface]\\(aq\n .sp\n-Set sub\\-surface to desynchronized mode\n+Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Change the commit behaviour of the sub\\-surface to desynchronized mode,\n-also described as independent or freely running mode.\n+Create new surface\n .sp\n-In desynchronized mode, \\fI\\%WlSurface.commit()\\fP on a sub\\-surface will\n-apply the pending state directly, without caching, as happens normally\n-with a \\fI\\%WlSurface\\fP\\&. Calling\n-\\fI\\%WlSurface.commit()\\fP on the parent surface\n-has no effect on the sub\\-surface\\(aqs\n-\\fI\\%WlSurface\\fP state. This mode allows\n-a sub\\-surface to be updated on its own.\n+Ask the compositor to create a new surface.\n+.INDENT 7.0\n+.TP\n+.B Returns\n+\\fI\\%WlSurface\\fP \\-\\- the new surface\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B create_region() -> \\(aqProxy[WlRegion]\\(aq\n .sp\n-If cached state exists when \\fI\\%WlSurface.commit()\\fP is called in\n-desynchronized mode, the pending state is added to the cached state,\n-and applied as a whole. This invalidates the cache.\n+Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-Note: even if a sub\\-surface is set to desynchronized, a parent sub\\-\n-surface may override it to behave as synchronized. For details, see\n-\\fI\\%WlSubsurface\\fP\\&.\n+Create new region\n .sp\n-If a surface\\(aqs parent surface behaves as desynchronized, then the\n-cached state is applied on set_desync.\n+Ask the compositor to create a new region.\n+.INDENT 7.0\n+.TP\n+.B Returns\n+\\fI\\%WlRegion\\fP \\-\\- the new region\n+.UNINDENT\n .UNINDENT\n .UNINDENT\n .SS WlDataDevice\n .INDENT 0.0\n .TP\n .B class pywayland.protocol.wayland.WlDataDevice\n Data transfer device\n@@ -1745,14 +1973,104 @@\n .INDENT 7.0\n .TP\n .B Parameters\n \\fBid\\fP (\\fI\\%WlDataOffer\\fP or \\fINone\\fP) \\-\\- selection data_offer object\n .UNINDENT\n .UNINDENT\n .UNINDENT\n+.SS WlShmPool\n+.INDENT 0.0\n+.TP\n+.B class pywayland.protocol.wayland.WlShmPool\n+A shared memory pool\n+.sp\n+The \\fI\\%WlShmPool\\fP object encapsulates a piece of memory shared between\n+the compositor and client. Through the \\fI\\%WlShmPool\\fP object, the\n+client can allocate shared memory\n+\\fI\\%WlBuffer\\fP objects. All objects created\n+through the same pool share the same underlying mapped memory. Reusing the\n+mapped memory avoids the setup/teardown overhead and is useful when\n+interactively resizing a surface or for many small buffers.\n+.INDENT 7.0\n+.TP\n+.B create_buffer(offset: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq, stride: \\(aqint\\(aq, format: \\(aqint\\(aq) -> \\(aqProxy[WlBuffer]\\(aq\n+.sp\n+Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+.sp\n+Create a buffer from the pool\n+.sp\n+Create a \\fI\\%WlBuffer\\fP object from the\n+pool.\n+.sp\n+The buffer is created offset bytes into the pool and has width and\n+height as specified. The stride argument specifies the number of bytes\n+from the beginning of one row to the beginning of the next. The format\n+is the pixel format of the buffer and must be one of those advertised\n+through the \\fI\\%WlShm.format()\\fP event.\n+.sp\n+A buffer will keep a reference to the pool it was created from so it is\n+valid to destroy the pool immediately after creating a buffer from it.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBoffset\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer byte offset within the pool\n+.IP \\(bu 2\n+\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer width, in pixels\n+.IP \\(bu 2\n+\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer height, in pixels\n+.IP \\(bu 2\n+\\fBstride\\fP (\\fIArgumentType.Int\\fP) \\-\\- number of bytes from the beginning of one row to the beginning of\n+the next row\n+.IP \\(bu 2\n+\\fBformat\\fP (\\fIArgumentType.Uint\\fP) \\-\\- buffer pixel format\n+.UNINDENT\n+.TP\n+.B Returns\n+\\fI\\%WlBuffer\\fP \\-\\- buffer to create\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B destroy() -> \\(aqNone\\(aq\n+.sp\n+Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n+.sp\n+Destroy the pool\n+.sp\n+Destroy the shared memory pool.\n+.sp\n+The mmapped memory will be released when all buffers that have been\n+created from this pool are gone.\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B resize(size: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.sp\n+Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n+.sp\n+Change the size of the pool mapping\n+.sp\n+This request will cause the server to remap the backing memory for the\n+pool from the file descriptor passed when the pool was created, but\n+using the new size. This request can only be used to make the pool\n+bigger.\n+.sp\n+This request only changes the amount of bytes that are mmapped by the\n+server and does not touch the file corresponding to the file descriptor\n+passed at creation time. It is the client\\(aqs responsibility to ensure\n+that the file is at least as big as the new pool size.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+\\fBsize\\fP (\\fIArgumentType.Int\\fP) \\-\\- new size of the pool, in bytes\n+.UNINDENT\n+.UNINDENT\n+.UNINDENT\n .SS WlShellSurface\n .INDENT 0.0\n .TP\n .B class pywayland.protocol.wayland.WlShellSurface\n Desktop\\-style metadata interface\n .sp\n An interface that may be implemented by a\n@@ -2102,1008 +2420,567 @@\n Popup interaction is done\n .sp\n The popup_done event is sent out when a popup grab is broken, that is,\n when the user clicks a surface that doesn\\(aqt belong to the client owning\n the popup surface.\n .UNINDENT\n .UNINDENT\n-.SS WlSurface\n+.SS WlOutput\n .INDENT 0.0\n .TP\n-.B class pywayland.protocol.wayland.WlSurface\n-An onscreen surface\n-.sp\n-A surface is a rectangular area that may be displayed on zero or more\n-outputs, and shown any number of times at the compositor\\(aqs discretion. They\n-can present wl_buffers, receive user input, and define a local coordinate\n-system.\n-.sp\n-The size of a surface (and relative positions on it) is described in\n-surface\\-local coordinates, which may differ from the buffer coordinates of\n-the pixel content, in case a buffer_transform or a buffer_scale is used.\n-.sp\n-A surface without a \\(dqrole\\(dq is fairly useless: a compositor does not know\n-where, when or how to present it. The role is the purpose of a\n-\\fI\\%WlSurface\\fP\\&. Examples of roles are a cursor for a pointer (as set by\n-\\fI\\%WlPointer.set_cursor()\\fP), a drag icon\n-(\\fI\\%WlDataDevice.start_drag()\\fP), a sub\\-surface\n-(\\fI\\%WlSubcompositor.get_subsurface()\\fP), and a window\n-as defined by a shell protocol (e.g. \\fI\\%WlShell.get_shell_surface()\\fP).\n-.sp\n-A surface can have only one role at a time. Initially a \\fI\\%WlSurface\\fP\n-does not have a role. Once a \\fI\\%WlSurface\\fP is given a role, it is set\n-permanently for the whole lifetime of the \\fI\\%WlSurface\\fP object. Giving\n-the current role again is allowed, unless explicitly forbidden by the\n-relevant interface specification.\n-.sp\n-Surface roles are given by requests in other interfaces such as\n-\\fI\\%WlPointer.set_cursor()\\fP\\&. The request should\n-explicitly mention that this request gives a role to a \\fI\\%WlSurface\\fP\\&.\n-Often, this request also creates a new protocol object that represents the\n-role and adds additional functionality to \\fI\\%WlSurface\\fP\\&. When a client\n-wants to destroy a \\fI\\%WlSurface\\fP, they must destroy this role object\n-before the \\fI\\%WlSurface\\fP, otherwise a defunct_role_object error is\n-sent.\n+.B class pywayland.protocol.wayland.WlOutput\n+Compositor output region\n .sp\n-Destroying the role object does not remove the role from the\n-\\fI\\%WlSurface\\fP, but it may stop the \\fI\\%WlSurface\\fP from \\(dqplaying\n-the role\\(dq. For instance, if a\n-\\fI\\%WlSubsurface\\fP object is destroyed, the\n-\\fI\\%WlSurface\\fP it was created for will be unmapped and forget its\n-position and z\\-order. It is allowed to create a\n-\\fI\\%WlSubsurface\\fP for the same\n-\\fI\\%WlSurface\\fP again, but it is not allowed to use the\n-\\fI\\%WlSurface\\fP as a cursor (cursor is a different role than sub\\-\n-surface, and role switching is not allowed).\n+An output describes part of the compositor geometry. The compositor works\n+in the \\(aqcompositor coordinate system\\(aq and an output corresponds to a\n+rectangular area in that space that is actually visible. This typically\n+corresponds to a monitor that displays part of the compositor space. This\n+object is published as global during start up, or when a monitor is\n+hotplugged.\n .INDENT 7.0\n .TP\n-.B destroy() -> \\(aqNone\\(aq\n+.B release() -> \\(aqNone\\(aq\n .sp\n Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Delete surface\n+Release the output object\n .sp\n-Deletes the surface and invalidates its object ID.\n+Using this request a client can tell the server that it is not going to\n+use the output object anymore.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B attach(buffer: \\(aqWlBuffer | None\\(aq, x: \\(aqint\\(aq, y: \\(aqint\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n-.sp\n-Set the surface contents\n-.sp\n-Set a buffer as the content of this surface.\n-.sp\n-The new size of the surface is calculated based on the buffer size\n-transformed by the inverse buffer_transform and the inverse\n-buffer_scale. This means that at commit time the supplied buffer size\n-must be an integer multiple of the buffer_scale. If that\\(aqs not the\n-case, an invalid_size error is sent.\n-.sp\n-The x and y arguments specify the location of the new pending buffer\\(aqs\n-upper left corner, relative to the current buffer\\(aqs upper left corner,\n-in surface\\-local coordinates. In other words, the x and y, combined\n-with the new surface size define in which directions the surface\\(aqs size\n-changes. Setting anything other than 0 as x and y arguments is\n-discouraged, and should instead be replaced with using the separate\n-\\fI\\%WlSurface.offset()\\fP request.\n-.sp\n-When the bound \\fI\\%WlSurface\\fP version is 5 or higher, passing any\n-non\\-zero x or y is a protocol violation, and will result in an\n-\\(aqinvalid_offset\\(aq error being raised. The x and y arguments are ignored\n-and do not change the pending state. To achieve equivalent semantics,\n-use \\fI\\%WlSurface.offset()\\fP\\&.\n+.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\n .sp\n-Surface contents are double\\-buffered state, see\n-\\fI\\%WlSurface.commit()\\fP\\&.\n+Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n .sp\n-The initial surface contents are void; there is no content.\n-\\fI\\%WlSurface.attach()\\fP assigns the given\n-\\fI\\%WlBuffer\\fP as the pending\n-\\fI\\%WlBuffer\\fP\\&.\n-\\fI\\%WlSurface.commit()\\fP makes the pending\n-\\fI\\%WlBuffer\\fP the new surface contents,\n-and the size of the surface becomes the size calculated from the\n-\\fI\\%WlBuffer\\fP, as described above.\n-After commit, there is no pending buffer until the next attach.\n+Properties of the output\n .sp\n-Committing a pending \\fI\\%WlBuffer\\fP\n-allows the compositor to read the pixels in the\n-\\fI\\%WlBuffer\\fP\\&. The compositor may\n-access the pixels at any time after the \\fI\\%WlSurface.commit()\\fP\n-request. When the compositor will not access the pixels anymore, it\n-will send the \\fI\\%WlBuffer.release()\\fP event. Only after\n-receiving \\fI\\%WlBuffer.release()\\fP, the client may reuse\n-the \\fI\\%WlBuffer\\fP\\&. A\n-\\fI\\%WlBuffer\\fP that has been attached\n-and then replaced by another attach instead of committed will not\n-receive a release event, and is not used by the compositor.\n+The geometry event describes geometric properties of the output. The\n+event is sent when binding to the output object and whenever any of the\n+properties change.\n .sp\n-If a pending \\fI\\%WlBuffer\\fP has been\n-committed to more than one \\fI\\%WlSurface\\fP, the delivery of\n-\\fI\\%WlBuffer.release()\\fP events becomes\n-undefined. A well behaved client should not rely on\n-\\fI\\%WlBuffer.release()\\fP events in this case.\n-Alternatively, a client could create multiple\n-\\fI\\%WlBuffer\\fP objects from the same\n-backing storage or use wp_linux_buffer_release.\n+The physical size can be set to zero if it doesn\\(aqt make sense for this\n+output (e.g. for projectors or virtual outputs).\n .sp\n-Destroying the \\fI\\%WlBuffer\\fP after\n-\\fI\\%WlBuffer.release()\\fP does not change the\n-surface contents. Destroying the\n-\\fI\\%WlBuffer\\fP before\n-\\fI\\%WlBuffer.release()\\fP is allowed as long as\n-the underlying buffer storage isn\\(aqt re\\-used (this can happen e.g. on\n-client process termination). However, if the client destroys the\n-\\fI\\%WlBuffer\\fP before receiving the\n-\\fI\\%WlBuffer.release()\\fP event and mutates the\n-underlying buffer storage, the surface contents become undefined\n-immediately.\n+The geometry event will be followed by a done event (starting from\n+version 2).\n .sp\n-If \\fI\\%WlSurface.attach()\\fP is sent with a NULL\n-\\fI\\%WlBuffer\\fP, the following\n-\\fI\\%WlSurface.commit()\\fP will remove the surface content.\n+Clients should use \\fI\\%WlSurface.preferred_buffer_transform()\\fP\n+instead of the transform advertised by this event to find the preferred\n+buffer transform to use for a surface.\n .sp\n-If a pending \\fI\\%WlBuffer\\fP has been\n-destroyed, the result is not specified. Many compositors are known to\n-remove the surface content on the following \\fI\\%WlSurface.commit()\\fP,\n-but this behaviour is not universal. Clients seeking to maximise\n-compatibility should not destroy pending buffers and should ensure that\n-they explicitly remove content from surfaces, even after destroying\n-buffers.\n+Note: \\fI\\%WlOutput\\fP only advertises partial information about the\n+output position and identification. Some compositors, for instance\n+those not implementing a desktop\\-style output layout or those exposing\n+virtual outputs, might fake this information. Instead of using x and y,\n+clients should use xdg_output.logical_position. Instead of using make\n+and model, clients should use name and description.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBbuffer\\fP (\\fI\\%WlBuffer\\fP or \\fINone\\fP) \\-\\- buffer of surface contents\n+\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- x position within the global compositor space\n .IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local x coordinate\n+\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- y position within the global compositor space\n .IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local y coordinate\n+\\fBphysical_width\\fP (\\fIArgumentType.Int\\fP) \\-\\- width in millimeters of the output\n+.IP \\(bu 2\n+\\fBphysical_height\\fP (\\fIArgumentType.Int\\fP) \\-\\- height in millimeters of the output\n+.IP \\(bu 2\n+\\fBsubpixel\\fP (\\fIArgumentType.Int\\fP) \\-\\- subpixel orientation of the output\n+.IP \\(bu 2\n+\\fBmake\\fP (\\fIArgumentType.String\\fP) \\-\\- textual description of the manufacturer\n+.IP \\(bu 2\n+\\fBmodel\\fP (\\fIArgumentType.String\\fP) \\-\\- textual description of the model\n+.IP \\(bu 2\n+\\fBtransform\\fP (\\fIArgumentType.Int\\fP) \\-\\- additional transformation applied to buffer contents during\n+presentation\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B damage(x: \\(aqint\\(aq, y: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B mode(flags: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq, refresh: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n .sp\n-Mark part of the surface damaged\n+Advertise available modes for the output\n .sp\n-This request is used to describe the regions where the pending buffer\n-is different from the current surface contents, and where the surface\n-therefore needs to be repainted. The compositor ignores the parts of\n-the damage that fall outside of the surface.\n+The mode event describes an available mode for the output.\n .sp\n-Damage is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n+The event is sent when binding to the output object and there will\n+always be one mode, the current mode. The event is sent again if an\n+output changes mode, for the mode that is now current. In other words,\n+the current mode is always the last mode that was received with the\n+current flag set.\n .sp\n-The damage rectangle is specified in surface\\-local coordinates, where x\n-and y specify the upper left corner of the damage rectangle.\n+Non\\-current modes are deprecated. A compositor can decide to only\n+advertise the current mode and never send other modes. Clients should\n+not rely on non\\-current modes.\n .sp\n-The initial value for pending damage is empty: no damage.\n-\\fI\\%WlSurface.damage()\\fP adds pending damage: the new pending damage\n-is the union of old pending damage and the given rectangle.\n+The size of a mode is given in physical hardware units of the output\n+device. This is not necessarily the same as the output size in the\n+global compositor space. For instance, the output may be scaled, as\n+described in \\fI\\%WlOutput.scale()\\fP, or transformed, as described in\n+\\fBWlOutput.transform()\\fP\\&. Clients willing to retrieve the output\n+size in the global compositor space should use xdg_output.logical_size\n+instead.\n .sp\n-\\fI\\%WlSurface.commit()\\fP assigns pending damage as the current\n-damage, and clears pending damage. The server will clear the current\n-damage as it repaints the surface.\n+The vertical refresh rate can be set to zero if it doesn\\(aqt make sense\n+for this output (e.g. for virtual outputs).\n .sp\n-Note! New clients should not use this request. Instead damage can be\n-posted with \\fI\\%WlSurface.damage_buffer()\\fP which uses buffer\n-coordinates instead of surface coordinates.\n+The mode event will be followed by a done event (starting from version\n+2).\n+.sp\n+Clients should not use the refresh rate to schedule frames. Instead,\n+they should use the \\fI\\%WlSurface.frame()\\fP event or the\n+presentation\\-time protocol.\n+.sp\n+Note: this information is not always meaningful for all outputs. Some\n+compositors, such as those exposing virtual outputs, might fake the\n+refresh rate or the size.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local x coordinate\n+\\fBflags\\fP (\\fIArgumentType.Uint\\fP) \\-\\- bitfield of mode flags\n .IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local y coordinate\n+\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- width of the mode in hardware units\n .IP \\(bu 2\n-\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- width of damage rectangle\n+\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- height of the mode in hardware units\n .IP \\(bu 2\n-\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- height of damage rectangle\n-.UNINDENT\n-.UNINDENT\n+\\fBrefresh\\fP (\\fIArgumentType.Int\\fP) \\-\\- vertical refresh rate in mHz\n .UNINDENT\n-.INDENT 7.0\n-.TP\n-.B frame() -> \\(aqProxy[WlCallback]\\(aq\n-.sp\n-Request \\-\\- opcode 3 (attached to \\fBResource\\fP instance)\n-.sp\n-Request a frame throttling hint\n-.sp\n-Request a notification when it is a good time to start drawing a new\n-frame, by creating a frame callback. This is useful for throttling\n-redrawing operations, and driving animations.\n-.sp\n-When a client is animating on a \\fI\\%WlSurface\\fP, it can use the\n-\\(aqframe\\(aq request to get notified when it is a good time to draw and\n-commit the next frame of animation. If the client commits an update\n-earlier than that, it is likely that some updates will not make it to\n-the display, and the client is wasting resources by drawing too often.\n-.sp\n-The frame request will take effect on the next\n-\\fI\\%WlSurface.commit()\\fP\\&. The notification will only be posted for\n-one frame unless requested again. For a \\fI\\%WlSurface\\fP, the\n-notifications are posted in the order the frame requests were\n-committed.\n-.sp\n-The server must send the notifications so that a client will not send\n-excessive updates, while still allowing the highest possible update\n-rate for clients that wait for the reply before drawing again. The\n-server should give some time for the client to draw and commit after\n-sending the frame callback events to let it hit the next output\n-refresh.\n-.sp\n-A server should avoid signaling the frame callbacks if the surface is\n-not visible in any way, e.g. the surface is off\\-screen, or completely\n-obscured by other opaque surfaces.\n-.sp\n-The object returned by this request will be destroyed by the compositor\n-after the callback is fired and as such the client must not attempt to\n-use it after that point.\n-.sp\n-The callback_data passed in the callback is the current time, in\n-milliseconds, with an undefined base.\n-.INDENT 7.0\n-.TP\n-.B Returns\n-\\fI\\%WlCallback\\fP \\-\\- callback object\n-for the frame request\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B set_opaque_region(region: \\(aqWlRegion | None\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 4 (attached to \\fBResource\\fP instance)\n-.sp\n-Set opaque region\n-.sp\n-This request sets the region of the surface that contains opaque\n-content.\n-.sp\n-The opaque region is an optimization hint for the compositor that lets\n-it optimize the redrawing of content behind opaque regions. Setting an\n-opaque region is not required for correct behaviour, but marking\n-transparent content as opaque will result in repaint artifacts.\n-.sp\n-The opaque region is specified in surface\\-local coordinates.\n-.sp\n-The compositor ignores the parts of the opaque region that fall outside\n-of the surface.\n+.B done() -> \\(aqNone\\(aq\n .sp\n-Opaque region is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n+Event \\-\\- opcode 2 (attached to \\fBProxy\\fP instance)\n .sp\n-\\fI\\%WlSurface.set_opaque_region()\\fP changes the pending opaque\n-region. \\fI\\%WlSurface.commit()\\fP copies the pending region to the\n-current region. Otherwise, the pending and current regions are never\n-changed.\n+Sent all information about output\n .sp\n-The initial value for an opaque region is empty. Setting the pending\n-opaque region has copy semantics, and the\n-\\fI\\%WlRegion\\fP object can be destroyed\n-immediately. A NULL \\fI\\%WlRegion\\fP\n-causes the pending opaque region to be set to empty.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-\\fBregion\\fP (\\fI\\%WlRegion\\fP or \\fINone\\fP) \\-\\- opaque region of the surface\n-.UNINDENT\n+This event is sent after all other properties have been sent after\n+binding to the output object and after any other property changes done\n+after that. This allows changes to the output properties to be seen as\n+atomic, even if they happen via multiple events.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B set_input_region(region: \\(aqWlRegion | None\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 5 (attached to \\fBResource\\fP instance)\n-.sp\n-Set input region\n+.B scale(factor: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-This request sets the region of the surface that can receive pointer\n-and touch events.\n+Event \\-\\- opcode 3 (attached to \\fBProxy\\fP instance)\n .sp\n-Input events happening outside of this region will try the next surface\n-in the server surface stack. The compositor ignores the parts of the\n-input region that fall outside of the surface.\n+Output scaling properties\n .sp\n-The input region is specified in surface\\-local coordinates.\n+This event contains scaling geometry information that is not in the\n+geometry event. It may be sent after binding the output object or if\n+the output scale changes later. The compositor will emit a non\\-zero,\n+positive value for scale. If it is not sent, the client should assume a\n+scale of 1.\n .sp\n-Input region is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n+A scale larger than 1 means that the compositor will automatically\n+scale surface buffers by this amount when rendering. This is used for\n+very high resolution displays where applications rendering at the\n+native resolution would be too small to be legible.\n .sp\n-\\fI\\%WlSurface.set_input_region()\\fP changes the pending input region.\n-\\fI\\%WlSurface.commit()\\fP copies the pending region to the current\n-region. Otherwise the pending and current regions are never changed,\n-except cursor and icon surfaces are special cases, see\n-\\fI\\%WlPointer.set_cursor()\\fP and\n-\\fI\\%WlDataDevice.start_drag()\\fP\\&.\n+Clients should use \\fI\\%WlSurface.preferred_buffer_scale()\\fP instead\n+of this event to find the preferred buffer scale to use for a surface.\n .sp\n-The initial value for an input region is infinite. That means the whole\n-surface will accept input. Setting the pending input region has copy\n-semantics, and the \\fI\\%WlRegion\\fP object\n-can be destroyed immediately. A NULL\n-\\fI\\%WlRegion\\fP causes the input region\n-to be set to infinite.\n+The scale event will be followed by a done event.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBregion\\fP (\\fI\\%WlRegion\\fP or \\fINone\\fP) \\-\\- input region of the surface\n-.UNINDENT\n+\\fBfactor\\fP (\\fIArgumentType.Int\\fP) \\-\\- scaling factor of output\n .UNINDENT\n-.INDENT 7.0\n-.TP\n-.B commit() -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 6 (attached to \\fBResource\\fP instance)\n-.sp\n-Commit pending surface state\n-.sp\n-Surface state (input, opaque, and damage regions, attached buffers,\n-etc.) is double\\-buffered. Protocol requests modify the pending state,\n-as opposed to the active state in use by the compositor.\n-.sp\n-A commit request atomically creates a content update from the pending\n-state, even if the pending state has not been touched. The content\n-update is placed in a queue until it becomes active. After commit, the\n-new pending state is as documented for each related request.\n-.sp\n-When the content update is applied, the\n-\\fI\\%WlBuffer\\fP is applied before all\n-other state. This means that all coordinates in double\\-buffered state\n-are relative to the newly attached wl_buffers, except for\n-\\fI\\%WlSurface.attach()\\fP itself. If there is no newly attached\n-\\fI\\%WlBuffer\\fP, the coordinates are\n-relative to the previous content update.\n-.sp\n-All requests that need a commit to become effective are documented to\n-affect double\\-buffered state.\n-.sp\n-Other interfaces may add further double\\-buffered surface state.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B set_buffer_transform(transform: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B name(name: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 7 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 4 (attached to \\fBProxy\\fP instance)\n .sp\n-Sets the buffer transformation\n+Name of this output\n .sp\n-This request sets the transformation that the client has already\n-applied to the content of the buffer. The accepted values for the\n-transform parameter are the values for \\fBWlOutput.transform()\\fP\\&.\n+Many compositors will assign user\\-friendly names to their outputs, show\n+them to the user, allow the user to refer to an output, etc. The client\n+may wish to know this name as well to offer the user similar behaviors.\n .sp\n-The compositor applies the inverse of this transformation whenever it\n-uses the buffer contents.\n+The name is a UTF\\-8 string with no convention defined for its contents.\n+Each name is unique among all \\fI\\%WlOutput\\fP globals. The name is\n+only guaranteed to be unique for the compositor instance.\n .sp\n-Buffer transform is double\\-buffered state, see\n-\\fI\\%WlSurface.commit()\\fP\\&.\n+The same output name is used for all clients for a given\n+\\fI\\%WlOutput\\fP global. Thus, the name can be shared across processes\n+to refer to a specific \\fI\\%WlOutput\\fP global.\n .sp\n-A newly created surface has its buffer transformation set to normal.\n+The name is not guaranteed to be persistent across sessions, thus\n+cannot be used to reliably identify an output in e.g. configuration\n+files.\n .sp\n-\\fI\\%WlSurface.set_buffer_transform()\\fP changes the pending buffer\n-transformation. \\fI\\%WlSurface.commit()\\fP copies the pending buffer\n-transformation to the current one. Otherwise, the pending and current\n-values are never changed.\n+Examples of names include \\(aqHDMI\\-A\\-1\\(aq, \\(aqWL\\-1\\(aq, \\(aqX11\\-1\\(aq, etc. However, do\n+not assume that the name is a reflection of an underlying DRM\n+connector, X11 connection, etc.\n .sp\n-The purpose of this request is to allow clients to render content\n-according to the output transform, thus permitting the compositor to\n-use certain optimizations even if the display is rotated. Using\n-hardware overlays and scanning out a client buffer for fullscreen\n-surfaces are examples of such optimizations. Those optimizations are\n-highly dependent on the compositor implementation, so the use of this\n-request should be considered on a case\\-by\\-case basis.\n+The name event is sent after binding the output object. This event is\n+only sent once per output object, and the name does not change over the\n+lifetime of the \\fI\\%WlOutput\\fP global.\n .sp\n-Note that if the transform value includes 90 or 270 degree rotation,\n-the width of the buffer will become the surface height and the height\n-of the buffer will become the surface width.\n+Compositors may re\\-use the same output name if the \\fI\\%WlOutput\\fP\n+global is destroyed and re\\-created later. Compositors should avoid re\\-\n+using the same name if possible.\n .sp\n-If transform is not one of the values from the\n-\\fBWlOutput.transform()\\fP enum the\n-invalid_transform protocol error is raised.\n+The name event will be followed by a done event.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBtransform\\fP (\\fIArgumentType.Int\\fP) \\-\\- transform for interpreting buffer contents\n+\\fBname\\fP (\\fIArgumentType.String\\fP) \\-\\- output name\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B set_buffer_scale(scale: \\(aqint\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 8 (attached to \\fBResource\\fP instance)\n-.sp\n-Sets the buffer scaling factor\n-.sp\n-This request sets an optional scaling factor on how the compositor\n-interprets the contents of the buffer attached to the window.\n+.B description(description: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n .sp\n-Buffer scale is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n+Event \\-\\- opcode 5 (attached to \\fBProxy\\fP instance)\n .sp\n-A newly created surface has its buffer scale set to 1.\n+Human\\-readable description of this output\n .sp\n-\\fI\\%WlSurface.set_buffer_scale()\\fP changes the pending buffer scale.\n-\\fI\\%WlSurface.commit()\\fP copies the pending buffer scale to the\n-current one. Otherwise, the pending and current values are never\n-changed.\n+Many compositors can produce human\\-readable descriptions of their\n+outputs. The client may wish to know this description as well, e.g. for\n+output selection purposes.\n .sp\n-The purpose of this request is to allow clients to supply higher\n-resolution buffer data for use on high resolution outputs. It is\n-intended that you pick the same buffer scale as the scale of the output\n-that the surface is displayed on. This means the compositor can avoid\n-scaling when rendering the surface on that output.\n+The description is a UTF\\-8 string with no convention defined for its\n+contents. The description is not guaranteed to be unique among all\n+\\fI\\%WlOutput\\fP globals. Examples might include \\(aqFoocorp 11\\(dq Display\\(aq\n+or \\(aqVirtual X11 output via :1\\(aq.\n .sp\n-Note that if the scale is larger than 1, then you have to attach a\n-buffer that is larger (by a factor of scale in each dimension) than the\n-desired surface size.\n+The description event is sent after binding the output object and\n+whenever the description changes. The description is optional, and may\n+not be sent at all.\n .sp\n-If scale is not greater than 0 the invalid_scale protocol error is\n-raised.\n+The description event will be followed by a done event.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBscale\\fP (\\fIArgumentType.Int\\fP) \\-\\- scale for interpreting buffer contents\n+\\fBdescription\\fP (\\fIArgumentType.String\\fP) \\-\\- output description\n .UNINDENT\n .UNINDENT\n-.INDENT 7.0\n+.UNINDENT\n+.SS WlRegistry\n+.INDENT 0.0\n .TP\n-.B damage_buffer(x: \\(aqint\\(aq, y: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 9 (attached to \\fBResource\\fP instance)\n-.sp\n-Mark part of the surface damaged using buffer coordinates\n-.sp\n-This request is used to describe the regions where the pending buffer\n-is different from the current surface contents, and where the surface\n-therefore needs to be repainted. The compositor ignores the parts of\n-the damage that fall outside of the surface.\n+.B class pywayland.protocol.wayland.WlRegistry\n+Global registry object\n .sp\n-Damage is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n+The singleton global registry object. The server has a number of global\n+objects that are available to all clients. These objects typically\n+represent an actual object in the server (for example, an input device) or\n+they are singleton objects that provide extension functionality.\n .sp\n-The damage rectangle is specified in buffer coordinates, where x and y\n-specify the upper left corner of the damage rectangle.\n+When a client creates a registry object, the registry object will emit a\n+global event for each global currently in the registry. Globals come and\n+go as a result of device or monitor hotplugs, reconfiguration or other\n+events, and the registry will send out global and global_remove events to\n+keep the client up to date with the changes. To mark the end of the\n+initial burst of events, the client can use the \\fI\\%WlDisplay.sync()\\fP request immediately after\n+calling \\fI\\%WlDisplay.get_registry()\\fP\\&.\n .sp\n-The initial value for pending damage is empty: no damage.\n-\\fI\\%WlSurface.damage_buffer()\\fP adds pending damage: the new pending\n-damage is the union of old pending damage and the given rectangle.\n+A client can bind to a global object by using the bind request. This\n+creates a client\\-side handle that lets the object emit events to the client\n+and lets the client invoke requests on the object.\n+.INDENT 7.0\n+.TP\n+.B bind(name: \\(aqint\\(aq, interface: \\(aqtype[T]\\(aq, version: \\(aqint\\(aq) -> \\(aqProxy[T]\\(aq\n .sp\n-\\fI\\%WlSurface.commit()\\fP assigns pending damage as the current\n-damage, and clears pending damage. The server will clear the current\n-damage as it repaints the surface.\n+Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-This request differs from \\fI\\%WlSurface.damage()\\fP in only one way \\-\n-it takes damage in buffer coordinates instead of surface\\-local\n-coordinates. While this generally is more intuitive than surface\n-coordinates, it is especially desirable when using wp_viewport or when\n-a drawing library (like EGL) is unaware of buffer scale and buffer\n-transform.\n+Bind an object to the display\n .sp\n-Note: Because buffer transformation changes and damage requests may be\n-interleaved in the protocol stream, it is impossible to determine the\n-actual mapping between surface and buffer damage until\n-\\fI\\%WlSurface.commit()\\fP time. Therefore, compositors wishing to take\n-both kinds of damage into account will have to accumulate damage from\n-the two requests separately and only transform from one to the other\n-after receiving the \\fI\\%WlSurface.commit()\\fP\\&.\n+Binds a new, client\\-created object to the server using the specified\n+name as the identifier.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer\\-local x coordinate\n-.IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer\\-local y coordinate\n+\\fBname\\fP (\\fIArgumentType.Uint\\fP) \\-\\- unique numeric name of the object\n .IP \\(bu 2\n-\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- width of damage rectangle\n+\\fBinterface\\fP (\\fIstring\\fP) \\-\\- Interface name\n .IP \\(bu 2\n-\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- height of damage rectangle\n+\\fBversion\\fP (\\fIint\\fP) \\-\\- Interface version\n .UNINDENT\n+.TP\n+.B Returns\n+\\fBpywayland.client.proxy.Proxy\\fP of specified Interface \\-\\-\n+bounded object\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B offset(x: \\(aqint\\(aq, y: \\(aqint\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 10 (attached to \\fBResource\\fP instance)\n+.B global_(name: \\(aqint\\(aq, interface: \\(aqstr\\(aq, version: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Set the surface contents offset\n+Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n .sp\n-The x and y arguments specify the location of the new pending buffer\\(aqs\n-upper left corner, relative to the current buffer\\(aqs upper left corner,\n-in surface\\-local coordinates. In other words, the x and y, combined\n-with the new surface size define in which directions the surface\\(aqs size\n-changes.\n+Announce global object\n .sp\n-Surface location offset is double\\-buffered state, see\n-\\fI\\%WlSurface.commit()\\fP\\&.\n+Notify the client of global objects.\n .sp\n-This request is semantically equivalent to and the replaces the x and y\n-arguments in the \\fI\\%WlSurface.attach()\\fP request in\n-\\fI\\%WlSurface\\fP versions prior to 5. See \\fI\\%WlSurface.attach()\\fP\n-for details.\n+The event notifies the client that a global object with the given name\n+is now available, and it implements the given version of the given\n+interface.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local x coordinate\n+\\fBname\\fP (\\fIArgumentType.Uint\\fP) \\-\\- numeric name of the global object\n .IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local y coordinate\n+\\fBinterface\\fP (\\fIArgumentType.String\\fP) \\-\\- interface implemented by the object\n+.IP \\(bu 2\n+\\fBversion\\fP (\\fIArgumentType.Uint\\fP) \\-\\- interface version\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B enter(output: \\(aqWlOutput\\(aq) -> \\(aqNone\\(aq\n+.B global_remove(name: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n+Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n .sp\n-Surface enters an output\n+Announce removal of global object\n .sp\n-This is emitted whenever a surface\\(aqs creation, movement, or resizing\n-results in some part of it being within the scanout region of an\n-output.\n+Notify the client of removed global objects.\n .sp\n-Note that a surface may be overlapping with zero or more outputs.\n+This event notifies the client that the global identified by name is no\n+longer available. If the client bound to the global using the bind\n+request, the client should now destroy that object.\n+.sp\n+The object remains valid and requests to the object will be ignored\n+until the client destroys it, to avoid races between the global going\n+away and a client sending a request to it.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBoutput\\fP (\\fI\\%WlOutput\\fP) \\-\\- output entered by the surface\n+\\fBname\\fP (\\fIArgumentType.Uint\\fP) \\-\\- numeric name of the global object\n .UNINDENT\n .UNINDENT\n-.INDENT 7.0\n+.UNINDENT\n+.SS WlDataSource\n+.INDENT 0.0\n .TP\n-.B leave(output: \\(aqWlOutput\\(aq) -> \\(aqNone\\(aq\n+.B class pywayland.protocol.wayland.WlDataSource\n+Offer to transfer data\n .sp\n-Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n+The \\fI\\%WlDataSource\\fP object is the source side of a\n+\\fI\\%WlDataOffer\\fP\\&. It is created by the\n+source client in a data transfer and provides a way to describe the offered\n+data and a way to respond to requests to transfer the data.\n+.INDENT 7.0\n+.TP\n+.B offer(mime_type: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n .sp\n-Surface leaves an output\n+Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-This is emitted whenever a surface\\(aqs creation, movement, or resizing\n-results in it no longer having any part of it within the scanout region\n-of an output.\n+Add an offered mime type\n .sp\n-Clients should not use the number of outputs the surface is on for\n-frame throttling purposes. The surface might be hidden even if no leave\n-event has been sent, and the compositor might expect new surface\n-content updates even if no enter event has been sent. The frame event\n-should be used instead.\n+This request adds a mime type to the set of mime types advertised to\n+targets. Can be called several times to offer multiple types.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBoutput\\fP (\\fI\\%WlOutput\\fP) \\-\\- output left by the surface\n+\\fBmime_type\\fP (\\fIArgumentType.String\\fP) \\-\\- mime type offered by the data source\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B preferred_buffer_scale(factor: \\(aqint\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 2 (attached to \\fBProxy\\fP instance)\n-.sp\n-Preferred buffer scale for the surface\n-.sp\n-This event indicates the preferred buffer scale for this surface. It is\n-sent whenever the compositor\\(aqs preference changes.\n+.B destroy() -> \\(aqNone\\(aq\n .sp\n-Before receiving this event the preferred buffer scale for this surface\n-is 1.\n+Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-It is intended that scaling aware clients use this event to scale their\n-content and use \\fI\\%WlSurface.set_buffer_scale()\\fP to indicate the\n-scale they have rendered with. This allows clients to supply a higher\n-detail buffer.\n+Destroy the data source\n .sp\n-The compositor shall emit a scale value greater than 0.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-\\fBfactor\\fP (\\fIArgumentType.Int\\fP) \\-\\- preferred scaling factor\n-.UNINDENT\n+Destroy the data source.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B preferred_buffer_transform(transform: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B set_actions(dnd_actions: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 3 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n .sp\n-Preferred buffer transform for the surface\n+Set the available drag\\-and\\-drop actions\n .sp\n-This event indicates the preferred buffer transform for this surface.\n-It is sent whenever the compositor\\(aqs preference changes.\n+Sets the actions that the source side client supports for this\n+operation. This request may trigger \\fI\\%WlDataSource.action()\\fP and\n+\\fI\\%WlDataOffer.action()\\fP events if the\n+compositor needs to change the selected action.\n .sp\n-Before receiving this event the preferred buffer transform for this\n-surface is normal.\n+The dnd_actions argument must contain only values expressed in the\n+\\fBWlDataDeviceManager.dnd_actions()\\fP enum,\n+otherwise it will result in a protocol error.\n .sp\n-Applying this transformation to the surface buffer contents and using\n-\\fI\\%WlSurface.set_buffer_transform()\\fP might allow the compositor to\n-use the surface buffer more efficiently.\n+This request must be made once only, and can only be made on sources\n+used in drag\\-and\\-drop, so it must be performed before\n+\\fI\\%WlDataDevice.start_drag()\\fP\\&. Attempting to\n+use the source other than for drag\\-and\\-drop will raise a protocol\n+error.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBtransform\\fP (\\fIArgumentType.Uint\\fP) \\-\\- preferred transform\n-.UNINDENT\n-.UNINDENT\n+\\fBdnd_actions\\fP (\\fIArgumentType.Uint\\fP) \\-\\- actions supported by the data source\n .UNINDENT\n-.SS WlTouch\n-.INDENT 0.0\n-.TP\n-.B class pywayland.protocol.wayland.WlTouch\n-Touchscreen input device\n-.sp\n-The \\fI\\%WlTouch\\fP interface represents a touchscreen associated with a\n-seat.\n-.sp\n-Touch interactions can consist of one or more contacts. For each contact, a\n-series of events is generated, starting with a down event, followed by zero\n-or more motion events, and ending with an up event. Events relating to the\n-same contact point can be identified by the ID of the sequence.\n-.INDENT 7.0\n-.TP\n-.B release() -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n-.sp\n-Release the touch object\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B down(serial: \\(aqint\\(aq, time: \\(aqint\\(aq, surface: \\(aqWlSurface\\(aq, id: \\(aqint\\(aq, x: \\(aqfloat\\(aq, y: \\(aqfloat\\(aq) -> \\(aqNone\\(aq\n+.B target(mime_type: \\(aqstr | None\\(aq) -> \\(aqNone\\(aq\n .sp\n Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n .sp\n-Touch down event and beginning of a touch sequence\n+A target accepts an offered mime type\n .sp\n-A new touch point has appeared on the surface. This touch point is\n-assigned a unique ID. Future events from this touch point reference\n-this ID. The ID ceases to be valid after a touch up event and may be\n-reused in the future.\n+Sent when a target accepts pointer_focus or motion events. If a target\n+does not accept any of the offered types, type is NULL.\n+.sp\n+Used for feedback during drag\\-and\\-drop.\n .INDENT 7.0\n .TP\n .B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBserial\\fP (\\fIArgumentType.Uint\\fP) \\-\\- serial number of the touch down event\n-.IP \\(bu 2\n-\\fBtime\\fP (\\fIArgumentType.Uint\\fP) \\-\\- timestamp with millisecond granularity\n-.IP \\(bu 2\n-\\fBsurface\\fP (\\fI\\%WlSurface\\fP) \\-\\- surface touched\n-.IP \\(bu 2\n-\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n-.IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- surface\\-local x coordinate\n-.IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- surface\\-local y coordinate\n-.UNINDENT\n+\\fBmime_type\\fP (\\fIArgumentType.String\\fP or \\fINone\\fP) \\-\\- mime type accepted by the target\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B up(serial: \\(aqint\\(aq, time: \\(aqint\\(aq, id: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B send(mime_type: \\(aqstr\\(aq, fd: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n .sp\n-End of a touch event sequence\n+Send the data\n .sp\n-The touch point has disappeared. No further events will be sent for\n-this touch point and the touch point\\(aqs ID is released and may be reused\n-in a future touch down event.\n+Request for data from the client. Send the data as the specified mime\n+type over the passed file descriptor, then close it.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBserial\\fP (\\fIArgumentType.Uint\\fP) \\-\\- serial number of the touch up event\n-.IP \\(bu 2\n-\\fBtime\\fP (\\fIArgumentType.Uint\\fP) \\-\\- timestamp with millisecond granularity\n+\\fBmime_type\\fP (\\fIArgumentType.String\\fP) \\-\\- mime type for the data\n .IP \\(bu 2\n-\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n+\\fBfd\\fP (\\fIArgumentType.FileDescriptor\\fP) \\-\\- file descriptor for the data\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B motion(time: \\(aqint\\(aq, id: \\(aqint\\(aq, x: \\(aqfloat\\(aq, y: \\(aqfloat\\(aq) -> \\(aqNone\\(aq\n+.B cancelled() -> \\(aqNone\\(aq\n .sp\n Event \\-\\- opcode 2 (attached to \\fBProxy\\fP instance)\n .sp\n-Update of touch point coordinates\n+Selection was cancelled\n .sp\n-A touch point has changed coordinates.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n+This data source is no longer valid. There are several reasons why this\n+could happen:\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBtime\\fP (\\fIArgumentType.Uint\\fP) \\-\\- timestamp with millisecond granularity\n-.IP \\(bu 2\n-\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n-.IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- surface\\-local x coordinate\n+The data source has been replaced by another data source.\n .IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- surface\\-local y coordinate\n-.UNINDENT\n-.UNINDENT\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B frame() -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 3 (attached to \\fBProxy\\fP instance)\n-.sp\n-End of touch frame event\n-.sp\n-Indicates the end of a set of events that logically belong together. A\n-client is expected to accumulate the data in all events within the\n-frame before proceeding.\n-.sp\n-A \\fI\\%WlTouch.frame()\\fP terminates at least one event but otherwise\n-no guarantee is provided about the set of events within a frame. A\n-client must assume that any state not updated in a frame is unchanged\n-from the previously known state.\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B cancel() -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 4 (attached to \\fBProxy\\fP instance)\n-.sp\n-Touch session cancelled\n-.sp\n-Sent if the compositor decides the touch stream is a global gesture. No\n-further events are sent to the clients from that particular gesture.\n-Touch cancellation applies to all touch points currently active on this\n-client\\(aqs surface. The client is responsible for finalizing the touch\n-points, future touch points on this surface may reuse the touch point\n-ID.\n-.sp\n-No frame event is required after the cancel event.\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B shape(id: \\(aqint\\(aq, major: \\(aqfloat\\(aq, minor: \\(aqfloat\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 5 (attached to \\fBProxy\\fP instance)\n-.sp\n-Update shape of touch point\n-.sp\n-Sent when a touchpoint has changed its shape.\n-.sp\n-This event does not occur on its own. It is sent before a\n-\\fI\\%WlTouch.frame()\\fP event and carries the new shape information for\n-any previously reported, or new touch points of that frame.\n-.sp\n-Other events describing the touch point such as \\fI\\%WlTouch.down()\\fP,\n-\\fI\\%WlTouch.motion()\\fP or \\fI\\%WlTouch.orientation()\\fP may be sent\n-within the same \\fI\\%WlTouch.frame()\\fP\\&. A client should treat these\n-events as a single logical touch point update. The order of\n-\\fI\\%WlTouch.shape()\\fP, \\fI\\%WlTouch.orientation()\\fP and\n-\\fI\\%WlTouch.motion()\\fP is not guaranteed. A \\fI\\%WlTouch.down()\\fP\n-event is guaranteed to occur before the first \\fI\\%WlTouch.shape()\\fP\n-event for this touch ID but both events may occur within the same\n-\\fI\\%WlTouch.frame()\\fP\\&.\n-.sp\n-A touchpoint shape is approximated by an ellipse through the major and\n-minor axis length. The major axis length describes the longer diameter\n-of the ellipse, while the minor axis length describes the shorter\n-diameter. Major and minor are orthogonal and both are specified in\n-surface\\-local coordinates. The center of the ellipse is always at the\n-touchpoint location as reported by \\fI\\%WlTouch.down()\\fP or\n-\\fBWlTouch.move()\\fP\\&.\n-.sp\n-This event is only sent by the compositor if the touch device supports\n-shape reports. The client has to make reasonable assumptions about the\n-shape if it did not receive this event.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-.INDENT 7.0\n+The drag\\-and\\-drop operation was performed, but the drop destination\n+did not accept any of the mime types offered through\n+\\fI\\%WlDataSource.target()\\fP\\&.\n .IP \\(bu 2\n-\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n+The drag\\-and\\-drop operation was performed, but the drop destination\n+did not select any of the actions present in the mask offered through\n+\\fI\\%WlDataSource.action()\\fP\\&.\n .IP \\(bu 2\n-\\fBmajor\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- length of the major axis in surface\\-local coordinates\n+The drag\\-and\\-drop operation was performed but didn\\(aqt happen over a\n+surface.\n .IP \\(bu 2\n-\\fBminor\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- length of the minor axis in surface\\-local coordinates\n-.UNINDENT\n-.UNINDENT\n+The compositor cancelled the drag\\-and\\-drop operation (e.g. compositor\n+dependent timeouts to avoid stale drag\\-and\\-drop transfers).\n .UNINDENT\n-.INDENT 7.0\n-.TP\n-.B orientation(id: \\(aqint\\(aq, orientation: \\(aqfloat\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 6 (attached to \\fBProxy\\fP instance)\n-.sp\n-Update orientation of touch point\n .sp\n-Sent when a touchpoint has changed its orientation.\n-.sp\n-This event does not occur on its own. It is sent before a\n-\\fI\\%WlTouch.frame()\\fP event and carries the new shape information for\n-any previously reported, or new touch points of that frame.\n-.sp\n-Other events describing the touch point such as \\fI\\%WlTouch.down()\\fP,\n-\\fI\\%WlTouch.motion()\\fP or \\fI\\%WlTouch.shape()\\fP may be sent within\n-the same \\fI\\%WlTouch.frame()\\fP\\&. A client should treat these events as\n-a single logical touch point update. The order of\n-\\fI\\%WlTouch.shape()\\fP, \\fI\\%WlTouch.orientation()\\fP and\n-\\fI\\%WlTouch.motion()\\fP is not guaranteed. A \\fI\\%WlTouch.down()\\fP\n-event is guaranteed to occur before the first\n-\\fI\\%WlTouch.orientation()\\fP event for this touch ID but both events\n-may occur within the same \\fI\\%WlTouch.frame()\\fP\\&.\n-.sp\n-The orientation describes the clockwise angle of a touchpoint\\(aqs major\n-axis to the positive surface y\\-axis and is normalized to the \\-180 to\n-+180 degree range. The granularity of orientation depends on the touch\n-device, some devices only support binary rotation values between 0 and\n-90 degrees.\n+The client should clean up and destroy this data source.\n .sp\n-This event is only sent by the compositor if the touch device supports\n-orientation reports.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBid\\fP (\\fIArgumentType.Int\\fP) \\-\\- the unique ID of this touch point\n-.IP \\(bu 2\n-\\fBorientation\\fP (\\fIArgumentType.Fixed\\fP) \\-\\- angle between major axis and positive surface y\\-axis in degrees\n-.UNINDENT\n-.UNINDENT\n-.UNINDENT\n+For objects of version 2 or older, \\fI\\%WlDataSource.cancelled()\\fP\n+will only be emitted if the data source was replaced by another data\n+source.\n .UNINDENT\n-.SS WlRegion\n-.INDENT 0.0\n-.TP\n-.B class pywayland.protocol.wayland.WlRegion\n-Region interface\n-.sp\n-A region object describes an area.\n-.sp\n-Region objects are used to describe the opaque and input regions of a\n-surface.\n .INDENT 7.0\n .TP\n-.B destroy() -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+.B dnd_drop_performed() -> \\(aqNone\\(aq\n .sp\n-Destroy region\n+Event \\-\\- opcode 3 (attached to \\fBProxy\\fP instance)\n .sp\n-Destroy the region. This will invalidate the object ID.\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B add(x: \\(aqint\\(aq, y: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+The drag\\-and\\-drop operation physically finished\n .sp\n-Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n+The user performed the drop action. This event does not indicate\n+acceptance, \\fI\\%WlDataSource.cancelled()\\fP may still be emitted\n+afterwards if the drop destination does not accept any mime type.\n .sp\n-Add rectangle to region\n+However, this event might however not be received if the compositor\n+cancelled the drag\\-and\\-drop operation before this event could happen.\n .sp\n-Add the specified rectangle to the region.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- region\\-local x coordinate\n-.IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- region\\-local y coordinate\n-.IP \\(bu 2\n-\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- rectangle width\n-.IP \\(bu 2\n-\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- rectangle height\n-.UNINDENT\n-.UNINDENT\n+Note that the data_source may still be used in the future and should\n+not be destroyed here.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B subtract(x: \\(aqint\\(aq, y: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n-.sp\n-Subtract rectangle from region\n-.sp\n-Subtract the specified rectangle from the region.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- region\\-local x coordinate\n-.IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- region\\-local y coordinate\n-.IP \\(bu 2\n-\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- rectangle width\n-.IP \\(bu 2\n-\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- rectangle height\n-.UNINDENT\n-.UNINDENT\n-.UNINDENT\n-.UNINDENT\n-.SS WlSubcompositor\n-.INDENT 0.0\n-.TP\n-.B class pywayland.protocol.wayland.WlSubcompositor\n-Sub\\-surface compositing\n-.sp\n-The global interface exposing sub\\-surface compositing capabilities. A\n-\\fI\\%WlSurface\\fP, that has sub\\-surfaces\n-associated, is called the parent surface. Sub\\-surfaces can be arbitrarily\n-nested and create a tree of sub\\-surfaces.\n-.sp\n-The root surface in a tree of sub\\-surfaces is the main surface. The main\n-surface cannot be a sub\\-surface, because sub\\-surfaces must always have a\n-parent.\n-.sp\n-A main surface with its sub\\-surfaces forms a (compound) window. For window\n-management purposes, this set of\n-\\fI\\%WlSurface\\fP objects is to be considered\n-as a single window, and it should also behave as such.\n+.B dnd_finished() -> \\(aqNone\\(aq\n .sp\n-The aim of sub\\-surfaces is to offload some of the compositing work within a\n-window from clients to the compositor. A prime example is a video player\n-with decorations and video in separate\n-\\fI\\%WlSurface\\fP objects. This should allow\n-the compositor to pass YUV video buffer processing to dedicated overlay\n-hardware when possible.\n-.INDENT 7.0\n-.TP\n-.B destroy() -> \\(aqNone\\(aq\n+Event \\-\\- opcode 4 (attached to \\fBProxy\\fP instance)\n .sp\n-Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+The drag\\-and\\-drop operation concluded\n .sp\n-Unbind from the subcompositor interface\n+The drop destination finished interoperating with this data source, so\n+the client is now free to destroy this data source and free all\n+associated data.\n .sp\n-Informs the server that the client will not be using this protocol\n-object anymore. This does not affect any other objects,\n-\\fI\\%WlSubsurface\\fP objects included.\n+If the action used to perform the operation was \\(dqmove\\(dq, the source can\n+now delete the transferred data.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B get_subsurface(surface: \\(aqWlSurface\\(aq, parent: \\(aqWlSurface\\(aq) -> \\(aqProxy[WlSubsurface]\\(aq\n+.B action(dnd_action: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 5 (attached to \\fBProxy\\fP instance)\n .sp\n-Give a surface the role sub\\-surface\n+Notify the selected action\n .sp\n-Create a sub\\-surface interface for the given surface, and associate it\n-with the given parent surface. This turns a plain\n-\\fI\\%WlSurface\\fP into a sub\\-surface.\n+This event indicates the action selected by the compositor after\n+matching the source/destination side actions. Only one action (or none)\n+will be offered here.\n .sp\n-The to\\-be sub\\-surface must not already have another role, and it must\n-not have an existing \\fI\\%WlSubsurface\\fP\n-object. Otherwise the bad_surface protocol error is raised.\n+This event can be emitted multiple times during the drag\\-and\\-drop\n+operation, mainly in response to destination side changes through\n+\\fI\\%WlDataOffer.set_actions()\\fP, and as the data\n+device enters/leaves surfaces.\n .sp\n-Adding sub\\-surfaces to a parent is a double\\-buffered operation on the\n-parent (see \\fI\\%WlSurface.commit()\\fP). The effect of adding a\n-sub\\-surface becomes visible on the next time the state of the parent\n-surface is applied.\n+It is only possible to receive this event after\n+\\fI\\%WlDataSource.dnd_drop_performed()\\fP if the drag\\-and\\-drop\n+operation ended in an \\(dqask\\(dq action, in which case the final\n+\\fI\\%WlDataSource.action()\\fP event will happen immediately before\n+\\fI\\%WlDataSource.dnd_finished()\\fP\\&.\n .sp\n-The parent surface must not be one of the child surface\\(aqs descendants,\n-and the parent must be different from the child surface, otherwise the\n-bad_parent protocol error is raised.\n+Compositors may also change the selected action on the fly, mainly in\n+response to keyboard modifier changes during the drag\\-and\\-drop\n+operation.\n .sp\n-This request modifies the behaviour of \\fI\\%WlSurface.commit()\\fP request on the sub\\-\n-surface, see the documentation on\n-\\fI\\%WlSubsurface\\fP interface.\n+The most recent action received is always the valid one. The chosen\n+action may change alongside negotiation (e.g. an \\(dqask\\(dq action can turn\n+into a \\(dqmove\\(dq operation), so the effects of the final action must\n+always be applied in \\fBWlDataOffer.dnd_finished()\\fP\\&.\n+.sp\n+Clients can trigger cursor surface changes from this point, so they\n+reflect the current action.\n .INDENT 7.0\n .TP\n .B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBsurface\\fP (\\fI\\%WlSurface\\fP) \\-\\- the surface to be turned into a sub\\-surface\n-.IP \\(bu 2\n-\\fBparent\\fP (\\fI\\%WlSurface\\fP) \\-\\- the parent surface\n-.UNINDENT\n-.TP\n-.B Returns\n-\\fI\\%WlSubsurface\\fP \\-\\- the new sub\\-\n-surface object ID\n+\\fBdnd_action\\fP (\\fIArgumentType.Uint\\fP) \\-\\- action selected by the compositor\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .SS WlPointer\n .INDENT 0.0\n .TP\n .B class pywayland.protocol.wayland.WlPointer\n@@ -3583,549 +3460,1022 @@\n \\fBaxis\\fP (\\fIArgumentType.Uint\\fP) \\-\\- axis type\n .IP \\(bu 2\n \\fBdirection\\fP (\\fIArgumentType.Uint\\fP) \\-\\- physical direction relative to axis motion\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .UNINDENT\n-.SS WlDataOffer\n+.SS WlDataDeviceManager\n .INDENT 0.0\n .TP\n-.B class pywayland.protocol.wayland.WlDataOffer\n-Offer to transfer data\n+.B class pywayland.protocol.wayland.WlDataDeviceManager\n+Data transfer interface\n .sp\n-A \\fI\\%WlDataOffer\\fP represents a piece of data offered for transfer by\n-another client (the source client). It is used by the copy\\-and\\-paste and\n-drag\\-and\\-drop mechanisms. The offer describes the different mime types\n-that the data can be converted to and provides the mechanism for\n-transferring the data directly from the source client.\n+The \\fI\\%WlDataDeviceManager\\fP is a singleton global object that provides\n+access to inter\\-client data transfer mechanisms such as copy\\-and\\-paste and\n+drag\\-and\\-drop. These mechanisms are tied to a\n+\\fI\\%WlSeat\\fP and this interface lets a\n+client get a \\fI\\%WlDataDevice\\fP\n+corresponding to a \\fI\\%WlSeat\\fP\\&.\n+.sp\n+Depending on the version bound, the objects created from the bound\n+\\fI\\%WlDataDeviceManager\\fP object will have different requirements for\n+functioning properly. See \\fI\\%WlDataSource.set_actions()\\fP,\n+\\fI\\%WlDataOffer.accept()\\fP and\n+\\fI\\%WlDataOffer.finish()\\fP for details.\n .INDENT 7.0\n .TP\n-.B accept(serial: \\(aqint\\(aq, mime_type: \\(aqstr | None\\(aq) -> \\(aqNone\\(aq\n+.B create_data_source() -> \\(aqProxy[WlDataSource]\\(aq\n .sp\n Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Accept one of the offered mime types\n+Create a new data source\n .sp\n-Indicate that the client can accept the given mime type, or NULL for\n-not accepted.\n+Create a new data source.\n+.INDENT 7.0\n+.TP\n+.B Returns\n+\\fI\\%WlDataSource\\fP \\-\\- data source to\n+create\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B get_data_device(seat: \\(aqWlSeat\\(aq) -> \\(aqProxy[WlDataDevice]\\(aq\n .sp\n-For objects of version 2 or older, this request is used by the client\n-to give feedback whether the client can receive the given mime type, or\n-NULL if none is accepted; the feedback does not determine whether the\n-drag\\-and\\-drop operation succeeds or not.\n+Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-For objects of version 3 or newer, this request determines the final\n-result of the drag\\-and\\-drop operation. If the end result is that no\n-mime types were accepted, the drag\\-and\\-drop operation will be cancelled\n-and the corresponding drag source will receive\n-\\fI\\%WlDataSource.cancelled()\\fP\\&. Clients may still\n-use this event in conjunction with \\fI\\%WlDataSource.action()\\fP for feedback.\n+Create a new data device\n+.sp\n+Create a new data device for a given seat.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+\\fBseat\\fP (\\fI\\%WlSeat\\fP) \\-\\- seat associated with the data device\n+.TP\n+.B Returns\n+\\fI\\%WlDataDevice\\fP \\-\\- data device to\n+create\n+.UNINDENT\n+.UNINDENT\n+.UNINDENT\n+.SS WlShm\n+.INDENT 0.0\n+.TP\n+.B class pywayland.protocol.wayland.WlShm\n+Shared memory support\n+.sp\n+A singleton global object that provides support for shared memory.\n+.sp\n+Clients can create \\fI\\%WlShmPool\\fP objects\n+using the create_pool request.\n+.sp\n+On binding the \\fI\\%WlShm\\fP object one or more format events are emitted\n+to inform clients about the valid pixel formats that can be used for\n+buffers.\n+.INDENT 7.0\n+.TP\n+.B create_pool(fd: \\(aqint\\(aq, size: \\(aqint\\(aq) -> \\(aqProxy[WlShmPool]\\(aq\n+.sp\n+Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+.sp\n+Create a shm pool\n+.sp\n+Create a new \\fI\\%WlShmPool\\fP object.\n+.sp\n+The pool can be used to create shared memory based buffer objects. The\n+server will mmap size bytes of the passed file descriptor, to use as\n+backing memory for the pool.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBserial\\fP (\\fIArgumentType.Uint\\fP) \\-\\- serial number of the accept request\n+\\fBfd\\fP (\\fIArgumentType.FileDescriptor\\fP) \\-\\- file descriptor for the pool\n .IP \\(bu 2\n-\\fBmime_type\\fP (\\fIArgumentType.String\\fP or \\fINone\\fP) \\-\\- mime type accepted by the client\n+\\fBsize\\fP (\\fIArgumentType.Int\\fP) \\-\\- pool size, in bytes\n .UNINDENT\n+.TP\n+.B Returns\n+\\fI\\%WlShmPool\\fP \\-\\- pool to create\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B receive(mime_type: \\(aqstr\\(aq, fd: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B release() -> \\(aqNone\\(aq\n .sp\n Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-Request that the data is transferred\n+Release the shm object\n .sp\n-To transfer the offered data, the client issues this request and\n-indicates the mime type it wants to receive. The transfer happens\n-through the passed file descriptor (typically created with the pipe\n-system call). The source client writes the data in the mime type\n-representation requested and then closes the file descriptor.\n+Using this request a client can tell the server that it is not going to\n+use the shm object anymore.\n .sp\n-The receiving client reads from the read end of the pipe until EOF and\n-then closes its end, at which point the transfer is complete.\n+Objects created via this interface remain unaffected.\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B format(format: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-This request may happen multiple times for different mime types, both\n-before and after \\fI\\%WlDataDevice.drop()\\fP\\&. Drag\\-and\\-drop\n-destination clients may preemptively fetch data or examine it more\n-closely to determine acceptance.\n+Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n+.sp\n+Pixel format description\n+.sp\n+Informs the client about a valid pixel format that can be used for\n+buffers. Known formats include argb8888 and xrgb8888.\n .INDENT 7.0\n .TP\n .B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBmime_type\\fP (\\fIArgumentType.String\\fP) \\-\\- mime type desired by receiver\n-.IP \\(bu 2\n-\\fBfd\\fP (\\fIArgumentType.FileDescriptor\\fP) \\-\\- file descriptor for data transfer\n+\\fBformat\\fP (\\fIArgumentType.Uint\\fP) \\-\\- buffer pixel format\n .UNINDENT\n .UNINDENT\n .UNINDENT\n+.SS WlBuffer\n+.INDENT 0.0\n+.TP\n+.B class pywayland.protocol.wayland.WlBuffer\n+Content for a \\fI\\%WlSurface\\fP\n+.sp\n+A buffer provides the content for a\n+\\fI\\%WlSurface\\fP\\&. Buffers are created through\n+factory interfaces such as \\fI\\%WlShm\\fP,\n+wp_linux_buffer_params (from the linux\\-dmabuf protocol extension) or\n+similar. It has a width and a height and can be attached to a\n+\\fI\\%WlSurface\\fP, but the mechanism by which\n+a client provides and updates the contents is defined by the buffer factory\n+interface.\n+.sp\n+Color channels are assumed to be electrical rather than optical (in other\n+words, encoded with a transfer function) unless otherwise specified. If the\n+buffer uses a format that has an alpha channel, the alpha channel is\n+assumed to be premultiplied into the electrical color channel values (after\n+transfer function encoding) unless otherwise specified.\n+.sp\n+Note, because \\fI\\%WlBuffer\\fP objects are created from multiple\n+independent factory interfaces, the \\fI\\%WlBuffer\\fP interface is frozen\n+at version 1.\n .INDENT 7.0\n .TP\n .B destroy() -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n+Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Destroy data offer\n+Destroy a buffer\n .sp\n-Destroy the data offer.\n+Destroy a buffer. If and how you need to release the backing storage is\n+defined by the buffer factory interface.\n+.sp\n+For possible side\\-effects to a surface, see \\fI\\%WlSurface.attach()\\fP\\&.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B finish() -> \\(aqNone\\(aq\n+.B release() -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 3 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n .sp\n-The offer will no longer be used\n+Compositor releases buffer\n .sp\n-Notifies the compositor that the drag destination successfully finished\n-the drag\\-and\\-drop operation.\n+Sent when this \\fI\\%WlBuffer\\fP is no longer used by the compositor.\n+The client is now free to reuse or destroy this buffer and its backing\n+storage.\n .sp\n-Upon receiving this request, the compositor will emit\n-\\fI\\%WlDataSource.dnd_finished()\\fP on the drag\n-source client.\n+If a client receives a release event before the frame callback\n+requested in the same \\fI\\%WlSurface.commit()\\fP that attaches this\n+\\fI\\%WlBuffer\\fP to a surface, then the client is immediately free to\n+reuse the buffer and its backing storage, and does not need a second\n+buffer for the next surface content update. Typically this is possible,\n+when the compositor maintains a copy of the\n+\\fI\\%WlSurface\\fP contents, e.g. as a GL\n+texture. This is an important optimization for GL(ES) compositors with\n+\\fI\\%WlShm\\fP clients.\n+.UNINDENT\n+.UNINDENT\n+.SS WlSurface\n+.INDENT 0.0\n+.TP\n+.B class pywayland.protocol.wayland.WlSurface\n+An onscreen surface\n .sp\n-It is a client error to perform other requests than\n-\\fI\\%WlDataOffer.destroy()\\fP after this one. It is also an error to\n-perform this request after a NULL mime type has been set in\n-\\fI\\%WlDataOffer.accept()\\fP or no action was received through\n-\\fI\\%WlDataOffer.action()\\fP\\&.\n+A surface is a rectangular area that may be displayed on zero or more\n+outputs, and shown any number of times at the compositor\\(aqs discretion. They\n+can present wl_buffers, receive user input, and define a local coordinate\n+system.\n .sp\n-If \\fI\\%WlDataOffer.finish()\\fP request is received for a non drag and\n-drop operation, the invalid_finish protocol error is raised.\n+The size of a surface (and relative positions on it) is described in\n+surface\\-local coordinates, which may differ from the buffer coordinates of\n+the pixel content, in case a buffer_transform or a buffer_scale is used.\n+.sp\n+A surface without a \\(dqrole\\(dq is fairly useless: a compositor does not know\n+where, when or how to present it. The role is the purpose of a\n+\\fI\\%WlSurface\\fP\\&. Examples of roles are a cursor for a pointer (as set by\n+\\fI\\%WlPointer.set_cursor()\\fP), a drag icon\n+(\\fI\\%WlDataDevice.start_drag()\\fP), a sub\\-surface\n+(\\fI\\%WlSubcompositor.get_subsurface()\\fP), and a window\n+as defined by a shell protocol (e.g. \\fI\\%WlShell.get_shell_surface()\\fP).\n+.sp\n+A surface can have only one role at a time. Initially a \\fI\\%WlSurface\\fP\n+does not have a role. Once a \\fI\\%WlSurface\\fP is given a role, it is set\n+permanently for the whole lifetime of the \\fI\\%WlSurface\\fP object. Giving\n+the current role again is allowed, unless explicitly forbidden by the\n+relevant interface specification.\n+.sp\n+Surface roles are given by requests in other interfaces such as\n+\\fI\\%WlPointer.set_cursor()\\fP\\&. The request should\n+explicitly mention that this request gives a role to a \\fI\\%WlSurface\\fP\\&.\n+Often, this request also creates a new protocol object that represents the\n+role and adds additional functionality to \\fI\\%WlSurface\\fP\\&. When a client\n+wants to destroy a \\fI\\%WlSurface\\fP, they must destroy this role object\n+before the \\fI\\%WlSurface\\fP, otherwise a defunct_role_object error is\n+sent.\n+.sp\n+Destroying the role object does not remove the role from the\n+\\fI\\%WlSurface\\fP, but it may stop the \\fI\\%WlSurface\\fP from \\(dqplaying\n+the role\\(dq. For instance, if a\n+\\fI\\%WlSubsurface\\fP object is destroyed, the\n+\\fI\\%WlSurface\\fP it was created for will be unmapped and forget its\n+position and z\\-order. It is allowed to create a\n+\\fI\\%WlSubsurface\\fP for the same\n+\\fI\\%WlSurface\\fP again, but it is not allowed to use the\n+\\fI\\%WlSurface\\fP as a cursor (cursor is a different role than sub\\-\n+surface, and role switching is not allowed).\n+.INDENT 7.0\n+.TP\n+.B destroy() -> \\(aqNone\\(aq\n+.sp\n+Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+.sp\n+Delete surface\n+.sp\n+Deletes the surface and invalidates its object ID.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B set_actions(dnd_actions: \\(aqint\\(aq, preferred_action: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B attach(buffer: \\(aqWlBuffer | None\\(aq, x: \\(aqint\\(aq, y: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 4 (attached to \\fBResource\\fP instance)\n+Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-Set the available/preferred drag\\-and\\-drop actions\n+Set the surface contents\n .sp\n-Sets the actions that the destination side client supports for this\n-operation. This request may trigger the emission of\n-\\fI\\%WlDataSource.action()\\fP and\n-\\fI\\%WlDataOffer.action()\\fP events if the compositor needs to change\n-the selected action.\n+Set a buffer as the content of this surface.\n .sp\n-This request can be called multiple times throughout the drag\\-and\\-drop\n-operation, typically in response to \\fI\\%WlDataDevice.enter()\\fP or\n-\\fI\\%WlDataDevice.motion()\\fP events.\n+The new size of the surface is calculated based on the buffer size\n+transformed by the inverse buffer_transform and the inverse\n+buffer_scale. This means that at commit time the supplied buffer size\n+must be an integer multiple of the buffer_scale. If that\\(aqs not the\n+case, an invalid_size error is sent.\n .sp\n-This request determines the final result of the drag\\-and\\-drop\n-operation. If the end result is that no action is accepted, the drag\n-source will receive \\fI\\%WlDataSource.cancelled()\\fP\\&.\n+The x and y arguments specify the location of the new pending buffer\\(aqs\n+upper left corner, relative to the current buffer\\(aqs upper left corner,\n+in surface\\-local coordinates. In other words, the x and y, combined\n+with the new surface size define in which directions the surface\\(aqs size\n+changes. Setting anything other than 0 as x and y arguments is\n+discouraged, and should instead be replaced with using the separate\n+\\fI\\%WlSurface.offset()\\fP request.\n .sp\n-The dnd_actions argument must contain only values expressed in the\n-\\fBWlDataDeviceManager.dnd_actions()\\fP enum, and\n-the preferred_action argument must only contain one of those values\n-set, otherwise it will result in a protocol error.\n+When the bound \\fI\\%WlSurface\\fP version is 5 or higher, passing any\n+non\\-zero x or y is a protocol violation, and will result in an\n+\\(aqinvalid_offset\\(aq error being raised. The x and y arguments are ignored\n+and do not change the pending state. To achieve equivalent semantics,\n+use \\fI\\%WlSurface.offset()\\fP\\&.\n .sp\n-While managing an \\(dqask\\(dq action, the destination drag\\-and\\-drop client\n-may perform further \\fI\\%WlDataOffer.receive()\\fP requests, and is\n-expected to perform one last \\fI\\%WlDataOffer.set_actions()\\fP request\n-with a preferred action other than \\(dqask\\(dq (and optionally\n-\\fI\\%WlDataOffer.accept()\\fP) before requesting\n-\\fI\\%WlDataOffer.finish()\\fP, in order to convey the action selected by\n-the user. If the preferred action is not in the\n-\\fI\\%WlDataOffer.source_actions()\\fP mask, an error will be raised.\n+Surface contents are double\\-buffered state, see\n+\\fI\\%WlSurface.commit()\\fP\\&.\n .sp\n-If the \\(dqask\\(dq action is dismissed (e.g. user cancellation), the client\n-is expected to perform \\fI\\%WlDataOffer.destroy()\\fP right away.\n+The initial surface contents are void; there is no content.\n+\\fI\\%WlSurface.attach()\\fP assigns the given\n+\\fI\\%WlBuffer\\fP as the pending\n+\\fI\\%WlBuffer\\fP\\&.\n+\\fI\\%WlSurface.commit()\\fP makes the pending\n+\\fI\\%WlBuffer\\fP the new surface contents,\n+and the size of the surface becomes the size calculated from the\n+\\fI\\%WlBuffer\\fP, as described above.\n+After commit, there is no pending buffer until the next attach.\n .sp\n-This request can only be made on drag\\-and\\-drop offers, a protocol error\n-will be raised otherwise.\n+Committing a pending \\fI\\%WlBuffer\\fP\n+allows the compositor to read the pixels in the\n+\\fI\\%WlBuffer\\fP\\&. The compositor may\n+access the pixels at any time after the \\fI\\%WlSurface.commit()\\fP\n+request. When the compositor will not access the pixels anymore, it\n+will send the \\fI\\%WlBuffer.release()\\fP event. Only after\n+receiving \\fI\\%WlBuffer.release()\\fP, the client may reuse\n+the \\fI\\%WlBuffer\\fP\\&. A\n+\\fI\\%WlBuffer\\fP that has been attached\n+and then replaced by another attach instead of committed will not\n+receive a release event, and is not used by the compositor.\n+.sp\n+If a pending \\fI\\%WlBuffer\\fP has been\n+committed to more than one \\fI\\%WlSurface\\fP, the delivery of\n+\\fI\\%WlBuffer.release()\\fP events becomes\n+undefined. A well behaved client should not rely on\n+\\fI\\%WlBuffer.release()\\fP events in this case.\n+Alternatively, a client could create multiple\n+\\fI\\%WlBuffer\\fP objects from the same\n+backing storage or use wp_linux_buffer_release.\n+.sp\n+Destroying the \\fI\\%WlBuffer\\fP after\n+\\fI\\%WlBuffer.release()\\fP does not change the\n+surface contents. Destroying the\n+\\fI\\%WlBuffer\\fP before\n+\\fI\\%WlBuffer.release()\\fP is allowed as long as\n+the underlying buffer storage isn\\(aqt re\\-used (this can happen e.g. on\n+client process termination). However, if the client destroys the\n+\\fI\\%WlBuffer\\fP before receiving the\n+\\fI\\%WlBuffer.release()\\fP event and mutates the\n+underlying buffer storage, the surface contents become undefined\n+immediately.\n+.sp\n+If \\fI\\%WlSurface.attach()\\fP is sent with a NULL\n+\\fI\\%WlBuffer\\fP, the following\n+\\fI\\%WlSurface.commit()\\fP will remove the surface content.\n+.sp\n+If a pending \\fI\\%WlBuffer\\fP has been\n+destroyed, the result is not specified. Many compositors are known to\n+remove the surface content on the following \\fI\\%WlSurface.commit()\\fP,\n+but this behaviour is not universal. Clients seeking to maximise\n+compatibility should not destroy pending buffers and should ensure that\n+they explicitly remove content from surfaces, even after destroying\n+buffers.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBdnd_actions\\fP (\\fIArgumentType.Uint\\fP) \\-\\- actions supported by the destination client\n+\\fBbuffer\\fP (\\fI\\%WlBuffer\\fP or \\fINone\\fP) \\-\\- buffer of surface contents\n .IP \\(bu 2\n-\\fBpreferred_action\\fP (\\fIArgumentType.Uint\\fP) \\-\\- action preferred by the destination client\n+\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local x coordinate\n+.IP \\(bu 2\n+\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local y coordinate\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B offer(mime_type: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n+.B damage(x: \\(aqint\\(aq, y: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n .sp\n-Advertise offered mime type\n+Mark part of the surface damaged\n .sp\n-Sent immediately after creating the \\fI\\%WlDataOffer\\fP object. One\n-event per offered mime type.\n+This request is used to describe the regions where the pending buffer\n+is different from the current surface contents, and where the surface\n+therefore needs to be repainted. The compositor ignores the parts of\n+the damage that fall outside of the surface.\n+.sp\n+Damage is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n+.sp\n+The damage rectangle is specified in surface\\-local coordinates, where x\n+and y specify the upper left corner of the damage rectangle.\n+.sp\n+The initial value for pending damage is empty: no damage.\n+\\fI\\%WlSurface.damage()\\fP adds pending damage: the new pending damage\n+is the union of old pending damage and the given rectangle.\n+.sp\n+\\fI\\%WlSurface.commit()\\fP assigns pending damage as the current\n+damage, and clears pending damage. The server will clear the current\n+damage as it repaints the surface.\n+.sp\n+Note! New clients should not use this request. Instead damage can be\n+posted with \\fI\\%WlSurface.damage_buffer()\\fP which uses buffer\n+coordinates instead of surface coordinates.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBmime_type\\fP (\\fIArgumentType.String\\fP) \\-\\- offered mime type\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local x coordinate\n+.IP \\(bu 2\n+\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local y coordinate\n+.IP \\(bu 2\n+\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- width of damage rectangle\n+.IP \\(bu 2\n+\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- height of damage rectangle\n+.UNINDENT\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B source_actions(source_actions: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B frame() -> \\(aqProxy[WlCallback]\\(aq\n .sp\n-Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 3 (attached to \\fBResource\\fP instance)\n .sp\n-Notify the source\\-side available actions\n+Request a frame throttling hint\n .sp\n-This event indicates the actions offered by the data source. It will be\n-sent immediately after creating the \\fI\\%WlDataOffer\\fP object, or\n-anytime the source side changes its offered actions through\n-\\fI\\%WlDataSource.set_actions()\\fP\\&.\n+Request a notification when it is a good time to start drawing a new\n+frame, by creating a frame callback. This is useful for throttling\n+redrawing operations, and driving animations.\n+.sp\n+When a client is animating on a \\fI\\%WlSurface\\fP, it can use the\n+\\(aqframe\\(aq request to get notified when it is a good time to draw and\n+commit the next frame of animation. If the client commits an update\n+earlier than that, it is likely that some updates will not make it to\n+the display, and the client is wasting resources by drawing too often.\n+.sp\n+The frame request will take effect on the next\n+\\fI\\%WlSurface.commit()\\fP\\&. The notification will only be posted for\n+one frame unless requested again. For a \\fI\\%WlSurface\\fP, the\n+notifications are posted in the order the frame requests were\n+committed.\n+.sp\n+The server must send the notifications so that a client will not send\n+excessive updates, while still allowing the highest possible update\n+rate for clients that wait for the reply before drawing again. The\n+server should give some time for the client to draw and commit after\n+sending the frame callback events to let it hit the next output\n+refresh.\n+.sp\n+A server should avoid signaling the frame callbacks if the surface is\n+not visible in any way, e.g. the surface is off\\-screen, or completely\n+obscured by other opaque surfaces.\n+.sp\n+The object returned by this request will be destroyed by the compositor\n+after the callback is fired and as such the client must not attempt to\n+use it after that point.\n+.sp\n+The callback_data passed in the callback is the current time, in\n+milliseconds, with an undefined base.\n .INDENT 7.0\n .TP\n-.B Parameters\n-\\fBsource_actions\\fP (\\fIArgumentType.Uint\\fP) \\-\\- actions offered by the data source\n+.B Returns\n+\\fI\\%WlCallback\\fP \\-\\- callback object\n+for the frame request\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B action(dnd_action: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B set_opaque_region(region: \\(aqWlRegion | None\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 2 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 4 (attached to \\fBResource\\fP instance)\n .sp\n-Notify the selected action\n+Set opaque region\n .sp\n-This event indicates the action selected by the compositor after\n-matching the source/destination side actions. Only one action (or none)\n-will be offered here.\n+This request sets the region of the surface that contains opaque\n+content.\n .sp\n-This event can be emitted multiple times during the drag\\-and\\-drop\n-operation in response to destination side action changes through\n-\\fI\\%WlDataOffer.set_actions()\\fP\\&.\n+The opaque region is an optimization hint for the compositor that lets\n+it optimize the redrawing of content behind opaque regions. Setting an\n+opaque region is not required for correct behaviour, but marking\n+transparent content as opaque will result in repaint artifacts.\n .sp\n-This event will no longer be emitted after \\fI\\%WlDataDevice.drop()\\fP happened on the drag\\-\n-and\\-drop destination, the client must honor the last action received,\n-or the last preferred one set through \\fI\\%WlDataOffer.set_actions()\\fP\n-when handling an \\(dqask\\(dq action.\n+The opaque region is specified in surface\\-local coordinates.\n .sp\n-Compositors may also change the selected action on the fly, mainly in\n-response to keyboard modifier changes during the drag\\-and\\-drop\n-operation.\n+The compositor ignores the parts of the opaque region that fall outside\n+of the surface.\n .sp\n-The most recent action received is always the valid one. Prior to\n-receiving \\fI\\%WlDataDevice.drop()\\fP, the chosen action may\n-change (e.g. due to keyboard modifiers being pressed). At the time of\n-receiving \\fI\\%WlDataDevice.drop()\\fP the drag\\-and\\-drop\n-destination must honor the last action received.\n+Opaque region is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n .sp\n-Action changes may still happen after \\fI\\%WlDataDevice.drop()\\fP, especially on \\(dqask\\(dq\n-actions, where the drag\\-and\\-drop destination may choose another action\n-afterwards. Action changes happening at this stage are always the\n-result of inter\\-client negotiation, the compositor shall no longer be\n-able to induce a different action.\n+\\fI\\%WlSurface.set_opaque_region()\\fP changes the pending opaque\n+region. \\fI\\%WlSurface.commit()\\fP copies the pending region to the\n+current region. Otherwise, the pending and current regions are never\n+changed.\n .sp\n-Upon \\(dqask\\(dq actions, it is expected that the drag\\-and\\-drop destination\n-may potentially choose a different action and/or mime type, based on\n-\\fI\\%WlDataOffer.source_actions()\\fP and finally chosen by the user\n-(e.g. popping up a menu with the available options). The final\n-\\fI\\%WlDataOffer.set_actions()\\fP and \\fI\\%WlDataOffer.accept()\\fP\n-requests must happen before the call to \\fI\\%WlDataOffer.finish()\\fP\\&.\n+The initial value for an opaque region is empty. Setting the pending\n+opaque region has copy semantics, and the\n+\\fI\\%WlRegion\\fP object can be destroyed\n+immediately. A NULL \\fI\\%WlRegion\\fP\n+causes the pending opaque region to be set to empty.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBdnd_action\\fP (\\fIArgumentType.Uint\\fP) \\-\\- action selected by the compositor\n+\\fBregion\\fP (\\fI\\%WlRegion\\fP or \\fINone\\fP) \\-\\- opaque region of the surface\n+.UNINDENT\n .UNINDENT\n+.INDENT 7.0\n+.TP\n+.B set_input_region(region: \\(aqWlRegion | None\\(aq) -> \\(aqNone\\(aq\n+.sp\n+Request \\-\\- opcode 5 (attached to \\fBResource\\fP instance)\n+.sp\n+Set input region\n+.sp\n+This request sets the region of the surface that can receive pointer\n+and touch events.\n+.sp\n+Input events happening outside of this region will try the next surface\n+in the server surface stack. The compositor ignores the parts of the\n+input region that fall outside of the surface.\n+.sp\n+The input region is specified in surface\\-local coordinates.\n+.sp\n+Input region is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n+.sp\n+\\fI\\%WlSurface.set_input_region()\\fP changes the pending input region.\n+\\fI\\%WlSurface.commit()\\fP copies the pending region to the current\n+region. Otherwise the pending and current regions are never changed,\n+except cursor and icon surfaces are special cases, see\n+\\fI\\%WlPointer.set_cursor()\\fP and\n+\\fI\\%WlDataDevice.start_drag()\\fP\\&.\n+.sp\n+The initial value for an input region is infinite. That means the whole\n+surface will accept input. Setting the pending input region has copy\n+semantics, and the \\fI\\%WlRegion\\fP object\n+can be destroyed immediately. A NULL\n+\\fI\\%WlRegion\\fP causes the input region\n+to be set to infinite.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+\\fBregion\\fP (\\fI\\%WlRegion\\fP or \\fINone\\fP) \\-\\- input region of the surface\n .UNINDENT\n .UNINDENT\n-.SS WlSeat\n-.INDENT 0.0\n+.INDENT 7.0\n .TP\n-.B class pywayland.protocol.wayland.WlSeat\n-Group of input devices\n+.B commit() -> \\(aqNone\\(aq\n .sp\n-A seat is a group of keyboards, pointer and touch devices. This object is\n-published as a global during start up, or when such a device is hot\n-plugged. A seat typically has a pointer and maintains a keyboard focus and\n-a pointer focus.\n+Request \\-\\- opcode 6 (attached to \\fBResource\\fP instance)\n+.sp\n+Commit pending surface state\n+.sp\n+Surface state (input, opaque, and damage regions, attached buffers,\n+etc.) is double\\-buffered. Protocol requests modify the pending state,\n+as opposed to the active state in use by the compositor.\n+.sp\n+A commit request atomically creates a content update from the pending\n+state, even if the pending state has not been touched. The content\n+update is placed in a queue until it becomes active. After commit, the\n+new pending state is as documented for each related request.\n+.sp\n+When the content update is applied, the\n+\\fI\\%WlBuffer\\fP is applied before all\n+other state. This means that all coordinates in double\\-buffered state\n+are relative to the newly attached wl_buffers, except for\n+\\fI\\%WlSurface.attach()\\fP itself. If there is no newly attached\n+\\fI\\%WlBuffer\\fP, the coordinates are\n+relative to the previous content update.\n+.sp\n+All requests that need a commit to become effective are documented to\n+affect double\\-buffered state.\n+.sp\n+Other interfaces may add further double\\-buffered surface state.\n+.UNINDENT\n .INDENT 7.0\n .TP\n-.B get_pointer() -> \\(aqProxy[WlPointer]\\(aq\n+.B set_buffer_transform(transform: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+Request \\-\\- opcode 7 (attached to \\fBResource\\fP instance)\n .sp\n-Return pointer object\n+Sets the buffer transformation\n .sp\n-The ID provided will be initialized to the\n-\\fI\\%WlPointer\\fP interface for this seat.\n+This request sets the transformation that the client has already\n+applied to the content of the buffer. The accepted values for the\n+transform parameter are the values for \\fBWlOutput.transform()\\fP\\&.\n .sp\n-This request only takes effect if the seat has the pointer capability,\n-or has had the pointer capability in the past. It is a protocol\n-violation to issue this request on a seat that has never had the\n-pointer capability. The missing_capability error will be sent in this\n-case.\n+The compositor applies the inverse of this transformation whenever it\n+uses the buffer contents.\n+.sp\n+Buffer transform is double\\-buffered state, see\n+\\fI\\%WlSurface.commit()\\fP\\&.\n+.sp\n+A newly created surface has its buffer transformation set to normal.\n+.sp\n+\\fI\\%WlSurface.set_buffer_transform()\\fP changes the pending buffer\n+transformation. \\fI\\%WlSurface.commit()\\fP copies the pending buffer\n+transformation to the current one. Otherwise, the pending and current\n+values are never changed.\n+.sp\n+The purpose of this request is to allow clients to render content\n+according to the output transform, thus permitting the compositor to\n+use certain optimizations even if the display is rotated. Using\n+hardware overlays and scanning out a client buffer for fullscreen\n+surfaces are examples of such optimizations. Those optimizations are\n+highly dependent on the compositor implementation, so the use of this\n+request should be considered on a case\\-by\\-case basis.\n+.sp\n+Note that if the transform value includes 90 or 270 degree rotation,\n+the width of the buffer will become the surface height and the height\n+of the buffer will become the surface width.\n+.sp\n+If transform is not one of the values from the\n+\\fBWlOutput.transform()\\fP enum the\n+invalid_transform protocol error is raised.\n .INDENT 7.0\n .TP\n-.B Returns\n-\\fI\\%WlPointer\\fP \\-\\- seat pointer\n+.B Parameters\n+\\fBtransform\\fP (\\fIArgumentType.Int\\fP) \\-\\- transform for interpreting buffer contents\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B get_keyboard() -> \\(aqProxy[WlKeyboard]\\(aq\n+.B set_buffer_scale(scale: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n+Request \\-\\- opcode 8 (attached to \\fBResource\\fP instance)\n .sp\n-Return keyboard object\n+Sets the buffer scaling factor\n .sp\n-The ID provided will be initialized to the\n-\\fI\\%WlKeyboard\\fP interface for this\n-seat.\n+This request sets an optional scaling factor on how the compositor\n+interprets the contents of the buffer attached to the window.\n .sp\n-This request only takes effect if the seat has the keyboard capability,\n-or has had the keyboard capability in the past. It is a protocol\n-violation to issue this request on a seat that has never had the\n-keyboard capability. The missing_capability error will be sent in this\n-case.\n+Buffer scale is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n+.sp\n+A newly created surface has its buffer scale set to 1.\n+.sp\n+\\fI\\%WlSurface.set_buffer_scale()\\fP changes the pending buffer scale.\n+\\fI\\%WlSurface.commit()\\fP copies the pending buffer scale to the\n+current one. Otherwise, the pending and current values are never\n+changed.\n+.sp\n+The purpose of this request is to allow clients to supply higher\n+resolution buffer data for use on high resolution outputs. It is\n+intended that you pick the same buffer scale as the scale of the output\n+that the surface is displayed on. This means the compositor can avoid\n+scaling when rendering the surface on that output.\n+.sp\n+Note that if the scale is larger than 1, then you have to attach a\n+buffer that is larger (by a factor of scale in each dimension) than the\n+desired surface size.\n+.sp\n+If scale is not greater than 0 the invalid_scale protocol error is\n+raised.\n .INDENT 7.0\n .TP\n-.B Returns\n-\\fI\\%WlKeyboard\\fP \\-\\- seat keyboard\n+.B Parameters\n+\\fBscale\\fP (\\fIArgumentType.Int\\fP) \\-\\- scale for interpreting buffer contents\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B get_touch() -> \\(aqProxy[WlTouch]\\(aq\n+.B damage_buffer(x: \\(aqint\\(aq, y: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n+Request \\-\\- opcode 9 (attached to \\fBResource\\fP instance)\n .sp\n-Return touch object\n+Mark part of the surface damaged using buffer coordinates\n .sp\n-The ID provided will be initialized to the\n-\\fI\\%WlTouch\\fP interface for this seat.\n+This request is used to describe the regions where the pending buffer\n+is different from the current surface contents, and where the surface\n+therefore needs to be repainted. The compositor ignores the parts of\n+the damage that fall outside of the surface.\n .sp\n-This request only takes effect if the seat has the touch capability, or\n-has had the touch capability in the past. It is a protocol violation to\n-issue this request on a seat that has never had the touch capability.\n-The missing_capability error will be sent in this case.\n+Damage is double\\-buffered state, see \\fI\\%WlSurface.commit()\\fP\\&.\n+.sp\n+The damage rectangle is specified in buffer coordinates, where x and y\n+specify the upper left corner of the damage rectangle.\n+.sp\n+The initial value for pending damage is empty: no damage.\n+\\fI\\%WlSurface.damage_buffer()\\fP adds pending damage: the new pending\n+damage is the union of old pending damage and the given rectangle.\n+.sp\n+\\fI\\%WlSurface.commit()\\fP assigns pending damage as the current\n+damage, and clears pending damage. The server will clear the current\n+damage as it repaints the surface.\n+.sp\n+This request differs from \\fI\\%WlSurface.damage()\\fP in only one way \\-\n+it takes damage in buffer coordinates instead of surface\\-local\n+coordinates. While this generally is more intuitive than surface\n+coordinates, it is especially desirable when using wp_viewport or when\n+a drawing library (like EGL) is unaware of buffer scale and buffer\n+transform.\n+.sp\n+Note: Because buffer transformation changes and damage requests may be\n+interleaved in the protocol stream, it is impossible to determine the\n+actual mapping between surface and buffer damage until\n+\\fI\\%WlSurface.commit()\\fP time. Therefore, compositors wishing to take\n+both kinds of damage into account will have to accumulate damage from\n+the two requests separately and only transform from one to the other\n+after receiving the \\fI\\%WlSurface.commit()\\fP\\&.\n .INDENT 7.0\n .TP\n-.B Returns\n-\\fI\\%WlTouch\\fP \\-\\- seat touch\n-interface\n+.B Parameters\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer\\-local x coordinate\n+.IP \\(bu 2\n+\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer\\-local y coordinate\n+.IP \\(bu 2\n+\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- width of damage rectangle\n+.IP \\(bu 2\n+\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- height of damage rectangle\n+.UNINDENT\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B release() -> \\(aqNone\\(aq\n+.B offset(x: \\(aqint\\(aq, y: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 3 (attached to \\fBResource\\fP instance)\n+Request \\-\\- opcode 10 (attached to \\fBResource\\fP instance)\n .sp\n-Release the seat object\n+Set the surface contents offset\n .sp\n-Using this request a client can tell the server that it is not going to\n-use the seat object anymore.\n+The x and y arguments specify the location of the new pending buffer\\(aqs\n+upper left corner, relative to the current buffer\\(aqs upper left corner,\n+in surface\\-local coordinates. In other words, the x and y, combined\n+with the new surface size define in which directions the surface\\(aqs size\n+changes.\n+.sp\n+Surface location offset is double\\-buffered state, see\n+\\fI\\%WlSurface.commit()\\fP\\&.\n+.sp\n+This request is semantically equivalent to and the replaces the x and y\n+arguments in the \\fI\\%WlSurface.attach()\\fP request in\n+\\fI\\%WlSurface\\fP versions prior to 5. See \\fI\\%WlSurface.attach()\\fP\n+for details.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local x coordinate\n+.IP \\(bu 2\n+\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- surface\\-local y coordinate\n+.UNINDENT\n+.UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B capabilities(capabilities: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B enter(output: \\(aqWlOutput\\(aq) -> \\(aqNone\\(aq\n .sp\n Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n .sp\n-Seat capabilities changed\n+Surface enters an output\n .sp\n-This is emitted whenever a seat gains or loses the pointer, keyboard or\n-touch capabilities. The argument is a capability enum containing the\n-complete set of capabilities this seat has.\n+This is emitted whenever a surface\\(aqs creation, movement, or resizing\n+results in some part of it being within the scanout region of an\n+output.\n .sp\n-When the pointer capability is added, a client may create a\n-\\fI\\%WlPointer\\fP object using the\n-\\fI\\%WlSeat.get_pointer()\\fP request. This object will receive pointer\n-events until the capability is removed in the future.\n+Note that a surface may be overlapping with zero or more outputs.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+\\fBoutput\\fP (\\fI\\%WlOutput\\fP) \\-\\- output entered by the surface\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B leave(output: \\(aqWlOutput\\(aq) -> \\(aqNone\\(aq\n .sp\n-When the pointer capability is removed, a client should destroy the\n-\\fI\\%WlPointer\\fP objects associated with\n-the seat where the capability was removed, using the\n-\\fI\\%WlPointer.release()\\fP request. No further\n-pointer events will be received on these objects.\n+Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n .sp\n-In some compositors, if a seat regains the pointer capability and a\n-client has a previously obtained\n-\\fI\\%WlPointer\\fP object of version 4 or\n-less, that object may start sending pointer events again. This behavior\n-is considered a misinterpretation of the intended behavior and must not\n-be relied upon by the client.\n-\\fI\\%WlPointer\\fP objects of version 5 or\n-later must not send events if created before the most recent event\n-notifying the client of an added pointer capability.\n+Surface leaves an output\n .sp\n-The above behavior also applies to\n-\\fI\\%WlKeyboard\\fP and\n-\\fI\\%WlTouch\\fP with the keyboard and\n-touch capabilities, respectively.\n+This is emitted whenever a surface\\(aqs creation, movement, or resizing\n+results in it no longer having any part of it within the scanout region\n+of an output.\n+.sp\n+Clients should not use the number of outputs the surface is on for\n+frame throttling purposes. The surface might be hidden even if no leave\n+event has been sent, and the compositor might expect new surface\n+content updates even if no enter event has been sent. The frame event\n+should be used instead.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBcapabilities\\fP (\\fIArgumentType.Uint\\fP) \\-\\- capabilities of the seat\n+\\fBoutput\\fP (\\fI\\%WlOutput\\fP) \\-\\- output left by the surface\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B name(name: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n+.B preferred_buffer_scale(factor: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n+Event \\-\\- opcode 2 (attached to \\fBProxy\\fP instance)\n .sp\n-Unique identifier for this seat\n+Preferred buffer scale for the surface\n .sp\n-In a multi\\-seat configuration the seat name can be used by clients to\n-help identify which physical devices the seat represents.\n+This event indicates the preferred buffer scale for this surface. It is\n+sent whenever the compositor\\(aqs preference changes.\n .sp\n-The seat name is a UTF\\-8 string with no convention defined for its\n-contents. Each name is unique among all \\fI\\%WlSeat\\fP globals. The\n-name is only guaranteed to be unique for the current compositor\n-instance.\n+Before receiving this event the preferred buffer scale for this surface\n+is 1.\n .sp\n-The same seat names are used for all clients. Thus, the name can be\n-shared across processes to refer to a specific \\fI\\%WlSeat\\fP global.\n+It is intended that scaling aware clients use this event to scale their\n+content and use \\fI\\%WlSurface.set_buffer_scale()\\fP to indicate the\n+scale they have rendered with. This allows clients to supply a higher\n+detail buffer.\n .sp\n-The name event is sent after binding to the seat global. This event is\n-only sent once per seat object, and the name does not change over the\n-lifetime of the \\fI\\%WlSeat\\fP global.\n+The compositor shall emit a scale value greater than 0.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+\\fBfactor\\fP (\\fIArgumentType.Int\\fP) \\-\\- preferred scaling factor\n+.UNINDENT\n+.UNINDENT\n+.INDENT 7.0\n+.TP\n+.B preferred_buffer_transform(transform: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Compositors may re\\-use the same seat name if the \\fI\\%WlSeat\\fP global\n-is destroyed and re\\-created later.\n+Event \\-\\- opcode 3 (attached to \\fBProxy\\fP instance)\n+.sp\n+Preferred buffer transform for the surface\n+.sp\n+This event indicates the preferred buffer transform for this surface.\n+It is sent whenever the compositor\\(aqs preference changes.\n+.sp\n+Before receiving this event the preferred buffer transform for this\n+surface is normal.\n+.sp\n+Applying this transformation to the surface buffer contents and using\n+\\fI\\%WlSurface.set_buffer_transform()\\fP might allow the compositor to\n+use the surface buffer more efficiently.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBname\\fP (\\fIArgumentType.String\\fP) \\-\\- seat identifier\n+\\fBtransform\\fP (\\fIArgumentType.Uint\\fP) \\-\\- preferred transform\n .UNINDENT\n .UNINDENT\n .UNINDENT\n-.SS WlBuffer\n+.SS WlSubsurface\n .INDENT 0.0\n .TP\n-.B class pywayland.protocol.wayland.WlBuffer\n-Content for a \\fI\\%WlSurface\\fP\n+.B class pywayland.protocol.wayland.WlSubsurface\n+Sub\\-surface interface to a \\fI\\%WlSurface\\fP\n .sp\n-A buffer provides the content for a\n-\\fI\\%WlSurface\\fP\\&. Buffers are created through\n-factory interfaces such as \\fI\\%WlShm\\fP,\n-wp_linux_buffer_params (from the linux\\-dmabuf protocol extension) or\n-similar. It has a width and a height and can be attached to a\n-\\fI\\%WlSurface\\fP, but the mechanism by which\n-a client provides and updates the contents is defined by the buffer factory\n-interface.\n+An additional interface to a \\fI\\%WlSurface\\fP\n+object, which has been made a sub\\-surface. A sub\\-surface has one parent\n+surface. A sub\\-surface\\(aqs size and position are not limited to that of the\n+parent. Particularly, a sub\\-surface is not automatically clipped to its\n+parent\\(aqs area.\n .sp\n-Color channels are assumed to be electrical rather than optical (in other\n-words, encoded with a transfer function) unless otherwise specified. If the\n-buffer uses a format that has an alpha channel, the alpha channel is\n-assumed to be premultiplied into the electrical color channel values (after\n-transfer function encoding) unless otherwise specified.\n+A sub\\-surface becomes mapped, when a non\\-NULL\n+\\fI\\%WlBuffer\\fP is applied and the parent\n+surface is mapped. The order of which one happens first is irrelevant. A\n+sub\\-surface is hidden if the parent becomes hidden, or if a NULL\n+\\fI\\%WlBuffer\\fP is applied. These rules apply\n+recursively through the tree of surfaces.\n .sp\n-Note, because \\fI\\%WlBuffer\\fP objects are created from multiple\n-independent factory interfaces, the \\fI\\%WlBuffer\\fP interface is frozen\n-at version 1.\n+The behaviour of a \\fI\\%WlSurface.commit()\\fP request on a sub\\-surface\n+depends on the sub\\-surface\\(aqs mode. The possible modes are synchronized and\n+desynchronized, see methods \\fI\\%WlSubsurface.set_sync()\\fP and\n+\\fI\\%WlSubsurface.set_desync()\\fP\\&. Synchronized mode caches the\n+\\fI\\%WlSurface\\fP state to be applied when the\n+parent\\(aqs state gets applied, and desynchronized mode applies the pending\n+\\fI\\%WlSurface\\fP state directly. A sub\\-\n+surface is initially in the synchronized mode.\n+.sp\n+Sub\\-surfaces also have another kind of state, which is managed by\n+\\fI\\%WlSubsurface\\fP requests, as opposed to\n+\\fI\\%WlSurface\\fP requests. This state\n+includes the sub\\-surface position relative to the parent surface\n+(\\fI\\%WlSubsurface.set_position()\\fP), and the stacking order of the parent\n+and its sub\\-surfaces (\\fI\\%WlSubsurface.place_above()\\fP and .place_below).\n+This state is applied when the parent surface\\(aqs\n+\\fI\\%WlSurface\\fP state is applied, regardless\n+of the sub\\-surface\\(aqs mode. As the exception, set_sync and set_desync are\n+effective immediately.\n+.sp\n+The main surface can be thought to be always in desynchronized mode, since\n+it does not have a parent in the sub\\-surfaces sense.\n+.sp\n+Even if a sub\\-surface is in desynchronized mode, it will behave as in\n+synchronized mode, if its parent surface behaves as in synchronized mode.\n+This rule is applied recursively throughout the tree of surfaces. This\n+means, that one can set a sub\\-surface into synchronized mode, and then\n+assume that all its child and grand\\-child sub\\-surfaces are synchronized,\n+too, without explicitly setting them.\n+.sp\n+Destroying a sub\\-surface takes effect immediately. If you need to\n+synchronize the removal of a sub\\-surface to the parent surface update,\n+unmap the sub\\-surface first by attaching a NULL\n+\\fI\\%WlBuffer\\fP, update parent, and then\n+destroy the sub\\-surface.\n+.sp\n+If the parent \\fI\\%WlSurface\\fP object is\n+destroyed, the sub\\-surface is unmapped.\n+.sp\n+A sub\\-surface never has the keyboard focus of any seat.\n+.sp\n+The \\fI\\%WlSurface.offset()\\fP request is ignored: clients\n+must use set_position instead to move the sub\\-surface.\n .INDENT 7.0\n .TP\n .B destroy() -> \\(aqNone\\(aq\n .sp\n Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Destroy a buffer\n-.sp\n-Destroy a buffer. If and how you need to release the backing storage is\n-defined by the buffer factory interface.\n+Remove sub\\-surface interface\n .sp\n-For possible side\\-effects to a surface, see \\fI\\%WlSurface.attach()\\fP\\&.\n+The sub\\-surface interface is removed from the\n+\\fI\\%WlSurface\\fP object that was turned\n+into a sub\\-surface with a \\fI\\%WlSubcompositor.get_subsurface()\\fP request.\n+The wl_surface\\(aqs association to the parent is deleted. The\n+\\fI\\%WlSurface\\fP is unmapped immediately.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B release() -> \\(aqNone\\(aq\n+.B set_position(x: \\(aqint\\(aq, y: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-Compositor releases buffer\n+Reposition the sub\\-surface\n .sp\n-Sent when this \\fI\\%WlBuffer\\fP is no longer used by the compositor.\n-The client is now free to reuse or destroy this buffer and its backing\n-storage.\n+This schedules a sub\\-surface position change. The sub\\-surface will be\n+moved so that its origin (top left corner pixel) will be at the\n+location x, y of the parent surface coordinate system. The coordinates\n+are not restricted to the parent surface area. Negative values are\n+allowed.\n .sp\n-If a client receives a release event before the frame callback\n-requested in the same \\fI\\%WlSurface.commit()\\fP that attaches this\n-\\fI\\%WlBuffer\\fP to a surface, then the client is immediately free to\n-reuse the buffer and its backing storage, and does not need a second\n-buffer for the next surface content update. Typically this is possible,\n-when the compositor maintains a copy of the\n-\\fI\\%WlSurface\\fP contents, e.g. as a GL\n-texture. This is an important optimization for GL(ES) compositors with\n-\\fI\\%WlShm\\fP clients.\n+The scheduled coordinates will take effect whenever the state of the\n+parent surface is applied.\n+.sp\n+If more than one set_position request is invoked by the client before\n+the commit of the parent surface, the position of a new request always\n+replaces the scheduled position from any previous request.\n+.sp\n+The initial position is 0, 0.\n+.INDENT 7.0\n+.TP\n+.B Parameters\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- x coordinate in the parent surface\n+.IP \\(bu 2\n+\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- y coordinate in the parent surface\n+.UNINDENT\n .UNINDENT\n .UNINDENT\n-.SS WlCompositor\n-.INDENT 0.0\n-.TP\n-.B class pywayland.protocol.wayland.WlCompositor\n-The compositor singleton\n-.sp\n-A compositor. This object is a singleton global. The compositor is in\n-charge of combining the contents of multiple surfaces into one displayable\n-output.\n .INDENT 7.0\n .TP\n-.B create_surface() -> \\(aqProxy[WlSurface]\\(aq\n+.B place_above(sibling: \\(aqWlSurface\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n .sp\n-Create new surface\n+Restack the sub\\-surface\n .sp\n-Ask the compositor to create a new surface.\n+This sub\\-surface is taken from the stack, and put back just above the\n+reference surface, changing the z\\-order of the sub\\-surfaces. The\n+reference surface must be one of the sibling surfaces, or the parent\n+surface. Using any other surface, including this sub\\-surface, will\n+cause a protocol error.\n+.sp\n+The z\\-order is double\\-buffered. Requests are handled in order and\n+applied immediately to a pending state. The final pending state is\n+copied to the active state the next time the state of the parent\n+surface is applied.\n+.sp\n+A new sub\\-surface is initially added as the top\\-most in the stack of\n+its siblings and parent.\n .INDENT 7.0\n .TP\n-.B Returns\n-\\fI\\%WlSurface\\fP \\-\\- the new surface\n+.B Parameters\n+\\fBsibling\\fP (\\fI\\%WlSurface\\fP) \\-\\- the reference surface\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B create_region() -> \\(aqProxy[WlRegion]\\(aq\n+.B place_below(sibling: \\(aqWlSurface\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n+Request \\-\\- opcode 3 (attached to \\fBResource\\fP instance)\n .sp\n-Create new region\n+Restack the sub\\-surface\n .sp\n-Ask the compositor to create a new region.\n+The sub\\-surface is placed just below the reference surface. See\n+\\fI\\%WlSubsurface.place_above()\\fP\\&.\n .INDENT 7.0\n .TP\n-.B Returns\n-\\fI\\%WlRegion\\fP \\-\\- the new region\n-.UNINDENT\n+.B Parameters\n+\\fBsibling\\fP (\\fI\\%WlSurface\\fP) \\-\\- the reference surface\n .UNINDENT\n .UNINDENT\n-.SS WlCallback\n-.INDENT 0.0\n+.INDENT 7.0\n .TP\n-.B class pywayland.protocol.wayland.WlCallback\n-Callback object\n+.B set_sync() -> \\(aqNone\\(aq\n .sp\n-Clients can handle the \\(aqdone\\(aq event to get notified when the related\n-request is done.\n+Request \\-\\- opcode 4 (attached to \\fBResource\\fP instance)\n .sp\n-Note, because \\fI\\%WlCallback\\fP objects are created from multiple\n-independent factory interfaces, the \\fI\\%WlCallback\\fP interface is frozen\n-at version 1.\n-.INDENT 7.0\n-.TP\n-.B done(callback_data: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+Set sub\\-surface to synchronized mode\n .sp\n-Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n+Change the commit behaviour of the sub\\-surface to synchronized mode,\n+also described as the parent dependent mode.\n .sp\n-Done event\n+In synchronized mode, \\fI\\%WlSurface.commit()\\fP on a sub\\-surface will\n+accumulate the committed state in a cache, but the state will not be\n+applied and hence will not change the compositor output. The cached\n+state is applied to the sub\\-surface immediately after the parent\n+surface\\(aqs state is applied. This ensures atomic updates of the parent\n+and all its synchronized sub\\-surfaces. Applying the cached state will\n+invalidate the cache, so further parent surface commits do not\n+(re\\-)apply old state.\n .sp\n-Notify the client when the related request is done.\n+See \\fI\\%WlSubsurface\\fP for the recursive effect of this mode.\n+.UNINDENT\n .INDENT 7.0\n .TP\n-.B Parameters\n-\\fBcallback_data\\fP (\\fIArgumentType.Uint\\fP) \\-\\- request\\-specific data for the callback\n-.UNINDENT\n+.B set_desync() -> \\(aqNone\\(aq\n+.sp\n+Request \\-\\- opcode 5 (attached to \\fBResource\\fP instance)\n+.sp\n+Set sub\\-surface to desynchronized mode\n+.sp\n+Change the commit behaviour of the sub\\-surface to desynchronized mode,\n+also described as independent or freely running mode.\n+.sp\n+In desynchronized mode, \\fI\\%WlSurface.commit()\\fP on a sub\\-surface will\n+apply the pending state directly, without caching, as happens normally\n+with a \\fI\\%WlSurface\\fP\\&. Calling\n+\\fI\\%WlSurface.commit()\\fP on the parent surface\n+has no effect on the sub\\-surface\\(aqs\n+\\fI\\%WlSurface\\fP state. This mode allows\n+a sub\\-surface to be updated on its own.\n+.sp\n+If cached state exists when \\fI\\%WlSurface.commit()\\fP is called in\n+desynchronized mode, the pending state is added to the cached state,\n+and applied as a whole. This invalidates the cache.\n+.sp\n+Note: even if a sub\\-surface is set to desynchronized, a parent sub\\-\n+surface may override it to behave as synchronized. For details, see\n+\\fI\\%WlSubsurface\\fP\\&.\n+.sp\n+If a surface\\(aqs parent surface behaves as desynchronized, then the\n+cached state is applied on set_desync.\n .UNINDENT\n .UNINDENT\n .SS WlKeyboard\n .INDENT 0.0\n .TP\n .B class pywayland.protocol.wayland.WlKeyboard\n Keyboard input device\n@@ -4349,409 +4699,174 @@\n \\fBrate\\fP (\\fIArgumentType.Int\\fP) \\-\\- the rate of repeating keys in characters per second\n .IP \\(bu 2\n \\fBdelay\\fP (\\fIArgumentType.Int\\fP) \\-\\- delay in milliseconds since key down until repeating starts\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .UNINDENT\n-.SS WlOutput\n+.SS WlSeat\n .INDENT 0.0\n .TP\n-.B class pywayland.protocol.wayland.WlOutput\n-Compositor output region\n+.B class pywayland.protocol.wayland.WlSeat\n+Group of input devices\n .sp\n-An output describes part of the compositor geometry. The compositor works\n-in the \\(aqcompositor coordinate system\\(aq and an output corresponds to a\n-rectangular area in that space that is actually visible. This typically\n-corresponds to a monitor that displays part of the compositor space. This\n-object is published as global during start up, or when a monitor is\n-hotplugged.\n+A seat is a group of keyboards, pointer and touch devices. This object is\n+published as a global during start up, or when such a device is hot\n+plugged. A seat typically has a pointer and maintains a keyboard focus and\n+a pointer focus.\n .INDENT 7.0\n .TP\n-.B release() -> \\(aqNone\\(aq\n+.B get_pointer() -> \\(aqProxy[WlPointer]\\(aq\n .sp\n Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Release the output object\n-.sp\n-Using this request a client can tell the server that it is not going to\n-use the output object anymore.\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.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\n-.sp\n-Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n-.sp\n-Properties of the output\n-.sp\n-The geometry event describes geometric properties of the output. The\n-event is sent when binding to the output object and whenever any of the\n-properties change.\n-.sp\n-The physical size can be set to zero if it doesn\\(aqt make sense for this\n-output (e.g. for projectors or virtual outputs).\n-.sp\n-The geometry event will be followed by a done event (starting from\n-version 2).\n-.sp\n-Clients should use \\fI\\%WlSurface.preferred_buffer_transform()\\fP\n-instead of the transform advertised by this event to find the preferred\n-buffer transform to use for a surface.\n-.sp\n-Note: \\fI\\%WlOutput\\fP only advertises partial information about the\n-output position and identification. Some compositors, for instance\n-those not implementing a desktop\\-style output layout or those exposing\n-virtual outputs, might fake this information. Instead of using x and y,\n-clients should use xdg_output.logical_position. Instead of using make\n-and model, clients should use name and description.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- x position within the global compositor space\n-.IP \\(bu 2\n-\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- y position within the global compositor space\n-.IP \\(bu 2\n-\\fBphysical_width\\fP (\\fIArgumentType.Int\\fP) \\-\\- width in millimeters of the output\n-.IP \\(bu 2\n-\\fBphysical_height\\fP (\\fIArgumentType.Int\\fP) \\-\\- height in millimeters of the output\n-.IP \\(bu 2\n-\\fBsubpixel\\fP (\\fIArgumentType.Int\\fP) \\-\\- subpixel orientation of the output\n-.IP \\(bu 2\n-\\fBmake\\fP (\\fIArgumentType.String\\fP) \\-\\- textual description of the manufacturer\n-.IP \\(bu 2\n-\\fBmodel\\fP (\\fIArgumentType.String\\fP) \\-\\- textual description of the model\n-.IP \\(bu 2\n-\\fBtransform\\fP (\\fIArgumentType.Int\\fP) \\-\\- additional transformation applied to buffer contents during\n-presentation\n-.UNINDENT\n-.UNINDENT\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B mode(flags: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq, refresh: \\(aqint\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n-.sp\n-Advertise available modes for the output\n-.sp\n-The mode event describes an available mode for the output.\n-.sp\n-The event is sent when binding to the output object and there will\n-always be one mode, the current mode. The event is sent again if an\n-output changes mode, for the mode that is now current. In other words,\n-the current mode is always the last mode that was received with the\n-current flag set.\n-.sp\n-Non\\-current modes are deprecated. A compositor can decide to only\n-advertise the current mode and never send other modes. Clients should\n-not rely on non\\-current modes.\n-.sp\n-The size of a mode is given in physical hardware units of the output\n-device. This is not necessarily the same as the output size in the\n-global compositor space. For instance, the output may be scaled, as\n-described in \\fI\\%WlOutput.scale()\\fP, or transformed, as described in\n-\\fBWlOutput.transform()\\fP\\&. Clients willing to retrieve the output\n-size in the global compositor space should use xdg_output.logical_size\n-instead.\n-.sp\n-The vertical refresh rate can be set to zero if it doesn\\(aqt make sense\n-for this output (e.g. for virtual outputs).\n-.sp\n-The mode event will be followed by a done event (starting from version\n-2).\n+Return pointer object\n .sp\n-Clients should not use the refresh rate to schedule frames. Instead,\n-they should use the \\fI\\%WlSurface.frame()\\fP event or the\n-presentation\\-time protocol.\n+The ID provided will be initialized to the\n+\\fI\\%WlPointer\\fP interface for this seat.\n .sp\n-Note: this information is not always meaningful for all outputs. Some\n-compositors, such as those exposing virtual outputs, might fake the\n-refresh rate or the size.\n+This request only takes effect if the seat has the pointer capability,\n+or has had the pointer capability in the past. It is a protocol\n+violation to issue this request on a seat that has never had the\n+pointer capability. The missing_capability error will be sent in this\n+case.\n .INDENT 7.0\n .TP\n-.B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBflags\\fP (\\fIArgumentType.Uint\\fP) \\-\\- bitfield of mode flags\n-.IP \\(bu 2\n-\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- width of the mode in hardware units\n-.IP \\(bu 2\n-\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- height of the mode in hardware units\n-.IP \\(bu 2\n-\\fBrefresh\\fP (\\fIArgumentType.Int\\fP) \\-\\- vertical refresh rate in mHz\n-.UNINDENT\n+.B Returns\n+\\fI\\%WlPointer\\fP \\-\\- seat pointer\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B done() -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 2 (attached to \\fBProxy\\fP instance)\n-.sp\n-Sent all information about output\n-.sp\n-This event is sent after all other properties have been sent after\n-binding to the output object and after any other property changes done\n-after that. This allows changes to the output properties to be seen as\n-atomic, even if they happen via multiple events.\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B scale(factor: \\(aqint\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 3 (attached to \\fBProxy\\fP instance)\n-.sp\n-Output scaling properties\n+.B get_keyboard() -> \\(aqProxy[WlKeyboard]\\(aq\n .sp\n-This event contains scaling geometry information that is not in the\n-geometry event. It may be sent after binding the output object or if\n-the output scale changes later. The compositor will emit a non\\-zero,\n-positive value for scale. If it is not sent, the client should assume a\n-scale of 1.\n+Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-A scale larger than 1 means that the compositor will automatically\n-scale surface buffers by this amount when rendering. This is used for\n-very high resolution displays where applications rendering at the\n-native resolution would be too small to be legible.\n+Return keyboard object\n .sp\n-Clients should use \\fI\\%WlSurface.preferred_buffer_scale()\\fP instead\n-of this event to find the preferred buffer scale to use for a surface.\n+The ID provided will be initialized to the\n+\\fI\\%WlKeyboard\\fP interface for this\n+seat.\n .sp\n-The scale event will be followed by a done event.\n+This request only takes effect if the seat has the keyboard capability,\n+or has had the keyboard capability in the past. It is a protocol\n+violation to issue this request on a seat that has never had the\n+keyboard capability. The missing_capability error will be sent in this\n+case.\n .INDENT 7.0\n .TP\n-.B Parameters\n-\\fBfactor\\fP (\\fIArgumentType.Int\\fP) \\-\\- scaling factor of output\n+.B Returns\n+\\fI\\%WlKeyboard\\fP \\-\\- seat keyboard\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B name(name: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 4 (attached to \\fBProxy\\fP instance)\n-.sp\n-Name of this output\n-.sp\n-Many compositors will assign user\\-friendly names to their outputs, show\n-them to the user, allow the user to refer to an output, etc. The client\n-may wish to know this name as well to offer the user similar behaviors.\n-.sp\n-The name is a UTF\\-8 string with no convention defined for its contents.\n-Each name is unique among all \\fI\\%WlOutput\\fP globals. The name is\n-only guaranteed to be unique for the compositor instance.\n-.sp\n-The same output name is used for all clients for a given\n-\\fI\\%WlOutput\\fP global. Thus, the name can be shared across processes\n-to refer to a specific \\fI\\%WlOutput\\fP global.\n-.sp\n-The name is not guaranteed to be persistent across sessions, thus\n-cannot be used to reliably identify an output in e.g. configuration\n-files.\n+.B get_touch() -> \\(aqProxy[WlTouch]\\(aq\n .sp\n-Examples of names include \\(aqHDMI\\-A\\-1\\(aq, \\(aqWL\\-1\\(aq, \\(aqX11\\-1\\(aq, etc. However, do\n-not assume that the name is a reflection of an underlying DRM\n-connector, X11 connection, etc.\n+Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n .sp\n-The name event is sent after binding the output object. This event is\n-only sent once per output object, and the name does not change over the\n-lifetime of the \\fI\\%WlOutput\\fP global.\n+Return touch object\n .sp\n-Compositors may re\\-use the same output name if the \\fI\\%WlOutput\\fP\n-global is destroyed and re\\-created later. Compositors should avoid re\\-\n-using the same name if possible.\n+The ID provided will be initialized to the\n+\\fI\\%WlTouch\\fP interface for this seat.\n .sp\n-The name event will be followed by a done event.\n+This request only takes effect if the seat has the touch capability, or\n+has had the touch capability in the past. It is a protocol violation to\n+issue this request on a seat that has never had the touch capability.\n+The missing_capability error will be sent in this case.\n .INDENT 7.0\n .TP\n-.B Parameters\n-\\fBname\\fP (\\fIArgumentType.String\\fP) \\-\\- output name\n+.B Returns\n+\\fI\\%WlTouch\\fP \\-\\- seat touch\n+interface\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B description(description: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 5 (attached to \\fBProxy\\fP instance)\n-.sp\n-Human\\-readable description of this output\n-.sp\n-Many compositors can produce human\\-readable descriptions of their\n-outputs. The client may wish to know this description as well, e.g. for\n-output selection purposes.\n+.B release() -> \\(aqNone\\(aq\n .sp\n-The description is a UTF\\-8 string with no convention defined for its\n-contents. The description is not guaranteed to be unique among all\n-\\fI\\%WlOutput\\fP globals. Examples might include \\(aqFoocorp 11\\(dq Display\\(aq\n-or \\(aqVirtual X11 output via :1\\(aq.\n+Request \\-\\- opcode 3 (attached to \\fBResource\\fP instance)\n .sp\n-The description event is sent after binding the output object and\n-whenever the description changes. The description is optional, and may\n-not be sent at all.\n+Release the seat object\n .sp\n-The description event will be followed by a done event.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-\\fBdescription\\fP (\\fIArgumentType.String\\fP) \\-\\- output description\n-.UNINDENT\n-.UNINDENT\n+Using this request a client can tell the server that it is not going to\n+use the seat object anymore.\n .UNINDENT\n-.SS WlRegistry\n-.INDENT 0.0\n-.TP\n-.B class pywayland.protocol.wayland.WlRegistry\n-Global registry object\n-.sp\n-The singleton global registry object. The server has a number of global\n-objects that are available to all clients. These objects typically\n-represent an actual object in the server (for example, an input device) or\n-they are singleton objects that provide extension functionality.\n-.sp\n-When a client creates a registry object, the registry object will emit a\n-global event for each global currently in the registry. Globals come and\n-go as a result of device or monitor hotplugs, reconfiguration or other\n-events, and the registry will send out global and global_remove events to\n-keep the client up to date with the changes. To mark the end of the\n-initial burst of events, the client can use the \\fI\\%WlDisplay.sync()\\fP request immediately after\n-calling \\fI\\%WlDisplay.get_registry()\\fP\\&.\n-.sp\n-A client can bind to a global object by using the bind request. This\n-creates a client\\-side handle that lets the object emit events to the client\n-and lets the client invoke requests on the object.\n .INDENT 7.0\n .TP\n-.B bind(name: \\(aqint\\(aq, interface: \\(aqtype[T]\\(aq, version: \\(aqint\\(aq) -> \\(aqProxy[T]\\(aq\n+.B capabilities(capabilities: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n .sp\n-Bind an object to the display\n+Seat capabilities changed\n .sp\n-Binds a new, client\\-created object to the server using the specified\n-name as the identifier.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBname\\fP (\\fIArgumentType.Uint\\fP) \\-\\- unique numeric name of the object\n-.IP \\(bu 2\n-\\fBinterface\\fP (\\fIstring\\fP) \\-\\- Interface name\n-.IP \\(bu 2\n-\\fBversion\\fP (\\fIint\\fP) \\-\\- Interface version\n-.UNINDENT\n-.TP\n-.B Returns\n-\\fBpywayland.client.proxy.Proxy\\fP of specified Interface \\-\\-\n-bounded object\n-.UNINDENT\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B global_(name: \\(aqint\\(aq, interface: \\(aqstr\\(aq, version: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+This is emitted whenever a seat gains or loses the pointer, keyboard or\n+touch capabilities. The argument is a capability enum containing the\n+complete set of capabilities this seat has.\n .sp\n-Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n+When the pointer capability is added, a client may create a\n+\\fI\\%WlPointer\\fP object using the\n+\\fI\\%WlSeat.get_pointer()\\fP request. This object will receive pointer\n+events until the capability is removed in the future.\n .sp\n-Announce global object\n+When the pointer capability is removed, a client should destroy the\n+\\fI\\%WlPointer\\fP objects associated with\n+the seat where the capability was removed, using the\n+\\fI\\%WlPointer.release()\\fP request. No further\n+pointer events will be received on these objects.\n .sp\n-Notify the client of global objects.\n+In some compositors, if a seat regains the pointer capability and a\n+client has a previously obtained\n+\\fI\\%WlPointer\\fP object of version 4 or\n+less, that object may start sending pointer events again. This behavior\n+is considered a misinterpretation of the intended behavior and must not\n+be relied upon by the client.\n+\\fI\\%WlPointer\\fP objects of version 5 or\n+later must not send events if created before the most recent event\n+notifying the client of an added pointer capability.\n .sp\n-The event notifies the client that a global object with the given name\n-is now available, and it implements the given version of the given\n-interface.\n+The above behavior also applies to\n+\\fI\\%WlKeyboard\\fP and\n+\\fI\\%WlTouch\\fP with the keyboard and\n+touch capabilities, respectively.\n .INDENT 7.0\n .TP\n .B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBname\\fP (\\fIArgumentType.Uint\\fP) \\-\\- numeric name of the global object\n-.IP \\(bu 2\n-\\fBinterface\\fP (\\fIArgumentType.String\\fP) \\-\\- interface implemented by the object\n-.IP \\(bu 2\n-\\fBversion\\fP (\\fIArgumentType.Uint\\fP) \\-\\- interface version\n-.UNINDENT\n+\\fBcapabilities\\fP (\\fIArgumentType.Uint\\fP) \\-\\- capabilities of the seat\n .UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B global_remove(name: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B name(name: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n .sp\n Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n .sp\n-Announce removal of global object\n-.sp\n-Notify the client of removed global objects.\n-.sp\n-This event notifies the client that the global identified by name is no\n-longer available. If the client bound to the global using the bind\n-request, the client should now destroy that object.\n-.sp\n-The object remains valid and requests to the object will be ignored\n-until the client destroys it, to avoid races between the global going\n-away and a client sending a request to it.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-\\fBname\\fP (\\fIArgumentType.Uint\\fP) \\-\\- numeric name of the global object\n-.UNINDENT\n-.UNINDENT\n-.UNINDENT\n-.SS WlDataDeviceManager\n-.INDENT 0.0\n-.TP\n-.B class pywayland.protocol.wayland.WlDataDeviceManager\n-Data transfer interface\n-.sp\n-The \\fI\\%WlDataDeviceManager\\fP is a singleton global object that provides\n-access to inter\\-client data transfer mechanisms such as copy\\-and\\-paste and\n-drag\\-and\\-drop. These mechanisms are tied to a\n-\\fI\\%WlSeat\\fP and this interface lets a\n-client get a \\fI\\%WlDataDevice\\fP\n-corresponding to a \\fI\\%WlSeat\\fP\\&.\n-.sp\n-Depending on the version bound, the objects created from the bound\n-\\fI\\%WlDataDeviceManager\\fP object will have different requirements for\n-functioning properly. See \\fI\\%WlDataSource.set_actions()\\fP,\n-\\fI\\%WlDataOffer.accept()\\fP and\n-\\fI\\%WlDataOffer.finish()\\fP for details.\n-.INDENT 7.0\n-.TP\n-.B create_data_source() -> \\(aqProxy[WlDataSource]\\(aq\n-.sp\n-Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n+Unique identifier for this seat\n .sp\n-Create a new data source\n+In a multi\\-seat configuration the seat name can be used by clients to\n+help identify which physical devices the seat represents.\n .sp\n-Create a new data source.\n-.INDENT 7.0\n-.TP\n-.B Returns\n-\\fI\\%WlDataSource\\fP \\-\\- data source to\n-create\n-.UNINDENT\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B get_data_device(seat: \\(aqWlSeat\\(aq) -> \\(aqProxy[WlDataDevice]\\(aq\n+The seat name is a UTF\\-8 string with no convention defined for its\n+contents. Each name is unique among all \\fI\\%WlSeat\\fP globals. The\n+name is only guaranteed to be unique for the current compositor\n+instance.\n .sp\n-Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n+The same seat names are used for all clients. Thus, the name can be\n+shared across processes to refer to a specific \\fI\\%WlSeat\\fP global.\n .sp\n-Create a new data device\n+The name event is sent after binding to the seat global. This event is\n+only sent once per seat object, and the name does not change over the\n+lifetime of the \\fI\\%WlSeat\\fP global.\n .sp\n-Create a new data device for a given seat.\n+Compositors may re\\-use the same seat name if the \\fI\\%WlSeat\\fP global\n+is destroyed and re\\-created later.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBseat\\fP (\\fI\\%WlSeat\\fP) \\-\\- seat associated with the data device\n-.TP\n-.B Returns\n-\\fI\\%WlDataDevice\\fP \\-\\- data device to\n-create\n+\\fBname\\fP (\\fIArgumentType.String\\fP) \\-\\- seat identifier\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .SS WlShell\n .INDENT 0.0\n .TP\n .B class pywayland.protocol.wayland.WlShell\n@@ -4787,277 +4902,162 @@\n .TP\n .B Returns\n \\fI\\%WlShellSurface\\fP \\-\\- shell\n surface to create\n .UNINDENT\n .UNINDENT\n .UNINDENT\n-.SS WlShm\n+.SS WlRegion\n .INDENT 0.0\n .TP\n-.B class pywayland.protocol.wayland.WlShm\n-Shared memory support\n-.sp\n-A singleton global object that provides support for shared memory.\n+.B class pywayland.protocol.wayland.WlRegion\n+Region interface\n .sp\n-Clients can create \\fI\\%WlShmPool\\fP objects\n-using the create_pool request.\n+A region object describes an area.\n .sp\n-On binding the \\fI\\%WlShm\\fP object one or more format events are emitted\n-to inform clients about the valid pixel formats that can be used for\n-buffers.\n+Region objects are used to describe the opaque and input regions of a\n+surface.\n .INDENT 7.0\n .TP\n-.B create_pool(fd: \\(aqint\\(aq, size: \\(aqint\\(aq) -> \\(aqProxy[WlShmPool]\\(aq\n+.B destroy() -> \\(aqNone\\(aq\n .sp\n Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Create a shm pool\n-.sp\n-Create a new \\fI\\%WlShmPool\\fP object.\n+Destroy region\n .sp\n-The pool can be used to create shared memory based buffer objects. The\n-server will mmap size bytes of the passed file descriptor, to use as\n-backing memory for the pool.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBfd\\fP (\\fIArgumentType.FileDescriptor\\fP) \\-\\- file descriptor for the pool\n-.IP \\(bu 2\n-\\fBsize\\fP (\\fIArgumentType.Int\\fP) \\-\\- pool size, in bytes\n-.UNINDENT\n-.TP\n-.B Returns\n-\\fI\\%WlShmPool\\fP \\-\\- pool to create\n-.UNINDENT\n+Destroy the region. This will invalidate the object ID.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B release() -> \\(aqNone\\(aq\n+.B add(x: \\(aqint\\(aq, y: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-Release the shm object\n-.sp\n-Using this request a client can tell the server that it is not going to\n-use the shm object anymore.\n-.sp\n-Objects created via this interface remain unaffected.\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B format(format: \\(aqint\\(aq) -> \\(aqNone\\(aq\n-.sp\n-Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n-.sp\n-Pixel format description\n+Add rectangle to region\n .sp\n-Informs the client about a valid pixel format that can be used for\n-buffers. Known formats include argb8888 and xrgb8888.\n+Add the specified rectangle to the region.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBformat\\fP (\\fIArgumentType.Uint\\fP) \\-\\- buffer pixel format\n-.UNINDENT\n-.UNINDENT\n-.UNINDENT\n-.SS WlDisplay\n-.INDENT 0.0\n-.TP\n-.B class pywayland.protocol.wayland.WlDisplay\n-Core global object\n-.sp\n-The core global object. This is a special singleton object. It is used\n-for internal Wayland protocol features.\n-.INDENT 7.0\n-.TP\n-.B sync() -> \\(aqProxy[WlCallback]\\(aq\n-.sp\n-Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n-.sp\n-Asynchronous roundtrip\n-.sp\n-The sync request asks the server to emit the \\(aqdone\\(aq event on the\n-returned \\fI\\%WlCallback\\fP object. Since\n-requests are handled in\\-order and events are delivered in\\-order, this\n-can be used as a barrier to ensure all previous requests and the\n-resulting events have been handled.\n-.sp\n-The object returned by this request will be destroyed by the compositor\n-after the callback is fired and as such the client must not attempt to\n-use it after that point.\n-.sp\n-The callback_data passed in the callback is undefined and should be\n-ignored.\n .INDENT 7.0\n-.TP\n-.B Returns\n-\\fI\\%WlCallback\\fP \\-\\- callback object\n-for the sync request\n+.IP \\(bu 2\n+\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- region\\-local x coordinate\n+.IP \\(bu 2\n+\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- region\\-local y coordinate\n+.IP \\(bu 2\n+\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- rectangle width\n+.IP \\(bu 2\n+\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- rectangle height\n .UNINDENT\n .UNINDENT\n-.INDENT 7.0\n-.TP\n-.B get_registry() -> \\(aqProxy[WlRegistry]\\(aq\n-.sp\n-Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n-.sp\n-Get global registry object\n-.sp\n-This request creates a registry object that allows the client to list\n-and bind the global objects available from the compositor.\n-.sp\n-It should be noted that the server side resources consumed in response\n-to a get_registry request can only be released when the client\n-disconnects, not when the client side proxy is destroyed. Therefore,\n-clients should invoke get_registry as infrequently as possible to avoid\n-wasting memory.\n-.INDENT 7.0\n-.TP\n-.B Returns\n-\\fI\\%WlRegistry\\fP \\-\\- global registry\n-object\n-.UNINDENT\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B error(object_id: \\(aqAny\\(aq, code: \\(aqint\\(aq, message: \\(aqstr\\(aq) -> \\(aqNone\\(aq\n+.B subtract(x: \\(aqint\\(aq, y: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq) -> \\(aqNone\\(aq\n .sp\n-Event \\-\\- opcode 0 (attached to \\fBProxy\\fP instance)\n+Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n .sp\n-Fatal error event\n+Subtract rectangle from region\n .sp\n-The error event is sent out when a fatal (non\\-recoverable) error has\n-occurred. The object_id argument is the object where the error\n-occurred, most often in response to a request to that object. The code\n-identifies the error and is defined by the object interface. As such,\n-each interface defines its own set of error codes. The message is a\n-brief description of the error, for (debugging) convenience.\n+Subtract the specified rectangle from the region.\n .INDENT 7.0\n .TP\n .B Parameters\n .INDENT 7.0\n .IP \\(bu 2\n-\\fBobject_id\\fP (\\fIArgumentType.Object\\fP) \\-\\- object where the error occurred\n+\\fBx\\fP (\\fIArgumentType.Int\\fP) \\-\\- region\\-local x coordinate\n .IP \\(bu 2\n-\\fBcode\\fP (\\fIArgumentType.Uint\\fP) \\-\\- error code\n+\\fBy\\fP (\\fIArgumentType.Int\\fP) \\-\\- region\\-local y coordinate\n .IP \\(bu 2\n-\\fBmessage\\fP (\\fIArgumentType.String\\fP) \\-\\- error description\n+\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- rectangle width\n+.IP \\(bu 2\n+\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- rectangle height\n .UNINDENT\n .UNINDENT\n .UNINDENT\n-.INDENT 7.0\n+.UNINDENT\n+.SS WlSubcompositor\n+.INDENT 0.0\n .TP\n-.B delete_id(id: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+.B class pywayland.protocol.wayland.WlSubcompositor\n+Sub\\-surface compositing\n .sp\n-Event \\-\\- opcode 1 (attached to \\fBProxy\\fP instance)\n+The global interface exposing sub\\-surface compositing capabilities. A\n+\\fI\\%WlSurface\\fP, that has sub\\-surfaces\n+associated, is called the parent surface. Sub\\-surfaces can be arbitrarily\n+nested and create a tree of sub\\-surfaces.\n .sp\n-Acknowledge object id deletion\n+The root surface in a tree of sub\\-surfaces is the main surface. The main\n+surface cannot be a sub\\-surface, because sub\\-surfaces must always have a\n+parent.\n .sp\n-This event is used internally by the object ID management logic. When a\n-client deletes an object that it had created, the server will send this\n-event to acknowledge that it has seen the delete request. When the\n-client receives this event, it will know that it can safely reuse the\n-object ID.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-\\fBid\\fP (\\fIArgumentType.Uint\\fP) \\-\\- deleted object ID\n-.UNINDENT\n-.UNINDENT\n-.UNINDENT\n-.SS WlShmPool\n-.INDENT 0.0\n-.TP\n-.B class pywayland.protocol.wayland.WlShmPool\n-A shared memory pool\n+A main surface with its sub\\-surfaces forms a (compound) window. For window\n+management purposes, this set of\n+\\fI\\%WlSurface\\fP objects is to be considered\n+as a single window, and it should also behave as such.\n .sp\n-The \\fI\\%WlShmPool\\fP object encapsulates a piece of memory shared between\n-the compositor and client. Through the \\fI\\%WlShmPool\\fP object, the\n-client can allocate shared memory\n-\\fI\\%WlBuffer\\fP objects. All objects created\n-through the same pool share the same underlying mapped memory. Reusing the\n-mapped memory avoids the setup/teardown overhead and is useful when\n-interactively resizing a surface or for many small buffers.\n+The aim of sub\\-surfaces is to offload some of the compositing work within a\n+window from clients to the compositor. A prime example is a video player\n+with decorations and video in separate\n+\\fI\\%WlSurface\\fP objects. This should allow\n+the compositor to pass YUV video buffer processing to dedicated overlay\n+hardware when possible.\n .INDENT 7.0\n .TP\n-.B create_buffer(offset: \\(aqint\\(aq, width: \\(aqint\\(aq, height: \\(aqint\\(aq, stride: \\(aqint\\(aq, format: \\(aqint\\(aq) -> \\(aqProxy[WlBuffer]\\(aq\n+.B destroy() -> \\(aqNone\\(aq\n .sp\n Request \\-\\- opcode 0 (attached to \\fBResource\\fP instance)\n .sp\n-Create a buffer from the pool\n-.sp\n-Create a \\fI\\%WlBuffer\\fP object from the\n-pool.\n-.sp\n-The buffer is created offset bytes into the pool and has width and\n-height as specified. The stride argument specifies the number of bytes\n-from the beginning of one row to the beginning of the next. The format\n-is the pixel format of the buffer and must be one of those advertised\n-through the \\fI\\%WlShm.format()\\fP event.\n+Unbind from the subcompositor interface\n .sp\n-A buffer will keep a reference to the pool it was created from so it is\n-valid to destroy the pool immediately after creating a buffer from it.\n-.INDENT 7.0\n-.TP\n-.B Parameters\n-.INDENT 7.0\n-.IP \\(bu 2\n-\\fBoffset\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer byte offset within the pool\n-.IP \\(bu 2\n-\\fBwidth\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer width, in pixels\n-.IP \\(bu 2\n-\\fBheight\\fP (\\fIArgumentType.Int\\fP) \\-\\- buffer height, in pixels\n-.IP \\(bu 2\n-\\fBstride\\fP (\\fIArgumentType.Int\\fP) \\-\\- number of bytes from the beginning of one row to the beginning of\n-the next row\n-.IP \\(bu 2\n-\\fBformat\\fP (\\fIArgumentType.Uint\\fP) \\-\\- buffer pixel format\n-.UNINDENT\n-.TP\n-.B Returns\n-\\fI\\%WlBuffer\\fP \\-\\- buffer to create\n-.UNINDENT\n+Informs the server that the client will not be using this protocol\n+object anymore. This does not affect any other objects,\n+\\fI\\%WlSubsurface\\fP objects included.\n .UNINDENT\n .INDENT 7.0\n .TP\n-.B destroy() -> \\(aqNone\\(aq\n+.B get_subsurface(surface: \\(aqWlSurface\\(aq, parent: \\(aqWlSurface\\(aq) -> \\(aqProxy[WlSubsurface]\\(aq\n .sp\n Request \\-\\- opcode 1 (attached to \\fBResource\\fP instance)\n .sp\n-Destroy the pool\n-.sp\n-Destroy the shared memory pool.\n+Give a surface the role sub\\-surface\n .sp\n-The mmapped memory will be released when all buffers that have been\n-created from this pool are gone.\n-.UNINDENT\n-.INDENT 7.0\n-.TP\n-.B resize(size: \\(aqint\\(aq) -> \\(aqNone\\(aq\n+Create a sub\\-surface interface for the given surface, and associate it\n+with the given parent surface. This turns a plain\n+\\fI\\%WlSurface\\fP into a sub\\-surface.\n .sp\n-Request \\-\\- opcode 2 (attached to \\fBResource\\fP instance)\n+The to\\-be sub\\-surface must not already have another role, and it must\n+not have an existing \\fI\\%WlSubsurface\\fP\n+object. Otherwise the bad_surface protocol error is raised.\n .sp\n-Change the size of the pool mapping\n+Adding sub\\-surfaces to a parent is a double\\-buffered operation on the\n+parent (see \\fI\\%WlSurface.commit()\\fP). The effect of adding a\n+sub\\-surface becomes visible on the next time the state of the parent\n+surface is applied.\n .sp\n-This request will cause the server to remap the backing memory for the\n-pool from the file descriptor passed when the pool was created, but\n-using the new size. This request can only be used to make the pool\n-bigger.\n+The parent surface must not be one of the child surface\\(aqs descendants,\n+and the parent must be different from the child surface, otherwise the\n+bad_parent protocol error is raised.\n .sp\n-This request only changes the amount of bytes that are mmapped by the\n-server and does not touch the file corresponding to the file descriptor\n-passed at creation time. It is the client\\(aqs responsibility to ensure\n-that the file is at least as big as the new pool size.\n+This request modifies the behaviour of \\fI\\%WlSurface.commit()\\fP request on the sub\\-\n+surface, see the documentation on\n+\\fI\\%WlSubsurface\\fP interface.\n .INDENT 7.0\n .TP\n .B Parameters\n-\\fBsize\\fP (\\fIArgumentType.Int\\fP) \\-\\- new size of the pool, in bytes\n+.INDENT 7.0\n+.IP \\(bu 2\n+\\fBsurface\\fP (\\fI\\%WlSurface\\fP) \\-\\- the surface to be turned into a sub\\-surface\n+.IP \\(bu 2\n+\\fBparent\\fP (\\fI\\%WlSurface\\fP) \\-\\- the parent surface\n+.UNINDENT\n+.TP\n+.B Returns\n+\\fI\\%WlSubsurface\\fP \\-\\- the new sub\\-\n+surface object ID\n .UNINDENT\n .UNINDENT\n .UNINDENT\n .SS Scanner Modules\n .SS Argumet\n .INDENT 0.0\n .TP\n"}]}]}]}]}]}