Star Micronics LC-20 Printer User Manual


 
p w
Thisprogrambeginsbyassigninganumberofprintercommandsto BASIC
stringvariables(lines1000to 1090).Youcanfindmostofthesecommands
nearthe beginningof chapter4.
TheWIDTH“LPT1:“255statementin line 1110meansintlnitelinewidth.
It preventsthe IBM-PCfrom insertingunwantedcarriagereturnsandline
feedsin graphicsdata.
Actualprintingbeginsinline 1120.Usingthe preassignedcommands,the
programprints samplesof its differentfonts,includinga line showingall
stylesinitalics,followedby samplesoftheprintpitches,thensomedouble
and quadruple-sizedprinting.
Next comes the central attractionof the program:a line of text printed
fourteentimesinexpandingandcontractingloopstogiveabarreleffect.The
workisdoneby fourprintercommands:acommandsettingtherightmargin
(line 14@);a centeringcommand(line 1420);a commandto varythe line
spacing(lines 1440and 1490);and a commandto micro-adjustthe space
betweencharactm (lines 1450and 15W).
Nexttheprogramreturnstonormalspacingandgivesademonstrationofthe
printer’swc)rd-processingabilities:boldprinting,underlining,subscripts,
etc.
The row of automobilesin thenextprintedlineis createdby dGwrdoading
twonewcharacterpatterns,whichareprintedinplaceof thecharacter“<”
(character60).Detailscanbe fwnd in Chapter5.
The finalpart of theprogramusesdotgraphicsto printsome“SW”IGgm
withvariousdensities.Thedotpatternofthelogowasoriginallylaidouton
graphpaper,thenconvertedto the datain lines2400to 2630withthehelp
of a calculator.Eachnumber~presentseightverticaIdots.(See“Graphics
cGmmands”in Chapter4 for details.)
Thepatternis printedinfourrows,eachrowis eightdotshigh and 65 dots
wide.Lines1800to 1850readthedotdataintoastringarrayvariablenamed
LOGO$.Line 1860setstheline spacingtG8/72inch so that the rows will
connectvertically.Theloopin lines 1870tG1960dGestheprintingin four
passesof the printhead.
86