[xmonad] darcs patch: GridSelect

Clemens Fruhwirth clemens at endorphin.org
Sun Nov 9 16:03:54 EST 2008

Hi everyone,

Here is my little GridSelect toy. I don't think it's polished enough
to go into contrib, but as I was asked about it when I posted a
screenshot on IRC, I thought that I don't want to hold it back until
I found time to polish it.


GridSelect brings up a 2D grid of windows in the center of the screen,
and I can select a window with cursors keys. The window is delivered
back to the caller of GridSelect, and for the moment the most useful
thing it does for me is to raise and focus the selected window. The
advantage over the presentation of Tabbed is that there is much more
space for window titles, that are now not forced into a single row at
the top of the screen, but can occupy multiple rows. Also navigating a
2D grid is also much faster than navigating a linear 1D structure.

GridSelect colorizes the cells according to the window class of
displayed window. So, all windows with the same class get the same
color, and after a while I start to remember which window class has
which color. E.g., when I want my xchat window, I just have to search
for light green, or if I want an emacs windows, I have to focus on
dark violet.

There are a few ideas that I haven't found time to toy with. First I
like the window arrangement to be more static. At the moment, the
windows are sorted (by XMonad) according to its last use and
GridSelect arranges them spiraling outwards in a diamond like
pattern. Mentally, I can only keep track of the usage history to the
depth of 2-3 for blindly selecting window. For everything else, I have
to read titles. It would be more helpful to give fixed spots to
windows. Of course, windows get deleted and new windows pop up all the
time. Probably it would be good to defragment/sort by display time
upon a key press.

Substring search on window titles is another idea. As GridSelect uses
cursor keys for the moment, the rest of the keyboard could be used to
enter the string used in searching. GridSelect should then gray out
the windows that do not contain the search term.

Thanks to the community for XMonad,

Fruhwirth Clemens - http://clemens.endorphin.org 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: GridSelect.darcs
Type: application/octet-stream
Size: 16876 bytes
Desc: not available
Url : http://www.haskell.org/pipermail/xmonad/attachments/20081109/59d3532d/GridSelect-0001.obj

More information about the xmonad mailing list