On Sat, 27 Nov 2004, Hans-Christoph Steiner wrote:
How then can you detect a key being held down in X? I mean it would be possible by tracking the auto-repeated values, but that seems needlessly complicated.
There is a way to turn off autorepeat for all keys (xset r off) or on a key-by-key basis (eg: xset -r 42)
But that is a global setting for the xserver, it's not on a window-per-window basis.
The only way to make it local is to register for Enter/Leave events and change the key settings every time and keep a backup of the default settings.
This is AFAIK. I've read the X11 spec a few years ago; I may have forgotten some segments of it.
_____________________________________________________________________ Mathieu Bouchard -=- Montréal QC Canada -=- http://artengine.ca/matju