Intro to wmii
wmii is a small, dynamic window manager for X11. It is scriptable, has a 9p filesystem interface and supports classic and tiling (acme-like) window management. It aims to maintain a small and clean (read hackable and beautiful) codebase.
Usage
Restart your current GUI session and select wmii from your login manager. You will be presented with a blank screen.
First thing first, before you log into wmii, do the following:
mkdir ~/.wmii-3.5
cp /etc/wmii-3.5/wmiirc ~/.wmii-3.5/
The ~/.wmii-3.5/ file will be the file you use to configure your environment. Note: many to the keystroke required will mention the Mod key, this is usally with Alt button but can be set to another keys (such as the Super Key/ windows key).
Useage
- Mod+Enter -> Start a new Terminal
- The defualt terminal value can be set in ~/.wmii-3.5, there you will find a line stating WMII_TERM=”xterm”, feel free to change that to aterm, eterm, urxvt, etc.
- Mod+p -> dmenu : a menu appears at the bottom of the screen, just type the beginning of the name of the application and enter to open it. Consider this you’re new “Alt F2″, but a bit more powerful. You can read more about demenu here: http://tools.suckless.org/dmenu
Selecting Windows
- Mod+j -> select the window below
- Mod+k -> select the window above
- Mod+h -> select the window to the left
- Mod+l -> select the window to the right
Moving Windows
- Shift+Mod+j -> move the window down
- Shift+Mod+k -> move the window up
- Mod+a -> Actions menu : choose “quit” to quit. You can also chose Welcome to display the welcome message that goes over many of the shortcuts here.
By default, only one column is used by the desktop (i.e. the entire screen). It’s possible to use several columns with h and l :
- Mod+Shift+h : move the selected window left
- Mod+Shift+l : move the selected window right
Layouts
You begin in “default” layout : all windows take the same space. You can make them bigger or smaller by clicking in the little square in the title bar of a window.
- “stacked” layout (Mod+s) : the selected window takes the entire column, but you can see the title bar of the other windows
- “maximum” layout (Mod+m) : the selected window takes the entire column, you don’t see other windows.
- “fullscreen” layout (Mod+f) : the selected window takes runs in full screen.
Floating layout
You can place your windows like a classic window manager. It’s called floating layout. It’s useful for some applications, like the Gimp, mplayer, vlc etc.
- Mod+Shift+Space : Move selected window in floating layout.
- Mod+Space : switch between floating layout and normal layout.
In the floating layout, we can select a window with Mod+j and Mod+k. We can change dimensions of the window, by dragging, like in any other window manager. But we can use hotkeys for that as well :
- Mod+Left click : move window
- Mod+Right click : change dimensions of the window (you can use it in other layouts too)
Views and Tagging
Tagging in wmii is very similar to the concept of virtual desktops in other window managers. However, tagging is slightly more powerful because it makes it very easy to group windows in multiple ways concurrently. This is made possible by the fact that WMII easily allows each window to have multiple tags. This allows you to group applications for specific use cases and easily switch between them without having to tear down your previous environment by sending applications to another “Desktop”.
By default, when you first start up wmii you will see the word ‘nil’ in the lower left corner. You are at the ‘nil’ view. The first application you start (such as a terminal: Mod+Enter) will automatically be tagged with a “1″ and you will be automatically switched to view “1″. Views can be navigated or changed with built in keybindings:
- Mod+Shift+2 : tag selected window to view “2″
- Mod+2 : this switches you to view “2″ where you can see all windows tagged with “2″
It’s the same thing for all numbers, from 0 to 9. But you can also use names :
- Mod+t : views menu : you can select a tag with right and left keys, or type the name of the tag (or just a part of the name, if it was created)
- Mod+Shift+t : this retags the currently selected window with whatever you type into the menu.
You can tag windows with multiple views by using a ‘+’ between the tag names :
- Mot+Shift+t foo+bar+2 : this tags the currently selected window to the views “foo”, “bar” and “2″
Tags can be set for specific applications in the wmiirc configuration file.
# Tagging Rules
wmiir write /tagrules <<!
/Firefox.*/ -> ~+2
/Gimp.*/ -> ~+3
/.*/ -> sel
/.*/ -> 1
!
With the above tag rules, firefox starts in floating mode (~) on view “2″. Gimp starts in floating mode on view “3″.
Source, Second Source








