Home » Archimedes archive » Acorn User » AU 1997-10 A.adf » Extras » Apple][e/PD/BOB/ARMBOB/doc/!See/!RunImage
Apple][e/PD/BOB/ARMBOB/doc/!See/!RunImage
This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.
Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.
Tape/disk: | Home » Archimedes archive » Acorn User » AU 1997-10 A.adf » Extras |
Filename: | Apple][e/PD/BOB/ARMBOB/doc/!See/!RunImage |
Read OK: | ✔ |
File size: | 27FE bytes |
Load address: | 0000 |
Exec address: | 0000 |
File contents
10REM !See.!RunImage version 0.3 20REM 30REM LEN G.C.Wraith (24/07/96) 40REM 50REM Uses ZapRedraw module LEN Dominic Symes 1994 60 70REM Purpose: display fast scrolling active coloured text; 80REM execute commands by clicking on them. 90 100REM <<<<< shows parts depending on SeeFile syntax 110 120DIM mesg% 7 130DIM offset%(8) 140DIM winblock% 93 : REM window def at winblock%+4 150DIM pollbuf% 255 : REM wimp poll buffer 160DIM redraw% 255 : REM Zap redraw block 170DIM chars% 4095 180DIM bitmaps% &8000 190DIM palette% 63 200DIM title% 255 210DIM code% 429 : REM <<<<<<<<<<<< 220 230task%=0 240ON ERROR PROCerror 250 260filetype% = 0 270width% = 0 280 290SeeFiletype% = EVAL("&"+FNsysvar("Seetype")) 300IF SeeFiletype% < 0 OR SeeFiletype% > &FFF THEN 310 ERROR 100,"Set Seetype to a hex string between 0 and FFF" 320ENDIF 330 340arg$ = FNgetarg 350filebuf% = FNload(arg$,filetype%) 360PROCreadctrl:REM <<<<<<< 370 380REM Assemble decoding code 390FOR pass% = 0 TO 2 STEP 2 400 P% = code% 410 PROCasm 420NEXT 430 440inbuf%=FNdecode(filebuf%,width%):REM converts to ZapRender format 450 460PROCdefine_zap_variables 470redraw%!r_data=inbuf% 480redraw%!r_workarea=winblock% 490 500SYS "ZapRedraw_ReadSystemChars",chars%,redraw% 510SYS "OS_File",16,"<See$Dir>.ExtraChars",chars%+2048,0:REM load extra font 520 530REM nonexistent mode 540mode%=FNmode_change(-1) 550 560offset%() = 1,3,0,3,5,1,2,2,5 570 580!mesg% = &400C1:mesg%!4 = 0 590SYS "Wimp_Initialise",310,&4B534154,"See",mesg% TO ,task% 600quit%=FALSE 610 620$title% = arg$+CHR$0 630window% = FNcreate_window(title%,width%,!_nlines) 640 650REPEAT 660SYS "Wimp_Poll",&31,pollbuf% TO event%,data% 670CASE event% OF 680 WHEN 1:SYS "ZapRedraw_RedrawWindow",data%,redraw% 690 WHEN 2:SYS "Wimp_OpenWindow",0,data% 700 WHEN 3:quit%=TRUE 710 SYS "Wimp_GetPointerInfo",,pollbuf% 720 IF pollbuf%!8 = 1 THEN 730 OSCLI("Filer_OpenDir "+FNdir(arg$)) 740 ENDIF 750 WHEN 6: 760 IF data%!12 = window% AND data%!16 = -1 THEN 770 PROCclick(!data%,data%!4,data%!8) 780 ENDIF 790 WHEN 17,18:CASE data%!16 OF 800 WHEN 0:quit%=TRUE 810 WHEN &400C1:mode% = FNmode_change(mode%) 820 ENDCASE 830ENDCASE 840UNTIL quit% 850SYS "Wimp_CloseDown",task%,&4B534154 860END 870 880DEF FNload(arg$, RETURN filetype%) 890LOCAL type%,filebuf%,length% 900SYS "OS_File",23,arg$ TO type%,,,,length%,,filetype% 910IF type% <> 1 ERROR 100,arg$ + " is not a file" 920IF filetype% = &1000 OR filetype% = &2000 THEN 930 ERROR 100,arg$ + "is a directory" 940ENDIF 950filetype% = filetype% AND &FFF 960DIM filebuf% length% 970SYS "OS_File",16,arg$,filebuf%,0 : REM load source file 980filebuf%?length% = 0 : REM terminator 990= filebuf% 1000 1010REM get directory part of pathname 1020DEF FNdir(a$) 1030LOCAL len%,over%,p%,b$ 1040SYS "OS_FSControl",37,a$,0,0,0,0 TO ,,,,,len% 1050SYS "OS_FSControl",37,a$,pollbuf%,0,0,1-len% TO ,,,,,over% 1060IF over%<>1 ERROR 100,"Cannot canonicalize "+a$ 1070p% = pollbuf% 1080b$ = FNgetstring(p%) 1090WHILE RIGHT$(b$)<>"." 1100 b$ = LEFT$(b$) 1110ENDWHILE 1120= LEFT$(b$) 1130 1140REM read a system variable 1150DEF FNsysvar(A$) 1160LOCAL length% 1170SYS "XOS_ReadVarVal",A$,pollbuf%,-1,0 TO ,,length% 1180IF length%=0 THEN ERROR 100,A$+" not found" 1190SYS "XOS_ReadVarVal",A$,pollbuf%,255,0 TO ,,length% 1200pollbuf%?length%=13 1210=$pollbuf% 1220 1230 1240REM Get string terminated by control code, updating pointer 1250REM to beyond the terminator. 1260DEF FNgetstring(RETURN a%) 1270LOCAL a$,c% 1280a$ = "" 1290c% = ?a% 1300WHILE c% > 31 1310 a$ += CHR$(c%) 1320 a% += 1 1330 c% = ?a% 1340ENDWHILE 1350a% += 1 1360= a$ 1370 1380DEF FNgetarg 1390LOCAL command$,i%,arg$ 1400SYS "OS_GetEnv" TO command$ 1410i% = INSTR(command$,"!RunImage") 1420IF i%=0 ERROR 100,"!RunImage not found. Name changed?" 1430arg$ = MID$(command$,i%+10) 1440WHILE ASC(arg$)=32:arg$=MID$(arg$,2):ENDWHILE 1450IF arg$="" ERROR 100,"See needs an argument" 1460= arg$ 1470 1480DEF PROCdefine_zap_variables 1490r_flags = 0 :REM Redraw flags 1500r_bpp = 28 :REM log base 2 of bpp 1510r_charw = 32 :REM width of a character in pixs 1520r_charh = 36 :REM height of a character in pixs 1530r_caddr = 40 :REM cache address / font name 1540r_cbpl = 44 :REM bytes per cached line 1550r_cbpc = 48 :REM bytes per cached character 1560r_linesp = 52 :REM line spacing in pixels 1570r_data = 56 :REM address of data to print 1580r_palette = 68 :REM address of palette data 1590r_for = 72 :REM start forground colour 1600r_bac = 76 :REM start background colour 1610r_workarea = 80 :REM address of work area 1620ENDPROC 1630 1640DEF FNcreate_window(title%,width%,lines%) 1650LOCAL handle% 1660winblock%!4=100 1670winblock%!8=288 1680winblock%!12=1100 1690winblock%!16=800 1700winblock%!20=0 1710winblock%!24=0 1720winblock%!28=-1 1730winblock%!32=&FF000002 1740winblock%!36=&FF070207 1750winblock%!40=&000C0103 1760winblock%!44=0 1770winblock%!48=-(redraw%!r_charh + redraw%!r_linesp)*lines% 1780winblock%!52=2*(redraw%!r_charw)*width% 1790winblock%!56=0 1800winblock%!60=&2700613D 1810winblock%!64=3<<12 1820winblock%!68=0 1830winblock%!72=&10001 1840winblock%!76=title% 1850winblock%!80=0 1860winblock%!84=255 1870winblock%!88=0 1880SYS "Wimp_CreateWindow",0,winblock%+4 TO handle% 1890!winblock%=handle% 1900SYS "Wimp_OpenWindow",0,winblock% 1910= handle% 1920 1930DEF PROCclick(x%,y%,b%) 1940LOCAL char%,line% 1950!winblock% = window% 1960SYS "Wimp_GetWindowInfo",,winblock% 1970char% = (x%-winblock%!4+winblock%!44+winblock%!20)/(redraw%!r_charw)/2 1980line% = (winblock%!16+winblock%!56 - winblock%!24 - y%)/(redraw%!r_charh+redraw%!r_linesp)/4 1990CASE b% OF 2000 WHEN 4: IF filetype%=SeeFiletype% PROCselect(char%,line%) 2010 WHEN 1: PROCadjust(char%,line%) 2020ENDCASE 2030ENDPROC 2040 2050DEF FNstrip(A$) 2060WHILE ASC(A$) = 32 2070 A$ = MID$(A$,2) 2080ENDWHILE 2090= A$ 2100 2110DEF PROCadjust(c%,l%) 2120LOCAL s$ 2130s$ = FNstrip(FNline(c%,l%)) 2140IF ASC(s$) = ASC("*") THEN SYS "Wimp_StartTask",s$ 2150ENDPROC 2160 2170DEF PROCselect(c%,l%) 2180LOCAL s$ 2190s$ = FNstrip(FNline(c%,l%)) 2200IF ASC(s$) = ASC("*") THEN SYS "Wimp_StartTask",s$:quit% = TRUE 2210ENDPROC 2220 2230 2240DEF FNmode_change(mode%) 2250LOCAL a%,b%,F%,YEigFactor 2260IF MODE=mode% THEN =MODE 2270SYS "ZapRedraw_ReadVduVars",,redraw% 2280SYS "OS_ReadModeVariable",mode%,5 TO ,,YEigFactor 2290IF YEigFactor=1 redraw%!r_flags=2 ELSE redraw%!r_flags=0 2300:REM CHANGE TO 0 FOR SINGLE HEIGHT 2310redraw%!r_charw=8 2320redraw%!r_charh=8 2330redraw%!r_caddr=bitmaps% 2340SYS "ZapRedraw_CachedCharSize",redraw%!r_bpp,0,8,8 TO ,,a%,b% 2350redraw%!r_cbpl=a% 2360redraw%!r_cbpc=b% 2370redraw%!r_linesp=2 2380SYS "ZapRedraw_ConvertBitmap",,redraw%,32,511,chars% 2390redraw%!r_palette=palette% 2400FOR F%=0 TO 15:palette%!(4*F%)=F%:NEXT 2410SYS "ZapRedraw_CreatePalette",3,redraw%,palette%,palette%,16 2420redraw%!r_for=7:REM black 2430redraw%!r_bac=0:REM white 2440=MODE 2450 2460DEF PROCerror 2470IF task%=0 THEN PRINT REPORT$+" at line "+STR$ ERL+CHR$0:END 2480!winblock%=0 2490$(winblock%+4)=REPORT$+" at line "+STR$ ERL+CHR$0 2500SYS "Wimp_ReportError",winblock%,0,"See" 2510SYS "Wimp_CloseDown",task%,&4B534154 2520END 2530 2540DEF FNdecode(in%, RETURN width%) 2550LOCAL A%,B%,C%,nlines%,out%,size% 2560A% = in% 2570CALL _calc:REM How many newlines, how much space needed? 2580size% = !_size:nlines% = !_nlines 2590width% = !_width 2600DIM out% size% 2610!(out%+nlines%+4) = 0 2620B% = out%:C% = out% + nlines% +8 2630CALL _put:REM prepare for Zap format 2640= out% 2650 2660REM part of l%-th line containing c%-th character 2670DEF FNline(c%,l%) 2680LOCAL line%,i%,x%,a$ 2690IF 4*l%>=!_nlines THEN = "" 2700line% = inbuf% + (inbuf%!(4*l%)) 2710REPEAT 2720 a$ = FNgetstring(line%) 2730 c% -= LEN(a$) 2740 x% = ?line% 2750 IF x% < 9 THEN line% += offset%(x%) ELSE ERROR 100,"File corrupted" 2760 IF x% = 2 THEN c% = 0 2770UNTIL c% <= 0 2780=a$ 2790 2800DEF PROCreadctrl 2810REM Read Control characters <<<<<<<<<<<<<<< 2820LOCAL c% 2830CASE filetype% OF 2840 WHEN SeeFiletype%: 2850 comment% = ?filebuf% 2860 IF comment%<31 ERROR 100,"Bad comment character" 2870 changefont% = filebuf%?1 2880 IF changefont%<31 ERROR 100,"Bad changefont character" 2890 changefor% = filebuf%?2 2900 IF changefor%<31 ERROR 100,"Bad changeforeground character" 2910 changebac% = filebuf%?3 2920 IF changebac%<31 ERROR 100,"Bad changebackground character" 2930 filebuf% += 4 2940 c% = ?filebuf% 2950 WHILE c% <> 10 AND c% <> 0 2960 filebuf% += 1 2970 c% = ?filebuf% 2980 ENDWHILE 2990 IF ?filebuf% = 10 filebuf% += 1 3000 OTHERWISE: 3010 REM defaults for plain text 3020 comment% = 0 3030 changefont% = 0 3040 changefor% = 0 3050 changebac% = 0 3060ENDCASE 3070ENDPROC 3080 3090DEF PROCasm : REM <<<<<<<<<<<<<<< 3100[ OPT pass% 3110._put 3120 MOV R7,#0 3130 MOV R5,#0 3140 MOV R6,R2 3150 MOV R3,R0 3160 LDR R4,[R3] 3170.while 3180 CMP R4,#0 3190 MOVEQ PC,R14 3200 SUB R9,R6,R1 3210 STR R9,[R1,R5] 3220 ADD R5,R5,#4 3230.repeat 3240 LDRB R4,[R3],#1 3250 CMP R4,#0 3260 CMPNE R4,#10 3270 BEQ L10 3280 CMP R4,#changefont% 3290 BEQ L160 3300 CMP R4,#changefor% 3310 CMPNE R4,#changebac% 3320 BEQ Lpound 3330 CMP R4,#comment% 3340 BEQ Lcomm 3350 .other 3360 CMP R7,#0 3370 STREQB R4,[R6],#1 3380 BEQ repeat 3390 MOV R9,#0 3400 STRB R9,[R6],#1 3410 MOV R9,#3 3420 STRB R9,[R6],#1 3430 STRB R4,[R6],#1 3440 MOV R9,#1 3450 STRB R9,[R6],#1 3460 B repeat 3470 3480 .Lcomm 3490 LDRB R4,[R3],#1 3500 CMP R4,#0 3510 CMPNE R4,#10 3520 BNE Lcomm 3530 3540 .L10 3550 MOV R9,#0 3560 STRB R9,[R6],#1 3570 MOV R9,#2 3580 STRB R9,[R6],#1 3590 B while 3600 3610 .L160 3620 EOR R7,R7,#1 3630 MOV R9,#32 3640 STRB R9,[R6],#1 3650 B repeat 3660 3670 .Lpound 3680 LDRB R8,[R3] 3690 CMP R8,#&30 3700 BCC other 3710 CMP R8,#&3A 3720 SUBCC R8,R8,#&30 3730 BCC readout 3740 CMP R8,#&41 3750 BCC other 3760 CMP R8,#&47 3770 BCS other 3780 SUBCC R8,R8,#55 3790 3800 .readout 3810 ADD R3,R3,#1 3820 MOV R9,#0 3830 STRB R9,[R6],#1 3840 MOV R9,#6 3850 CMP R4,#changefor% 3860 ADDNE R9,R9,#1 3870 STRB R9,[R6],#1 3880 STRB R8,[R6],#1 3890 B repeat 3900 3910._size EQUD 0 3920._nlines EQUD 0 3930._width EQUD 0 3940.out 3950 CMP R6,R7 3960 MOVCS R7,R6 3970 ADD R5,R1,R3 3980 ADD R5,R5,#9 3990 STR R5,_size 4000 STR R1,_nlines 4010 STR R7,_width 4020 MOV PC,R14 4030._calc 4040 MOV R1,#0 4050 MOV R3,#0 4060 MOV R4,#0 4070 MOV R6,#0 ; width count 4080 MOV R7,#0 ; width max 4090 B loop 4100.endline 4110 ADD R1,R1,#4 4120 ADD R3,R3,#2 4130 CMP R6,R7 4140 MOVCS R7,R6 ; reset max 4150 MOV R6,#0 ; zero counter 4160.loop 4170 LDRB R2,[R0],#1 4180 CMP R2,#0 4190 BEQ out 4200 CMP R2,#10 4210 BEQ endline 4220 CMP R2,#changefont% 4230 EOREQ R4,R4,#1 4240 ADDEQ R3,R3,#1 4250 BEQ loop 4260 CMP R2,#changefor% 4270 CMPNE R2,#changebac% 4280 ADDEQ R3,R3,#3 4290 BEQ loop 4300 CMP R4,#0 4310 ADDEQ R3,R3,#1 4320 ADDNE R3,R3,#4 4330 ADD R6,R6,#1 4340 B loop 4350] 4360ENDPROC
� !See.!RunImage version 0.3 � � � G.C.Wraith (24/07/96) (� 20� Uses ZapRedraw module � Dominic Symes 1994 < F;� Purpose: display fast scrolling active coloured text; P4� execute commands by clicking on them. Z d3� <<<<< shows parts depending on SeeFile syntax n x � mesg% 7 �� offset%(8) �0� winblock% 93 : � window def at winblock%+4 �'� pollbuf% 255 : � wimp poll buffer �'� redraw% 255 : � Zap redraw block �� chars% 4095 �� bitmaps% &8000 �� palette% 63 �� title% 255 � � code% 429 : � <<<<<<<<<<<< � �task%=0 �� � �error � filetype% = 0 width% = 0 ",SeeFiletype% = �("&"+�sysvar("Seetype")) ,.� SeeFiletype% < 0 � SeeFiletype% > &FFF � 6; � 100,"Set Seetype to a hex string between 0 and FFF" @� J Targ$ = �getarg ^$filebuf% = �load(arg$,filetype%) h�readctrl:� <<<<<<< r |� Assemble decoding code �� pass% = 0 � 2 � 2 � P% = code% � �asm �� � �Binbuf%=�decode(filebuf%,width%):� converts to ZapRender format � ��define_zap_variables �redraw%!r_data=inbuf% � redraw%!r_workarea=winblock% � �1ș "ZapRedraw_ReadSystemChars",chars%,redraw% �Jș "OS_File",16,"<See$Dir>.ExtraChars",chars%+2048,0:� load extra font � nonexistent mode mode%=�mode_change(-1) & 0!offset%() = 1,3,0,3,5,1,2,2,5 : D!mesg% = &400C1:mesg%!4 = 0 N;ș "Wimp_Initialise",310,&4B534154,"See",mesg% � ,task% Xquit%=� b l$title% = arg$+�0 v4window% = �create_window(title%,width%,!_nlines) � �� �.ș "Wimp_Poll",&31,pollbuf% � event%,data% �Ȏ event% � �2 � 1:ș "ZapRedraw_RedrawWindow",data%,redraw% �% � 2:ș "Wimp_OpenWindow",0,data% � � 3:quit%=� �. ș "Wimp_GetPointerInfo",,pollbuf% � � pollbuf%!8 = 1 � �, �("Filer_OpenDir "+�dir(arg$)) � � � � 6: �, � data%!12 = window% � data%!16 = -1 � & �click(!data%,data%!4,data%!8) � � 17,18:Ȏ data%!16 � � 0:quit%=� *5 � &400C1:mode% = �mode_change(mode%) 4 � >� H� quit% R'ș "Wimp_CloseDown",task%,&4B534154 \� f p� �load(arg$, � filetype%) z� type%,filebuf%,length% �6ș "OS_File",23,arg$ � type%,,,,length%,,filetype% �.� type% <> 1 � 100,arg$ + " is not a file" �-� filetype% = &1000 � filetype% = &2000 � �" � 100,arg$ + "is a directory" �� � filetype% = filetype% � &FFF �� filebuf% length% �8ș "OS_File",16,arg$,filebuf%,0 : � load source file �'filebuf%?length% = 0 : � terminator �= filebuf% � �$� get directory part of pathname �� �dir(a$) � len%,over%,p%,b$ /ș "OS_FSControl",37,a$,0,0,0,0 � ,,,,,len% <ș "OS_FSControl",37,a$,pollbuf%,0,0,1-len% � ,,,,,over% $.� over%<>1 � 100,"Cannot canonicalize "+a$ .p% = pollbuf% 8b$ = �getstring(p%) Bȕ �b$)<>"." L b$ = �b$) V� ` = �b$) j t� read a system variable ~� �sysvar(A$) � � length% �4ș "XOS_ReadVarVal",A$,pollbuf%,-1,0 � ,,length% �'� length%=0 � � 100,A$+" not found" �5ș "XOS_ReadVarVal",A$,pollbuf%,255,0 � ,,length% �pollbuf%?length%=13 �=$pollbuf% � � �=� Get string terminated by control code, updating pointer �� to beyond the terminator. �� �getstring(� a%) �� a$,c% a$ = "" c% = ?a% ȕ c% > 31 a$ += �(c%) ( a% += 1 2 c% = ?a% <� Fa% += 1 P= a$ Z d � �getarg n� command$,i%,arg$ xș "OS_GetEnv" � command$ �i% = �command$,"!RunImage") �5� i%=0 � 100,"!RunImage not found. Name changed?" �arg$ = �command$,i%+10) �!ȕ �(arg$)=32:arg$=�arg$,2):� �+� arg$="" � 100,"See needs an argument" � = arg$ � �� �define_zap_variables �*r_flags = 0 :� Redraw flags �/r_bpp = 28 :� log base 2 of bpp �:r_charw = 32 :� width of a character in pixs �;r_charh = 36 :� height of a character in pixs �7r_caddr = 40 :� cache address / font name 3r_cbpl = 44 :� bytes per cached line 8r_cbpc = 48 :� bytes per cached character 4r_linesp = 52 :� line spacing in pixels "6r_data = 56 :� address of data to print ,5r_palette = 68 :� address of palette data 64r_for = 72 :� start forground colour @5r_bac = 76 :� start background colour J2r_workarea = 80 :� address of work area T� ^ h*� �create_window(title%,width%,lines%) r � handle% |winblock%!4=100 �winblock%!8=288 �winblock%!12=1100 �winblock%!16=800 �winblock%!20=0 �winblock%!24=0 �winblock%!28=-1 �winblock%!32=&FF000002 �winblock%!36=&FF070207 �winblock%!40=&000C0103 �winblock%!44=0 �=winblock%!48=-(redraw%!r_charh + redraw%!r_linesp)*lines% �+winblock%!52=2*(redraw%!r_charw)*width% �winblock%!56=0 winblock%!60=&2700613D winblock%!64=3<<12 winblock%!68=0 &winblock%!72=&10001 0winblock%!76=title% :winblock%!80=0 Dwinblock%!84=255 Nwinblock%!88=0 X2ș "Wimp_CreateWindow",0,winblock%+4 � handle% b!winblock%=handle% l$ș "Wimp_OpenWindow",0,winblock% v = handle% � �� �click(x%,y%,b%) �� char%,line% �!winblock% = window% �&ș "Wimp_GetWindowInfo",,winblock% �Jchar% = (x%-winblock%!4+winblock%!44+winblock%!20)/(redraw%!r_charw)/2 �`line% = (winblock%!16+winblock%!56 - winblock%!24 - y%)/(redraw%!r_charh+redraw%!r_linesp)/4 �Ȏ b% � �7 � 4: � filetype%=SeeFiletype% �select(char%,line%) � � 1: �adjust(char%,line%) �� �� � � �strip(A$) ȕ �(A$) = 32 A$ = �A$,2) � *= A$ 4 >� �adjust(c%,l%) H� s$ Rs$ = �strip(�line(c%,l%)) \-� �(s$) = �("*") � ș "Wimp_StartTask",s$ f� p z� �select(c%,l%) �� s$ �s$ = �strip(�line(c%,l%)) �7� �(s$) = �("*") � ș "Wimp_StartTask",s$:quit% = � �� � � �� �mode_change(mode%) �� a%,b%,F%,YEigFactor �� �=mode% � =� �'ș "ZapRedraw_ReadVduVars",,redraw% �3ș "OS_ReadModeVariable",mode%,5 � ,,YEigFactor �8� YEigFactor=1 redraw%!r_flags=2 � redraw%!r_flags=0 �$:� CHANGE TO 0 FOR SINGLE HEIGHT redraw%!r_charw=8 redraw%!r_charh=8 redraw%!r_caddr=bitmaps% $?ș "ZapRedraw_CachedCharSize",redraw%!r_bpp,0,8,8 � ,,a%,b% .redraw%!r_cbpl=a% 8redraw%!r_cbpc=b% Bredraw%!r_linesp=2 L7ș "ZapRedraw_ConvertBitmap",,redraw%,32,511,chars% Vredraw%!r_palette=palette% `$� F%=0 � 15:palette%!(4*F%)=F%:� j?ș "ZapRedraw_CreatePalette",3,redraw%,palette%,palette%,16 tredraw%!r_for=7:� black ~redraw%!r_bac=0:� white �=� � �� �error �)� task%=0 � � �$+" at line "+� �+�0:� �!winblock%=0 �($(winblock%+4)=�$+" at line "+� �+�0 �+ș "Wimp_ReportError",winblock%,0,"See" �'ș "Wimp_CloseDown",task%,&4B534154 �� � �� �decode(in%, � width%) �!� A%,B%,C%,nlines%,out%,size% A% = in% 7� _calc:� How many newlines, how much space needed? %size% = !_size:nlines% = !_nlines width% = !_width (� out% size% 2!(out%+nlines%+4) = 0 <$B% = out%:C% = out% + nlines% +8 F#� _put:� prepare for Zap format P = out% Z d3� part of l%-th line containing c%-th character n� �line(c%,l%) x� line%,i%,x%,a$ �� 4*l%>=!_nlines � = "" �$line% = inbuf% + (inbuf%!(4*l%)) �� � a$ = �getstring(line%) � c% -= �(a$) � x% = ?line% �= � x% < 9 � line% += offset%(x%) � � 100,"File corrupted" � � x% = 2 � c% = 0 � � c% <= 0 �=a$ � �� �readctrl �.� Read Control characters <<<<<<<<<<<<<<< � c% Ȏ filetype% � � SeeFiletype%: " comment% = ?filebuf% ,1 � comment%<31 � 100,"Bad comment character" 6 changefont% = filebuf%?1 @7 � changefont%<31 � 100,"Bad changefont character" J changefor% = filebuf%?2 T< � changefor%<31 � 100,"Bad changeforeground character" ^ changebac% = filebuf%?3 h< � changebac%<31 � 100,"Bad changebackground character" r filebuf% += 4 | c% = ?filebuf% � ȕ c% <> 10 � c% <> 0 � filebuf% += 1 � c% = ?filebuf% � � �$ � ?filebuf% = 10 filebuf% += 1 � : � � defaults for plain text � comment% = 0 � changefont% = 0 � changefor% = 0 � changebac% = 0 �� �� � �asm : � <<<<<<<<<<<<<<< [ OPT pass% & ._put 0 MOV R7,#0 : MOV R5,#0 D MOV R6,R2 N MOV R3,R0 X LDR R4,[R3] b .while l CMP R4,#0 v �Q PC,R14 � SUB R9,R6,R1 � STR R9,[R1,R5] � ADD R5,R5,#4 �.repeat � LDRB R4,[R3],#1 � CMP R4,#0 � CMPNE R4,#10 � BEQ L10 � CMP R4,#changefont% � BEQ L160 � CMP R4,#changefor% � CMPNE R4,#changebac% � BEQ Lpound CMP R4,#comment% BEQ Lcomm .other CMP R7,#0 * STREQB R4,[R6],#1 4 BEQ repeat > MOV R9,#0 H STRB R9,[R6],#1 R MOV R9,#3 \ STRB R9,[R6],#1 f STRB R4,[R6],#1 p MOV R9,#1 z STRB R9,[R6],#1 � B repeat � � .Lcomm � LDRB R4,[R3],#1 � CMP R4,#0 � CMPNE R4,#10 � BNE Lcomm � � .L10 � MOV R9,#0 � STRB R9,[R6],#1 � MOV R9,#2 � STRB R9,[R6],#1 B while .L160 $ � R7,R7,#1 . MOV R9,#32 8 STRB R9,[R6],#1 B B repeat L V .Lpound ` LDRB R8,[R3] j CMP R8,#&30 t BCC other ~ CMP R8,#&3A � SUBCC R8,R8,#&30 � BCC readout � CMP R8,#&41 � BCC other � CMP R8,#&47 � BCS other � SUBCC R8,R8,#55 � � .readout � ADD R3,R3,#1 � MOV R9,#0 � STRB R9,[R6],#1 MOV R9,#6 CMP R4,#changefor% ADDNE R9,R9,#1 STRB R9,[R6],#1 ( STRB R8,[R6],#1 2 B repeat < F._size EQUD 0 P._nlines EQUD 0 Z._width EQUD 0 d.out n CMP R6,R7 x MOVCS R7,R6 � ADD R5,R1,R3 � ADD R5,R5,#9 � STR R5,_size � STR R1,_nlines � STR R7,_width � MOV PC,R14 � ._calc � MOV R1,#0 � MOV R3,#0 � MOV R4,#0 � MOV R6,#0 ; width count � MOV R7,#0 ; width max � B loop .endline ADD R1,R1,#4 ADD R3,R3,#2 " CMP R6,R7 ," MOVCS R7,R6 ; reset max 6% MOV R6,#0 ; zero counter @ .loop J LDRB R2,[R0],#1 T CMP R2,#0 ^ BEQ out h CMP R2,#10 r BEQ endline | CMP R2,#changefont% � �EQ R4,R4,#1 � ADDEQ R3,R3,#1 � BEQ loop � CMP R2,#changefor% � CMPNE R2,#changebac% � ADDEQ R3,R3,#3 � BEQ loop � CMP R4,#0 � ADDEQ R3,R3,#1 � ADDNE R3,R3,#4 � ADD R6,R6,#1 � B loop �] � �
00000000 0d 00 0a 20 f4 20 21 53 65 65 2e 21 52 75 6e 49 |... . !See.!RunI| 00000010 6d 61 67 65 20 76 65 72 73 69 6f 6e 20 30 2e 33 |mage version 0.3| 00000020 0d 00 14 05 f4 0d 00 1e 1e f4 20 a9 20 47 2e 43 |.......... . G.C| 00000030 2e 57 72 61 69 74 68 20 20 28 32 34 2f 30 37 2f |.Wraith (24/07/| 00000040 39 36 29 0d 00 28 05 f4 0d 00 32 30 f4 20 55 73 |96)..(....20. Us| 00000050 65 73 20 5a 61 70 52 65 64 72 61 77 20 6d 6f 64 |es ZapRedraw mod| 00000060 75 6c 65 20 a9 20 44 6f 6d 69 6e 69 63 20 53 79 |ule . Dominic Sy| 00000070 6d 65 73 20 31 39 39 34 0d 00 3c 04 0d 00 46 3b |mes 1994..<...F;| 00000080 f4 20 50 75 72 70 6f 73 65 3a 20 64 69 73 70 6c |. Purpose: displ| 00000090 61 79 20 66 61 73 74 20 73 63 72 6f 6c 6c 69 6e |ay fast scrollin| 000000a0 67 20 61 63 74 69 76 65 20 63 6f 6c 6f 75 72 65 |g active coloure| 000000b0 64 20 74 65 78 74 3b 0d 00 50 34 f4 20 20 20 20 |d text;..P4. | 000000c0 20 20 20 20 20 20 65 78 65 63 75 74 65 20 63 6f | execute co| 000000d0 6d 6d 61 6e 64 73 20 62 79 20 63 6c 69 63 6b 69 |mmands by clicki| 000000e0 6e 67 20 6f 6e 20 74 68 65 6d 2e 0d 00 5a 04 0d |ng on them...Z..| 000000f0 00 64 33 f4 20 3c 3c 3c 3c 3c 20 73 68 6f 77 73 |.d3. <<<<< shows| 00000100 20 70 61 72 74 73 20 64 65 70 65 6e 64 69 6e 67 | parts depending| 00000110 20 6f 6e 20 53 65 65 46 69 6c 65 20 73 79 6e 74 | on SeeFile synt| 00000120 61 78 0d 00 6e 04 0d 00 78 0d de 20 6d 65 73 67 |ax..n...x.. mesg| 00000130 25 20 37 0d 00 82 10 de 20 6f 66 66 73 65 74 25 |% 7..... offset%| 00000140 28 38 29 0d 00 8c 30 de 20 77 69 6e 62 6c 6f 63 |(8)...0. winbloc| 00000150 6b 25 20 39 33 20 3a 20 f4 20 77 69 6e 64 6f 77 |k% 93 : . window| 00000160 20 64 65 66 20 61 74 20 77 69 6e 62 6c 6f 63 6b | def at winblock| 00000170 25 2b 34 0d 00 96 27 de 20 70 6f 6c 6c 62 75 66 |%+4...'. pollbuf| 00000180 25 20 32 35 35 20 3a 20 f4 20 77 69 6d 70 20 70 |% 255 : . wimp p| 00000190 6f 6c 6c 20 62 75 66 66 65 72 0d 00 a0 27 de 20 |oll buffer...'. | 000001a0 72 65 64 72 61 77 25 20 32 35 35 20 20 3a 20 f4 |redraw% 255 : .| 000001b0 20 5a 61 70 20 72 65 64 72 61 77 20 62 6c 6f 63 | Zap redraw bloc| 000001c0 6b 0d 00 aa 11 de 20 63 68 61 72 73 25 20 34 30 |k..... chars% 40| 000001d0 39 35 0d 00 b4 14 de 20 62 69 74 6d 61 70 73 25 |95..... bitmaps%| 000001e0 20 26 38 30 30 30 0d 00 be 11 de 20 70 61 6c 65 | &8000..... pale| 000001f0 74 74 65 25 20 36 33 0d 00 c8 11 de 20 74 69 74 |tte% 63..... tit| 00000200 6c 65 25 20 20 32 35 35 0d 00 d2 20 de 20 63 6f |le% 255... . co| 00000210 64 65 25 20 34 32 39 20 3a 20 f4 20 3c 3c 3c 3c |de% 429 : . <<<<| 00000220 3c 3c 3c 3c 3c 3c 3c 3c 0d 00 dc 04 0d 00 e6 0b |<<<<<<<<........| 00000230 74 61 73 6b 25 3d 30 0d 00 f0 0e ee 20 85 20 f2 |task%=0..... . .| 00000240 65 72 72 6f 72 0d 00 fa 04 0d 01 04 11 66 69 6c |error........fil| 00000250 65 74 79 70 65 25 20 3d 20 30 0d 01 0e 0e 77 69 |etype% = 0....wi| 00000260 64 74 68 25 20 3d 20 30 0d 01 18 04 0d 01 22 2c |dth% = 0......",| 00000270 53 65 65 46 69 6c 65 74 79 70 65 25 20 3d 20 a0 |SeeFiletype% = .| 00000280 28 22 26 22 2b a4 73 79 73 76 61 72 28 22 53 65 |("&"+.sysvar("Se| 00000290 65 74 79 70 65 22 29 29 0d 01 2c 2e e7 20 53 65 |etype"))..,.. Se| 000002a0 65 46 69 6c 65 74 79 70 65 25 20 3c 20 30 20 84 |eFiletype% < 0 .| 000002b0 20 53 65 65 46 69 6c 65 74 79 70 65 25 20 3e 20 | SeeFiletype% > | 000002c0 26 46 46 46 20 8c 0d 01 36 3b 20 20 85 20 31 30 |&FFF ...6; . 10| 000002d0 30 2c 22 53 65 74 20 53 65 65 74 79 70 65 20 74 |0,"Set Seetype t| 000002e0 6f 20 61 20 68 65 78 20 73 74 72 69 6e 67 20 62 |o a hex string b| 000002f0 65 74 77 65 65 6e 20 30 20 61 6e 64 20 46 46 46 |etween 0 and FFF| 00000300 22 0d 01 40 05 cd 0d 01 4a 04 0d 01 54 12 61 72 |"..@....J...T.ar| 00000310 67 24 20 3d 20 a4 67 65 74 61 72 67 0d 01 5e 24 |g$ = .getarg..^$| 00000320 66 69 6c 65 62 75 66 25 20 3d 20 a4 6c 6f 61 64 |filebuf% = .load| 00000330 28 61 72 67 24 2c 66 69 6c 65 74 79 70 65 25 29 |(arg$,filetype%)| 00000340 0d 01 68 17 f2 72 65 61 64 63 74 72 6c 3a f4 20 |..h..readctrl:. | 00000350 3c 3c 3c 3c 3c 3c 3c 0d 01 72 04 0d 01 7c 1c f4 |<<<<<<<..r...|..| 00000360 20 41 73 73 65 6d 62 6c 65 20 64 65 63 6f 64 69 | Assemble decodi| 00000370 6e 67 20 63 6f 64 65 0d 01 86 17 e3 20 70 61 73 |ng code..... pas| 00000380 73 25 20 3d 20 30 20 b8 20 32 20 88 20 32 0d 01 |s% = 0 . 2 . 2..| 00000390 90 10 20 20 50 25 20 3d 20 63 6f 64 65 25 0d 01 |.. P% = code%..| 000003a0 9a 0a 20 20 f2 61 73 6d 0d 01 a4 05 ed 0d 01 ae |.. .asm........| 000003b0 04 0d 01 b8 42 69 6e 62 75 66 25 3d a4 64 65 63 |....Binbuf%=.dec| 000003c0 6f 64 65 28 66 69 6c 65 62 75 66 25 2c 77 69 64 |ode(filebuf%,wid| 000003d0 74 68 25 29 3a f4 20 63 6f 6e 76 65 72 74 73 20 |th%):. converts | 000003e0 74 6f 20 5a 61 70 52 65 6e 64 65 72 20 66 6f 72 |to ZapRender for| 000003f0 6d 61 74 0d 01 c2 04 0d 01 cc 19 f2 64 65 66 69 |mat.........defi| 00000400 6e 65 5f 7a 61 70 5f 76 61 72 69 61 62 6c 65 73 |ne_zap_variables| 00000410 0d 01 d6 19 72 65 64 72 61 77 25 21 72 5f 64 61 |....redraw%!r_da| 00000420 74 61 3d 69 6e 62 75 66 25 0d 01 e0 20 72 65 64 |ta=inbuf%... red| 00000430 72 61 77 25 21 72 5f 77 6f 72 6b 61 72 65 61 3d |raw%!r_workarea=| 00000440 77 69 6e 62 6c 6f 63 6b 25 0d 01 ea 04 0d 01 f4 |winblock%.......| 00000450 31 c8 99 20 22 5a 61 70 52 65 64 72 61 77 5f 52 |1.. "ZapRedraw_R| 00000460 65 61 64 53 79 73 74 65 6d 43 68 61 72 73 22 2c |eadSystemChars",| 00000470 63 68 61 72 73 25 2c 72 65 64 72 61 77 25 0d 01 |chars%,redraw%..| 00000480 fe 4a c8 99 20 22 4f 53 5f 46 69 6c 65 22 2c 31 |.J.. "OS_File",1| 00000490 36 2c 22 3c 53 65 65 24 44 69 72 3e 2e 45 78 74 |6,"<See$Dir>.Ext| 000004a0 72 61 43 68 61 72 73 22 2c 63 68 61 72 73 25 2b |raChars",chars%+| 000004b0 32 30 34 38 2c 30 3a f4 20 6c 6f 61 64 20 65 78 |2048,0:. load ex| 000004c0 74 72 61 20 66 6f 6e 74 0d 02 08 04 0d 02 12 16 |tra font........| 000004d0 f4 20 6e 6f 6e 65 78 69 73 74 65 6e 74 20 6d 6f |. nonexistent mo| 000004e0 64 65 0d 02 1c 1a 6d 6f 64 65 25 3d a4 6d 6f 64 |de....mode%=.mod| 000004f0 65 5f 63 68 61 6e 67 65 28 2d 31 29 0d 02 26 04 |e_change(-1)..&.| 00000500 0d 02 30 21 6f 66 66 73 65 74 25 28 29 20 3d 20 |..0!offset%() = | 00000510 31 2c 33 2c 30 2c 33 2c 35 2c 31 2c 32 2c 32 2c |1,3,0,3,5,1,2,2,| 00000520 35 0d 02 3a 04 0d 02 44 1f 21 6d 65 73 67 25 20 |5..:...D.!mesg% | 00000530 3d 20 26 34 30 30 43 31 3a 6d 65 73 67 25 21 34 |= &400C1:mesg%!4| 00000540 20 3d 20 30 0d 02 4e 3b c8 99 20 22 57 69 6d 70 | = 0..N;.. "Wimp| 00000550 5f 49 6e 69 74 69 61 6c 69 73 65 22 2c 33 31 30 |_Initialise",310| 00000560 2c 26 34 42 35 33 34 31 35 34 2c 22 53 65 65 22 |,&4B534154,"See"| 00000570 2c 6d 65 73 67 25 20 b8 20 2c 74 61 73 6b 25 0d |,mesg% . ,task%.| 00000580 02 58 0b 71 75 69 74 25 3d a3 0d 02 62 04 0d 02 |.X.quit%=...b...| 00000590 6c 15 24 74 69 74 6c 65 25 20 3d 20 61 72 67 24 |l.$title% = arg$| 000005a0 2b bd 30 0d 02 76 34 77 69 6e 64 6f 77 25 20 3d |+.0..v4window% =| 000005b0 20 a4 63 72 65 61 74 65 5f 77 69 6e 64 6f 77 28 | .create_window(| 000005c0 74 69 74 6c 65 25 2c 77 69 64 74 68 25 2c 21 5f |title%,width%,!_| 000005d0 6e 6c 69 6e 65 73 29 0d 02 80 04 0d 02 8a 05 f5 |nlines).........| 000005e0 0d 02 94 2e c8 99 20 22 57 69 6d 70 5f 50 6f 6c |...... "Wimp_Pol| 000005f0 6c 22 2c 26 33 31 2c 70 6f 6c 6c 62 75 66 25 20 |l",&31,pollbuf% | 00000600 b8 20 65 76 65 6e 74 25 2c 64 61 74 61 25 0d 02 |. event%,data%..| 00000610 9e 0f c8 8e 20 65 76 65 6e 74 25 20 ca 0d 02 a8 |.... event% ....| 00000620 32 20 c9 20 31 3a c8 99 20 22 5a 61 70 52 65 64 |2 . 1:.. "ZapRed| 00000630 72 61 77 5f 52 65 64 72 61 77 57 69 6e 64 6f 77 |raw_RedrawWindow| 00000640 22 2c 64 61 74 61 25 2c 72 65 64 72 61 77 25 0d |",data%,redraw%.| 00000650 02 b2 25 20 c9 20 32 3a c8 99 20 22 57 69 6d 70 |..% . 2:.. "Wimp| 00000660 5f 4f 70 65 6e 57 69 6e 64 6f 77 22 2c 30 2c 64 |_OpenWindow",0,d| 00000670 61 74 61 25 0d 02 bc 10 20 c9 20 33 3a 71 75 69 |ata%.... . 3:qui| 00000680 74 25 3d b9 0d 02 c6 2e 20 20 20 20 20 20 20 20 |t%=..... | 00000690 c8 99 20 22 57 69 6d 70 5f 47 65 74 50 6f 69 6e |.. "Wimp_GetPoin| 000006a0 74 65 72 49 6e 66 6f 22 2c 2c 70 6f 6c 6c 62 75 |terInfo",,pollbu| 000006b0 66 25 0d 02 d0 1e 20 20 20 20 20 20 20 20 e7 20 |f%.... . | 000006c0 70 6f 6c 6c 62 75 66 25 21 38 20 3d 20 31 20 8c |pollbuf%!8 = 1 .| 000006d0 0d 02 da 2c 20 20 20 20 20 20 20 20 20 20 ff 28 |..., .(| 000006e0 22 46 69 6c 65 72 5f 4f 70 65 6e 44 69 72 20 22 |"Filer_OpenDir "| 000006f0 2b a4 64 69 72 28 61 72 67 24 29 29 0d 02 e4 0d |+.dir(arg$))....| 00000700 20 20 20 20 20 20 20 20 cd 0d 02 ee 09 20 c9 20 | ..... . | 00000710 36 3a 0d 02 f8 2c 20 20 e7 20 64 61 74 61 25 21 |6:..., . data%!| 00000720 31 32 20 3d 20 77 69 6e 64 6f 77 25 20 80 20 64 |12 = window% . d| 00000730 61 74 61 25 21 31 36 20 3d 20 2d 31 20 8c 0d 03 |ata%!16 = -1 ...| 00000740 02 26 20 20 20 20 f2 63 6c 69 63 6b 28 21 64 61 |.& .click(!da| 00000750 74 61 25 2c 64 61 74 61 25 21 34 2c 64 61 74 61 |ta%,data%!4,data| 00000760 25 21 38 29 0d 03 0c 07 20 20 cd 0d 03 16 1a 20 |%!8).... ..... | 00000770 c9 20 31 37 2c 31 38 3a c8 8e 20 64 61 74 61 25 |. 17,18:.. data%| 00000780 21 31 36 20 ca 0d 03 20 1c 20 20 20 20 20 20 20 |!16 ... . | 00000790 20 20 20 20 20 20 c9 20 30 3a 71 75 69 74 25 3d | . 0:quit%=| 000007a0 b9 0d 03 2a 35 20 20 20 20 20 20 20 20 20 20 20 |...*5 | 000007b0 20 20 c9 20 26 34 30 30 43 31 3a 6d 6f 64 65 25 | . &400C1:mode%| 000007c0 20 3d 20 a4 6d 6f 64 65 5f 63 68 61 6e 67 65 28 | = .mode_change(| 000007d0 6d 6f 64 65 25 29 0d 03 34 11 20 20 20 20 20 20 |mode%)..4. | 000007e0 20 20 20 20 20 20 cb 0d 03 3e 05 cb 0d 03 48 0b | ...>....H.| 000007f0 fd 20 71 75 69 74 25 0d 03 52 27 c8 99 20 22 57 |. quit%..R'.. "W| 00000800 69 6d 70 5f 43 6c 6f 73 65 44 6f 77 6e 22 2c 74 |imp_CloseDown",t| 00000810 61 73 6b 25 2c 26 34 42 35 33 34 31 35 34 0d 03 |ask%,&4B534154..| 00000820 5c 05 e0 0d 03 66 04 0d 03 70 1e dd 20 a4 6c 6f |\....f...p.. .lo| 00000830 61 64 28 61 72 67 24 2c 20 f8 20 66 69 6c 65 74 |ad(arg$, . filet| 00000840 79 70 65 25 29 0d 03 7a 1c ea 20 74 79 70 65 25 |ype%)..z.. type%| 00000850 2c 66 69 6c 65 62 75 66 25 2c 6c 65 6e 67 74 68 |,filebuf%,length| 00000860 25 0d 03 84 36 c8 99 20 22 4f 53 5f 46 69 6c 65 |%...6.. "OS_File| 00000870 22 2c 32 33 2c 61 72 67 24 20 b8 20 74 79 70 65 |",23,arg$ . type| 00000880 25 2c 2c 2c 2c 6c 65 6e 67 74 68 25 2c 2c 66 69 |%,,,,length%,,fi| 00000890 6c 65 74 79 70 65 25 0d 03 8e 2e e7 20 74 79 70 |letype%..... typ| 000008a0 65 25 20 3c 3e 20 31 20 85 20 31 30 30 2c 61 72 |e% <> 1 . 100,ar| 000008b0 67 24 20 2b 20 22 20 69 73 20 6e 6f 74 20 61 20 |g$ + " is not a | 000008c0 66 69 6c 65 22 0d 03 98 2d e7 20 66 69 6c 65 74 |file"...-. filet| 000008d0 79 70 65 25 20 3d 20 26 31 30 30 30 20 84 20 66 |ype% = &1000 . f| 000008e0 69 6c 65 74 79 70 65 25 20 3d 20 26 32 30 30 30 |iletype% = &2000| 000008f0 20 8c 0d 03 a2 22 20 85 20 31 30 30 2c 61 72 67 | ...." . 100,arg| 00000900 24 20 2b 20 22 69 73 20 61 20 64 69 72 65 63 74 |$ + "is a direct| 00000910 6f 72 79 22 0d 03 ac 05 cd 0d 03 b6 20 66 69 6c |ory"........ fil| 00000920 65 74 79 70 65 25 20 3d 20 66 69 6c 65 74 79 70 |etype% = filetyp| 00000930 65 25 20 80 20 26 46 46 46 0d 03 c0 16 de 20 66 |e% . &FFF..... f| 00000940 69 6c 65 62 75 66 25 20 6c 65 6e 67 74 68 25 0d |ilebuf% length%.| 00000950 03 ca 38 c8 99 20 22 4f 53 5f 46 69 6c 65 22 2c |..8.. "OS_File",| 00000960 31 36 2c 61 72 67 24 2c 66 69 6c 65 62 75 66 25 |16,arg$,filebuf%| 00000970 2c 30 20 3a 20 f4 20 6c 6f 61 64 20 73 6f 75 72 |,0 : . load sour| 00000980 63 65 20 66 69 6c 65 0d 03 d4 27 66 69 6c 65 62 |ce file...'fileb| 00000990 75 66 25 3f 6c 65 6e 67 74 68 25 20 3d 20 30 20 |uf%?length% = 0 | 000009a0 3a 20 f4 20 74 65 72 6d 69 6e 61 74 6f 72 0d 03 |: . terminator..| 000009b0 de 0e 3d 20 66 69 6c 65 62 75 66 25 0d 03 e8 04 |..= filebuf%....| 000009c0 0d 03 f2 24 f4 20 67 65 74 20 64 69 72 65 63 74 |...$. get direct| 000009d0 6f 72 79 20 70 61 72 74 20 6f 66 20 70 61 74 68 |ory part of path| 000009e0 6e 61 6d 65 0d 03 fc 0e dd 20 a4 64 69 72 28 61 |name..... .dir(a| 000009f0 24 29 0d 04 06 16 ea 20 6c 65 6e 25 2c 6f 76 65 |$)..... len%,ove| 00000a00 72 25 2c 70 25 2c 62 24 0d 04 10 2f c8 99 20 22 |r%,p%,b$.../.. "| 00000a10 4f 53 5f 46 53 43 6f 6e 74 72 6f 6c 22 2c 33 37 |OS_FSControl",37| 00000a20 2c 61 24 2c 30 2c 30 2c 30 2c 30 20 b8 20 2c 2c |,a$,0,0,0,0 . ,,| 00000a30 2c 2c 2c 6c 65 6e 25 0d 04 1a 3c c8 99 20 22 4f |,,,len%...<.. "O| 00000a40 53 5f 46 53 43 6f 6e 74 72 6f 6c 22 2c 33 37 2c |S_FSControl",37,| 00000a50 61 24 2c 70 6f 6c 6c 62 75 66 25 2c 30 2c 30 2c |a$,pollbuf%,0,0,| 00000a60 31 2d 6c 65 6e 25 20 b8 20 2c 2c 2c 2c 2c 6f 76 |1-len% . ,,,,,ov| 00000a70 65 72 25 0d 04 24 2e e7 20 6f 76 65 72 25 3c 3e |er%..$.. over%<>| 00000a80 31 20 85 20 31 30 30 2c 22 43 61 6e 6e 6f 74 20 |1 . 100,"Cannot | 00000a90 63 61 6e 6f 6e 69 63 61 6c 69 7a 65 20 22 2b 61 |canonicalize "+a| 00000aa0 24 0d 04 2e 11 70 25 20 3d 20 70 6f 6c 6c 62 75 |$....p% = pollbu| 00000ab0 66 25 0d 04 38 17 62 24 20 3d 20 a4 67 65 74 73 |f%..8.b$ = .gets| 00000ac0 74 72 69 6e 67 28 70 25 29 0d 04 42 10 c8 95 20 |tring(p%)..B... | 00000ad0 c2 62 24 29 3c 3e 22 2e 22 0d 04 4c 0e 20 62 24 |.b$)<>"."..L. b$| 00000ae0 20 3d 20 c0 62 24 29 0d 04 56 05 ce 0d 04 60 0a | = .b$)..V....`.| 00000af0 3d 20 c0 62 24 29 0d 04 6a 04 0d 04 74 1c f4 20 |= .b$)..j...t.. | 00000b00 72 65 61 64 20 61 20 73 79 73 74 65 6d 20 76 61 |read a system va| 00000b10 72 69 61 62 6c 65 0d 04 7e 11 dd 20 a4 73 79 73 |riable..~.. .sys| 00000b20 76 61 72 28 41 24 29 0d 04 88 0d ea 20 6c 65 6e |var(A$)..... len| 00000b30 67 74 68 25 0d 04 92 34 c8 99 20 22 58 4f 53 5f |gth%...4.. "XOS_| 00000b40 52 65 61 64 56 61 72 56 61 6c 22 2c 41 24 2c 70 |ReadVarVal",A$,p| 00000b50 6f 6c 6c 62 75 66 25 2c 2d 31 2c 30 20 b8 20 2c |ollbuf%,-1,0 . ,| 00000b60 2c 6c 65 6e 67 74 68 25 0d 04 9c 27 e7 20 6c 65 |,length%...'. le| 00000b70 6e 67 74 68 25 3d 30 20 8c 20 85 20 31 30 30 2c |ngth%=0 . . 100,| 00000b80 41 24 2b 22 20 6e 6f 74 20 66 6f 75 6e 64 22 0d |A$+" not found".| 00000b90 04 a6 35 c8 99 20 22 58 4f 53 5f 52 65 61 64 56 |..5.. "XOS_ReadV| 00000ba0 61 72 56 61 6c 22 2c 41 24 2c 70 6f 6c 6c 62 75 |arVal",A$,pollbu| 00000bb0 66 25 2c 32 35 35 2c 30 20 b8 20 2c 2c 6c 65 6e |f%,255,0 . ,,len| 00000bc0 67 74 68 25 0d 04 b0 17 70 6f 6c 6c 62 75 66 25 |gth%....pollbuf%| 00000bd0 3f 6c 65 6e 67 74 68 25 3d 31 33 0d 04 ba 0e 3d |?length%=13....=| 00000be0 24 70 6f 6c 6c 62 75 66 25 0d 04 c4 04 0d 04 ce |$pollbuf%.......| 00000bf0 04 0d 04 d8 3d f4 20 47 65 74 20 73 74 72 69 6e |....=. Get strin| 00000c00 67 20 74 65 72 6d 69 6e 61 74 65 64 20 62 79 20 |g terminated by | 00000c10 63 6f 6e 74 72 6f 6c 20 63 6f 64 65 2c 20 75 70 |control code, up| 00000c20 64 61 74 69 6e 67 20 70 6f 69 6e 74 65 72 0d 04 |dating pointer..| 00000c30 e2 1f f4 20 74 6f 20 62 65 79 6f 6e 64 20 74 68 |... to beyond th| 00000c40 65 20 74 65 72 6d 69 6e 61 74 6f 72 2e 0d 04 ec |e terminator....| 00000c50 16 dd 20 a4 67 65 74 73 74 72 69 6e 67 28 f8 20 |.. .getstring(. | 00000c60 61 25 29 0d 04 f6 0b ea 20 61 24 2c 63 25 0d 05 |a%)..... a$,c%..| 00000c70 00 0b 61 24 20 3d 20 22 22 0d 05 0a 0c 63 25 20 |..a$ = ""....c% | 00000c80 3d 20 3f 61 25 0d 05 14 0e c8 95 20 63 25 20 3e |= ?a%...... c% >| 00000c90 20 33 31 0d 05 1e 10 20 61 24 20 2b 3d 20 bd 28 | 31.... a$ += .(| 00000ca0 63 25 29 0d 05 28 0c 20 61 25 20 2b 3d 20 31 0d |c%)..(. a% += 1.| 00000cb0 05 32 0d 20 63 25 20 3d 20 3f 61 25 0d 05 3c 05 |.2. c% = ?a%..<.| 00000cc0 ce 0d 05 46 0b 61 25 20 2b 3d 20 31 0d 05 50 08 |...F.a% += 1..P.| 00000cd0 3d 20 61 24 0d 05 5a 04 0d 05 64 0d dd 20 a4 67 |= a$..Z...d.. .g| 00000ce0 65 74 61 72 67 0d 05 6e 16 ea 20 63 6f 6d 6d 61 |etarg..n.. comma| 00000cf0 6e 64 24 2c 69 25 2c 61 72 67 24 0d 05 78 1d c8 |nd$,i%,arg$..x..| 00000d00 99 20 22 4f 53 5f 47 65 74 45 6e 76 22 20 b8 20 |. "OS_GetEnv" . | 00000d10 63 6f 6d 6d 61 6e 64 24 0d 05 82 1f 69 25 20 3d |command$....i% =| 00000d20 20 a7 63 6f 6d 6d 61 6e 64 24 2c 22 21 52 75 6e | .command$,"!Run| 00000d30 49 6d 61 67 65 22 29 0d 05 8c 35 e7 20 69 25 3d |Image")...5. i%=| 00000d40 30 20 85 20 31 30 30 2c 22 21 52 75 6e 49 6d 61 |0 . 100,"!RunIma| 00000d50 67 65 20 6e 6f 74 20 66 6f 75 6e 64 2e 20 4e 61 |ge not found. Na| 00000d60 6d 65 20 63 68 61 6e 67 65 64 3f 22 0d 05 96 1b |me changed?"....| 00000d70 61 72 67 24 20 3d 20 c1 63 6f 6d 6d 61 6e 64 24 |arg$ = .command$| 00000d80 2c 69 25 2b 31 30 29 0d 05 a0 21 c8 95 20 97 28 |,i%+10)...!.. .(| 00000d90 61 72 67 24 29 3d 33 32 3a 61 72 67 24 3d c1 61 |arg$)=32:arg$=.a| 00000da0 72 67 24 2c 32 29 3a ce 0d 05 aa 2b e7 20 61 72 |rg$,2):....+. ar| 00000db0 67 24 3d 22 22 20 85 20 31 30 30 2c 22 53 65 65 |g$="" . 100,"See| 00000dc0 20 6e 65 65 64 73 20 61 6e 20 61 72 67 75 6d 65 | needs an argume| 00000dd0 6e 74 22 0d 05 b4 0a 3d 20 61 72 67 24 0d 05 be |nt"....= arg$...| 00000de0 04 0d 05 c8 1c dd 20 20 f2 64 65 66 69 6e 65 5f |...... .define_| 00000df0 7a 61 70 5f 76 61 72 69 61 62 6c 65 73 0d 05 d2 |zap_variables...| 00000e00 2a 72 5f 66 6c 61 67 73 20 3d 20 30 20 20 20 20 |*r_flags = 0 | 00000e10 20 20 20 20 20 20 20 20 3a f4 20 52 65 64 72 61 | :. Redra| 00000e20 77 20 66 6c 61 67 73 0d 05 dc 2f 72 5f 62 70 70 |w flags.../r_bpp| 00000e30 20 3d 20 32 38 20 20 20 20 20 20 20 20 20 20 20 | = 28 | 00000e40 20 20 3a f4 20 6c 6f 67 20 62 61 73 65 20 32 20 | :. log base 2 | 00000e50 6f 66 20 62 70 70 0d 05 e6 3a 72 5f 63 68 61 72 |of bpp...:r_char| 00000e60 77 20 3d 20 33 32 20 20 20 20 20 20 20 20 20 20 |w = 32 | 00000e70 20 3a f4 20 77 69 64 74 68 20 6f 66 20 61 20 63 | :. width of a c| 00000e80 68 61 72 61 63 74 65 72 20 69 6e 20 70 69 78 73 |haracter in pixs| 00000e90 0d 05 f0 3b 72 5f 63 68 61 72 68 20 3d 20 33 36 |...;r_charh = 36| 00000ea0 20 20 20 20 20 20 20 20 20 20 20 3a f4 20 68 65 | :. he| 00000eb0 69 67 68 74 20 6f 66 20 61 20 63 68 61 72 61 63 |ight of a charac| 00000ec0 74 65 72 20 69 6e 20 70 69 78 73 0d 05 fa 37 72 |ter in pixs...7r| 00000ed0 5f 63 61 64 64 72 20 3d 20 34 30 20 20 20 20 20 |_caddr = 40 | 00000ee0 20 20 20 20 20 20 3a f4 20 63 61 63 68 65 20 61 | :. cache a| 00000ef0 64 64 72 65 73 73 20 2f 20 66 6f 6e 74 20 6e 61 |ddress / font na| 00000f00 6d 65 0d 06 04 33 72 5f 63 62 70 6c 20 3d 20 34 |me...3r_cbpl = 4| 00000f10 34 20 20 20 20 20 20 20 20 20 20 20 20 3a f4 20 |4 :. | 00000f20 62 79 74 65 73 20 70 65 72 20 63 61 63 68 65 64 |bytes per cached| 00000f30 20 6c 69 6e 65 0d 06 0e 38 72 5f 63 62 70 63 20 | line...8r_cbpc | 00000f40 3d 20 34 38 20 20 20 20 20 20 20 20 20 20 20 20 |= 48 | 00000f50 3a f4 20 62 79 74 65 73 20 70 65 72 20 63 61 63 |:. bytes per cac| 00000f60 68 65 64 20 63 68 61 72 61 63 74 65 72 0d 06 18 |hed character...| 00000f70 34 72 5f 6c 69 6e 65 73 70 20 3d 20 35 32 20 20 |4r_linesp = 52 | 00000f80 20 20 20 20 20 20 20 20 3a f4 20 6c 69 6e 65 20 | :. line | 00000f90 73 70 61 63 69 6e 67 20 69 6e 20 70 69 78 65 6c |spacing in pixel| 00000fa0 73 0d 06 22 36 72 5f 64 61 74 61 20 20 3d 20 35 |s.."6r_data = 5| 00000fb0 36 20 20 20 20 20 20 20 20 20 20 20 3a f4 20 61 |6 :. a| 00000fc0 64 64 72 65 73 73 20 6f 66 20 64 61 74 61 20 74 |ddress of data t| 00000fd0 6f 20 70 72 69 6e 74 0d 06 2c 35 72 5f 70 61 6c |o print..,5r_pal| 00000fe0 65 74 74 65 20 3d 20 36 38 20 20 20 20 20 20 20 |ette = 68 | 00000ff0 20 20 3a f4 20 61 64 64 72 65 73 73 20 6f 66 20 | :. address of | 00001000 70 61 6c 65 74 74 65 20 64 61 74 61 0d 06 36 34 |palette data..64| 00001010 72 5f 66 6f 72 20 3d 20 37 32 20 20 20 20 20 20 |r_for = 72 | 00001020 20 20 20 20 20 20 20 3a f4 20 73 74 61 72 74 20 | :. start | 00001030 66 6f 72 67 72 6f 75 6e 64 20 63 6f 6c 6f 75 72 |forground colour| 00001040 0d 06 40 35 72 5f 62 61 63 20 3d 20 37 36 20 20 |..@5r_bac = 76 | 00001050 20 20 20 20 20 20 20 20 20 20 20 3a f4 20 73 74 | :. st| 00001060 61 72 74 20 62 61 63 6b 67 72 6f 75 6e 64 20 63 |art background c| 00001070 6f 6c 6f 75 72 0d 06 4a 32 72 5f 77 6f 72 6b 61 |olour..J2r_worka| 00001080 72 65 61 20 3d 20 38 30 20 20 20 20 20 20 20 20 |rea = 80 | 00001090 3a f4 20 61 64 64 72 65 73 73 20 6f 66 20 77 6f |:. address of wo| 000010a0 72 6b 20 61 72 65 61 0d 06 54 05 e1 0d 06 5e 04 |rk area..T....^.| 000010b0 0d 06 68 2a dd 20 a4 63 72 65 61 74 65 5f 77 69 |..h*. .create_wi| 000010c0 6e 64 6f 77 28 74 69 74 6c 65 25 2c 77 69 64 74 |ndow(title%,widt| 000010d0 68 25 2c 6c 69 6e 65 73 25 29 0d 06 72 0d ea 20 |h%,lines%)..r.. | 000010e0 68 61 6e 64 6c 65 25 0d 06 7c 13 77 69 6e 62 6c |handle%..|.winbl| 000010f0 6f 63 6b 25 21 34 3d 31 30 30 0d 06 86 13 77 69 |ock%!4=100....wi| 00001100 6e 62 6c 6f 63 6b 25 21 38 3d 32 38 38 0d 06 90 |nblock%!8=288...| 00001110 15 77 69 6e 62 6c 6f 63 6b 25 21 31 32 3d 31 31 |.winblock%!12=11| 00001120 30 30 0d 06 9a 14 77 69 6e 62 6c 6f 63 6b 25 21 |00....winblock%!| 00001130 31 36 3d 38 30 30 0d 06 a4 12 77 69 6e 62 6c 6f |16=800....winblo| 00001140 63 6b 25 21 32 30 3d 30 0d 06 ae 12 77 69 6e 62 |ck%!20=0....winb| 00001150 6c 6f 63 6b 25 21 32 34 3d 30 0d 06 b8 13 77 69 |lock%!24=0....wi| 00001160 6e 62 6c 6f 63 6b 25 21 32 38 3d 2d 31 0d 06 c2 |nblock%!28=-1...| 00001170 1a 77 69 6e 62 6c 6f 63 6b 25 21 33 32 3d 26 46 |.winblock%!32=&F| 00001180 46 30 30 30 30 30 32 0d 06 cc 1a 77 69 6e 62 6c |F000002....winbl| 00001190 6f 63 6b 25 21 33 36 3d 26 46 46 30 37 30 32 30 |ock%!36=&FF07020| 000011a0 37 0d 06 d6 1a 77 69 6e 62 6c 6f 63 6b 25 21 34 |7....winblock%!4| 000011b0 30 3d 26 30 30 30 43 30 31 30 33 0d 06 e0 12 77 |0=&000C0103....w| 000011c0 69 6e 62 6c 6f 63 6b 25 21 34 34 3d 30 0d 06 ea |inblock%!44=0...| 000011d0 3d 77 69 6e 62 6c 6f 63 6b 25 21 34 38 3d 2d 28 |=winblock%!48=-(| 000011e0 72 65 64 72 61 77 25 21 72 5f 63 68 61 72 68 20 |redraw%!r_charh | 000011f0 2b 20 72 65 64 72 61 77 25 21 72 5f 6c 69 6e 65 |+ redraw%!r_line| 00001200 73 70 29 2a 6c 69 6e 65 73 25 0d 06 f4 2b 77 69 |sp)*lines%...+wi| 00001210 6e 62 6c 6f 63 6b 25 21 35 32 3d 32 2a 28 72 65 |nblock%!52=2*(re| 00001220 64 72 61 77 25 21 72 5f 63 68 61 72 77 29 2a 77 |draw%!r_charw)*w| 00001230 69 64 74 68 25 0d 06 fe 12 77 69 6e 62 6c 6f 63 |idth%....winbloc| 00001240 6b 25 21 35 36 3d 30 0d 07 08 1a 77 69 6e 62 6c |k%!56=0....winbl| 00001250 6f 63 6b 25 21 36 30 3d 26 32 37 30 30 36 31 33 |ock%!60=&2700613| 00001260 44 0d 07 12 16 77 69 6e 62 6c 6f 63 6b 25 21 36 |D....winblock%!6| 00001270 34 3d 33 3c 3c 31 32 0d 07 1c 12 77 69 6e 62 6c |4=3<<12....winbl| 00001280 6f 63 6b 25 21 36 38 3d 30 0d 07 26 17 77 69 6e |ock%!68=0..&.win| 00001290 62 6c 6f 63 6b 25 21 37 32 3d 26 31 30 30 30 31 |block%!72=&10001| 000012a0 0d 07 30 17 77 69 6e 62 6c 6f 63 6b 25 21 37 36 |..0.winblock%!76| 000012b0 3d 74 69 74 6c 65 25 0d 07 3a 12 77 69 6e 62 6c |=title%..:.winbl| 000012c0 6f 63 6b 25 21 38 30 3d 30 0d 07 44 14 77 69 6e |ock%!80=0..D.win| 000012d0 62 6c 6f 63 6b 25 21 38 34 3d 32 35 35 0d 07 4e |block%!84=255..N| 000012e0 12 77 69 6e 62 6c 6f 63 6b 25 21 38 38 3d 30 0d |.winblock%!88=0.| 000012f0 07 58 32 c8 99 20 22 57 69 6d 70 5f 43 72 65 61 |.X2.. "Wimp_Crea| 00001300 74 65 57 69 6e 64 6f 77 22 2c 30 2c 77 69 6e 62 |teWindow",0,winb| 00001310 6c 6f 63 6b 25 2b 34 20 b8 20 68 61 6e 64 6c 65 |lock%+4 . handle| 00001320 25 0d 07 62 16 21 77 69 6e 62 6c 6f 63 6b 25 3d |%..b.!winblock%=| 00001330 68 61 6e 64 6c 65 25 0d 07 6c 24 c8 99 20 22 57 |handle%..l$.. "W| 00001340 69 6d 70 5f 4f 70 65 6e 57 69 6e 64 6f 77 22 2c |imp_OpenWindow",| 00001350 30 2c 77 69 6e 62 6c 6f 63 6b 25 0d 07 76 0d 3d |0,winblock%..v.=| 00001360 20 68 61 6e 64 6c 65 25 0d 07 80 04 0d 07 8a 16 | handle%........| 00001370 dd 20 f2 63 6c 69 63 6b 28 78 25 2c 79 25 2c 62 |. .click(x%,y%,b| 00001380 25 29 0d 07 94 11 ea 20 63 68 61 72 25 2c 6c 69 |%)..... char%,li| 00001390 6e 65 25 0d 07 9e 18 21 77 69 6e 62 6c 6f 63 6b |ne%....!winblock| 000013a0 25 20 3d 20 77 69 6e 64 6f 77 25 0d 07 a8 26 c8 |% = window%...&.| 000013b0 99 20 22 57 69 6d 70 5f 47 65 74 57 69 6e 64 6f |. "Wimp_GetWindo| 000013c0 77 49 6e 66 6f 22 2c 2c 77 69 6e 62 6c 6f 63 6b |wInfo",,winblock| 000013d0 25 0d 07 b2 4a 63 68 61 72 25 20 3d 20 28 78 25 |%...Jchar% = (x%| 000013e0 2d 77 69 6e 62 6c 6f 63 6b 25 21 34 2b 77 69 6e |-winblock%!4+win| 000013f0 62 6c 6f 63 6b 25 21 34 34 2b 77 69 6e 62 6c 6f |block%!44+winblo| 00001400 63 6b 25 21 32 30 29 2f 28 72 65 64 72 61 77 25 |ck%!20)/(redraw%| 00001410 21 72 5f 63 68 61 72 77 29 2f 32 0d 07 bc 60 6c |!r_charw)/2...`l| 00001420 69 6e 65 25 20 3d 20 28 77 69 6e 62 6c 6f 63 6b |ine% = (winblock| 00001430 25 21 31 36 2b 77 69 6e 62 6c 6f 63 6b 25 21 35 |%!16+winblock%!5| 00001440 36 20 2d 20 77 69 6e 62 6c 6f 63 6b 25 21 32 34 |6 - winblock%!24| 00001450 20 2d 20 79 25 29 2f 28 72 65 64 72 61 77 25 21 | - y%)/(redraw%!| 00001460 72 5f 63 68 61 72 68 2b 72 65 64 72 61 77 25 21 |r_charh+redraw%!| 00001470 72 5f 6c 69 6e 65 73 70 29 2f 34 0d 07 c6 0b c8 |r_linesp)/4.....| 00001480 8e 20 62 25 20 ca 0d 07 d0 37 20 c9 20 34 3a 20 |. b% ....7 . 4: | 00001490 e7 20 66 69 6c 65 74 79 70 65 25 3d 53 65 65 46 |. filetype%=SeeF| 000014a0 69 6c 65 74 79 70 65 25 20 f2 73 65 6c 65 63 74 |iletype% .select| 000014b0 28 63 68 61 72 25 2c 6c 69 6e 65 25 29 0d 07 da |(char%,line%)...| 000014c0 1e 20 c9 20 31 3a 20 f2 61 64 6a 75 73 74 28 63 |. . 1: .adjust(c| 000014d0 68 61 72 25 2c 6c 69 6e 65 25 29 0d 07 e4 05 cb |har%,line%).....| 000014e0 0d 07 ee 05 e1 0d 07 f8 04 0d 08 02 10 dd 20 a4 |.............. .| 000014f0 73 74 72 69 70 28 41 24 29 0d 08 0c 11 c8 95 20 |strip(A$)...... | 00001500 97 28 41 24 29 20 3d 20 33 32 0d 08 16 10 20 41 |.(A$) = 32.... A| 00001510 24 20 3d 20 c1 41 24 2c 32 29 0d 08 20 05 ce 0d |$ = .A$,2).. ...| 00001520 08 2a 08 3d 20 41 24 0d 08 34 04 0d 08 3e 14 dd |.*.= A$..4...>..| 00001530 20 f2 61 64 6a 75 73 74 28 63 25 2c 6c 25 29 0d | .adjust(c%,l%).| 00001540 08 48 08 ea 20 73 24 0d 08 52 1d 73 24 20 3d 20 |.H.. s$..R.s$ = | 00001550 a4 73 74 72 69 70 28 a4 6c 69 6e 65 28 63 25 2c |.strip(.line(c%,| 00001560 6c 25 29 29 0d 08 5c 2d e7 20 97 28 73 24 29 20 |l%))..\-. .(s$) | 00001570 3d 20 97 28 22 2a 22 29 20 8c 20 c8 99 20 22 57 |= .("*") . .. "W| 00001580 69 6d 70 5f 53 74 61 72 74 54 61 73 6b 22 2c 73 |imp_StartTask",s| 00001590 24 0d 08 66 05 e1 0d 08 70 04 0d 08 7a 14 dd 20 |$..f....p...z.. | 000015a0 f2 73 65 6c 65 63 74 28 63 25 2c 6c 25 29 0d 08 |.select(c%,l%)..| 000015b0 84 08 ea 20 73 24 0d 08 8e 1d 73 24 20 3d 20 a4 |... s$....s$ = .| 000015c0 73 74 72 69 70 28 a4 6c 69 6e 65 28 63 25 2c 6c |strip(.line(c%,l| 000015d0 25 29 29 0d 08 98 37 e7 20 97 28 73 24 29 20 3d |%))...7. .(s$) =| 000015e0 20 97 28 22 2a 22 29 20 8c 20 c8 99 20 22 57 69 | .("*") . .. "Wi| 000015f0 6d 70 5f 53 74 61 72 74 54 61 73 6b 22 2c 73 24 |mp_StartTask",s$| 00001600 3a 71 75 69 74 25 20 3d 20 b9 0d 08 a2 05 e1 0d |:quit% = .......| 00001610 08 ac 04 0d 08 b6 04 0d 08 c0 19 dd 20 a4 6d 6f |............ .mo| 00001620 64 65 5f 63 68 61 6e 67 65 28 6d 6f 64 65 25 29 |de_change(mode%)| 00001630 0d 08 ca 19 ea 20 61 25 2c 62 25 2c 46 25 2c 59 |..... a%,b%,F%,Y| 00001640 45 69 67 46 61 63 74 6f 72 0d 08 d4 12 e7 20 eb |EigFactor..... .| 00001650 3d 6d 6f 64 65 25 20 8c 20 3d eb 0d 08 de 27 c8 |=mode% . =....'.| 00001660 99 20 22 5a 61 70 52 65 64 72 61 77 5f 52 65 61 |. "ZapRedraw_Rea| 00001670 64 56 64 75 56 61 72 73 22 2c 2c 72 65 64 72 61 |dVduVars",,redra| 00001680 77 25 0d 08 e8 33 c8 99 20 22 4f 53 5f 52 65 61 |w%...3.. "OS_Rea| 00001690 64 4d 6f 64 65 56 61 72 69 61 62 6c 65 22 2c 6d |dModeVariable",m| 000016a0 6f 64 65 25 2c 35 20 b8 20 2c 2c 59 45 69 67 46 |ode%,5 . ,,YEigF| 000016b0 61 63 74 6f 72 0d 08 f2 38 e7 20 59 45 69 67 46 |actor...8. YEigF| 000016c0 61 63 74 6f 72 3d 31 20 72 65 64 72 61 77 25 21 |actor=1 redraw%!| 000016d0 72 5f 66 6c 61 67 73 3d 32 20 8b 20 72 65 64 72 |r_flags=2 . redr| 000016e0 61 77 25 21 72 5f 66 6c 61 67 73 3d 30 0d 08 fc |aw%!r_flags=0...| 000016f0 24 3a f4 20 43 48 41 4e 47 45 20 54 4f 20 30 20 |$:. CHANGE TO 0 | 00001700 46 4f 52 20 53 49 4e 47 4c 45 20 48 45 49 47 48 |FOR SINGLE HEIGH| 00001710 54 0d 09 06 15 72 65 64 72 61 77 25 21 72 5f 63 |T....redraw%!r_c| 00001720 68 61 72 77 3d 38 0d 09 10 15 72 65 64 72 61 77 |harw=8....redraw| 00001730 25 21 72 5f 63 68 61 72 68 3d 38 0d 09 1a 1c 72 |%!r_charh=8....r| 00001740 65 64 72 61 77 25 21 72 5f 63 61 64 64 72 3d 62 |edraw%!r_caddr=b| 00001750 69 74 6d 61 70 73 25 0d 09 24 3f c8 99 20 22 5a |itmaps%..$?.. "Z| 00001760 61 70 52 65 64 72 61 77 5f 43 61 63 68 65 64 43 |apRedraw_CachedC| 00001770 68 61 72 53 69 7a 65 22 2c 72 65 64 72 61 77 25 |harSize",redraw%| 00001780 21 72 5f 62 70 70 2c 30 2c 38 2c 38 20 b8 20 2c |!r_bpp,0,8,8 . ,| 00001790 2c 61 25 2c 62 25 0d 09 2e 15 72 65 64 72 61 77 |,a%,b%....redraw| 000017a0 25 21 72 5f 63 62 70 6c 3d 61 25 0d 09 38 15 72 |%!r_cbpl=a%..8.r| 000017b0 65 64 72 61 77 25 21 72 5f 63 62 70 63 3d 62 25 |edraw%!r_cbpc=b%| 000017c0 0d 09 42 16 72 65 64 72 61 77 25 21 72 5f 6c 69 |..B.redraw%!r_li| 000017d0 6e 65 73 70 3d 32 0d 09 4c 37 c8 99 20 22 5a 61 |nesp=2..L7.. "Za| 000017e0 70 52 65 64 72 61 77 5f 43 6f 6e 76 65 72 74 42 |pRedraw_ConvertB| 000017f0 69 74 6d 61 70 22 2c 2c 72 65 64 72 61 77 25 2c |itmap",,redraw%,| 00001800 33 32 2c 35 31 31 2c 63 68 61 72 73 25 0d 09 56 |32,511,chars%..V| 00001810 1e 72 65 64 72 61 77 25 21 72 5f 70 61 6c 65 74 |.redraw%!r_palet| 00001820 74 65 3d 70 61 6c 65 74 74 65 25 0d 09 60 24 e3 |te=palette%..`$.| 00001830 20 46 25 3d 30 20 b8 20 31 35 3a 70 61 6c 65 74 | F%=0 . 15:palet| 00001840 74 65 25 21 28 34 2a 46 25 29 3d 46 25 3a ed 0d |te%!(4*F%)=F%:..| 00001850 09 6a 3f c8 99 20 22 5a 61 70 52 65 64 72 61 77 |.j?.. "ZapRedraw| 00001860 5f 43 72 65 61 74 65 50 61 6c 65 74 74 65 22 2c |_CreatePalette",| 00001870 33 2c 72 65 64 72 61 77 25 2c 70 61 6c 65 74 74 |3,redraw%,palett| 00001880 65 25 2c 70 61 6c 65 74 74 65 25 2c 31 36 0d 09 |e%,palette%,16..| 00001890 74 1b 72 65 64 72 61 77 25 21 72 5f 66 6f 72 3d |t.redraw%!r_for=| 000018a0 37 3a f4 20 62 6c 61 63 6b 0d 09 7e 1b 72 65 64 |7:. black..~.red| 000018b0 72 61 77 25 21 72 5f 62 61 63 3d 30 3a f4 20 77 |raw%!r_bac=0:. w| 000018c0 68 69 74 65 0d 09 88 06 3d eb 0d 09 92 04 0d 09 |hite....=.......| 000018d0 9c 0c dd 20 f2 65 72 72 6f 72 0d 09 a6 29 e7 20 |... .error...). | 000018e0 74 61 73 6b 25 3d 30 20 8c 20 f1 20 f6 24 2b 22 |task%=0 . . .$+"| 000018f0 20 61 74 20 6c 69 6e 65 20 22 2b c3 20 9e 2b bd | at line "+. .+.| 00001900 30 3a e0 0d 09 b0 10 21 77 69 6e 62 6c 6f 63 6b |0:.....!winblock| 00001910 25 3d 30 0d 09 ba 28 24 28 77 69 6e 62 6c 6f 63 |%=0...($(winbloc| 00001920 6b 25 2b 34 29 3d f6 24 2b 22 20 61 74 20 6c 69 |k%+4)=.$+" at li| 00001930 6e 65 20 22 2b c3 20 9e 2b bd 30 0d 09 c4 2b c8 |ne "+. .+.0...+.| 00001940 99 20 22 57 69 6d 70 5f 52 65 70 6f 72 74 45 72 |. "Wimp_ReportEr| 00001950 72 6f 72 22 2c 77 69 6e 62 6c 6f 63 6b 25 2c 30 |ror",winblock%,0| 00001960 2c 22 53 65 65 22 0d 09 ce 27 c8 99 20 22 57 69 |,"See"...'.. "Wi| 00001970 6d 70 5f 43 6c 6f 73 65 44 6f 77 6e 22 2c 74 61 |mp_CloseDown",ta| 00001980 73 6b 25 2c 26 34 42 35 33 34 31 35 34 0d 09 d8 |sk%,&4B534154...| 00001990 05 e0 0d 09 e2 04 0d 09 ec 1c dd 20 a4 64 65 63 |........... .dec| 000019a0 6f 64 65 28 69 6e 25 2c 20 f8 20 77 69 64 74 68 |ode(in%, . width| 000019b0 25 29 0d 09 f6 21 ea 20 41 25 2c 42 25 2c 43 25 |%)...!. A%,B%,C%| 000019c0 2c 6e 6c 69 6e 65 73 25 2c 6f 75 74 25 2c 73 69 |,nlines%,out%,si| 000019d0 7a 65 25 0d 0a 00 0c 41 25 20 3d 20 69 6e 25 0d |ze%....A% = in%.| 000019e0 0a 0a 37 d6 20 5f 63 61 6c 63 3a f4 20 48 6f 77 |..7. _calc:. How| 000019f0 20 6d 61 6e 79 20 6e 65 77 6c 69 6e 65 73 2c 20 | many newlines, | 00001a00 68 6f 77 20 6d 75 63 68 20 73 70 61 63 65 20 6e |how much space n| 00001a10 65 65 64 65 64 3f 0d 0a 14 25 73 69 7a 65 25 20 |eeded?...%size% | 00001a20 3d 20 21 5f 73 69 7a 65 3a 6e 6c 69 6e 65 73 25 |= !_size:nlines%| 00001a30 20 3d 20 21 5f 6e 6c 69 6e 65 73 0d 0a 1e 14 77 | = !_nlines....w| 00001a40 69 64 74 68 25 20 3d 20 21 5f 77 69 64 74 68 0d |idth% = !_width.| 00001a50 0a 28 10 de 20 6f 75 74 25 20 73 69 7a 65 25 0d |.(.. out% size%.| 00001a60 0a 32 19 21 28 6f 75 74 25 2b 6e 6c 69 6e 65 73 |.2.!(out%+nlines| 00001a70 25 2b 34 29 20 3d 20 30 0d 0a 3c 24 42 25 20 3d |%+4) = 0..<$B% =| 00001a80 20 6f 75 74 25 3a 43 25 20 3d 20 6f 75 74 25 20 | out%:C% = out% | 00001a90 2b 20 6e 6c 69 6e 65 73 25 20 2b 38 0d 0a 46 23 |+ nlines% +8..F#| 00001aa0 d6 20 5f 70 75 74 3a f4 20 70 72 65 70 61 72 65 |. _put:. prepare| 00001ab0 20 66 6f 72 20 5a 61 70 20 66 6f 72 6d 61 74 0d | for Zap format.| 00001ac0 0a 50 0a 3d 20 6f 75 74 25 0d 0a 5a 04 0d 0a 64 |.P.= out%..Z...d| 00001ad0 33 f4 20 70 61 72 74 20 6f 66 20 6c 25 2d 74 68 |3. part of l%-th| 00001ae0 20 6c 69 6e 65 20 63 6f 6e 74 61 69 6e 69 6e 67 | line containing| 00001af0 20 63 25 2d 74 68 20 63 68 61 72 61 63 74 65 72 | c%-th character| 00001b00 0d 0a 6e 12 dd 20 a4 6c 69 6e 65 28 63 25 2c 6c |..n.. .line(c%,l| 00001b10 25 29 0d 0a 78 14 ea 20 6c 69 6e 65 25 2c 69 25 |%)..x.. line%,i%| 00001b20 2c 78 25 2c 61 24 0d 0a 82 1c e7 20 34 2a 6c 25 |,x%,a$..... 4*l%| 00001b30 3e 3d 21 5f 6e 6c 69 6e 65 73 20 20 8c 20 3d 20 |>=!_nlines . = | 00001b40 22 22 0d 0a 8c 24 6c 69 6e 65 25 20 3d 20 69 6e |""...$line% = in| 00001b50 62 75 66 25 20 2b 20 28 69 6e 62 75 66 25 21 28 |buf% + (inbuf%!(| 00001b60 34 2a 6c 25 29 29 0d 0a 96 05 f5 0d 0a a0 1b 20 |4*l%))......... | 00001b70 61 24 20 3d 20 a4 67 65 74 73 74 72 69 6e 67 28 |a$ = .getstring(| 00001b80 6c 69 6e 65 25 29 0d 0a aa 10 20 63 25 20 2d 3d |line%).... c% -=| 00001b90 20 a9 28 61 24 29 0d 0a b4 10 20 78 25 20 3d 20 | .(a$).... x% = | 00001ba0 3f 6c 69 6e 65 25 0d 0a be 3d 20 e7 20 78 25 20 |?line%...= . x% | 00001bb0 3c 20 39 20 8c 20 6c 69 6e 65 25 20 2b 3d 20 6f |< 9 . line% += o| 00001bc0 66 66 73 65 74 25 28 78 25 29 20 8b 20 85 20 31 |ffset%(x%) . . 1| 00001bd0 30 30 2c 22 46 69 6c 65 20 63 6f 72 72 75 70 74 |00,"File corrupt| 00001be0 65 64 22 0d 0a c8 16 20 e7 20 78 25 20 3d 20 32 |ed".... . x% = 2| 00001bf0 20 8c 20 63 25 20 3d 20 30 0d 0a d2 0d fd 20 63 | . c% = 0..... c| 00001c00 25 20 3c 3d 20 30 0d 0a dc 07 3d 61 24 0d 0a e6 |% <= 0....=a$...| 00001c10 04 0d 0a f0 0f dd 20 f2 72 65 61 64 63 74 72 6c |...... .readctrl| 00001c20 0d 0a fa 2e f4 20 52 65 61 64 20 43 6f 6e 74 72 |..... Read Contr| 00001c30 6f 6c 20 63 68 61 72 61 63 74 65 72 73 20 20 3c |ol characters <| 00001c40 3c 3c 3c 3c 3c 3c 3c 3c 3c 3c 3c 3c 3c 3c 0d 0b |<<<<<<<<<<<<<<..| 00001c50 04 08 ea 20 63 25 0d 0b 0e 12 c8 8e 20 66 69 6c |... c%...... fil| 00001c60 65 74 79 70 65 25 20 ca 0d 0b 18 14 20 c9 20 53 |etype% ..... . S| 00001c70 65 65 46 69 6c 65 74 79 70 65 25 3a 0d 0b 22 1a |eeFiletype%:..".| 00001c80 20 20 63 6f 6d 6d 65 6e 74 25 20 3d 20 3f 66 69 | comment% = ?fi| 00001c90 6c 65 62 75 66 25 0d 0b 2c 31 20 20 e7 20 63 6f |lebuf%..,1 . co| 00001ca0 6d 6d 65 6e 74 25 3c 33 31 20 85 20 31 30 30 2c |mment%<31 . 100,| 00001cb0 22 42 61 64 20 63 6f 6d 6d 65 6e 74 20 63 68 61 |"Bad comment cha| 00001cc0 72 61 63 74 65 72 22 0d 0b 36 1e 20 20 63 68 61 |racter"..6. cha| 00001cd0 6e 67 65 66 6f 6e 74 25 20 3d 20 66 69 6c 65 62 |ngefont% = fileb| 00001ce0 75 66 25 3f 31 0d 0b 40 37 20 20 e7 20 63 68 61 |uf%?1..@7 . cha| 00001cf0 6e 67 65 66 6f 6e 74 25 3c 33 31 20 85 20 31 30 |ngefont%<31 . 10| 00001d00 30 2c 22 42 61 64 20 63 68 61 6e 67 65 66 6f 6e |0,"Bad changefon| 00001d10 74 20 63 68 61 72 61 63 74 65 72 22 0d 0b 4a 1d |t character"..J.| 00001d20 20 20 63 68 61 6e 67 65 66 6f 72 25 20 3d 20 66 | changefor% = f| 00001d30 69 6c 65 62 75 66 25 3f 32 0d 0b 54 3c 20 20 e7 |ilebuf%?2..T< .| 00001d40 20 63 68 61 6e 67 65 66 6f 72 25 3c 33 31 20 85 | changefor%<31 .| 00001d50 20 31 30 30 2c 22 42 61 64 20 63 68 61 6e 67 65 | 100,"Bad change| 00001d60 66 6f 72 65 67 72 6f 75 6e 64 20 63 68 61 72 61 |foreground chara| 00001d70 63 74 65 72 22 0d 0b 5e 1d 20 20 63 68 61 6e 67 |cter"..^. chang| 00001d80 65 62 61 63 25 20 3d 20 66 69 6c 65 62 75 66 25 |ebac% = filebuf%| 00001d90 3f 33 0d 0b 68 3c 20 20 e7 20 63 68 61 6e 67 65 |?3..h< . change| 00001da0 62 61 63 25 3c 33 31 20 85 20 31 30 30 2c 22 42 |bac%<31 . 100,"B| 00001db0 61 64 20 63 68 61 6e 67 65 62 61 63 6b 67 72 6f |ad changebackgro| 00001dc0 75 6e 64 20 63 68 61 72 61 63 74 65 72 22 0d 0b |und character"..| 00001dd0 72 13 20 20 66 69 6c 65 62 75 66 25 20 2b 3d 20 |r. filebuf% += | 00001de0 34 0d 0b 7c 14 20 20 63 25 20 3d 20 3f 66 69 6c |4..|. c% = ?fil| 00001df0 65 62 75 66 25 0d 0b 86 1b 20 20 c8 95 20 63 25 |ebuf%.... .. c%| 00001e00 20 3c 3e 20 31 30 20 80 20 63 25 20 3c 3e 20 30 | <> 10 . c% <> 0| 00001e10 0d 0b 90 15 20 20 20 20 66 69 6c 65 62 75 66 25 |.... filebuf%| 00001e20 20 2b 3d 20 31 0d 0b 9a 16 20 20 20 20 63 25 20 | += 1.... c% | 00001e30 3d 20 3f 66 69 6c 65 62 75 66 25 0d 0b a4 07 20 |= ?filebuf%.... | 00001e40 20 ce 0d 0b ae 24 20 20 e7 20 3f 66 69 6c 65 62 | ....$ . ?fileb| 00001e50 75 66 25 20 3d 20 31 30 20 66 69 6c 65 62 75 66 |uf% = 10 filebuf| 00001e60 25 20 2b 3d 20 31 0d 0b b8 07 20 7f 3a 0d 0b c2 |% += 1.... .:...| 00001e70 1f 20 20 f4 20 64 65 66 61 75 6c 74 73 20 66 6f |. . defaults fo| 00001e80 72 20 70 6c 61 69 6e 20 74 65 78 74 0d 0b cc 12 |r plain text....| 00001e90 20 20 63 6f 6d 6d 65 6e 74 25 20 3d 20 30 0d 0b | comment% = 0..| 00001ea0 d6 15 20 20 63 68 61 6e 67 65 66 6f 6e 74 25 20 |.. changefont% | 00001eb0 3d 20 30 0d 0b e0 14 20 20 63 68 61 6e 67 65 66 |= 0.... changef| 00001ec0 6f 72 25 20 3d 20 30 0d 0b ea 14 20 20 63 68 61 |or% = 0.... cha| 00001ed0 6e 67 65 62 61 63 25 20 3d 20 30 0d 0b f4 05 cb |ngebac% = 0.....| 00001ee0 0d 0b fe 05 e1 0d 0c 08 04 0d 0c 12 1e dd 20 f2 |.............. .| 00001ef0 61 73 6d 20 3a 20 f4 20 3c 3c 3c 3c 3c 3c 3c 3c |asm : . <<<<<<<<| 00001f00 3c 3c 3c 3c 3c 3c 3c 0d 0c 1c 0f 5b 20 4f 50 54 |<<<<<<<....[ OPT| 00001f10 20 70 61 73 73 25 0d 0c 26 09 2e 5f 70 75 74 0d | pass%..&.._put.| 00001f20 0c 30 0e 20 4d 4f 56 20 52 37 2c 23 30 0d 0c 3a |.0. MOV R7,#0..:| 00001f30 0e 20 4d 4f 56 20 52 35 2c 23 30 0d 0c 44 0e 20 |. MOV R5,#0..D. | 00001f40 4d 4f 56 20 52 36 2c 52 32 0d 0c 4e 0e 20 4d 4f |MOV R6,R2..N. MO| 00001f50 56 20 52 33 2c 52 30 0d 0c 58 10 20 4c 44 52 20 |V R3,R0..X. LDR | 00001f60 52 34 2c 5b 52 33 5d 0d 0c 62 0a 2e 77 68 69 6c |R4,[R3]..b..whil| 00001f70 65 0d 0c 6c 0f 20 20 43 4d 50 20 52 34 2c 23 30 |e..l. CMP R4,#0| 00001f80 0d 0c 76 0f 20 20 ec 51 20 50 43 2c 52 31 34 0d |..v. .Q PC,R14.| 00001f90 0c 80 12 20 20 53 55 42 20 52 39 2c 52 36 2c 52 |... SUB R9,R6,R| 00001fa0 31 0d 0c 8a 14 20 20 53 54 52 20 52 39 2c 5b 52 |1.... STR R9,[R| 00001fb0 31 2c 52 35 5d 0d 0c 94 12 20 20 41 44 44 20 52 |1,R5].... ADD R| 00001fc0 35 2c 52 35 2c 23 34 0d 0c 9e 0b 2e 72 65 70 65 |5,R5,#4.....repe| 00001fd0 61 74 0d 0c a8 17 20 20 20 20 4c 44 52 42 20 52 |at.... LDRB R| 00001fe0 34 2c 5b 52 33 5d 2c 23 31 0d 0c b2 11 20 20 20 |4,[R3],#1.... | 00001ff0 20 43 4d 50 20 52 34 2c 23 30 0d 0c bc 14 20 20 | CMP R4,#0.... | 00002000 20 20 43 4d 50 4e 45 20 52 34 2c 23 31 30 0d 0c | CMPNE R4,#10..| 00002010 c6 0f 20 20 20 20 42 45 51 20 4c 31 30 0d 0c d0 |.. BEQ L10...| 00002020 1b 20 20 20 20 43 4d 50 20 52 34 2c 23 63 68 61 |. CMP R4,#cha| 00002030 6e 67 65 66 6f 6e 74 25 0d 0c da 10 20 20 20 20 |ngefont%.... | 00002040 42 45 51 20 4c 31 36 30 0d 0c e4 1a 20 20 20 20 |BEQ L160.... | 00002050 43 4d 50 20 52 34 2c 23 63 68 61 6e 67 65 66 6f |CMP R4,#changefo| 00002060 72 25 0d 0c ee 1c 20 20 20 20 43 4d 50 4e 45 20 |r%.... CMPNE | 00002070 52 34 2c 23 63 68 61 6e 67 65 62 61 63 25 0d 0c |R4,#changebac%..| 00002080 f8 12 20 20 20 20 42 45 51 20 4c 70 6f 75 6e 64 |.. BEQ Lpound| 00002090 0d 0d 02 18 20 20 20 20 43 4d 50 20 52 34 2c 23 |.... CMP R4,#| 000020a0 63 6f 6d 6d 65 6e 74 25 0d 0d 0c 11 20 20 20 20 |comment%.... | 000020b0 42 45 51 20 4c 63 6f 6d 6d 0d 0d 16 0e 20 20 20 |BEQ Lcomm.... | 000020c0 20 2e 6f 74 68 65 72 0d 0d 20 11 20 20 20 20 43 | .other.. . C| 000020d0 4d 50 20 52 37 2c 23 30 0d 0d 2a 19 20 20 20 20 |MP R7,#0..*. | 000020e0 53 54 52 45 51 42 20 52 34 2c 5b 52 36 5d 2c 23 |STREQB R4,[R6],#| 000020f0 31 0d 0d 34 12 20 20 20 20 42 45 51 20 72 65 70 |1..4. BEQ rep| 00002100 65 61 74 0d 0d 3e 11 20 20 20 20 4d 4f 56 20 52 |eat..>. MOV R| 00002110 39 2c 23 30 0d 0d 48 17 20 20 20 20 53 54 52 42 |9,#0..H. STRB| 00002120 20 52 39 2c 5b 52 36 5d 2c 23 31 0d 0d 52 11 20 | R9,[R6],#1..R. | 00002130 20 20 20 4d 4f 56 20 52 39 2c 23 33 0d 0d 5c 17 | MOV R9,#3..\.| 00002140 20 20 20 20 53 54 52 42 20 52 39 2c 5b 52 36 5d | STRB R9,[R6]| 00002150 2c 23 31 0d 0d 66 17 20 20 20 20 53 54 52 42 20 |,#1..f. STRB | 00002160 52 34 2c 5b 52 36 5d 2c 23 31 0d 0d 70 11 20 20 |R4,[R6],#1..p. | 00002170 20 20 4d 4f 56 20 52 39 2c 23 31 0d 0d 7a 17 20 | MOV R9,#1..z. | 00002180 20 20 20 53 54 52 42 20 52 39 2c 5b 52 36 5d 2c | STRB R9,[R6],| 00002190 23 31 0d 0d 84 10 20 20 20 20 42 20 72 65 70 65 |#1.... B repe| 000021a0 61 74 0d 0d 8e 04 0d 0d 98 0e 20 20 20 20 2e 4c |at........ .L| 000021b0 63 6f 6d 6d 0d 0d a2 17 20 20 20 20 4c 44 52 42 |comm.... LDRB| 000021c0 20 52 34 2c 5b 52 33 5d 2c 23 31 0d 0d ac 11 20 | R4,[R3],#1.... | 000021d0 20 20 20 43 4d 50 20 52 34 2c 23 30 0d 0d b6 14 | CMP R4,#0....| 000021e0 20 20 20 20 43 4d 50 4e 45 20 52 34 2c 23 31 30 | CMPNE R4,#10| 000021f0 0d 0d c0 11 20 20 20 20 42 4e 45 20 4c 63 6f 6d |.... BNE Lcom| 00002200 6d 0d 0d ca 04 0d 0d d4 0c 20 20 20 20 2e 4c 31 |m........ .L1| 00002210 30 0d 0d de 11 20 20 20 20 4d 4f 56 20 52 39 2c |0.... MOV R9,| 00002220 23 30 0d 0d e8 17 20 20 20 20 53 54 52 42 20 52 |#0.... STRB R| 00002230 39 2c 5b 52 36 5d 2c 23 31 0d 0d f2 11 20 20 20 |9,[R6],#1.... | 00002240 20 4d 4f 56 20 52 39 2c 23 32 0d 0d fc 17 20 20 | MOV R9,#2.... | 00002250 20 20 53 54 52 42 20 52 39 2c 5b 52 36 5d 2c 23 | STRB R9,[R6],#| 00002260 31 0d 0e 06 0f 20 20 20 20 42 20 77 68 69 6c 65 |1.... B while| 00002270 0d 0e 10 04 0d 0e 1a 0d 20 20 20 20 2e 4c 31 36 |........ .L16| 00002280 30 0d 0e 24 12 20 20 20 20 82 20 52 37 2c 52 37 |0..$. . R7,R7| 00002290 2c 23 31 0d 0e 2e 12 20 20 20 20 4d 4f 56 20 52 |,#1.... MOV R| 000022a0 39 2c 23 33 32 0d 0e 38 17 20 20 20 20 53 54 52 |9,#32..8. STR| 000022b0 42 20 52 39 2c 5b 52 36 5d 2c 23 31 0d 0e 42 10 |B R9,[R6],#1..B.| 000022c0 20 20 20 20 42 20 72 65 70 65 61 74 0d 0e 4c 04 | B repeat..L.| 000022d0 0d 0e 56 0f 20 20 20 20 2e 4c 70 6f 75 6e 64 0d |..V. .Lpound.| 000022e0 0e 60 14 20 20 20 20 4c 44 52 42 20 52 38 2c 5b |.`. LDRB R8,[| 000022f0 52 33 5d 0d 0e 6a 13 20 20 20 20 43 4d 50 20 52 |R3]..j. CMP R| 00002300 38 2c 23 26 33 30 0d 0e 74 11 20 20 20 20 42 43 |8,#&30..t. BC| 00002310 43 20 6f 74 68 65 72 0d 0e 7e 13 20 20 20 20 43 |C other..~. C| 00002320 4d 50 20 52 38 2c 23 26 33 41 0d 0e 88 18 20 20 |MP R8,#&3A.... | 00002330 20 20 53 55 42 43 43 20 52 38 2c 52 38 2c 23 26 | SUBCC R8,R8,#&| 00002340 33 30 0d 0e 92 13 20 20 20 20 42 43 43 20 72 65 |30.... BCC re| 00002350 61 64 6f 75 74 0d 0e 9c 13 20 20 20 20 43 4d 50 |adout.... CMP| 00002360 20 52 38 2c 23 26 34 31 0d 0e a6 11 20 20 20 20 | R8,#&41.... | 00002370 42 43 43 20 6f 74 68 65 72 0d 0e b0 13 20 20 20 |BCC other.... | 00002380 20 43 4d 50 20 52 38 2c 23 26 34 37 0d 0e ba 11 | CMP R8,#&47....| 00002390 20 20 20 20 42 43 53 20 6f 74 68 65 72 0d 0e c4 | BCS other...| 000023a0 17 20 20 20 20 53 55 42 43 43 20 52 38 2c 52 38 |. SUBCC R8,R8| 000023b0 2c 23 35 35 0d 0e ce 04 0d 0e d8 10 20 20 20 20 |,#55........ | 000023c0 2e 72 65 61 64 6f 75 74 0d 0e e2 14 20 20 20 20 |.readout.... | 000023d0 41 44 44 20 52 33 2c 52 33 2c 23 31 0d 0e ec 11 |ADD R3,R3,#1....| 000023e0 20 20 20 20 4d 4f 56 20 52 39 2c 23 30 0d 0e f6 | MOV R9,#0...| 000023f0 17 20 20 20 20 53 54 52 42 20 52 39 2c 5b 52 36 |. STRB R9,[R6| 00002400 5d 2c 23 31 0d 0f 00 11 20 20 20 20 4d 4f 56 20 |],#1.... MOV | 00002410 52 39 2c 23 36 0d 0f 0a 1a 20 20 20 20 43 4d 50 |R9,#6.... CMP| 00002420 20 52 34 2c 23 63 68 61 6e 67 65 66 6f 72 25 0d | R4,#changefor%.| 00002430 0f 14 16 20 20 20 20 41 44 44 4e 45 20 52 39 2c |... ADDNE R9,| 00002440 52 39 2c 23 31 0d 0f 1e 17 20 20 20 20 53 54 52 |R9,#1.... STR| 00002450 42 20 52 39 2c 5b 52 36 5d 2c 23 31 0d 0f 28 17 |B R9,[R6],#1..(.| 00002460 20 20 20 20 53 54 52 42 20 52 38 2c 5b 52 36 5d | STRB R8,[R6]| 00002470 2c 23 31 0d 0f 32 10 20 20 20 20 42 20 72 65 70 |,#1..2. B rep| 00002480 65 61 74 0d 0f 3c 04 0d 0f 46 14 2e 5f 73 69 7a |eat..<...F.._siz| 00002490 65 20 20 20 20 45 51 55 44 20 30 0d 0f 50 14 2e |e EQUD 0..P..| 000024a0 5f 6e 6c 69 6e 65 73 20 20 45 51 55 44 20 30 0d |_nlines EQUD 0.| 000024b0 0f 5a 14 2e 5f 77 69 64 74 68 20 20 20 45 51 55 |.Z.._width EQU| 000024c0 44 20 30 0d 0f 64 08 2e 6f 75 74 0d 0f 6e 11 20 |D 0..d..out..n. | 000024d0 20 20 20 43 4d 50 20 52 36 2c 52 37 0d 0f 78 13 | CMP R6,R7..x.| 000024e0 20 20 20 20 4d 4f 56 43 53 20 52 37 2c 52 36 0d | MOVCS R7,R6.| 000024f0 0f 82 14 20 20 20 20 41 44 44 20 52 35 2c 52 31 |... ADD R5,R1| 00002500 2c 52 33 0d 0f 8c 14 20 20 20 20 41 44 44 20 52 |,R3.... ADD R| 00002510 35 2c 52 35 2c 23 39 0d 0f 96 14 20 20 20 20 53 |5,R5,#9.... S| 00002520 54 52 20 52 35 2c 5f 73 69 7a 65 0d 0f a0 16 20 |TR R5,_size.... | 00002530 20 20 20 53 54 52 20 52 31 2c 5f 6e 6c 69 6e 65 | STR R1,_nline| 00002540 73 0d 0f aa 15 20 20 20 20 53 54 52 20 52 37 2c |s.... STR R7,| 00002550 5f 77 69 64 74 68 0d 0f b4 12 20 20 20 20 4d 4f |_width.... MO| 00002560 56 20 50 43 2c 52 31 34 0d 0f be 0a 2e 5f 63 61 |V PC,R14....._ca| 00002570 6c 63 0d 0f c8 11 20 20 20 20 4d 4f 56 20 52 31 |lc.... MOV R1| 00002580 2c 23 30 0d 0f d2 11 20 20 20 20 4d 4f 56 20 52 |,#0.... MOV R| 00002590 33 2c 23 30 0d 0f dc 11 20 20 20 20 4d 4f 56 20 |3,#0.... MOV | 000025a0 52 34 2c 23 30 0d 0f e6 20 20 20 20 20 4d 4f 56 |R4,#0... MOV| 000025b0 20 52 36 2c 23 30 20 20 3b 20 77 69 64 74 68 20 | R6,#0 ; width | 000025c0 63 6f 75 6e 74 0d 0f f0 1e 20 20 20 20 4d 4f 56 |count.... MOV| 000025d0 20 52 37 2c 23 30 20 20 3b 20 77 69 64 74 68 20 | R7,#0 ; width | 000025e0 6d 61 78 0d 0f fa 0e 20 20 20 20 42 20 6c 6f 6f |max.... B loo| 000025f0 70 0d 10 04 0c 2e 65 6e 64 6c 69 6e 65 0d 10 0e |p.....endline...| 00002600 14 20 20 20 20 41 44 44 20 52 31 2c 52 31 2c 23 |. ADD R1,R1,#| 00002610 34 0d 10 18 14 20 20 20 20 41 44 44 20 52 33 2c |4.... ADD R3,| 00002620 52 33 2c 23 32 0d 10 22 11 20 20 20 20 43 4d 50 |R3,#2..". CMP| 00002630 20 52 36 2c 52 37 0d 10 2c 22 20 20 20 20 4d 4f | R6,R7..," MO| 00002640 56 43 53 20 52 37 2c 52 36 20 20 20 20 3b 20 72 |VCS R7,R6 ; r| 00002650 65 73 65 74 20 6d 61 78 0d 10 36 25 20 20 20 20 |eset max..6% | 00002660 4d 4f 56 20 52 36 2c 23 30 20 20 20 20 20 20 3b |MOV R6,#0 ;| 00002670 20 7a 65 72 6f 20 63 6f 75 6e 74 65 72 0d 10 40 | zero counter..@| 00002680 09 2e 6c 6f 6f 70 0d 10 4a 17 20 20 20 20 4c 44 |..loop..J. LD| 00002690 52 42 20 52 32 2c 5b 52 30 5d 2c 23 31 0d 10 54 |RB R2,[R0],#1..T| 000026a0 11 20 20 20 20 43 4d 50 20 52 32 2c 23 30 0d 10 |. CMP R2,#0..| 000026b0 5e 0f 20 20 20 20 42 45 51 20 6f 75 74 0d 10 68 |^. BEQ out..h| 000026c0 12 20 20 20 20 43 4d 50 20 52 32 2c 23 31 30 0d |. CMP R2,#10.| 000026d0 10 72 13 20 20 20 20 42 45 51 20 65 6e 64 6c 69 |.r. BEQ endli| 000026e0 6e 65 0d 10 7c 1b 20 20 20 20 43 4d 50 20 52 32 |ne..|. CMP R2| 000026f0 2c 23 63 68 61 6e 67 65 66 6f 6e 74 25 0d 10 86 |,#changefont%...| 00002700 14 20 20 20 20 82 45 51 20 52 34 2c 52 34 2c 23 |. .EQ R4,R4,#| 00002710 31 0d 10 90 16 20 20 20 20 41 44 44 45 51 20 52 |1.... ADDEQ R| 00002720 33 2c 52 33 2c 23 31 0d 10 9a 10 20 20 20 20 42 |3,R3,#1.... B| 00002730 45 51 20 6c 6f 6f 70 0d 10 a4 1a 20 20 20 20 43 |EQ loop.... C| 00002740 4d 50 20 52 32 2c 23 63 68 61 6e 67 65 66 6f 72 |MP R2,#changefor| 00002750 25 0d 10 ae 1c 20 20 20 20 43 4d 50 4e 45 20 52 |%.... CMPNE R| 00002760 32 2c 23 63 68 61 6e 67 65 62 61 63 25 0d 10 b8 |2,#changebac%...| 00002770 16 20 20 20 20 41 44 44 45 51 20 52 33 2c 52 33 |. ADDEQ R3,R3| 00002780 2c 23 33 0d 10 c2 10 20 20 20 20 42 45 51 20 6c |,#3.... BEQ l| 00002790 6f 6f 70 0d 10 cc 11 20 20 20 20 43 4d 50 20 52 |oop.... CMP R| 000027a0 34 2c 23 30 0d 10 d6 16 20 20 20 20 41 44 44 45 |4,#0.... ADDE| 000027b0 51 20 52 33 2c 52 33 2c 23 31 0d 10 e0 16 20 20 |Q R3,R3,#1.... | 000027c0 20 20 41 44 44 4e 45 20 52 33 2c 52 33 2c 23 34 | ADDNE R3,R3,#4| 000027d0 0d 10 ea 14 20 20 20 20 41 44 44 20 52 36 2c 52 |.... ADD R6,R| 000027e0 36 2c 23 31 0d 10 f4 0e 20 20 20 20 42 20 6c 6f |6,#1.... B lo| 000027f0 6f 70 0d 10 fe 05 5d 0d 11 08 05 e1 0d ff |op....].......| 000027fe