Re: Pending EWMH additions



Hi,

Here is a patch that tackles some of the issues.

 - I cleaned up the _NET_DESKTOP_LAYOUT patch a bit 
   (but wasn't sure what issues were left, maybe I didn't 
    address them)
 
 - Added _NET_SHOWING_DESKTOP root window property and client 
   message

 - Added _NET_WM_STATE_STAYS_ON_TOP (I like FLOATING more, but since
   KWin uses STAYS_ON_TOP already maybe it's not worth changing)

 - Added _NET_WM_STATE_STUCK_TO_GLASS (this is for onscreen keyboards, 
   but doesn't fully cover their needs; the other thing they need is 
   to never be focused when clicked. I'm not sure what the right 
   thing here is, just throwing out an idea.)

Of the other issues, I would like to sort out the saving-window-states
thing, but only a couple people commented, so I don't feel like we
have consensus. Still it's a big practical problem IMO. Well, rather,
if we do nothing the "applications are responsible for it" solution
will just happen by itself. So if people prefer another solution we
should cover this.

I would say the multihead/Xinerama discussion can be saved for a later
version of the spec. I'm not sure yet how many issues there are.

Havoc

Index: wm-spec.sgml
===================================================================
RCS file: /home/freedesktop/wm-spec/wm-spec.sgml,v
retrieving revision 1.20
diff -u -p -u -r1.20 wm-spec.sgml
--- wm-spec.sgml	11 Jun 2002 21:18:30 -0000	1.20
+++ wm-spec.sgml	10 Jul 2002 02:27:15 -0000
@@ -357,7 +357,8 @@ _NET_DESKTOP_VIEWPORT
 		<para>
 The Window Manager MAY choose to ignore this message, in which case _NET_DESKTOP_VIEWPORT property will remain unchanged.
 		</para>
-	</sect2><sect2><title>_NET_CURRENT_DESKTOP</title>
+	</sect2>
+        <sect2><title>_NET_CURRENT_DESKTOP</title>
 	<programlisting><![CDATA[
 _NET_CURRENT_DESKTOP desktop, CARDINAL/32
 ]]></programlisting>
@@ -373,7 +374,8 @@ _NET_CURRENT_DESKTOP
   format = 32
   data.l[0] = new_index
 ]]></programlisting>
-	</sect2><sect2><title>_NET_DESKTOP_NAMES</title>
+	</sect2>
+       <sect2><title>_NET_DESKTOP_NAMES</title>
 	<programlisting><![CDATA[
 _NET_DESKTOP_NAMES, UTF8_STRING[]
 ]]></programlisting>
@@ -463,6 +465,100 @@ virtual roots and allows clients to figu
 windows.
 	</para>
 	</sect2>
+	<sect2>
+	<title>_NET_DESKTOP_LAYOUT</title>
+	<programlisting><![CDATA[
+_NET_DESKTOP_LAYOUT, CARDINAL[3]/32
+]]>
+ #define _NET_WM_ORIENTATION_HORZ 0
+ #define _NET_WM_ORIENTATION_VERT 1
+</programlisting>
+        <para>
+        <emphasis>This property is set by a workspace switcher or
+        pager application, not by the window manager.</emphasis>
+        When setting this property, the workspace switcher must
+        own a manager selection (as defined in the ICCCM 2.8). 
+        The manager selection is called
+        <literal>_NET_DESKTOP_LAYOUT_Sn</literal> where
+        <literal>n</literal> is the screen number. The purpose of 
+        this property is to allow the window manager to know the desktop 
+        layout displayed by the pager.
+        </para>
+	<para>
+  <literal>_NET_DESKTOP_LAYOUT</literal> describes the layout of virtual
+  desktops relative to each other. More specifically, it describes the layout
+  used by the owner of the manager selection. The window manager may use 
+  this layout information or may choose to ignore it.
+  The property contains three values: the pager orientation, the number of
+  desktops in the X direction, and the number in the Y direction.
+        </para>
+  <para>
+  The virtual desktops are arranged in a rectangle
+  with X rows and Y columns.  If X times Y does not match the total number of
+  desktops as specified by
+  <literal>_NET_NUMBER_OF_DESKTOPS</literal>, the highest-numbered
+  workspaces are assumed to be nonexistent. Either X or Y (but not
+  both) may be specified as 0 in which case its actual value will be
+  derived from <literal>_NET_NUMBER_OF_DESKTOPS</literal>.
+        </para>
+        <para>
+  When the orientation is <literal>_NET_WM_ORIENTATION_HORZ</literal> (integer
+ value 0) the layout for X=4 and Y=3 looks like this:
+<programlisting>
+ +--+--+--+--+
+ | 0| 1| 2| 3|
+ +--+--+--+--+
+ | 4| 5| 6| 7|
+ +--+--+--+--+
+ | 8| 9|10|11|
+ +--+--+--+--+
+</programlisting>
+         </para>
+        <para>
+
+  When the orientation is <literal>_NET_WM_ORIENTATION_VERT</literal>
+  (integer value 1) the layout for X=4 and Y=3 looks like:
+
+<programlisting>
+ +--+--+--+--+
+ | 0| 3| 6| 9|
+ +--+--+--+--+
+ | 1| 4| 7|10|
+ +--+--+--+--+
+ | 2| 5| 8|11|
+ +--+--+--+--+
+</programlisting>
+	</para>
+        <para>
+         The numbers here are the desktop numbers, as for 
+         <literal>_NET_CURRENT_DESKTOP</literal>.
+        </para>
+	</sect2>
+
+        <sect2><title>_NET_SHOWING_DESKTOP</title>
+	<programlisting><![CDATA[
+_NET_SHOWING_DESKTOP desktop, CARDINAL/32
+]]></programlisting>
+	<para>
+Some window managers have a "showing the desktop" mode in which windows are
+hidden, and the desktop background is displayed and focused. If a window manager
+supports the _NET_SHOWING_DESKTOP hint, it MUST set it to a value of 1 if the
+window manager is in "showing the desktop" mode, and a value of zero if the
+window manager is not in this mode.
+        </para>
+        <para>
+If an external application wants to enter or leave the mode, it MUST send a
+_NET_SHOWING_DESKTOP client message to the root window requesting the change:
+	<programlisting><![CDATA[
+_NET_SHOWING_DESKTOP
+  message_type = _NET_SHOWING_DESKTOP 
+  format = 32
+  data.l[0] = boolean 0 or 1
+]]></programlisting> 
+ The window manager may choose to ignore this client message.
+	</para>
+	</sect2>
+
 	</sect1>
 	<sect1>
 	<title>Other Root Window Messages</title>
@@ -737,6 +833,7 @@ _NET_WM_STATE_SKIP_TASKBAR, ATOM
 _NET_WM_STATE_SKIP_PAGER, ATOM
 _NET_WM_STATE_HIDDEN, ATOM
 _NET_WM_STATE_FULLSCREEN, ATOM
+_NET_WM_STATE_STAYS_ON_TOP, ATOM
 ]]></programlisting>
       <para>
 An implementation MAY add new atoms to this list. Implementations
@@ -800,6 +897,28 @@ _NET_WM_STATE_FULLSCREEN indicates that 
 and have no window decorations. For example, a presentation program would use
 this hint.
 	</para>
+
+	<para>
+_NET_WM_STATE_STAYS_ON_TOP indicates that the window should be on top of normal
+windows. Applications should not set this hint if _NET_WM_WINDOW_TYPE already
+conveys the exact nature of the window. Windows in this state would typically
+appear above other windows of type _NET_WM_WINDOW_TYPE_NORMAL, but potentially
+below windows of type _NET_WM_WINDOW_TYPE_DOCK, below dialogs that are transient
+for the STAYS_ON_TOP window, and below windows in state
+_NET_WM_STATE_FULLSCREEN. That is, windows in this state are not necessarily
+above all windows, only above normal applications.
+	</para>
+
+	<para>
+_NET_WM_STATE_STUCK_TO_GLASS indicates that the window should be on top of
+<emphasis>everything</emphasis>; including fullscreen presentations and movies,
+docks, the application's own transient windows, and so on. An example of when
+this hint should be used is an onscreen keyboard application, where a disabled
+user may rely on accessing the onscreen keyboard to be able to interact with the
+computer. Applications should not set this hint if _NET_WM_WINDOW_TYPE already
+conveys the exact nature of the window.
+	</para>
+
 	<para>
 To change the state of a mapped window, a Client MUST send a _NET_WM_STATE
 client message to the root window  (window is the respective window, type



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]