From 55ff6a17cd124806e30f27f5da7c5e976f6925e8 Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Fri, 22 Apr 2022 09:50:45 +0430 Subject: initial commit --- dmenu-numbers-4.9.diff | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 dmenu-numbers-4.9.diff (limited to 'dmenu-numbers-4.9.diff') diff --git a/dmenu-numbers-4.9.diff b/dmenu-numbers-4.9.diff new file mode 100644 index 0000000..969e54f --- /dev/null +++ b/dmenu-numbers-4.9.diff @@ -0,0 +1,34 @@ +From 61abc60dbfaa8ec63fcd176307308aee88a19e32 Mon Sep 17 00:00:00 2001 +From: Miles Alan +Date: Sat, 10 Aug 2019 17:20:08 -0500 +Subject: [PATCH] Display number of matched and total items in top right corner + +--- + dmenu.c | 25 +++++++++++++++++++++++-- + 1 file changed, 23 insertions(+), 2 deletions(-) + +diff --git a/dmenu.c b/dmenu.c +index 6b8f51b..98c5810 100644 +--- a/dmenu.c ++++ b/dmenu.c +@@ -165,13 +184,15 @@ drawmenu(void) + } + x += w; + for (item = curr; item != next; item = item->right) +- x = drawitem(item, x, 0, MIN(TEXTW(item->text), mw - x - TEXTW(">"))); ++ x = drawitem(item, x, 0, MIN(TEXTW(item->text), mw - x - TEXTW(">") - TEXTW(numbers))); + if (next) { + w = TEXTW(">"); + drw_setscheme(drw, scheme[SchemeNorm]); +- drw_text(drw, mw - w, 0, w, bh, lrpad / 2, ">", 0); ++ drw_text(drw, mw - w - TEXTW(numbers), 0, w, bh, lrpad / 2, ">", 0); + } + } ++ drw_setscheme(drw, scheme[SchemeNorm]); ++ drw_text(drw, mw - TEXTW(numbers), 0, TEXTW(numbers), bh, lrpad / 2, numbers, 0); + drw_map(drw, win, 0, 0, mw, mh); + } + +-- +2.19.2 + -- cgit v1.2.3