• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<?xml version="1.0" encoding="UTF-8"?>
2<protocol name="remote_shell_unstable_v2">
3
4  <copyright>
5    Copyright 2021 The Chromium Authors
6
7    Permission is hereby granted, free of charge, to any person obtaining a
8    copy of this software and associated documentation files (the "Software"),
9    to deal in the Software without restriction, including without limitation
10    the rights to use, copy, modify, merge, publish, distribute, sublicense,
11    and/or sell copies of the Software, and to permit persons to whom the
12    Software is furnished to do so, subject to the following conditions:
13
14    The above copyright notice and this permission notice (including the next
15    paragraph) shall be included in all copies or substantial portions of the
16    Software.
17
18    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
21    THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
23    FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
24    DEALINGS IN THE SOFTWARE.
25  </copyright>
26
27  <description summary="Create remote desktop-style surfaces">
28    remote_shell allows clients to turn a wl_surface into a "real window"
29    which can be stacked and activated by the user.
30
31    Warning! The protocol described in this file is experimental and backward
32    incompatible changes may be made. Backward compatible changes may be added
33    together with the corresponding interface version bump. Backward
34    incompatible changes are done by bumping the version number in the protocol
35    and interface names and resetting the interface version. Once the protocol
36    is to be declared stable, the 'z' prefix and the version number in the
37    protocol and interface names are removed and the interface version number is
38    reset.
39  </description>
40
41  <interface name="zcr_remote_shell_v2" version="6">
42    <description summary="remote_shell">
43      The global interface that allows clients to turn a wl_surface into a
44      "real window" which is remotely managed but can be stacked, activated
45      and made fullscreen by the user.
46    </description>
47
48    <enum name="error">
49      <entry name="role" value="0" summary="given wl_surface has another role"/>
50      <entry name="invalid_notification_key" value="1" summary="invalid notification key"/>
51    </enum>
52
53    <request name="destroy" type="destructor">
54      <description summary="destroy remote_shell">
55	Destroy this remote_shell object.
56
57	Destroying a bound remote_shell object while there are surfaces
58	still alive created by this remote_shell object instance is illegal
59	and will result in a protocol error.
60      </description>
61    </request>
62
63    <enum name="container">
64      <description summary="containers for remote surfaces">
65	Determine how a remote surface should be stacked relative to other
66	shell surfaces.
67      </description>
68      <entry name="default" value="1" summary="default container"/>
69      <entry name="overlay" value="2" summary="system modal container"/>
70    </enum>
71
72    <request name="get_remote_surface">
73      <description summary="create a remote shell surface from a surface">
74	This creates an remote_surface for the given surface and gives it the
75	remote_surface role. A wl_surface can only be given a remote_surface
76	role once. If get_remote_surface is called with a wl_surface that
77	already has an active remote_surface associated with it, or if it had
78	any other role, an error is raised.
79
80	See the documentation of remote_surface for more details about what an
81	remote_surface is and how it is used.
82      </description>
83      <arg name="id" type="new_id" interface="zcr_remote_surface_v2"/>
84      <arg name="surface" type="object" interface="wl_surface"/>
85      <arg name="container" type="uint" enum="container"/>
86    </request>
87
88    <request name="get_notification_surface">
89      <description summary="create a notification surface from a surface">
90	Creates a notification_surface for the given surface, gives it the
91	notification_surface role and associated it with a notification id.
92      </description>
93      <arg name="id" type="new_id" interface="zcr_notification_surface_v2"/>
94      <arg name="surface" type="object" interface="wl_surface"/>
95      <arg name="notification_key" type="string"/>
96    </request>
97
98    <event name="default_device_scale_factor" since="1">
99      <description summary="initialize scale configuration">
100	Sends the default device scale factor.
101      </description>
102      <arg name="scale" type="int" summary="DP to pixels ratio, in 8.24 fixed point format"/>
103    </event>
104
105    <request name="get_input_method_surface" since="1">
106      <description summary="Create a input method surface from a surface">
107	Creates an input_method_surface for the given surface, gives it
108	the input_method_surface role.
109      </description>
110      <arg name="id" type="new_id" interface="zcr_input_method_surface_v2"/>
111      <arg name="surface" type="object" interface="wl_surface"/>
112    </request>
113
114    <request name="get_toast_surface" since="1">
115      <description summary="Create a toast surface from a surface">
116	Creates an toast_surface for the given surface, gives it
117	the toast_surface role.
118      </description>
119      <arg name="id" type="new_id" interface="zcr_toast_surface_v2"/>
120      <arg name="surface" type="object" interface="wl_surface"/>
121    </request>
122
123    <enum name="layout_mode">
124      <description summary="the layout mode">
125	Determine how a client should layout surfaces.
126      </description>
127      <entry name="windowed" value="1" summary="multiple windows"/>
128      <entry name="tablet" value="2" summary="restricted mode for tablet"/>
129    </enum>
130
131    <event name="layout_mode" since="1">
132      <description summary="sends the layout_mode">
133	Sends the layout_mode used by the server.
134      </description>
135      <arg name="layout_mode" type="uint" enum="layout_mode"/>
136    </event>
137
138    <request name="get_remote_output" since="1">
139      <description summary="extend output interface for remote shell">
140	Instantiate an interface extension for the given wl_output to
141	provide remote shell functionality.
142      </description>
143      <arg name="id" type="new_id" interface="zcr_remote_output_v2" summary="the new remote output interface id"/>
144      <arg name="output" type="object" interface="wl_output"/>
145    </request>
146
147    <enum name="desktop_focus_state">
148      <description summary="desktop foucs state">
149	Desktop client window focus state.
150      </description>
151      <entry name="no_focus" value="1" summary="no window get focused"/>
152      <entry name="client_focused" value="2" summary="client window get focused"/>
153      <entry name="other_client_focused" value="3" summary="other client window get focused"/>
154    </enum>
155
156    <event name="desktop_focus_state_changed" since="1">
157      <description summary="desktop window focus state change">
158	Notifies client that the window focus state change.
159      </description>
160      <arg name="focus_state" type="uint" enum="desktop_focus_state"/>
161    </event>
162
163  </interface>
164
165  <interface name="zcr_remote_surface_v2" version="6">
166    <description summary="A desktop window">
167      An interface that may be implemented by a wl_surface, for
168      implementations that provide a desktop-style user interface
169      and allows for remotely managed windows.
170
171      It provides requests to treat surfaces like windows, allowing to set
172      properties like app id and geometry.
173
174      The client must call wl_surface.commit on the corresponding wl_surface
175      for the remote_surface state to take effect.
176
177      For a surface to be mapped by the compositor the client must have
178      committed both an remote_surface state and a buffer.
179    </description>
180
181    <enum name="systemui_visibility_state">
182      <description summary="systemui visibility behavior">
183	Determine the visibility behavior of the system UI.
184      </description>
185      <entry name="visible" value="1" summary="system ui is visible"/>
186      <entry name="autohide_non_sticky" value="2" summary="system ui autohides and is not sticky"/>
187      <entry name="autohide_sticky" value="3" summary="system ui autohides and is sticky"/>
188    </enum>
189
190    <request name="destroy" type="destructor">
191      <description summary="Destroy the remote_surface">
192	Unmap and destroy the window. The window will be effectively
193	hidden from the user's point of view, and all state will be lost.
194      </description>
195    </request>
196
197    <request name="set_app_id">
198      <description summary="set application ID">
199	Set an application identifier for the surface.
200      </description>
201      <arg name="app_id" type="string"/>
202    </request>
203
204    <request name="set_title">
205      <description summary="set surface title">
206	Set a short title for the surface.
207
208	This string may be used to identify the surface in a task bar,
209	window list, or other user interface elements provided by the
210	compositor.
211
212	The string must be encoded in UTF-8.
213      </description>
214      <arg name="title" type="string"/>
215    </request>
216
217    <request name="set_top_inset">
218      <description summary="set top inset for surface">
219	Set distance from the top of the surface to the contents.
220
221	This distance typically represents the size of the window caption.
222      </description>
223      <arg name="height" type="int"/>
224    </request>
225
226    <request name="maximize">
227      <description summary="maximize">
228	Request that surface is maximized. The window geometry will be updated
229	to whatever the compositor finds appropriate for a maximized window.
230
231	This is only a request that the window should be maximized. The
232	compositor may choose to ignore this request. The client should
233	listen to state_type_changed events to determine if the window was
234	maximized or not.
235      </description>
236    </request>
237
238    <request name="minimize">
239      <description summary="minimize">
240	Request that surface is minimized.
241
242	This is only a request that the window should be minimized. The
243	compositor may choose to ignore this request. The client should
244	listen to state_type_changed events to determine if the window was
245	minimized or not.
246      </description>
247    </request>
248
249    <request name="restore">
250      <description summary="restore">
251	Request that surface is restored. This restores the window geometry
252	to what it was before the window was minimized, maximized or made
253	fullscreen.
254
255	This is only a request that the window should be restored. The
256	compositor may choose to ignore this request. The client should
257	listen to state_type_changed events to determine if the window was restored
258  or not.
259      </description>
260    </request>
261
262    <request name="fullscreen">
263      <description summary="fullscreen">
264	Request that surface is made fullscreen.
265
266	This is only a request that the window should be made fullscreen.
267	The compositor may choose to ignore this request. The client should
268	listen to set_fullscreen events to determine if the window was
269	made fullscreen or not.
270      </description>
271    </request>
272
273    <request name="pin">
274      <description summary="pin">
275	Request that surface is pinned.
276
277	This is only a request that the window should be pinned.
278	The compositor may choose to ignore this request. The client should
279	listen to state_type_changed events to determine if the window was
280	pinned or not. If trusted flag is non-zero, the app can prevent users
281	from exiting the pinned mode.
282      </description>
283      <arg name="trusted" type="int"/>
284    </request>
285
286    <request name="unpin">
287      <description summary="unpin">
288	Request that surface is unpinned.
289
290	This is only a request that the window should be unpinned.
291	The compositor may choose to ignore this request. The client should
292	listen to state_type_changed events to determine if the window was
293	unpinned or not.
294      </description>
295    </request>
296
297    <request name="set_system_modal">
298      <description summary="suggests a re-layout of remote shell input area">
299	Suggests a surface should become system modal.
300      </description>
301    </request>
302
303    <request name="unset_system_modal">
304      <description summary="suggests a re-layout of remote shell input area">
305	Suggests a surface should become non system modal.
306      </description>
307    </request>
308
309    <event name="close">
310      <description summary="surface wants to be closed">
311	The close event is sent by the compositor when the user
312	wants the surface to be closed. This should be equivalent to
313	the user clicking the close button in client-side decorations,
314	if your application has any...
315
316	This is only a request that the user intends to close your
317	window. The client may choose to ignore this request, or show
318	a dialog to ask the user to save their data...
319      </description>
320    </event>
321
322    <enum name="state_type">
323      <description summary="state types for remote surfaces">
324	Defines common show states for shell surfaces.
325      </description>
326      <entry name="normal" value="1" summary="normal window state"/>
327      <entry name="minimized" value="2" summary="minimized window state"/>
328      <entry name="maximized" value="3" summary="maximized window state"/>
329      <entry name="fullscreen" value="4" summary="fullscreen window state"/>
330      <entry name="pinned" value="5" summary="pinned window state"/>
331      <entry name="trusted_pinned" value="6" summary="trusted pinned window state"/>
332      <entry name="moving" value="7" summary="moving window state"/>
333      <entry name="resizing" value="8" summary="resizing window state"/>
334      <entry name="left_snapped" value="9" summary="left snapped window state"/>
335      <entry name="right_snapped" value="10" summary="right snapped window state"/>
336      <entry name="pip" value="11" summary="pip window state"/>
337    </enum>
338
339    <event name="state_type_changed">
340      <description summary="surface state type changed">
341	The state_type_changed event is sent by the compositor when
342	the surface state changed.
343
344	This is an event to notify that the window state changed in compositor.
345	The state change may be triggered by a client's request, or some user
346	action directly handled by the compositor. The client may choose to
347	ignore this event.
348      </description>
349      <arg name="state_type" type="uint" enum="state_type"/>
350    </event>
351
352    <request name="set_rectangular_surface_shadow" since="1">
353      <description summary="set a rectangular shadow">
354	Request that surface needs a rectangular shadow.
355
356	This is only a request that the surface should have a rectangular
357	shadow. The compositor may choose to ignore this request.
358
359	The arguments are given in the remote surface coordinate space and
360	specifies inner bounds of the shadow. Specifying zero width and height
361	will disable the shadow.
362      </description>
363      <arg name="x" type="int"/>
364      <arg name="y" type="int"/>
365      <arg name="width" type="int"/>
366      <arg name="height" type="int"/>
367    </request>
368
369    <request name="set_systemui_visibility" since="1">
370      <description summary="requests the system ui visibility behavior for the surface">
371	Requests how the surface will change the visibility of the system UI when it is made active.
372      </description>
373      <arg name="visibility" type="uint" enum="systemui_visibility_state"/>
374    </request>
375
376    <request name="set_always_on_top" since="1">
377      <description summary="set always on top">
378	Request that surface is made to be always on top.
379
380	This is only a request that the window should be always on top.
381	The compositor may choose to ignore this request.
382
383      </description>
384    </request>
385
386    <request name="unset_always_on_top" since="1">
387      <description summary="unset always on top">
388	Request that surface is made to be not always on top.
389
390	This is only a request that the window should be not always on top.
391	The compositor may choose to ignore this request.
392      </description>
393    </request>
394
395    <enum name="orientation">
396      <description summary="window orientation">
397	The orientation of the window.
398      </description>
399      <entry name="portrait" value="1" summary="portrait"/>
400      <entry name="landscape" value="2" summary="landscape"/>
401    </enum>
402
403    <request name="set_orientation" since="1">
404      <description summary="set orientation">
405	Set an orientation for the surface.
406      </description>
407      <arg name="orientation" type="int" enum="orientation"/>
408    </request>
409
410    <event name="window_geometry_changed" since="1">
411      <description summary="announce window geometry commit">
412	Notify the client of committed window geometry.
413
414	The compositor sends this event when it commits window geometry. The
415	client may use this information to convert coordinates of input events
416	using the latest committed geometry.
417      </description>
418      <arg name="x" type="int"/>
419      <arg name="y" type="int"/>
420      <arg name="width" type="int"/>
421      <arg name="height" type="int"/>
422    </event>
423
424    <enum name="bounds_change_reason">
425      <description summary="bounds_change_reason">
426	Specifies the cause of the window bounds change event.
427      </description>
428      <entry name="drag_move" value="1" summary="the window is being moved by drag operation"/>
429      <entry name="drag_resize" value="2" summary="the window is being resized by drag operation."/>
430      <entry name="snap_to_left" value="3" summary="the window is resized to left snapped state"/>
431      <entry name="snap_to_right" value="4" summary="the window is resized to right snapped state"/>
432      <entry name="move" value="5" summary="the window bounds is moved due to other WM operations"/>
433      <entry name="resize" value="6" summary="the window bounds is reiszed due to other WM operations"/>
434      <entry name="pip" value="7" summary="the window bounds is resized or moved for PIP"/>
435      <entry name="float" value="8" summary="the window bounds is resized or moved for float state" since="3"/>
436    </enum>
437
438    <event name="bounds_changed" since="1">
439      <description summary="The compositor requested to change the bounds">
440	The compositor requested to change its
441	bounds. "bounds_change_reason" specifies the cause of the
442	bounds change. The client may apply the different move/resize
443	strategy depending on the reason.
444
445	"display_id_hi", "display_id_lo" specifies in which workspace
446	the surface should live in.
447
448	The client responds with set_bounds_in_output request, with the
449	bounds it is resized to (this may be different from the bounds
450	requested).
451
452	The client may ignore move request depending on the state,
453	e.g, if it becomes resizable or other constrants.
454      </description>
455      <arg name="display_id_hi" type="uint"/>
456      <arg name="display_id_lo" type="uint"/>
457      <arg name="x" type="int"/>
458      <arg name="y" type="int"/>
459      <arg name="width" type="int"/>
460      <arg name="height" type="int"/>
461      <arg name="bounds_change_reason" type="uint" enum="bounds_change_reason"/>
462    </event>
463
464    <request name="start_move" since="1">
465      <description summary="start an interactive move">
466	Request an interactive, user-driven move of the surface. "x"
467	and "y" specifies the starting point of the pointer device
468	that initiated the move.
469
470	The compositor responds to this request with a drag_started
471	event with "none" direction.  Please see drag_started event
472	for more details.
473
474	The compositor may ignore move requests depending on the state of the
475	surface, e.g. fullscreen or maximized.
476      </description>
477      <arg name="x" type="int"/>
478      <arg name="y" type="int"/>
479    </request>
480
481    <enum name="resize_direction">
482      <description summary="resize direction">
483	The resize direction for drag operation
484      </description>
485      <entry name="none" value="0" summary="move only, no resize"/>
486      <entry name="left" value="1" summary="resize to the left"/>
487      <entry name="topleft" value="2" summary="resize to the top left"/>
488      <entry name="top" value="3" summary="resize to the top"/>
489      <entry name="topright" value="4" summary="resize to the top right"/>
490      <entry name="right" value="5" summary="resize to the right"/>
491      <entry name="bottomright" value="6" summary="resize to the buttom right"/>
492      <entry name="bottom" value="7" summary="resize to the bottom"/>
493      <entry name="bottomleft" value="8" summary="resize to the bottom left"/>
494    </enum>
495
496    <event name="drag_started" since="1">
497      <description summary="Notifies that a drag to move/resize started.">
498	Notifies a client that the compositor started drag
499	operation. "direction" specifies which direction it is being
500	resized. "none" direction means just move but not resize.
501
502	This will be followed by series of the "bounds_changed" event
503	with "drag_resize" or "drag_move" reasons to update the window
504	bounds druing the drag operation.
505      </description>
506      <arg name="direction" type="uint" enum="resize_direction"/>
507    </event>
508
509    <event name="drag_finished" since="1">
510      <description summary="Notifies that a drag operation has finished.">
511	Called when the drag operation is finished.  "x" and "y"
512	specifies the position of the pointer device used to drag.
513	"canceled" is true if the drag operation is aborted during
514	drag (e.g. by capture change or user action.)
515      </description>
516      <arg name="x" type="int"/>
517      <arg name="y" type="int"/>
518      <arg name="canceled" type="int" summary="true if the operation was canceled"/>
519    </event>
520
521    <request name="set_can_maximize" since="1">
522      <description summary="set can_maximize">
523	Request that surface can be in maximzied state.
524      </description>
525    </request>
526
527    <request name="unset_can_maximize" since="1">
528      <description summary="unset can_maximize">
529	Request that surface can not be in maximzied state.
530      </description>
531    </request>
532
533    <request name="set_min_size" since="1">
534      <description summary="set the minimum size">
535	Set a minimum size of the surface.
536
537	Values set in this way are double-buffered. They will get
538	applied on the next commit.
539      </description>
540      <arg name="width" type="int"/>
541      <arg name="height" type="int"/>
542    </request>
543
544    <request name="set_max_size" since="1">
545      <description summary="set the maximum size">
546	Set a maximum size of the surface.
547
548	Values set in this way are double-buffered. They will get
549	applied on the next commit.
550
551	Setting the same size as minimum size makes the surface
552	unresizable.
553      </description>
554      <arg name="width" type="int"/>
555      <arg name="height" type="int"/>
556    </request>
557
558    <request name="set_snapped_to_left" since="1">
559      <description summary="set the surface to left snapped">
560	Request that surface is snapped to left.
561      </description>
562    </request>
563
564    <request name="set_snapped_to_right" since="1">
565      <description summary="set the surface to right snapped">
566	Request that surface is snapped to right.
567      </description>
568    </request>
569
570    <request name="start_resize" since="1">
571      <description summary="start an interactive resize">
572	Request to start an interactive, user-driven resize of the surface.
573	"x" and "y" specifies the starting point of the pointer device
574	that initiated the reize.
575
576	The compositor responds to this request with a "drag_started"
577	event, followed by "bounds_changed" events, and ends the
578	resize operation with a "drag_finhsed" event. The compositor
579	determines the new bounds using the resize_direction and the
580	pointer event location.
581
582	The compositor may ignore resize requests depending on the state of the
583	surface, e.g. fullscreen or maximized, or no drag event is in pregress.
584      </description>
585      <arg name="resize_direction" type="uint" enum="resize_direction"/>
586      <arg name="x" type="int"/>
587      <arg name="y" type="int"/>
588    </request>
589
590    <enum name="frame_type">
591      <description summary="frame types">
592	Frame type that can be used to decorate a surface.
593      </description>
594      <entry name="none" value="0" summary="no frame"/>
595      <entry name="normal" value="1" summary="caption with shadow"/>
596      <entry name="shadow" value="2" summary="shadow only"/>
597      <entry name="autohide" value="3" summary="autohide frame with shadow"/>
598      <entry name="overlay" value="4" summary="[Deprecated] overlay frame with shadow"/>
599      <entry name="overlap" value="5" summary="overlap frame with the window" since="6"/>
600    </enum>
601
602    <request name="set_frame" since="1">
603      <description summary="request a frame for surface">
604	Enables compositor side frame decoration. |type|
605	specifies the type of frame to use for the surface.
606      </description>
607      <arg name="type" type="uint" enum="frame_type"/>
608    </request>
609
610    <enum name="frame_button_type" bitfield="true">
611      <description summary="frame button types">
612	The mask that represents buttons on frame.
613      </description>
614      <entry name="back" value="1" summary="a button to naviate backwards"/>
615      <entry name="minimize" value="2" summary="a button to minimize the window"/>
616      <entry name="maximize_restore" value="4"
617	     summary="a button to maximize or restore"/>
618      <entry name="menu" value="8"
619	     summary="a button to activate application's menu"/>
620      <entry name="close" value="16" summary="a button to close the window"/>
621      <entry name="zoom" value="32"
622	     summary="a mask to turn the maximize_restore button to zoom button"/>
623      <entry name="center" value="64"
624	     summary="a customizable, center-aligned button"/>
625      <entry name="float" value="128"
626	     summary="a button to float a window without maximize or restore"/>
627    </enum>
628
629    <request name="set_frame_buttons" since="1">
630      <description summary="updates buttons' state on frame">
631	Updates the frame's button state. |visible_buttons| and |enabled_buttons|
632	are the union of button mask defined in |frame_button_type| enum.
633
634	The mask present in |enabled_buttons| but not in |visible_buttons| will
635	be ignored.
636      </description>
637      <arg name="visible_buttons" type="uint"/>
638      <arg name="enabled_buttons" type="uint"/>
639    </request>
640
641    <request name="set_extra_title" since="1">
642      <description summary="set extra title string">
643	The extra informational string about the surface. This can be
644	used to show the debug information in the title bar, or log
645	messages.
646
647	This is different from "set_title" which is used to identify
648	the surface.
649
650	The string must be encoded in UTF-8.
651      </description>
652      <arg name="extra_title" type="string"/>
653    </request>
654
655    <enum name="orientation_lock">
656      <description summary="orientation lock request for remote surfaces">
657	Defines orientation request when a remote surface is in foreground.
658      </description>
659      <entry name="none" value="1" summary="no orientation lock"/>
660      <entry name="portrait" value="2" summary="primary or secondary portrait"/>
661      <entry name="landscape" value="3" summary="primary or secondary landscape"/>
662      <entry name="current" value="4" summary="keep current orientation"/>
663      <entry name="portrait_primary" value="5" summary="primary portrait"/>
664      <entry name="landscape_primary" value="6" summary="primary landscape"/>
665      <entry name="portrait_secondary" value="7" summary="secondary portrait"/>
666      <entry name="landscape_secondary" value="8" summary="secondary landscape"/>
667    </enum>
668
669    <request name="set_orientation_lock" since="1">
670      <description summary="set orientation lock for a remote surface">
671	Request a specific orientation behavior when this surface is in foreground.
672      </description>
673      <arg name="orientation_lock" type="uint" enum="orientation_lock"/>
674    </request>
675
676    <request name="pip" since="1">
677      <description summary="set pip for a remote surface">
678	Request that surface is set to Picture-in-Picture (PIP).
679      </description>
680    </request>
681
682    <request name="set_aspect_ratio" since="1">
683      <description summary="set the maximum size">
684	Set an aspect ratio of the surface.
685
686	Values set in this way are double-buffered. They will get
687	applied on the next commit.
688
689	The ratio of the values is used for the ratio of width to height of the
690  surface. The size of surface is restricted to the ratio. If any value is
691  zero, the restriction on aspect ratio is unset.
692      </description>
693      <arg name="width" type="int"/>
694      <arg name="height" type="int"/>
695    </request>
696
697    <enum name="zoom_change">
698      <description summary="zoom level change">
699	Zoom level change.
700      </description>
701      <entry name="in" value="0" summary="zoom in"/>
702      <entry name="out" value="1" summary="zoom out"/>
703      <entry name="reset" value="2" summary="reset zoom level"/>
704    </enum>
705
706    <event name="change_zoom_level" since="1">
707      <description summary="change zoom level">
708	Request application zoom level change.
709      </description>
710      <arg name="change" type="int" enum="zoom_change"/>
711    </event>
712
713    <request name="set_accessibility_id" since="1">
714      <description summary="set accessibility ID to the surface">
715        [Deprecated] Use zaura_surface's set_accessibility_id instead.
716
717        Set accessibility window ID to the surface. A negative number removes
718        the existing accessibility ID from the surface.
719      </description>
720      <arg name="id" type="int" summary="Accessibility ID. Negative number removes existing accessibility ID from the surface."/>
721    </request>
722
723    <request name="set_pip_original_window" since="1">
724      <description summary="set the pip original window">
725        Set this surface the original window for the current PIP window.
726      </description>
727    </request>
728
729    <request name="unset_pip_original_window" since="1">
730      <description summary="unset the pip original window">
731        Unset this surface the original window for the current PIP window.
732      </description>
733    </request>
734
735    <request name="set_system_gesture_exclusion" since="1">
736      <description summary="set system gesture exclusion">
737        Set system gesture exclusion region in which system gestures e.g. back
738        gesture should not be triggered.
739      </description>
740      <arg name="region" type="object" interface="wl_region" allow-null="true"/>
741    </request>
742
743    <request name="set_resize_lock" since="1">
744      <description summary="set resize lock state">
745          [Deprecated] Enable the resize lock and put restrictions related to resizing on
746          the shell surface.
747
748          The resize lock state is double buffered, and will be applied at the
749          time wl_surface.commit of the corresponding wl_surface is called.
750      </description>
751    </request>
752
753    <request name="unset_resize_lock" since="1">
754      <description summary="unset resize lock state">
755          [Deprecated] Disable the resize lock and allow the shell surface to be resized
756          freely.
757
758          The resize lock state is double buffered, and will be applied at the
759          time wl_surface.commit of the corresponding wl_surface is called.
760      </description>
761    </request>
762
763    <event name="bounds_changed_in_output" since="1">
764      <description summary="The compositor requested to change the bounds">
765	The compositor requested to change its
766	bounds. "bounds_change_reason" specifies the cause of the
767	bounds change. The client may apply the different move/resize
768	strategy depending on the reason.
769
770	The "output" specifies the wayland output in which the suface should live.
771
772	The client responds with set_bounds_in_output request, with the
773	bounds it is resized to (this may be different from the bounds
774	requested).
775
776	The client may ignore move request depending on the state,
777	e.g, if it becomes resizable or other constrants.
778      </description>
779      <arg name="output" type="object" interface="wl_output"/>
780      <arg name="x" type="int"/>
781      <arg name="y" type="int"/>
782      <arg name="width" type="int"/>
783      <arg name="height" type="int"/>
784      <arg name="bounds_change_reason" type="uint" enum="bounds_change_reason"/>
785    </event>
786
787    <request name="set_bounds_in_output" since="1">
788      <description summary="set window bounds">
789	Set the "visible bounds" of a window from the user's perspective.
790	Client-side decorations often have invisible portions like drop shadows
791	which should be ignored for the purposes of aligning, placing and
792	constraining windows.
793
794	The bounds are double buffered, and will be applied at the
795	time wl_surface.commit of the corresponding wl_surface is called.
796
797	Once the bounds are set, it is not possible to unset them, and they will
798	remain the same until set_bounds_in_output is called again, even if a new sub-
799	surface or buffer is attached.
800
801	If never set, the value is the surface content bounds. This updates
802	dynamically on every commit.
803
804	The bounds are relative to the given display. If the display is invalid,
805	they are assumed to be relative to the primary display.
806
807	The width and height must be greater than zero.
808      </description>
809      <arg name="output" type="object" interface="wl_output"/>
810      <arg name="x" type="int"/>
811      <arg name="y" type="int"/>
812      <arg name="width" type="int"/>
813      <arg name="height" type="int"/>
814    </request>
815
816    <!-- Version 2 additions -->
817
818    <enum name="resize_lock_type">
819      <description summary="resize lock type">
820  Resize lock type that can be used to put restrictions related to resizing.
821      </description>
822      <entry name="none" value="0" summary="follows normal resizeable policies"/>
823      <entry name="resize_enabled_togglable" value="1" summary="resizing is enabled and resize lock type is togglable" />
824      <entry name="resize_disabled_togglable" value="2" summary="resizing is disabled and resize lock type is togglable" />
825      <entry name="resize_disalbed_nontoggleable" value="3" summary="resizing is disabled and resize lock type is not togglable"/>
826    </enum>
827
828    <request name="set_resize_lock_type" since="2">
829      <description summary="set resize lock type">
830  Set resize lock type and put restrictions related to resizing on the shell surface.
831
832  The resize lock type is double buffered, and will be applied at the
833  time wl_surface.commit of the corresponding wl_surface is called.
834      </description>
835      <arg name="type" type="uint" enum="resize_lock_type" summary="resize lock type"/>
836    </request>
837
838    <request name="set_float" since="3">
839      <description summary="set the surface to be floated">
840	Request that surface is floated.
841      </description>
842    </request>
843
844    <!-- Version 4 additions -->
845    <request name="set_scale_factor" since="4">
846      <description summary="Allows the client to set the scale factor for the future buffer commits.">
847        The client has a 32-bit float scale factor that is associated with each
848        remote surface. This scale factor must be propagated exactly to exo. To
849        do so we reinterpret_cast into a 32-bit uint and later cast back into a
850        float. This is because wayland does not support native transport of
851        floats. As different CPU architectures may use different endian
852        representations for IEEE 754 floats, this protocol implicitly assumes
853        that the caller and receiver are the same machine.
854        This is double buffered state and will be applied in the next commit.
855      </description>
856      <arg name="scale_factor_as_uint" type="uint"/>
857    </request>
858
859     <!-- Version 5 additions -->
860    <request name="set_window_corner_radii" since="5">
861      <description summary="Request to apply rounded corners to the window of the surface.">
862        The client specifies the radius of each corner to be applied to the
863        window in DPs (device independent pixels).
864
865        The window radius is double buffered, and will be applied at the
866        time wl_surface.commit of the corresponding wl_surface is called.
867
868        Note: Rounded corner radii affects the wl_surface tree, including
869        subsurfaces. Once this protocol is called, surfaces cannot set
870        their own rounded corner bounds because rounded window bounds will be
871        applied to the whole surface tree.
872      </description>
873      <arg name="upper_left_radius" type="uint"/>
874      <arg name="upper_right_radius" type="uint"/>
875      <arg name="lower_right_radius" type="uint"/>
876      <arg name="lower_left_radius" type="uint"/>
877    </request>
878
879    <!-- Version 6 additions -->
880    <request name="set_shadow_corner_radii" since="6">
881      <description summary="Request to apply rounded corners to the shadow of the surface.">
882        The client specifies the radius of each corner to be applied to the shadow
883        associated with the aura toplevel surface in device independent pixels (DPs).
884
885        The shadow radius is double buffered, and will be applied at the
886        time wl_surface.commit of the corresponding wl_surface is called.
887      </description>
888      <arg name="upper_left_radius" type="uint"/>
889      <arg name="upper_right_radius" type="uint"/>
890      <arg name="lower_right_radius" type="uint"/>
891      <arg name="lower_left_radius" type="uint"/>
892    </request>
893  </interface>
894
895  <interface name="zcr_notification_surface_v2" version="1">
896    <description summary="A notification window">
897      An interface that may be implemented by a wl_surface to host
898      notification contents.
899    </description>
900
901    <request name="destroy" type="destructor">
902      <description summary="Destroy the notification_surface">
903	Unmap and destroy the notification surface.
904      </description>
905    </request>
906
907    <request name="set_app_id" since="1">
908      <description summary="set application ID">
909	Set an application identifier for the notification surface.
910      </description>
911      <arg name="app_id" type="string"/>
912    </request>
913  </interface>
914
915  <interface name="zcr_input_method_surface_v2" version="1">
916    <description summary="An input method window">
917      An interface that may be implemented by a wl_surface to host IME contents.
918    </description>
919
920    <request name="destroy" type="destructor">
921      <description summary="Destroy the ime_surface">
922	Unmap and destroy the input mtehod surface.
923      </description>
924    </request>
925
926    <request name="set_bounds_in_output" since="1">
927      <description summary="set window bounds">
928	Set the "visible bounds" of a window from the user's perspective.
929
930	The bounds are double buffered, and will be applied at the
931	time wl_surface.commit of the corresponding wl_surface is called.
932
933	Once the bounds are set, it is not possible to unset them, and they will
934	remain the same until set_bounds_in_output is called again, even if a new sub-
935	surface or buffer is attached.
936
937	If never set, the value is the surface content bounds. This updates
938	dynamically on every commit.
939
940	The bounds are relative to the given display. If the display is invalid,
941	they are assumed to be relative to the primary display.
942
943	The width and height must be greater than zero.
944      </description>
945      <arg name="output" type="object" interface="wl_output"/>
946      <arg name="x" type="int"/>
947      <arg name="y" type="int"/>
948      <arg name="width" type="int"/>
949      <arg name="height" type="int"/>
950    </request>
951  </interface>
952
953  <interface name="zcr_toast_surface_v2" version="2">
954    <description summary="A toast window">
955      An interface that may be implemented by a wl_surface to host
956      toast contents.
957    </description>
958
959    <request name="destroy" type="destructor">
960      <description summary="Destroy the toast_surface">
961	Unmap and destroy the toast surface.
962      </description>
963    </request>
964
965    <request name="set_bounds_in_output" since="1">
966      <description summary="set toast bounds position">
967	Set the bounds of a toast window from the user's perspective.
968
969	The bounds are double buffered, and will be applied at the
970	time wl_surface.commit of the corresponding wl_surface is called.
971
972	Once the bounds are set, it is not possible to unset them, and they will
973	remain the same until set_bounds is called again, even if a new sub-
974	surface or buffer is attached.
975
976	If never set, the compositor will determine the toast position.
977
978	The bounds are relative to the given display. If the display is invalid,
979	they are assumed to be relative to the primary display.
980      </description>
981      <arg name="output" type="object" interface="wl_output"/>
982      <arg name="x" type="int"/>
983      <arg name="y" type="int"/>
984      <arg name="width" type="int"/>
985      <arg name="height" type="int"/>
986    </request>
987
988    <!-- Version 2 additions -->
989    <request name="set_scale_factor" since="2">
990      <description summary="Allows the client to set the scale factor for the future buffer commits.">
991        The client has a 32-bit float scale factor that is associated with each
992        remote surface. This scale factor must be propagated exactly to exo. To
993        do so we reinterpret_cast into a 32-bit uint and later cast back into a
994        float. This is because wayland does not support native transport of
995        floats. As different CPU architectures may use different endian
996        representations for IEEE 754 floats, this protocol implicitly assumes
997        that the caller and receiver are the same machine.
998        This is double buffered state and will be applied in the next commit.
999      </description>
1000      <arg name="scale_factor_as_uint" type="uint"/>
1001    </request>
1002  </interface>
1003
1004  <interface name="zcr_remote_output_v2" version="1">
1005    <description summary="remote shell interface to a wl_output">
1006	An additional interface to a wl_output object, which allows the
1007	client to access additional functionality for output.
1008    </description>
1009
1010    <request name="destroy" type="destructor" since="1">
1011      <description summary="destroy remote_output">
1012	Destroy this remote_output object.
1013      </description>
1014    </request>
1015
1016    <event name="display_id" since="1">
1017      <description summary="the identifier for the display">
1018	[Deprecated] Sends the display identifier used by the server for the display.
1019      </description>
1020      <arg name="display_id_hi" type="uint"/>
1021      <arg name="display_id_lo" type="uint"/>
1022    </event>
1023
1024    <event name="port" since="1">
1025      <description summary="the port of the display">
1026	Sends the port to which the display is connected for the server.
1027      </description>
1028      <arg name="port" type="uint"/>
1029    </event>
1030
1031    <event name="identification_data" since="1">
1032      <description summary="the identification data for the display">
1033	Sends the identification data for the display, typically in the EDID format.
1034      </description>
1035      <arg name="identification_data" type="array"/>
1036    </event>
1037
1038    <event name="insets" since="1">
1039      <description summary="insets for the display in pixels">
1040	Sends inset information about a particular display in the display's native coordinates.
1041      </description>
1042      <arg name="inset_left" type="int"/>
1043      <arg name="inset_top" type="int"/>
1044      <arg name="inset_right" type="int"/>
1045      <arg name="inset_bottom" type="int"/>
1046    </event>
1047
1048    <event name="stable_insets" since="1">
1049      <description summary="stable insets for a display in pixels">
1050	Sends stable inset information about a particular display in the display's native
1051	coordinates.
1052      </description>
1053      <arg name="stable_inset_left" type="int"/>
1054      <arg name="stable_inset_top" type="int"/>
1055      <arg name="stable_inset_right" type="int"/>
1056      <arg name="stable_inset_bottom" type="int"/>
1057    </event>
1058
1059    <enum name="systemui_behavior">
1060      <description summary="systemui behavior">
1061	Determine the behavior of the system UI.
1062      </description>
1063      <entry name="visible" value="1" summary="system ui is visible"/>
1064      <entry name="hidden" value="2" summary="system ui is autohide or hidden"/>
1065    </enum>
1066
1067    <event name="systemui_behavior" since="1">
1068      <description summary="systemui_behavior_state for a display">
1069	Sends information about whether the systemui behavior is auto hide.
1070	The "systemui_behavior" value is of enum type "systemui_behavior".
1071      </description>
1072      <arg name="systemui_behavior" type="int" enum="systemui_behavior"/>
1073    </event>
1074
1075 </interface>
1076
1077</protocol>
1078