From 08067aed0fd5b6ae280ef27c6e465f2d6e1ddb00 Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Fri, 8 Oct 2021 13:34:03 +0200 Subject: xdg-shell: introduce toplevel wm_capabilities Some compositors don't implement all of the features of xdg-shell. This results in UI elements (e.g. buttons) in clients which do nothing when activated. Add a wm_capabilities event to allow clients to hide these UI elements when they don't make sense. Signed-off-by: Simon Ser Closes: https://gitlab.freedesktop.org/wayland/wayland-protocols/-/issues/64 --- stable/xdg-shell/xdg-shell.xml | 45 +++++++++++++++++++++++++++++++++++++----- 1 file changed, 40 insertions(+), 5 deletions(-) diff --git a/stable/xdg-shell/xdg-shell.xml b/stable/xdg-shell/xdg-shell.xml index ecfaa46..8c9804f 100644 --- a/stable/xdg-shell/xdg-shell.xml +++ b/stable/xdg-shell/xdg-shell.xml @@ -29,7 +29,7 @@ DEALINGS IN THE SOFTWARE. - + The xdg_wm_base interface is exposed as a global object enabling clients to turn their wl_surfaces into windows in a desktop environment. It @@ -117,7 +117,7 @@ - + The xdg_positioner provides a collection of rules for the placement of a child surface relative to a parent surface. Rules can be defined to ensure @@ -401,7 +401,7 @@ - + An interface that may be implemented by a wl_surface, for implementations that provide a desktop-style user interface. @@ -577,7 +577,7 @@ - + This interface defines an xdg_surface role which allows a surface to, among other things, set window-like properties such as maximize, @@ -1100,9 +1100,44 @@ + + + + + + + + + + + + + This event advertises the capabilities supported by the compositor. If + a capability isn't supported, clients should hide or disable the UI + elements that expose this functionality. For instance, if the + compositor doesn't advertise support for minimized toplevels, a button + triggering the set_minimized request should not be displayed. + + The compositor will ignore requests it doesn't support. For instance, + a compositor which doesn't advertise support for minimized will ignore + set_minimized requests. + + Compositors must send this event once before the first + xdg_surface.configure event. When the capabilities change, compositors + must send this event again and then send an xdg_surface.configure + event. + + The configured state should not be applied immediately. See + xdg_surface.configure for details. + + The capabilities are sent as an array of 32-bit unsigned integers in + native endianness. + + + - + A popup surface is a short-lived, temporary surface. It can be used to implement for example menus, popovers, tooltips and other similar user -- cgit v1.2.3