Tiling window management that sucks less - see http://wmii.suckless.org/. This emulates wmii in Vim as much as possible. A dwm emulation might come next.
For the window management, all shortcuts use the Alt (Meta) key by default:
Alt+[sdf] => tiling mode selection: [s]tacked, [d]ivided, [f]ullscreen Alt+[hjkl] => select adjacent window Alt+[HJKL] => move current window Ctrl+Alt+[hjkl] => resize current window
Vim tabs are used as “views”:
Alt+ => select tab [1..10] <Leader> => select tab [1..10] <Leader>t => move current window to tab [1..10] <Leader>T => copy current window to tab [1..10]
Copy the script into your
$HOME/.vim/plugin directory so that it will be sourced on startup.
Warning, using the Alt key in these shortcuts implies that:
- you’re not using Alt as main modifier in your tiling window manager
— in which case, I’d suggest to use the Super (win) key for your WM instead;
- the Alt key is enabled in your Vim session:
- if your Alt key sends Esc instead of setting the 8th bit,
please uncomment the related shortcuts in the
- if you’re running gVim, a quick and dirty way to free Alt-*
shortcuts is to disable all menus:
- if you’re runing MacVim, you’ll have to set the
macmetapref to enable Option keys as "Meta" (MacVim ≥ 7.3 required); and if you want to keep one Option key, this patch will help.
- if your Alt key sends Esc instead of setting the 8th bit, please uncomment the related shortcuts in the
If you’re not pleased with Alt-* shortcuts, you’ll have to define your own shortcuts directly in the
suckless.vim file. :-/
This is my very first Vim plugin, so there should be a bunch of mistakes… feel free to submit corrections, enhancements and suggestions.