X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=main.c;h=067f383666b460f366eee558f48e2c589e655633;hb=f679125206ae28b38f77e9620a67365d310ddff3;hp=47749fe3215b2470b979b5076268155449211277;hpb=6a9300e8158ec0c35d92f09e886c653758408948;p=dwm.git diff --git a/main.c b/main.c index 47749fe..067f383 100644 --- a/main.c +++ b/main.c @@ -17,10 +17,10 @@ /* 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, ntags, numlockmask; +unsigned int master, nmaster, ntags, numlockmask; Atom wmatom[WMLast], netatom[NetLast]; Bool running = True; Bool issel = True; @@ -101,6 +101,7 @@ setup(void) { cursor[CurResize] = XCreateFontCursor(dpy, XC_sizing); cursor[CurMove] = XCreateFontCursor(dpy, XC_fleur); /* init modifier map */ + numlockmask = 0; modmap = XGetModifierMapping(dpy); for (i = 0; i < 8; i++) { for (j = 0; j < modmap->max_keypermod; j++) { @@ -128,11 +129,12 @@ 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; + updatemodetext(); /* bar */ bx = sx; by = sy;