[wiki] [sites] dwm/patches: Add 'titlecolor' patch || Leon Plickat
commit 16d3caa56a18c2f13454ed82d1671944f0a0f877
Author: Leon Plickat <Leon-Plickat_AT_protonmail.com>
Date: Mon Dec 31 01:33:22 2018 +0100
dwm/patches: Add 'titlecolor' patch
This patch adds the possibility to independently change the foreground and background
colors of the window title displayed on the bar.
diff --git a/dwm.suckless.org/patches/titlecolor/dwm-titlecolor-6.1.diff b/dwm.suckless.org/patches/titlecolor/dwm-titlecolor-6.1.diff
new file mode 100644
index 00000000..6f34b805
--- /dev/null
+++ b/dwm.suckless.org/patches/titlecolor/dwm-titlecolor-6.1.diff
_AT_@ -0,0 +1,43 @@
+diff -up dwm-b/config.def.h dwm-a/config.def.h
+--- dwm-b/config.def.h 2015-11-08 23:39:37.000000000 +0100
++++ dwm-a/config.def.h 2018-12-31 00:51:15.215522689 +0100
+_AT_@ -11,6 +11,8 @@ static const char normfgcolor[] = "#
+ static const char selbordercolor[] = "#005577";
+ static const char selbgcolor[] = "#005577";
+ static const char selfgcolor[] = "#eeeeee";
++static const char titlebgcolor[] = "#222222";
++static const char titlefgcolor[] = "#005577";
+ static const unsigned int borderpx = 1; /* border pixel of windows */
+ static const unsigned int snap = 32; /* snap pixel */
+ static const int showbar = 1; /* 0 means no bar */
+diff -up dwm-b/dwm.c dwm-a/dwm.c
+--- dwm-b/dwm.c 2015-11-08 23:39:37.000000000 +0100
++++ dwm-a/dwm.c 2018-12-31 01:02:44.315267927 +0100
+_AT_@ -59,7 +59,7 @@
+
+ /* enums */
+ enum { CurNormal, CurResize, CurMove, CurLast }; /* cursor */
+-enum { SchemeNorm, SchemeSel, SchemeLast }; /* color schemes */
++enum { SchemeNorm, SchemeSel, SchemeTitle, SchemeLast }; /* color schemes */
+ enum { NetSupported, NetWMName, NetWMState,
+ NetWMFullscreen, NetActiveWindow, NetWMWindowType,
+ NetWMWindowTypeDialog, NetClientList, NetLast }; /* EWMH atoms */
+_AT_@ -742,7 +742,7 @@ drawbar(Monitor *m)
+ if ((w = x - xx) > bh) {
+ x = xx;
+ if (m->sel) {
+- drw_setscheme(drw, m == selmon ? &scheme[SchemeSel] : &scheme[SchemeNorm]);
++ drw_setscheme(drw, m == selmon ? &scheme[SchemeTitle] : &scheme[SchemeNorm]);
+ drw_text(drw, x, 0, w, bh, m->sel->name, 0);
+ drw_rect(drw, x + 1, 1, dx, dx, m->sel->isfixed, m->sel->isfloating, 0);
+ } else {
+_AT_@ -1586,6 +1586,9 @@ setup(void)
+ scheme[SchemeSel].border = drw_clr_create(drw, selbordercolor);
+ scheme[SchemeSel].bg = drw_clr_create(drw, selbgcolor);
+ scheme[SchemeSel].fg = drw_clr_create(drw, selfgcolor);
++ scheme[SchemeTitle].border = drw_clr_create(drw, normbordercolor);
++ scheme[SchemeTitle].bg = drw_clr_create(drw, titlebgcolor);
++ scheme[SchemeTitle].fg = drw_clr_create(drw, titlefgcolor);
+ /* init bars */
+ updatebars();
+ updatestatus();
diff --git a/dwm.suckless.org/patches/titlecolor/index.md b/dwm.suckless.org/patches/titlecolor/index.md
new file mode 100644
index 00000000..d6046153
--- /dev/null
+++ b/dwm.suckless.org/patches/titlecolor/index.md
_AT_@ -0,0 +1,14 @@
+# titlecolor
+
+## Description
+
+Adds a new color scheme used by the window title in the bar, so that its colors
+(foreground and background) can be changed independently.
+
+## Download
+
+* [dwm-titlecolor-6.1.diff](dwm-titlecolor-6.1.diff) (31.12.2018)
+
+## Author
+
+* Leon Plickat <leonhenrik[dot]plickat[at]stud[dot]uni-goettingen[dot]de>
Received on Mon Dec 31 2018 - 01:38:10 CET
This archive was generated by hypermail 2.3.0
: Mon Dec 31 2018 - 01:48:27 CET