Reputation: 415
I am a proud and satisfied user of XMonad, but I don't really know how to write configs for it. I was wondering whether it was possible to customize my xmonad.hs config to achieve the following functionality:
When focused on an empty workspace, enter a certain modifier (e.g. alt-shift-left) to move all following (i.e. higher index) workspaces to the left by one. So, if I have a terminal in workspace 1, a browser in workspace 3, and email in workspace 4, I can switch to workspace 2 and use this keystroke to move the browser to workspace 2 and the mail client to workspace 3.
When focused on any workspace, enter a certain modifier (e.g. alt-shift-right) to move all the windows in that workspace to the next workspace to the right, shifting all the following indices over by one as well, Hilbert Hotel style. That way, if I want to open a window in the second workspace, I can empty it by moving its current contents to the third, the contents of the third to the fourth, and so on. Essentially, this is the inverse of the above operation.
XMonad seems powerful and customizable enough that I doubt that this is impossible. Does anyone have an implementation?
Upvotes: 3
Views: 923
Reputation: 745
Using XMonad.Actions.DynamicWorkspace
you can add and delete Workspaces, and XMonad.Actions.WorkspaceNames
provides functionality for renaming them.
This way you can
This way there is no need to shift the applications.
Upvotes: 2