Re: Addition for pager layout.



On Friday 30 November 2001 17:18, Waldo Bastian wrote:
> Hi,
>
> I would like to propose an addition for the NET spec that defines the
> layout of the virtual desktops. The rationale is that a pager may define a
> certain layout for the various virtual desktops and that it should be able
> to inform the window manager about this so that the window manager can
> implement an action like "select the virtual desktop to the right of the
> current one" in a meaningfull way.
>
> This is needed for (at least) KDE since the orientation of the KDE panel
> influences the layout of the pager that is embedded in the panel while the
> window manager handles the "select desktop left/right/up/down" action which
> can be bound to keybindings or can be used by the "active/eletric desktop
> border" feature of the window manager.

What about Above/Below relationship ?

>
> _NET_DESKTOP_LAYOUT orient, x, y, CARDINAL[][3]/32
>
> A Window Manager MAY choose to ignore this message
>
> Structure describing the layout of virtual desktops relative to each other.
>
> The virtual desktops are being laid out in a rectangular fashion with
> x desktops next to each other and y desktops above each other.
> x times y must match the total number of desktops as specified by
> _NET_NUMBER_OF_DESKTOPS. Either x or y (but not both) may be specified as
> -1 in which case its actual value will be derived from
> _NET_NUMBER_OF_DESKTOPS.
>
> When orient is _NET_WM_ORIENTATION_HORZ the layout for x=4 and y=3 looks
> like:
<snip>


It would be much cooler if Pager could send messages like : 

_NET_DESKTOP_NEIGHBOUR   desk,relationship,neighbour, CARDINAL[3]/32

where relationship is one of: 

_NET_DESKTOP_NEIGHBOUR_WEST
_NET_DESKTOP_NEIGHBOUR_NORTH
_NET_DESKTOP_NEIGHBOUR_EAST
_NET_DESKTOP_NEIGHBOUR_SOUTH
_NET_DESKTOP_NEIGHBOUR_ABOVE
_NET_DESKTOP_NEIGHBOUR_BELOW

_NET_DESKTOP_NEIGHBOUR_FORGET ( to drop relationship between desks)

Sort of like XFree configures screens in xinerama. ( only more traditional 
North/west/east/south instead of left/right/etc. )

This way you don't limit anybody to rectangular number of desks, 
relationships can come and go, as desktops added/removed, etc.

Also it makes it more extensible, for example if window manager allows for 
some additional relationship between desktops - it could simply add more 
atoms, which will be ignored by others.

Naturally Window Manager should store that info in some property of the root 
window. Which is a bit trikier then with original approach.
Two possible solutions are : 
1) Store entire log of such messages ( except for _FORGET ones ) :

_NET_DESKTOP_NEIGHBOURHOOD,  CARDINAL [][3]/32

2) Store per-desktop list of relationships ;
_NET_DESKTOP_NEIGHBOURHOOD,  CARDINAL [][2]/32, For example : 

Desk 0:                                                            Desk1:
| _WEST, 1|_NORTH, 2|_FORGET,0xFFFFFFFF| _EAST, 0| _NORTH,3| ....

where _FORGET, 0xFFFFFFFF pair represent end of the one desktop and beginning 
of another's data.


Cheers
Sasha



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