From 9762876832bdb99a09285ff671ef4d3f1676721a Mon Sep 17 00:00:00 2001 From: WhySoBad <49595640+WhySoBad@users.noreply.github.com> Date: Wed, 26 Mar 2025 21:03:50 +0100 Subject: [PATCH] feat: add hyprland-toplevel-mapping-v1 protocol --- protocols/hyprland-toplevel-mapping-v1.xml | 195 +++++++++++++++++++++ 1 file changed, 195 insertions(+) create mode 100644 protocols/hyprland-toplevel-mapping-v1.xml diff --git a/protocols/hyprland-toplevel-mapping-v1.xml b/protocols/hyprland-toplevel-mapping-v1.xml new file mode 100644 index 0000000..4d1aabe --- /dev/null +++ b/protocols/hyprland-toplevel-mapping-v1.xml @@ -0,0 +1,195 @@ + + + + Copyright © 2025 WhySoBad + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + + 2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE + FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + + + This protocol allows clients to retrieve the mapping of toplevels to hyprland window addresses + and vice versa. + + + + + This object is a manager which offers requests to retrieve a window address + for a toplevel or to get a (wlr) toplevel for a window address. + + + + + Get the window address for a toplevel. + + + + + + + + Get the window address for a wlr toplevel. + + + + + + + + All objects created by the manager will still remain valid, until their appropriate destroy + request has been called. + + + + + + + This object represents a mapping of a (wlr) toplevel to a window address. + + Once created, the `window_address` event will be sent containing the address of the window + associated with the toplevel. + Should the mapping fail, the `failed` event will be sent. + + + + + The full 64bit window address. The `address` field contains the lower 32 bits whilst the + `address_hi` contains the upper 32 bits + + + + + + + + The mapping of the toplevel to a window address failed. Most likely the window does not + exist (anymore). + + + + + + Destroy the handle. This request can be sent at any time by the client. + + + + + + + This object represents a mapping of window address to a toplevel. + + Once created, the `toplevel` event will be sent containing the handle to the associated + toplevel. + Should the mapping fail, the `failed` event will be sent. + + + + + The requested toplevel + + + + + + + The mapping of the window address to a toplevel failed. Most likely the window does not + exist (anymore). + + + + + + Destroy the handle. This request can be sent at any time by the client. + + + + + + + This object represents a mapping of window address to a wlr toplevel. + + Once created, the `toplevel` event will be sent containing the handle to the associated wlr + toplevel. + Should the mapping fail, the `failed` event will be sent. + + + + + The requested wlr toplevel + + + + + + + The mapping of the window address to a wlr toplevel failed. Most likely the window does not + exist (anymore). + + + + + + Destroy the handle. This request can be sent at any time by the client. + + + + \ No newline at end of file