dwm-colorbar-6.2.diff (3120B)
1 diff --git a/config.def.h b/config.def.h 2 index 1c0b587..a516645 100644 3 --- a/config.def.h 4 +++ b/config.def.h 5 @@ -16,6 +16,11 @@ static const char *colors[][3] = { 6 /* fg bg border */ 7 [SchemeNorm] = { col_gray3, col_gray1, col_gray2 }, 8 [SchemeSel] = { col_gray4, col_cyan, col_cyan }, 9 + [SchemeStatus] = { col_gray3, col_gray1, "#000000" }, // Statusbar right {text,background,not used but cannot be empty} 10 + [SchemeTagsSel] = { col_gray4, col_cyan, "#000000" }, // Tagbar left selected {text,background,not used but cannot be empty} 11 + [SchemeTagsNorm] = { col_gray3, col_gray1, "#000000" }, // Tagbar left unselected {text,background,not used but cannot be empty} 12 + [SchemeInfoSel] = { col_gray4, col_cyan, "#000000" }, // infobar middle selected {text,background,not used but cannot be empty} 13 + [SchemeInfoNorm] = { col_gray3, col_gray1, "#000000" }, // infobar middle unselected {text,background,not used but cannot be empty} 14 }; 15 16 /* tagging */ 17 diff --git a/dwm.c b/dwm.c 18 index 4465af1..0d1d2f7 100644 19 --- a/dwm.c 20 +++ b/dwm.c 21 @@ -59,7 +59,7 @@ 22 23 /* enums */ 24 enum { CurNormal, CurResize, CurMove, CurLast }; /* cursor */ 25 -enum { SchemeNorm, SchemeSel }; /* color schemes */ 26 +enum { SchemeNorm, SchemeSel, SchemeStatus, SchemeTagsSel, SchemeTagsNorm, SchemeInfoSel, SchemeInfoNorm }; /* color schemes */ 27 enum { NetSupported, NetWMName, NetWMState, NetWMCheck, 28 NetWMFullscreen, NetActiveWindow, NetWMWindowType, 29 NetWMWindowTypeDialog, NetClientList, NetLast }; /* EWMH atoms */ 30 @@ -703,7 +703,7 @@ drawbar(Monitor *m) 31 32 /* draw status first so it can be overdrawn by tags later */ 33 if (m == selmon) { /* status is only drawn on selected monitor */ 34 - drw_setscheme(drw, scheme[SchemeNorm]); 35 + drw_setscheme(drw, scheme[SchemeStatus]); 36 sw = TEXTW(stext) - lrpad + 2; /* 2px right padding */ 37 drw_text(drw, m->ww - sw, 0, sw, bh, 0, stext, 0); 38 } 39 @@ -716,7 +716,7 @@ drawbar(Monitor *m) 40 x = 0; 41 for (i = 0; i < LENGTH(tags); i++) { 42 w = TEXTW(tags[i]); 43 - drw_setscheme(drw, scheme[m->tagset[m->seltags] & 1 << i ? SchemeSel : SchemeNorm]); 44 + drw_setscheme(drw, scheme[m->tagset[m->seltags] & 1 << i ? SchemeTagsSel : SchemeTagsNorm]); 45 drw_text(drw, x, 0, w, bh, lrpad / 2, tags[i], urg & 1 << i); 46 if (occ & 1 << i) 47 drw_rect(drw, x + boxs, boxs, boxw, boxw, 48 @@ -725,17 +725,17 @@ drawbar(Monitor *m) 49 x += w; 50 } 51 w = blw = TEXTW(m->ltsymbol); 52 - drw_setscheme(drw, scheme[SchemeNorm]); 53 + drw_setscheme(drw, scheme[SchemeTagsNorm]); 54 x = drw_text(drw, x, 0, w, bh, lrpad / 2, m->ltsymbol, 0); 55 56 if ((w = m->ww - sw - x) > bh) { 57 if (m->sel) { 58 - drw_setscheme(drw, scheme[m == selmon ? SchemeSel : SchemeNorm]); 59 + drw_setscheme(drw, scheme[m == selmon ? SchemeInfoSel : SchemeInfoNorm]); 60 drw_text(drw, x, 0, w, bh, lrpad / 2, m->sel->name, 0); 61 if (m->sel->isfloating) 62 drw_rect(drw, x + boxs, boxs, boxw, boxw, m->sel->isfixed, 0); 63 } else { 64 - drw_setscheme(drw, scheme[SchemeNorm]); 65 + drw_setscheme(drw, scheme[SchemeInfoNorm]); 66 drw_rect(drw, x, 0, w, bh, 1, 1); 67 } 68 }