From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JqQNK-0000eb-3B for qemu-devel@nongnu.org; Mon, 28 Apr 2008 06:14:22 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JqQNI-0000dQ-Aj for qemu-devel@nongnu.org; Mon, 28 Apr 2008 06:14:21 -0400 Received: from [199.232.76.173] (port=43303 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JqQNH-0000dL-S5 for qemu-devel@nongnu.org; Mon, 28 Apr 2008 06:14:19 -0400 Received: from relay01.mx.bawue.net ([193.7.176.67]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JqQNH-0003y7-DU for qemu-devel@nongnu.org; Mon, 28 Apr 2008 06:14:19 -0400 Date: Mon, 28 Apr 2008 11:14:15 +0100 From: Thiemo Seufer Subject: Re: [Qemu-devel] [PATCH] ncurses: resize console if required Message-ID: <20080428101415.GD16597@networkno.de> References: <20080428035445.GA8787@tapir> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20080428035445.GA8787@tapir> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Carlo Marcelo Arenas Belon Cc: qemu-devel@nongnu.org Carlo Marcelo Arenas Belon wrote: > The following patch instructs qemu to print an escape command to resize the > curses console to 80x25 if detected to have a different geometry (xterm and > friends use 80x24 by default). Sounds like this should be specific to the PC/VGA emulation. Thiemo > Carlo > > --- > Index: curses.c > =================================================================== > --- curses.c (revision 4274) > +++ curses.c (working copy) > @@ -367,6 +367,11 @@ > > invalidate = 1; > > + /* check size of console and try to adjust if needed */ > + getmaxyx(stdscr, gheight, gwidth); > + if ((gwidth != 80) || (gheight != 25)) { > + printf("\033[8;25;80t"); > + } > /* Standard VGA initial text mode dimensions */ > curses_resize(ds, 80, 25); > } >