mirror of
https://gitlab.freedesktop.org/wlroots/wlr-protocols.git
synced 2025-12-27 04:30:06 +01:00
Add set_accomodate_exclusive_zones
Right now a layer shell surface can be set to not be moved and resized by the areas reserved by exclusive zones owned by otther surfaces by setting a magic value of -1 to the exclusive_zone property. Besides not being a clear API, this has the limitation of allowing a layershell surface to not be moved only if it does not have any exclusive zone by itself, which is ok for "desktop" windows but not for panels. On a shell where we have all the panels in the same process we know their layout and things are much more controllable if is the client side which asks the panels to be sized correctly It also becomes possible for more panels to be on the same side, for instance one aligned to the left and one aligned to the right, thing that we do support in Plasma on X11
This commit is contained in:
parent
2b8d43325b
commit
a58c092faf
1 changed files with 30 additions and 9 deletions
|
|
@ -25,7 +25,7 @@
|
|||
THIS SOFTWARE.
|
||||
</copyright>
|
||||
|
||||
<interface name="zwlr_layer_shell_v1" version="5">
|
||||
<interface name="zwlr_layer_shell_v1" version="6">
|
||||
<description summary="create surfaces that are layers of the desktop">
|
||||
Clients can use this interface to assign the surface_layer role to
|
||||
wl_surfaces. Such surfaces are assigned to a "layer" of the output and
|
||||
|
|
@ -100,7 +100,7 @@
|
|||
</request>
|
||||
</interface>
|
||||
|
||||
<interface name="zwlr_layer_surface_v1" version="5">
|
||||
<interface name="zwlr_layer_surface_v1" version="6">
|
||||
<description summary="layer metadata interface">
|
||||
An interface that may be implemented by a wl_surface, for surfaces that
|
||||
are designed to be rendered as a layer of a stacked desktop-like
|
||||
|
|
@ -168,21 +168,25 @@
|
|||
Surfaces that do not wish to have an exclusive zone may instead specify
|
||||
how they should interact with surfaces that do. If set to zero, the
|
||||
surface indicates that it would like to be moved to avoid occluding
|
||||
surfaces with a positive exclusive zone. If set to -1, the surface
|
||||
indicates that it would not like to be moved to accommodate for other
|
||||
surfaces, and the compositor should extend it all the way to the edges
|
||||
it is anchored to.
|
||||
surfaces with a positive exclusive zone.
|
||||
|
||||
For example, a panel might set its exclusive zone to 10, so that
|
||||
maximized shell surfaces are not shown on top of it. A notification
|
||||
might set its exclusive zone to 0, so that it is moved to avoid
|
||||
occluding the panel, but shell surfaces are shown underneath it. A
|
||||
wallpaper or lock screen might set their exclusive zone to -1, so that
|
||||
they stretch below or over the panel.
|
||||
occluding the panel, but shell surfaces are shown underneath it.
|
||||
|
||||
The default value is 0.
|
||||
|
||||
Exclusive zone is double-buffered, see wl_surface.commit.
|
||||
|
||||
Since version 6 It must be a value of 0 or more, otherwise the error
|
||||
invalid_exclusive_zone will be triggered.
|
||||
|
||||
Until version 5 if set to -1, the surface indicates that it would not
|
||||
like to be moved to accommodate for other surfaces, and the compositor
|
||||
should extend it all the way to the edges it is anchored to.
|
||||
A wallpaper or lock screen might set their exclusive zone to -1, so that
|
||||
they stretch below or over the panel.
|
||||
</description>
|
||||
<arg name="zone" type="int"/>
|
||||
</request>
|
||||
|
|
@ -368,6 +372,7 @@
|
|||
<entry name="invalid_anchor" value="2" summary="anchor bitfield is invalid"/>
|
||||
<entry name="invalid_keyboard_interactivity" value="3" summary="keyboard interactivity is invalid"/>
|
||||
<entry name="invalid_exclusive_edge" value="4" summary="exclusive edge is invalid given the surface anchors"/>
|
||||
<entry name="invalid_exclusive_zone" value="5" summary="exclusive zone value is invalid, since version 6 it can't be less than zero"/>
|
||||
</enum>
|
||||
|
||||
<enum name="anchor" bitfield="true">
|
||||
|
|
@ -403,5 +408,21 @@
|
|||
</description>
|
||||
<arg name="edge" type="uint" enum="anchor"/>
|
||||
</request>
|
||||
|
||||
<!-- Version 6 additions -->
|
||||
|
||||
<request name="set_accomodate_exclusive_zones" since="6">
|
||||
<description summary="set whether accomodate exclusive zones of other surfaces">
|
||||
Asks for this surface to not be automatically moved and resized according to
|
||||
exclusive zones claimed by other surfaces.
|
||||
|
||||
The accomodate parameter is treated as a boolean flag, a zero value means false,
|
||||
a non zero value means true.
|
||||
|
||||
This is the default behavior, if you want a zone to not be automatically moved,
|
||||
explicitly call this with 0 as parameter.
|
||||
</description>
|
||||
<arg name="accomodate" type="uint"/>
|
||||
</request>
|
||||
</interface>
|
||||
</protocol>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue