HP-UX Reference (11i v3 07/02) - 4 File Formats (vol 8)
t
terminfo(4) terminfo(4)
(ENHANCED CURSES)
Notation Represents Character
^x Control-x (for any appropriate x)
\a Alert
\b Backspace
\E or \e An ESCAPE character
\f Form feed
\l Linefeed
\n Newline
\r Carriage return
\s Space
\t Tab
\ˆ Caret (ˆ)
\\ Backslash (\)
\, Comma (,)
\: Colon (:)
\0 Null
\nnn Any character, specified as three octal digits
(See the "X/Open System Interface Definitions, Issue 4, Version 2" specification, "General Terminal Inter-
face".)
Commented-Out Capabilities
Sometimes individual capabilities must be commented out. To do this, put a period before the capability
name. For example, see the second ind in the example in the Sample Entry section above. Note that
capabilities are defined in a left-to-right order and, therefore, a prior definition will override a later
definition.
Device Capabilities
Basic Capabilities
The number of columns on each line for the device is given by the cols numeric capability. If the device
has a screen, then the number of lines on the screen is given by the lines capability. If the device wraps
around to the beginning of the next line when it reaches the right margin, then it should have the am capa-
bility. If the terminal can clear its screen, leaving the cursor in the home position, then this is given by the
clear string capability. If the terminal overstrikes (rather than clearing a position when a character is
struck over) then it should have the os capability. If the device is a printing terminal, with no soft copy
unit, specify both hc and os. If there is a way to move the cursor to the left edge of the current row,
specify this as cr. (Normally this will be carriage return, control-M.) If there is a way to produce an audi-
ble signal (such as a bell or a beep), specify it as bel. If, like most devices, the device uses the XON/XOFF
flow-control protocol, specify xon.
If there is a way to move the cursor one position to the left (such as backspace), that capability should be
given as cub1. Similarly, sequences to move to the right, up, and down should be given as cuf1, cuu1,
and cud1, respectively. These local cursor motions must not alter the text they pass over; for example,
you would not normally use "cuf1=\s" because the space would erase the character moved over.
A very important point here is that the local cursor motions encoded in terminfo are undefined at the left
and top edges of a screen terminal. Programs should never attempt to backspace around the left edge,
unless bw is specified, and should never attempt to go up locally off the top. To scroll text up, a program
goes to the bottom left corner of the screen and sends the ind (index) string. To scroll text down, a pro-
gram goes to the top left corner of the screen and sends the ri (reverse index) string. The strings ind
and ri are undefined when not on their respective corners of the screen.
Parameterized versions of the scrolling sequences are indn and rin. These versions have the same
semantics as ind and ri, except that they take one argument and scroll the number of lines specified by
that argument. They are also undefined except at the appropriate edge of the screen.
The am capability tells whether the cursor sticks at the right edge of the screen when text is output, but
this does not necessarily apply to a cuf1 from the last column. Backward motion from the left edge of the
screen is possible only when bw is specified. In this case, cub1 will move to the right edge of the previous
row. If bw is not given, the effect is undefined. This is useful for drawing a box around the edge of the
screen, for example. If the device has switch-selectable automatic margins, am should be specified in the
terminfo source file. In this case, initialization strings should turn on this option, if possible. If the device
has a command that moves to the first column of the next line, that command can be given as nel (new-
line). It does not matter if the command clears the remainder of the current line, so if the device has no
500 Hewlett-Packard Company − 16 − HP-UX 11i Version 3: February 2007