diff options
author | Anselm R. Garbe <arg@suckless.org> | 2007-01-08 17:33:24 +0100 |
---|---|---|
committer | Anselm R. Garbe <arg@suckless.org> | 2007-01-08 17:33:24 +0100 |
commit | 1d4a24dae02cfb3a3241c3d293e96dba910317bd (patch) | |
tree | 52267e4a8de9e198fed15726c20734e7ac735197 /main.c | |
parent | a768ea93fdb3adfa33b3ea7ccc7abfe86a2bfb2a (diff) | |
download | dwm-1d4a24dae02cfb3a3241c3d293e96dba910317bd.tar.gz |
implemented nmaster appearance in mode label (using %u)
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -17,7 +17,7 @@ /* extern */ -char stext[1024]; +char stext[1024], mtext[32]; Bool *seltag; int bx, by, bw, bh, bmw, masterd, screen, sx, sy, sw, sh, wax, way, waw, wah; unsigned int master, nmaster, ntags, numlockmask; @@ -128,12 +128,13 @@ setup(void) { dc.status[ColFG] = getcolor(STATUSFGCOLOR); setfont(FONT); /* geometry */ - bmw = textw(TILESYMBOL) > textw(FLOATSYMBOL) ? textw(TILESYMBOL) : textw(FLOATSYMBOL); sx = sy = 0; sw = DisplayWidth(dpy, screen); sh = DisplayHeight(dpy, screen); master = MASTER; nmaster = NMASTER; + snprintf(mtext, sizeof mtext, arrange == dofloat ? FLOATSYMBOL : TILESYMBOL, nmaster); + bmw = textw(mtext); /* bar */ bx = sx; by = sy; |