using ioctl() to get window-size
Doug Gwyn
gwyn at smoke.BRL.MIL
Thu Oct 4 19:03:14 AEST 1990
In article <10650105 at hpisod2.HP.COM> decot at hpisod2.HP.COM (Dave Decot) writes:
>> there some other way to get this info from ioctl other than via TIOCGWINSZ??
>> If so, how portable is it (AT&T only? BSD only? SunOS only? ...)?
>For those systems that have this capability, that's about the most common
>way to do it. It appears to be mostly on systems derived from SunOS
>(such as System VR3).
Actually, TIOCGWINSZ first appeared under that name on some intermediate
release of 4.2BSD. SunOS had introduced a very similar ioctl with a slightly
different name, and Berkeley did their usual reengineering act on it. AT&T
around 1984 had come up with a similar JWINSIZE ioctl to support "layers"
(xt protocol, as used in Blit, 5620, 630, etc. terminals). AT&T's was
different in one significant way: the size originally could not be set
from user mode; the xt pseudo-device driver took care of setting the size.
(This has since changed somewhat.)
Notice the historical lack of communication among UNIX developers all
working on similar facilities. Shame, shame.
More information about the Comp.unix.questions
mailing list