Re: [hackers] [dmenu][PATCH] fix a bug introduced by e2a2805 that that ignores composed characters

From: Quentin Rameau <quinq_AT_fifth.space>
Date: Thu, 15 Mar 2018 16:59:33 +0100

> XmbLookupString may not return a keysym, but only a string for
> composed characters.

Ah, could you provide a test-case for this?

> ---
> dmenu.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/dmenu.c b/dmenu.c
> index 5e9c367..3a3f8e4 100644
> --- a/dmenu.c
> +++ b/dmenu.c
> _AT_@ -387,12 +387,11 @@ keypress(XKeyEvent *ev)
> return;
> }
> switch(ksym) {
> + case NoSymbol:
> default:
> if (!iscntrl(*buf))
> insert(buf, len);
> break;
> - case NoSymbol:
> - break;
> case XK_Delete:
> if (text[cursor] == '\0')
> return;

This may solve the introduced regression, but introduces a new bug.
Received on Thu Mar 15 2018 - 16:59:33 CET

This archive was generated by hypermail 2.3.0 : Thu Mar 15 2018 - 17:00:28 CET