alternate screen selection in termcap

Phil Howard KA9WGN phil at ux1.cso.uiuc.edu
Sat Feb 23 06:16:57 AEST 1991


I am trying to figure out how to correct some termcap entries for terminal
types that have alternate screens.  It seems that "ti" and "te" are for the
purpose of some sort of initialization (can someone explain exactly what
they are for better than termcap(5) does?).  However for terminal types
that have an alternate screen, these are usually set to switch to that screen.

I need to be able to specify to a program via the termap HOW to switch to an
alternate screen, but NOT to do it by default as part of initialization for
cursor motions.

A typical reason for NOT switching is so that output from programs like the
"less" command, when concluded, will still be visible on the screen.  It is
very annoying when I "less" a file to see something in to in order to type
the next command with, and when I press "q" to get out of "less" it switches
back to the primary screen and I no longer can see what I need to look at.
Yet I want to retain the ability to use the alternate screen in editors.

Also if anyone has a program already written (so I don't have to re-invent
it) that searches for terminal types via both user and system termcap files
(such as ".termcap" then "/etc/termcap") I'd like to know about it.

Thanks!
-- 

--Phil Howard, KA9WGN-- | Individual CHOICE is fundamental to a free society
<phil at ux1.cso.uiuc.edu> | no matter what the particular issue is all about.



More information about the Comp.unix.programmer mailing list