From: Daniel Liu Date: Thu, 10 Sep 2020 21:12:59 +0000 (-0400) Subject: applied border X-Git-Url: https://git.danieliu.xyz/?a=commitdiff_plain;h=e900a283a94108a153e3136f50e2e838a99b900f;p=dmenu.git applied border --- diff --git a/config.def.h b/config.def.h index e578368..35adb50 100644 --- a/config.def.h +++ b/config.def.h @@ -23,3 +23,6 @@ static unsigned int lines = 20; * for example: " /?\"&[]" */ static const char worddelimiters[] = " "; + +/* Size of the window border */ +static const unsigned int border_width = 5; diff --git a/dmenu.c b/dmenu.c index 8862150..3f8f689 100644 --- a/dmenu.c +++ b/dmenu.c @@ -692,9 +692,10 @@ setup(void) swa.override_redirect = True; swa.background_pixel = scheme[SchemeNorm][ColBg].pixel; swa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask; - win = XCreateWindow(dpy, parentwin, x, y, mw, mh, 0, + win = XCreateWindow(dpy, parentwin, x, y, mw, mh, border_width, CopyFromParent, CopyFromParent, CopyFromParent, CWOverrideRedirect | CWBackPixel | CWEventMask, &swa); ++ XSetWindowBorder(dpy, win, scheme[SchemeSel][ColBg].pixel); XSetClassHint(dpy, win, &ch);