Re: Determining XKeysyms
- From: Matthew Garrett <mjg59 srcf ucam org>
- To: Bill Haneman <bill haneman sun com>
- Cc: gnome-accessibility-list gnome org
- Subject: Re: Determining XKeysyms
- Date: Tue, 4 Mar 2003 05:50:21 +0000
On Mon, Mar 03, 2003 at 01:24:49PM +0000, Matthew Garrett wrote:
> That would be great from my point of view, but implementing something
> myself is also an option. I also need to look into the Windows interface
> for this stuff and see what messy details I need to go into there.
For anyone who's interested: Windows provides two mechanisms for this,
the availability of which depends on the version.
1) vkkeyscan will take a character and turn it into the corresponding
virtual-key code *and shift state* for the current keyboard. The
vkkeyscanex version lets you choose any loaded keymap, so I can load a
keymap corresponding to the loaded Dasher alphabet, generate a keycode
and then send it to the application using kbd_event without having to
know anything about the user's keyboard.
2) In Windows 2000 and later, I can use SendInput with a kbdinput
structure. I can simply stuff a UTF8 character into this and magic stuff
that I probably don't want to understand happens.
So, at the moment, it looks significantly easier to do this with Windows
than X. Another application that I looked at that's doing something
similar under X11 is Xstroke, which is an on-screen scribbling input
thing. It seems to use an X keysym lookup defined in its alphabet, but I
didn't check how comprehensive its list of characters was.
--
Matthew Garrett | mjg59 srcf ucam org
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]