Warning, /plasma/kwin/src/wayland/protocols/wlr-layer-shell-unstable-v1.xml is written in an unsupported language. File is not indexed.
0001 <?xml version="1.0" encoding="UTF-8"?> 0002 <protocol name="wlr_layer_shell_unstable_v1"> 0003 <copyright> 0004 Copyright © 2017 Drew DeVault 0005 0006 Permission to use, copy, modify, distribute, and sell this 0007 software and its documentation for any purpose is hereby granted 0008 without fee, provided that the above copyright notice appear in 0009 all copies and that both that copyright notice and this permission 0010 notice appear in supporting documentation, and that the name of 0011 the copyright holders not be used in advertising or publicity 0012 pertaining to distribution of the software without specific, 0013 written prior permission. The copyright holders make no 0014 representations about the suitability of this software for any 0015 purpose. It is provided "as is" without express or implied 0016 warranty. 0017 0018 THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS 0019 SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND 0020 FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY 0021 SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 0022 WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN 0023 AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, 0024 ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF 0025 THIS SOFTWARE. 0026 </copyright> 0027 0028 <interface name="zwlr_layer_shell_v1" version="5"> 0029 <description summary="create surfaces that are layers of the desktop"> 0030 Clients can use this interface to assign the surface_layer role to 0031 wl_surfaces. Such surfaces are assigned to a "layer" of the output and 0032 rendered with a defined z-depth respective to each other. They may also be 0033 anchored to the edges and corners of a screen and specify input handling 0034 semantics. This interface should be suitable for the implementation of 0035 many desktop shell components, and a broad number of other applications 0036 that interact with the desktop. 0037 </description> 0038 0039 <request name="get_layer_surface"> 0040 <description summary="create a layer_surface from a surface"> 0041 Create a layer surface for an existing surface. This assigns the role of 0042 layer_surface, or raises a protocol error if another role is already 0043 assigned. 0044 0045 Creating a layer surface from a wl_surface which has a buffer attached 0046 or committed is a client error, and any attempts by a client to attach 0047 or manipulate a buffer prior to the first layer_surface.configure call 0048 must also be treated as errors. 0049 0050 After creating a layer_surface object and setting it up, the client 0051 must perform an initial commit without any buffer attached. 0052 The compositor will reply with a layer_surface.configure event. 0053 The client must acknowledge it and is then allowed to attach a buffer 0054 to map the surface. 0055 0056 You may pass NULL for output to allow the compositor to decide which 0057 output to use. Generally this will be the one that the user most 0058 recently interacted with. 0059 0060 Clients can specify a namespace that defines the purpose of the layer 0061 surface. 0062 </description> 0063 <arg name="id" type="new_id" interface="zwlr_layer_surface_v1"/> 0064 <arg name="surface" type="object" interface="wl_surface"/> 0065 <arg name="output" type="object" interface="wl_output" allow-null="true"/> 0066 <arg name="layer" type="uint" enum="layer" summary="layer to add this surface to"/> 0067 <arg name="scope" type="string" summary="namespace for the layer surface"/> 0068 </request> 0069 0070 <enum name="error"> 0071 <entry name="role" value="0" summary="wl_surface has another role"/> 0072 <entry name="invalid_layer" value="1" summary="layer value is invalid"/> 0073 <entry name="already_constructed" value="2" summary="wl_surface has a buffer attached or committed"/> 0074 </enum> 0075 0076 <enum name="layer"> 0077 <description summary="available layers for surfaces"> 0078 These values indicate which layers a surface can be rendered in. They 0079 are ordered by z depth, bottom-most first. Traditional shell surfaces 0080 will typically be rendered between the bottom and top layers. 0081 Fullscreen shell surfaces are typically rendered at the top layer. 0082 Multiple surfaces can share a single layer, and ordering within a 0083 single layer is undefined. 0084 </description> 0085 0086 <entry name="background" value="0"/> 0087 <entry name="bottom" value="1"/> 0088 <entry name="top" value="2"/> 0089 <entry name="overlay" value="3"/> 0090 </enum> 0091 0092 <!-- Version 3 additions --> 0093 0094 <request name="destroy" type="destructor" since="3"> 0095 <description summary="destroy the layer_shell object"> 0096 This request indicates that the client will not use the layer_shell 0097 object any more. Objects that have been created through this instance 0098 are not affected. 0099 </description> 0100 </request> 0101 </interface> 0102 0103 <interface name="zwlr_layer_surface_v1" version="5"> 0104 <description summary="layer metadata interface"> 0105 An interface that may be implemented by a wl_surface, for surfaces that 0106 are designed to be rendered as a layer of a stacked desktop-like 0107 environment. 0108 0109 Layer surface state (layer, size, anchor, exclusive zone, 0110 margin, interactivity) is double-buffered, and will be applied at the 0111 time wl_surface.commit of the corresponding wl_surface is called. 0112 0113 Attaching a null buffer to a layer surface unmaps it. 0114 0115 Unmapping a layer_surface means that the surface cannot be shown by the 0116 compositor until it is explicitly mapped again. The layer_surface 0117 returns to the state it had right after layer_shell.get_layer_surface. 0118 The client can re-map the surface by performing a commit without any 0119 buffer attached, waiting for a configure event and handling it as usual. 0120 </description> 0121 0122 <request name="set_size"> 0123 <description summary="sets the size of the surface"> 0124 Sets the size of the surface in surface-local coordinates. The 0125 compositor will display the surface centered with respect to its 0126 anchors. 0127 0128 If you pass 0 for either value, the compositor will assign it and 0129 inform you of the assignment in the configure event. You must set your 0130 anchor to opposite edges in the dimensions you omit; not doing so is a 0131 protocol error. Both values are 0 by default. 0132 0133 Size is double-buffered, see wl_surface.commit. 0134 </description> 0135 <arg name="width" type="uint"/> 0136 <arg name="height" type="uint"/> 0137 </request> 0138 0139 <request name="set_anchor"> 0140 <description summary="configures the anchor point of the surface"> 0141 Requests that the compositor anchor the surface to the specified edges 0142 and corners. If two orthogonal edges are specified (e.g. 'top' and 0143 'left'), then the anchor point will be the intersection of the edges 0144 (e.g. the top left corner of the output); otherwise the anchor point 0145 will be centered on that edge, or in the center if none is specified. 0146 0147 Anchor is double-buffered, see wl_surface.commit. 0148 </description> 0149 <arg name="anchor" type="uint" enum="anchor"/> 0150 </request> 0151 0152 <request name="set_exclusive_zone"> 0153 <description summary="configures the exclusive geometry of this surface"> 0154 Requests that the compositor avoids occluding an area with other 0155 surfaces. The compositor's use of this information is 0156 implementation-dependent - do not assume that this region will not 0157 actually be occluded. 0158 0159 A positive value is only meaningful if the surface is anchored to one 0160 edge or an edge and both perpendicular edges. If the surface is not 0161 anchored, anchored to only two perpendicular edges (a corner), anchored 0162 to only two parallel edges or anchored to all edges, a positive value 0163 will be treated the same as zero. 0164 0165 A positive zone is the distance from the edge in surface-local 0166 coordinates to consider exclusive. 0167 0168 Surfaces that do not wish to have an exclusive zone may instead specify 0169 how they should interact with surfaces that do. If set to zero, the 0170 surface indicates that it would like to be moved to avoid occluding 0171 surfaces with a positive exclusive zone. If set to -1, the surface 0172 indicates that it would not like to be moved to accommodate for other 0173 surfaces, and the compositor should extend it all the way to the edges 0174 it is anchored to. 0175 0176 For example, a panel might set its exclusive zone to 10, so that 0177 maximized shell surfaces are not shown on top of it. A notification 0178 might set its exclusive zone to 0, so that it is moved to avoid 0179 occluding the panel, but shell surfaces are shown underneath it. A 0180 wallpaper or lock screen might set their exclusive zone to -1, so that 0181 they stretch below or over the panel. 0182 0183 The default value is 0. 0184 0185 Exclusive zone is double-buffered, see wl_surface.commit. 0186 </description> 0187 <arg name="zone" type="int"/> 0188 </request> 0189 0190 <request name="set_margin"> 0191 <description summary="sets a margin from the anchor point"> 0192 Requests that the surface be placed some distance away from the anchor 0193 point on the output, in surface-local coordinates. Setting this value 0194 for edges you are not anchored to has no effect. 0195 0196 The exclusive zone includes the margin. 0197 0198 Margin is double-buffered, see wl_surface.commit. 0199 </description> 0200 <arg name="top" type="int"/> 0201 <arg name="right" type="int"/> 0202 <arg name="bottom" type="int"/> 0203 <arg name="left" type="int"/> 0204 </request> 0205 0206 <request name="set_keyboard_interactivity"> 0207 <description summary="requests keyboard events"> 0208 Set to 1 to request that the seat send keyboard events to this layer 0209 surface. For layers below the shell surface layer, the seat will use 0210 normal focus semantics. For layers above the shell surface layers, the 0211 seat will always give exclusive keyboard focus to the top-most layer 0212 which has keyboard interactivity set to true. 0213 0214 Layer surfaces receive pointer, touch, and tablet events normally. If 0215 you do not want to receive them, set the input region on your surface 0216 to an empty region. 0217 0218 Events is double-buffered, see wl_surface.commit. 0219 </description> 0220 <arg name="keyboard_interactivity" type="uint"/> 0221 </request> 0222 0223 <request name="get_popup"> 0224 <description summary="assign this layer_surface as an xdg_popup parent"> 0225 This assigns an xdg_popup's parent to this layer_surface. This popup 0226 should have been created via xdg_surface::get_popup with the parent set 0227 to NULL, and this request must be invoked before committing the popup's 0228 initial state. 0229 0230 See the documentation of xdg_popup for more details about what an 0231 xdg_popup is and how it is used. 0232 </description> 0233 <arg name="popup" type="object" interface="xdg_popup"/> 0234 </request> 0235 0236 <request name="ack_configure"> 0237 <description summary="ack a configure event"> 0238 When a configure event is received, if a client commits the 0239 surface in response to the configure event, then the client 0240 must make an ack_configure request sometime before the commit 0241 request, passing along the serial of the configure event. 0242 0243 If the client receives multiple configure events before it 0244 can respond to one, it only has to ack the last configure event. 0245 0246 A client is not required to commit immediately after sending 0247 an ack_configure request - it may even ack_configure several times 0248 before its next surface commit. 0249 0250 A client may send multiple ack_configure requests before committing, but 0251 only the last request sent before a commit indicates which configure 0252 event the client really is responding to. 0253 </description> 0254 <arg name="serial" type="uint" summary="the serial from the configure event"/> 0255 </request> 0256 0257 <request name="destroy" type="destructor"> 0258 <description summary="destroy the layer_surface"> 0259 This request destroys the layer surface. 0260 </description> 0261 </request> 0262 0263 <event name="configure"> 0264 <description summary="suggest a surface change"> 0265 The configure event asks the client to resize its surface. 0266 0267 Clients should arrange their surface for the new states, and then send 0268 an ack_configure request with the serial sent in this configure event at 0269 some point before committing the new surface. 0270 0271 The client is free to dismiss all but the last configure event it 0272 received. 0273 0274 The width and height arguments specify the size of the window in 0275 surface-local coordinates. 0276 0277 The size is a hint, in the sense that the client is free to ignore it if 0278 it doesn't resize, pick a smaller size (to satisfy aspect ratio or 0279 resize in steps of NxM pixels). If the client picks a smaller size and 0280 is anchored to two opposite anchors (e.g. 'top' and 'bottom'), the 0281 surface will be centered on this axis. 0282 0283 If the width or height arguments are zero, it means the client should 0284 decide its own window dimension. 0285 </description> 0286 <arg name="serial" type="uint"/> 0287 <arg name="width" type="uint"/> 0288 <arg name="height" type="uint"/> 0289 </event> 0290 0291 <event name="closed"> 0292 <description summary="surface should be closed"> 0293 The closed event is sent by the compositor when the surface will no 0294 longer be shown. The output may have been destroyed or the user may 0295 have asked for it to be removed. Further changes to the surface will be 0296 ignored. The client should destroy the resource after receiving this 0297 event, and create a new surface if they so choose. 0298 </description> 0299 </event> 0300 0301 <enum name="error"> 0302 <entry name="invalid_surface_state" value="0" summary="provided surface state is invalid"/> 0303 <entry name="invalid_size" value="1" summary="size is invalid"/> 0304 <entry name="invalid_anchor" value="2" summary="anchor bitfield is invalid"/> 0305 <entry name="invalid_exclusive_edge" value="4" summary="exclusive edge is invalid given the surface anchors"/> 0306 </enum> 0307 0308 <enum name="anchor" bitfield="true"> 0309 <entry name="top" value="1" summary="the top edge of the anchor rectangle"/> 0310 <entry name="bottom" value="2" summary="the bottom edge of the anchor rectangle"/> 0311 <entry name="left" value="4" summary="the left edge of the anchor rectangle"/> 0312 <entry name="right" value="8" summary="the right edge of the anchor rectangle"/> 0313 </enum> 0314 0315 <!-- Version 2 additions --> 0316 0317 <request name="set_layer" since="2"> 0318 <description summary="change the layer of the surface"> 0319 Change the layer that the surface is rendered on. 0320 0321 Layer is double-buffered, see wl_surface.commit. 0322 </description> 0323 <arg name="layer" type="uint" enum="zwlr_layer_shell_v1.layer" summary="layer to move this surface to"/> 0324 </request> 0325 0326 <!-- Version 5 additions --> 0327 0328 <request name="set_exclusive_edge" since="5"> 0329 <description summary="set the edge the exclusive zone will be applied to"> 0330 Requests an edge for the exclusive zone to apply. The exclusive 0331 edge will be automatically deduced from anchor points when possible, 0332 but when the surface is anchored to a corner, it will be necessary 0333 to set it explicitly to disambiguate, as it is not possible to deduce 0334 which one of the two corner edges should be used. 0335 0336 The edge must be one the surface is anchored to, otherwise the 0337 invalid_exclusive_edge protocol error will be raised. 0338 </description> 0339 <arg name="edge" type="uint"/> 0340 </request> 0341 </interface> 0342 </protocol>