Star Micronics NX-15 Printer User Manual


 
69
Table 5-8
one-time horzontal tabs
Function
Control code
One-timehorizontaltab of
n
(ESC) “f” OCHR$(n)
spaces
Absolutehorizontaltab
(ESC) “$” CHR$(nl)CIIIl$(@
Relativehorizontaltab
(ESC) “\” CHR$(nl)CHR$(n2)
The first command in Table 5-8 moves the print head n col-
umns to the right. It has the same effect as sending n spaces to
the printer.
The absolute horizontal tab command moves the print head to
a specified position on the page. The position that you want the
print head to move to (measured from the left margin) is
specified by the values of nl and n2 using the formula nl + n2
x 256. The units by which the print head actually moves vary
with the print pitch you are using, as shown in Table 5-9.
Try this program to see how this works.
In this program, the print head is positioned before the “H” in
“Horizontal” is printed.
‘t..;,).1:::!,,
‘1::..:;1.1::1,,
‘t.21::)s,
“!:.al:],,
,!~] +.11-1+
I’””li::il’”i ::!c,r) “1:.A :1. “[:.;(L.!3,!
..7.,...
..J
.I.I--IF+
Hc)l ”” 1.;; i::)l”i‘!:.A 1. ‘t..::31:2ii
The relative horizontal tab command can move the print head
right from the current position. The formula for calculating how
much the print head moves is the same as in the absolute
horizontal tab command. However, the units by which the print
head actually moves vary with the print pitch you are using as
shown in Table 5-9.