TASWORD TWO PATCHED (AGAIN?)
When are people going to stop fooling around with Tasword? Probably never and more power to ’em. There are some very good ideas floating around from those who have a go at making a “good” program “better (?)”. I have taken some of them, added a few of my own and here is my patch which I call version 4.2.
1. This change is one that should have been in from the beginning. It simply reactivates the TS2040 printer after each return to the text file (Line 10) by POKING 26703,0:26704,5. These pokes are changed each time you select the wide printer mode.
2. I’ve included a word count which appears each time you call the STOP menu; it appears right after the edit line option. This code starts at 33100 and is 88 bytes long. More about this later.
3. There is an option for saving the AUTOSTART boot of this version; this assumes you have the Larken LKDOS (Line 9000).
4. Then I show a routine to allow for the changing of the text PAPER and INK colours to suit your taste and that of your monitor (Line 9100). This would seem like a one time facility but it takes a few tries to get your choice just right. For example, I used the following:
Area PAPER INK Text 0 7 L&R Margin 1 7 Bottom Screen Top Line 5 0 Bottom Screen Bottom Line 0 5 64 column Border 1 32 column Border 6
When you get it right, GO TO 9300 and SAVE your new version of taswo.C2.
5. The LOAD text option brings up the catalogue (CAT) of the LKDOS disk to remind you what texts are available so that you may LOAD the text of your choice. NOTE: The ENTER prompt in this program is INPUT LINE a$ which eliminates the quotes around the INPUT cursor. This neat trick prevents your accidentally EDITing out the quotes which usually messes up the INPUTing.
6. The PRINT OPTION menu will present you with the choice of setting the Line spacing (eg, double for draft copies,) the left margin and other regular options.
7. The SAVE routine at Line 1000 has been reworked to bring up the catalogue as for LOAD and the error traps have been simplified.
8. If you don’t have the code for wordcount (wrd.C2), here it is and load it to start at 33100 (814Ch).
814CH 00 82 00 00 00 B4 09 CD
8154H B0 81 C5 D5 E5 3E 00 01
815CH 00 01 11 00 00 2A 4C 81
8164H 7E FE 20 28 25 3E 40 B8
816CH 20 03 13 00 00 0E 01 3E
8174H 40 B8 20 02 06 00 04 7C
817CH FE CD 20 0B 7D FE 00 20
8184H 06 18 14 00 00 00 00 23
818CH 18 D6 3E 01 B8 28 04 B9
8194H 20 01 13 0E 00 18 D8 62
819CH 6B 22 51 81 E1 D1 C1 C9
9. To sum up: Type in the tasword listing and load your tasword code to address 54784 as usual. Then do the colour mod and save tasword code as taswo.C2 same address same length. Save wrd.C2. Save the Autostart. Then clear the 2068 and boot up tasword per LKDOS instructions. Best of luck!
10. Personally, I’m going to work on Version 4.3 which will eliminate the colour routine, the autostart SAVE and insert some new stuff.
Bob Mitchell
871112
1 REM Tasword Version 4.2 RH Mitchell
2 REM 871112
3
10 RANDOMIZE USR VAL "100": OPEN #4,"dd": POKE VAL "23658",NOT PI: POKE VAL "26703",NOT PI: POKE VAL "26704",VAL "5": PAPER VAL "7": INK VAL "9": BORDER VAL "7": CLS : LET a=USR VAL "64330": GO TO VAL "20"
15 POKE VAL "23609",VAL "2": CLEAR VAL "33099": RANDOMIZE USR 100: LOAD "wrd.C2"CODE : RANDOMIZE USR 100: LOAD "taswo.C2"CODE : CLS : LET a=USR VAL "59081": GO TO VAL "10"
20 CLS : LET fs=VAL "6000": LET th=VAL "31": LET a=VAL "64"*INT (a/VAL "64"+VAL "0.99"): IF a=NOT PI THEN GO TO VAL "3000"
25 PAPER NOT PI: INK VAL "7": BORDER NOT PI: CLS : GO SUB VAL "4000": RANDOMIZE USR VAL "33110": PRINT AT VAL "4",NOT PI;"print text";TAB th;"p"
28 PRINT '"save text";TAB th;"s"
30 PRINT '"load text";TAB th;"l"
40 PRINT '"edit text [";PEEK VAL "33105"+VAL "256"*PEEK VAL "33106";" words]";TAB th;"y"
50 PRINT '"save Tasword autostart";TAB th;"t"
60 PRINT '"modify colours";TAB th;"m"
70 PRINT AT VAL "20",VAL "11";"press key"
80 LET a$=INKEY$: IF a$="" THEN GO TO VAL "80"
90 LET i=NOT PI: LET b=CODE a$: IF b<VAL "97" THEN LET b=b+VAL "32"
110 IF b=VAL "115" THEN LET i=VAL "6"
120 IF b=VAL "108" THEN LET i=VAL "8"
130 IF b=VAL "112" THEN LET i=VAL "4"
140 IF b=VAL "121" THEN LET i=VAL "10"
150 IF b=VAL "116" THEN LET i=VAL "12"
160 IF b=VAL "109" THEN LET i=VAL "14"
180 IF i>NOT PI THEN PRINT AT i,VAL "31"; FLASH PI/PI;CHR$ b;: GO TO VAL "500"
190 GO TO VAL "80"
200: CLS : PRINT AT SGN PI,VAL "8";"PRINT OPTIONS"''"Defaults in ( ) New value";AT 21,0;"[ENTER]"
210 LET i=VAL "6": LET j0=VAL "23": PRINT AT i,VAL "0";"Line spacing? (1) ";TAB 22;: GO SUB fs: IF a$="" THEN LET a$="1"
211 PRINT a$
215 POKE VAL "62235",VAL a$
216 LET i=VAL "8": LET j0=VAL "23": PRINT AT i,VAL "0";"Left margin? (8) ";TAB 22;: GO SUB fs: IF a$="" THEN LET a$="8"
217 PRINT a$
218 POKE VAL "60927",VAL a$
220 LET i=VAL "10": PRINT AT i,NOT PI;"Start line? (1) ";TAB 22;: GO SUB fs: IF a$="" THEN LET a$="1"
221 PRINT a$
230 LET c=VAL "64"*(INT VAL a$-PI/PI): LET b=c+(VAL "33280"): LET x=VAL "60045": GO SUB VAL "950"
240 LET i=VAL "12": PRINT AT i,NOT PI;"Finish line? (last)";TAB 22;: GO SUB fs: IF a$="" THEN LET b=a-c: GO TO VAL "250"
241 PRINT a$
245 LET b=VAL "64"*INT VAL a$-c
250 RANDOMIZE USR VAL "59806": RANDOMIZE USR (PEEK VAL "62472"+VAL "256"*PEEK VAL "62473")
260 CLS : PRINT AT VAL "20",NOT PI;"Press 'q' to stop printing "
270 LET x=VAL "60049": GO SUB VAL "950"
275 LET c=PEEK VAL "62470": IF c<>NOT PI THEN LPRINT CHR$ c
280 RANDOMIZE USR VAL "60038"
285 LET c=PEEK VAL "62471": IF c<>NOT PI THEN LPRINT CHR$ c
290 RANDOMIZE USR VAL "59806": GO TO VAL "10"
500 PRINT AT VAL "20",NOT PI;"press the "; FLASH PI/PI;"ENTER"; FLASH NOT PI;" key to proceed";AT VAL "21",NOT PI;" press "; FLASH PI/PI;"c"; FLASH NOT PI;" to change the choice "
510 LET a$=INKEY$: IF a$="c" OR a$="C" THEN GO TO VAL "20"
520 IF CODE a$=VAL "13" THEN GO TO VAL "600"
530 GO TO VAL "510"
610 IF b=VAL "121" THEN CLS : GO TO VAL "10"
615 IF b=VAL "109" THEN CLS : GO TO VAL "9100"
620 IF b=VAL "115" THEN CLS : GO TO VAL "1000"
630 IF b=VAL "116" THEN CLS : GO TO 9000
640 IF b=VAL "108" THEN LET a=NOT PI: GO TO VAL "2000"
650 IF b=VAL "112" THEN GO TO VAL "200"
850 PRINT AT i,j;a$;PEEK x: GO SUB fs: IF a$<>"" THEN POKE x,VAL a$
860 RETURN
950 POKE x,b-VAL "256"*INT (b/VAL "256"): POKE (x+PI/PI),INT (b/VAL "256"): RETURN
1000 LET b=VAL "33280":CLS
1005 CLS : PRINT #4: CAT ".CT",: PRINT AT VAL "20",NOT PI;"name?(less the .CT)";AT VAL "21",NOT PI;"[ENTER]": LET i=VAL "10": LET j0=NOT PI: GO SUB fs
1010 IF LEN a$<SGN PI OR LEN a$>VAL "6" THEN CLS : PRINT AT VAL "12",NOT PI; INVERSE 1;"invalid name": GO TO VAL "1005"
1038 PRINT #4: SAVE a$+".CT"CODE b,a
1039 GO TO VAL "10"
2000 CLS : PRINT #4: CAT ".CT",: PRINT AT VAL "20",NOT PI;"name?(less the .CT)";AT VAL "21",NOT PI;"[ENTER]"
2010 LET j0=NOT PI: LET i=VAL "12": GO SUB fs
2030 LET b=VAL "33280"
2032 PRINT #4: LOAD a$+".CT"CODE
2045 GO TO VAL "10"
3000 FOR i=VAL "23296" TO VAL "23361": POKE i,VAL "32": NEXT i
3005 POKE VAL "23362",NOT PI
3010 PRINT AT VAL "8",NOT PI;"type word to be replaced / found"
3012 LET j0=NOT PI: LET i=VAL "10": GO SUB fs: IF a$="" THEN GO TO VAL "10"
3020 LET j=NOT PI: FOR i=PI/PI TO LEN a$: POKE VAL "23297"+i,CODE a$(i): IF a$(i)=" " THEN LET j=j+PI/PI
3021 NEXT i
3022 IF j<>NOT PI THEN CLS : PRINT AT VAL "12",NOT PI;"just a word - no spaces allowed": GO TO VAL "3000"
3025 POKE VAL "23297",LEN a$
3030 PRINT AT VAL "12",NOT PI;"with (just ENTER for find only)": LET i=VAL "14": GO SUB fs
3040 IF a$="" THEN POKE VAL "23362",PI/PI: GO TO VAL "3060"
3050 FOR i=PI/PI TO LEN a$: POKE VAL "23329"+i,CODE a$(i): NEXT i
3060 LET a=USR VAL "64955": LET a=USR VAL "64333": GO TO VAL "20"
4000 PRINT AT NOT PI,VAL "9";"Tasword Two";AT SGN PI,VAL "4";" Tasman Software 1983";AT VAL "2",VAL "3";"Version 4.2 R.H.Mitchell": RETURN
6000 INPUT LINE a$: RETURN
9000 CLEAR VAL "33099": PAPER NOT PI: INK NOT PI: BORDER NOT PI: CLS : RANDOMIZE USR VAL "102"
9020 GO TO VAL "15"
9100 CLS : INPUT "text area"'"paper ";paper: INPUT "ink ";ink: LET c=paper*VAL "8"+ink
9120 POKE VAL "58512",VAL "54": POKE VAL "58521",VAL "54": POKE VAL "58513",c: POKE VAL "58522",c
9130 INPUT "l & r margin area"'"paper ";paper: INPUT "ink ";ink: LET c=paper*VAL "8"+ink
9140 POKE VAL "58508",VAL "54": POKE VAL "58517",VAL "54": POKE VAL "58509",c: POKE VAL "58518",c
9150 INPUT "bottom screen area TOP line"'"paper ";paper: INPUT "ink ";ink: LET c=paper*VAL "8"+ink
9155 POKE VAL "59993",c
9160 INPUT "bottom screen area BOTTOM line"'"paper ";paper: INPUT "ink ";ink: LET c=paper*VAL "8"+ink
9165 POKE VAL "64570",c
9170 INPUT "64 col border colour ";b
9175 INPUT "32 col border colour ";b1
9180 POKE VAL "64516",b: POKE VAL "60641",b1
9200 GO TO VAL "10"
9300 PRINT #4: SAVE "taswo.C2"CODE 54784,10751
Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.