From 5c440dfd8cc26f9777896857ee8ff926e34221ea Mon Sep 17 00:00:00 2001 From: Anthony Debucquoy Date: Wed, 12 Apr 2023 15:18:17 +0200 Subject: [PATCH] bar height --- config.def.h | 2 ++ dmenu.c | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/config.def.h b/config.def.h index 697d511..f41c899 100644 --- a/config.def.h +++ b/config.def.h @@ -4,6 +4,8 @@ static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */ static const unsigned int alpha = 0xf0; /* -fn option overrides fonts[0]; default X11 font or font set */ +static const int user_bt = 0; /* add an defined amount of pixels to the bar height */ + static const char *fonts[] = { "monospace:size=10" }; diff --git a/dmenu.c b/dmenu.c index fd84a91..47b0d25 100644 --- a/dmenu.c +++ b/dmenu.c @@ -643,7 +643,8 @@ setup(void) utf8 = XInternAtom(dpy, "UTF8_STRING", False); /* calculate menu geometry */ - bh = drw->fonts->h + 2; + bh = drw->fonts->h; + bh = user_bh ? bh + user_bh : bh + 2; lines = MAX(lines, 0); mh = (lines + 1) * bh; #ifdef XINERAMA