home *** CD-ROM | disk | FTP | other *** search
/ No Fragments Archive 10: Diskmags / nf_archive_10.iso / MAGS / ST_USER / 1989 / USER1089.MSA / README.BAS < prev    next >
BASIC Source File  |  1985-11-19  |  1KB  |  63 lines

  1. REM READ_ME.PRG
  2. REM By R.A.Waddilove
  3. REM Last altered 2/7/89
  4. REM $OPTION Y+
  5.  
  6. LIBRARY "GEMAES"
  7. LIBRARY "XBIOS"
  8.  
  9. REM ------------ Open window ------------------
  10. res% = FNgetrez%
  11. x%=16:y%=24:h%=368:w%=608:linelen%=74:maxline%=18
  12. IF res%<2 THEN y%=16:h%=176:maxline%=16
  13. IF res%=0 THEN x%=2:w%=314:linelen%=38
  14. WINDOW OPEN 7," Atari ST User Disc Information ",x%,y%,w%,h%,1
  15. WINDOW OUTPUT 7
  16.  
  17. REM ---------- Load INFO.STW ----------------
  18. OPEN "READ_ME.STW" FOR INPUT AS #1
  19. buffer$=INPUT$(LOF(1),#1)
  20. CLOSE #1
  21.  
  22. REM ------------ Print file ------------------
  23. ptr& = SADD(buffer$)+&H22
  24. lines% = 0
  25. a$=""
  26. DO
  27.     char% = PEEKB(ptr&) : INCR ptr&
  28.     IF char% THEN a$=a$+CHR$(char%) ELSE INCR lines% : PRINT " ";a$ : a$=""
  29.     IF LEN(a$)=linelen% THEN INCR lines% : GOSUB slice
  30.     IF lines%>maxline% THEN lines%=0 : GOSUB pause
  31. LOOP UNTIL ( ptr&-SADD(buffer$)>LEN(buffer$) )
  32. GOSUB pause
  33. WINDOW CLOSE 7
  34. SYSTEM
  35.  
  36. slice:
  37. i%=LEN(a$)
  38. DO
  39.     DECR i%
  40.     c$=MID$(a$,i%,1)
  41. LOOP UNTIL c$=" " OR c$="-" OR c$="," OR c$="."
  42. PRINT " ";LEFT$(a$,i%)
  43. a$=MID$(a$,i%+1)
  44. RETURN
  45.  
  46. pause:
  47. PRINT " (Click the mouse...)";
  48. WHILE ( MOUSE(2)=0 ) : WEND
  49. CLEARW 7
  50. RETURN
  51.  
  52. DEF FNfilename$
  53. path$="A:\*.*"
  54. name$=""
  55. ok%=0
  56. fsel_input path$,name$,ok%
  57. WHILE right$(path$,1)<>"\"
  58. path$=LEFT$(path$,LEN(path$)-1)
  59. WEND
  60. CHDIR path$
  61. FNfilename$=path$+name$
  62. END DEF
  63.