how do I tell the size of a pseudoterm window?

Doug Gwyn gwyn at smoke.BRL.MIL
Fri Dec 9 18:05:58 AEST 1988


In article <5463 at cbmvax.UUCP> ditto at cbmvax.UUCP (Michael "Ford" Ditto) writes:
>What about a windowing system which communicates with its clients with
>"in band" data, using escape sequences in both directions?  Such a
>system has several disadvantages, but it is also appealing for many
>reasons, such as its usefulness over a "plain" tty connection or a
>long stream of virtual connections (like telnet, dataswitches, etc.).
>It could not support an ioctl of any kind.

Anything that provides "virtual terminals" but no ioctl support is
not worth worrying about because nobody in his right mind is going
to put up with that when he can easily get real windowing elsewhere.

If you use streams-based network technology, you can pass control
packets in the nominal data stream.

>Also, the idea of display LINES & COLUMNS is not specific to "windowing
>systems" -- "/dev/console" on the Amiga, for example, is just a plain
>ANSI text-only terminal, but it might be 80x25, 80x32, 80x50, or 128x100,
>depending on what kind of monitor and video format are being used, and
>other factors.  I would like to use the same method of inquiring about
>screen size with this device as with the windowing system.  Why should
>this depend on an ioctl command defined in a header file for a windowing
>system?

I don't know what you're talking about -- nobody said you should limit
your window-size ioctl definitions to <sys/jioctl.h>.  In fact I'd hope
that <sys/ioctl.h> defines TIOC[GS]WINSZ or equivalent on any modern UNIX.

>How about a library function to inquire about screen size?

Great, but 1003.1 didn't define one.  Nor did the SVID.  Where is
the "standard" going to come from?

Until there's an accepted standard for this, how about adding it to
your little box of system interface functions (those things with
invariant application interface specs that are implemented differently
for different systems).



More information about the Comp.unix.wizards mailing list