dwm-titlecolor-6.1.diff - sites - public wiki contents of suckless.org
HTML git clone git://git.suckless.org/sites
DIR Log
DIR Files
DIR Refs
---
dwm-titlecolor-6.1.diff (2099B)
---
1 diff -up dwm-b/config.def.h dwm-a/config.def.h
2 --- dwm-b/config.def.h 2015-11-08 23:39:37.000000000 +0100
3 +++ dwm-a/config.def.h 2018-12-31 00:51:15.215522689 +0100
4 @@ -11,6 +11,8 @@ static const char normfgcolor[] = "#
5 static const char selbordercolor[] = "#005577";
6 static const char selbgcolor[] = "#005577";
7 static const char selfgcolor[] = "#eeeeee";
8 +static const char titlebgcolor[] = "#222222";
9 +static const char titlefgcolor[] = "#005577";
10 static const unsigned int borderpx = 1; /* border pixel of windows */
11 static const unsigned int snap = 32; /* snap pixel */
12 static const int showbar = 1; /* 0 means no bar */
13 diff -up dwm-b/dwm.c dwm-a/dwm.c
14 --- dwm-b/dwm.c 2015-11-08 23:39:37.000000000 +0100
15 +++ dwm-a/dwm.c 2018-12-31 01:02:44.315267927 +0100
16 @@ -59,7 +59,7 @@
17
18 /* enums */
19 enum { CurNormal, CurResize, CurMove, CurLast }; /* cursor */
20 -enum { SchemeNorm, SchemeSel, SchemeLast }; /* color schemes */
21 +enum { SchemeNorm, SchemeSel, SchemeTitle, SchemeLast }; /* color schemes */
22 enum { NetSupported, NetWMName, NetWMState,
23 NetWMFullscreen, NetActiveWindow, NetWMWindowType,
24 NetWMWindowTypeDialog, NetClientList, NetLast }; /* EWMH atoms */
25 @@ -742,7 +742,7 @@ drawbar(Monitor *m)
26 if ((w = x - xx) > bh) {
27 x = xx;
28 if (m->sel) {
29 - drw_setscheme(drw, m == selmon ? &scheme[SchemeSel] : &scheme[SchemeNorm]);
30 + drw_setscheme(drw, m == selmon ? &scheme[SchemeTitle] : &scheme[SchemeNorm]);
31 drw_text(drw, x, 0, w, bh, m->sel->name, 0);
32 drw_rect(drw, x + 1, 1, dx, dx, m->sel->isfixed, m->sel->isfloating, 0);
33 } else {
34 @@ -1586,6 +1586,9 @@ setup(void)
35 scheme[SchemeSel].border = drw_clr_create(drw, selbordercolor);
36 scheme[SchemeSel].bg = drw_clr_create(drw, selbgcolor);
37 scheme[SchemeSel].fg = drw_clr_create(drw, selfgcolor);
38 + scheme[SchemeTitle].border = drw_clr_create(drw, normbordercolor);
39 + scheme[SchemeTitle].bg = drw_clr_create(drw, titlebgcolor);
40 + scheme[SchemeTitle].fg = drw_clr_create(drw, titlefgcolor);
41 /* init bars */
42 updatebars();
43 updatestatus();