main neuswc / protocol / server-decoration.xml
 1<?xml version="1.0" encoding="UTF-8"?>
 2<protocol name="server_decoration">
 3  <copyright><![CDATA[
 4    Copyright (C) 2015 Martin Gräßlin
 5
 6    This program is free software: you can redistribute it and/or modify
 7    it under the terms of the GNU Lesser General Public License as published by
 8    the Free Software Foundation, either version 2.1 of the License, or
 9    (at your option) any later version.
10
11    This program is distributed in the hope that it will be useful,
12    but WITHOUT ANY WARRANTY; without even the implied warranty of
13    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14    GNU Lesser General Public License for more details.
15
16    You should have received a copy of the GNU Lesser General Public License
17    along with this program.  If not, see <http://www.gnu.org/licenses/>.
18  ]]></copyright>
19  <interface  name="org_kde_kwin_server_decoration_manager" version="1">
20      <description summary="Server side window decoration manager">
21        This interface allows to coordinate whether the server should create
22        a server-side window decoration around a wl_surface representing a
23        shell surface (wl_shell_surface or similar). By announcing support
24        for this interface the server indicates that it supports server
25        side decorations.
26
27        Use in conjunction with zxdg_decoration_manager_v1 is undefined.
28      </description>
29      <request name="create">
30        <description summary="Create a server-side decoration object for a given surface">
31            When a client creates a server-side decoration object it indicates
32            that it supports the protocol. The client is supposed to tell the
33            server whether it wants server-side decorations or will provide
34            client-side decorations.
35
36            If the client does not create a server-side decoration object for
37            a surface the server interprets this as lack of support for this
38            protocol and considers it as client-side decorated. Nevertheless a
39            client-side decorated surface should use this protocol to indicate
40            to the server that it does not want a server-side deco.
41        </description>
42        <arg name="id" type="new_id" interface="org_kde_kwin_server_decoration"/>
43        <arg name="surface" type="object" interface="wl_surface"/>
44      </request>
45      <enum name="mode">
46            <description summary="Possible values to use in request_mode and the event mode."/>
47            <entry name="None" value="0" summary="Undecorated: The surface is not decorated at all, neither server nor client-side. An example is a popup surface which should not be decorated."/>
48            <entry name="Client" value="1" summary="Client-side decoration: The decoration is part of the surface and the client."/>
49            <entry name="Server" value="2" summary="Server-side decoration: The server embeds the surface into a decoration frame."/>
50      </enum>
51      <event name="default_mode">
52          <description summary="The default mode used on the server">
53              This event is emitted directly after binding the interface. It contains
54              the default mode for the decoration. When a new server decoration object
55              is created this new object will be in the default mode until the first
56              request_mode is requested.
57
58              The server may change the default mode at any time.
59          </description>
60          <arg name="mode" type="uint" summary="The default decoration mode applied to newly created server decorations."/>
61      </event>
62  </interface>
63  <interface name="org_kde_kwin_server_decoration" version="1">
64      <request name="release" type="destructor">
65        <description summary="release the server decoration object"/>
66      </request>
67      <enum name="mode">
68            <description summary="Possible values to use in request_mode and the event mode."/>
69            <entry name="None" value="0" summary="Undecorated: The surface is not decorated at all, neither server nor client-side. An example is a popup surface which should not be decorated."/>
70            <entry name="Client" value="1" summary="Client-side decoration: The decoration is part of the surface and the client."/>
71            <entry name="Server" value="2" summary="Server-side decoration: The server embeds the surface into a decoration frame."/>
72      </enum>
73      <request name="request_mode">
74          <description summary="The decoration mode the surface wants to use."/>
75          <arg name="mode" type="uint" summary="The mode this surface wants to use."/>
76      </request>
77      <event name="mode">
78          <description summary="The new decoration mode applied by the server">
79              This event is emitted directly after the decoration is created and
80              represents the base decoration policy by the server. E.g. a server
81              which wants all surfaces to be client-side decorated will send Client,
82              a server which wants server-side decoration will send Server.
83
84              The client can request a different mode through the decoration request.
85              The server will acknowledge this by another event with the same mode. So
86              even if a server prefers server-side decoration it's possible to force a
87              client-side decoration.
88
89              The server may emit this event at any time. In this case the client can
90              again request a different mode. It's the responsibility of the server to
91              prevent a feedback loop.
92          </description>
93          <arg name="mode" type="uint" summary="The decoration mode applied to the surface by the server."/>
94      </event>
95  </interface>
96</protocol>