The following lines bind mod-[wer] to going to displays 1, 2 and 3. Instead of this mechanism, I'd like to toggle between displays in a single keystroke, How can I do so?
Thanks.
[((m .|. modm, key), screenWorkspace sc >>= flip whenJust (windows . f))
| (key, sc) <- zip [xK_e, xK_w, xK_r] [0..]
, (f, m) <- [(W.view, 0), (W.shift, shiftMask)]]
Have a look at:
http://xmonad.org/xmonad-docs/xmonad-contrib/XMonad-Actions-CycleWS.html#1
Don't forget the import line import XMonad.Actions.CycleWS