Programming W Ithbasic - Star Micronics XB-2425 User Manual

Multi-font
Table of Contents

Advertisement

PROGRAMMING WITH BASIC
As an exampleof programmingthe printeron MicrosoftBASIC,we have
listed the program for the IBM-PC. This program nms in the printer's
Standardmode, and the downloadable condition.
1000
1010
1020
1030
1040
1050
1060
1070
1080
1090
1100
1110
1120
1130
1140
1150
1160
1170
1186
1190
1200
1210
1220
1230
1240
1250
1260
1270
1280
1290
1300
1310
1320
1330
1340
1350
1360
1370
1380
1390
1400
1410
1420
1430
1440
1450
1460
1470
1480
1490
1500
1510
1520
1530
1540
1550
1560
1570
Set
contro
1 codes
E$=CHR$ ( 27)
Escape
code
D$=E$+" XO"
Draft
qual i ty
L$=E$+" X 1 "+E$+"k"
Letter
qual i ty
RM$=L$+CHR$ (0)
'Roman character
H$=CHR$( 9 )
'Horizontal
tab
PI $=E$+ "P"
'Pica
pitch
4 Start
printing
WIDTH "LPTI:" .255
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
LPRINT
FOR 1=1 TO 7
LPRINT E$; UA";CHR$(I);
LPRINT E$;"
":CHR$(I);
LPRINT "THE SPACINGS ARE CHANGED"
NEXT I
FOR 1=7 TO 1 STEP -1
LPRINT E$; "AU;CHR$(I)
;
LPRINT E$;"
";CHR$(I);
LPRINT "THE SPACINGS ARE CHANGED"
NEXT I
'Line
spacing
set
'Increase
character
space
'Line
spacing
set
'Increase
character
space
E$; "D'';cHR$(3);
cHR$(24)
;CHR$(0)
'Set
HT
L$;CHR$ (0);
president
fonts
are:"
H$;D$; "Draft
characters,";
H$:L$;cHR$(0)
;"Roman
characters,
"
H$;L$;CHR$(l)
;".$anserif
characters,";
H$;L$;CHR$(2)
;"Courier
characters,
"
H$;L$;CHR$(3)
; "Prestige
characters,";
H$;L$;CHR$(4)
;"Script
characters,
"
H$;L$;CHR$(7)
;" Orator
characters,";
H$;L$;CHR$(12);
"H-Gothic
characters,
"
H$:L$;cHR$(32);
'SLQ Roman,";
H$; L$;cHR$(33):"sLQ
Twilight.
"
RM$; "Print
pitches
are:"
H$;PI$;
"Pica
pitch
(10
CPI),";
H$;E$;
"M"; "Elite
pitch
(12
CPI),"
H$; E$; "g"; "Semi-condensed
pitch
(15
CPI),U;
H$;PI$;
CHR$(15);
'Select
condensed
print
"Condensed
pica
pitch
(17
CPI),"
H$; E$; ''MO ;"Condensed
elite
pitch
(20
CPI),";
CHR$(18)
'Cancel
condensed
print
H$;E$;
"pl";
'Select
proportional
spacing
PI$; "Normal
proportional,";
H$;CHR$(15)
; "Condensed
proportional.";
CHR$(18) ;
E$;UPO"
'Cancel
proportional
spacing
H$;E$;
"W1";"Double-height,
";E$;
"wO"
H$;E$;
"W1'; "Double
width,
";E$;
NWO"
H$;CHR$(28)
;"E";cHR$(2)
;"Triple
width,";
CHR$(28) ;"E";CHR$(0)
H$; E$; ''h" ;CHR$(l);
"Doubl e-sized,
"
H$;E$;
"h";CHR$(2)
; "Quad-sized.
';
E$; "h";CHR$(0)
:LPRINT,
E$; "Q'';CHR$(47)
'Set
right
margin
RM$; "Various
line
and character
spacings:"
E$;"al"
'Center
text
135

Advertisement

Table of Contents
loading

This manual is also suitable for:

Xb-2420

Table of Contents