From: "Jim C. Brown" <jma5@umd.edu>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] Re: [PATCH] Fix virtual console switching with SDL on Mac OS X
Date: Sat, 23 Jul 2005 14:46:22 -0400 [thread overview]
Message-ID: <20050723184622.GA15598@jbrown.mylinuxbox.org> (raw)
In-Reply-To: <dbtdv4$fva$1@sea.gmane.org>
On Sat, Jul 23, 2005 at 02:42:12PM +0200, Christian Walther wrote:
> >Looks like the bug affects X11 and W32 as well, if you are not using a
> >US keymap.
>
Oops, I meant only X11, as W32 doesnt use qemu's keymaps. Only the X11 SDL
driver, and the not-yet-committed X11 GTK driver, use it.
> I don't think so. The non-keymap code that was used before my patch
> (sdl_keyevent_to_keycode()) uses event.key.keysym.scancode, which is
> platform-dependent, but refers to the location of the keys, not their
> value under the current keyboard mapping (apparently X keycodes on X11,
> PC keycodes on Windows, ADB keycodes on Mac OS).
Well, the X keycodes returned actually do change depending on what kind of
hardware keyboard you are using.
But if eveyone was running SDL under X11 with PC keyboards, then it is possible
that no one would have noticed. I'll have to investigate how keycodes and X11
keysyms are handled further.
> The with-keymap code
> (sdl_keyevent_to_keycode_generic()) on the other hand uses
> event.key.keysym.sym (one of the SDLK_xxx constants), which is affected
> by the OS's keyboard mapping.
Which is converted back into a raw X11 keycode, based on the given keymap
file passed via "-k keymap".
So for the bug to not affect X11, the keycode in the keymap file and the
keycode returned by SDL would have to be the same, or at least map to the
same character. Curious.
--
Infinite complexity begets infinite beauty.
Infinite precision begets infinite perfection.
prev parent reply other threads:[~2005-07-23 19:02 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-22 21:24 [Qemu-devel] [PATCH] Fix virtual console switching with SDL on Mac OS X Christian Walther
2005-07-22 22:40 ` Jim C. Brown
2005-07-23 12:42 ` [Qemu-devel] " Christian Walther
2005-07-23 18:46 ` Jim C. Brown [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050723184622.GA15598@jbrown.mylinuxbox.org \
--to=jma5@umd.edu \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).