getting info from TERMINFO/TERMCAP

Brad Appleton brad at SSD.CSD.HARRIS.COM
Fri Sep 28 00:50:24 AEST 1990


I want to get some info from terminfo: namely the window size (number
of rows and columns) of the tty-screen. That is ALL I need. I DONT want
the rest of curses, I DONT need/want to call setupterm(), just the
window size. Is there someway to do this directly through terminfo
without having to include (or compile with) curses at ALL?

I know about the tigetnum() function but it looks like I have to call
setupterm first (and I DONT want to use curses or terminfo to do any
input or output).

As for doing the same thing with termcap. It appears I can
use tgetent() combined with tgetnum(). But when I do this I get
some unresolved externals from the linker. I cant find in TFM where
it says what special libraries (if any) I need to compile with for
termcap stuff.

Any help would be greatly appreciated!!!!!!!!!!!

______________________ "And miles to go before I sleep." ______________________
 Brad Appleton        brad at travis.ssd.csd.harris.com   Harris Computer Systems
                          ...!uunet!hcx1!brad          Fort Lauderdale, FL USA
~~~~~~~~~~~~~~~~~~~~ Disclaimer: I said it, not my company! ~~~~~~~~~~~~~~~~~~~



More information about the Comp.unix.programmer mailing list