Eugeni Dodonov has asked for a keybinding to return to the previous workspace. For example, if you were on workspace 1 and switched to workspace 2, then pressing this key would jump back to workspace 1. Pressing it again would jump to workspace 2. Apparently this is a standard keybinding in xfwm4.
This is GNOME bug 618018, and there is a patch.
However, we believe this can be done adequately with an external EWMH-based script, although it’s a little more difficult than most EWMH scripts because it requires internal state.
Incidentally, this may be an interesting moment to discuss the question of whether Metacity should be able to make DBus calls on given keypresses as well as launching external scripts. Supplementing the EWMH controls with DBus is often suggested (see, for example, GNOME bug 531512 and ewmhbus) but perhaps we should instead be considering sending signals when windows are opened, hot keys are pressed, and workspaces are switched.
Photo © coffee bee, cc-by-nc.
After your comment, I actually agree that, as this is a seldom-used functionality, having an external script for it would be better. I just could not think on a way to implement it without going directly into metacity/mutter code, but it could be a solution.
In any case, thanks for the feedback!
As this is a seldom-used functionality, having an external script for it would be better
You are believe this can be done adequately with an external EWMH-based script?