summaryrefslogtreecommitdiff
path: root/test/keyseq.c
diff options
context:
space:
mode:
authorDavid Herrmann <dh.herrmann@googlemail.com>2012-10-16 16:05:34 +0200
committerRan Benita <ran234@gmail.com>2012-10-16 21:29:09 +0200
commit7b3bd11f92f0bed76f25eab8c79c0eca21e037bc (patch)
tree006662df88956808da70985418e1e0f8025a298a /test/keyseq.c
parent5fff637e07d75b24f778210e7838ee9667810806 (diff)
Add xkb_keysym_from_name() flags argument for case-insensitive search
This adds a flags argument to xkb_keysym_from_name() so we can perform a case-insensitive search. This should really be supported as many keysyms have really weird capitalization-rules. However, as this may produce conflicts, users must be warned to only use this for fallback paths or error-recovery. This is also the reason why the internal XKB parsers still use the case-sensitive search. This also adds some test-cases so the expected results are really produced. The binary-size does _not_ change with this patch. However, case-sensitive search may be slightly slower with this patch. But this is barely measurable. [ran: use bool instead of int for icase, add a recommendation to the doc, and test a couple "thorny" cases.] Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Diffstat (limited to 'test/keyseq.c')
-rw-r--r--test/keyseq.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/keyseq.c b/test/keyseq.c
index d5993ec..cb53739 100644
--- a/test/keyseq.c
+++ b/test/keyseq.c
@@ -305,7 +305,7 @@ main(void)
KEY_RIGHTSHIFT, UP, XKB_KEY_Shift_R, NEXT,
KEY_V, BOTH, XKB_KEY_Cyrillic_ZHE, FINISH));
-#define KS(name) xkb_keysym_from_name(name)
+#define KS(name) xkb_keysym_from_name(name, 0)
/* Test that levels (1-5) in de(neo) symbols map work. */
assert(test_key_seq(keymap,