XInput2 does not repeat keystrokes for held-down keys
Over on https://bugs.debian.org/1004946, Jamie Zawinski describes moving XScreenSaver to XInput2 for better privilege separation, but then losing the ability to get automatic keystroke repeats when a key is held down.
This causes pretty surprising and unfriendly behavior in the XScreenSaver unlock screen, where it's now impossible for the user to hold down the backspace key to clear the password input field.
(i noticed this because this is a common use pattern for me, but i'm sure i'm not the only one)
Zawinski writes:
When an X11 client reads X11-core events of type KeyPress and KeyRelease, a held-down key will result in a series of synthetic release/press events to make it look like the key was pressed multiple times. The initial delay and repeat rate are configured in the X server by xset and/or xkbset. Also, not all keys auto-repeat.
When that same X11 client reads XInput2-extension events of type XI_RawKeyPress and XI_RawKeyRelease, a held-and-released key results in exactly 2 events, no matter how long it was held. The XInput2 server extension ignores the server auto-repeat settings.
It is unreasonable to expect an X11 client to hack auto-repeat by itself. This is a server-side configuration issue.