Hi, I'm proposing that we add a new _NET_WM_STATE_FOCUSED hint to _NET_WM_STATE. The goal is to be able to do something like [1].
We decided not to use the existing _NET_ACTIVE_WINDOW property since it would mean that all clients would have to listen for changes on the root window properties and also because _NET_ACTIVE_WINDOW allows for at most one window while _NET_WM_STATE_FOCUSED can be set for any number windows. I'm attaching a patch against the 1.4.draft-2 xml file that I got from [2]. Comments are very welcome. Rui [1] http://gitorious.org/gnome-design/gnome-design/blobs/master/mockups/theming/unfocused-window.png [2] http://www.freedesktop.org/wiki/Specifications/wm-spec
diff --git a/wm-spec-1.4.xml b/wm-spec-1.4.xml index 98f9f9b..2518824 100644 --- a/wm-spec-1.4.xml +++ b/wm-spec-1.4.xml @@ -1117,6 +1117,7 @@ _NET_WM_STATE_FULLSCREEN, ATOM _NET_WM_STATE_ABOVE, ATOM _NET_WM_STATE_BELOW, ATOM _NET_WM_STATE_DEMANDS_ATTENTION, ATOM +_NET_WM_STATE_FOCUSED, ATOM ]]></programlisting> <para> An implementation MAY add new atoms to this list. Implementations @@ -1207,6 +1208,17 @@ the window got the required attention (usually, that it got activated). </para> <para> +_NET_WM_STATE_FOCUSED indicates that the window is being presented as +focused. This is purely an hint about how the Window Manager visually displays +the window, in particular it's unrelated to input. Clients MUST regard this as +a read only hint which they can't change. The window given by +_NET_ACTIVE_WINDOW will usually have this hint, but at times other windows may +as well, if they have a strong association with the active window and will be +considered as a unit with it by the user. This hint generally corresponds to +whether window decorations are drawn in an active state. + </para> + + <para> To change the state of a mapped window, a Client MUST send a _NET_WM_STATE client message to the root window: </para> @@ -2267,6 +2279,9 @@ Added _NET_WM_FULL_PLACEMENT. <listitem><para> Added _NET_WM_FULLSCREEN_MONITORS. </para></listitem> + <listitem><para> +Added _NET_WM_STATE_FOCUSED. + </para></listitem> </itemizedlist> </sect2> <sect2>
_______________________________________________ wm-spec-list mailing list wm-spec-list@gnome.org http://mail.gnome.org/mailman/listinfo/wm-spec-list