summaryrefslogtreecommitdiff
path: root/console.c
AgeCommit message (Collapse)AuthorFilesLines
2009-01-16Fix warningsblueswir11-1/+2
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6346 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-16graphical_console_init change (Stefano Stabellini)aliguori1-18/+42
Patch 5/7 This patch changes the graphical_console_init function to return an allocated DisplayState instead of a QEMUConsole. This patch contains just the graphical_console_init change and few other modifications mainly in console.c and vl.c. It was necessary to move the display frontends (e.g. sdl and vnc) initialization after machine->init in vl.c. This patch does *not* include any required changes to any device, these changes come with the following patches. Patch 6/7 This patch changes the QEMUMachine init functions not to take a DisplayState as an argument because is not needed any more; In few places the graphic hardware initialization function was called only if DisplayState was not NULL, now they are always called. Apart from these cases, the rest are all mechanical substitutions. Patch 7/7 This patch updates the graphic device code to use the new graphical_console_init function. As for the previous patch, in few places graphical_console_init was called only if DisplayState was not NULL, now it is always called. Apart from these cases, the rest are all mechanical substitutions. Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6344 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-15DisplayState interface change (Stefano Stabellini)aliguori1-27/+144
This patch changes the DisplayState interface adding support for multiple frontends at the same time (sdl and vnc) and implements most of the benefit of the shared_buf patch without the added complexity. Currently DisplayState is managed by sdl (or vnc) and sdl (or vnc) is also responsible for allocating the data and setting the depth. Vga.c (or another backend) will do any necessary conversion. The idea is to change it so that is vga.c (or another backend) together with console.c that fully manage the DisplayState interface allocating data and setting the depth (either 16 or 32 bit, if the guest uses a different resolution or is in text mode, vga.c (or another backend) is in charge of doing the conversion seamlessly). The other idea is that DisplayState supports *multiple* frontends like sdl and vnc; each of them can register some callbacks to be called when a display event occurs. The interesting changes are: - the new structures and related functions in console.h and console.c in particular the following functions are very helpful to manage a DisplaySurface: qemu_create_displaysurface qemu_resize_displaysurface qemu_create_displaysurface_from qemu_free_displaysurface - console_select and qemu_console_resize in console.c this two functions manage multiple consoles on a single host display - moving code around in hw/vga.c as for the shared_buf patch this is necessary to be able to handle a dynamic DisplaySurface bpp - changes to vga_draw_graphic in hw/vga.c this is the place where the DisplaySurface buffer is shared with the videoram, when possible; Compared to the last version the only changes are: - do not remove support to dpy_copy in cirrus_vga - change the name of the displaysurface handling functions Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6336 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-24Introduce accessors for DisplayState (Stefano Stabellini)aliguori1-37/+37
Introducing some accessors: ds_get_linesize ds_get_bits_per_pixel ds_get_width ds_get_height ds_get_data Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5789 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-24Reintroduce TEXT_CONSOLE_FIXED_SIZE and TEXT_CONSOLE for resizable vc's.balrog1-7/+20
This partially reverts r4812 to fix an issue highlighted by Ryan Harper with all vc's being fixed size which prevented backends with resizable window (curses) from displaying okay. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5309 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-24Don't use ds->dpy_copy directly from hw/ (Jan Niehusmann).balrog1-0/+13
I left a TODO in the code because this still doesn't definitely fix all issues. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5308 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-02Fix typo in console.c commentaurel321-1/+1
Signed-off-by: Ryan Harper <ryanh@us.ibm.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5129 c046a42c-6fe2-441c-8c8c-71466251a162
2008-07-19Force screen resize if no buffer set (Avi Kivity).balrog1-1/+2
This is a hack to get screen_dump to work, we should start using a global screen_dump method. Signed-off-by: Avi Kivity <avi@qumranet.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4903 c046a42c-6fe2-441c-8c8c-71466251a162
2008-07-19Pretend to be the active console while a screendump takes place (Avi Kivity).balrog1-1/+6
Signed-off-by: Avi Kivity <avi@qumranet.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4901 c046a42c-6fe2-441c-8c8c-71466251a162
2008-07-01Implement resolution switching in common console code.pbrook1-15/+20
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4812 c046a42c-6fe2-441c-8c8c-71466251a162
2008-02-10Add an ncurses UI.balrog1-16/+97
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3976 c046a42c-6fe2-441c-8c8c-71466251a162
2007-11-18Add statics and missing #includes for prototypes.pbrook1-2/+2
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3683 c046a42c-6fe2-441c-8c8c-71466251a162
2007-11-17Break up vl.h.pbrook1-1/+3
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3674 c046a42c-6fe2-441c-8c8c-71466251a162
2007-10-30Miscellaneous VNC related fixes from Xen forwarded by Matthew Kent.balrog1-8/+13
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3489 c046a42c-6fe2-441c-8c8c-71466251a162
2007-09-17find -type f | xargs sed -i 's/[\t ]*$//g' # Yes, again. Note the star in ↵ths1-4/+4
the regex. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3177 c046a42c-6fe2-441c-8c8c-71466251a162
2007-09-16find -type f | xargs sed -i 's/[\t ]$//g' # on most filesths1-28/+28
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3173 c046a42c-6fe2-441c-8c8c-71466251a162
2007-07-11New features for QEMU text console, by Stefan Weil.ths1-15/+46
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3068 c046a42c-6fe2-441c-8c8c-71466251a162
2007-02-10Serial console improvements, by Stefan Weil.ths1-13/+12
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2412 c046a42c-6fe2-441c-8c8c-71466251a162
2007-01-27Rearrange char event handlers to fix CHR_EVENT_RESET.pbrook1-18/+5
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2361 c046a42c-6fe2-441c-8c8c-71466251a162
2007-01-16Improved console handling, thanks Stefan Weil.ths1-18/+155
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2322 c046a42c-6fe2-441c-8c8c-71466251a162
2007-01-05Reinitialize monitor upon reconnect, by Anthony Liguori.ths1-0/+2
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2300 c046a42c-6fe2-441c-8c8c-71466251a162
2006-07-14fixed LF interpretationbellard1-2/+4
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2054 c046a42c-6fe2-441c-8c8c-71466251a162
2006-06-25avoid name conflictsbellard1-18/+18
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2015 c046a42c-6fe2-441c-8c8c-71466251a162
2006-06-25send correctly long key sequences on slow terminals - fixes backspace handlingbellard1-24/+104
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2012 c046a42c-6fe2-441c-8c8c-71466251a162
2006-04-09Allow multiple graphics devices.pbrook1-9/+66
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1803 c046a42c-6fe2-441c-8c8c-71466251a162
2006-03-11Improved terminal emulation (Piotr Esden-Tempski).pbrook1-48/+268
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1773 c046a42c-6fe2-441c-8c8c-71466251a162
2004-10-09monitor fixes (Johannes Schindelin)bellard1-1/+4
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1109 c046a42c-6fe2-441c-8c8c-71466251a162
2004-08-01console focus supportbellard1-0/+17
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1032 c046a42c-6fe2-441c-8c8c-71466251a162
2004-07-14virtual consolebellard1-0/+711
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1024 c046a42c-6fe2-441c-8c8c-71466251a162