terminfo.4 (2010 09)
t
terminfo(4) terminfo(4)
(ENHANCED CURSES)
• Protected text (prot)
• A reverse-video screen (rev)
• An alternate character set (smacs to enter this mode and rmacs to exit it). (If a command is
necessary before you can enter alternate character set mode, give the sequence in enacs or
"enable alternate-character-set" mode.) Turning on any of these modes singly may turn off other
modes.
sgr0 should be used to turn off all video enhancement capabilities. It should always be specified because
it represents the only way to turn off some capabilities, such as dim or blink.
Choose one display method as standout mode and use it to highlight error messages and other text to
which you want to draw attention. Choose a form of display that provides strong contrast but that is easy
on the eyes. (We recommend reverse-video plus half-bright or reverse-video alone.) The sequences to
enter and exit standout mode are given as smso and rmso, respectively. If the code to change into or
out of standout mode leaves one or even two blank spaces on the screen, as the TVI 912 and Teleray 1061
do, then xmc should be given to tell how many spaces are left.
Sequences to begin underlining and end underlining can be specified as smul and rmul, respectively. If
the device has a sequence to underline the current character and to move the cursor one space to the
right (such as the Micro-Term MIME), this sequence can be specified as uc.
Terminals with the "magic cookie" glitch (xmc) deposit special "cookies" when they receive mode-setting
sequences, which affect the display algorithm rather than having extra bits for each character. Some ter-
minals, such as the Hewlett-Packard 2621, automatically leave standout mode when they move to a new
line or the cursor is addressed. Programs using standout mode should exit standout mode before moving
the cursor or sending a newline, unless the msgr capability, asserting that it is safe to move in standout
mode, is present.
If the terminal has a way of flashing the screen to indicate an error quietly (a bell replacement), then this
can be given as flash; it must not move the cursor. A good flash can be done by changing the screen
into reverse video, pad for 200 ms, then return the screen to normal video.
If the cursor needs to be made more visible than normal when it is not on the bottom line (to make, for
example, a nonblinking underline into an easier to find block or blinking underline) give this sequence as
cvvis. The boolean chts should also be given. If there is a way to make the cursor completely invisi-
ble, give that as civis. The capability cnorm should be given, which undoes the effects of either of
these modes.
If your terminal generates underlined characters by using the underline character (with no special
sequences needed) even though it does not otherwise overstrike characters, then specify the capability
ul. For devices on which a character overstriking another leaves both characters on the screen, specify
the capability os. If overstrikes are erasable with a blank, then this should be indicated by specifying
eo.
If there is a sequence to set arbitrary combinations of modes, this should be given as sgr (set attributes),
taking nine arguments. Each argument is either 0 or nonzero, as the corresponding attribute is on or off.
The nine arguments are, in order: standout, underline, reverse, blink, dim, bold, blank, protect, alter-
nate character set. Not all modes need to be supported by sgr; only those for which corresponding
separate attribute commands exist should be supported. For example, let’s assume that the terminal in
question needs the following escape sequences to turn on various modes.
20 Hewlett-Packard Company − 20 − HP-UX 11i Version 3: September 2010