qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "andrzej zaborowski" <balrogg@gmail.com>
To: Ryan Harper <ryanh@us.ibm.com>
Cc: Paul Brook <paul@codesourcery.com>,
	qemu-devel@nongnu.org, kvm@vger.kernel.org,
	Ian Kirk <blob@blob.co.uk>
Subject: Re: [Qemu-devel] [PATCH 1/1][RESEND] v2: Fix text console size/resize when using curses
Date: Mon, 15 Sep 2008 20:42:06 +0200	[thread overview]
Message-ID: <fb249edb0809151142o86be706w10eeeb7bbbaaad81@mail.gmail.com> (raw)
In-Reply-To: <20080915173503.GT17312@us.ibm.com>

2008/9/15 Ryan Harper <ryanh@us.ibm.com>:
> * andrzej zaborowski <balrogg@gmail.com> [2008-09-15 11:51]:
>> Hi,
>
> Hello,
>
>>
>> 2008/9/4 Ryan Harper <ryanh@us.ibm.com>:
>> > v2: drop initial size adjustment, not needed.
>> >
>> > Resize events fail to ensure that both the text console and curses display areas
>> > are the same size; this causes broken output like:
>>
>> It seems that this was broken by r4812.  Your patch looks correct but
>
> Thanks for taking a look,
>
>> I think it will prevent things like -serial vc:80Cx24C from working as
>> documented. There's a conflict here: either virtual consoles have
>> commandline-set fixed size or they adjust to the window size like
>> before r4812 and don't have parts that don't fit on the screen. The
>> SDL window is not resizable but the curses window is always resizable.
>>  I propose to add TEXT_CONSOLE_FIXED_SIZE back, it was removed by
>> r4812.  I will do this unless there are better ideas.
>
> I'll test the -serial to see if that breaks with the current patch..
> I'm also looking at an alternative.  I think that in curses.c if on
> window change event we can send a qemu_console_resize() to the text
> consoles with the new width,height, that does the work of getting the
> width/height in sync.  I'll send an update if I get that working.

The TEXT_CONSOLE_FIXED_SIZE approach worked ok, too, and it's generic
(i.e. if in sdl.c you make the SDL window resizable then it'll start
working for SDL automatically).

>
>>
>> Another idea would be to set the default console size to 640x400 and
>> agree to not support terminals < 80x24.
>
> I'm not sure that would fix it completely, I'm pretty sure the output
> still looks broken even if your terminal is bigger than the min size
> required.

Right, at the moment it is broken because curses.c assumes that text
consoles automatically resized to ds->width,ds->height and they
didn't, they keep the size given through vc:XxY or 800x600 if none was
given.

Regards

      reply	other threads:[~2008-09-15 18:42 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-04 16:10 [Qemu-devel] [PATCH 0/1][RESEND] v2: Fix monitor console in curses mode Ryan Harper
2008-09-04 16:10 ` [Qemu-devel] [PATCH 1/1][RESEND] v2: Fix text console size/resize when using curses Ryan Harper
2008-09-15 16:48   ` andrzej zaborowski
2008-09-15 17:35     ` Ryan Harper
2008-09-15 18:42       ` andrzej zaborowski [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=fb249edb0809151142o86be706w10eeeb7bbbaaad81@mail.gmail.com \
    --to=balrogg@gmail.com \
    --cc=blob@blob.co.uk \
    --cc=kvm@vger.kernel.org \
    --cc=paul@codesourcery.com \
    --cc=qemu-devel@nongnu.org \
    --cc=ryanh@us.ibm.com \
    /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).