45

In this program underline is turned on in line 20 with (ESC)

<<

–“ 1, and then off in line 40 with (ESC) “-” O.There’s a new aspect to this program, though. The semicolons at the end of the first three lines told BASIC that those lines were to be con- tinued. Therefore, BASIC didn’t send a carriage return and line feed at the end of those lines. We just did this to illustrate that all these control codes can be used in the middle of a line. It’s easy to underline or italicize only part of a line.

Superscripts and subscripts

Your printer can print in two different heights of characters. The smaller characters are called superscriptsand subscrifltsand are half the height of normal characters. Superscriptsprint even- ly with the tops of regular printing while subscriptsprint evenly with the bottom of regular printing. They are frequently used to reference footnotes, and in mathematical formulas.

Table 4-4 has the codes for using superscripts and subscripts.

Table 4-4

Superscripts and subscripts commands

Try this program to see them work:

10 ‘ Demo of superscripts and subscripts

20 LPRINT “Look! “ ;

30LPRINT CHR$(27) ; “SO”;

40LPRINT “SUPERSCRIPTS ;

50LPRINTCHR$(27) ; “T”;

60LPRINT !,& ,,;

70LPRINTCHR$(27) ; “S1” ;

80LPRINT “SUBSCRIPTS“ ;

90LPRINTCHR$(27); “T”;

Page 53
Image 53
Star Micronics NX-15 user manual Lprint Superscripts, Lprint Subscripts