[comp.unix.questions] Standout mode in System V.3.2 curses

mday@iconsys (Matt Day) (09/08/90)

I've been having some trouble using the standout display mode in SVR3.2 curses.
Consider the following program:

#include <curses.h>

main() {
	initscr();
	noecho();

	standout();
	addstr("<highlighted>");
	standend();
	refresh();

	getch();
	wrefresh(curscr);

	endwin();
}

When this program exits (after you press a key), my vt100 terminal is completely
highlighted, while only "<highlighted>" is left in standout mode on other
various terminal types (the correct behavior, I believe).

I think this problem has been mentioned before, but I didn't see a solution
or workaround.  Apparently it has something to do with vt100's specifically,
rather than a total bug in curses, which is why I haven't fixed it myself.
Perhaps the vt100 terminfo library isn't complete or curses doesn't know that
vt100's need a special escape sequence.  In any case, could some vt100 guru
lend some insight?
-- 
- Matthew T. Day, Sanyo/Icon, mday@iconsys.icon.com || uunet!iconsys!mday

cpcahil@virtech.uucp (Conor P. Cahill) (09/08/90)

In article <78@iconsys> mday@iconsys (Matt Day) writes:
> When this program exits (after you press a key), my vt100 terminal is
> completely highlighted, while only "<highlighted>" is left in standout
> mode on other various terminal types (the correct behavior, I believe).

You can add the sequence which "sets the terminal to normal mode"  to one
of the terminfo reset sequences (rs1, rs2, or rs3) for the vt100 terminfo 
definition.  See terminfo(4) for more information.

-- 
Conor P. Cahill            (703)430-9247        Virtual Technologies, Inc.,
uunet!virtech!cpcahil                           46030 Manekin Plaza, Suite 160
                                                Sterling, VA 22170