Where to start? Implementing independent workspace switching with Xinerama
ja at disorder.sk
Tue Jun 26 22:13:31 CEST 2012
Omari Stephens <xsdg+xfcedev <at> mit.edu> writes:
> I'd like to implement independent workspace switching in Xinerama.
Specifically, this will allow a
> person with multiple screens and Xinerama extensions to switch workspaces on
one screen while leaving
> the workspaces on other screens untouched. The current Xinerama workspace
behavior is a blocking
> drawback for me (it completely disrupts the way I use workspaces), and is the
only reason I'm still using
> multihead rather than Xinerama.
> After peeking through the source code a bit, I'm not really sure where to
start. However, I've come up with
> two potential plans of attack. For the first, I would make xfwm4 understand
that there are n sets of
> workspaces (for an n-screen setup), and that it should concurrently show
clients from 1 of each of the n
> sets of workspaces. By requiring that a workspace in class k only contain
clients that are on screen k, it
> seems like this could work.
> For the second plan, xfwm4 and friends would have to gain some conception of
virtual workspaces. That is, it
> is my possibly-mistaken understanding that xfwm4 considers a "workspace" to be
a set of clients that can
> occupy any location in a single screen. Since Xinerama presents (with special
metadata) a single
> oddly-shaped screen to xfwm4, xfwm4 currently only supports having a single
workspace span the entire
> oddly-shaped screen (which may encompass a display containing n physical
screens). A virtual workspace
> might be some partition of a workspace (with physical extents restricted to
match one of the physical
> screens) that could be swapped out for another partition from a different
> A further extension of this idea might be the ability to move entire
workspaces from one screen to another.
> Considering, for example, someone with 2 monitors and an email workspace, an
instant message workspace,
> and a web browser workspace, this might allow that person to look at a set of
web pages while chatting with
> someone via instant message and subsequently to either send email related to
the web pages or related to
> the instant message discussion.
> That said, any suggestions on where to start? As it stands, the first plan
seems like it would be less painful
> to implement, but the second may be more robust; I'm not sure. Any help or
tips would be appreciated.
This is old message but I was researching this topic.
I just implemented experimental prototype of this feature. Code is available
here and should work with any window manager which doesn't use viewports
(tested with xfwm4):
More information about the Xfce4-dev