Discussion:
[xmonad] Prevent swapping workspaces on multi-monitor setup
Eyal Erez
2016-08-22 22:09:02 UTC
Permalink
Hi,

I use xmonad with two monitors. I love that I can switch workspaces
in each monitor independently. I don't believe any other WM supports
this feature. However, if a workspace is visible on one monitor and I
hit its number on another monitor, xmonad will swap the two
workspaces.

For example:

*focus
mon A B
SW [1] [2]*

If I hit M-1, I get

*focus
mon A B
ws [2] [1]*

I was hoping that there's a way to change this behavior. I would like
xmonad to either not do anything in this case or better yet, switch
the focus on the other monitor without swapping workspaces.

Thank you,
--
There are 10 types of people, those who know binary and those who don't.
Norbert Zeh
2016-08-22 22:59:29 UTC
Permalink
For cycling through workspaces (in my setup with Win-PgUp/PgDown, you can
achieve what you want using moveTo Prev HiddenWS and moveTo Next HiddenWS
(defined in X.A.CycleWS). For switching to workspaces, say 1..10, directly
without messing with their assignment to monitors, XMonad has
XMonad.StackSet.view. With the behaviour you describe, I suspect that your
workspace switching keys are bound to XMonad.StackSet.greedyView.
XMonad.StackSet.view simply focuses the requested workspace if it is
already visible on some monitor and otherwise behaves the same as
greedyView.

Cheers,
Norbert
Post by Eyal Erez
Hi,
I use xmonad with two monitors. I love that I can switch workspaces
in each monitor independently. I don't believe any other WM supports
this feature. However, if a workspace is visible on one monitor and I
hit its number on another monitor, xmonad will swap the two
workspaces.
*focus
mon A B
SW [1] [2]*
If I hit M-1, I get
*focus
mon A B
ws [2] [1]*
I was hoping that there's a way to change this behavior. I would like
xmonad to either not do anything in this case or better yet, switch
the focus on the other monitor without swapping workspaces.
Thank you,
--
There are 10 types of people, those who know binary and those who don't.
_______________________________________________
xmonad mailing list
http://mail.haskell.org/cgi-bin/mailman/listinfo/xmonad
--
Norbert Zeh
Professor and Canada Research Chair
Faculty of Computer Science, Dalhousie University
E: ***@cs.dal.ca - T: +1-902-494-3154 - F: +1-902-492-1517
Brandon Allbery
2016-08-22 23:34:26 UTC
Permalink
I was hoping that there's a way to change this behavior. I would like
xmonad to either not do anything in this case or better yet, switch the
focus on the other monitor without swapping workspaces
https://wiki.haskell.org/Xmonad/Frequently_asked_questions#Replacing_greedyView_with_view
--
brandon s allbery kf8nh sine nomine associates
***@gmail.com ***@sinenomine.net
unix, openafs, kerberos, infrastructure, xmonad http://sinenomine.net
Eyal Erez
2016-08-31 19:54:20 UTC
Permalink
Thank you Brandon, that was _exactly_ what I was looking for.
Post by Brandon Allbery
I was hoping that there's a way to change this behavior. I would like
xmonad to either not do anything in this case or better yet, switch the
focus on the other monitor without swapping workspaces
https://wiki.haskell.org/Xmonad/Frequently_asked_questions#Replacing_
greedyView_with_view
--
brandon s allbery kf8nh sine nomine associates
unix, openafs, kerberos, infrastructure, xmonad
http://sinenomine.net
--
*Eyal Erez <*****@gmail.com* <***@gmail.com>*>*

There are 10 types of people, those who know binary and those who don't.
Loading...