diff options
author | Ping Cheng <pinglinux@gmail.com> | 2016-08-05 18:27:55 -0700 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2016-08-08 10:06:24 +1000 |
commit | 97d86e150c23108b4dbc99dbb8338aec60eea39c (patch) | |
tree | 273aaa6beb9cde8f3768f70bbd41d72e0369581b | |
parent | d54db63e716317bb336ddf444ab8034353913db7 (diff) | |
download | xf86-input-wacom-97d86e150c23108b4dbc99dbb8338aec60eea39c.tar.gz |
xsetwacom: refer KeySyms defined by keysymdef.h in man page
xsetwacom accepts keys in X11 KeySyms format. To make the interface
user friendly, we mapped a set of modifiers to aliases that can be
recognized by most users. But, there are a few less recognizable or
confusing keys/modifiers left. This patch tells users where to find
the X11 KeySyms they are looking for.
Signed-off-by: Ping Cheng <pingc@wacom.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r-- | man/xsetwacom.man | 15 | ||||
-rw-r--r-- | tools/xsetwacom.c | 3 |
2 files changed, 14 insertions, 4 deletions
diff --git a/man/xsetwacom.man b/man/xsetwacom.man index 1930d67..234e9ba 100644 --- a/man/xsetwacom.man +++ b/man/xsetwacom.man @@ -109,7 +109,7 @@ button-number will produce a press of X11 button 3 (i.e. right click). Action mappings allow button presses to perform many events. They take the form of a string of keywords and arguments. -The "key" keyword is following by a list of key names. These can optionally +The "key" keyword is followed by a list of key names. These can optionally be preceded by "+" for press and "-" for release. If +/- is not given, press-and-release is assumed, except for modifier keys which are left pressed. Key names can be X11 KeySyms or some aliases such as 'shift' or 'f1' (the @@ -117,9 +117,16 @@ full list can be seen with the .B list modifiers command). -For example, "key +a +shift b -shift -a" converts the button into a series of -keystrokes, in this example "press a, press shift, press and release b, -release shift, release a". +To assign a key that is not in the modifiers list, use the KeySym in +/usr/include/X11/keysymdef.h with the XK_ prefix removed or its actual value +as is. For example, XK_BackSpace should be specified as "BackSpace". "0xff80" +can also be used to replace "BackSpace" since it's the unique KeySym value of +Backspace key. + +Here is a combined example: "key +a shift b shift -a 0xff0d" converts the +button into a series of keystrokes. In this example, "press a, press shift, +press and release b, release shift, release a, then press and release enter". +"key +a +shift b -shift -a 0xff0d" does the same thing. The "button" keyword is similar except that its arguments are X11 button numbers. diff --git a/tools/xsetwacom.c b/tools/xsetwacom.c index f5291ee..bbc92f1 100644 --- a/tools/xsetwacom.c +++ b/tools/xsetwacom.c @@ -939,6 +939,9 @@ static void list_mod(Display *dpy) m = specialkeys; while(m->name) printf(" %s\n", m++->name); + + printf("Keys not listed above can be specified via their KeySyms." + " See the man page for details.\n"); } static void list(Display *dpy, int argc, char **argv) |