home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 147 / 147.d81 / hrs2.print.1525 (.txt) < prev    next >
Encoding:
Commodore BASIC  |  1996-01-01  |  3.1 KB  |  114 lines

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