HP-UX Reference (11i v3 07/02) - 4 File Formats (vol 8)
t
terminfo(4) terminfo(4)
(ENHANCED CURSES)
Changing the Character/Line Pitches
cpi Change character pitch
cpix If set, cpi changes orhi; otherwise, changes orc
lpi Change line pitch
lpix If set, lpi changes orvi; otherwise, changes orl
chr Change steps per column
cvr Change steps per line
The cpi and lpi string capabilities are each used with a single argument, the pitch in columns (or char-
acters) and lines per inch, respectively. The chr and cvr string capabilities are each used with a single
argument, the number of steps per column and line, respectively.
Using any of the control sequences in these strings will imply a change in some of the values of orc, orhi,
orl, and orvi. Also, the distance moved when a wide character is printed, widcs, changes in relation to
orc. The distance moved when a character is printed in micro mode, mcs, changes similarly, with one
exception: if the distance is 0 or 1, then no change is assumed.
Programs that use cpi, lpi, chr,or cvr should recalculate the printer resolution (and should recalcu-
late other values. See the Effect of Changing Printing Resolution section below.
Effects of Changing the Character/Line Pitches
Before After
Using cpi with cpix clear:
orhi’ orhi
orc’ orc = orhi / Vcpi
Using cpi with cpix set:
orhi’ orhi = orc * Vcpi
orc’ orc
Using lpi with lpix clear:
orvi’ orvi
orl’ orl = orvi / Vlpi
Using lpi with lpix set:
orvi’ orvi = orl * Vlp
orl’ orl
Using chr:
orhi’ orhi
orc’ Vchr
Using cvr:
orvi’ orvi
orl’ Vcvr
Using cpi or chr:
widcs’ widcs = widcs’ * orc / orc’
mcs’ mcs = mcs’ * orc / orc’
Vchr, Vcpi, Vcvr, and Vlpi are the arguments used with chr, cpi, cvr, and lpi, respectively. The prime
marks (’) indicate the old values.
Capabilities That Cause Movement
In the following descriptions, "movement" refers to the motion of the "current position". With video termi-
nals this would be the cursor; with some printers, this is the carriage position. Other printers have
different equivalents. In general, the current position is where a character would be displayed if printed.
terminfo has string capabilities for control sequences that cause movement a number of full columns or
lines. It also has equivalent string capabilities for control sequences that cause movement a number of
smallest steps.
512 Hewlett-Packard Company − 28 − HP-UX 11i Version 3: February 2007