1234567891011121314151617181920212223242526272829303132333435363738 |
- --- dwm.c
- +++ dwm.c
- @@ -708,7 +710,7 @@ drawbar(Monitor *m)
- if (m == selmon) { /* status is only drawn on selected monitor */
- drw_setscheme(drw, scheme[SchemeNorm]);
- tw = TEXTW(stext) - lrpad + 2; /* 2px right padding */
- - drw_text(drw, m->ww - tw, 0, tw, bh, 0, stext, 0);
- + drw_text(drw, m->ww - tw - 2 * sp, 0, tw, bh, 0, stext, 0);
- }
-
- for (c = m->clients; c; c = c->next) {
- @@ -734,12 +736,12 @@ drawbar(Monitor *m)
- if ((w = m->ww - tw - x) > bh) {
- if (m->sel) {
- drw_setscheme(drw, scheme[m == selmon ? SchemeSel : SchemeNorm]);
- - drw_text(drw, x, 0, w, bh, lrpad / 2, m->sel->name, 0);
- + drw_text(drw, x, 0, w - 2 * sp, bh, lrpad / 2, m->sel->name, 0);
- if (m->sel->isfloating)
- drw_rect(drw, x + boxs, boxs, boxw, boxw, m->sel->isfixed, 0);
- } else {
- drw_setscheme(drw, scheme[SchemeNorm]);
- - drw_rect(drw, x, 0, w, bh, 1, 1);
- + drw_rect(drw, x, 0, w - 2 * sp, bh, 1, 1);
- }
- }
- drw_map(drw, m->barwin, 0, 0, m->ww, bh);
- @@ -1549,7 +1551,10 @@ setup(void)
- die("no fonts could be loaded.");
- lrpad = drw->fonts->h;
- bh = drw->fonts->h + 2;
- + sp = sidepad;
- + vp = (topbar == 1) ? vertpad : - vertpad;
- updategeom();
- +
- /* init atoms */
- utf8string = XInternAtom(dpy, "UTF8_STRING", False);
- wmatom[WMProtocols] = XInternAtom(dpy, "WM_PROTOCOLS", False);
|