qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] Controlling SDL2 output with Ctrl+Alt+*


From: Gerd Hoffmann
Subject: Re: [Qemu-devel] Controlling SDL2 output with Ctrl+Alt+*
Date: Tue, 22 Apr 2014 10:14:59 +0200

On Mo, 2014-04-21 at 18:14 -0400, Cole Robinson wrote:
> On 04/18/2014 02:28 PM, Michael Tokarev wrote:
> > SDL2 display apparently does not work with standard keyboard
> > shortcuts documented in the qemu manpage.  In particular,
> > Ctrl+Alt+(123) does not switch between monitor, serial and
> > guest graphical conslole,
> 
> Certainly seems intentional: notice the lack of qemu_console_is_graphic checks
> in sdl2.c compared to sdl.c. My guess is Dave just ripped it all out since it
> was tangential to the original goal of facilitating some virtio graphics 
> magic.

Yep, was intentionally ripped out.

When bringing it back we certainly wouldn't do it the sdl1 way as the
input api got a overhaul in sld2.

Big question is (a) whenever bring it back, and (b) how to do it.

On (a): I personally almost never use the qemu terminals.  When running
qemu directly I usually use "-monitor stdio" or "-serial stdio" instead,
so chardev goes to my normal xterm, which works better than the qemu
terminal emulation.  When using qemu via libvirt it's moot anyway.  So,
is there a strong need for it in the first place?

On (b): Swapping window content becomes pretty messy with multihead
support.  And as SDL2 has support for multiple windows anyway I think it
would be easier to just create a new window per vc.  Ctrl-Alt-123
hotkeys could simply show/hide the windows.

Comments?

> Ctrl+Alt+[-+] does not grow/shrink
> > guest window and so on.
> 
> There was some attempt to wire this up, sdl2.c:487. If I do
> s/SDL_SCANCODE_KP/SDL_SCANCODE/g it will make the keyboard shortcuts actually
> trigger the zoom code, but it still doesn't seem to work.

Need to look at it.  Patches are welcome of course.

cheers,
  Gerd





reply via email to

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