home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 147 / 147.d81 / hrs2.print.epson (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  3KB  |  106 lines

  1. 100 poke56,30:clr
  2. 105 dima,b,c,x,y,z,l,k,s,h,x$,pc,px,py
  3. 110 o=6:dimo$(o),o(o),h(o),l(o),rv$(1),b(9),c(9),z%(8,3),s$(8),m1,m2,m3,m4,l1,l2
  4. 130 o$(0)="x scale    "
  5. 140 o$(1)="y scale    "
  6. 150 o$(2)="top  margin"
  7. 160 o$(3)="left margin"
  8. 170 o$(4)="device  4-7"
  9. 175 o$(5)="density 0-9"
  10. 178 o$(6)="sideways(1)"
  11. 180 fora=.to6:reado(a),l(a),h(a):next
  12. 190 fora=.to9:readb(a):next
  13. 200 fora=.to9:readc(a):next
  14. 230 fora=.to8
  15. 240 forb=.to3:readz%(a,b):next
  16. 270 reads$(a):next
  17. 290 rv$(0)="[146]":rv$(1)=""
  18. 300 bg=peek(700):fg=peek(701):px=211:py=214:pc=58732:ky=197:sk=653
  19. 330 x=fre(0)
  20. 340 c=peek(45)+(peek(46)-2)*256
  21. 350 b=peek(49)+peek(50)*256+15
  22. 360 l1=b:l2=b+1215
  23. 390 a=256
  24. 395 poke252,l1/a:poke251,l1-peek(252)*a:poke254,l2/a:poke253,l2-peek(254)*a
  25. 410 poke780,.:sys50309
  26. 420 print"[147]";:poke53280,fg:poke53281,fg:poke646,bg:print"";:a=10:x=17
  27. 430 printspc(a)"  [176][195][201][176][195][201][213][192][201][213][192][201][213][201][213]"
  28. 431 printspc(a)"  [171][192] [171][192][203][202][192][201][221] [221][221][221][194]"
  29. 432 printspc(a)"  [173][195][189][177]  [173][192][203][202][192][203][189][202][203]"
  30. 433 printspc(a)"   print program"
  31. 440 printspc(a)"[176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174]"
  32. 450 printspc(a)"[221](1).........print[221]"
  33. 460 printspc(a)"[221](2).......options[171][192][174]"
  34. 470 printspc(a)"[221](_)..........exit[221] [221]"
  35. 480 printspc(a)"[173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189] [221]"
  36. 510 print"[176][195][195][195][195][195][195][195][174] [176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174] [221]"
  37. 520 print"[194]0....60[194] [221]"spc(x)"[221] [221]"
  38. 540 print"[194]1...120[194] [221]"spc(x)"[221] [221]"
  39. 560 print"[194]2..'120[194] [221]"spc(x)"[221]_[189]"
  40. 580 print"[194]3...240[194] [221]"spc(x)"[221]"
  41. 600 print"[194]4....80[194] [221]"spc(x)"[221]"
  42. 605 print"[194]5....72[194]_[179]"spc(x)"[221]"
  43. 607 print"[194]6....90[194] [221]"spc(x)"[221]"
  44. 610 print"[171][192][192][192][192][192][192][192][179] [173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189]"
  45. 611 print"[194]7....60[194]         ^"
  46. 612 print"[194]8...120[194] [176][192][192][192][192][192][192][192][177][192][192][192][192][192][192][192][174]"
  47. 613 print"[194]9...240[194] [221]up/dn to select[221]"
  48. 614 print"[173][195][195][195][195][195][195][195][189] [221]lf/rt to change[221]"
  49. 615 print"          [221]+...+10 -...-10[221]"
  50. 616 print"          [173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189]";
  51. 620 gosub850
  52. 630 poke198,.:wait198,1:getx$:a=fre(0)
  53. 640 ifx$="2"thengosub870
  54. 650 ifx$="_"then810
  55. 660 ifx$<>"1"then630
  56. 665 poke691,o(5)*13
  57. 670 fora=0to3:poke692+a,z%(o(0),a):next
  58. 680 fora=0to3:poke696+a,z%(o(1),a):next
  59. 690 print"[147]";:open15,o(4),15:close15:ifst=.then710
  60. 700 printspc(9)"printer is not present":fora=.to2500:next:goto390
  61. 710 printspc(15)"printing...":print:printspc(7)"hold down any key to cancel"
  62. 715 m1=peek(3):m2=peek(4):m3=peek(5):m4=peek(6)
  63. 720 open1,o(4),5
  64. 735 h=int(o(2)/8):l=o(2)-h*8
  65. 745 ifhthenfora=.toh:print#1,chr$(27)chr$(51)chr$(24)chr$(10);:next
  66. 755 poke2,o(3):a=b(o(5)):poke4,a/256:poke3,a-peek(4)*256:a=o(5)<7:poke5,4-a
  67. 760 poke681,27:poke682,42:poke682-a,c(o(5)):poke683-a,peek(3):poke684-a,peek(4)
  68. 765 poke6,4:poke687,27:poke688,51:poke689,24:poke690,10:sysc+256*o(6),b,255-2^l
  69. 790 close1:poke3,m1:poke4,m2:poke5,m3:poke6,m4:goto390
  70. 810 poke646,fg:print"[147]s[217]53235:g[207]147";
  71. 820 poke198,1:poke631,13:end
  72. 850 z=.:fory=.too:x=o(y):gosub1010:next
  73. 860 return
  74. 870 y=.:h=h(y):l=l(y):x=o(y):z=1
  75. 880 fora=-1to.
  76. 890 k=peek(ky):s=peek(sk)
  77. 895 ifk=43thenx=x+(x-9>l)*10
  78. 896 ifk=40thenx=x-(x+9<h)*10
  79. 900 ifk<>2then930
  80. 910 ifs=1thenx=x+(x>l)
  81. 920 ifs=.thenx=x-(x<h)
  82. 930 ifk<>7then980
  83. 940 gosub1000
  84. 950 ifs=.theny=y-(y<o)
  85. 960 ifs=1theny=y+(y>.)
  86. 970 z=1:h=h(y):l=l(y):x=o(y)
  87. 980 gosub1010
  88. 990 a=k<>1:next
  89. 1000 o(y)=x:z=.
  90. 1010 pokepy,11+y:pokepx,11:syspc
  91. 1020 printrv$(z)o$(y)"[146]  ";
  92. 1030 ify>1thenprintspc(2+(x>9)+(x>99))x:return
  93. 1040 prints$(x):fora=.to25:next:return
  94. 1041 data0,0,8
  95. 1042 data0,0,8
  96. 1043 data0,0,500
  97. 1044 data0,0,255
  98. 1045 data4,4,7
  99. 1046 data7,0,9
  100. 1047 data0,0,1
  101. 1048 data480,960,960,1215,640,576,720,480,960,1215,0,1,2,3,4,5,6,75,76,90
  102. 1050 data0,0,0,0,"1.00",0,0,0,1,"1.25",0,1,0,1,"1.50",1,1,1,0,"1.75"
  103. 1080 data1,1,1,1,"2.00",1,1,1,2,"2.25",1,2,1,2,"2.50",2,2,2,1,"2.75"
  104. 1110 data2,2,2,2,"3.00"
  105. 1120 rem machine code here
  106.