diff options
author | 2018-04-12 20:19:54 -0400 | |
---|---|---|
committer | 2018-04-12 20:19:54 -0400 | |
commit | cd1b32453a9296c18b28bff71607aeb22987b5cd (patch) | |
tree | c653c6d525b471914c01a9d7ae543f521b6138ed /protocols/wlr-layer-shell-unstable-v1.xml | |
parent | Merge pull request #1634 from aleksander/master (diff) | |
parent | Fix separator height calculation (diff) | |
download | sway-cd1b32453a9296c18b28bff71607aeb22987b5cd.tar.gz sway-cd1b32453a9296c18b28bff71607aeb22987b5cd.tar.zst sway-cd1b32453a9296c18b28bff71607aeb22987b5cd.zip |
Merge branch 'wlroots'
Diffstat (limited to 'protocols/wlr-layer-shell-unstable-v1.xml')
-rw-r--r-- | protocols/wlr-layer-shell-unstable-v1.xml | 281 |
1 files changed, 281 insertions, 0 deletions
diff --git a/protocols/wlr-layer-shell-unstable-v1.xml b/protocols/wlr-layer-shell-unstable-v1.xml new file mode 100644 index 00000000..3181c0bb --- /dev/null +++ b/protocols/wlr-layer-shell-unstable-v1.xml | |||
@@ -0,0 +1,281 @@ | |||
1 | <?xml version="1.0" encoding="UTF-8"?> | ||
2 | <protocol name="wlr_layer_shell_unstable_v1"> | ||
3 | <copyright> | ||
4 | Copyright © 2017 Drew DeVault | ||
5 | |||
6 | Permission to use, copy, modify, distribute, and sell this | ||
7 | software and its documentation for any purpose is hereby granted | ||
8 | without fee, provided that the above copyright notice appear in | ||
9 | all copies and that both that copyright notice and this permission | ||
10 | notice appear in supporting documentation, and that the name of | ||
11 | the copyright holders not be used in advertising or publicity | ||
12 | pertaining to distribution of the software without specific, | ||
13 | written prior permission. The copyright holders make no | ||
14 | representations about the suitability of this software for any | ||
15 | purpose. It is provided "as is" without express or implied | ||
16 | warranty. | ||
17 | |||
18 | THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS | ||
19 | SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND | ||
20 | FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY | ||
21 | SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
22 | WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN | ||
23 | AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, | ||
24 | ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF | ||
25 | THIS SOFTWARE. | ||
26 | </copyright> | ||
27 | |||
28 | <interface name="zwlr_layer_shell_v1" version="1"> | ||
29 | <description summary="create surfaces that are layers of the desktop"> | ||
30 | Clients can use this interface to assign the surface_layer role to | ||
31 | wl_surfaces. Such surfaces are assigned to a "layer" of the output and | ||
32 | rendered with a defined z-depth respective to each other. They may also be | ||
33 | anchored to the edges and corners of a screen and specify input handling | ||
34 | semantics. This interface should be suitable for the implementation of | ||
35 | many desktop shell components, and a broad number of other applications | ||
36 | that interact with the desktop. | ||
37 | </description> | ||
38 | |||
39 | <request name="get_layer_surface"> | ||
40 | <description summary="create a layer_surface from a surface"> | ||
41 | Create a layer surface for an existing surface. This assigns the role of | ||
42 | layer_surface, or raises a protocol error if another role is already | ||
43 | assigned. | ||
44 | |||
45 | Creating a layer surface from a wl_surface which has a buffer attached | ||
46 | or committed is a client error, and any attempts by a client to attach | ||
47 | or manipulate a buffer prior to the first layer_surface.configure call | ||
48 | must also be treated as errors. | ||
49 | |||
50 | Clients can specify a namespace that defines the purpose of the layer | ||
51 | surface. | ||
52 | </description> | ||
53 | <arg name="id" type="new_id" interface="zwlr_layer_surface_v1"/> | ||
54 | <arg name="surface" type="object" interface="wl_surface"/> | ||
55 | <arg name="output" type="object" interface="wl_output"/> | ||
56 | <arg name="layer" type="uint" enum="layer" summary="layer to add this surface to"/> | ||
57 | <arg name="namespace" type="string" summary="namespace for the layer surface"/> | ||
58 | </request> | ||
59 | |||
60 | <enum name="error"> | ||
61 | <entry name="role" value="0" summary="wl_surface has another role"/> | ||
62 | <entry name="invalid_layer" value="1" summary="layer value is invalid"/> | ||
63 | <entry name="already_constructed" value="2" summary="wl_surface has a buffer attached or committed"/> | ||
64 | </enum> | ||
65 | |||
66 | <enum name="layer"> | ||
67 | <description summary="available layers for surfaces"> | ||
68 | These values indicate which layers a surface can be rendered in. They | ||
69 | are ordered by z depth, bottom-most first. Traditional shell surfaces | ||
70 | will typically be rendered between the bottom and top layers. | ||
71 | Fullscreen shell surfaces are typically rendered at the top layer. | ||
72 | Multiple surfaces can share a single layer, and ordering within a | ||
73 | single layer is undefined. | ||
74 | </description> | ||
75 | |||
76 | <entry name="background" value="0"/> | ||
77 | <entry name="bottom" value="1"/> | ||
78 | <entry name="top" value="2"/> | ||
79 | <entry name="overlay" value="3"/> | ||
80 | </enum> | ||
81 | </interface> | ||
82 | |||
83 | <interface name="zwlr_layer_surface_v1" version="1"> | ||
84 | <description summary="layer metadata interface"> | ||
85 | An interface that may be implemented by a wl_surface, for surfaces that | ||
86 | are designed to be rendered as a layer of a stacked desktop-like | ||
87 | environment. | ||
88 | |||
89 | Layer surface state (size, anchor, exclusive zone, margin, interactivity) | ||
90 | is double-buffered, and will be applied at the time wl_surface.commit of | ||
91 | the corresponding wl_surface is called. | ||
92 | </description> | ||
93 | |||
94 | <request name="set_size"> | ||
95 | <description summary="sets the size of the surface"> | ||
96 | Sets the size of the surface in surface-local coordinates. The | ||
97 | compositor will display the surface centered with respect to its | ||
98 | anchors. | ||
99 | |||
100 | If you pass 0 for either value, the compositor will assign it and | ||
101 | inform you of the assignment in the configure event. You must set your | ||
102 | anchor to opposite edges in the dimensions you omit; not doing so is a | ||
103 | protocol error. Both values are 0 by default. | ||
104 | |||
105 | Size is double-buffered, see wl_surface.commit. | ||
106 | </description> | ||
107 | <arg name="width" type="uint"/> | ||
108 | <arg name="height" type="uint"/> | ||
109 | </request> | ||
110 | |||
111 | <request name="set_anchor"> | ||
112 | <description summary="configures the anchor point of the surface"> | ||
113 | Requests that the compositor anchor the surface to the specified edges | ||
114 | and corners. If two orthoginal edges are specified (e.g. 'top' and | ||
115 | 'left'), then the anchor point will be the intersection of the edges | ||
116 | (e.g. the top left corner of the output); otherwise the anchor point | ||
117 | will be centered on that edge, or in the center if none is specified. | ||
118 | |||
119 | Anchor is double-buffered, see wl_surface.commit. | ||
120 | </description> | ||
121 | <arg name="anchor" type="uint" enum="anchor"/> | ||
122 | </request> | ||
123 | |||
124 | <request name="set_exclusive_zone"> | ||
125 | <description summary="configures the exclusive geometry of this surface"> | ||
126 | Requests that the compositor avoids occluding an area of the surface | ||
127 | with other surfaces. The compositor's use of this information is | ||
128 | implementation-dependent - do not assume that this region will not | ||
129 | actually be occluded. | ||
130 | |||
131 | A positive value is only meaningful if the surface is anchored to an | ||
132 | edge, rather than a corner. The zone is the number of surface-local | ||
133 | coordinates from the edge that are considered exclusive. | ||
134 | |||
135 | Surfaces that do not wish to have an exclusive zone may instead specify | ||
136 | how they should interact with surfaces that do. If set to zero, the | ||
137 | surface indicates that it would like to be moved to avoid occluding | ||
138 | surfaces with a positive excluzive zone. If set to -1, the surface | ||
139 | indicates that it would not like to be moved to accomodate for other | ||
140 | surfaces, and the compositor should extend it all the way to the edges | ||
141 | it is anchored to. | ||
142 | |||
143 | For example, a panel might set its exclusive zone to 10, so that | ||
144 | maximized shell surfaces are not shown on top of it. A notification | ||
145 | might set its exclusive zone to 0, so that it is moved to avoid | ||
146 | occluding the panel, but shell surfaces are shown underneath it. A | ||
147 | wallpaper or lock screen might set their exclusive zone to -1, so that | ||
148 | they stretch below or over the panel. | ||
149 | |||
150 | The default value is 0. | ||
151 | |||
152 | Exclusive zone is double-buffered, see wl_surface.commit. | ||
153 | </description> | ||
154 | <arg name="zone" type="int"/> | ||
155 | </request> | ||
156 | |||
157 | <request name="set_margin"> | ||
158 | <description summary="sets a margin from the anchor point"> | ||
159 | Requests that the surface be placed some distance away from the anchor | ||
160 | point on the output, in surface-local coordinates. Setting this value | ||
161 | for edges you are not anchored to has no effect. | ||
162 | |||
163 | The exclusive zone includes the margin. | ||
164 | |||
165 | Margin is double-buffered, see wl_surface.commit. | ||
166 | </description> | ||
167 | <arg name="top" type="int"/> | ||
168 | <arg name="right" type="int"/> | ||
169 | <arg name="bottom" type="int"/> | ||
170 | <arg name="left" type="int"/> | ||
171 | </request> | ||
172 | |||
173 | <request name="set_keyboard_interactivity"> | ||
174 | <description summary="requests keyboard events"> | ||
175 | Set to 1 to request that the seat send keyboard events to this layer | ||
176 | surface. For layers below the shell surface layer, the seat will use | ||
177 | normal focus semantics. For layers above the shell surface layers, the | ||
178 | seat will always give exclusive keyboard focus to the top-most layer | ||
179 | which has keyboard interactivity set to true. | ||
180 | |||
181 | Layer surfaces receive pointer, touch, and tablet events normally. If | ||
182 | you do not want to receive them, set the input region on your surface | ||
183 | to an empty region. | ||
184 | |||
185 | Events is double-buffered, see wl_surface.commit. | ||
186 | </description> | ||
187 | <arg name="keyboard_interactivity" type="uint"/> | ||
188 | </request> | ||
189 | |||
190 | <request name="get_popup"> | ||
191 | <description summary="assign this layer_surface as an xdg_popup parent"> | ||
192 | This assigns an xdg_popup's parent to this layer_surface. This popup | ||
193 | should have been created via xdg_surface::get_popup with the parent set | ||
194 | to NULL, and this request must be invoked before committing the popup's | ||
195 | initial state. | ||
196 | |||
197 | See the documentation of xdg_popup for more details about what an | ||
198 | xdg_popup is and how it is used. | ||
199 | </description> | ||
200 | <arg name="popup" type="object" interface="xdg_popup"/> | ||
201 | </request> | ||
202 | |||
203 | <request name="ack_configure"> | ||
204 | <description summary="ack a configure event"> | ||
205 | When a configure event is received, if a client commits the | ||
206 | surface in response to the configure event, then the client | ||
207 | must make an ack_configure request sometime before the commit | ||
208 | request, passing along the serial of the configure event. | ||
209 | |||
210 | If the client receives multiple configure events before it | ||
211 | can respond to one, it only has to ack the last configure event. | ||
212 | |||
213 | A client is not required to commit immediately after sending | ||
214 | an ack_configure request - it may even ack_configure several times | ||
215 | before its next surface commit. | ||
216 | |||
217 | A client may send multiple ack_configure requests before committing, but | ||
218 | only the last request sent before a commit indicates which configure | ||
219 | event the client really is responding to. | ||
220 | </description> | ||
221 | <arg name="serial" type="uint" summary="the serial from the configure event"/> | ||
222 | </request> | ||
223 | |||
224 | <request name="destroy" type="destructor"> | ||
225 | <description summary="destroy the layer_surface"> | ||
226 | This request destroys the layer surface. | ||
227 | </description> | ||
228 | </request> | ||
229 | |||
230 | <event name="configure"> | ||
231 | <description summary="suggest a surface change"> | ||
232 | The configure event asks the client to resize its surface. | ||
233 | |||
234 | Clients should arrange their surface for the new states, and then send | ||
235 | an ack_configure request with the serial sent in this configure event at | ||
236 | some point before committing the new surface. | ||
237 | |||
238 | The client is free to dismiss all but the last configure event it | ||
239 | received. | ||
240 | |||
241 | The width and height arguments specify the size of the window in | ||
242 | surface-local coordinates. | ||
243 | |||
244 | The size is a hint, in the sense that the client is free to ignore it if | ||
245 | it doesn't resize, pick a smaller size (to satisfy aspect ratio or | ||
246 | resize in steps of NxM pixels). If the client picks a smaller size and | ||
247 | is anchored to two opposite anchors (e.g. 'top' and 'bottom'), the | ||
248 | surface will be centered on this axis. | ||
249 | |||
250 | If the width or height arguments are zero, it means the client should | ||
251 | decide its own window dimension. | ||
252 | </description> | ||
253 | <arg name="serial" type="uint"/> | ||
254 | <arg name="width" type="uint"/> | ||
255 | <arg name="height" type="uint"/> | ||
256 | </event> | ||
257 | |||
258 | <event name="closed"> | ||
259 | <description summary="surface should be closed"> | ||
260 | The closed event is sent by the compositor when the surface will no | ||
261 | longer be shown. The output may have been destroyed or the user may | ||
262 | have asked for it to be removed. Further changes to the surface will be | ||
263 | ignored. The client should destroy the resource after receiving this | ||
264 | event, and create a new surface if they so choose. | ||
265 | </description> | ||
266 | </event> | ||
267 | |||
268 | <enum name="error"> | ||
269 | <entry name="invalid_surface_state" value="0" summary="provided surface state is invalid"/> | ||
270 | <entry name="invalid_size" value="1" summary="size is invalid"/> | ||
271 | <entry name="invalid_anchor" value="2" summary="anchor bitfield is invalid"/> | ||
272 | </enum> | ||
273 | |||
274 | <enum name="anchor" bitfield="true"> | ||
275 | <entry name="top" value="1" summary="the top edge of the anchor rectangle"/> | ||
276 | <entry name="bottom" value="2" summary="the bottom edge of the anchor rectangle"/> | ||
277 | <entry name="left" value="4" summary="the left edge of the anchor rectangle"/> | ||
278 | <entry name="right" value="8" summary="the right edge of the anchor rectangle"/> | ||
279 | </enum> | ||
280 | </interface> | ||
281 | </protocol> | ||