Multiple Key Repeat
ran234 at gmail.com
Thu Apr 23 08:51:02 PDT 2015
On Sat, Apr 04, 2015 at 03:17:29AM +0200, Vasil Zlatanov wrote:
> Currently when you hold down two keys at the same time on the keyboard,
> say for instance 'g' and '0' only the second key is repeated, producing
> g000.. or 0ggg... On Microsoft Windows (given the right keyboard) if you
> press 'g' and '0' at the same time it produces g0g0g0g0.. repeating both
> keys at the same time.
That's interesting - I never thought to do it this way. I tried it on a
windows machine but couldn't reproduce the behavior; probably the
keyboard saved a few bucks on the required wiring. Out of interest, can
you send an evemu recording of a g0g0-like session, to see how it looks
like on the evdev side?
> a key. On windows one is capable of rapidly alternating two abilties
> while this isn't possible for the same game running under X11.
> Can the g0g0g0g0 behaviour of repeating both keys be achieved?
Not formally, the simple single-key repeat behavior is well ingrained in
both the XKB protocol and server-side implementation (i.e. there's a
single repeat timer and a single repeatKey per device).
You might be able to achieve that client-side by setting
DetectableAutoRepeat, ignoring the server repeats and rolling your
own with a timer. I'm not sure how much of a good idea that is though.
On Wayland, key repeat is left entirely to the client, with just
rate/delay sent by the server, and the behavior is not specified. I
don't think this was intentional btw - just no one considered the
multiple-key repeat option. So there you are free to do as you wish. But
most toolkits implement the simple behavior AFAIK.
More information about the xorg-devel