[xmonad] Configuring XMonad.Layout.Monitor

Roman Cheplyaka roma at ro-che.info
Fri Dec 26 17:12:36 EST 2008

In order to simplify understanding and configuration of Monitor
extension, I made these (backwards-incompatible) changes:
- remove a bunch of add*Monitor functions
- added some new, so now monitor can be configured using three steps:

1. Define Monitor record. 'monitor' can be used as a template, so if you
   don't need some features (opacity, named monitors) or you're ok with
   default values you may not define corresponding fields (or even know
   about them).

    clock = monitor
        { prop = ClassName "Cairo-clock" `And` Title "MacSlow's Cairo-Clock"
        , rect = (Rectangle (1280-150) (800-150) 150 150)
        , persistent = True
        , opacity = 0xAAAAAAAA

2. Add ManageHook to de-manage monitor windows and apply opacity settings.

    manageHook = myManageHook <+> manageMonitor clock

3. Apply layout modifier.

    myLayouts = ModifiedLayout clock $ ...

Please see updated documentation for details.

To users who have already configured their monitors: all you need to
change is layout (define monitor and use ModifiedLayout instead of
addMonitor). You may leave manageHook as it is and it will work.
So conversion should be pretty easy. Sorry for the inconvenience.

Roman I. Cheplyaka (aka Feuerbach @ IRC)

More information about the xmonad mailing list