dmenu: update to 4.9.

This commit is contained in:
Doan Tran Cong Danh 2019-02-04 07:04:29 +07:00 committed by maxice8
parent a86f6dd2f9
commit db9c144a3f
2 changed files with 11 additions and 20 deletions

View File

@ -1,14 +1,8 @@
From 34e4ada60c7ca73cfdd83a02c7416af39dfc0dc0 Mon Sep 17 00:00:00 2001
From: Andrea Brancaleoni <miwaxe@gmail.com>
Date: Tue, 10 Nov 2015 19:29:45 +0100
Subject: [PATCH] fuzzymatch-4.6
---
dmenu.c | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
1 file changed, 85 insertions(+), 4 deletions(-)
diff --git a/dmenu.c b/dmenu.c
index a07f8e3..c26ecfc 100644
index 6b8f51b..4221233 100644
--- a/dmenu.c
+++ b/dmenu.c
@@ -32,6 +32,7 @@ struct item {
@ -19,7 +13,7 @@ index a07f8e3..c26ecfc 100644
};
static char text[BUFSIZ] = "";
@@ -253,6 +254,86 @@ match(void)
@@ -264,6 +265,86 @@ match(void)
calcoffsets();
}
@ -106,7 +100,7 @@ index a07f8e3..c26ecfc 100644
static void
insert(const char *str, ssize_t n)
{
@@ -263,7 +344,7 @@ insert(const char *str, ssize_t n)
@@ -274,7 +355,7 @@ insert(const char *str, ssize_t n)
if (n > 0)
memcpy(&text[cursor], str, n);
cursor += n;
@ -115,7 +109,7 @@ index a07f8e3..c26ecfc 100644
}
static size_t
@@ -308,7 +389,7 @@ keypress(XKeyEvent *ev)
@@ -343,7 +424,7 @@ keypress(XKeyEvent *ev)
case XK_k: /* delete right */
text[cursor] = '\0';
@ -124,7 +118,7 @@ index a07f8e3..c26ecfc 100644
break;
case XK_u: /* delete left */
insert(NULL, 0 - cursor);
@@ -442,7 +523,7 @@ keypress(XKeyEvent *ev)
@@ -492,7 +573,7 @@ insert:
strncpy(text, sel->text, sizeof text - 1);
text[sizeof text - 1] = '\0';
cursor = strlen(text);
@ -132,16 +126,13 @@ index a07f8e3..c26ecfc 100644
+ fuzzymatch();
break;
}
drawmenu();
@@ -584,7 +665,7 @@ setup(void)
@@ -648,7 +729,7 @@ setup(void)
}
promptw = (prompt && *prompt) ? TEXTW(prompt) : 0;
promptw = (prompt && *prompt) ? TEXTW(prompt) - lrpad / 4 : 0;
inputw = MIN(inputw, mw/3);
- match();
+ fuzzymatch();
/* create menu window */
swa.override_redirect = True;
--
2.6.3

View File

@ -1,14 +1,14 @@
# Template file for 'dmenu'
pkgname=dmenu
version=4.8
version=4.9
revision=1
makedepends="libXinerama-devel libXft-devel freetype-devel"
short_desc="A generic menu for X"
short_desc="Generic menu for X"
maintainer="Juan RP <xtraeme@voidlinux.org>"
license="MIT"
homepage="https://tools.suckless.org/dmenu/"
distfiles="https://dl.suckless.org/tools/${pkgname}-${version}.tar.gz"
checksum=fe615a5c3607061e2106700862e82ac62a9fa1e6a7ac3d616a9c76106476db61
checksum=b3971f4f354476a37b2afb498693649009b201550b0c7c88e866af8132b64945
build_options="fuzzymatch"
desc_option_fuzzymatch="Enable Fuzzymatch support"