Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sdd.hp.com!decwrl!sgi!shinobu!odin!pkr From: pkr@sgi.com (Phil Ronzone) Newsgroups: comp.sys.sgi Subject: Re: wsh window size code Message-ID: <1991Apr18.190445.21806@odin.corp.sgi.com> Date: 18 Apr 91 19:04:45 GMT References: <9104170341.AA13470@karron.med.nyu.edu> <1991Apr18.183945.21088@odin.corp.sgi.com> Sender: news@odin.corp.sgi.com (Net News) Organization: Cold War Victory Parade Float Construction Company Lines: 31 In article <1991Apr18.183945.21088@odin.corp.sgi.com> msc@sgi.com writes: >I will admit that the TIOCGETWINSZ ioctl is not clearly documented. However >most of the rest of this stuff is documented in the terminfo/curses man pages. > >-- >From the TARDIS of Mark Callow >msc@ramoth.sgi.com, ...{ames,decwrl}!sgi!msc >"Spirits of genius are always opposed by mediocre minds" - Albert Einstein int lines; int columns; status = ioctl(fileno(stdin),TIOCGWINSZ,&ws); if (status != 0) { rpterr(1,1,fn,"Bad return from ioctl(,TIOCGWINSZ,) of %d",status); return(1); } columns = ws.ws_col; lines = ws.ws_row; -- Philip K. Ronzone pkr@sgi.com Silicon Graphics, Inc. MS 9U-500 work (415) 335-1511 2011 N. Shoreline Blvd., Mountain View, CA 94039 fax (415) 969-2314 ...................................."Why, you little ........", Homer Simpson