qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] VNC key presses not correct


From: Erik Rull
Subject: [Qemu-devel] VNC key presses not correct
Date: Thu, 15 Aug 2013 14:43:31 +0200 (CEST)

Hi all,

I'm struggling with the QEMU VNC on qemu-kvm-1.2.0 a bit, the following two
things are not working properly:

1) Shift key pressed and hold for several seconds causes multiple shift key
press + release events => I would expect getting one press, one or more hold and
one release event (minor issue)
2) German Umlaute and german keyboard layouts are not interpreted properly. I
added some debug output into:

static void do_key_event(VncState *vs, int down, int keycode, int sym)
{
    printf("do_key_event1: %d %d %d\n",down,keycode,sym);

and:

void kbd_put_keycode(int keycode)
{
    if (!runstate_is_running() && !runstate_check(RUN_STATE_SUSPENDED)) {
        return;
    }
    if (qemu_put_kbd_event) {
        printf("kbd_put_keycode: %d\n",keycode);
        qemu_put_kbd_event(qemu_put_kbd_event_opaque, keycode);
    }
}


This reports to me when e.g. pressing "#" on a german keyboard:
do_key_event1: 1 4 35
kbd_put_keycode: 4
do_key_event1: 0 4 35
kbd_put_keycode: 132
=> This results into a "3" on the guest side...

And when I press the "3" on the german keyboard, I get the following events:
do_key_event1: 1 4 51
kbd_put_keycode: 4
do_key_event1: 0 4 51
kbd_put_keycode: 132

=> result is a "3", too...

And when pressing one of the Umlaute (ä), I get a keymap error:

Warning: no scancode found for keysym 228
do_key_event1: 1 0 228
kbd_put_keycode: 0
Warning: no scancode found for keysym 228
do_key_event1: 0 0 228
kbd_put_keycode: 128
do_key_event7: 0 0 228

=> why is 228 not transported to the guest? this is definitvely the correct sign
- according to the table in vnc_keysym.h ...
{ "adiaeresis",           0x0e4},

I tested it with several VNC clients - all with the same results.

Any hints and ideas how to get it running properly would be great.

When I use the same system directly via SDL and a real hardware keyboard, it
works perfect - without changing anything in the qemu configuration even with
different keyboard layouts (I tested US/International, German, French and Spain
keyboards)

Thanks.

Best regards,

Erik



reply via email to

[Prev in Thread] Current Thread [Next in Thread]