[Y-devel] Key mappings
Maurice van der Pot griffon26 at kfk4ever.com
Fri Feb 27 21:05:09 GMT 2004
On Fri, Feb 27, 2004 at 09:42:12PM +0100, Rupert Mazzucco wrote:
> On Fri, 27 Feb 2004, Maurice van der Pot wrote:
>
> > > The question is, how many "special keys" do we think
> > > should be standardised? There is quite a bunch of
> > > non-alphanumeric keys on every modern keyboard, maybe
> > > it would be better to use them for real "standards".
> >
> > I'm not sure what you mean with 'real "standards"', Rupert.
>
> It occurred to me that, while I voted for great flexibility on
> a low level, I really only thought of remapping the alphanumeric
> (and an. modified) keys. There is a set of keys that probably
> should never change their meaning, like modifiers, esc, ctrl,
> function keys, return, backspace, begin/end, pause, print, pg up/down
> etc., because they have a kind of meta-purpose.
No matter the keymap, these keys would always stay the same, so
there is no problem. If someone were to design a keymap that maps
a greek alpha character on F1, that's fine by me. They still have the
choice to map F1 function to another key or just not use it at all.
> > I think that for each type of key there should be a unique
> > identifying value (what is called a KeySym in X).
>
> (But that is only unique if the keymap doesn't change. The
> invariable identifier is the keycode.)
You're right, I misused the word KeySym. What I meant was a value
that is the same for the 'a' on azerty and on qwerty, but different
for the 'alpha' even if the key that produces it is labeled with 'a'.
In any case, the uniqueness I meant was that if a key press causes
an event with this value (say 'alpha') that there can never be a
situation where a key generates the same value but it actually means
'$'.
> > layouts for a moment, I'm pretty sure that if I were able to type
> > fluently on both of them, I'd expect things to be bound to 'a' or
> > 'q' no matter where they may be moved to by a change in keymap.
>
> Yes, but it seems that you are talking about switching keyboards,
> not keymaps.
>
> I was thinking about eg switching from a latin to a greek keymap,
> so that I would have "alpha" where there used to be "a". What I
> suggested was to write then "ctrl+alpha" in the menu where there
> was "ctrl+a" before.
If you want ctrl-a in your latin keymap to do the same as ctrl-alpha
with the greek keymap, that is not a problem. What I am uncertain
about is this:
if you have a key k1 that with latin keymap generates character X and
is bound to the paste action, what would you want to happen if with
the greek keymap k2 produced the same character X?
Would you want the shortcut to be triggered by pressing k2 or k1?
> But obviously I wasn't thinking clearly, because this is nonsense.
> There would still be written "a" on the key, and this is what counts.
> There is, of course, the possibility of a pathological remapping that
> moves the logical "a" to the physical "b" and vice versa. Then
> confusion would be complete. Should probably be forbidden and enforced.
So that means that if pressing 'q' is quit and I change my qwerty keymap
to an azerty one, I suddenly have to press the key that produces an 'a'?
> It seems to me now that the server needs to know, on the lowest level,
> not only the available keycodes, but also what is actually printed on
> the key that corresponds to a certain keycode (or, while we're at it,
> make that a complete physical layout). It would be quite annoying if,
> after much keymap switching, an application for some control purpose
> demanded pressing <some fancy unicode char> that the user can't actually
> find on the board by looking at what's written on the keys!
You will always need to be able to switch keymaps, so I can imagine you
always have to use the same physical key to switch, but that is as far
as I'm willing to go at the moment.
Please try to convince me if you have a different opinion.
Best regards,
Maurice.
More information about the Y-devel mailing list
2026 © www.Y-Windows.Org - All Rights Reserved