From 41259cc53bb01ca01564321894ffa027c1fd2928 Mon Sep 17 00:00:00 2001 From: dianshi Date: Sun, 5 Apr 2020 14:49:13 +0100 Subject: Added urgent notification coloring --- dwm.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'dwm.c') diff --git a/dwm.c b/dwm.c index 2ce630f..0a1e33e 100644 --- a/dwm.c +++ b/dwm.c @@ -61,7 +61,11 @@ /* enums */ enum { CurNormal, CurResize, CurMove, CurLast }; /* cursor */ +#ifdef CONFIG_DWM_URGBORDER +enum { SchemeNorm, SchemeSel, SchemeUrg }; /* color schemes */ +#else enum { SchemeNorm, SchemeSel }; /* color schemes */ +#endif enum { NetSupported, NetWMName, NetWMState, NetWMCheck, NetWMFullscreen, NetActiveWindow, NetWMWindowType, NetWMWindowTypeDialog, NetClientList, NetLast }; /* EWMH atoms */ @@ -2179,6 +2183,15 @@ updatewmhints(Client *c) XSetWMHints(dpy, c->win, wmh); } else c->isurgent = (wmh->flags & XUrgencyHint) ? 1 : 0; + /******************************************************************/ + #ifdef CONFIG_DWM_URGBORDER + if (c->isurgent) + { + //XSetWindowBorder(dpy, c->win, scheme[SchemeUrg].border->pix); + XSetWindowBorder(dpy, c->win, scheme[SchemeUrg][ColBorder].pixel); + } + #endif + /******************************************************************/ if (wmh->flags & InputHint) c->neverfocus = !wmh->input; else -- cgit v1.2.3