DIM l$(1600), k$(21), c$(5), m$(5) DIM t$(400) ON ERROR GOTO 200 p3 = 1: p = 1: adr = 1: m = 78: k = 1: bc = 0: bp = 0: nw = 0: ii = 23 e = 0: c = 2: na = 1: s2 = 0: hi = 1: co = 14: tm = 1: xe = 330 COLOR co, bp 1 CLS : LOCATE 4, 15: PRINT "starting EB.EXE "; 'n$ = COMMAND$ IF n$ <> "" THEN a$ = RIGHT$(n$, 2): adr = 0 IF LEFT$(a$, 1) = "/" THEN n$ = LEFT$(n$, LEN(n$) - 2) a$ = LCASE$(RIGHT$(a$, 1)) IF LEN(n$) < 3 THEN 10 END IF IF RIGHT$(n$, 1) = "*" THEN n$ = LEFT$(n$, LEN(n$) - 1) IF LEN(n$) > 2 THEN rd = 1: ii = 24: GOTO 25 ELSE 12 END IF 10 DATA 31,31,28,31,30,31,30,31,31,30,31,30,31 i$ = DATE$: w = VAL(MID$(i$, 4, 2)): ga = 0 FOR a = 1 TO VAL(LEFT$(i$, 2)) z = z + y READ y NEXT x = INT((((z + w) / 7) - INT((z + w) / 7)) * 7.2): IF x = 0 THEN x = 7 IF x = 3 THEN IF w = y OR w < 7 OR (w > 13 AND w < 21) THEN ga = 1 END IF OPEN "list" FOR INPUT AS #1: INPUT #1, b, pg, x, y, z, j$: CLOSE IF b < -352 AND j$ <> "" THEN IF b = -353 THEN hi = 1 c = z: adr = 0: e = x: rd = y: n$ = j$: ii = ii + rd END IF 12 ERASE l$ 13 i$ = n$: IF nw = 2 THEN c$(1) = "" ELSE nw = 0 IF hi = 1 OR s2 = 0 THEN IF s2 = 0 OR c$(1) = "" THEN IF adr = 0 THEN PRINT " Reading filenames"; IF v$ = "" THEN SHELL "ver > ver": OPEN "ver" FOR INPUT AS #1: v$ = "" WHILE v$ = "" LINE INPUT #1, v$ WEND CLOSE : SHELL "del ver": b = 1 WHILE LCASE$(b$) <> "sion" b$ = MID$(v$, b, 4): b = b + 1 WEND v$ = LEFT$(v$, b + 8) END IF b = VAL(RIGHT$(v$, 5)) IF b > 4 THEN SHELL "dir /o:n > list" ELSE co = 7: COLOR co, 0: SHELL "dir > list" END IF 14 ERASE c$, m$: cc = 3 c$(1) = ">>> EXIT <<<**New File**-Renew List-" m$(1) = " " OPEN "list" FOR INPUT AS #1: x = 10: fi = 0 WHILE NOT EOF(1) AND cc < 100 LINE INPUT #1, a$: b$ = " ": b = 13 IF LEN(a$) > 15 THEN IF MID$(a$, 1, 1) <> " " AND MID$(a$, 16, 1) = " " THEN DO WHILE b$ = " " b = b + 1: b$ = MID$(a$, b, 1) LOOP c = b: e$ = b$ DO WHILE RIGHT$(e$, 1) <> " " b = b + 1: e$ = MID$(a$, c, b - c) LOOP e$ = RIGHT$(" " + e$, 10) d$ = MID$(a$, 10, 3) a$ = MID$(a$, 1, 8) DO WHILE RIGHT$(a$, 1) = " " AND a$ <> "" a$ = LEFT$(a$, LEN(a$) - 1) LOOP IF d$ <> " " THEN a$ = a$ + "." + d$ a = 20 IF a$ <> "LIST" AND a$ <> "COPY!" THEN IF fi <> 0 THEN IF fi < 0 THEN IF RIGHT$(a$, ABS(fi)) = UCASE$(fi$) THEN a = 90 IF fi > 0 THEN IF LEFT$(a$, fi) = UCASE$(fi$) THEN a = 90 IF a = 20 THEN a = 30 END IF IF a <> 30 THEN IF LEN(a$) > 8 OR LEFT$(RIGHT$(a$, 4), 1) = "." THEN a = 0 ELSE a = 4 IF LEN(a$) > 12 THEN a$ = LEFT$(a$, 1) + RIGHT$(a$, 11) END IF b$ = SPACE$(12 - LEN(a$) - a) + a$ + SPACE$(a): cc = cc + 1 IF a$ = UCASE$(n$) THEN na = cc y = INT((cc - 1) / 20) + 1: c$(y) = c$(y) + b$: x = 0 m$(y) = m$(y) + " " + e$ END IF END IF ELSE IF RIGHT$(a$, 5) = "bytes" THEN i$ = RIGHT$(a$, 17) i$ = LEFT$(i$, 12) MID$(m$(1), 1, 36) = i$ + i$ + i$ END IF END IF END IF WEND CLOSE : IF x = 10 THEN fi = 100 END IF IF d = -29 THEN d = 0: s2 = 1: GOTO 50 IF s2 = 0 THEN s2 = 1: IF n$ <> "" THEN 25 ELSE 12 CLS FOR y = 0 TO 4 a$ = c$(y + 1) FOR z = 0 TO 3 FOR d = 1 TO 5 b$ = MID$(a$, z * 60 + d * 12 - 11, 12) + " ": PRINT b$; NEXT PRINT NEXT IF y = 0 AND fi = 100 THEN PRINT " File not found": y = 4 NEXT PRINT x = INT((na - 1) / 5) + 1: p = (na - ((x - 1) * 5)) * 15 - 14 LOCATE 22, 1 PRINT "Press ENTER to select, a leading character or arrow key"; PRINT " to shift the cursor," LOCATE 23, 1 PRINT " ? for Help, = for DOS, ` to define a file subset,"; PRINT "] to set starting line "; PRINT " DEL to Delete the selected file, "; PRINT " ALT-v to toggle mono vs. color,"; LOCATE 25, 1: PRINT " ALT-r to rename the selected file,"; PRINT " ESC to exit highlight listing."; 21 y = INT((na - 1) / 20) a$ = MID$(c$(y + 1), (na - y * 20) * 12 - 11, 12) e$ = MID$(m$(y + 1), (na - y * 20) * 12 - 11, 12) LOCATE 21, 4: PRINT v$; TAB(55); e$; " bytes"; LOCATE x, p: COLOR bp, co: PRINT a$; : COLOR co, bp: LOCATE x, p e$ = "" WHILE e$ = "" e$ = INKEY$ WEND b = ASC(RIGHT$(e$, 1)): PRINT a$ IF ASC(LEFT$(e$, 1)) = 0 THEN IF b = 37 THEN SHELL "k.bat": GOTO 12 IF b = 45 THEN 400 IF b = 47 THEN d = -29: GOTO colo y = na: z = x: a = p IF b = 19 THEN d = -29: GOTO 23 IF b = 83 THEN LOCATE 21, 15 PRINT "**** Press Delete again or 'y' to delete ****"; : b$ = INPUT$(1) IF b$ = "y" OR ASC(b$) = 0 THEN d = -28: GOTO 23 LOCATE 25, 10: PRINT SPACE$(50); END IF IF b = 72 THEN na = na - 5: x = x - 1 IF b = 80 THEN na = na + 5: x = x + 1 IF b = 77 THEN na = na + 1: p = p + 15 IF b = 75 THEN na = na - 1: p = p - 15 IF na < 1 OR na > cc THEN na = y: x = z: p = a IF p < 0 THEN p = 61: x = x - 1 IF p > 61 THEN p = 1: x = x + 1 GOTO 21 END IF find: IF e$ <> "]" AND b > 32 AND b < 127 AND b <> 96 AND b <> 61 AND b <> 63 THEN d = 1: a = -12: b$ = " ": IF b = 123 THEN e$ = n$ e$ = LCASE$(e$) LOCATE 12, 1 WHILE b$ <> e$ AND d < 5 b$ = " ": y = fi IF a < 228 THEN a = a + 12: z = a ELSE d = d + 1: a = 0: z = 0 DO WHILE LEFT$(b$, 1) = " " AND z < 228 z = z + 1 b$ = LCASE$(MID$(c$(d), z, LEN(e$))) IF b$ <> " " AND y > 0 THEN y = y - 1: b$ = " " LOOP WEND IF e$ = b$ THEN na = (d - 1) * 20 + INT(z / 12) + 1: x = INT((na - 1) / 5) + 1 p = a - INT(a / 60) * 60 p = p + (3 * INT(p / 12)) + 1 IF b = 123 THEN a$ = MID$(c$(d), a + 1, 12): GOTO 23 END IF ELSE IF b = 123 THEN d1 = 2: GOTO 40 END IF IF hi = 1 THEN 21 ELSE 25 END IF LOCATE 24, 15 ELSE CLS IF fi = 0 THEN FILES ELSE IF fi > 0 THEN FILES fi$ + "*" IF fi < 0 THEN FILES "*" + fi$ END IF PRINT dir: IF adr = 1 THEN LOCATE 25, 40: PRINT "(`\' ending to engage abreviating)"; LOCATE 23, 1: PRINT " `?' for Help, `=' for DOS, "; PRINT "ESC for a highlight list, ` to display *.TXT"; LOCATE 24, 1: PRINT " or "; IF adr = 0 THEN PRINT "the first letters of "; PRINT "a Filename to edit:____________"; LOCATE CSRLIN, POS(0) - 12 22 e$ = INPUT$(1): b = ASC(e$): IF b = 13 THEN hi = 0: adr = 1: GOTO 400 IF b < 27 THEN 12 END IF IF e$ = "=" THEN na = 1 CLS : PRINT : PRINT "you are at the DOS prompt: "; : a$ = " ": e$ = "" WHILE ASC(a$) <> 13 a$ = INPUT$(1) IF a$ = "`" THEN a$ = "*" IF ASC(a$) > 30 THEN e$ = e$ + a$: PRINT a$; IF ASC(a$) = 8 THEN IF e$ <> "" THEN e$ = LEFT$(e$, LEN(e$) - 1): LOCATE CSRLIN, POS(0) - 1 PRINT " "; : LOCATE CSRLIN, POS(0) - 1 END IF END IF WEND CLS IF e$ = "" THEN SHELL "command /k dir/w" ELSE SHELL e$ IF LCASE$(LEFT$(e$, 3)) = "dir" THEN hi = 0: GOTO dir IF e$ = "" OR LEN(e$) = 2 THEN s2 = 0: n$ = "": CLS : GOTO 12 ELSE 12 END IF IF e$ = "?" THEN 430 IF ASC(e$) = 27 THEN IF hi = 1 THEN hi = 0 ELSE hi = 1 GOTO 12 END IF IF ASC(RIGHT$(e$, 1)) = 45 AND LEN(e$) = 2 THEN 400 IF e$ = "`" THEN CLS : LOCATE 10, 1 PRINT "Enter the characters to include, with an * or "; CHR$(96); INPUT ": ", fi$ IF fi$ <> "" THEN fi = LEN(fi$) - 1 IF LEFT$(fi$, 1) = "*" OR LEFT$(fi$, 1) = "`" THEN fi = fi * -1: fi$ = RIGHT$(fi$, fi) ELSE a$ = RIGHT$(fi$, 1) IF a$ <> "*" AND a$ <> "`" THEN fi = fi + 1 ELSE fi$ = LEFT$(fi$, fi) END IF ELSE IF fi = 1 THEN fi = 0 ELSE fi = 1: fi = -4: fi$ = ".TXT" END IF IF hi = 1 THEN 14 ELSE 13 END IF IF hi = 1 THEN IF na = 3 THEN ERASE c$, m$: GOTO 12 IF na = 2 THEN CLS : LOCATE 13, 10: PRINT "**** Enter a Name:"; : e$ = INPUT$(1) IF ASC(e$) = 13 THEN 12 ELSE nw = 1 END IF IF na <> 2 AND na <> 3 THEN IF na = 1 THEN adr = 1: hi = 0: GOTO 400 c = 2: p = 1 23 IF LEFT$(a$, 1) = " " THEN a$ = RIGHT$(a$, LEN(a$) - 1): GOTO 23 24 IF RIGHT$(a$, 1) = " " THEN a$ = LEFT$(a$, LEN(a$) - 1): GOTO 24 IF d = -29 THEN n$ = a$: GOTO colo IF d = -28 THEN d = 0: IF na > 1 THEN KILL a$: na = na - 1: s2 = 0: GOTO 13 n$ = a$: IF a$ = "" THEN 12 ELSE 25 END IF END IF IF ASC(e$) = 0 THEN e$ = LEFT$(i$, 1) PRINT e$; : x = 0: n$ = e$ WHILE x <> 13 a$ = INPUT$(1) IF a$ = "]" THEN a$ = CHR$(13): pg = 700 x = ASC(a$) IF x <> 8 THEN IF x = 0 THEN a$ = MID$(i$, LEN(n$) + 1, 1) IF x <> 13 THEN n$ = n$ + a$ PRINT a$; ELSE LOCATE CSRLIN, POS(0) - 1: PRINT " "; : LOCATE CSRLIN, POS(0) - 1 IF LEN(n$) = 1 THEN n$ = "": GOTO 22 n$ = LEFT$(n$, LEN(n$) - 1) END IF WEND IF RIGHT$(n$, 1) = "\" THEN adr = 0: n$ = LEFT$(n$, LEN(n$) - 1) END IF IF LCASE$(n$) = "con" THEN n$ = "co": PRINT "renamed to `co':" 25 IF j$ <> n$ THEN p = 1: s = 0: s2 = 1: c3 = 2: pg = 0: e = 0 IF c < 2 THEN c = 2 26 ERASE l$: d1 = 1: p3 = 1: xp = 1300: j$ = "": m = 80 IF n$ = "" THEN 12 IF e$ = "]" THEN CLS : LOCATE 13, 20: INPUT "Reload at what line number"; pg: pg = pg - 1 IF pg < 0 THEN pg = 0 END IF IF pg = 0 AND e = 0 THEN CLS : LOCATE 13, 26: PRINT "Loading "; n$; ELSE LOCATE 1, 12: PRINT "Loading "; n$; " after line "; pg; END IF OPEN n$ FOR INPUT AS #1: a$ = "": lode = 1: n2$ = "": x = 0 30 IF NOT EOF(1) THEN LINE INPUT #1, a$ IF p3 / 30 = INT(p3 / 30) THEN LOCATE 1, 52: PRINT p3; "lines "; IF p3 > pg THEN b$ = LEFT$(a$, 2) IF LEN(a$) > 60 AND b$ = " " THEN IF y > 60 THEN m = 80 END IF IF LEN(a$) < 60 AND b$ <> " " THEN IF y > 0 AND y < 60 THEN m = 80 y = LEN(a$) ELSE y = 0 END IF IF x < 2 AND LEN(a$) > 2 THEN x = x + 1: IF b$ = " " THEN m = 78 END IF IF RIGHT$(a$, 1) <> " " THEN a$ = a$ + " " 35 IF LEN(a$) > 3 THEN IF RIGHT$(a$, 2) = " " THEN a$ = LEFT$(a$, LEN(a$) - 1): GOTO 35 END IF xp = FRE(a$) IF d1 > 1590 THEN xp = 590: CLOSE : GOTO 40 l$(d1) = a$: b$ = "": b$ = INKEY$ IF b$ <> "" AND d1 > 30 THEN b = ASC(RIGHT$(b$, 1)) IF b = 72 OR b = 73 THEN e = e - ii + 1 ELSE e = e + ii - 1 END IF IF b$ <> "" OR (d1 = 30 AND (e = 0 OR j$ = n$)) THEN GOSUB 50 d1 = d1 + 1: IF LEN(a$) > 78 THEN m = 80 END IF p3 = p3 + 1 IF NOT EOF(1) AND xp > 1200 THEN 30 IF d1 < 400 THEN xe = 100 CLOSE 40 a$ = " *** End of File *** ": p3 = 1: j$ = "" IF l$(d1 - 1) <> a$ THEN l$(d1) = a$: ELSE d1 = d1 - 1 d1 = d1 + 1: lode = 0 50 CLS : IF e < 0 THEN e = 0 55 IF ii = 23 THEN PRINT IF LEN(l$(d1 - 2)) < 3 AND d1 > 3 THEN a = d1 - 1 FOR d = a - 1 TO 3 STEP -1 IF l$(d) = " " OR l$(d) = " " THEN l$(d) = "" IF l$(d) = "" THEN d1 = d1 - 1 IF LEN(l$(d)) > 0 THEN d = 3 NEXT IF d1 - 1 < a THEN l$(d1 - 1) = l$(a): l$(a) = "" END IF a = INT(23 / ii) FOR d = 1 TO ii LOCATE d + a, 1 PRINT LEFT$(l$(d + e), 78 + rd); IF rd = 0 AND LEN(l$(e + d)) > 78 THEN PRINT "$"; NEXT d s = 0: IF lode = 1 THEN RETURN ELSE 185 100 b$ = INKEY$ IF ts = 1 AND ec = 0 THEN LOCATE 25, 25 + (rd * 35): a$ = LEFT$(TIME$, 5) a = VAL(LEFT$(a$, 2)) IF a > 12 THEN a$ = RIGHT$(STR$(a - 12) + RIGHT$(a$, 3), 5) PRINT a$; : LOCATE c, p END IF IF s2 < 50 THEN tmr = TIMER IF TIMER - tmr > 300 AND tm = 1 THEN 196 IF rd = 0 THEN COLOR bp, co: PRINT i$; : LOCATE c, p: COLOR co, bp IF b$ = "" THEN 100 PRINT i$; : LOCATE c, p IF b = 60 AND f = 0 THEN x = -4000 ELSE x = 0 110 b = ASC(RIGHT$(b$, 1)): f = ASC(LEFT$(b$, 1)) IF ac = 1 THEN CLS : LOCATE 5, 5: i$ = b$ PRINT " "; f, b, "Length:"; LEN(b$); " "; ">"; i$; "<" IF f = 0 AND b = 30 THEN ac = 0: GOTO 50 ELSE GOTO 100 END IF IF xp < 1201 AND (f > 30) AND rd = 0 THEN LOCATE 1, 20: PRINT "No memory for editing"; : GOTO 100 END IF p3 = p: p = POS(0): c3 = c: c = CSRLIN IF rd = 1 AND b$ = "`" THEN SYSTEM IF b = 11 THEN b = 25 IF b = 16 OR (f = 0 AND b = 68) THEN 111 OPEN "lpt1:" FOR OUTPUT AS #1 IF ec = bc THEN x = d1 - 2 ELSE x = ec 112 FOR d = bc TO x: PRINT #1, l$(d): NEXT CLOSE : b = 0 END IF IF b = 12 OR (f = 23 AND b = 23) THEN IF g > 0 THEN LOCATE 25, 22: PRINT ", Searching"; SPACE$(21); : GOTO 117 ELSE b = 17: f = 17 END IF END IF IF b = 30 AND f = 30 THEN f = 0: b = 65: ec = d1 - 2 IF b = 17 AND f = 17 THEN f = 0: b = 61 IF b = 9 AND p < 68 THEN p = p + 10 IF b = 20 AND f = 20 THEN IF ts = 1 THEN ts = 0 ELSE ts = 1 IF f = 0 THEN IF b = 44 THEN OPEN "!" + LEFT$(n$, 7) FOR APPEND AS #1 PRINT #1, l$(e + c - 1) PRINT " "; CHR$(175); " "; : LOCATE c, p CLOSE : GOTO 100 END IF IF b = 49 AND rd = 1 THEN IF ii = 24 THEN ii = 25 ELSE ii = 24 GOTO 50 END IF IF b = 59 THEN CLS PRINT "Enter address or nothing for default addressee or a single "; INPUT "letter to abort: ", jk$ IF LEN(jk$) < 4 THEN 50 IF jk$ <> "" THEN CLOSE OPEN "script" FOR INPUT AS #1 OPEN "7" FOR OUTPUT AS #2 FOR d = 1 TO 17 LINE INPUT #1, a$ IF d = 10 THEN a$ = "output /usr/lib/sendmail " + jk$ + " < 7\13" PRINT #2, a$ NEXT d CLOSE KILL "script": NAME "7" AS "script" END IF SHELL "copy " + n$ + " 7" SHELL "k.bat" SHELL "del 7" GOTO 50 END IF IF b = 110 THEN e$ = "]": GOTO 25 IF b = 112 THEN IF n2$ = "" THEN CLS : LOCATE 4, 10: INPUT "Backup filename: ", n2$ SHELL "copy " + n$ + " " + n2$: GOTO 50 END IF IF b = 111 THEN ec = 0: bc = 0 IF b = 38 THEN CLS : INPUT " Lower case (l) or Shift left # of spaces (#)"; i$ OPEN n$ FOR INPUT AS #1: a$ = "!" + LEFT$(n$, 7) OPEN a$ FOR OUTPUT AS #2 IF xp < 1201 THEN PRINT "More than"; ELSE PRINT " "; PRINT d1; "lines": a = 0 WHILE NOT EOF(1) LINE INPUT #1, b$: d = 1: x = VAL(i$): a = a + 1 IF x > 0 THEN IF LEN(b$) > x THEN b$ = RIGHT$(b$, LEN(b$) - x) ELSE DO WHILE d < LEN(b$) + 1 e$ = MID$(b$, d, 1) IF q = 0 OR d > 1 THEN IF e$ = "." THEN d = d + 3 ELSE MID$(b$, d, 1) = LCASE$(e$) END IF d = d + 1 LOOP IF e$ = "." THEN q = 1 ELSE q = 0 END IF PRINT #2, b$: IF INT(a) / 30 = a / 30 THEN LOCATE 2, 25: PRINT " "; a WEND CLOSE : n$ = a$: CLS : GOTO 25 END IF IF b = 20 THEN LOCATE 1, 26: PRINT "Five minute autosave turned "; IF tm = 0 THEN tm = 1: PRINT "on " ELSE tm = 0: PRINT "off" LOCATE c, p: GOTO 100 END IF IF b > 119 AND b < 130 THEN 120 IF b = 48 THEN 500 colo: IF b = 47 THEN IF co = 14 THEN co = 7 ELSE co = 14 COLOR co, bp: IF d = -29 THEN d = 0: GOTO 13 ELSE 50 END IF IF b = 99 THEN IF fi = 1 THEN fi = 0 ELSE fi = 1 b = 64 END IF IF b = 117 OR b = 119 THEN i$ = "": d = 118 - b: x = e + c - 1 WHILE i$ <> " " IF p + d > 0 AND p < LEN(l$(x)) THEN p = p + d: i$ = MID$(l$(x), p, 1) ELSE i$ = " " END IF WEND END IF IF b = 37 THEN CLS : SHELL "k.bat": nw = 2: GOTO 50 IF b = 68 THEN GOTO 111 IF b = 36 THEN CLS : LOCATE 10, 30: PRINT "Resetting margin to"; m; ", on"; d1 - 2; "lines" PRINT : PRINT " line number:"; s2 = s2 + 1: e = 0: c = 2: p = 1: s = 36 WHILE e + 1 < d1 IF LEFT$(l$(e + 1), 2) = " " AND LEFT$(l$(e + 2), 1) <> " " THEN e = e + 1: p = 1: b = 8: c = 2: GOSUB 133 PRINT d4; : e = d4 - 2 END IF e = e + 1 WEND c = 2: p = 1: e = 0: GOTO 50 END IF IF b = 23 THEN 420 IF b = 33 OR b = 64 THEN e = 0: a$ = "": IF s2 = 1 OR xp < 1201 THEN n$ = "": CLS : GOTO 12 ELSE s = 2: GOTO 300 END IF IF b = 30 THEN b$ = " ": ac = 1: GOTO 110 IF b = 17 THEN IF rd = 0 THEN rd = 1: ii = 24 ELSE rd = 0: ii = 23 GOTO 50 END IF IF b = 65 THEN bc = c + e - 1: IF ec < bc THEN ec = bc + 1 IF b = 66 THEN ec = c + e - 1: IF ec < bc THEN bc = ec - 1 IF b = 46 THEN copy: fl = 0 IF ec - bc + d1 < 700 THEN IF b = 25 THEN a = d4 ELSE a = ec FOR d = bc TO a t$(d - bc + 1) = l$(d): fl = fl + 1 NEXT ELSE OPEN "copy!" FOR OUTPUT AS #2 FOR d = bc TO ec PRINT #2, l$(d): fl = fl + 1 NEXT CLOSE 2 END IF IF b = 25 THEN RETURN END IF IF b = 25 THEN d1 = d1 + fl FOR d = d1 TO c + e + fl - 1 STEP -1 IF d < 850 THEN l$(d) = l$(d - fl) NEXT 114 IF t$(1) <> "" THEN FOR d = c + e - 1 TO c + e + fl - 2 l$(d) = t$(d - c - e + 2): t$(d - c - e + 2) = "" NEXT ELSE OPEN "copy!" FOR INPUT AS #2 FOR d = c + e - 1 TO c + e + fl - 2 LINE INPUT #2, a$: l$(d) = a$ NEXT CLOSE 2 END IF s2 = s2 + 1 c = 15 e = d - 14: IF e < 0 THEN e = 0: c = d GOTO 50 END IF IF b = 19 THEN FOR x = 1 TO 3 LOCATE x, 1: PRINT SPACE$(80); NEXT LOCATE 2, 1 PRINT "***** Enter a new name for "; n$; " or nothing to cancel: "; LOCATE CSRLIN, POS(0) - 11 INPUT "; ", a$ IF a$ <> "" THEN NAME n$ AS a$: n$ = a$ ELSE IF d = -29 THEN d = 0: GOTO 13 ELSE 50 END IF IF na > 3 THEN y = INT((na - 1) / 20) MID$(c$(y + 1), (na - y * 20) * 12 - 11, 12) = a$ + SPACE$(12 - LEN(a$)) END IF IF d = -29 THEN d = 0: GOTO 13 ELSE 50 END IF IF b = 61 THEN d4 = c + e - 1: LOCATE 1, 1: INPUT " Find: ", a$: IF a$ = "" THEN 50 a$ = UCASE$(a$) LOCATE 25, 20: PRINT "Searching"; SPACE$(25); v = LEN(a$): w = 0: g = 0 115 u = ABS(w) 116 u = u + 1 117 g = g + 1 IF g < 1 + LEN(l$(u)) THEN IF UCASE$(MID$(l$(u), g, v)) = a$ THEN p = g: e = u - 15: c = 16 IF e < 0 THEN c = 16 + e: e = 0 GOTO 50 END IF END IF IF g < LEN(l$(u)) - v THEN 117 ELSE g = 0 IF u < d1 + 1 THEN 116 w = u * -1: GOTO 50 END IF IF b = 118 THEN p = LEN(l$(d1 - 2)): c = 20: e = d1 - 21 IF c > d1 THEN c = d1 - 1 IF e < 0 THEN e = 0 GOTO 130 END IF IF b = 132 THEN p = 1: c = 2: e = 0: GOTO 130 IF b = 83 THEN b = -83 IF b = 60 AND x = -4000 THEN LOCATE 1, 1: b = 0 PRINT "F7: Mark/F8: Endmark/ALT-F7: Markzero/ ALT-c: Copy/ALT-p: Paste/"; PRINT " CTRL-PgDn: Last"; LOCATE 25, 1 PRINT "F2: Commands/ ALT-j: Justify/"; PRINT " ALT-i: Instr/ALT-h: xHTML/ALT-l: Lcase/ALT-w: Read"; LOCATE c, p: GOTO 100 END IF IF b = 60 THEN LOCATE 1, 1 PRINT "F6: New /ALT-x: Quit /F9: Save /F4: Margin/"; PRINT " ALT-r: rename/ALT-d: Delete/F5: DOS "; LOCATE 25, 1 PRINT "F2: Commands/ CTRL-y: Cut/ CTRL-u: Uncut/"; PRINT " F10: Print/ F3: Search/ CTRL-l: again"; LOCATE c, p: GOTO 100 END IF IF b = 62 OR b = 50 THEN LOCATE 1, 1: PRINT SPACE$(80); LOCATE 1, 1: INPUT "How many spaces over shall the margin be"; a$ x = VAL(a$): IF x > 10 AND x < 81 THEN m = x: ELSE m = 80 END IF IF b = 35 THEN 230 IF b = 63 THEN CLS : PRINT "Type `exit' to return to the editor.": 119 SHELL "command /k dir/w" GOTO 50 END IF IF b = 31 OR b = 67 THEN s = 1: IF xp > 600 THEN 310 ELSE 300 IF b = 32 THEN LOCATE 2, 1: PRINT SPACE$(80); LOCATE 3, 1: PRINT SPACE$(80); LOCATE 1, 1: PRINT SPACE$(80); : LOCATE 2, 1 PRINT " ****** Delete "; n$; " (y/n)? ******"; j$ = INPUT$(1) IF j$ = "y" THEN CLOSE : KILL n$ IF na > 1 THEN na = na - 1 s2 = 0: e = 0: n$ = "": CLS : GOTO 12 ELSE GOTO 50 END IF END IF IF b = 45 THEN 300 IF b = 73 OR (rd = 1 AND b = 72) THEN IF e = 0 THEN IF pg > 0 THEN pg = pg - xe: e = xe IF pg < 80 THEN e = e + pg: pg = 0 GOTO 26 END IF c = 2: p = 1 END IF IF e > 0 THEN e = e - ii + 1: IF e < 0 THEN e = 0 GOTO 50 END IF IF b = 81 OR (rd = 1 AND b = 80) THEN IF e < d1 - 22 THEN e = e + ii - 1 ELSE IF xp < 1201 THEN pg = pg + d1 - 75: e = e + 75 - d1: GOTO 26 c = 24: p = LEN(l$(d1 - 2)): IF p = 0 THEN p = 1 END IF GOTO 50 END IF IF b = 21 THEN b = 25: f = 25: GOTO 120 IF b = 22 THEN b = 21: f = 21: GOTO 120 GOTO 133 END IF REM *** Carriage Return or Line Delete *** 120 IF rd = 1 THEN IF (b > 47 AND b < 58) OR f = 0 THEN c = 2: a = INT(((e / ii) + 1.35) / 10) * 10 e = ii * (b - 49 + a): IF e < 0 THEN e = 207 IF e > d1 - 3 THEN e = d1 - 15 GOTO 50 END IF b = 81: GOTO colo: END IF IF b = 13 OR b = 25 OR b = 21 OR b = 0 THEN s2 = s2 + 1 IF b = 13 THEN d4 = c + e - 1: h$ = l$(d4) IF p > LEN(h$) THEN g$ = " " ELSE l$(d4) = LEFT$(h$, p - 1): g$ = RIGHT$(h$, LEN(h$) - p + 1) END IF IF RIGHT$(l$(d4), 1) <> " " THEN l$(d4) = l$(d4) + " " END IF IF r2 = 0 AND b <> 25 THEN d1 = d1 + 1: IF c + e > d1 THEN d1 = e + c END IF IF b = 21 THEN c = c - 1 IF k > 1 THEN k = k - 1: g$ = k$(k): k$(k) = "" ELSE g$ = " " END IF IF b = 25 THEN d4 = c + e - 1 IF r2 = 0 THEN k$(k) = l$(d4): k = k + 1 IF k > 21 THEN FOR d = 1 TO 20 k$(d) = k$(d + 1) NEXT k = 21 END IF IF bc = ec AND d4 > bc AND bc <> 0 THEN GOSUB copy x = d4 - bc + 1 ELSE x = 1 END IF FOR d = d4 - x + 1 TO d1 l$(d) = l$(d + x) NEXT l$(d1 + 1) = "" d1 = d1 - x e = e - x + 1: IF e < 0 THEN c = c + e: e = 0: IF c < 2 THEN c = 2 IF s = 36 THEN RETURN ELSE IF r2 = 0 THEN FOR d = e + c TO d1 h$ = g$: g$ = l$(d): l$(d) = h$ NEXT c = c + 1 END IF END IF IF c = 25 THEN c = 24: e = e + 1 IF r2 = 0 THEN p = 1 130 CLS : PRINT a = INT(23 / ii) FOR d = 1 TO ii LOCATE d + a, 1 PRINT LEFT$(l$(d + e), 78 + rd); IF rd = 0 AND LEN(l$(e + d)) > 78 THEN PRINT "$"; NEXT d x = 0: IF r2 = 1 AND b = 25 THEN c = c - 1 IF b <> 13 THEN IF c > ii THEN e = e + 11: c = c - 11: GOTO 50 ELSE 185 END IF IF LEFT$(l$(c + e), 2) <> " " AND m <> 80 AND l$(c + e) <> "" THEN c = c + 1: b = 8: p = 1: b2 = -1 END IF END IF REM *** Adding or deleting a character *** 133 IF f > 31 OR b = 8 OR b = -83 THEN d4 = e + c - 1: s2 = s2 + 1 134 IF RIGHT$(l$(d4), 2) = " " THEN l$(d4) = LEFT$(l$(d4), LEN(l$(d4)) - 1): GOTO 134 END IF IF e + c > d1 THEN d1 = e + c IF b = 8 THEN b$ = "": n = 1: n2 = 0: r2 = 1 IF p = 1 THEN c = c - 1: d4 = e + c - 1: p = LEN(l$(d4)) + 1 h$ = l$(d4) + l$(d4 + 1): x = LEN(h$) l$(d4) = h$ IF x > m - 2 AND m <> 80 THEN p = p + 1: l$(d4 + 1) = "": GOTO 135 ELSE c = c + 1: b = 25 END IF GOTO 120 END IF ELSE IF b = -83 THEN b$ = "": n2 = 1 IF LEN(l$(d4)) < p THEN l$(d4) = l$(d4) + l$(d4 + 1) FOR d = d4 + 1 TO d1 l$(d) = l$(d + 1) NEXT d1 = d1 - 1: n2 = 0 END IF ELSE PRINT b$; : n2 = 0 END IF n = 0 END IF g$ = l$(d4): h$ = LEFT$(g$ + SPACE$(p), p - n - 1) + b$ IF LEN(h$) + n2 < 1 + LEN(g$) THEN h$ = h$ + MID$(g$, p + n2, 80): o = 0 ELSE IF p > m - 2 THEN o = -1: IF f > 31 THEN c = c + 1 ELSE o = 0 END IF END IF l$(d4) = h$ 135 IF LEN(h$) > m - 2 AND m <> 80 THEN 140 h$ = l$(d4): LOCATE 20, 1 FOR d = LEN(h$) - 1 TO 1 STEP -1 x$ = MID$(h$, d, 1) IF x$ = " " OR (f > 31 AND d = p AND o = 0) THEN p1 = d: IF p1 < m THEN d = 1 END IF NEXT g$ = RIGHT$(h$, LEN(h$) - p1): l$(d4) = LEFT$(h$, p1) IF o = -1 THEN o = LEN(g$) + 1 IF f > 31 THEN f = 30 IF d4 - e < 24 AND s <> 36 THEN LOCATE d4 - e + 1, 1: PRINT SPACE$(m); LOCATE d4 - e + 1, 1: PRINT LEFT$(l$(d4), m); ; END IF d4 = d4 + 1 IF LEFT$(l$(d4), 2) = " " OR m = 80 THEN IF m <> 80 OR b <> 8 THEN d1 = d1 + 1 FOR z = d1 TO d4 STEP -1 l$(z) = l$(z - 1) NEXT l$(d4) = "" END IF END IF l$(d4) = g$ + l$(d4) IF LEN(l$(d4)) > m - 1 THEN 140 x = -3: IF o > 0 OR c > d1 - 1 THEN p = p + 1: GOTO 130 142 IF LEFT$(l$(d4 + 1), 2) <> " " AND m <> 80 THEN l$(d4) = l$(d4) + l$(d4 + 1) FOR d = d4 + 1 TO d1 l$(d) = l$(d + 1) NEXT d1 = d1 - 1: IF LEN(l$(d4)) > m - 2 THEN 140 ELSE 142 END IF END IF IF b = -83 AND n2 = 0 THEN 50 IF s = 36 THEN RETURN 145 l$(d1 + 1) = "" IF b <> 8 AND b <> -83 THEN p = p + 1 ELSE IF b = 8 THEN p = p - 1 IF p = 0 THEN p = 1 IF x = -3 THEN 130 IF d4 - e < 24 AND s <> 36 THEN LOCATE d4 - e + 1, 1: PRINT SPACE$(m); LOCATE d4 - e + 1, 1: PRINT LEFT$(l$(d4), 78); IF LEN(l$(d4)) > 78 THEN PRINT "$"; END IF END IF IF rd = 0 AND f = 0 THEN IF b = 77 THEN p = p + 1 IF b = 75 THEN IF p > 1 THEN p = p - 1 ELSE IF c > 2 OR e <> 0 THEN c = c - 1: p = 1 + LEN(l$(c + e - 1)) IF c = 1 THEN b = 72: c = 2: GOTO 133 END IF END IF END IF IF b = 80 THEN c = c + 1 IF e + c = d1 AND xp < 1201 THEN pg = pg + d1 - 75: e = e + 75 - d1: GOTO 26 END IF IF c = 25 THEN LOCATE 24, 80: PRINT " "; : PRINT " "; : LOCATE 24, 1 c = 24: e = e + 1: PRINT LEFT$(l$(e + 23), 78); IF LEN(l$(e + 23)) > 78 THEN PRINT "$"; LOCATE 1, 1: PRINT SPACE$(m); END IF END IF IF b = 72 THEN IF e + c < 3 AND pg > 0 THEN pg = pg - xe: e = xe IF pg < 80 THEN e = e + pg: pg = 0: IF e < 0 THEN e = 0 GOTO 26 END IF IF c > 2 THEN c = c - 1 ELSE CLS : PRINT : IF e > 0 THEN e = e - 1 a = INT(23 / ii) FOR d = 1 TO ii LOCATE d + a, 1 PRINT LEFT$(l$(d + e), 78); IF LEN(l$(e + d)) > 78 THEN PRINT "$"; NEXT END IF END IF IF b = 71 THEN IF p = 1 THEN c = c - 1: b = 79 ELSE p = 1 END IF IF b = 79 THEN p = LEN(l$(e + c - 1)) + 1 END IF 185 IF ii = 25 THEN 100 IF e + c + 1 > d1 THEN c = c - 1 IF d1 > 15 AND c < 4 THEN c = 10: e = d1 - 11: p = LEN(l$(d1 - 2)) + 1: GOTO 50 END IF GOTO 185 END IF IF b2 = -1 THEN p = 1: b2 = 0 IF o > 0 THEN p = 80 i$ = RIGHT$(" " + STR$(pg + c + e - 1), 4) IF ii = 24 THEN 189 LOCATE 1, 1: PRINT SPACE$(80); 186 IF m <> 80 THEN LOCATE 1, m: PRINT "M"; 187 LOCATE 1, 77: PRINT i$; IF p > m - 1 THEN IF o > 0 THEN p = o: o = 0 IF p > 79 THEN p = 79 IF c = 25 THEN c = 24: b = 80: GOTO 110 188 IF p3 < 1 OR p3 > 80 THEN p3 = 1 LOCATE 1, p3: PRINT " "; : LOCATE 1, p: PRINT CHR$(25); IF ga = 1 THEN LOCATE 1, 25: PRINT " *** Garbage Day *** "; IF f = 0 AND (b = 65 OR b = 66) AND ec = bc THEN LOCATE 1, 25: PRINT "Block delete is on"; END IF 189 IF rd = 0 THEN LOCATE 25, 1: IF bc <> ec OR bc = 0 THEN IF s2 > 1 OR d1 + c + e = 4 THEN IF s2 / 21 = INT(s2 / 21) THEN PRINT "Press F1 for commands"; ELSE PRINT s2 - 1; "characters"; TAB(22); END IF ELSE PRINT " The file is saved"; END IF ELSE PRINT "Block delete is on "; END IF PRINT SPACE$(59); IF w > -1 THEN LOCATE 25, 22 IF rd = 0 THEN IF bc > 0 THEN 190 PRINT RIGHT$(" , " + STR$(pg + bc), 6); "-"; 191 PRINT LEFT$(STR$(pg + ec) + " ", 6); ELSE PRINT SPACE$(13); END IF ELSE PRINT " Whole Pages "; END IF PRINT "< "; n$; " >"; TAB(57); pg + d1 - 2; "lines"; IF xp < 1201 THEN PRINT " (cut off)"; ELSE IF m = 80 THEN PRINT ", no margin"; ELSE PRINT ", paragraphs"; END IF ELSE IF w = -3 THEN LOCATE 1, 22 PRINT " ** Command.com failed ** " ELSE LOCATE 25, 22: PRINT " ** "; a$; " Not Found **"; END IF w = 1 END IF END IF 192 IF c3 > 25 OR c3 < 2 THEN c3 = 2 IF c > 25 OR c < 2 THEN c = 2 193 LOCATE c3, 80: PRINT " "; : LOCATE c, 80 PRINT CHR$(27); IF rd = 1 THEN LOCATE 25, 1 194 PRINT "Page"; CINT((e / 23) + 1.35); "of"; CINT((d1 / 23) + .65); PRINT SPACE$(17); TAB(34); "< "; n$; " > "; IF xp < 1201 THEN PRINT " Cut off "; LOCATE 25, 77: PRINT i$; END IF IF ga = 1 THEN LOCATE 25, 47: PRINT "!Garbage Day!"; r2 = 0: LOCATE c, p g$ = l$(c + e - 1) IF LEN(g$) < p THEN i$ = " " ELSE i$ = MID$(g$, p, 1) IF s2 > 1000 AND tm = 1 THEN 196 tmr = TIMER IF rd = 0 THEN s = 1: IF xp > 1200 THEN 310 ELSE 300 END IF GOTO 100 200 SELECT CASE ERR CASE 53 IF ERL = 21 THEN FILES: RESUME NEXT IF ERL = 400 OR ERL = 119 OR ERL = 22 OR ERL = 323 THEN RESUME NEXT IF ERL = 114 THEN RESUME 133 IF ERL = 12 OR ERL = 10 OR ERL = 400 THEN RESUME NEXT IF ERL = 320 THEN d = -29: RESUME NEXT CLOSE IF ERL = 26 THEN e = 0 IF adr = 0 THEN b = 123: RESUME find ELSE d1 = 2: RESUME 40 RESUME NEXT CASE 62 CLOSE IF ERL = 10 THEN RESUME 12 ELSE RESUME NEXT CASE ELSE IF ERL = 13 THEN PRINT "Wrong Command.com version": RESUME 410 IF ERL = 21 THEN FILES: RESUME NEXT IF ERL = 310 THEN LOCATE CSRLIN, 1: PRINT "n$: >"; n$; "<"; SPACE$(30); IF ERL = 119 THEN w = -3: RESUME 50 IF ERL = 30 THEN IF NOT EOF(1) THEN RESUME CLOSE IF ERL = 111 OR ERL = 112 THEN LOCATE 1, 20: PRINT "The printer is not responding."; : RESUME 100 END IF IF ERL = 10 THEN RESUME NEXT IF ero = ERL THEN RESUME 12 RESTORE WHILE x <> 76 READ x, a$: IF ERR = x THEN 225 WEND a$ = "an error": x = ERR 225 LOCATE 1, 1: PRINT SPACE$(80); : LOCATE 1, 1 PRINT "#"; x; " "; a$; " in line "; ERL PRINT SPACE$(78); CLOSE : a$ = INPUT$(1) IF ERL = 100 THEN RESUME 310 ELSE RESUME 50 END SELECT 230 h = 1: x = 0: CLS : IF xp < 1201 THEN a$ = "over" ELSE a$ = "" PRINT " Commencing change of HTML for "; a$; d1; " lines. " PRINT " Press 'q' to abort, 'l' to pause, enter any letter to reautomate." PRINT CLOSE : ERASE l$ OPEN n$ FOR INPUT AS #1 OPEN "out" FOR OUTPUT AS #2 240 LINE INPUT #1, b$: x = x + 1 d = 1 IF b$ = "" THEN 261 250 IF MID$(b$, d, 3) = "" THEN c$ = MID$(b$, d, 6): e$ = RIGHT$(c$, 3): g = d IF e$ = "51;" THEN c$ = "; " ELSE IF e$ = "46;" OR e$ = "45;" THEN c$ = "'" ELSE IF e$ = "33;" THEN c$ = " - " IF e$ = "47;" THEN c$ = "`" IF e$ = "48;" THEN c$ = "'" IF LEN(c$) = 6 THEN c$ = " " END IF END IF IF INKEY$ = "q" THEN CLOSE : GOTO 26 IF INKEY$ = "l" THEN h = 0 IF h = 0 THEN PRINT x; b$ b$ = LEFT$(b$, g - 1) + c$ + RIGHT$(b$, LEN(b$) - g - 5) IF h = 0 THEN PRINT b$; : INPUT " "; c$: IF c$ <> "" THEN h = 1 END IF IF d < LEN(b$) - 5 THEN d = d + 1: GOTO 250 261 PRINT #2, b$: IF x / 50 = INT(x / 50) THEN PRINT x; IF NOT EOF(1) THEN 240 CLOSE KILL n$ NAME "out" AS n$ GOTO 26 300 IF s2 = 1 THEN 390 305 LOCATE 4, 17: PRINT STRING$(50, "-"); LOCATE 5, 17: PRINT "|"; SPACE$(48); "|"; LOCATE 6, 17: PRINT "|"; SPACE$(48); "|"; LOCATE 6, 17: PRINT "|"; SPACE$(48); "|"; LOCATE 7, 17: PRINT "| Save changes (y/n)? |"; LOCATE 8, 17: PRINT "|"; SPACE$(48); "|"; LOCATE 9, 17: PRINT STRING$(50, "-"); LOCATE 7, 34: j$ = INPUT$(1) IF j$ = "n" THEN IF s = 8 THEN 430 ELSE IF s = 2 THEN 12 ELSE 390 310 LOCATE 25, 1: PRINT " Rewriting "; n$; SPACE$(20 - LEN(n$)); tmr = TIMER: IF nw = 1 THEN nw = 2 311 OPEN "t!mp" FOR OUTPUT AS #1 IF pg > 0 THEN 312 OPEN n$ FOR INPUT AS #2: p = 1 WHILE p < pg + 1 313 LINE INPUT #2, b$: PRINT #1, b$: p = p + 1 WEND p = 1 END IF FOR d = 1 TO d1 - 2 b$ = l$(d) 320 IF LEN(b$) > 3 AND RIGHT$(b$, 1) = " " THEN b$ = LEFT$(b$, LEN(b$) - 1): GOTO 320 END IF 322 PRINT #1, b$ NEXT CLOSE 323 KILL n$ 325 NAME "t!mp" AS n$ IF s = 8 THEN 430 IF s = 2 THEN d = 0: s2 = 0: n$ = "": CLS : GOTO 12 390 IF s = 1 THEN s2 = 1: IF d = -29 THEN s2 = 0: CLS : GOTO 13 ELSE 50 400 CLS : LOCATE 12, 15: PRINT "Closing EB.EXE" KILL "copy!" IF adr = 0 OR hi = 1 THEN OPEN "list" FOR OUTPUT AS #1: PRINT #1, hi - 354, pg, e, rd, c, n$: CLOSE END IF CLS 410 PRINT "Out of EB.EXE" SYSTEM 420 IF s2 > 1 THEN s = 8: GOTO 305 430 RESTORE 440: ERASE l$: m = 78: s = 0: d1 = 89: xp = 2000: n$ = "HELP" FOR d = 1 TO 88 READ l$(d) NEXT 431 GOTO 50 DATA 1 , "next w/o for", 2 , "syntax error" DATA 3 , "return without gosub", 4 , "out of data" DATA 5 , "illegal function call", 6 , "overflow (total too large)" DATA 7 , "out of memory", 8 , "label not defined" DATA 9 , "subscript out of range", 11 , "division by zero" DATA 13 , "type mismatch", 14 , "out of string space" DATA 16 , "string formula too complex", 17 , "cannot continue" DATA 18 , "function not defined", 19 , "no resume statement" DATA 20 , "resume w/o error", 24 , "device timeout", 25 , "device fault" DATA 26 , "for w/o next", 29 , "while w/o wend", 30 , "wend w/o while" DATA 33 , "duplicate label", 38 , "array not defined" DATA 51 , "internal error", 52 , "bad file number" DATA 53 , "file not found", 54 , "bad file mode" DATA 55 , "file already open", 57 , "device I/O error" DATA 58 , "file already exists", 61 , "disk full" DATA 62 , "input past end of file", 64 , "bad file name" DATA 67 , "too many files", 68 , "device unavailable" DATA 69 , "comm buffer overflow", 70 , "permission denied" DATA 71 , "disk not ready", 72 , "disk media error" DATA 73 , "feature unavailable", 74 , "rename across disks" DATA 75 , "path/file access error", 76 , "path not found" 440 DATA " " DATA " Instructions for EB.EXE" DATA " " DATA " " DATA " 'eb' at the DOS prompt starts the editor. The first screen presents" DATA "all the filenames in the current directory (or 'folder') and highlights the" DATA "'exit' command. The arrow keys move the highlight around. If you press a" DATA "letter key then the highlight jumps to a file beginning with that letter," DATA "if there is one. Press 'enter' to select what is highlighted. If you select" DATA "a filename then the screen will change to commence editing. The lower part" DATA "of the file list screen shows several commands." DATA " When the editting screen shows, as with these instructions, there are" DATA "two arrows; one at the screen top and one to the right, pointing to the" DATA "current cursor position. A number in the upper right corner declares the" DATA "line number that the cursor is on. The bottom of the screen has a remark" DATA "noting that the current file has not been changed since the last save, or" DATA "else the number of keystrokes since the last saving of the current file. To" DATA "the right of that is a space that the program uses to display cut & paste" DATA "line numbers and similiar things. Next is the name of the current file in" DATA "'< >'. To the right of the name is the total number of lines in the whole" DATA "file, a comma, and either the words 'paragraphs' or 'no margin'. If the" DATA "margin is set at 80 characters per line, or less than 11, then the editor" DATA "doesn't automatically justify paragraphs and the words 'no margin' will show" DATA "in the lower right corner. This is the setting in place when the program" DATA "loads a file that has a line more than 78 characters long. A computer screen" DATA "is 80 characters wide." DATA " Editting has no unusual tricks. The arrow keys move the cursor one" DATA "space at a time and 'HOME' and 'END' put it at the beginning or end of the" DATA "line. Tab gives eight spaces. Delete at the end of a line combines the" DATA "current line with the line below. Backspace at the beginning of a line" DATA "combines with the line above." DATA " Pressing the 'F2' key temporarily shows half of the possible command" DATA "keystrokes on the top and bottom lines. The top line shows the most common" DATA "ones. Most programs use these same keystroke commands. 'ALT' means hold" DATA "down the 'ALT' key while pressing the command letter. 'ALT-x' quits the" DATA "program entirely. 'F6' quits editting the present file and displays the" DATA "entry screen. Either way, if the current file has been changed then the" DATA "computer will prompt for whether or not to save the changes. 'ALT-s' (or" DATA "F9) saves the file but remains ready to continue editting the file. 'ALT-r'" DATA "requests to rename the file and 'ALT-d' requests to delete it and return to" DATA "the entry screen. 'ALT-m' (or F4) requests a change of the margin length." DATA "Entering any number greater than 10 and less than 79 sets the computer to" DATA "autojustify paragraphs, and if the number is less than 77 then an 'M' will" DATA "display on the screen top at the margin point. 'F5' evokes the DOS command" DATA "prompt until you enter the word exit on the command line." DATA " The lower line has six commands. The command 'CTRL-y' deletes the" DATA "current line into a buffer that holds ten lines that can be sequentially" DATA "undeleted with the command 'CTRL-u'. The Pico editor uses 'CTRL-k' instead" DATA "of 'CTRL-y' so that key does the same thing.'CTRL-p' or F10 prints the" DATA "current file (within what I call 'the marklines'). 'CTRL-q' or 'F3'" DATA "requests a search. The computer will prompt for a sequence of characters or" DATA "spaces. 'CTRL-l' (small 'L') gets the computer to look some more for the" DATA "same thing. 'F2' twice presents other commands." DATA " The second set of commands shown by 'F2' are less straightforward. 'F7'" DATA "and 'F8' set the marklines; the beginning and end of a file section to copy" DATA "or print. The part can be as big as the file (maximum 900 lines or so)." DATA "'ALT-c' evokes the copying into the buffer and 'ALT-p' puts the whole buffer" DATA "into the current file. You can load a new file to paste into. If you set the" DATA "marklines at the same line, then the lower left of the screen will warn that" DATA "'block delete is on'. If you then press 'CTRL-y' at a lower line then all" DATA "lines in between are cut out and copied into the buffer, erasing the" DATA "previous buffer material. 'ALT-F8' sets both marklines to zero. With them at" DATA "zero, the print command prints the whole file." DATA " 'CTRL' with the page down key puts the cursor at the last line of the" DATA "file and, with the page up key, the first line. 'ALT-j' justifies the file" DATA "to a new margin. 'ALT-h' cleans all of the. '__' HTML code out of" DATA "downloaded files to make them more readable. 'ALT-i' displays this" DATA "instruction file, saving the current file first. 'ALT-l' (small 'L') removes" DATA "excessive use of uppercase letters from a file. 'ALT-v' toggles two video" DATA "modes, for mono-chrome machines." DATA " Several more commands aren't shown. 'ALT-a' puts the computer onto a" DATA "screen that displays the character codes associated with each key, for use" DATA "in programing these commands. 'ALT-w' evokes reading mode, in which almost" DATA "any keystroke advances one screen, up arrow goes back one, and with 'ALT-n'," DATA "the total number of screens shows on the lower left. 'ALT-b' evokes a" DATA "printing sequence that makes book pages, printing both sides of the paper." DATA "'ALT-k' starts the Kermit modem program without exiting the editor. 'ALT-t'" DATA "toggles the five minute autosave, which is on when the editor first starts." DATA "'ALT-F9' saves a backup file copy. 'ALT-F7' reloads with a startline." DATA "'ALT-z' records the cursor line into a file with the a name preceded by '!'." DATA "'CTRL-t' puts the current time on the screen." DATA " If the file read into the editor is too big for the computer's memory" DATA "then the computer will take as much of it as it can and put a freeze on any" DATA "editting. When the end of the loaded segment is exceeded by the cursor then" DATA "the computer will load another portion of the file. The final section of" DATA "the file can be editted and the save command will preserve the entire file" DATA "with the changes." DATA " *** End of File *** " DATA " " DATA " " DATA " " DATA " " DATA " " 500 CLS : PRINT "Set the printer at one line below page top and press 'p'." PRINT "Press 'q' at any time to abort the printing."; e$ = INPUT$(1): IF e$ <> "p" THEN IF ASC(e$) < 30 THEN 500 ELSE 50 ERASE l$: OPEN n$ FOR INPUT AS #1 OPEN "lpt1:" FOR OUTPUT AS #2 OPEN "paeg2" FOR OUTPUT AS #3 w = 1 FOR x = 1 TO 2 540 IF x = 1 THEN PRINT #2, SPACE$(75); RIGHT$(" " + STR$(w), 3) ELSE PRINT #2, w END IF PRINT #2, : w = w + 2 FOR d = 1 TO 60 IF NOT EOF(1) THEN LINE INPUT #1, a$ e$ = INKEY$ IF e$ <> "" THEN WHILE e$ = i$ i$ = INPUT$(1) WEND END IF PRINT #2, LEFT$(a$, 78) ' IF LEN(a$) > 78 THEN PRINT #2, MID$(a$, 79, 78): d = d + 1 END IF NEXT PRINT #2, : PRINT #2, : PRINT #2, : PRINT #2, e$ = INKEY$ IF e$ <> "" THEN WHILE e$ = i$ i$ = INPUT$(1) WEND END IF IF i$ = "x" OR i$ = "q" THEN CLOSE : GOTO 25 IF x = 1 THEN FOR d = 1 TO 60 IF NOT EOF(1) THEN LINE INPUT #1, a$: PRINT #3, LEFT$(a$, 78) NEXT END IF IF NOT EOF(1) THEN 540 IF x = 1 THEN w = 2: CLOSE 1: CLOSE 3: OPEN "paeg2" FOR INPUT AS #1 PRINT : PRINT PRINT "Pull the paper out of the printer and reload the head of the stack." PRINT "Then press 'p' to continue or 'q' to abort the print." i$ = INPUT$(1): IF i$ = "x" OR i$ = "q" THEN CLOSE : GOTO 25 END IF NEXT CLOSE : KILL "paeg2" GOTO 25 END