From 8e3e7bb774beac484c3c74b9f46597a5debad219 Mon Sep 17 00:00:00 2001 From: Ran Benita Date: Tue, 3 Feb 2015 13:23:50 -0500 Subject: compose: fix the description of modifiers in compose sequences The Compose format has a feature which allows specifying certain modifiers must (or must not) be present with a given keysym in the sequence. The grammar in imLcPrs.c and the Compose man page both do not match what the code actually does (see the handling of the variables `modifier_mask` and `modifier` in parseline() in imLcPrs.c, which are eventually matched as `ev->state & modifier_mask == modifier`). Also explicitly list the accepted modifier names, since they are not standard (e.g. "Ctrl" instead of "Control"). Signed-off-by: Ran Benita Signed-off-by: James Cloos Backported-to-NX-by: Ulrich Sibiller --- nx-X11/lib/X11/imLcPrs.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'nx-X11/lib') diff --git a/nx-X11/lib/X11/imLcPrs.c b/nx-X11/lib/X11/imLcPrs.c index afc947468..7528d838f 100644 --- a/nx-X11/lib/X11/imLcPrs.c +++ b/nx-X11/lib/X11/imLcPrs.c @@ -68,8 +68,9 @@ static void parsestringfile(FILE *fp, Xim im, int depth); * COMMENT ::= "#" {} * LHS ::= EVENT { EVENT } * EVENT ::= [MODIFIER_LIST] "<" keysym ">" - * MODIFIER_LIST ::= ("!" {MODIFIER} ) | "None" - * MODIFIER ::= ["~"] modifier_name + * MODIFIER_LIST ::= (["!"] {MODIFIER} ) | "None" + * MODIFIER ::= ["~"] MODIFIER_NAME + * MODIFIER_NAME ::= ("Ctrl"|"Lock"|"Caps"|"Shift"|"Alt"|"Meta") * RHS ::= ( STRING | keysym | STRING keysym ) * STRING ::= '"' { CHAR } '"' * CHAR ::= GRAPHIC_CHAR | ESCAPED_CHAR -- cgit v1.2.3