Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: test patches

On May 10,  1:48pm, Zoltan Hidvegi wrote:
} Subject: Re: test patches
} > There still doesn't appear to be a test in init.c for the case where
} > the system supports TIOCGWINSZ but the rows and columns value in the
} > shttyinfo.winsize structure are both zero.  In that case we ought to
} > be using the row and column sizes from the termcap or terminfo entry?
} The test is done in zlevarsetfn() in params.c.

Yeah, but all it does is pretend the terminal is very narrow and set the
imaginary columns and lines to 80 and 24.

A zero value in shttyinfo.winsize is a special indicator from the driver
that it doesn't know what the window size is.  The actual window shape
in that case is read from the termcap by most applications.  It doesn't
mean that the window is actually zero sized.

I should have remembered this when I was fiddling with this code some
months ago; I remembered it a few weeks later when Geoff was hacking on
the zle refresh stuff, and mentioned it on the list.

The same test should probably go in adjustwinsize, but I don't think the
driver ever sends SIGWINCH when it doesn't know the window shape, so it
isn't as important there.

Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts        http://www.nbn.com/people/lantern

Messages sorted by: Reverse Date, Date, Thread, Author