Add border patch

This commit is contained in:
Marco Thomas
2021-03-23 17:56:29 +01:00
parent b6c3c05cb7
commit 7ae769178d
4 changed files with 9 additions and 3 deletions

5
README
View File

@@ -4,8 +4,9 @@ dmenu is an efficient dynamic menu for X.
Patches
-------
+ Case insensitive
+ Center
+ case insensitive
+ center
+ border (manually)
Requirements
------------

View File

@@ -21,3 +21,5 @@ static unsigned int lines = 0;
* for example: " /?\"&[]"
*/
static const char worddelimiters[] = " ";
static const unsigned int border_width = 5;

View File

@@ -22,3 +22,5 @@ static unsigned int lines = 6;
* for example: " /?\"&[]"
*/
static const char worddelimiters[] = " ";
static const unsigned int border_width = 3;

View File

@@ -669,9 +669,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);