mirror of
https://gitlab.freedesktop.org/xorg/lib/libx11.git
synced 2026-05-07 08:38:04 +02:00
XKBCvt: remove an if that never gets triggered
The 'if' at the beginning of _XkbHandleSpecialSym() allows only symbols from the numeric keypad and some control symbols to pass -- XK_hyphen is not among them, so the check for XK_hyphen in the later 'if' will always be false. (The corresponding conversion in _XTranslateKeySym() in KeyBind.c was removed in March 1994.) (Also, several keyboard layouts nowadays contain the 'hyphen' symbol, allowing the user to enter soft hyphens into a document. So we really don't want to remap this symbol.) Fixes issue #48. Reported-by: Bhavi Dhingra Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
This commit is contained in:
parent
6786744f63
commit
fbbc3cf8b8
1 changed files with 0 additions and 2 deletions
|
|
@ -75,8 +75,6 @@ _XkbHandleSpecialSym(KeySym keysym, char *buffer, int nbytes, int *extra_rtrn)
|
|||
/* if X keysym, convert to ascii by grabbing low 7 bits */
|
||||
if (keysym == XK_KP_Space)
|
||||
buffer[0] = XK_space & 0x7F; /* patch encoding botch */
|
||||
else if (keysym == XK_hyphen)
|
||||
buffer[0] = (char) (XK_minus & 0xFF); /* map to equiv character */
|
||||
else
|
||||
buffer[0] = (char) (keysym & 0x7F);
|
||||
return 1;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue