[dev] dwm with top and bottom bar

From: Sidney Amani <seed95_AT_gmail.com>
Date: Mon, 20 Jul 2009 22:59:51 +0200

Hi list,

I would like to share my conf which is optimized for laptops or
single screen users.

As I like to keep my top bar with the window title and tag
descriptions, I couldn't display enough information in the
top-right corner.
So I just quickly patched dwm to add a empty bottom border
and I use conky to display information at the bottom.

My bottom bar is only 10 pix but anyway if you miss some
space you can use MODKEY+B to get the full screen available.

I let you take a look at the screenshot :
http://yfrog.com/b8screenshotconf1p

If you want to do the same just launch conky like this :
conky -d -y 2

This is the patch, you just have to define an "int marginbottom"
in your config.h with the size in pixel of the bottom margin.

diff -r bcce736c1de3 dwm.c
--- a/dwm.c Tue Jul 14 19:07:53 2009 +0100
+++ b/dwm.c Mon Jul 20 22:43:09 2009 +0200
@@ -1674,6 +1674,9 @@
         m->wh = m->mh;
         if(m->showbar) {
                 m->wh -= bh;
+ m->wh -= marginbottom;
+ if(!m->topbar)
+ m->wy += marginbottom;
                 m->by = m->topbar ? m->wy : m->wy + m->wh;
                 m->wy = m->topbar ? m->wy + bh : m->wy;
         }

Enjoy

-- 
Sidney Amani
Received on Mon Jul 20 2009 - 20:59:51 UTC

This archive was generated by hypermail 2.2.0 : Mon Jul 20 2009 - 21:12:02 UTC