Re: key themes (cont.)



>> So as you can see, keysyms still correspond to a relatively
>> low-level operation: that of pressing a key.  As far as I can tell
>> there is no way to tell X to map a sequence of keycodes onto a
>> keysym (unless the keycodes include modifier keys, like shift);
>> this means that Emacs keybindings could never be emulated at this
>> level.

Joel> A given keycode can be given an arbitrary sequence of (I think)
Joel> ascii characters; there's stuff in the O'Reilly Xlib book which
Joel> mentions using this to bind strings to function keys.

Yes, you can do this (except you assign the string to a keysym, not a
keycode).  But it doesn't help us.

This functionality is used so that you can assign an ASCII translation
to a given keysym, so that, e.g., the user could have some function
key insert a whole string.

Using this to assign some kind of logical name to each key would
probably result in disaster, since it would be an abuse of this
feature.  E.g., an existing client might assume that any keysym with
an ASCII representation is not a "control key", so if we assigned a
"binding" in this way to control-a, then whatever other meaning that
might have would go away.  Does this make sense?

Also, this doesn't address the problem of Emacs keybindings, which
require multi-key sequences.

This functionality has to be done in the client.  If you still don't
believe me, you're welcome to try to implement it...

Tom



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]