diff --git a/protocols/shell-surface-intersection-observer-v1.xml b/protocols/shell-surface-intersection-observer-v1.xml new file mode 100644 index 0000000..f6f351c --- /dev/null +++ b/protocols/shell-surface-intersection-observer-v1.xml @@ -0,0 +1,144 @@ + + + + Copyright © 2025 outfoxxed + + Permission to use, copy, modify, distribute, and sell this + software and its documentation for any purpose is hereby granted + without fee, provided that the above copyright notice appear in + all copies and that both that copyright notice and this permission + notice appear in supporting documentation, and that the name of + the copyright holders not be used in advertising or publicity + pertaining to distribution of the software without specific, + written prior permission. The copyright holders make no + representations about the suitability of this software for any + purpose. It is provided "as is" without express or implied + warranty. + + THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS + SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY + SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN + AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, + ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF + THIS SOFTWARE. + + + + This protocol allows clients to detect when a toplevel window intersects + with a region relative to a client surface. This is intended to support + desktop shell components that wish to avoid covering or being covered by + a window, such as docks. + + The key words "must", "must not", "required", "shall", "shall not", + "should", "should not", "recommended", "may", and "optional" in this + document are to be interpreted as described in IETF RFC 2119. + + Warning! The protocol described in this file is intended as a stopgap + and is expected to be superseded by a solution in wayland-protocols. + Clients should not assume this protocol will continue to exist in the + future. + + + + + + Destroy the manager. Destroying the manager does not destroy objects + created by the manager. + + + + + + Get an intersection observer for the given surface. + + If a client intends to change the geometry of the surface based + on observed intersections and intends to detect intersections + in the same location after modifying the surface geometry, + the client should use 'set_detection_region' to ensure the + observed region matches the desired location. + + A compositor may wish to offer intersection information to + only a subset of clients or surfaces. If the compositor's + decision is influenced by the specific surface or requested + intersection region, the compositor must wait for a + 'wl_surface.commit' following creation of the observer + before making a descision. + + Clients may wait for a 'flags' event following the previously + mentioned commit to make a decision about where to map the + surface based on potential intersections, so compositors must + respond with a 'flags' or 'finished' event following the commit + to avoid blocking the client. + + + + + + + + + + A shell surface intersection observer allows a client to monitor + a region relative to a wl_surface for intersecting toplevels. + + + + + Destroys the object. + + + + + + The compositor is done sending events to this intersection observer. + + This event may be sent immediately if the compositor does not wish + to provide intersection information for the surface, or if the + compositor later decides to stop providing intersection information + to the surface. + + + + + + Sets the region the client wishes to observe intersections for. + This region is relative to the geometry of the surface. + + When unset or set to null, the observation region matches the + geometry of the surface. + + The detection region is double-buffered and must not take effect + until 'wl_surface.commit' is called. + + + + + + + + + + + + + + This event reports the current state of intersections in the + observed region. It is sent upon creation of the intersection + observer and following any observed changes in the observed region. + + Window decorations should be included when checking if a toplevel + intersects with the region. + + + + + +