[Y-devel] Logical input devices
Bryce Nichols bryce at bnichols.org
Sun Feb 29 00:59:01 GMT 2004
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Great ideas for input devices. Read my responses to specific points
below.
On Sat, 28 Feb 2004, Mikko Rantalainen wrote:
> Logical input device should be able to provide value of every axis
> *and* granularity of that axis *and* information if the axis is
> relative (like mouse movement, no limits) or absolute (like joystick
> movement, physical movement +/- 45 degrees). This allows us to be
> forward compatible with future keyboards where every button is
> "analog" or keyboards with sliders and/or wheels. Plus, the output
> API will be truly abstract as every input event looks the same. Why
> mess with "buttons" and "wheels" when it really doesn't matter.
Yes, excellent idea. The hard part is deciding on a standard for
representation of the logical devices as well as the format for events.
> On top of this logical device (which some applications, like games,
> would use directly) would reside the logical character input driver
> which would constantly get events from logical device and output
> characters. This layer would be pretty similar to keymap, but it
> could do a bit more. For example, somebody said that X cannot handle
> keyboard shortcuts in case the character map is modified because
> those keyboard shortcuts are designed for some special keyboard
> layout. Character input driver of Y should be allowed to generate
> multiple "characters" for a single keypress. If somebody has
> remapped the keyboard to give "compose+non-breaking-space" charcter
> for some combination of keypresses, this layer should be able to
> output Ctrl+Shift+AltGr+Y in addition to that special character
> above, which only a few selected applications could handle.
> Applications could then decide to read character input or handle key
> combination instead.
See my previous e-mail to the list for a discussion of a possible way to
handle mapping key sequences.
> Some things to consider:
> 1) which level should handle repeating of characters when the key
> has been pressed for some time?
This is somewhat complicated, so we should think carefully about how to
make this work in a clean, consistent manner. The general appoach, I
think, should be that after the initial delay, while a key that triggered
a "key typed" event is still depressed, repeat "key typed" events will be
sent until the key is released or some modifier changes.
> 2) I think we should allow any key to work as a modificator (instead
> of simply Ctrl, Alt, AltGr, Shift, Meta, Super, Hyper). However,
> current keyboards give output of "a" and "b" in case of the
> following key sequence: "a down", "b down", "b up", "a up". Should
> Y's logical character driver generate characters "a","b","a+b" or
> "a","a+b","b" (I think it should be the latter). Does it matter?
We may want to make the behavior for this sort of thing configurable.
> 3) How should the characters be outputted from the driver. If we
> allow any key combination, we cannot output a character with a full
> mod key bitmap like X does. Perhaps an array of all currently
> pressed keys?
Yes, send the set of modifiers currently in effect.
> 4) Should the user be able to customize behavior of logical input
> device (emulation of different key emulations). Probably yes? If so,
> should the customization have some kind of API or should this be
> driver dependant? The same issue needs to be decided for the
> character input driver too.
>
Yes, an API and supporting tools would be crucial for it to be usable.
> --
> Mikko
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
Comment: For info see https://quantumlab.net/pine_privacy_guard/
iD8DBQFAQTlWIT7jkoqrwXkRAkAaAJ9Jpgyo08+qkIFzW7ThxbmrmRwH/QCgi48P
QdDrWBKfUZjUlIGUlmzsVX0=
=jjmp
-----END PGP SIGNATURE-----
More information about the Y-devel mailing list
2026 © www.Y-Windows.Org - All Rights Reserved