Implement 'workspace back_and_forth' (Patch by Michael Walle)

This commit is contained in:
Michael Stapelberg
2011-10-17 23:17:56 +01:00
parent c3a18104cd
commit 178be03fa6
8 changed files with 101 additions and 4 deletions

View File

@ -737,6 +737,25 @@ force_xinerama yes
Also note that your output names are not descriptive (like +HDMI1+) when using
Xinerama, instead they are counted up, starting at 0: +xinerama-0+, +xinerama-1+, …
=== Automatic back-and-forth when switching to the current workspace
This configuration directive enables automatic +workspace back_and_forth+ (see
<<back_and_forth>>) when switching to the workspace that is currently focused.
For instance: Assume you are on workspace "1: www" and switch to "2: IM" using
mod+2 because somebody sent you a message. You dont need to remember where you
came from now, you can just press mod+2 again to switch back to "1: www".
*Syntax*:
--------------------------------------
workspace_auto_back_and_forth <yes|no>
--------------------------------------
*Example*:
---------------------------------
workspace_auto_back_and_forth yes
---------------------------------
== List of commands
Commands are what you bind to specific keypresses. You can also issue commands
@ -892,6 +911,10 @@ workspace 1, 3, 4 and 9 and you want to cycle through them with a single key
combination. Similarily, you can use +move workspace next+ and +move workspace
prev+ to move a container to the next/previous workspace.
[[back_and_forth]]
To switch back to the previously focused workspace, use +workspace
back_and_forth+.
To move a container to another xrandr output such as +LVDS1+ or +VGA1+, you can
use the +move output+ command followed by the name of the target output. You
may also use +left+, +right+, +up+, +down+ instead of the xrandr output name to
@ -906,6 +929,9 @@ bindsym mod+2 workspace 2
bindsym mod+Shift+1 move workspace 1
bindsym mod+Shift+2 move workspace 2
...
# switch between the current and the previously focused one
bindsym mod+b workspace back_and_forth
-------------------------
==== Named workspaces