commit 368fcd3628b5ece2b6b9a970e4e9d77739d0385a
parent bdde9a8809682fc77616202b68304306310f0e78
Author: grouse <bdmfegys@duck.com>
Date: Mon, 27 Nov 2023 03:13:33 -0500
patched border patch successfully
Diffstat:
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/config.def.h b/config.def.h
@@ -33,3 +33,6 @@ static unsigned int lines = 10;
* for example: " /?\"&[]"
*/
static const char worddelimiters[] = " ";
+
+/* Size of the window border */
+static unsigned int border_width = 0;
diff --git a/dmenu.c b/dmenu.c
@@ -876,9 +876,11 @@ setup(void)
swa.colormap = cmap;
swa.event_mask = ExposureMask | KeyPressMask | VisibilityChangeMask |
ButtonPressMask;
- win = XCreateWindow(dpy, parentwin, x, y, mw, mh, 0,
+ win = XCreateWindow(dpy, parentwin, x, y, mw, mh, border_width,
depth, InputOutput, visual,
CWOverrideRedirect | CWBackPixel | CWColormap | CWEventMask | CWBorderPixel, &swa);
+ if (border_width)
+ XSetWindowBorder(dpy, win, scheme[SchemeSel][ColBg].pixel);
XSetClassHint(dpy, win, &ch);
@@ -982,6 +984,8 @@ main(int argc, char *argv[])
colors[SchemeSel][ColFg] = argv[++i];
else if (!strcmp(argv[i], "-w")) /* embedding window id */
embed = argv[++i];
+ else if (!strcmp(argv[i], "-bw"))
+ border_width = atoi(argv[++i]); /* border width */
else
usage();