Home » Personal collection » Acorn ADFS disks » Archimedes » Dominic_2.ADF » PrinterDMs/!PrinterDM/!RunImage
PrinterDMs/!PrinterDM/!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 » Personal collection » Acorn ADFS disks » Archimedes » Dominic_2.ADF |
Filename: | PrinterDMs/!PrinterDM/!RunImage |
Read OK: | ✔ |
File size: | 5B5C bytes |
Load address: | FFFFFB41 |
Exec address: | 5BADE454 |
Duplicates
There are 3 duplicate copies of this file in the archive:
- Personal collection » Acorn ADFS disks » Archimedes » Dominic_2.ADF » PrinterDMs/!PrinterDM/!RunImage
- Personal collection » Acorn ADFS disks » Greaseweazled » adfs_Dominic_2.adf » PrinterDMs/!PrinterDM/!RunImage
- Personal collection » Acorn ADFS disks » Greaseweazled » adfs_Dominic_2B.adf » PrinterDMs/!PrinterDM/!RunImage
- Personal collection » Acorn hard disk » apps » Printers » RiscOs2/!PrinterDM/!RunImage
File contents
10REM >!RunImage Version 0.82 20REM Purpose: printer independent part of printer application 30REM Authors: DTee, AThompson, NReeves 40LIBRARY "<PDriver$dir>.Library" 50PROCinit 60ON ERROR PROCerror(ERR,REPORT$) 70REPEAT 80 SYS "Wimp_Poll",poll_mask%,event% TO action% 90 PROCdespatch_poll 100UNTIL FALSE 110END 120: 130DEFPROCdespatch_poll 140 IF NOT FNPrinter_process_event(action%, event%) THEN 150 CASE action% OF 160 WHEN 0: PROCcopy 170 WHEN 1: PROCredraw(!event%) 180 IF !event%=confirm% THEN PROCendconfirm 190 WHEN 2: IF !event%<>confirm% THEN PROCendconfirm 200 PROCopen(!event%,event%!4,event%!8,event%!12,event%!16,event%!20,event%!24,event%!28) 210 WHEN 3: PROCendconfirm 220 PROCclose(!event%) 230 WHEN 6: PROCmouse(!event%,event%!4,event%!8,event%!12,event%!16,event%!20) 240 PROCendconfirm 250 WHEN 9: PROCdecodemenu(menuhandle%, event%) 260 PROCgetpointer:IF buttons%AND1 THEN PROCremenu 270 WHEN 17,18:PROCreceive(event%) 280 WHEN 19:PROCbounced(event%) 290 ENDCASE 300 ENDIF 310ENDPROC 320: 330DEF FNp_field(size%) 340 printer_field% += size% 350 = printer_field% - size% 360: 370DEF PROCinit 380LOCAL ERROR 390in_file%=0 400out_file%=0 410REM define printer class independent fields in printer data area 420printer_field% = 0 430 list_pointer_field% = FNp_field(4) 440 pxres_field% = FNp_field(4) 450 pyres_field% = FNp_field(4) 460 features_field% = FNp_field(4) 470 description_field% = FNp_field(4) 480pxres_halftone_field% = FNp_field(4) 490pyres_halftone_field% = FNp_field(4) 500printer_number_field% = FNp_field(4) 510 page_width_field% = FNp_field(4) 520 page_height_field% = FNp_field(4) 530 page_bottom_field% = FNp_field(4) 540 page_top_field% = FNp_field(4) 550 page_left_field% = FNp_field(4) 560 page_right_field% = FNp_field(4) 570REM define class independent icons in main window 580main_description% = 1 590REM mark configure options as unset initially 600 printer_ptr% = -1 610printer_config% = 0 620 printer_new% = 0 630 location_ptr% = -1 640 baud_ptr% = -1 650 data_ptr% = -1 660 XON_ptr% = -1 670 server_ptr% = -1 680 feed_ptr% = -1 690REM message values 700Message_PrintFile% =&80140 710Message_WillPrint% =&80141 720Message_PrintSave% =&80142 730Message_PrintInit% =&80143 740Message_PrintBusy% =&80144 750Message_PrintTypeOdd% =&80145 760Message_PrintTypeKnown%=&80146 770Message_SetPrinter% =&80147 780REM dimension system arrays 790DIM q% &800 800DIM event% &800 810maxbuf%=&800 820DIM curbuf% maxbuf%: endbuf% = curbuf%+maxbuf% 830DIM menufree% &800: menuend% = menufree%+&800 840DIM icon_buf% 40 850DIM text_buffer% 12, valid_buffer% 12 860DIM block% 20 870DIM error_blk% 256 880DIM msg% 256 890bufsz%=256 900DIM buf% bufsz% 910REM set up colours 920`wbcol=&0:`wfcol=&7:`tfcol=&7 930REM initial mask state 940poll_mask% = NOT(%111 << 17): REM only messages 950confirm_answer% = 0 : REM not inside FNconfirm currently 960PROCPrinter_initialise 970Printer$=PrinterClass$ 980save_name$="" 990print_ref%=0 1000REM Initialise WIMP 1010DIM taskid% 5: $taskid%="TASK" 1020SYS "Wimp_Initialise",200,!taskid%,Printer$ TO ,task_handle% 1030ON ERROR LOCAL PROCerror(ERR, REPORT$):PROCterminate 1040msg%!0=20 1050msg%!12=0 1060msg%!16=Message_PrintInit% 1070SYS "Wimp_SendMessage", 18, msg%, 0 1080ENDPROC 1090: 1100DEF PROCinit2 1110LOCAL S$ 1120LOCAL ERROR 1130REM load the template file 1140SYS "Wimp_OpenTemplate",,"<PDriver$dir>.Templates" 1150main% = FNwindow("main") 1160confirm% = FNwindow("confirm") 1170info% = FNwindow("info") 1180PROCPrinter_load_templates 1190SYS "Wimp_CloseTemplate" 1200printer_type$ = "" 1210icprint%=FNiconbar 1220REM create the menu tree 1230DIM server_new% 8 1240$server_new% = "" 1250DIM file_name% 201 1260SYS "XOS_ReadVarVal","PrinterType$5",file_name%,200 TO ,,L% 1270IF L% THEN 1280 file_name%?L% = 13 1290ELSE 1300 $file_name%="<PDriver$Dir>.^.PrintData" 1310ENDIF 1320baudm% = FNcrmenu("#Baud;75;150;300;1200;2400;4800;9600;19200;50;110;134.5;600;1800;3600;7200") 1330bitsm% = FNcrmenu("#Bits;5;6;7;8") 1340paritym% = FNcrmenu("#Parity;off;odd;even;1 on TX;0 on TX") 1350stopm% = FNcrmenu("#Stop bits;1;2 (1.5 if 5 bits parity,1 if 8 bits no parity)") 1360datam% = FNcrmenu("#Data format;Bits>bitsm%;Parity>paritym%;Stop bits>stopm%") 1370serialm% = FNcrmenu("#Serial;Baud rate>baudm%;Data format>datam%;XON / XOFF") 1380netprintm% = FNcrmenu("#Net print;$server_new%(8)") 1390filemenu% = FNcrmenu("#File name;$file_name%(200)") 1400printmenu% = FNcrmenu("#"+Printer$+";Info>info%#;Parallel;Serial>serialm%;Network>netprintm%;File>filemenu%#;Save choices;Stop printing;Quit") 1410PROCset_print_state(FALSE) 1420PROCdefaults 1430PROCPrinter_set_initial_state 1440ON ERROR LOCAL PROCerror(ERR, REPORT$):ENDPROC 1450PROCchange_icon 1460ENDPROC 1470: 1480DEF PROCSaveConfig 1490out_file%=OPENUP"<PDriver$dir>.PrData" 1500IF printer_ptr% <> -1 THEN 1510 IF printer_config% <> printer_new% THEN 1520 PTR#out_file% = printer_ptr% 1530 BPUT#out_file%,RIGHT$("0"+STR$printer_new%,2); 1540 printer_config% = printer_new% 1550 ENDIF 1560ENDIF 1570IF location_new%=5 AND FNlowercase(LEFT$($file_name%,5))="null:" THEN 1580 IF location_config% <> location_new% THEN 1590 IF location_ptr% <> -1 THEN 1600 PTR#out_file% = location_ptr% 1610 BPUT#out_file%,"0"; 1620 ENDIF 1630 location_config%=location_new% 1640 ENDIF 1650 SYS"OS_CLI","Configure Print 0" 1660ELSE 1670 IF location_config% <> location_new% THEN 1680 IF location_ptr% <> -1 THEN 1690 PTR#out_file% = location_ptr% 1700 BPUT#out_file%,STR$location_new%; 1710 ENDIF 1720 location_config%=location_new% 1730 ENDIF 1740 SYS"XOS_CLI","Configure Print "+STR$location_new% 1750ENDIF 1760IF baud_config% <> baud_new% THEN 1770 IF baud_ptr% <> -1 THEN 1780 PTR#out_file%=baud_ptr% 1790 BPUT#out_file%,STR$baud_new%; 1800 ENDIF 1810 baud_config% = baud_new% 1820ENDIF 1830IF location_new%=2 AND baud_new%<=7 THEN SYS"OS_CLI","Configure Baud "+STR$(baud_new%+1) 1840IF data_config% <> data_new% THEN 1850 IF data_ptr% <> -1 THEN 1860 PTR#out_file%=data_ptr% 1870 A$=STR$~(data_new%):IF LENA$=1 A$="0"+A$ 1880 BPUT#out_file%,"&"+A$; 1890 ENDIF 1900 data_config% = data_new% 1910ENDIF 1920IF XON_config% <> XON_new% THEN 1930 IF XON_ptr% <> -1 THEN 1940 PTR#out_file%=XON_ptr% 1950 BPUT#out_file%,STR$XON_new%; 1960 ENDIF 1970 XON_config% = XON_new% 1980ENDIF 1990IF server_config$ <> $server_new% THEN 2000 IF server_ptr% <> -1 THEN 2010 PTR#out_file%=server_ptr% 2020 BPUT#out_file%,$server_new%+STRING$(8-LEN$server_new%,";"); 2030 ENDIF 2040 server_config$ = $server_new% 2050ENDIF 2060IF location_new%=4 THEN 2070 SYS"XOS_CLI","Configure PS "+$server_new% 2080 SYS"XOS_CLI","PS "+$server_new% 2090ENDIF 2100PROCPrinter_AmendConfig 2110CLOSE#out_file%:out_file%=0 2120ENDPROC 2130: 2140DEFPROCterminate 2150*unset $Printing 2160ON ERROR SYS"Wimp_CloseDown":END 2170PROCPrinter_terminate 2180IF in_file%<>0 SYS"XOS_Find",0,in_file%:in_file%=0 2190IF out_file%<>0 PROCEscOn:SYS"XOS_Find",0,out_file%:out_file%=0:PROCEscOff 2200SYS"Wimp_CloseDown" 2210END 2220: 2230DEF PROCdefaults 2240LOCAL ramval%, temp% 2250data_new%=data_config% 2260PROCset_tick(bitsm%,3-(data_new% AND 3),1) 2270IF data_new% AND (1<<3) THEN 2280 PROCset_tick(paritym%,((data_new% >> 4) AND 3)+1,1) 2290ELSE 2300 PROCset_tick(paritym%,0,1) 2310ENDIF 2320PROCset_tick(stopm%,(data_new%>>2) AND 1,1) 2330PROCset_tick(serialm%, 2, XON_new%) 2340SYS "OS_Byte", 161, 15 TO ,,temp% 2350IF baud_ptr% = -1 THEN baud_config% = (temp% AND %00011100) >> 2 2360baud_new% = baud_config% 2370IF location_ptr%=-1 THEN location_config% = (temp% AND %11100000) >> 5 2380IF location_config% = 2 THEN 2390 SYS"OS_Byte",8,baud_new%+1 2400 SYS"OS_Byte",7,baud_new%+1 2410 SYS"OS_SerialOp",1,data_new% 2420 SYS"OS_SerialOp",0,XON_new%,NOT1 2430 PROCPrinter_Ignore 2440 PROCPrinter_XonXoff(XON_new%) 2450ENDIF 2460IF location_config% = 0 THEN $file_name% = "null:":location_config%=5 2470PROCset_tick(baudm%, baud_new%, 1) 2480CASE location_config% OF 2490 WHEN 1: PROCset_tick(printmenu%, 1, 1) 2500 WHEN 2: PROCset_tick(printmenu%, 2, 1) 2510 WHEN 4: PROCset_tick(printmenu%, 3, 1) 2520 WHEN 5: PROCset_tick(printmenu%, 4, 1) 2530ENDCASE 2540location_new% = location_config% 2550IF location_new%=5 PROCstamp 2560IF server_ptr% = -1 THEN 2570 SYS "OS_Byte", 161, 3 TO ,,temp% 2580 IF temp% = 0 THEN 2590 SYS "OS_Byte", 161, 4 TO ,,temp% 2600 server_config$ = CHR$(temp%) 2610 ramval% = &99 2620 REPEAT 2630 SYS "OS_Byte", 161, ramval% TO ,,temp% 2640 IF temp% >32 server_config$ = server_config$ + CHR$(temp%) 2650 ramval% += 1 2660 UNTIL temp% <= 32 OR ramval% = &9E 2670 ELSE 2680 server_config$ = "."+STR$(temp%) 2690 SYS "OS_Byte", 161, 4 TO ,,temp% 2700 server_config$ = STR$(temp%) + server_config$ 2710 ENDIF 2720ENDIF 2730$server_new% = server_config$ 2740ENDPROC 2750: 2760DEF PROCredraw(handle%) 2770ENDPROC 2780: 2790DEF PROCreceive(message%) 2800LOCAL my_ref%, type$, option$, I%, pflag% 2810my_ref% = message%!8 2820CASE message%!16 OF 2830 WHEN 0,Message_PrintBusy% 2840 PROCendconfirm 2850 PROCterminate 2860 WHEN 1,Message_PrintSave% 2870 REM save onto our icon; reply with Print message 2880 FOR I%=0TO252STEP4:msg%!I%=message%!I%:NEXT 2890 PROCendconfirm 2900 IF print_ref% THEN PROCmoan("Can only print one file at a time") 2910 save_name$=FNrtoz(message%+44) 2920 IF print_on% THEN 2930 IF message%!16=1 THEN 2940 PROCmoan("Already printing") 2950 ELSE 2960 msg%!0 = 20 2970 msg%!12 = my_ref% 2980 msg%!16 = Message_PrintBusy% 2990 SYS "Wimp_SendMessage", 17, msg%, msg%!4 3000 ENDIF 3010 ELSE 3020 msg%!12 = my_ref% 3030 msg%!16 = Message_PrintFile% 3040 IF message%!16=1 THEN 3050 msg%!0 = 60 3060 $(msg%+44) = "<Printer$Scrap>" 3070 msg%?59 = 0 3080 ENDIF 3090 SYS "Wimp_SendMessage", 18, msg%, msg%!4 3100 msg%!4 = message%!4 3110 print_ref%=msg%!8 3120 ENDIF 3130 WHEN 3 3140 PROCendconfirm 3150 IF print_ref% IF print_ref%<>message%!12 THEN PROCmoan("Can only print one file at a time") 3160 print_ref%=0 3170 IF print_on% THEN 3180 PROCmoan("Already printing") 3190 ELSE 3200 FOR I%=0TO252STEP4:msg%!I%=message%!I%:NEXT 3210 filenam$=FNrtoz(message%+44) 3220 message%!12 = my_ref% 3230 SYS "Wimp_SendMessage",19,message%,message%!4 3240 REM just ack the message in case FNconfirm called 3250 Ftype%=message%!40 3260 type_state%=0 3270 IF Ftype%<>OutputType% THEN 3280 msg%!12=0 3290 msg%!16=Message_PrintTypeOdd% 3300 SYS"Wimp_SendMessage", 18, msg%, 0 3310 print_ref%=msg%!8 3320 REPEAT 3330 SYS "Wimp_Poll",poll_mask%,event% TO action% 3340 PROCdespatch_poll 3350 UNTIL type_state% 3360 ENDIF 3370 pflag%=FALSE 3380 IF type_state%=2 THEN 3390 IF filenam$ = "<Printer$Scrap>" THEN OSCLI("remove "+filenam$) 3400 in_file%=OPENIN"<Printer$Temp>" 3410 IF in_file%<>0 THEN 3420 filenam$ = "<Printer$Temp>" 3430 CLOSE#in_file%:in_file%=0 3440 pflag%=TRUE 3450 ENDIF 3460 ELSE 3470 IF FNcheck_type THEN 3480 IF Alias$ <> "" THEN 3490 SYS "Wimp_StartTask",Alias$+" "+filenam$ 3500 in_file%=OPENIN"<Printer$Temp>" 3510 IF in_file%<>0 THEN 3520 filenam$ = "<Printer$Temp>" 3530 IF filenam$ = "<Printer$Scrap>" THEN OSCLI("remove "+filenam$) 3540 CLOSE#in_file%:in_file%=0 3550 pflag%=TRUE 3560 ENDIF 3570 ELSE 3580 pflag%=TRUE 3590 ENDIF 3600 ENDIF 3610 ENDIF 3620 IF pflag% THEN 3630 IF location_new% = 4 THEN 3640 type$ = "netprint#"+printer_type$+":$" 3650 ELSE 3660 IF location_new% = 5 THEN OSCLI("set PrinterType$5 "+$file_name%) 3670 type$="printer:$" 3680 SYS"OS_Byte",5,location_new% 3690 ENDIF 3700 REM filenam$ is also used in PROCcopy 3710 in_file% = OPENIN(filenam$) 3720 IF in_file% = 0 THEN 3730 PROCmoan("Can't open '"+filenam$+"' for printing") 3740 ENDIF 3750 out_file% = OPENOUT(type$+".output") 3760 IF out_file% = 0 THEN 3770 CLOSE#in_file%:in_file%=0 3780 PROCmoan("Can't open '"+type$+".output' for printing") 3790 ENDIF 3800 PROCset_print_state(TRUE) 3810 PROCchange_icon:PROCupdate_icon 3820 pbuf%=ADVAL(-4) 3830 sent%=FALSE 3840 PROCPrinter_Header 3850 ENDIF 3860 REM indicate we received the file OK 3870 msg%!0 = 20 3880 msg%!12 = my_ref% 3890 msg%!16 = 4 3900 msg%!36 = -1 3910 SYS"Wimp_SendMessage", 17, msg%, msg%!4 3920 ENDIF 3930 WHEN &502: REM help request 3940 IF message%!32=-2 AND message%!36=icprint% PROChelpreply("This is the "+FullPrinterClass$+" printer icon.|MDrop text files on to it to print them.|MClick MENU or SELECT to set the printer options.",my_ref%,message%!4) 3950 WHEN Message_WillPrint% 3960 print_ref%=0 3970 WHEN Message_PrintInit% 3980 IF poll_mask%<>NOT(%111 << 17) THEN 3990 IF print_on% THEN 4000 msg%!0=20 4010 msg%!12=my_ref% 4020 msg%!16=Message_PrintBusy% 4030 SYS "Wimp_SendMessage", 17, msg%, message%!4 4040 ELSE 4050 PROCterminate 4060 ENDIF 4070 ENDIF 4080 WHEN Message_PrintTypeKnown% 4090 Ftype%=message%!40 4100 type_state%=2 4110 print_ref%=0 4120ENDCASE 4130ENDPROC 4140: 4150DEFPROChelpreply(help$, ref%, to%) 4160msg%!0 = 256 4170msg%!12 = ref% 4180msg%!16 = &503 4190$(msg%+20) = help$ 4200PROCzero_terminate(msg%+20) 4210SYS "Wimp_SendMessage", 17, msg%, to% 4220ENDPROC 4230: 4240DEFPROCbounced(message%) 4250CASE message%!16 OF 4260 WHEN Message_PrintFile% 4270 print_ref%=0 4280 REM must be an app that can't do its own printing; reply to message 4290 REM still in msg% 4300 PROCendconfirm 4310 IF NOT print_on% THEN 4320 REM can't ask for confirmation of stupid types as an affirmative 4330 REM click will probably shut down the transfer at the source 4340 msg%!16 = 2 4350 msg%!36 = -1 : REM file is not safe 4360 SYS "Wimp_SendMessage", 17, msg%, msg%!4 4370 ELSE 4380 PROCmoan("Already printing") 4390 ENDIF 4400 WHEN Message_PrintInit% 4410 PROCinit2 4420 poll_mask%=1 4430 WHEN Message_PrintTypeOdd% 4440 type_state%=1 4450 print_ref%=0 4460ENDCASE 4470ENDPROC 4480: 4490DEFFNcheck_type 4500LOCAL L%,psr%, type$ 4510Alias$="" 4520REM if an Alias$@PrintType_<Ftype%> exists then print via that 4530type$ = STR$~Ftype% 4540IF LENtype$ < 3 THEN type$ = STRING$(3-LENtype$,"0")+type$ 4550SYS"XOS_ReadVarVal","Alias$@PrintType_"+type$,,-1 TO ,,L% 4560IF L% < 0 THEN Alias$="@PrintType_"+type$: = TRUE 4570IF Ftype% = &FFF OR Ftype% = &FFE OR Ftype% = &FEB OR Ftype%=OutputType% THEN =TRUE 4580REM text, exec and obey files are all straight text 4590IF Ftype% = &1000 THEN PROCmoan("Cannot print directories") 4600IF Ftype% = &2000 THEN PROCmoan("Cannot print applications") 4610IF Ftype% = &3000 THEN 4620 $error_blk% = "an untyped" 4630ELSE 4640 SYS"XOS_ReadVarVal","File$Type_"+type$,error_blk%,100 TO ,,L%;psr% 4650 IF psr% AND 1 THEN $error_blk%="type &"+STR$~Ftype% ELSE error_blk%?L% = 13 4660ENDIF 4670=FNconfirm("This is a "+$error_blk%+" file; do you really want to print it?") 4680: 4690DEFFNconfirm(message$) 4700LOCAL S%, action% 4710S%=FNiconaddr(confirm%,0) 4720$S%=message$ 4730PROCgetpointer 4740SYS "Wimp_CreateMenu",,confirm%,mousex%-200,mousey%+200 4750confirm_answer% = 2 4760REPEAT 4770 SYS "Wimp_Poll",poll_mask%,event% TO action% 4780 PROCdespatch_poll 4790UNTIL confirm_answer% <> 2 4800PROCclose(confirm%) 4810=confirm_answer% 4820: 4830DEFPROCendconfirm 4840IF confirm_answer% = 2 THEN confirm_answer%=FALSE 4850REM FNconfirm closes the window if necessary 4860ENDPROC 4870: 4880DEF FNrtoz(s%) 4890LOCAL n$ 4900WHILE?s%:n$+=CHR$?s%:s%+=1:ENDWHILE 4910=n$ 4920: 4930DEF PROCcopy 4940LOCAL L% 4950LOCAL ERROR 4960ON ERROR LOCAL RESTORE ERROR:PROCerror(ERR, REPORT$):PROCstop_printing:ENDPROC 4970IF sent% THEN 4980 IF ADVAL(-4)>=pbuf% THEN 4990 PROCPrinter_Footer 5000 CLOSE#in_file%:in_file%=0 5010 PROCEscOn:CLOSE#out_file%:out_file%=0:PROCEscOff 5020 PROCstop_printing 5030 ENDIF 5040ELSE 5050 IF location_new%=1 OR location_new%=2 THEN 5060 L%=ADVAL(-4) 5070 IF L%>bufsz% L%=bufsz% 5080 ELSE 5090 L%=128 5100 ENDIF 5110 sent%=FNPrinter_Send(L%) 5120ENDIF 5130ENDPROC 5140: 5150DEFPROCstop_printing 5160PROCset_print_state(FALSE) 5170PROCchange_icon:PROCupdate_icon 5180IF in_file% SYS"XOS_Find",0,in_file%:in_file%=0 5190IF out_file% PROCEscOn:SYS"XOS_Find",0,out_file%:out_file%=0:PROCEscOff 5200IF filenam$ = "<Printer$Scrap>" THEN OSCLI("remove "+filenam$) 5210IF filenam$ = "<Printer$Temp>" THEN OSCLI("remove "+filenam$) 5220REM delete the scrap file: now finished with 5230PROCupdate_icon 5240ENDPROC 5250: 5260DEF PROCmouse(mousex%,mousey%,buttons%,handle%,icon%,oldbuttons%) 5270CASE buttons% OF 5280 WHEN 4: REM left hand click 5290 CASE handle% OF 5300 WHEN -2: 5310 PROCfront(main%) 5320 WHEN confirm%: 5330 IF icon%=1 THEN confirm_answer%=TRUE 5340 IF icon%=2 THEN confirm_answer%=FALSE 5350 ENDCASE 5360 WHEN 2: REM menu button 5370 CASE handle% OF 5380 WHEN -2: PROCmenu(printmenu%) 5390 ENDCASE 5400ENDCASE 5410ENDPROC 5420: 5430DEF PROCdecodemenu(menuhandle%,menus%) 5440CASE menuhandle% OF 5450 WHEN printmenu% 5460 IF print_on% AND (!menus%<5) THEN ENDPROC 5470 CASE !menus% OF 5480 WHEN 1 5490 PROCtickit(printmenu%, 1, 4) 5500 location_new% = 1 5510 *FX 5,1 5520 WHEN 2 5530 PROCPrinter_Ignore 5540 PROCdecodemenu(serialm%, menus%+4) 5550 PROCtickit(printmenu%, 2, 4) 5560 location_new% = 2 5570 SYS "OS_Byte", 8, baud_new%+1 5580 SYS "OS_Byte", 7, baud_new%+1 5590 SYS "OS_SerialOp",1,data_new% 5600 SYS "OS_SerialOp",0,XON_new%,NOT 1 5610 PROCPrinter_XonXoff(XON_new%) 5620 *FX 5,2 5630 WHEN 3 5640 PROCdecodemenu(netprintm%, menus%+4) 5650 PROCtickit(printmenu%, 3, 4) 5660 location_new% = 4 5670 SYS "XOS_CLI","PS "+$server_new% 5680 *FX 5,4 5690 WHEN 4 5700 location_new%=5 5710 PROCtickit(printmenu%, 4, 4) 5720 IF LEN$file_name%=0 THEN $file_name%="<PDriver$Dir>.^.PrintData" 5730 SYS "XOS_CLI","Set PrinterType$5 "+$file_name% 5740 PROCstamp 5750 *FX 5,5 5760 WHEN 5 5770 PROCSaveConfig 5780 WHEN 6 5790 IF print_on% THEN 5800 *FX 21,3 5810 PROCstop_printing 5820 ENDIF 5830 WHEN 7 5840 IF print_on% THEN 5850 *FX 21,3 5860 PROCstop_printing 5870 ENDIF 5880 PROCterminate 5890 ENDCASE 5900 PROCchange_icon 5910 WHEN serialm% 5920 CASE !menus% OF 5930 WHEN 0 5940 PROCdecodemenu(baudm%, menus%+4) 5950 WHEN 1 5960 PROCdecodemenu(datam%, menus%+4) 5970 WHEN 2 5980 XON_new% = XON_new% EOR 1 5990 PROCset_tick(serialm%,2,XON_new%) 6000 ENDCASE 6010 WHEN baudm% 6020 IF !menus% <> -1 THEN 6030 PROCtickit(baudm%, !menus%, 14) 6040 baud_new%=!menus% 6050 ENDIF 6060 WHEN datam% 6070 CASE !menus% OF 6080 WHEN 0 6090 PROCdecodemenu(bitsm%, menus%+4) 6100 WHEN 1 6110 PROCdecodemenu(paritym%, menus%+4) 6120 WHEN 2 6130 PROCdecodemenu(stopm%, menus%+4) 6140 ENDCASE 6150 WHEN bitsm% 6160 IF !menus% <> -1 THEN 6170 data_new%=(data_new% AND %111100)+3-!menus% 6180 PROCtickit(bitsm%, !menus%, 3) 6190 ENDIF 6200 WHEN paritym% 6210 IF !menus% <> -1 THEN 6220 IF !menus% THEN 6230 data_new% = (data_new% AND %111)+8+((!menus%-1)<<4) 6240 ELSE 6250 data_new% = data_new% AND NOT(1<<3) 6260 ENDIF 6270 PROCtickit(paritym%, !menus%, 4) 6280 ENDIF 6290 WHEN stopm% 6300 IF !menus% <> -1 THEN 6310 data_new%=(data_new% AND %111011) EOR (!menus%<<2) 6320 PROCtickit(stopm%, !menus%, 1) 6330 ENDIF 6340ENDCASE 6350PROCupdate_icon 6360ENDPROC 6370: 6380DEF PROCupdate_icon 6390block%!0 = -2 6400block%!4 = icprint% 6410block%!8 = 0 6420block%!12 = 0 6430SYS "Wimp_SetIconState",,block% 6440ENDPROC 6450: 6460DEF PROCtickit(menu%, item%, nitems%) 6470LOCAL I% 6480FOR I%=0 TO nitems% 6490 PROCset_tick(menu%, I%, 0) 6500NEXT 6510PROCset_tick(menu%, item%, 1) 6520ENDPROC 6530: 6540DEF PROCfront(h%) 6550!q%=h% 6560SYS "Wimp_GetWindowState",,q% : q%!28=-1 6570SYS "Wimp_OpenWindow",,q% 6580ENDPROC 6590: 6600DEF PROCopen(handle%,x0%,y0%,x1%,y1%,scx%,scy%,bhandle%) 6610!q%=handle% 6620q%!4=x0%:q%!8=y0%:q%!12=x1%:q%!16=y1% 6630q%!20=scx%:q%!24=scy% 6640q%!28=bhandle% 6650SYS "Wimp_OpenWindow",,q% 6660ENDPROC 6670: 6680DEF PROCclose(handle%) 6690!q%=handle%:SYS "Wimp_CloseWindow",,q% 6700ENDPROC 6710: 6720DEF FNwindow(a$) 6730LOCAL c% 6740SYS "Wimp_LoadTemplate",,q%,curbuf%,endbuf%,-1,a$,0 TO ,,curbuf%,,,,c% 6750IF c%=0 THEN PROCmoan("Template '"+a$+"' not found") 6760SYS "Wimp_CreateWindow",,q% TO c% 6770=c% 6780: 6790DEF FNiconaddr(h%,i%) 6800!q%=h%:q%!4=i%:SYS "Wimp_GetIconState",,q% 6810IF (q%!24 AND &100)=0 THEN PROCmoan("Icon is not indirected") 6820=q%!28 6830: 6840DEF PROCmenu(m%) 6850LOCAL Y% 6860Y% = mousey% 6870IF Y%<496 THEN Y%=496 6880menuhandle%=m% 6890SYS "Wimp_CreateMenu",,menuhandle%,mousex%-66,Y% 6900ENDPROC 6910: 6920DEF PROCremenu 6930LOCAL Y% 6940Y% = mousey% 6950IF Y% < 300 THEN Y% = 316 6960SYS "Wimp_CreateMenu",,menuhandle%,mousex%-66,Y% :REM default coords 6970ENDPROC 6980: 6990DEF FNcrmenu(menu$) 7000IF menufree%+28 > menuend% THEN PROCmoan("Menu area full") 7010LOCAL m%,i% 7020menuptr%=menufree% 7030i%=0 7040IF LEFT$(menu$,1)="#" THEN i%=1:menutitle$=FNpar(";") ELSE menutitle$="" 7050$menuptr%=menutitle$ 7060menuptr%?12=`tfcol:menuptr%?13=2:menuptr%?14=`wfcol:menuptr%?15=`wbcol 7070menuptr%!16=196-24:menuptr%!20=44:menuptr%!24=0 7080menuptr%+=28:maxx%=LENmenutitle$-3 7090REPEAT item$=FNpar(";"):PROCmenuitem(item$):UNTIL item$="" 7100m%=menufree%:m%!16=(maxx%*8+6)*2 7110menufree%=menuptr% 7120=m% 7130: 7140DEF PROCmenuitem(text$) 7150IF text$="" THEN menuptr%!-24=(menuptr%!-24)OR&80:ENDPROC 7160IF menuptr%+24 > menuend% THEN PROCmoan("Menu area full") 7170LOCALi%,flg%,V% 7180flg%=&00 7190i%=INSTR(text$,">") 7200IF RIGHT$(text$,1)="#" THEN text$=LEFT$(text$,LENtext$-1):flg%+=&02 7210IFi%>0THENsubptr%=EVALMID$(text$,i%+1):text$=LEFT$(text$,i%-1)ELSEsubptr%=-1 7220menuptr%!0=flg% 7230menuptr%!4=subptr% 7240menuptr%!8=&07000021 7250IFLEFT$(text$,1)="$"THEN 7260 !menuptr%+=&04 7270 menuptr%!8+=&108 7280 i%=INSTR(text$,"(") 7290 IFi%>0THENL%=VALMID$(text$,i%+1):text$=LEFT$(text$,i%-1)ELSEL%=12 7300 V% = -1 7310 menuptr%!12=EVALMID$(text$,2) 7320 menuptr%!16=-1 7330 menuptr%!20=L% 7340 text$=STRING$(L%," ") 7350 IF maxx%<20 THEN maxx%=20 7360ELSE 7370 IFLENtext$<=12THEN 7380 $(menuptr%+12)=text$ 7390 ELSE I%=FNworkspace(LENtext$+1):$I%=text$ 7400 menuptr%!12=I%:menuptr%!16=-1:menuptr%!20=LENtext$+1 7410 menuptr%!8=menuptr%!8 OR &100 7420 ENDIF 7430IFLENtext$>maxx% THENmaxx%=LENtext$ 7440ENDIF 7450menuptr%+=24 7460ENDPROC 7470: 7480DEF FNworkspace(L%) 7490DIM L% L% 7500= L% 7510: 7520DEF FNpar(sep$) 7530i1%=i%+1:i%=INSTR(menu$+sep$,sep$,i1%) 7540=MID$(menu$,i1%,i%-i1%) 7550: 7560DEF PROCshade(menuhandle%, item%) 7570menuhandle%!(28+8+24*item%)=menuhandle%!(28+8+24*item%)EOR&400000:ENDPROC 7580: 7590DEF FNshade_status(menuhandle%,item%) = -((menuhandle%!(28+8+24*item%) AND &400000)=&400000) 7600: 7610DEF PROCset_shade(menuhandle%, item%, value%) 7620LOCAL st% 7630st% = FNshade_status(menuhandle%, item%) 7640IF value% <> st% THEN PROCshade(menuhandle%, item%) 7650ENDPROC 7660: 7670DEF PROCtick(menuhandle%,item%) 7680menuhandle%!(28+24*item%)=menuhandle%!(28+24*item%)EOR&01 7690ENDPROC 7700: 7710DEF FNtick_status(menuhandle%, item%) = menuhandle%!(28+24*item%)AND1 7720: 7730DEF PROCset_tick(menuhandle%, item%, value%) 7740IF FNtick_status(menuhandle%, item%)<>value% THEN PROCtick(menuhandle%, item%) 7750ENDPROC 7760: 7770DEF PROCset_print_state(flag%) 7780PROCset_shade(printmenu%,1,-flag%) 7790PROCset_shade(printmenu%,2,-flag%) 7800PROCset_shade(printmenu%,3,-flag%) 7810PROCset_shade(printmenu%,4,-flag%) 7820PROCset_shade(printmenu%,5,-flag%) 7830PROCset_shade(printmenu%,6,(1+flag%)) 7840PROCset_shade(printmenu%,7,-flag%) 7850print_on%=flag% 7860poll_mask%=(poll_mask% AND NOT1) OR (1+flag%) 7870IF flag% THEN 7880 *set $Printing "T" 7890ELSE 7900 *unset $Printing 7910ENDIF 7920ENDPROC 7930: 7940DEF FNread_icon_data(handle%, icon%) 7950!icon_buf% = handle% 7960icon_buf%!4 = icon% 7970SYS "Wimp_GetIconState", , icon_buf% 7980IF icon_buf%!28 < curbuf% THEN =$(icon_buf%!28) ELSE = $(icon_buf%+28) 7990: 8000DEF PROCset_icon_state(handle%, icon%, eor%, mask%) 8010!icon_buf% = handle% 8020icon_buf%!4 = icon% 8030icon_buf%!8 = eor% 8040icon_buf%!12 = mask% 8050SYS "Wimp_SetIconState",,icon_buf% 8060ENDPROC 8070: 8080DEF FNiconbar 8090LOCAL I% 8100icon_buf%!0 =-2 8110icon_buf%!4 =0 8120icon_buf%!8 =-16 8130icon_buf%!12=144 8140icon_buf%!16= 86 8150icon_buf%!20= &1700312B: REM 0001 0111 0000 0000 0011 0001 0010 1011 8160$text_buffer% = printer_type$ 8170$valid_buffer% = "S!"+Printer$ 8180icon_buf%!24= text_buffer% 8190icon_buf%!28 = valid_buffer% 8200icon_buf%!32 = LEN($text_buffer%)+1 8210SYS "Wimp_CreateIcon",,icon_buf% TO I% 8220=I% 8230: 8240DEF PROCchange_icon 8250PROCset_ptype 8260$text_buffer% = printer_type$ 8270ENDPROC 8280: 8290DEFPROCset_ptype 8300IF print_on% THEN 8310 printer_type$ = "Printing" 8320ELSE 8330SYS"OS_Byte",5,location_new% 8340CASE location_new% OF 8350 WHEN 1: printer_type$ = "Parallel" 8360 WHEN 2: printer_type$ = "Serial" 8370 WHEN 4: printer_type$ = $server_new% 8380 WHEN 5: 8390 IF FNlowercase(LEFT$($file_name%,5))="null:" THEN 8400 printer_type$ = "To null:" 8410 ELSE 8420 printer_type$ = "To file" 8430 ENDIF 8440 OSCLI("set PrinterType$5 """+$file_name%+"""") 8450ENDCASE 8460ENDIF 8470ENDPROC 8480: 8490DEF PROCgetpointer 8500SYS "Wimp_GetPointerInfo",,q% 8510mousex%=!q%:mousey%=q%!4:buttons%=q%!8 8520handle%=q%!12:icon%=q%!16 8530ENDPROC 8540: 8550DEF PROCmoan(report$) 8560ERROR &20000,report$ 8570: 8580DEF PROCerror(err%, report$) 8590LOCAL stop% 8600PROCEscOff 8610stop%=(report$<>"Already printing") 8620IF (err%<&10100 OR err%>&20000) AND err%<>17 THEN report$=report$+" internal error "+STR$(ERL) 8630!error_blk% = err% 8640$(error_blk%+4)=report$ 8650PROCzero_terminate(error_blk%+4) 8660IF stop% IF print_on% THEN *FX 21,3 8670SYS "Wimp_ReportError", error_blk%, 1, Printer$ 8680PROCendconfirm 8690IF stop% THEN 8700 IF print_on% PROCstop_printing 8710 IF in_file% SYS"XOS_Find",0,in_file%:in_file%=0 8720 IF out_file% PROCEscOn:SYS"XOS_Find",0,out_file%:out_file%=0:PROCEscOff 8730ENDIF 8740ENDPROC 8750: 8760DEFPROCzero_terminate(S%) 8770S%?LEN$S% = 0 8780ENDPROC 8790: 8800DEFFNlowercase(S$) 8810LOCAL R$, C% 8820R$="" 8830WHILE LENS$>0 8840 C% = ASCLEFT$(S$,1) 8850 S$ = RIGHT$(S$,LENS$-1) 8860 IF C%>=ASC"A" AND C%<=ASC"Z" THEN C% = C% - ASC"A" + ASC"a" 8870 R$ += CHR$C% 8880ENDWHILE 8890=R$ 8900: 8910DEF PROCstamp 8920LOCAL load% 8930LOCAL ERROR 8940ON ERROR LOCAL ENDPROC 8950SYS "OS_File",5,file_name% TO ,,load% 8960IF (load%>>>8) <> &FFF000 + OutputType% THEN SYS "OS_File",11,file_name%,OutputType% 8970ENDPROC 8980: 8990DEF PROCEscOn 9000*FX 229 9010ENDPROC 9020: 9030DEF PROCEscOff 9040*FX 229,1 9050ENDPROC
� >!RunImage Version 0.82 >� Purpose: printer independent part of printer application '� Authors: DTee, AThompson, NReeves (ț "<PDriver$dir>.Library" 2 �init <� � �error(�,�$) F� P/ ș "Wimp_Poll",poll_mask%,event% � action% Z �despatch_poll d� � n� x: ���despatch_poll �2 � � �Printer_process_event(action%, event%) � � Ȏ action% � � � 0: �copy � � 1: �redraw(!event%) �/ � !event%=confirm% � �endconfirm �- � 2: � !event%<>confirm% � �endconfirm �a �open(!event%,event%!4,event%!8,event%!12,event%!16,event%!20,event%!24,event%!28) � � 3: �endconfirm � �close(!event%) �K � 6: �mouse(!event%,event%!4,event%!8,event%!12,event%!16,event%!20) � �endconfirm �, � 9: �decodemenu(menuhandle%, event%) 1 �getpointer:� buttons%�1 � �remenu � 17,18:�receive(event%) � 19:�bounced(event%) " � , � 6� @: J� �p_field(size%) T printer_field% += size% ^ = printer_field% - size% h: r� �init |� � �in_file%=0 �out_file%=0 �B� define printer class independent fields in printer data area �printer_field% = 0 �' list_pointer_field% = �p_field(4) �' pxres_field% = �p_field(4) �' pyres_field% = �p_field(4) �' features_field% = �p_field(4) �' description_field% = �p_field(4) �'pxres_halftone_field% = �p_field(4) �'pyres_halftone_field% = �p_field(4) �'printer_number_field% = �p_field(4) �' page_width_field% = �p_field(4) ' page_height_field% = �p_field(4) ' page_bottom_field% = �p_field(4) ' page_top_field% = �p_field(4) &' page_left_field% = �p_field(4) 0' page_right_field% = �p_field(4) :3� define class independent icons in main window Dmain_description% = 1 N/� mark configure options as unset initially X printer_ptr% = -1 bprinter_config% = 0 l printer_new% = 0 v location_ptr% = -1 � baud_ptr% = -1 � data_ptr% = -1 � XON_ptr% = -1 � server_ptr% = -1 � feed_ptr% = -1 �� message values �"Message_PrintFile% =&80140 �"Message_WillPrint% =&80141 �"Message_PrintSave% =&80142 �"Message_PrintInit% =&80143 �"Message_PrintBusy% =&80144 �"Message_PrintTypeOdd% =&80145 �"Message_PrintTypeKnown%=&80146 "Message_SetPrinter% =&80147 � dimension system arrays � q% &800 � event% &800 *maxbuf%=&800 40� curbuf% maxbuf%: endbuf% = curbuf%+maxbuf% >/� menufree% &800: menuend% = menufree%+&800 H� icon_buf% 40 R'� text_buffer% 12, valid_buffer% 12 \� block% 20 f� error_blk% 256 p� msg% 256 zbufsz%=256 �� buf% bufsz% �� set up colours �!`wbcol=&0:`wfcol=&7:`tfcol=&7 �� initial mask state �/poll_mask% = �(%111 << 17): � only messages �:confirm_answer% = 0 : � not inside FNconfirm currently ��Printer_initialise �Printer$=PrinterClass$ �save_name$="" �print_ref%=0 �� Initialise WIMP � � taskid% 5: $taskid%="TASK" �>ș "Wimp_Initialise",200,!taskid%,Printer$ � ,task_handle% "� � � �error(�, �$):�terminate msg%!0=20 msg%!12=0 $msg%!16=Message_PrintInit% .&ș "Wimp_SendMessage", 18, msg%, 0 8� B: L� �init2 V� S$ `� � j� load the template file t5ș "Wimp_OpenTemplate",,"<PDriver$dir>.Templates" ~main% = �window("main") �!confirm% = �window("confirm") �info% = �window("info") ��Printer_load_templates �ș "Wimp_CloseTemplate" �printer_type$ = "" �icprint%=�iconbar �� create the menu tree �� server_new% 8 �$server_new% = "" �� file_name% 201 �=ș "XOS_ReadVarVal","PrinterType$5",file_name%,200 � ,,L% � � L% � file_name%?L% = 13 � , $file_name%="<PDriver$Dir>.^.PrintData" � (bbaudm% = �crmenu("#Baud;75;150;300;1200;2400;4800;9600;19200;50;110;134.5;600;1800;3600;7200") 2%bitsm% = �crmenu("#Bits;5;6;7;8") <>paritym% = �crmenu("#Parity;off;odd;even;1 on TX;0 on TX") FSstopm% = �crmenu("#Stop bits;1;2 (1.5 if 5 bits parity,1 if 8 bits no parity)") PQdatam% = �crmenu("#Data format;Bits>bitsm%;Parity>paritym%;Stop bits>stopm%") ZPserialm% = �crmenu("#Serial;Baud rate>baudm%;Data format>datam%;XON / XOFF") d6netprintm% = �crmenu("#Net print;$server_new%(8)") n6filemenu% = �crmenu("#File name;$file_name%(200)") x�printmenu% = �crmenu("#"+Printer$+";Info>info%#;Parallel;Serial>serialm%;Network>netprintm%;File>filemenu%#;Save choices;Stop printing;Quit") ��set_print_state(�) � �defaults ��Printer_set_initial_state �� � � �error(�, �$):� ��change_icon �� �: �� �SaveConfig �%out_file%=�"<PDriver$dir>.PrData" �� printer_ptr% <> -1 � �( � printer_config% <> printer_new% � � �#out_file% = printer_ptr% �( �#out_file%,�"0"+�printer_new%,2); $ printer_config% = printer_new% � � "=� location_new%=5 � �lowercase(�$file_name%,5))="null:" � ,* � location_config% <> location_new% � 6 � location_ptr% <> -1 � @" �#out_file% = location_ptr% J �#out_file%,"0"; T � ^$ location_config%=location_new% h � r# ș"OS_CLI","Configure Print 0" |� �* � location_config% <> location_new% � � � location_ptr% <> -1 � �" �#out_file% = location_ptr% �" �#out_file%,�location_new%; � � �$ location_config%=location_new% � � �2 ș"XOS_CLI","Configure Print "+�location_new% �� �!� baud_config% <> baud_new% � � � baud_ptr% <> -1 � � �#out_file%=baud_ptr% � �#out_file%,�baud_new%; � baud_config% = baud_new% � &R� location_new%=2 � baud_new%<=7 � ș"OS_CLI","Configure Baud "+�(baud_new%+1) 0!� data_config% <> data_new% � : � data_ptr% <> -1 � D �#out_file%=data_ptr% N( A$=�~(data_new%):� �A$=1 A$="0"+A$ X �#out_file%,"&"+A$; b � l data_config% = data_new% v� �� XON_config% <> XON_new% � � � XON_ptr% <> -1 � � �#out_file%=XON_ptr% � �#out_file%,�XON_new%; � � � XON_config% = XON_new% �� �&� server_config$ <> $server_new% � � � server_ptr% <> -1 � � �#out_file%=server_ptr% �5 �#out_file%,$server_new%+�8-�$server_new%,";"); � � �" server_config$ = $server_new% � � location_new%=4 � - ș"XOS_CLI","Configure PS "+$server_new% # ș"XOS_CLI","PS "+$server_new% *� 4�Printer_AmendConfig >�#out_file%:out_file%=0 H� R: \��terminate f*unset $Printing p� � ș"Wimp_CloseDown":� z�Printer_terminate �4� in_file%<>0 ș"XOS_Find",0,in_file%:in_file%=0 �F� out_file%<>0 �EscOn:ș"XOS_Find",0,out_file%:out_file%=0:�EscOff �ș"Wimp_CloseDown" �� �: �� �defaults �� ramval%, temp% �data_new%=data_config% �)�set_tick(bitsm%,3-(data_new% � 3),1) �� data_new% � (1<<3) � �3 �set_tick(paritym%,((data_new% >> 4) � 3)+1,1) �� � �set_tick(paritym%,0,1) � *�set_tick(stopm%,(data_new%>>2) � 1,1) $�set_tick(serialm%, 2, XON_new%) $#ș "OS_Byte", 161, 15 � ,,temp% .>� baud_ptr% = -1 � baud_config% = (temp% � %00011100) >> 2 8baud_new% = baud_config% BD� location_ptr%=-1 � location_config% = (temp% � %11100000) >> 5 L� location_config% = 2 � V ș"OS_Byte",8,baud_new%+1 ` ș"OS_Byte",7,baud_new%+1 j ș"OS_SerialOp",1,data_new% t" ș"OS_SerialOp",0,XON_new%,�1 ~ �Printer_Ignore � �Printer_XonXoff(XON_new%) �� �E� location_config% = 0 � $file_name% = "null:":location_config%=5 �#�set_tick(baudm%, baud_new%, 1) �Ȏ location_config% � �' � 1: �set_tick(printmenu%, 1, 1) �' � 2: �set_tick(printmenu%, 2, 1) �' � 4: �set_tick(printmenu%, 3, 1) �' � 5: �set_tick(printmenu%, 4, 1) �� �$location_new% = location_config% �� location_new%=5 �stamp � server_ptr% = -1 � # ș "OS_Byte", 161, 3 � ,,temp% � temp% = 0 � $ ș "OS_Byte", 161, 4 � ,,temp% ( server_config$ = �(temp%) 2 ramval% = &99 < � F+ ș "OS_Byte", 161, ramval% � ,,temp% P= � temp% >32 server_config$ = server_config$ + �(temp%) Z ramval% += 1 d# � temp% <= 32 � ramval% = &9E n � x# server_config$ = "."+�(temp%) �$ ș "OS_Byte", 161, 4 � ,,temp% �0 server_config$ = �(temp%) + server_config$ � � �� �!$server_new% = server_config$ �� �: �� �redraw(handle%) �� �: �� �receive(message%) �)� my_ref%, type$, option$, I%, pflag% �my_ref% = message%!8 Ȏ message%!16 � � 0,Message_PrintBusy% �endconfirm " �terminate , � 1,Message_PrintSave% 64 � save onto our icon; reply with Print message @( � I%=0�252�4:msg%!I%=message%!I%:� J �endconfirm T? � print_ref% � �moan("Can only print one file at a time") ^# save_name$=�rtoz(message%+44) h � print_on% � r � message%!16=1 � |! �moan("Already printing") � � � msg%!0 = 20 � msg%!12 = my_ref% �$ msg%!16 = Message_PrintBusy% �/ ș "Wimp_SendMessage", 17, msg%, msg%!4 � � � � � msg%!12 = my_ref% �# msg%!16 = Message_PrintFile% � � message%!16=1 � � msg%!0 = 60 �& $(msg%+44) = "<Printer$Scrap>" � msg%?59 = 0 � . ș "Wimp_SendMessage", 18, msg%, msg%!4 msg%!4 = message%!4 & print_ref%=msg%!8 0 � : � 3 D �endconfirm NY � print_ref% � print_ref%<>message%!12 � �moan("Can only print one file at a time") X print_ref%=0 b � print_on% � l �moan("Already printing") v � �) � I%=0�252�4:msg%!I%=message%!I%:� �" filenam$=�rtoz(message%+44) � message%!12 = my_ref% �3 ș "Wimp_SendMessage",19,message%,message%!4 �6 � just ack the message in case FNconfirm called � Ftype%=message%!40 � type_state%=0 � � Ftype%<>OutputType% � � msg%!12=0 �% msg%!16=Message_PrintTypeOdd% �) ș"Wimp_SendMessage", 18, msg%, 0 � print_ref%=msg%!8 � � 3 ș "Wimp_Poll",poll_mask%,event% � action% �despatch_poll � type_state% � * pflag%=� 4 � type_state%=2 � >> � filenam$ = "<Printer$Scrap>" � �("remove "+filenam$) H" in_file%=�"<Printer$Temp>" R � in_file%<>0 � \$ filenam$ = "<Printer$Temp>" f �#in_file%:in_file%=0 p pflag%=� z � � � � � �check_type � � � Alias$ <> "" � �1 ș "Wimp_StartTask",Alias$+" "+filenam$ �$ in_file%=�"<Printer$Temp>" � � in_file%<>0 � �& filenam$ = "<Printer$Temp>" �A � filenam$ = "<Printer$Scrap>" � �("remove "+filenam$) � �#in_file%:in_file%=0 � pflag%=� � � � � � pflag%=� � � � $ � pflag% � . � location_new% = 4 � 8/ type$ = "netprint#"+printer_type$+":$" B � LB � location_new% = 5 � �("set PrinterType$5 "+$file_name%) V type$="printer:$" `$ ș"OS_Byte",5,location_new% j � t+ � filenam$ is also used in PROCcopy ~ in_file% = �(filenam$) � � in_file% = 0 � �8 �moan("Can't open '"+filenam$+"' for printing") � � �& out_file% = �(type$+".output") � � out_file% = 0 � � �#in_file%:in_file%=0 �< �moan("Can't open '"+type$+".output' for printing") � � � �set_print_state(�) �! �change_icon:�update_icon � pbuf%=�(-4) � sent%=� �Printer_Header � ) � indicate we received the file OK msg%!0 = 20 ( msg%!12 = my_ref% 2 msg%!16 = 4 < msg%!36 = -1 F- ș"Wimp_SendMessage", 17, msg%, msg%!4 P � Z � &502: � help request d� � message%!32=-2 � message%!36=icprint% �helpreply("This is the "+FullPrinterClass$+" printer icon.|MDrop text files on to it to print them.|MClick MENU or SELECT to set the printer options.",my_ref%,message%!4) n � Message_WillPrint% x print_ref%=0 � � Message_PrintInit% �# � poll_mask%<>�(%111 << 17) � � � print_on% � � msg%!0=20 � msg%!12=my_ref% �" msg%!16=Message_PrintBusy% �3 ș "Wimp_SendMessage", 17, msg%, message%!4 � � � �terminate � � � � � � Message_PrintTypeKnown% � Ftype%=message%!40 type_state%=2 print_ref%=0 � "� ,: 6!��helpreply(help$, ref%, to%) @msg%!0 = 256 Jmsg%!12 = ref% Tmsg%!16 = &503 ^$(msg%+20) = help$ h�zero_terminate(msg%+20) r(ș "Wimp_SendMessage", 17, msg%, to% |� �: ���bounced(message%) �Ȏ message%!16 � � � Message_PrintFile% � print_ref%=0 �G � must be an app that can't do its own printing; reply to message � � still in msg% � �endconfirm � � � print_on% � �E � can't ask for confirmation of stupid types as an affirmative �A � click will probably shut down the transfer at the source � msg%!16 = 2 �+ msg%!36 = -1 : � file is not safe . ș "Wimp_SendMessage", 17, msg%, msg%!4 � �moan("Already printing") & � 0 � Message_PrintInit% : �init2 D poll_mask%=1 N � Message_PrintTypeOdd% X type_state%=1 b print_ref%=0 l� v� �: �ݤcheck_type �� L%,psr%, type$ � Alias$="" �@� if an Alias$@PrintType_<Ftype%> exists then print via that �type$ = �~Ftype% �/� �type$ < 3 � type$ = �3-�type$,"0")+type$ �;ș"XOS_ReadVarVal","Alias$@PrintType_"+type$,,-1 � ,,L% �.� L% < 0 � Alias$="@PrintType_"+type$: = � �M� Ftype% = &FFF � Ftype% = &FFE � Ftype% = &FEB � Ftype%=OutputType% � =� �5� text, exec and obey files are all straight text �8� Ftype% = &1000 � �moan("Cannot print directories") �9� Ftype% = &2000 � �moan("Cannot print applications") � Ftype% = &3000 � $error_blk% = "an untyped" � E ș"XOS_ReadVarVal","File$Type_"+type$,error_blk%,100 � ,,L%;psr% *D � psr% � 1 � $error_blk%="type &"+�~Ftype% � error_blk%?L% = 13 4� >P=�confirm("This is a "+$error_blk%+" file; do you really want to print it?") H: Rݤconfirm(message$) \� S%, action% fS%=�iconaddr(confirm%,0) p$S%=message$ z�getpointer �:ș "Wimp_CreateMenu",,confirm%,mousex%-200,mousey%+200 �confirm_answer% = 2 �� �/ ș "Wimp_Poll",poll_mask%,event% � action% � �despatch_poll �� confirm_answer% <> 2 ��close(confirm%) �=confirm_answer% �: ���endconfirm �-� confirm_answer% = 2 � confirm_answer%=� �.� FNconfirm closes the window if necessary �� : � �rtoz(s%) � n$ $ȕ?s%:n$+=�?s%:s%+=1:� .=n$ 8: B� �copy L� L% V� � `,� � � � �:�error(�, �$):�stop_printing:� j � sent% � t � �(-4)>=pbuf% � ~ �Printer_Footer � �#in_file%:in_file%=0 �, �EscOn:�#out_file%:out_file%=0:�EscOff � �stop_printing � � �� �* � location_new%=1 � location_new%=2 � � L%=�(-4) � � L%>bufsz% L%=bufsz% � � � L%=128 � � � sent%=�Printer_Send(L%) � � : ��stop_printing (�set_print_state(�) 2�change_icon:�update_icon <1� in_file% ș"XOS_Find",0,in_file%:in_file%=0 FC� out_file% �EscOn:ș"XOS_Find",0,out_file%:out_file%=0:�EscOff P:� filenam$ = "<Printer$Scrap>" � �("remove "+filenam$) Z9� filenam$ = "<Printer$Temp>" � �("remove "+filenam$) d.� delete the scrap file: now finished with n�update_icon x� �: �@� �mouse(mousex%,mousey%,buttons%,handle%,icon%,oldbuttons%) �Ȏ buttons% � � � 4: � left hand click � Ȏ handle% � � � -2: � �front(main%) � � confirm%: �% � icon%=1 � confirm_answer%=� �% � icon%=2 � confirm_answer%=� � � � � 2: � menu button � Ȏ handle% � � -2: �menu(printmenu%) � � "� ,: 6%� �decodemenu(menuhandle%,menus%) @Ȏ menuhandle% � J � printmenu% T# � print_on% � (!menus%<5) � � ^ Ȏ !menus% � h � 1 r! �tickit(printmenu%, 1, 4) | location_new% = 1 � *FX 5,1 � � 2 � �Printer_Ignore �' �decodemenu(serialm%, menus%+4) �! �tickit(printmenu%, 2, 4) � location_new% = 2 �$ ș "OS_Byte", 8, baud_new%+1 �$ ș "OS_Byte", 7, baud_new%+1 �$ ș "OS_SerialOp",1,data_new% �' ș "OS_SerialOp",0,XON_new%,� 1 �" �Printer_XonXoff(XON_new%) � *FX 5,2 � � 3 ) �decodemenu(netprintm%, menus%+4) ! �tickit(printmenu%, 3, 4) location_new% = 4 &' ș "XOS_CLI","PS "+$server_new% 0 *FX 5,4 : � 4 D location_new%=5 N! �tickit(printmenu%, 4, 4) XB � �$file_name%=0 � $file_name%="<PDriver$Dir>.^.PrintData" b5 ș "XOS_CLI","Set PrinterType$5 "+$file_name% l �stamp v *FX 5,5 � � 5 � �SaveConfig � � 6 � � print_on% � � *FX 21,3 � �stop_printing � � � � 7 � � print_on% � � *FX 21,3 � �stop_printing � � � �terminate � �change_icon � serialm% Ȏ !menus% � * � 0 4% �decodemenu(baudm%, menus%+4) > � 1 H% �decodemenu(datam%, menus%+4) R � 2 \ XON_new% = XON_new% � 1 f& �set_tick(serialm%,2,XON_new%) p � z � baudm% � � !menus% <> -1 � �# �tickit(baudm%, !menus%, 14) � baud_new%=!menus% � � � � datam% � Ȏ !menus% � � � 0 �% �decodemenu(bitsm%, menus%+4) � � 1 �' �decodemenu(paritym%, menus%+4) � � 2 �% �decodemenu(stopm%, menus%+4) � � � bitsm% � !menus% <> -1 � 0 data_new%=(data_new% � %111100)+3-!menus% $" �tickit(bitsm%, !menus%, 3) . � 8 � paritym% B � !menus% <> -1 � L � !menus% � V9 data_new% = (data_new% � %111)+8+((!menus%-1)<<4) ` � j' data_new% = data_new% � �(1<<3) t � ~$ �tickit(paritym%, !menus%, 4) � � � � stopm% � � !menus% <> -1 � �5 data_new%=(data_new% � %111011) � (!menus%<<2) �" �tickit(stopm%, !menus%, 1) � � �� ��update_icon �� �: �� �update_icon �block%!0 = -2 block%!4 = icprint% block%!8 = 0 block%!12 = 0 "ș "Wimp_SetIconState",,block% (� 2: <$� �tickit(menu%, item%, nitems%) F� I% P� I%=0 � nitems% Z �set_tick(menu%, I%, 0) d� n�set_tick(menu%, item%, 1) x� �: �� �front(h%) � !q%=h% �+ș "Wimp_GetWindowState",,q% : q%!28=-1 �ș "Wimp_OpenWindow",,q% �� �: �7� �open(handle%,x0%,y0%,x1%,y1%,scx%,scy%,bhandle%) �!q%=handle% �)q%!4=x0%:q%!8=y0%:q%!12=x1%:q%!16=y1% �q%!20=scx%:q%!24=scy% �q%!28=bhandle% �ș "Wimp_OpenWindow",,q% � : � �close(handle%) ")!q%=handle%:ș "Wimp_CloseWindow",,q% ,� 6: @� �window(a$) J� c% THș "Wimp_LoadTemplate",,q%,curbuf%,endbuf%,-1,a$,0 � ,,curbuf%,,,,c% ^1� c%=0 � �moan("Template '"+a$+"' not found") h#ș "Wimp_CreateWindow",,q% � c% r=c% |: �� �iconaddr(h%,i%) �-!q%=h%:q%!4=i%:ș "Wimp_GetIconState",,q% �8� (q%!24 � &100)=0 � �moan("Icon is not indirected") � =q%!28 �: �� �menu(m%) �� Y% �Y% = mousey% �� Y%<496 � Y%=496 �menuhandle%=m% �3ș "Wimp_CreateMenu",,menuhandle%,mousex%-66,Y% �� �: � �remenu � Y% Y% = mousey% &� Y% < 300 � Y% = 316 0Eș "Wimp_CreateMenu",,menuhandle%,mousex%-66,Y% :� default coords :� D: N� �crmenu(menu$) X7� menufree%+28 > menuend% � �moan("Menu area full") b� m%,i% lmenuptr%=menufree% vi%=0 �?� �menu$,1)="#" � i%=1:menutitle$=�par(";") � menutitle$="" �$menuptr%=menutitle$ �Jmenuptr%?12=`tfcol:menuptr%?13=2:menuptr%?14=`wfcol:menuptr%?15=`wbcol �3menuptr%!16=196-24:menuptr%!20=44:menuptr%!24=0 �$menuptr%+=28:maxx%=�menutitle$-3 �1� item$=�par(";"):�menuitem(item$):� item$="" �$m%=menufree%:m%!16=(maxx%*8+6)*2 �menufree%=menuptr% �=m% �: �� �menuitem(text$) �2� text$="" � menuptr%!-24=(menuptr%!-24)�&80:� �6� menuptr%+24 > menuend% � �moan("Menu area full") �i%,flg%,V% flg%=&00 i%=�text$,">") 6� �text$,1)="#" � text$=�text$,�text$-1):flg%+=&02 *=�i%>0�subptr%=��text$,i%+1):text$=�text$,i%-1)�subptr%=-1 4menuptr%!0=flg% >menuptr%!4=subptr% Hmenuptr%!8=&07000021 R�text$,1)="$"� \ !menuptr%+=&04 f menuptr%!8+=&108 p i%=�text$,"(") z4 �i%>0�L%=��text$,i%+1):text$=�text$,i%-1)�L%=12 � V% = -1 � menuptr%!12=��text$,2) � menuptr%!16=-1 � menuptr%!20=L% � text$=�L%," ") � � maxx%<20 � maxx%=20 �� � �text$<=12� � $(menuptr%+12)=text$ �( � I%=�workspace(�text$+1):$I%=text$ �8 menuptr%!12=I%:menuptr%!16=-1:menuptr%!20=�text$+1 �" menuptr%!8=menuptr%!8 � &100 � � �text$>maxx% �maxx%=�text$ � menuptr%+=24 $� .: 8� �workspace(L%) B� L% L% L= L% V: `� �par(sep$) j%i1%=i%+1:i%=�menu$+sep$,sep$,i1%) t=�menu$,i1%,i%-i1%) ~: � � �shade(menuhandle%, item%) �Emenuhandle%!(28+8+24*item%)=menuhandle%!(28+8+24*item%)�&400000:� �: �[� �shade_status(menuhandle%,item%) = -((menuhandle%!(28+8+24*item%) � &400000)=&400000) �: �,� �set_shade(menuhandle%, item%, value%) � � st% �+st% = �shade_status(menuhandle%, item%) �0� value% <> st% � �shade(menuhandle%, item%) �� �: �� �tick(menuhandle%,item%) ;menuhandle%!(28+24*item%)=menuhandle%!(28+24*item%)�&01 � : D� �tick_status(menuhandle%, item%) = menuhandle%!(28+24*item%)�1 (: 2+� �set_tick(menuhandle%, item%, value%) <J� �tick_status(menuhandle%, item%)<>value% � �tick(menuhandle%, item%) F� P: Z� �set_print_state(flag%) d#�set_shade(printmenu%,1,-flag%) n#�set_shade(printmenu%,2,-flag%) x#�set_shade(printmenu%,3,-flag%) �#�set_shade(printmenu%,4,-flag%) �#�set_shade(printmenu%,5,-flag%) �&�set_shade(printmenu%,6,(1+flag%)) �#�set_shade(printmenu%,7,-flag%) �print_on%=flag% �,poll_mask%=(poll_mask% � �1) � (1+flag%) � � flag% � � *set $Printing "T" �� � *unset $Printing �� �� �: %� �read_icon_data(handle%, icon%) !icon_buf% = handle% icon_buf%!4 = icon% "'ș "Wimp_GetIconState", , icon_buf% ,C� icon_buf%!28 < curbuf% � =$(icon_buf%!28) � = $(icon_buf%+28) 6: @2� �set_icon_state(handle%, icon%, eor%, mask%) J!icon_buf% = handle% Ticon_buf%!4 = icon% ^icon_buf%!8 = eor% hicon_buf%!12 = mask% r%ș "Wimp_SetIconState",,icon_buf% |� �: �� �iconbar �� I% �icon_buf%!0 =-2 �icon_buf%!4 =0 �icon_buf%!8 =-16 �icon_buf%!12=144 �icon_buf%!16= 86 �Gicon_buf%!20= &1700312B: � 0001 0111 0000 0000 0011 0001 0010 1011 �#$text_buffer% = printer_type$ �#$valid_buffer% = "S!"+Printer$ �icon_buf%!24= text_buffer% � icon_buf%!28 = valid_buffer% %icon_buf%!32 = �($text_buffer%)+1 (ș "Wimp_CreateIcon",,icon_buf% � I% =I% &: 0� �change_icon :�set_ptype D!$text_buffer% = printer_type$ N� X: b��set_ptype l� print_on% � v printer_type$ = "Printing" �� �ș"OS_Byte",5,location_new% �Ȏ location_new% � �$ � 1: printer_type$ = "Parallel" �" � 2: printer_type$ = "Serial" �& � 4: printer_type$ = $server_new% � � 5: �- � �lowercase(�$file_name%,5))="null:" � �! printer_type$ = "To null:" � � � printer_type$ = "To file" � � �0 �("set PrinterType$5 """+$file_name%+"""") !� !� !� ! : !*� �getpointer !4 ș "Wimp_GetPointerInfo",,q% !>*mousex%=!q%:mousey%=q%!4:buttons%=q%!8 !Hhandle%=q%!12:icon%=q%!16 !R� !\: !f� �moan(report$) !p� &20000,report$ !z: !�� �error(err%, report$) !�� stop% !��EscOff !�'stop%=(report$<>"Already printing") !�V� (err%<&10100 � err%>&20000) � err%<>17 � report$=report$+" internal error "+�(�) !�!error_blk% = err% !�$(error_blk%+4)=report$ !�!�zero_terminate(error_blk%+4) !�"� stop% � print_on% � *FX 21,3 !�2ș "Wimp_ReportError", error_blk%, 1, Printer$ !��endconfirm !� � stop% � !� � print_on% �stop_printing "2 � in_file% ș"XOS_Find",0,in_file%:in_file%=0 "D � out_file% �EscOn:ș"XOS_Find",0,out_file%:out_file%=0:�EscOff "� "$� ".: "8��zero_terminate(S%) "BS%?�$S% = 0 "L� "V: "`ݤlowercase(S$) "j� R$, C% "t R$="" "~ȕ �S$>0 "� C% = ��S$,1) "� S$ = �S$,�S$-1) "�2 � C%>=�"A" � C%<=�"Z" � C% = C% - �"A" + �"a" "� R$ += �C% "�� "�=R$ "�: "�� �stamp "�� load% "�� � "�� � � � "�'ș "OS_File",5,file_name% � ,,load% # S� (load%>>>8) <> &FFF000 + OutputType% � ș "OS_File",11,file_name%,OutputType% # � #: #� �EscOn #(*FX 229 #2� #<: #F � �EscOff #P *FX 229,1 #Z� �
00000000 0d 00 0a 1d f4 20 3e 21 52 75 6e 49 6d 61 67 65 |..... >!RunImage| 00000010 20 56 65 72 73 69 6f 6e 20 30 2e 38 32 0d 00 14 | Version 0.82...| 00000020 3e f4 20 50 75 72 70 6f 73 65 3a 20 70 72 69 6e |>. Purpose: prin| 00000030 74 65 72 20 69 6e 64 65 70 65 6e 64 65 6e 74 20 |ter independent | 00000040 70 61 72 74 20 6f 66 20 70 72 69 6e 74 65 72 20 |part of printer | 00000050 61 70 70 6c 69 63 61 74 69 6f 6e 0d 00 1e 27 f4 |application...'.| 00000060 20 41 75 74 68 6f 72 73 3a 20 44 54 65 65 2c 20 | Authors: DTee, | 00000070 41 54 68 6f 6d 70 73 6f 6e 2c 20 4e 52 65 65 76 |AThompson, NReev| 00000080 65 73 0d 00 28 1e c8 9b 20 22 3c 50 44 72 69 76 |es..(... "<PDriv| 00000090 65 72 24 64 69 72 3e 2e 4c 69 62 72 61 72 79 22 |er$dir>.Library"| 000000a0 0d 00 32 09 f2 69 6e 69 74 0d 00 3c 14 ee 20 85 |..2..init..<.. .| 000000b0 20 f2 65 72 72 6f 72 28 9f 2c f6 24 29 0d 00 46 | .error(.,.$)..F| 000000c0 05 f5 0d 00 50 2f 20 c8 99 20 22 57 69 6d 70 5f |....P/ .. "Wimp_| 000000d0 50 6f 6c 6c 22 2c 70 6f 6c 6c 5f 6d 61 73 6b 25 |Poll",poll_mask%| 000000e0 2c 65 76 65 6e 74 25 20 b8 20 61 63 74 69 6f 6e |,event% . action| 000000f0 25 0d 00 5a 13 20 f2 64 65 73 70 61 74 63 68 5f |%..Z. .despatch_| 00000100 70 6f 6c 6c 0d 00 64 07 fd 20 a3 0d 00 6e 05 e0 |poll..d.. ...n..| 00000110 0d 00 78 05 3a 0d 00 82 13 dd f2 64 65 73 70 61 |..x.:......despa| 00000120 74 63 68 5f 70 6f 6c 6c 0d 00 8c 32 20 e7 20 ac |tch_poll...2 . .| 00000130 20 a4 50 72 69 6e 74 65 72 5f 70 72 6f 63 65 73 | .Printer_proces| 00000140 73 5f 65 76 65 6e 74 28 61 63 74 69 6f 6e 25 2c |s_event(action%,| 00000150 20 65 76 65 6e 74 25 29 20 8c 0d 00 96 12 20 20 | event%) ..... | 00000160 c8 8e 20 61 63 74 69 6f 6e 25 20 ca 0d 00 a0 11 |.. action% .....| 00000170 20 20 20 c9 20 30 3a 20 f2 63 6f 70 79 0d 00 aa | . 0: .copy...| 00000180 1c 20 20 20 c9 20 31 3a 20 f2 72 65 64 72 61 77 |. . 1: .redraw| 00000190 28 21 65 76 65 6e 74 25 29 0d 00 b4 2f 20 20 20 |(!event%).../ | 000001a0 20 20 20 20 20 20 20 20 e7 20 21 65 76 65 6e 74 | . !event| 000001b0 25 3d 63 6f 6e 66 69 72 6d 25 20 8c 20 f2 65 6e |%=confirm% . .en| 000001c0 64 63 6f 6e 66 69 72 6d 0d 00 be 2d 20 20 20 c9 |dconfirm...- .| 000001d0 20 32 3a 20 e7 20 21 65 76 65 6e 74 25 3c 3e 63 | 2: . !event%<>c| 000001e0 6f 6e 66 69 72 6d 25 20 8c 20 f2 65 6e 64 63 6f |onfirm% . .endco| 000001f0 6e 66 69 72 6d 0d 00 c8 61 20 20 20 20 20 20 20 |nfirm...a | 00000200 20 20 20 20 f2 6f 70 65 6e 28 21 65 76 65 6e 74 | .open(!event| 00000210 25 2c 65 76 65 6e 74 25 21 34 2c 65 76 65 6e 74 |%,event%!4,event| 00000220 25 21 38 2c 65 76 65 6e 74 25 21 31 32 2c 65 76 |%!8,event%!12,ev| 00000230 65 6e 74 25 21 31 36 2c 65 76 65 6e 74 25 21 32 |ent%!16,event%!2| 00000240 30 2c 65 76 65 6e 74 25 21 32 34 2c 65 76 65 6e |0,event%!24,even| 00000250 74 25 21 32 38 29 0d 00 d2 17 20 20 20 c9 20 33 |t%!28).... . 3| 00000260 3a 20 f2 65 6e 64 63 6f 6e 66 69 72 6d 0d 00 dc |: .endconfirm...| 00000270 1e 20 20 20 20 20 20 20 20 20 20 20 f2 63 6c 6f |. .clo| 00000280 73 65 28 21 65 76 65 6e 74 25 29 0d 00 e6 4b 20 |se(!event%)...K | 00000290 20 20 c9 20 36 3a 20 f2 6d 6f 75 73 65 28 21 65 | . 6: .mouse(!e| 000002a0 76 65 6e 74 25 2c 65 76 65 6e 74 25 21 34 2c 65 |vent%,event%!4,e| 000002b0 76 65 6e 74 25 21 38 2c 65 76 65 6e 74 25 21 31 |vent%!8,event%!1| 000002c0 32 2c 65 76 65 6e 74 25 21 31 36 2c 65 76 65 6e |2,event%!16,even| 000002d0 74 25 21 32 30 29 0d 00 f0 1a 20 20 20 20 20 20 |t%!20).... | 000002e0 20 20 20 20 20 f2 65 6e 64 63 6f 6e 66 69 72 6d | .endconfirm| 000002f0 0d 00 fa 2c 20 20 20 c9 20 39 3a 20 f2 64 65 63 |..., . 9: .dec| 00000300 6f 64 65 6d 65 6e 75 28 6d 65 6e 75 68 61 6e 64 |odemenu(menuhand| 00000310 6c 65 25 2c 20 65 76 65 6e 74 25 29 0d 01 04 31 |le%, event%)...1| 00000320 20 20 20 20 20 20 20 20 20 20 20 f2 67 65 74 70 | .getp| 00000330 6f 69 6e 74 65 72 3a e7 20 62 75 74 74 6f 6e 73 |ointer:. buttons| 00000340 25 80 31 20 8c 20 f2 72 65 6d 65 6e 75 0d 01 0e |%.1 . .remenu...| 00000350 1f 20 20 20 c9 20 31 37 2c 31 38 3a f2 72 65 63 |. . 17,18:.rec| 00000360 65 69 76 65 28 65 76 65 6e 74 25 29 0d 01 18 1c |eive(event%)....| 00000370 20 20 20 c9 20 31 39 3a f2 62 6f 75 6e 63 65 64 | . 19:.bounced| 00000380 28 65 76 65 6e 74 25 29 0d 01 22 07 20 20 cb 0d |(event%)..". ..| 00000390 01 2c 06 20 cd 0d 01 36 05 e1 0d 01 40 05 3a 0d |.,. ...6....@.:.| 000003a0 01 4a 15 dd 20 a4 70 5f 66 69 65 6c 64 28 73 69 |.J.. .p_field(si| 000003b0 7a 65 25 29 0d 01 54 1c 20 70 72 69 6e 74 65 72 |ze%)..T. printer| 000003c0 5f 66 69 65 6c 64 25 20 2b 3d 20 73 69 7a 65 25 |_field% += size%| 000003d0 0d 01 5e 1d 20 3d 20 70 72 69 6e 74 65 72 5f 66 |..^. = printer_f| 000003e0 69 65 6c 64 25 20 2d 20 73 69 7a 65 25 0d 01 68 |ield% - size%..h| 000003f0 05 3a 0d 01 72 0b dd 20 f2 69 6e 69 74 0d 01 7c |.:..r.. .init..|| 00000400 07 ea 20 85 0d 01 86 0e 69 6e 5f 66 69 6c 65 25 |.. .....in_file%| 00000410 3d 30 0d 01 90 0f 6f 75 74 5f 66 69 6c 65 25 3d |=0....out_file%=| 00000420 30 0d 01 9a 42 f4 20 64 65 66 69 6e 65 20 70 72 |0...B. define pr| 00000430 69 6e 74 65 72 20 63 6c 61 73 73 20 69 6e 64 65 |inter class inde| 00000440 70 65 6e 64 65 6e 74 20 66 69 65 6c 64 73 20 69 |pendent fields i| 00000450 6e 20 70 72 69 6e 74 65 72 20 64 61 74 61 20 61 |n printer data a| 00000460 72 65 61 0d 01 a4 16 70 72 69 6e 74 65 72 5f 66 |rea....printer_f| 00000470 69 65 6c 64 25 20 3d 20 30 0d 01 ae 27 20 20 6c |ield% = 0...' l| 00000480 69 73 74 5f 70 6f 69 6e 74 65 72 5f 66 69 65 6c |ist_pointer_fiel| 00000490 64 25 20 3d 20 a4 70 5f 66 69 65 6c 64 28 34 29 |d% = .p_field(4)| 000004a0 0d 01 b8 27 20 20 20 20 20 20 20 20 20 70 78 72 |...' pxr| 000004b0 65 73 5f 66 69 65 6c 64 25 20 3d 20 a4 70 5f 66 |es_field% = .p_f| 000004c0 69 65 6c 64 28 34 29 0d 01 c2 27 20 20 20 20 20 |ield(4)...' | 000004d0 20 20 20 20 70 79 72 65 73 5f 66 69 65 6c 64 25 | pyres_field%| 000004e0 20 3d 20 a4 70 5f 66 69 65 6c 64 28 34 29 0d 01 | = .p_field(4)..| 000004f0 cc 27 20 20 20 20 20 20 66 65 61 74 75 72 65 73 |.' features| 00000500 5f 66 69 65 6c 64 25 20 3d 20 a4 70 5f 66 69 65 |_field% = .p_fie| 00000510 6c 64 28 34 29 0d 01 d6 27 20 20 20 64 65 73 63 |ld(4)...' desc| 00000520 72 69 70 74 69 6f 6e 5f 66 69 65 6c 64 25 20 3d |ription_field% =| 00000530 20 a4 70 5f 66 69 65 6c 64 28 34 29 0d 01 e0 27 | .p_field(4)...'| 00000540 70 78 72 65 73 5f 68 61 6c 66 74 6f 6e 65 5f 66 |pxres_halftone_f| 00000550 69 65 6c 64 25 20 3d 20 a4 70 5f 66 69 65 6c 64 |ield% = .p_field| 00000560 28 34 29 0d 01 ea 27 70 79 72 65 73 5f 68 61 6c |(4)...'pyres_hal| 00000570 66 74 6f 6e 65 5f 66 69 65 6c 64 25 20 3d 20 a4 |ftone_field% = .| 00000580 70 5f 66 69 65 6c 64 28 34 29 0d 01 f4 27 70 72 |p_field(4)...'pr| 00000590 69 6e 74 65 72 5f 6e 75 6d 62 65 72 5f 66 69 65 |inter_number_fie| 000005a0 6c 64 25 20 3d 20 a4 70 5f 66 69 65 6c 64 28 34 |ld% = .p_field(4| 000005b0 29 0d 01 fe 27 20 20 20 20 70 61 67 65 5f 77 69 |)...' page_wi| 000005c0 64 74 68 5f 66 69 65 6c 64 25 20 3d 20 a4 70 5f |dth_field% = .p_| 000005d0 66 69 65 6c 64 28 34 29 0d 02 08 27 20 20 20 70 |field(4)...' p| 000005e0 61 67 65 5f 68 65 69 67 68 74 5f 66 69 65 6c 64 |age_height_field| 000005f0 25 20 3d 20 a4 70 5f 66 69 65 6c 64 28 34 29 0d |% = .p_field(4).| 00000600 02 12 27 20 20 20 70 61 67 65 5f 62 6f 74 74 6f |..' page_botto| 00000610 6d 5f 66 69 65 6c 64 25 20 3d 20 a4 70 5f 66 69 |m_field% = .p_fi| 00000620 65 6c 64 28 34 29 0d 02 1c 27 20 20 20 20 20 20 |eld(4)...' | 00000630 70 61 67 65 5f 74 6f 70 5f 66 69 65 6c 64 25 20 |page_top_field% | 00000640 3d 20 a4 70 5f 66 69 65 6c 64 28 34 29 0d 02 26 |= .p_field(4)..&| 00000650 27 20 20 20 20 20 70 61 67 65 5f 6c 65 66 74 5f |' page_left_| 00000660 66 69 65 6c 64 25 20 3d 20 a4 70 5f 66 69 65 6c |field% = .p_fiel| 00000670 64 28 34 29 0d 02 30 27 20 20 20 20 70 61 67 65 |d(4)..0' page| 00000680 5f 72 69 67 68 74 5f 66 69 65 6c 64 25 20 3d 20 |_right_field% = | 00000690 a4 70 5f 66 69 65 6c 64 28 34 29 0d 02 3a 33 f4 |.p_field(4)..:3.| 000006a0 20 64 65 66 69 6e 65 20 63 6c 61 73 73 20 69 6e | define class in| 000006b0 64 65 70 65 6e 64 65 6e 74 20 69 63 6f 6e 73 20 |dependent icons | 000006c0 69 6e 20 6d 61 69 6e 20 77 69 6e 64 6f 77 0d 02 |in main window..| 000006d0 44 19 6d 61 69 6e 5f 64 65 73 63 72 69 70 74 69 |D.main_descripti| 000006e0 6f 6e 25 20 3d 20 31 0d 02 4e 2f f4 20 6d 61 72 |on% = 1..N/. mar| 000006f0 6b 20 63 6f 6e 66 69 67 75 72 65 20 6f 70 74 69 |k configure opti| 00000700 6f 6e 73 20 61 73 20 75 6e 73 65 74 20 69 6e 69 |ons as unset ini| 00000710 74 69 61 6c 6c 79 0d 02 58 18 20 20 20 70 72 69 |tially..X. pri| 00000720 6e 74 65 72 5f 70 74 72 25 20 3d 20 2d 31 0d 02 |nter_ptr% = -1..| 00000730 62 17 70 72 69 6e 74 65 72 5f 63 6f 6e 66 69 67 |b.printer_config| 00000740 25 20 3d 20 30 0d 02 6c 17 20 20 20 70 72 69 6e |% = 0..l. prin| 00000750 74 65 72 5f 6e 65 77 25 20 3d 20 30 0d 02 76 18 |ter_new% = 0..v.| 00000760 20 20 6c 6f 63 61 74 69 6f 6e 5f 70 74 72 25 20 | location_ptr% | 00000770 3d 20 2d 31 0d 02 80 18 20 20 20 20 20 20 62 61 |= -1.... ba| 00000780 75 64 5f 70 74 72 25 20 3d 20 2d 31 0d 02 8a 18 |ud_ptr% = -1....| 00000790 20 20 20 20 20 20 64 61 74 61 5f 70 74 72 25 20 | data_ptr% | 000007a0 3d 20 2d 31 0d 02 94 18 20 20 20 20 20 20 20 58 |= -1.... X| 000007b0 4f 4e 5f 70 74 72 25 20 3d 20 2d 31 0d 02 9e 18 |ON_ptr% = -1....| 000007c0 20 20 20 20 73 65 72 76 65 72 5f 70 74 72 25 20 | server_ptr% | 000007d0 3d 20 2d 31 0d 02 a8 18 20 20 20 20 20 20 66 65 |= -1.... fe| 000007e0 65 64 5f 70 74 72 25 20 3d 20 2d 31 0d 02 b2 14 |ed_ptr% = -1....| 000007f0 f4 20 6d 65 73 73 61 67 65 20 76 61 6c 75 65 73 |. message values| 00000800 0d 02 bc 22 4d 65 73 73 61 67 65 5f 50 72 69 6e |..."Message_Prin| 00000810 74 46 69 6c 65 25 20 20 20 20 20 3d 26 38 30 31 |tFile% =&801| 00000820 34 30 0d 02 c6 22 4d 65 73 73 61 67 65 5f 57 69 |40..."Message_Wi| 00000830 6c 6c 50 72 69 6e 74 25 20 20 20 20 20 3d 26 38 |llPrint% =&8| 00000840 30 31 34 31 0d 02 d0 22 4d 65 73 73 61 67 65 5f |0141..."Message_| 00000850 50 72 69 6e 74 53 61 76 65 25 20 20 20 20 20 3d |PrintSave% =| 00000860 26 38 30 31 34 32 0d 02 da 22 4d 65 73 73 61 67 |&80142..."Messag| 00000870 65 5f 50 72 69 6e 74 49 6e 69 74 25 20 20 20 20 |e_PrintInit% | 00000880 20 3d 26 38 30 31 34 33 0d 02 e4 22 4d 65 73 73 | =&80143..."Mess| 00000890 61 67 65 5f 50 72 69 6e 74 42 75 73 79 25 20 20 |age_PrintBusy% | 000008a0 20 20 20 3d 26 38 30 31 34 34 0d 02 ee 22 4d 65 | =&80144..."Me| 000008b0 73 73 61 67 65 5f 50 72 69 6e 74 54 79 70 65 4f |ssage_PrintTypeO| 000008c0 64 64 25 20 20 3d 26 38 30 31 34 35 0d 02 f8 22 |dd% =&80145..."| 000008d0 4d 65 73 73 61 67 65 5f 50 72 69 6e 74 54 79 70 |Message_PrintTyp| 000008e0 65 4b 6e 6f 77 6e 25 3d 26 38 30 31 34 36 0d 03 |eKnown%=&80146..| 000008f0 02 22 4d 65 73 73 61 67 65 5f 53 65 74 50 72 69 |."Message_SetPri| 00000900 6e 74 65 72 25 20 20 20 20 3d 26 38 30 31 34 37 |nter% =&80147| 00000910 0d 03 0c 1d f4 20 64 69 6d 65 6e 73 69 6f 6e 20 |..... dimension | 00000920 73 79 73 74 65 6d 20 61 72 72 61 79 73 0d 03 16 |system arrays...| 00000930 0d de 20 71 25 20 26 38 30 30 0d 03 20 11 de 20 |.. q% &800.. .. | 00000940 65 76 65 6e 74 25 20 26 38 30 30 0d 03 2a 10 6d |event% &800..*.m| 00000950 61 78 62 75 66 25 3d 26 38 30 30 0d 03 34 30 de |axbuf%=&800..40.| 00000960 20 63 75 72 62 75 66 25 20 6d 61 78 62 75 66 25 | curbuf% maxbuf%| 00000970 3a 20 65 6e 64 62 75 66 25 20 3d 20 63 75 72 62 |: endbuf% = curb| 00000980 75 66 25 2b 6d 61 78 62 75 66 25 0d 03 3e 2f de |uf%+maxbuf%..>/.| 00000990 20 6d 65 6e 75 66 72 65 65 25 20 26 38 30 30 3a | menufree% &800:| 000009a0 20 6d 65 6e 75 65 6e 64 25 20 3d 20 6d 65 6e 75 | menuend% = menu| 000009b0 66 72 65 65 25 2b 26 38 30 30 0d 03 48 12 de 20 |free%+&800..H.. | 000009c0 69 63 6f 6e 5f 62 75 66 25 20 34 30 0d 03 52 27 |icon_buf% 40..R'| 000009d0 de 20 74 65 78 74 5f 62 75 66 66 65 72 25 20 31 |. text_buffer% 1| 000009e0 32 2c 20 76 61 6c 69 64 5f 62 75 66 66 65 72 25 |2, valid_buffer%| 000009f0 20 31 32 0d 03 5c 0f de 20 62 6c 6f 63 6b 25 20 | 12..\.. block% | 00000a00 32 30 0d 03 66 14 de 20 65 72 72 6f 72 5f 62 6c |20..f.. error_bl| 00000a10 6b 25 20 32 35 36 0d 03 70 0e de 20 6d 73 67 25 |k% 256..p.. msg%| 00000a20 20 32 35 36 0d 03 7a 0e 62 75 66 73 7a 25 3d 32 | 256..z.bufsz%=2| 00000a30 35 36 0d 03 84 11 de 20 62 75 66 25 20 62 75 66 |56..... buf% buf| 00000a40 73 7a 25 0d 03 8e 14 f4 20 73 65 74 20 75 70 20 |sz%..... set up | 00000a50 63 6f 6c 6f 75 72 73 0d 03 98 21 60 77 62 63 6f |colours...!`wbco| 00000a60 6c 3d 26 30 3a 60 77 66 63 6f 6c 3d 26 37 3a 60 |l=&0:`wfcol=&7:`| 00000a70 74 66 63 6f 6c 3d 26 37 0d 03 a2 18 f4 20 69 6e |tfcol=&7..... in| 00000a80 69 74 69 61 6c 20 6d 61 73 6b 20 73 74 61 74 65 |itial mask state| 00000a90 0d 03 ac 2f 70 6f 6c 6c 5f 6d 61 73 6b 25 20 3d |.../poll_mask% =| 00000aa0 20 ac 28 25 31 31 31 20 3c 3c 20 31 37 29 3a 20 | .(%111 << 17): | 00000ab0 f4 20 6f 6e 6c 79 20 6d 65 73 73 61 67 65 73 0d |. only messages.| 00000ac0 03 b6 3a 63 6f 6e 66 69 72 6d 5f 61 6e 73 77 65 |..:confirm_answe| 00000ad0 72 25 20 3d 20 30 20 3a 20 f4 20 6e 6f 74 20 69 |r% = 0 : . not i| 00000ae0 6e 73 69 64 65 20 46 4e 63 6f 6e 66 69 72 6d 20 |nside FNconfirm | 00000af0 63 75 72 72 65 6e 74 6c 79 0d 03 c0 17 f2 50 72 |currently.....Pr| 00000b00 69 6e 74 65 72 5f 69 6e 69 74 69 61 6c 69 73 65 |inter_initialise| 00000b10 0d 03 ca 1a 50 72 69 6e 74 65 72 24 3d 50 72 69 |....Printer$=Pri| 00000b20 6e 74 65 72 43 6c 61 73 73 24 0d 03 d4 11 73 61 |nterClass$....sa| 00000b30 76 65 5f 6e 61 6d 65 24 3d 22 22 0d 03 de 10 70 |ve_name$=""....p| 00000b40 72 69 6e 74 5f 72 65 66 25 3d 30 0d 03 e8 16 f4 |rint_ref%=0.....| 00000b50 20 20 49 6e 69 74 69 61 6c 69 73 65 20 57 49 4d | Initialise WIM| 00000b60 50 0d 03 f2 20 de 20 74 61 73 6b 69 64 25 20 35 |P... . taskid% 5| 00000b70 3a 20 24 74 61 73 6b 69 64 25 3d 22 54 41 53 4b |: $taskid%="TASK| 00000b80 22 0d 03 fc 3e c8 99 20 22 57 69 6d 70 5f 49 6e |"...>.. "Wimp_In| 00000b90 69 74 69 61 6c 69 73 65 22 2c 32 30 30 2c 21 74 |itialise",200,!t| 00000ba0 61 73 6b 69 64 25 2c 50 72 69 6e 74 65 72 24 20 |askid%,Printer$ | 00000bb0 b8 20 2c 74 61 73 6b 5f 68 61 6e 64 6c 65 25 0d |. ,task_handle%.| 00000bc0 04 06 22 ee 20 85 20 ea 20 f2 65 72 72 6f 72 28 |..". . . .error(| 00000bd0 9f 2c 20 f6 24 29 3a f2 74 65 72 6d 69 6e 61 74 |., .$):.terminat| 00000be0 65 0d 04 10 0d 6d 73 67 25 21 30 3d 32 30 0d 04 |e....msg%!0=20..| 00000bf0 1a 0d 6d 73 67 25 21 31 32 3d 30 0d 04 24 1e 6d |..msg%!12=0..$.m| 00000c00 73 67 25 21 31 36 3d 4d 65 73 73 61 67 65 5f 50 |sg%!16=Message_P| 00000c10 72 69 6e 74 49 6e 69 74 25 0d 04 2e 26 c8 99 20 |rintInit%...&.. | 00000c20 22 57 69 6d 70 5f 53 65 6e 64 4d 65 73 73 61 67 |"Wimp_SendMessag| 00000c30 65 22 2c 20 31 38 2c 20 6d 73 67 25 2c 20 30 0d |e", 18, msg%, 0.| 00000c40 04 38 05 e1 0d 04 42 05 3a 0d 04 4c 0c dd 20 f2 |.8....B.:..L.. .| 00000c50 69 6e 69 74 32 0d 04 56 08 ea 20 53 24 0d 04 60 |init2..V.. S$..`| 00000c60 07 ea 20 85 0d 04 6a 1c f4 20 6c 6f 61 64 20 74 |.. ...j.. load t| 00000c70 68 65 20 74 65 6d 70 6c 61 74 65 20 66 69 6c 65 |he template file| 00000c80 0d 04 74 35 c8 99 20 22 57 69 6d 70 5f 4f 70 65 |..t5.. "Wimp_Ope| 00000c90 6e 54 65 6d 70 6c 61 74 65 22 2c 2c 22 3c 50 44 |nTemplate",,"<PD| 00000ca0 72 69 76 65 72 24 64 69 72 3e 2e 54 65 6d 70 6c |river$dir>.Templ| 00000cb0 61 74 65 73 22 0d 04 7e 1b 6d 61 69 6e 25 20 3d |ates"..~.main% =| 00000cc0 20 a4 77 69 6e 64 6f 77 28 22 6d 61 69 6e 22 29 | .window("main")| 00000cd0 0d 04 88 21 63 6f 6e 66 69 72 6d 25 20 3d 20 a4 |...!confirm% = .| 00000ce0 77 69 6e 64 6f 77 28 22 63 6f 6e 66 69 72 6d 22 |window("confirm"| 00000cf0 29 0d 04 92 1b 69 6e 66 6f 25 20 3d 20 a4 77 69 |)....info% = .wi| 00000d00 6e 64 6f 77 28 22 69 6e 66 6f 22 29 0d 04 9c 1b |ndow("info")....| 00000d10 f2 50 72 69 6e 74 65 72 5f 6c 6f 61 64 5f 74 65 |.Printer_load_te| 00000d20 6d 70 6c 61 74 65 73 0d 04 a6 1b c8 99 20 22 57 |mplates...... "W| 00000d30 69 6d 70 5f 43 6c 6f 73 65 54 65 6d 70 6c 61 74 |imp_CloseTemplat| 00000d40 65 22 0d 04 b0 16 70 72 69 6e 74 65 72 5f 74 79 |e"....printer_ty| 00000d50 70 65 24 20 3d 20 22 22 0d 04 ba 15 69 63 70 72 |pe$ = ""....icpr| 00000d60 69 6e 74 25 3d a4 69 63 6f 6e 62 61 72 0d 04 c4 |int%=.iconbar...| 00000d70 1a f4 20 63 72 65 61 74 65 20 74 68 65 20 6d 65 |.. create the me| 00000d80 6e 75 20 74 72 65 65 0d 04 ce 13 de 20 73 65 72 |nu tree..... ser| 00000d90 76 65 72 5f 6e 65 77 25 20 38 0d 04 d8 15 24 73 |ver_new% 8....$s| 00000da0 65 72 76 65 72 5f 6e 65 77 25 20 3d 20 22 22 0d |erver_new% = "".| 00000db0 04 e2 14 de 20 66 69 6c 65 5f 6e 61 6d 65 25 20 |.... file_name% | 00000dc0 32 30 31 0d 04 ec 3d c8 99 20 22 58 4f 53 5f 52 |201...=.. "XOS_R| 00000dd0 65 61 64 56 61 72 56 61 6c 22 2c 22 50 72 69 6e |eadVarVal","Prin| 00000de0 74 65 72 54 79 70 65 24 35 22 2c 66 69 6c 65 5f |terType$5",file_| 00000df0 6e 61 6d 65 25 2c 32 30 30 20 b8 20 2c 2c 4c 25 |name%,200 . ,,L%| 00000e00 0d 04 f6 0a e7 20 4c 25 20 8c 0d 05 00 17 20 66 |..... L% ..... f| 00000e10 69 6c 65 5f 6e 61 6d 65 25 3f 4c 25 20 3d 20 31 |ile_name%?L% = 1| 00000e20 33 0d 05 0a 05 cc 0d 05 14 2c 20 24 66 69 6c 65 |3........, $file| 00000e30 5f 6e 61 6d 65 25 3d 22 3c 50 44 72 69 76 65 72 |_name%="<PDriver| 00000e40 24 44 69 72 3e 2e 5e 2e 50 72 69 6e 74 44 61 74 |$Dir>.^.PrintDat| 00000e50 61 22 0d 05 1e 05 cd 0d 05 28 62 62 61 75 64 6d |a".......(bbaudm| 00000e60 25 20 3d 20 a4 63 72 6d 65 6e 75 28 22 23 42 61 |% = .crmenu("#Ba| 00000e70 75 64 3b 37 35 3b 31 35 30 3b 33 30 30 3b 31 32 |ud;75;150;300;12| 00000e80 30 30 3b 32 34 30 30 3b 34 38 30 30 3b 39 36 30 |00;2400;4800;960| 00000e90 30 3b 31 39 32 30 30 3b 35 30 3b 31 31 30 3b 31 |0;19200;50;110;1| 00000ea0 33 34 2e 35 3b 36 30 30 3b 31 38 30 30 3b 33 36 |34.5;600;1800;36| 00000eb0 30 30 3b 37 32 30 30 22 29 0d 05 32 25 62 69 74 |00;7200")..2%bit| 00000ec0 73 6d 25 20 3d 20 a4 63 72 6d 65 6e 75 28 22 23 |sm% = .crmenu("#| 00000ed0 42 69 74 73 3b 35 3b 36 3b 37 3b 38 22 29 0d 05 |Bits;5;6;7;8")..| 00000ee0 3c 3e 70 61 72 69 74 79 6d 25 20 3d 20 a4 63 72 |<>paritym% = .cr| 00000ef0 6d 65 6e 75 28 22 23 50 61 72 69 74 79 3b 6f 66 |menu("#Parity;of| 00000f00 66 3b 6f 64 64 3b 65 76 65 6e 3b 31 20 6f 6e 20 |f;odd;even;1 on | 00000f10 54 58 3b 30 20 6f 6e 20 54 58 22 29 0d 05 46 53 |TX;0 on TX")..FS| 00000f20 73 74 6f 70 6d 25 20 3d 20 a4 63 72 6d 65 6e 75 |stopm% = .crmenu| 00000f30 28 22 23 53 74 6f 70 20 62 69 74 73 3b 31 3b 32 |("#Stop bits;1;2| 00000f40 20 28 31 2e 35 20 69 66 20 35 20 62 69 74 73 20 | (1.5 if 5 bits | 00000f50 70 61 72 69 74 79 2c 31 20 69 66 20 38 20 62 69 |parity,1 if 8 bi| 00000f60 74 73 20 6e 6f 20 70 61 72 69 74 79 29 22 29 0d |ts no parity)").| 00000f70 05 50 51 64 61 74 61 6d 25 20 3d 20 a4 63 72 6d |.PQdatam% = .crm| 00000f80 65 6e 75 28 22 23 44 61 74 61 20 66 6f 72 6d 61 |enu("#Data forma| 00000f90 74 3b 42 69 74 73 3e 62 69 74 73 6d 25 3b 50 61 |t;Bits>bitsm%;Pa| 00000fa0 72 69 74 79 3e 70 61 72 69 74 79 6d 25 3b 53 74 |rity>paritym%;St| 00000fb0 6f 70 20 62 69 74 73 3e 73 74 6f 70 6d 25 22 29 |op bits>stopm%")| 00000fc0 0d 05 5a 50 73 65 72 69 61 6c 6d 25 20 3d 20 a4 |..ZPserialm% = .| 00000fd0 63 72 6d 65 6e 75 28 22 23 53 65 72 69 61 6c 3b |crmenu("#Serial;| 00000fe0 42 61 75 64 20 72 61 74 65 3e 62 61 75 64 6d 25 |Baud rate>baudm%| 00000ff0 3b 44 61 74 61 20 66 6f 72 6d 61 74 3e 64 61 74 |;Data format>dat| 00001000 61 6d 25 3b 58 4f 4e 20 2f 20 58 4f 46 46 22 29 |am%;XON / XOFF")| 00001010 0d 05 64 36 6e 65 74 70 72 69 6e 74 6d 25 20 3d |..d6netprintm% =| 00001020 20 a4 63 72 6d 65 6e 75 28 22 23 4e 65 74 20 70 | .crmenu("#Net p| 00001030 72 69 6e 74 3b 24 73 65 72 76 65 72 5f 6e 65 77 |rint;$server_new| 00001040 25 28 38 29 22 29 0d 05 6e 36 66 69 6c 65 6d 65 |%(8)")..n6fileme| 00001050 6e 75 25 20 3d 20 a4 63 72 6d 65 6e 75 28 22 23 |nu% = .crmenu("#| 00001060 46 69 6c 65 20 6e 61 6d 65 3b 24 66 69 6c 65 5f |File name;$file_| 00001070 6e 61 6d 65 25 28 32 30 30 29 22 29 0d 05 78 91 |name%(200)")..x.| 00001080 70 72 69 6e 74 6d 65 6e 75 25 20 3d 20 a4 63 72 |printmenu% = .cr| 00001090 6d 65 6e 75 28 22 23 22 2b 50 72 69 6e 74 65 72 |menu("#"+Printer| 000010a0 24 2b 22 3b 49 6e 66 6f 3e 69 6e 66 6f 25 23 3b |$+";Info>info%#;| 000010b0 50 61 72 61 6c 6c 65 6c 3b 53 65 72 69 61 6c 3e |Parallel;Serial>| 000010c0 73 65 72 69 61 6c 6d 25 3b 4e 65 74 77 6f 72 6b |serialm%;Network| 000010d0 3e 6e 65 74 70 72 69 6e 74 6d 25 3b 46 69 6c 65 |>netprintm%;File| 000010e0 3e 66 69 6c 65 6d 65 6e 75 25 23 3b 53 61 76 65 |>filemenu%#;Save| 000010f0 20 63 68 6f 69 63 65 73 3b 53 74 6f 70 20 70 72 | choices;Stop pr| 00001100 69 6e 74 69 6e 67 3b 51 75 69 74 22 29 0d 05 82 |inting;Quit")...| 00001110 17 f2 73 65 74 5f 70 72 69 6e 74 5f 73 74 61 74 |..set_print_stat| 00001120 65 28 a3 29 0d 05 8c 0d f2 64 65 66 61 75 6c 74 |e(.).....default| 00001130 73 0d 05 96 1e f2 50 72 69 6e 74 65 72 5f 73 65 |s.....Printer_se| 00001140 74 5f 69 6e 69 74 69 61 6c 5f 73 74 61 74 65 0d |t_initial_state.| 00001150 05 a0 19 ee 20 85 20 ea 20 f2 65 72 72 6f 72 28 |.... . . .error(| 00001160 9f 2c 20 f6 24 29 3a e1 0d 05 aa 10 f2 63 68 61 |., .$):......cha| 00001170 6e 67 65 5f 69 63 6f 6e 0d 05 b4 05 e1 0d 05 be |nge_icon........| 00001180 05 3a 0d 05 c8 11 dd 20 f2 53 61 76 65 43 6f 6e |.:..... .SaveCon| 00001190 66 69 67 0d 05 d2 25 6f 75 74 5f 66 69 6c 65 25 |fig...%out_file%| 000011a0 3d ad 22 3c 50 44 72 69 76 65 72 24 64 69 72 3e |=."<PDriver$dir>| 000011b0 2e 50 72 44 61 74 61 22 0d 05 dc 1a e7 20 70 72 |.PrData"..... pr| 000011c0 69 6e 74 65 72 5f 70 74 72 25 20 3c 3e 20 2d 31 |inter_ptr% <> -1| 000011d0 20 8c 0d 05 e6 28 20 e7 20 70 72 69 6e 74 65 72 | ....( . printer| 000011e0 5f 63 6f 6e 66 69 67 25 20 3c 3e 20 70 72 69 6e |_config% <> prin| 000011f0 74 65 72 5f 6e 65 77 25 20 8c 0d 05 f0 20 20 20 |ter_new% .... | 00001200 cf 23 6f 75 74 5f 66 69 6c 65 25 20 3d 20 70 72 |.#out_file% = pr| 00001210 69 6e 74 65 72 5f 70 74 72 25 0d 05 fa 28 20 20 |inter_ptr%...( | 00001220 d5 23 6f 75 74 5f 66 69 6c 65 25 2c c2 22 30 22 |.#out_file%,."0"| 00001230 2b c3 70 72 69 6e 74 65 72 5f 6e 65 77 25 2c 32 |+.printer_new%,2| 00001240 29 3b 0d 06 04 24 20 20 70 72 69 6e 74 65 72 5f |);...$ printer_| 00001250 63 6f 6e 66 69 67 25 20 3d 20 70 72 69 6e 74 65 |config% = printe| 00001260 72 5f 6e 65 77 25 0d 06 0e 06 20 cd 0d 06 18 05 |r_new%.... .....| 00001270 cd 0d 06 22 3d e7 20 6c 6f 63 61 74 69 6f 6e 5f |..."=. location_| 00001280 6e 65 77 25 3d 35 20 80 20 a4 6c 6f 77 65 72 63 |new%=5 . .lowerc| 00001290 61 73 65 28 c0 24 66 69 6c 65 5f 6e 61 6d 65 25 |ase(.$file_name%| 000012a0 2c 35 29 29 3d 22 6e 75 6c 6c 3a 22 20 8c 0d 06 |,5))="null:" ...| 000012b0 2c 2a 20 e7 20 6c 6f 63 61 74 69 6f 6e 5f 63 6f |,* . location_co| 000012c0 6e 66 69 67 25 20 3c 3e 20 6c 6f 63 61 74 69 6f |nfig% <> locatio| 000012d0 6e 5f 6e 65 77 25 20 8c 0d 06 36 1d 20 20 e7 20 |n_new% ...6. . | 000012e0 6c 6f 63 61 74 69 6f 6e 5f 70 74 72 25 20 3c 3e |location_ptr% <>| 000012f0 20 2d 31 20 8c 0d 06 40 22 20 20 20 cf 23 6f 75 | -1 ...@" .#ou| 00001300 74 5f 66 69 6c 65 25 20 3d 20 6c 6f 63 61 74 69 |t_file% = locati| 00001310 6f 6e 5f 70 74 72 25 0d 06 4a 17 20 20 20 d5 23 |on_ptr%..J. .#| 00001320 6f 75 74 5f 66 69 6c 65 25 2c 22 30 22 3b 0d 06 |out_file%,"0";..| 00001330 54 07 20 20 cd 0d 06 5e 24 20 20 6c 6f 63 61 74 |T. ...^$ locat| 00001340 69 6f 6e 5f 63 6f 6e 66 69 67 25 3d 6c 6f 63 61 |ion_config%=loca| 00001350 74 69 6f 6e 5f 6e 65 77 25 0d 06 68 06 20 cd 0d |tion_new%..h. ..| 00001360 06 72 23 20 c8 99 22 4f 53 5f 43 4c 49 22 2c 22 |.r# .."OS_CLI","| 00001370 43 6f 6e 66 69 67 75 72 65 20 50 72 69 6e 74 20 |Configure Print | 00001380 30 22 0d 06 7c 05 cc 0d 06 86 2a 20 e7 20 6c 6f |0"..|.....* . lo| 00001390 63 61 74 69 6f 6e 5f 63 6f 6e 66 69 67 25 20 3c |cation_config% <| 000013a0 3e 20 6c 6f 63 61 74 69 6f 6e 5f 6e 65 77 25 20 |> location_new% | 000013b0 8c 0d 06 90 1d 20 20 e7 20 6c 6f 63 61 74 69 6f |..... . locatio| 000013c0 6e 5f 70 74 72 25 20 3c 3e 20 2d 31 20 8c 0d 06 |n_ptr% <> -1 ...| 000013d0 9a 22 20 20 20 cf 23 6f 75 74 5f 66 69 6c 65 25 |." .#out_file%| 000013e0 20 3d 20 6c 6f 63 61 74 69 6f 6e 5f 70 74 72 25 | = location_ptr%| 000013f0 0d 06 a4 22 20 20 20 d5 23 6f 75 74 5f 66 69 6c |..." .#out_fil| 00001400 65 25 2c c3 6c 6f 63 61 74 69 6f 6e 5f 6e 65 77 |e%,.location_new| 00001410 25 3b 0d 06 ae 07 20 20 cd 0d 06 b8 24 20 20 6c |%;.... ....$ l| 00001420 6f 63 61 74 69 6f 6e 5f 63 6f 6e 66 69 67 25 3d |ocation_config%=| 00001430 6c 6f 63 61 74 69 6f 6e 5f 6e 65 77 25 0d 06 c2 |location_new%...| 00001440 06 20 cd 0d 06 cc 32 20 c8 99 22 58 4f 53 5f 43 |. ....2 .."XOS_C| 00001450 4c 49 22 2c 22 43 6f 6e 66 69 67 75 72 65 20 50 |LI","Configure P| 00001460 72 69 6e 74 20 22 2b c3 6c 6f 63 61 74 69 6f 6e |rint "+.location| 00001470 5f 6e 65 77 25 0d 06 d6 05 cd 0d 06 e0 21 e7 20 |_new%........!. | 00001480 62 61 75 64 5f 63 6f 6e 66 69 67 25 20 3c 3e 20 |baud_config% <> | 00001490 62 61 75 64 5f 6e 65 77 25 20 8c 0d 06 ea 18 20 |baud_new% ..... | 000014a0 e7 20 62 61 75 64 5f 70 74 72 25 20 3c 3e 20 2d |. baud_ptr% <> -| 000014b0 31 20 8c 0d 06 f4 1b 20 20 cf 23 6f 75 74 5f 66 |1 ..... .#out_f| 000014c0 69 6c 65 25 3d 62 61 75 64 5f 70 74 72 25 0d 06 |ile%=baud_ptr%..| 000014d0 fe 1d 20 20 d5 23 6f 75 74 5f 66 69 6c 65 25 2c |.. .#out_file%,| 000014e0 c3 62 61 75 64 5f 6e 65 77 25 3b 0d 07 08 06 20 |.baud_new%;.... | 000014f0 cd 0d 07 12 1d 20 62 61 75 64 5f 63 6f 6e 66 69 |..... baud_confi| 00001500 67 25 20 3d 20 62 61 75 64 5f 6e 65 77 25 0d 07 |g% = baud_new%..| 00001510 1c 05 cd 0d 07 26 52 e7 20 6c 6f 63 61 74 69 6f |.....&R. locatio| 00001520 6e 5f 6e 65 77 25 3d 32 20 80 20 62 61 75 64 5f |n_new%=2 . baud_| 00001530 6e 65 77 25 3c 3d 37 20 8c 20 c8 99 22 4f 53 5f |new%<=7 . .."OS_| 00001540 43 4c 49 22 2c 22 43 6f 6e 66 69 67 75 72 65 20 |CLI","Configure | 00001550 42 61 75 64 20 22 2b c3 28 62 61 75 64 5f 6e 65 |Baud "+.(baud_ne| 00001560 77 25 2b 31 29 0d 07 30 21 e7 20 64 61 74 61 5f |w%+1)..0!. data_| 00001570 63 6f 6e 66 69 67 25 20 3c 3e 20 64 61 74 61 5f |config% <> data_| 00001580 6e 65 77 25 20 8c 0d 07 3a 18 20 e7 20 64 61 74 |new% ...:. . dat| 00001590 61 5f 70 74 72 25 20 3c 3e 20 2d 31 20 8c 0d 07 |a_ptr% <> -1 ...| 000015a0 44 1b 20 20 cf 23 6f 75 74 5f 66 69 6c 65 25 3d |D. .#out_file%=| 000015b0 64 61 74 61 5f 70 74 72 25 0d 07 4e 28 20 20 41 |data_ptr%..N( A| 000015c0 24 3d c3 7e 28 64 61 74 61 5f 6e 65 77 25 29 3a |$=.~(data_new%):| 000015d0 e7 20 a9 41 24 3d 31 20 41 24 3d 22 30 22 2b 41 |. .A$=1 A$="0"+A| 000015e0 24 0d 07 58 19 20 20 d5 23 6f 75 74 5f 66 69 6c |$..X. .#out_fil| 000015f0 65 25 2c 22 26 22 2b 41 24 3b 0d 07 62 06 20 cd |e%,"&"+A$;..b. .| 00001600 0d 07 6c 1d 20 64 61 74 61 5f 63 6f 6e 66 69 67 |..l. data_config| 00001610 25 20 3d 20 64 61 74 61 5f 6e 65 77 25 0d 07 76 |% = data_new%..v| 00001620 05 cd 0d 07 80 1f e7 20 58 4f 4e 5f 63 6f 6e 66 |....... XON_conf| 00001630 69 67 25 20 3c 3e 20 58 4f 4e 5f 6e 65 77 25 20 |ig% <> XON_new% | 00001640 8c 0d 07 8a 17 20 e7 20 58 4f 4e 5f 70 74 72 25 |..... . XON_ptr%| 00001650 20 3c 3e 20 2d 31 20 8c 0d 07 94 1a 20 20 cf 23 | <> -1 ..... .#| 00001660 6f 75 74 5f 66 69 6c 65 25 3d 58 4f 4e 5f 70 74 |out_file%=XON_pt| 00001670 72 25 0d 07 9e 1c 20 20 d5 23 6f 75 74 5f 66 69 |r%.... .#out_fi| 00001680 6c 65 25 2c c3 58 4f 4e 5f 6e 65 77 25 3b 0d 07 |le%,.XON_new%;..| 00001690 a8 06 20 cd 0d 07 b2 1b 20 58 4f 4e 5f 63 6f 6e |.. ..... XON_con| 000016a0 66 69 67 25 20 3d 20 58 4f 4e 5f 6e 65 77 25 0d |fig% = XON_new%.| 000016b0 07 bc 05 cd 0d 07 c6 26 e7 20 73 65 72 76 65 72 |.......&. server| 000016c0 5f 63 6f 6e 66 69 67 24 20 3c 3e 20 24 73 65 72 |_config$ <> $ser| 000016d0 76 65 72 5f 6e 65 77 25 20 8c 0d 07 d0 1a 20 e7 |ver_new% ..... .| 000016e0 20 73 65 72 76 65 72 5f 70 74 72 25 20 3c 3e 20 | server_ptr% <> | 000016f0 2d 31 20 8c 0d 07 da 1d 20 20 cf 23 6f 75 74 5f |-1 ..... .#out_| 00001700 66 69 6c 65 25 3d 73 65 72 76 65 72 5f 70 74 72 |file%=server_ptr| 00001710 25 0d 07 e4 35 20 20 d5 23 6f 75 74 5f 66 69 6c |%...5 .#out_fil| 00001720 65 25 2c 24 73 65 72 76 65 72 5f 6e 65 77 25 2b |e%,$server_new%+| 00001730 c4 38 2d a9 24 73 65 72 76 65 72 5f 6e 65 77 25 |.8-.$server_new%| 00001740 2c 22 3b 22 29 3b 0d 07 ee 06 20 cd 0d 07 f8 22 |,";");.... ...."| 00001750 20 73 65 72 76 65 72 5f 63 6f 6e 66 69 67 24 20 | server_config$ | 00001760 3d 20 24 73 65 72 76 65 72 5f 6e 65 77 25 0d 08 |= $server_new%..| 00001770 02 05 cd 0d 08 0c 17 e7 20 6c 6f 63 61 74 69 6f |........ locatio| 00001780 6e 5f 6e 65 77 25 3d 34 20 8c 0d 08 16 2d 20 c8 |n_new%=4 ....- .| 00001790 99 22 58 4f 53 5f 43 4c 49 22 2c 22 43 6f 6e 66 |."XOS_CLI","Conf| 000017a0 69 67 75 72 65 20 50 53 20 22 2b 24 73 65 72 76 |igure PS "+$serv| 000017b0 65 72 5f 6e 65 77 25 0d 08 20 23 20 c8 99 22 58 |er_new%.. # .."X| 000017c0 4f 53 5f 43 4c 49 22 2c 22 50 53 20 22 2b 24 73 |OS_CLI","PS "+$s| 000017d0 65 72 76 65 72 5f 6e 65 77 25 0d 08 2a 05 cd 0d |erver_new%..*...| 000017e0 08 34 18 f2 50 72 69 6e 74 65 72 5f 41 6d 65 6e |.4..Printer_Amen| 000017f0 64 43 6f 6e 66 69 67 0d 08 3e 1b d9 23 6f 75 74 |dConfig..>..#out| 00001800 5f 66 69 6c 65 25 3a 6f 75 74 5f 66 69 6c 65 25 |_file%:out_file%| 00001810 3d 30 0d 08 48 05 e1 0d 08 52 05 3a 0d 08 5c 0f |=0..H....R.:..\.| 00001820 dd f2 74 65 72 6d 69 6e 61 74 65 0d 08 66 14 2a |..terminate..f.*| 00001830 75 6e 73 65 74 20 24 50 72 69 6e 74 69 6e 67 0d |unset $Printing.| 00001840 08 70 1c ee 20 85 20 c8 99 22 57 69 6d 70 5f 43 |.p.. . .."Wimp_C| 00001850 6c 6f 73 65 44 6f 77 6e 22 3a e0 0d 08 7a 16 f2 |loseDown":...z..| 00001860 50 72 69 6e 74 65 72 5f 74 65 72 6d 69 6e 61 74 |Printer_terminat| 00001870 65 0d 08 84 34 e7 20 69 6e 5f 66 69 6c 65 25 3c |e...4. in_file%<| 00001880 3e 30 20 c8 99 22 58 4f 53 5f 46 69 6e 64 22 2c |>0 .."XOS_Find",| 00001890 30 2c 69 6e 5f 66 69 6c 65 25 3a 69 6e 5f 66 69 |0,in_file%:in_fi| 000018a0 6c 65 25 3d 30 0d 08 8e 46 e7 20 6f 75 74 5f 66 |le%=0...F. out_f| 000018b0 69 6c 65 25 3c 3e 30 20 f2 45 73 63 4f 6e 3a c8 |ile%<>0 .EscOn:.| 000018c0 99 22 58 4f 53 5f 46 69 6e 64 22 2c 30 2c 6f 75 |."XOS_Find",0,ou| 000018d0 74 5f 66 69 6c 65 25 3a 6f 75 74 5f 66 69 6c 65 |t_file%:out_file| 000018e0 25 3d 30 3a f2 45 73 63 4f 66 66 0d 08 98 16 c8 |%=0:.EscOff.....| 000018f0 99 22 57 69 6d 70 5f 43 6c 6f 73 65 44 6f 77 6e |."Wimp_CloseDown| 00001900 22 0d 08 a2 05 e0 0d 08 ac 05 3a 0d 08 b6 0f dd |".........:.....| 00001910 20 f2 64 65 66 61 75 6c 74 73 0d 08 c0 14 ea 20 | .defaults..... | 00001920 72 61 6d 76 61 6c 25 2c 20 74 65 6d 70 25 0d 08 |ramval%, temp%..| 00001930 ca 1a 64 61 74 61 5f 6e 65 77 25 3d 64 61 74 61 |..data_new%=data| 00001940 5f 63 6f 6e 66 69 67 25 0d 08 d4 29 f2 73 65 74 |_config%...).set| 00001950 5f 74 69 63 6b 28 62 69 74 73 6d 25 2c 33 2d 28 |_tick(bitsm%,3-(| 00001960 64 61 74 61 5f 6e 65 77 25 20 80 20 33 29 2c 31 |data_new% . 3),1| 00001970 29 0d 08 de 1a e7 20 64 61 74 61 5f 6e 65 77 25 |)..... data_new%| 00001980 20 80 20 28 31 3c 3c 33 29 20 8c 0d 08 e8 33 20 | . (1<<3) ....3 | 00001990 f2 73 65 74 5f 74 69 63 6b 28 70 61 72 69 74 79 |.set_tick(parity| 000019a0 6d 25 2c 28 28 64 61 74 61 5f 6e 65 77 25 20 3e |m%,((data_new% >| 000019b0 3e 20 34 29 20 80 20 33 29 2b 31 2c 31 29 0d 08 |> 4) . 3)+1,1)..| 000019c0 f2 05 cc 0d 08 fc 1c 20 f2 73 65 74 5f 74 69 63 |....... .set_tic| 000019d0 6b 28 70 61 72 69 74 79 6d 25 2c 30 2c 31 29 0d |k(paritym%,0,1).| 000019e0 09 06 05 cd 0d 09 10 2a f2 73 65 74 5f 74 69 63 |.......*.set_tic| 000019f0 6b 28 73 74 6f 70 6d 25 2c 28 64 61 74 61 5f 6e |k(stopm%,(data_n| 00001a00 65 77 25 3e 3e 32 29 20 80 20 31 2c 31 29 0d 09 |ew%>>2) . 1,1)..| 00001a10 1a 24 f2 73 65 74 5f 74 69 63 6b 28 73 65 72 69 |.$.set_tick(seri| 00001a20 61 6c 6d 25 2c 20 32 2c 20 58 4f 4e 5f 6e 65 77 |alm%, 2, XON_new| 00001a30 25 29 0d 09 24 23 c8 99 20 22 4f 53 5f 42 79 74 |%)..$#.. "OS_Byt| 00001a40 65 22 2c 20 31 36 31 2c 20 31 35 20 b8 20 2c 2c |e", 161, 15 . ,,| 00001a50 74 65 6d 70 25 0d 09 2e 3e e7 20 62 61 75 64 5f |temp%...>. baud_| 00001a60 70 74 72 25 20 3d 20 2d 31 20 8c 20 62 61 75 64 |ptr% = -1 . baud| 00001a70 5f 63 6f 6e 66 69 67 25 20 3d 20 28 74 65 6d 70 |_config% = (temp| 00001a80 25 20 80 20 25 30 30 30 31 31 31 30 30 29 20 3e |% . %00011100) >| 00001a90 3e 20 32 0d 09 38 1c 62 61 75 64 5f 6e 65 77 25 |> 2..8.baud_new%| 00001aa0 20 3d 20 62 61 75 64 5f 63 6f 6e 66 69 67 25 0d | = baud_config%.| 00001ab0 09 42 44 e7 20 6c 6f 63 61 74 69 6f 6e 5f 70 74 |.BD. location_pt| 00001ac0 72 25 3d 2d 31 20 8c 20 6c 6f 63 61 74 69 6f 6e |r%=-1 . location| 00001ad0 5f 63 6f 6e 66 69 67 25 20 3d 20 28 74 65 6d 70 |_config% = (temp| 00001ae0 25 20 80 20 25 31 31 31 30 30 30 30 30 29 20 3e |% . %11100000) >| 00001af0 3e 20 35 0d 09 4c 1c e7 20 6c 6f 63 61 74 69 6f |> 5..L.. locatio| 00001b00 6e 5f 63 6f 6e 66 69 67 25 20 3d 20 32 20 8c 0d |n_config% = 2 ..| 00001b10 09 56 1e 20 c8 99 22 4f 53 5f 42 79 74 65 22 2c |.V. .."OS_Byte",| 00001b20 38 2c 62 61 75 64 5f 6e 65 77 25 2b 31 0d 09 60 |8,baud_new%+1..`| 00001b30 1e 20 c8 99 22 4f 53 5f 42 79 74 65 22 2c 37 2c |. .."OS_Byte",7,| 00001b40 62 61 75 64 5f 6e 65 77 25 2b 31 0d 09 6a 20 20 |baud_new%+1..j | 00001b50 c8 99 22 4f 53 5f 53 65 72 69 61 6c 4f 70 22 2c |.."OS_SerialOp",| 00001b60 31 2c 64 61 74 61 5f 6e 65 77 25 0d 09 74 22 20 |1,data_new%..t" | 00001b70 c8 99 22 4f 53 5f 53 65 72 69 61 6c 4f 70 22 2c |.."OS_SerialOp",| 00001b80 30 2c 58 4f 4e 5f 6e 65 77 25 2c ac 31 0d 09 7e |0,XON_new%,.1..~| 00001b90 14 20 f2 50 72 69 6e 74 65 72 5f 49 67 6e 6f 72 |. .Printer_Ignor| 00001ba0 65 0d 09 88 1f 20 f2 50 72 69 6e 74 65 72 5f 58 |e.... .Printer_X| 00001bb0 6f 6e 58 6f 66 66 28 58 4f 4e 5f 6e 65 77 25 29 |onXoff(XON_new%)| 00001bc0 0d 09 92 05 cd 0d 09 9c 45 e7 20 6c 6f 63 61 74 |........E. locat| 00001bd0 69 6f 6e 5f 63 6f 6e 66 69 67 25 20 3d 20 30 20 |ion_config% = 0 | 00001be0 8c 20 24 66 69 6c 65 5f 6e 61 6d 65 25 20 3d 20 |. $file_name% = | 00001bf0 22 6e 75 6c 6c 3a 22 3a 6c 6f 63 61 74 69 6f 6e |"null:":location| 00001c00 5f 63 6f 6e 66 69 67 25 3d 35 0d 09 a6 23 f2 73 |_config%=5...#.s| 00001c10 65 74 5f 74 69 63 6b 28 62 61 75 64 6d 25 2c 20 |et_tick(baudm%, | 00001c20 62 61 75 64 5f 6e 65 77 25 2c 20 31 29 0d 09 b0 |baud_new%, 1)...| 00001c30 19 c8 8e 20 6c 6f 63 61 74 69 6f 6e 5f 63 6f 6e |... location_con| 00001c40 66 69 67 25 20 ca 0d 09 ba 27 20 20 20 c9 20 31 |fig% ....' . 1| 00001c50 3a 20 f2 73 65 74 5f 74 69 63 6b 28 70 72 69 6e |: .set_tick(prin| 00001c60 74 6d 65 6e 75 25 2c 20 31 2c 20 31 29 0d 09 c4 |tmenu%, 1, 1)...| 00001c70 27 20 20 20 c9 20 32 3a 20 f2 73 65 74 5f 74 69 |' . 2: .set_ti| 00001c80 63 6b 28 70 72 69 6e 74 6d 65 6e 75 25 2c 20 32 |ck(printmenu%, 2| 00001c90 2c 20 31 29 0d 09 ce 27 20 20 20 c9 20 34 3a 20 |, 1)...' . 4: | 00001ca0 f2 73 65 74 5f 74 69 63 6b 28 70 72 69 6e 74 6d |.set_tick(printm| 00001cb0 65 6e 75 25 2c 20 33 2c 20 31 29 0d 09 d8 27 20 |enu%, 3, 1)...' | 00001cc0 20 20 c9 20 35 3a 20 f2 73 65 74 5f 74 69 63 6b | . 5: .set_tick| 00001cd0 28 70 72 69 6e 74 6d 65 6e 75 25 2c 20 34 2c 20 |(printmenu%, 4, | 00001ce0 31 29 0d 09 e2 05 cb 0d 09 ec 24 6c 6f 63 61 74 |1)........$locat| 00001cf0 69 6f 6e 5f 6e 65 77 25 20 3d 20 6c 6f 63 61 74 |ion_new% = locat| 00001d00 69 6f 6e 5f 63 6f 6e 66 69 67 25 0d 09 f6 1c e7 |ion_config%.....| 00001d10 20 6c 6f 63 61 74 69 6f 6e 5f 6e 65 77 25 3d 35 | location_new%=5| 00001d20 20 f2 73 74 61 6d 70 0d 0a 00 18 e7 20 73 65 72 | .stamp..... ser| 00001d30 76 65 72 5f 70 74 72 25 20 3d 20 2d 31 20 8c 0d |ver_ptr% = -1 ..| 00001d40 0a 0a 23 20 c8 99 20 22 4f 53 5f 42 79 74 65 22 |..# .. "OS_Byte"| 00001d50 2c 20 31 36 31 2c 20 33 20 b8 20 2c 2c 74 65 6d |, 161, 3 . ,,tem| 00001d60 70 25 0d 0a 14 12 20 e7 20 74 65 6d 70 25 20 3d |p%.... . temp% =| 00001d70 20 30 20 8c 0d 0a 1e 24 20 20 c8 99 20 22 4f 53 | 0 ....$ .. "OS| 00001d80 5f 42 79 74 65 22 2c 20 31 36 31 2c 20 34 20 b8 |_Byte", 161, 4 .| 00001d90 20 2c 2c 74 65 6d 70 25 0d 0a 28 1f 20 20 73 65 | ,,temp%..(. se| 00001da0 72 76 65 72 5f 63 6f 6e 66 69 67 24 20 3d 20 bd |rver_config$ = .| 00001db0 28 74 65 6d 70 25 29 0d 0a 32 13 20 20 72 61 6d |(temp%)..2. ram| 00001dc0 76 61 6c 25 20 3d 20 26 39 39 0d 0a 3c 07 20 20 |val% = &99..<. | 00001dd0 f5 0d 0a 46 2b 20 20 20 c8 99 20 22 4f 53 5f 42 |...F+ .. "OS_B| 00001de0 79 74 65 22 2c 20 31 36 31 2c 20 72 61 6d 76 61 |yte", 161, ramva| 00001df0 6c 25 20 b8 20 2c 2c 74 65 6d 70 25 0d 0a 50 3d |l% . ,,temp%..P=| 00001e00 20 20 20 e7 20 74 65 6d 70 25 20 3e 33 32 20 73 | . temp% >32 s| 00001e10 65 72 76 65 72 5f 63 6f 6e 66 69 67 24 20 3d 20 |erver_config$ = | 00001e20 73 65 72 76 65 72 5f 63 6f 6e 66 69 67 24 20 2b |server_config$ +| 00001e30 20 bd 28 74 65 6d 70 25 29 0d 0a 5a 13 20 20 20 | .(temp%)..Z. | 00001e40 72 61 6d 76 61 6c 25 20 2b 3d 20 31 0d 0a 64 23 |ramval% += 1..d#| 00001e50 20 20 fd 20 74 65 6d 70 25 20 3c 3d 20 33 32 20 | . temp% <= 32 | 00001e60 84 20 72 61 6d 76 61 6c 25 20 3d 20 26 39 45 0d |. ramval% = &9E.| 00001e70 0a 6e 06 20 cc 0d 0a 78 23 20 20 73 65 72 76 65 |.n. ...x# serve| 00001e80 72 5f 63 6f 6e 66 69 67 24 20 3d 20 22 2e 22 2b |r_config$ = "."+| 00001e90 c3 28 74 65 6d 70 25 29 0d 0a 82 24 20 20 c8 99 |.(temp%)...$ ..| 00001ea0 20 22 4f 53 5f 42 79 74 65 22 2c 20 31 36 31 2c | "OS_Byte", 161,| 00001eb0 20 34 20 b8 20 2c 2c 74 65 6d 70 25 0d 0a 8c 30 | 4 . ,,temp%...0| 00001ec0 20 20 73 65 72 76 65 72 5f 63 6f 6e 66 69 67 24 | server_config$| 00001ed0 20 3d 20 c3 28 74 65 6d 70 25 29 20 2b 20 73 65 | = .(temp%) + se| 00001ee0 72 76 65 72 5f 63 6f 6e 66 69 67 24 0d 0a 96 06 |rver_config$....| 00001ef0 20 cd 0d 0a a0 05 cd 0d 0a aa 21 24 73 65 72 76 | .........!$serv| 00001f00 65 72 5f 6e 65 77 25 20 3d 20 73 65 72 76 65 72 |er_new% = server| 00001f10 5f 63 6f 6e 66 69 67 24 0d 0a b4 05 e1 0d 0a be |_config$........| 00001f20 05 3a 0d 0a c8 16 dd 20 f2 72 65 64 72 61 77 28 |.:..... .redraw(| 00001f30 68 61 6e 64 6c 65 25 29 0d 0a d2 05 e1 0d 0a dc |handle%)........| 00001f40 05 3a 0d 0a e6 18 dd 20 f2 72 65 63 65 69 76 65 |.:..... .receive| 00001f50 28 6d 65 73 73 61 67 65 25 29 0d 0a f0 29 ea 20 |(message%)...). | 00001f60 6d 79 5f 72 65 66 25 2c 20 74 79 70 65 24 2c 20 |my_ref%, type$, | 00001f70 6f 70 74 69 6f 6e 24 2c 20 49 25 2c 20 70 66 6c |option$, I%, pfl| 00001f80 61 67 25 0d 0a fa 18 6d 79 5f 72 65 66 25 20 3d |ag%....my_ref% =| 00001f90 20 6d 65 73 73 61 67 65 25 21 38 0d 0b 04 14 c8 | message%!8.....| 00001fa0 8e 20 6d 65 73 73 61 67 65 25 21 31 36 20 ca 0d |. message%!16 ..| 00001fb0 0b 0e 1b 20 c9 20 30 2c 4d 65 73 73 61 67 65 5f |... . 0,Message_| 00001fc0 50 72 69 6e 74 42 75 73 79 25 0d 0b 18 11 20 20 |PrintBusy%.... | 00001fd0 f2 65 6e 64 63 6f 6e 66 69 72 6d 0d 0b 22 10 20 |.endconfirm..". | 00001fe0 20 f2 74 65 72 6d 69 6e 61 74 65 0d 0b 2c 1b 20 | .terminate..,. | 00001ff0 c9 20 31 2c 4d 65 73 73 61 67 65 5f 50 72 69 6e |. 1,Message_Prin| 00002000 74 53 61 76 65 25 0d 0b 36 34 20 20 f4 20 73 61 |tSave%..64 . sa| 00002010 76 65 20 6f 6e 74 6f 20 6f 75 72 20 69 63 6f 6e |ve onto our icon| 00002020 3b 20 72 65 70 6c 79 20 77 69 74 68 20 50 72 69 |; reply with Pri| 00002030 6e 74 20 6d 65 73 73 61 67 65 0d 0b 40 28 20 20 |nt message..@( | 00002040 e3 20 49 25 3d 30 b8 32 35 32 88 34 3a 6d 73 67 |. I%=0.252.4:msg| 00002050 25 21 49 25 3d 6d 65 73 73 61 67 65 25 21 49 25 |%!I%=message%!I%| 00002060 3a ed 0d 0b 4a 11 20 20 f2 65 6e 64 63 6f 6e 66 |:...J. .endconf| 00002070 69 72 6d 0d 0b 54 3f 20 20 e7 20 70 72 69 6e 74 |irm..T? . print| 00002080 5f 72 65 66 25 20 8c 20 f2 6d 6f 61 6e 28 22 43 |_ref% . .moan("C| 00002090 61 6e 20 6f 6e 6c 79 20 70 72 69 6e 74 20 6f 6e |an only print on| 000020a0 65 20 66 69 6c 65 20 61 74 20 61 20 74 69 6d 65 |e file at a time| 000020b0 22 29 0d 0b 5e 23 20 20 73 61 76 65 5f 6e 61 6d |")..^# save_nam| 000020c0 65 24 3d a4 72 74 6f 7a 28 6d 65 73 73 61 67 65 |e$=.rtoz(message| 000020d0 25 2b 34 34 29 0d 0b 68 13 20 20 e7 20 70 72 69 |%+44)..h. . pri| 000020e0 6e 74 5f 6f 6e 25 20 8c 0d 0b 72 18 20 20 20 e7 |nt_on% ...r. .| 000020f0 20 6d 65 73 73 61 67 65 25 21 31 36 3d 31 20 8c | message%!16=1 .| 00002100 0d 0b 7c 21 20 20 20 20 f2 6d 6f 61 6e 28 22 41 |..|! .moan("A| 00002110 6c 72 65 61 64 79 20 70 72 69 6e 74 69 6e 67 22 |lready printing"| 00002120 29 0d 0b 86 08 20 20 20 cc 0d 0b 90 13 20 20 20 |).... ..... | 00002130 20 6d 73 67 25 21 30 20 3d 20 32 30 0d 0b 9a 19 | msg%!0 = 20....| 00002140 20 20 20 20 6d 73 67 25 21 31 32 20 3d 20 6d 79 | msg%!12 = my| 00002150 5f 72 65 66 25 0d 0b a4 24 20 20 20 20 6d 73 67 |_ref%...$ msg| 00002160 25 21 31 36 20 3d 20 4d 65 73 73 61 67 65 5f 50 |%!16 = Message_P| 00002170 72 69 6e 74 42 75 73 79 25 0d 0b ae 2f 20 20 20 |rintBusy%.../ | 00002180 20 c8 99 20 22 57 69 6d 70 5f 53 65 6e 64 4d 65 | .. "Wimp_SendMe| 00002190 73 73 61 67 65 22 2c 20 31 37 2c 20 6d 73 67 25 |ssage", 17, msg%| 000021a0 2c 20 6d 73 67 25 21 34 0d 0b b8 08 20 20 20 cd |, msg%!4.... .| 000021b0 0d 0b c2 07 20 20 cc 0d 0b cc 18 20 20 20 6d 73 |.... ..... ms| 000021c0 67 25 21 31 32 20 3d 20 6d 79 5f 72 65 66 25 0d |g%!12 = my_ref%.| 000021d0 0b d6 23 20 20 20 6d 73 67 25 21 31 36 20 3d 20 |..# msg%!16 = | 000021e0 4d 65 73 73 61 67 65 5f 50 72 69 6e 74 46 69 6c |Message_PrintFil| 000021f0 65 25 0d 0b e0 18 20 20 20 e7 20 6d 65 73 73 61 |e%.... . messa| 00002200 67 65 25 21 31 36 3d 31 20 8c 0d 0b ea 13 20 20 |ge%!16=1 ..... | 00002210 20 20 6d 73 67 25 21 30 20 3d 20 36 30 0d 0b f4 | msg%!0 = 60...| 00002220 26 20 20 20 20 24 28 6d 73 67 25 2b 34 34 29 20 |& $(msg%+44) | 00002230 3d 20 22 3c 50 72 69 6e 74 65 72 24 53 63 72 61 |= "<Printer$Scra| 00002240 70 3e 22 0d 0b fe 13 20 20 20 20 6d 73 67 25 3f |p>".... msg%?| 00002250 35 39 20 3d 20 30 0d 0c 08 08 20 20 20 cd 0d 0c |59 = 0.... ...| 00002260 12 2e 20 20 20 c8 99 20 22 57 69 6d 70 5f 53 65 |.. .. "Wimp_Se| 00002270 6e 64 4d 65 73 73 61 67 65 22 2c 20 31 38 2c 20 |ndMessage", 18, | 00002280 6d 73 67 25 2c 20 6d 73 67 25 21 34 0d 0c 1c 1a |msg%, msg%!4....| 00002290 20 20 20 6d 73 67 25 21 34 20 3d 20 6d 65 73 73 | msg%!4 = mess| 000022a0 61 67 65 25 21 34 0d 0c 26 18 20 20 20 70 72 69 |age%!4..&. pri| 000022b0 6e 74 5f 72 65 66 25 3d 6d 73 67 25 21 38 0d 0c |nt_ref%=msg%!8..| 000022c0 30 07 20 20 cd 0d 0c 3a 08 20 c9 20 33 0d 0c 44 |0. ...:. . 3..D| 000022d0 11 20 20 f2 65 6e 64 63 6f 6e 66 69 72 6d 0d 0c |. .endconfirm..| 000022e0 4e 59 20 20 e7 20 70 72 69 6e 74 5f 72 65 66 25 |NY . print_ref%| 000022f0 20 e7 20 70 72 69 6e 74 5f 72 65 66 25 3c 3e 6d | . print_ref%<>m| 00002300 65 73 73 61 67 65 25 21 31 32 20 8c 20 f2 6d 6f |essage%!12 . .mo| 00002310 61 6e 28 22 43 61 6e 20 6f 6e 6c 79 20 70 72 69 |an("Can only pri| 00002320 6e 74 20 6f 6e 65 20 66 69 6c 65 20 61 74 20 61 |nt one file at a| 00002330 20 74 69 6d 65 22 29 0d 0c 58 12 20 20 70 72 69 | time")..X. pri| 00002340 6e 74 5f 72 65 66 25 3d 30 0d 0c 62 14 20 20 e7 |nt_ref%=0..b. .| 00002350 20 70 72 69 6e 74 5f 6f 6e 25 20 20 8c 0d 0c 6c | print_on% ...l| 00002360 20 20 20 20 f2 6d 6f 61 6e 28 22 41 6c 72 65 61 | .moan("Alrea| 00002370 64 79 20 70 72 69 6e 74 69 6e 67 22 29 0d 0c 76 |dy printing")..v| 00002380 07 20 20 cc 0d 0c 80 29 20 20 20 e3 20 49 25 3d |. ....) . I%=| 00002390 30 b8 32 35 32 88 34 3a 6d 73 67 25 21 49 25 3d |0.252.4:msg%!I%=| 000023a0 6d 65 73 73 61 67 65 25 21 49 25 3a ed 0d 0c 8a |message%!I%:....| 000023b0 22 20 20 20 66 69 6c 65 6e 61 6d 24 3d a4 72 74 |" filenam$=.rt| 000023c0 6f 7a 28 6d 65 73 73 61 67 65 25 2b 34 34 29 0d |oz(message%+44).| 000023d0 0c 94 1c 20 20 20 6d 65 73 73 61 67 65 25 21 31 |... message%!1| 000023e0 32 20 3d 20 6d 79 5f 72 65 66 25 0d 0c 9e 33 20 |2 = my_ref%...3 | 000023f0 20 20 c8 99 20 22 57 69 6d 70 5f 53 65 6e 64 4d | .. "Wimp_SendM| 00002400 65 73 73 61 67 65 22 2c 31 39 2c 6d 65 73 73 61 |essage",19,messa| 00002410 67 65 25 2c 6d 65 73 73 61 67 65 25 21 34 0d 0c |ge%,message%!4..| 00002420 a8 36 20 20 20 f4 20 6a 75 73 74 20 61 63 6b 20 |.6 . just ack | 00002430 74 68 65 20 6d 65 73 73 61 67 65 20 69 6e 20 63 |the message in c| 00002440 61 73 65 20 46 4e 63 6f 6e 66 69 72 6d 20 63 61 |ase FNconfirm ca| 00002450 6c 6c 65 64 0d 0c b2 19 20 20 20 46 74 79 70 65 |lled.... Ftype| 00002460 25 3d 6d 65 73 73 61 67 65 25 21 34 30 0d 0c bc |%=message%!40...| 00002470 14 20 20 20 74 79 70 65 5f 73 74 61 74 65 25 3d |. type_state%=| 00002480 30 0d 0c c6 1e 20 20 20 e7 20 46 74 79 70 65 25 |0.... . Ftype%| 00002490 3c 3e 4f 75 74 70 75 74 54 79 70 65 25 20 8c 0d |<>OutputType% ..| 000024a0 0c d0 11 20 20 20 20 6d 73 67 25 21 31 32 3d 30 |... msg%!12=0| 000024b0 0d 0c da 25 20 20 20 20 6d 73 67 25 21 31 36 3d |...% msg%!16=| 000024c0 4d 65 73 73 61 67 65 5f 50 72 69 6e 74 54 79 70 |Message_PrintTyp| 000024d0 65 4f 64 64 25 0d 0c e4 29 20 20 20 20 c8 99 22 |eOdd%...) .."| 000024e0 57 69 6d 70 5f 53 65 6e 64 4d 65 73 73 61 67 65 |Wimp_SendMessage| 000024f0 22 2c 20 31 38 2c 20 6d 73 67 25 2c 20 30 0d 0c |", 18, msg%, 0..| 00002500 ee 19 20 20 20 20 70 72 69 6e 74 5f 72 65 66 25 |.. print_ref%| 00002510 3d 6d 73 67 25 21 38 0d 0c f8 09 20 20 20 20 f5 |=msg%!8.... .| 00002520 0d 0d 02 33 20 20 20 20 20 c8 99 20 22 57 69 6d |...3 .. "Wim| 00002530 70 5f 50 6f 6c 6c 22 2c 70 6f 6c 6c 5f 6d 61 73 |p_Poll",poll_mas| 00002540 6b 25 2c 65 76 65 6e 74 25 20 b8 20 61 63 74 69 |k%,event% . acti| 00002550 6f 6e 25 0d 0d 0c 17 20 20 20 20 20 f2 64 65 73 |on%.... .des| 00002560 70 61 74 63 68 5f 70 6f 6c 6c 0d 0d 16 15 20 20 |patch_poll.... | 00002570 20 20 fd 20 74 79 70 65 5f 73 74 61 74 65 25 0d | . type_state%.| 00002580 0d 20 08 20 20 20 cd 0d 0d 2a 0f 20 20 20 70 66 |. . ...*. pf| 00002590 6c 61 67 25 3d a3 0d 0d 34 18 20 20 20 e7 20 74 |lag%=...4. . t| 000025a0 79 70 65 5f 73 74 61 74 65 25 3d 32 20 8c 0d 0d |ype_state%=2 ...| 000025b0 3e 3e 20 20 20 20 e7 20 66 69 6c 65 6e 61 6d 24 |>> . filenam$| 000025c0 20 3d 20 22 3c 50 72 69 6e 74 65 72 24 53 63 72 | = "<Printer$Scr| 000025d0 61 70 3e 22 20 8c 20 ff 28 22 72 65 6d 6f 76 65 |ap>" . .("remove| 000025e0 20 22 2b 66 69 6c 65 6e 61 6d 24 29 0d 0d 48 22 | "+filenam$)..H"| 000025f0 20 20 20 20 69 6e 5f 66 69 6c 65 25 3d 8e 22 3c | in_file%=."<| 00002600 50 72 69 6e 74 65 72 24 54 65 6d 70 3e 22 0d 0d |Printer$Temp>"..| 00002610 52 17 20 20 20 20 e7 20 69 6e 5f 66 69 6c 65 25 |R. . in_file%| 00002620 3c 3e 30 20 8c 0d 0d 5c 24 20 20 20 20 20 66 69 |<>0 ...\$ fi| 00002630 6c 65 6e 61 6d 24 20 3d 20 22 3c 50 72 69 6e 74 |lenam$ = "<Print| 00002640 65 72 24 54 65 6d 70 3e 22 0d 0d 66 1e 20 20 20 |er$Temp>"..f. | 00002650 20 20 d9 23 69 6e 5f 66 69 6c 65 25 3a 69 6e 5f | .#in_file%:in_| 00002660 66 69 6c 65 25 3d 30 0d 0d 70 11 20 20 20 20 20 |file%=0..p. | 00002670 70 66 6c 61 67 25 3d b9 0d 0d 7a 09 20 20 20 20 |pflag%=...z. | 00002680 cd 0d 0d 84 08 20 20 20 cc 0d 0d 8e 17 20 20 20 |..... ..... | 00002690 20 e7 20 a4 63 68 65 63 6b 5f 74 79 70 65 20 8c | . .check_type .| 000026a0 0d 0d 98 19 20 20 20 20 20 e7 20 41 6c 69 61 73 |.... . Alias| 000026b0 24 20 3c 3e 20 22 22 20 8c 0d 0d a2 31 20 20 20 |$ <> "" ....1 | 000026c0 20 20 20 c8 99 20 22 57 69 6d 70 5f 53 74 61 72 | .. "Wimp_Star| 000026d0 74 54 61 73 6b 22 2c 41 6c 69 61 73 24 2b 22 20 |tTask",Alias$+" | 000026e0 22 2b 66 69 6c 65 6e 61 6d 24 0d 0d ac 24 20 20 |"+filenam$...$ | 000026f0 20 20 20 20 69 6e 5f 66 69 6c 65 25 3d 8e 22 3c | in_file%=."<| 00002700 50 72 69 6e 74 65 72 24 54 65 6d 70 3e 22 0d 0d |Printer$Temp>"..| 00002710 b6 19 20 20 20 20 20 20 e7 20 69 6e 5f 66 69 6c |.. . in_fil| 00002720 65 25 3c 3e 30 20 8c 0d 0d c0 26 20 20 20 20 20 |e%<>0 ....& | 00002730 20 20 66 69 6c 65 6e 61 6d 24 20 3d 20 22 3c 50 | filenam$ = "<P| 00002740 72 69 6e 74 65 72 24 54 65 6d 70 3e 22 0d 0d ca |rinter$Temp>"...| 00002750 41 20 20 20 20 20 20 20 e7 20 66 69 6c 65 6e 61 |A . filena| 00002760 6d 24 20 3d 20 22 3c 50 72 69 6e 74 65 72 24 53 |m$ = "<Printer$S| 00002770 63 72 61 70 3e 22 20 8c 20 ff 28 22 72 65 6d 6f |crap>" . .("remo| 00002780 76 65 20 22 2b 66 69 6c 65 6e 61 6d 24 29 0d 0d |ve "+filenam$)..| 00002790 d4 20 20 20 20 20 20 20 20 d9 23 69 6e 5f 66 69 |. .#in_fi| 000027a0 6c 65 25 3a 69 6e 5f 66 69 6c 65 25 3d 30 0d 0d |le%:in_file%=0..| 000027b0 de 13 20 20 20 20 20 20 20 70 66 6c 61 67 25 3d |.. pflag%=| 000027c0 b9 0d 0d e8 0b 20 20 20 20 20 20 cd 0d 0d f2 0a |..... .....| 000027d0 20 20 20 20 20 cc 0d 0d fc 12 20 20 20 20 20 20 | ..... | 000027e0 70 66 6c 61 67 25 3d b9 0d 0e 06 0a 20 20 20 20 |pflag%=..... | 000027f0 20 cd 0d 0e 10 09 20 20 20 20 cd 0d 0e 1a 08 20 | ..... ..... | 00002800 20 20 cd 0d 0e 24 11 20 20 20 e7 20 70 66 6c 61 | ...$. . pfla| 00002810 67 25 20 8c 0d 0e 2e 1d 20 20 20 20 e7 20 6c 6f |g% ..... . lo| 00002820 63 61 74 69 6f 6e 5f 6e 65 77 25 20 3d 20 34 20 |cation_new% = 4 | 00002830 8c 0d 0e 38 2f 20 20 20 20 20 74 79 70 65 24 20 |...8/ type$ | 00002840 3d 20 22 6e 65 74 70 72 69 6e 74 23 22 2b 70 72 |= "netprint#"+pr| 00002850 69 6e 74 65 72 5f 74 79 70 65 24 2b 22 3a 24 22 |inter_type$+":$"| 00002860 0d 0e 42 09 20 20 20 20 cc 0d 0e 4c 42 20 20 20 |..B. ...LB | 00002870 20 20 e7 20 6c 6f 63 61 74 69 6f 6e 5f 6e 65 77 | . location_new| 00002880 25 20 3d 20 35 20 8c 20 ff 28 22 73 65 74 20 50 |% = 5 . .("set P| 00002890 72 69 6e 74 65 72 54 79 70 65 24 35 20 22 2b 24 |rinterType$5 "+$| 000028a0 66 69 6c 65 5f 6e 61 6d 65 25 29 0d 0e 56 1a 20 |file_name%)..V. | 000028b0 20 20 20 20 74 79 70 65 24 3d 22 70 72 69 6e 74 | type$="print| 000028c0 65 72 3a 24 22 0d 0e 60 24 20 20 20 20 20 c8 99 |er:$"..`$ ..| 000028d0 22 4f 53 5f 42 79 74 65 22 2c 35 2c 6c 6f 63 61 |"OS_Byte",5,loca| 000028e0 74 69 6f 6e 5f 6e 65 77 25 0d 0e 6a 09 20 20 20 |tion_new%..j. | 000028f0 20 cd 0d 0e 74 2b 20 20 20 20 f4 20 66 69 6c 65 | ...t+ . file| 00002900 6e 61 6d 24 20 69 73 20 61 6c 73 6f 20 75 73 65 |nam$ is also use| 00002910 64 20 69 6e 20 50 52 4f 43 63 6f 70 79 0d 0e 7e |d in PROCcopy..~| 00002920 1f 20 20 20 20 69 6e 5f 66 69 6c 65 25 20 20 3d |. in_file% =| 00002930 20 8e 28 66 69 6c 65 6e 61 6d 24 29 0d 0e 88 18 | .(filenam$)....| 00002940 20 20 20 20 e7 20 69 6e 5f 66 69 6c 65 25 20 3d | . in_file% =| 00002950 20 30 20 8c 0d 0e 92 38 20 20 20 20 20 f2 6d 6f | 0 ....8 .mo| 00002960 61 6e 28 22 43 61 6e 27 74 20 6f 70 65 6e 20 27 |an("Can't open '| 00002970 22 2b 66 69 6c 65 6e 61 6d 24 2b 22 27 20 66 6f |"+filenam$+"' fo| 00002980 72 20 70 72 69 6e 74 69 6e 67 22 29 0d 0e 9c 09 |r printing")....| 00002990 20 20 20 20 cd 0d 0e a6 26 20 20 20 20 6f 75 74 | ....& out| 000029a0 5f 66 69 6c 65 25 20 3d 20 ae 28 74 79 70 65 24 |_file% = .(type$| 000029b0 2b 22 2e 6f 75 74 70 75 74 22 29 0d 0e b0 19 20 |+".output").... | 000029c0 20 20 20 e7 20 6f 75 74 5f 66 69 6c 65 25 20 3d | . out_file% =| 000029d0 20 30 20 8c 0d 0e ba 1e 20 20 20 20 20 d9 23 69 | 0 ..... .#i| 000029e0 6e 5f 66 69 6c 65 25 3a 69 6e 5f 66 69 6c 65 25 |n_file%:in_file%| 000029f0 3d 30 0d 0e c4 3c 20 20 20 20 20 f2 6d 6f 61 6e |=0...< .moan| 00002a00 28 22 43 61 6e 27 74 20 6f 70 65 6e 20 27 22 2b |("Can't open '"+| 00002a10 74 79 70 65 24 2b 22 2e 6f 75 74 70 75 74 27 20 |type$+".output' | 00002a20 66 6f 72 20 70 72 69 6e 74 69 6e 67 22 29 0d 0e |for printing")..| 00002a30 ce 09 20 20 20 20 cd 0d 0e d8 1b 20 20 20 20 f2 |.. ..... .| 00002a40 73 65 74 5f 70 72 69 6e 74 5f 73 74 61 74 65 28 |set_print_state(| 00002a50 b9 29 0d 0e e2 21 20 20 20 20 f2 63 68 61 6e 67 |.)...! .chang| 00002a60 65 5f 69 63 6f 6e 3a f2 75 70 64 61 74 65 5f 69 |e_icon:.update_i| 00002a70 63 6f 6e 0d 0e ec 13 20 20 20 20 70 62 75 66 25 |con.... pbuf%| 00002a80 3d 96 28 2d 34 29 0d 0e f6 0f 20 20 20 20 73 65 |=.(-4).... se| 00002a90 6e 74 25 3d a3 0d 0f 00 17 20 20 20 20 f2 50 72 |nt%=..... .Pr| 00002aa0 69 6e 74 65 72 5f 48 65 61 64 65 72 0d 0f 0a 08 |inter_Header....| 00002ab0 20 20 20 cd 0d 0f 14 29 20 20 20 f4 20 69 6e 64 | ....) . ind| 00002ac0 69 63 61 74 65 20 77 65 20 72 65 63 65 69 76 65 |icate we receive| 00002ad0 64 20 74 68 65 20 66 69 6c 65 20 4f 4b 0d 0f 1e |d the file OK...| 00002ae0 13 20 20 20 6d 73 67 25 21 30 20 20 3d 20 32 30 |. msg%!0 = 20| 00002af0 0d 0f 28 18 20 20 20 6d 73 67 25 21 31 32 20 3d |..(. msg%!12 =| 00002b00 20 6d 79 5f 72 65 66 25 0d 0f 32 12 20 20 20 6d | my_ref%..2. m| 00002b10 73 67 25 21 31 36 20 3d 20 34 0d 0f 3c 13 20 20 |sg%!16 = 4..<. | 00002b20 20 6d 73 67 25 21 33 36 20 3d 20 2d 31 0d 0f 46 | msg%!36 = -1..F| 00002b30 2d 20 20 20 c8 99 22 57 69 6d 70 5f 53 65 6e 64 |- .."Wimp_Send| 00002b40 4d 65 73 73 61 67 65 22 2c 20 31 37 2c 20 6d 73 |Message", 17, ms| 00002b50 67 25 2c 20 6d 73 67 25 21 34 0d 0f 50 07 20 20 |g%, msg%!4..P. | 00002b60 cd 0d 0f 5a 1b 20 c9 20 26 35 30 32 3a 20 f4 20 |...Z. . &502: . | 00002b70 68 65 6c 70 20 72 65 71 75 65 73 74 0d 0f 64 d9 |help request..d.| 00002b80 20 20 e7 20 6d 65 73 73 61 67 65 25 21 33 32 3d | . message%!32=| 00002b90 2d 32 20 80 20 6d 65 73 73 61 67 65 25 21 33 36 |-2 . message%!36| 00002ba0 3d 69 63 70 72 69 6e 74 25 20 f2 68 65 6c 70 72 |=icprint% .helpr| 00002bb0 65 70 6c 79 28 22 54 68 69 73 20 69 73 20 74 68 |eply("This is th| 00002bc0 65 20 22 2b 46 75 6c 6c 50 72 69 6e 74 65 72 43 |e "+FullPrinterC| 00002bd0 6c 61 73 73 24 2b 22 20 70 72 69 6e 74 65 72 20 |lass$+" printer | 00002be0 69 63 6f 6e 2e 7c 4d 44 72 6f 70 20 74 65 78 74 |icon.|MDrop text| 00002bf0 20 66 69 6c 65 73 20 6f 6e 20 74 6f 20 69 74 20 | files on to it | 00002c00 74 6f 20 70 72 69 6e 74 20 74 68 65 6d 2e 7c 4d |to print them.|M| 00002c10 43 6c 69 63 6b 20 4d 45 4e 55 20 6f 72 20 53 45 |Click MENU or SE| 00002c20 4c 45 43 54 20 74 6f 20 73 65 74 20 74 68 65 20 |LECT to set the | 00002c30 70 72 69 6e 74 65 72 20 6f 70 74 69 6f 6e 73 2e |printer options.| 00002c40 22 2c 6d 79 5f 72 65 66 25 2c 6d 65 73 73 61 67 |",my_ref%,messag| 00002c50 65 25 21 34 29 0d 0f 6e 19 20 c9 20 4d 65 73 73 |e%!4)..n. . Mess| 00002c60 61 67 65 5f 57 69 6c 6c 50 72 69 6e 74 25 0d 0f |age_WillPrint%..| 00002c70 78 12 20 20 70 72 69 6e 74 5f 72 65 66 25 3d 30 |x. print_ref%=0| 00002c80 0d 0f 82 19 20 c9 20 4d 65 73 73 61 67 65 5f 50 |.... . Message_P| 00002c90 72 69 6e 74 49 6e 69 74 25 0d 0f 8c 23 20 20 e7 |rintInit%...# .| 00002ca0 20 70 6f 6c 6c 5f 6d 61 73 6b 25 3c 3e ac 28 25 | poll_mask%<>.(%| 00002cb0 31 31 31 20 3c 3c 20 31 37 29 20 8c 0d 0f 96 14 |111 << 17) .....| 00002cc0 20 20 20 e7 20 70 72 69 6e 74 5f 6f 6e 25 20 8c | . print_on% .| 00002cd0 0d 0f a0 11 20 20 20 20 6d 73 67 25 21 30 3d 32 |.... msg%!0=2| 00002ce0 30 0d 0f aa 17 20 20 20 20 6d 73 67 25 21 31 32 |0.... msg%!12| 00002cf0 3d 6d 79 5f 72 65 66 25 0d 0f b4 22 20 20 20 20 |=my_ref%..." | 00002d00 6d 73 67 25 21 31 36 3d 4d 65 73 73 61 67 65 5f |msg%!16=Message_| 00002d10 50 72 69 6e 74 42 75 73 79 25 0d 0f be 33 20 20 |PrintBusy%...3 | 00002d20 20 20 c8 99 20 22 57 69 6d 70 5f 53 65 6e 64 4d | .. "Wimp_SendM| 00002d30 65 73 73 61 67 65 22 2c 20 31 37 2c 20 6d 73 67 |essage", 17, msg| 00002d40 25 2c 20 6d 65 73 73 61 67 65 25 21 34 0d 0f c8 |%, message%!4...| 00002d50 08 20 20 20 cc 0d 0f d2 12 20 20 20 20 f2 74 65 |. ..... .te| 00002d60 72 6d 69 6e 61 74 65 0d 0f dc 08 20 20 20 cd 0d |rminate.... ..| 00002d70 0f e6 07 20 20 cd 0d 0f f0 1e 20 c9 20 4d 65 73 |... ..... . Mes| 00002d80 73 61 67 65 5f 50 72 69 6e 74 54 79 70 65 4b 6e |sage_PrintTypeKn| 00002d90 6f 77 6e 25 0d 0f fa 18 20 20 46 74 79 70 65 25 |own%.... Ftype%| 00002da0 3d 6d 65 73 73 61 67 65 25 21 34 30 0d 10 04 13 |=message%!40....| 00002db0 20 20 74 79 70 65 5f 73 74 61 74 65 25 3d 32 0d | type_state%=2.| 00002dc0 10 0e 12 20 20 70 72 69 6e 74 5f 72 65 66 25 3d |... print_ref%=| 00002dd0 30 0d 10 18 05 cb 0d 10 22 05 e1 0d 10 2c 05 3a |0......."....,.:| 00002de0 0d 10 36 21 dd f2 68 65 6c 70 72 65 70 6c 79 28 |..6!..helpreply(| 00002df0 68 65 6c 70 24 2c 20 72 65 66 25 2c 20 74 6f 25 |help$, ref%, to%| 00002e00 29 0d 10 40 14 6d 73 67 25 21 30 20 20 20 20 20 |)..@.msg%!0 | 00002e10 3d 20 32 35 36 0d 10 4a 15 6d 73 67 25 21 31 32 |= 256..J.msg%!12| 00002e20 20 20 20 20 3d 20 72 65 66 25 0d 10 54 15 6d 73 | = ref%..T.ms| 00002e30 67 25 21 31 36 20 20 20 20 3d 20 26 35 30 33 0d |g%!16 = &503.| 00002e40 10 5e 16 24 28 6d 73 67 25 2b 32 30 29 20 3d 20 |.^.$(msg%+20) = | 00002e50 68 65 6c 70 24 0d 10 68 1c f2 7a 65 72 6f 5f 74 |help$..h..zero_t| 00002e60 65 72 6d 69 6e 61 74 65 28 6d 73 67 25 2b 32 30 |erminate(msg%+20| 00002e70 29 0d 10 72 28 c8 99 20 22 57 69 6d 70 5f 53 65 |)..r(.. "Wimp_Se| 00002e80 6e 64 4d 65 73 73 61 67 65 22 2c 20 31 37 2c 20 |ndMessage", 17, | 00002e90 6d 73 67 25 2c 20 74 6f 25 0d 10 7c 05 e1 0d 10 |msg%, to%..|....| 00002ea0 86 05 3a 0d 10 90 17 dd f2 62 6f 75 6e 63 65 64 |..:......bounced| 00002eb0 28 6d 65 73 73 61 67 65 25 29 0d 10 9a 14 c8 8e |(message%)......| 00002ec0 20 6d 65 73 73 61 67 65 25 21 31 36 20 ca 0d 10 | message%!16 ...| 00002ed0 a4 19 20 c9 20 4d 65 73 73 61 67 65 5f 50 72 69 |.. . Message_Pri| 00002ee0 6e 74 46 69 6c 65 25 0d 10 ae 12 20 20 70 72 69 |ntFile%.... pri| 00002ef0 6e 74 5f 72 65 66 25 3d 30 0d 10 b8 47 20 20 f4 |nt_ref%=0...G .| 00002f00 20 6d 75 73 74 20 62 65 20 61 6e 20 61 70 70 20 | must be an app | 00002f10 74 68 61 74 20 63 61 6e 27 74 20 64 6f 20 69 74 |that can't do it| 00002f20 73 20 6f 77 6e 20 70 72 69 6e 74 69 6e 67 3b 20 |s own printing; | 00002f30 72 65 70 6c 79 20 74 6f 20 6d 65 73 73 61 67 65 |reply to message| 00002f40 0d 10 c2 15 20 20 f4 20 73 74 69 6c 6c 20 69 6e |.... . still in| 00002f50 20 6d 73 67 25 0d 10 cc 11 20 20 f2 65 6e 64 63 | msg%.... .endc| 00002f60 6f 6e 66 69 72 6d 0d 10 d6 16 20 20 e7 20 ac 20 |onfirm.... . . | 00002f70 70 72 69 6e 74 5f 6f 6e 25 20 20 8c 0d 10 e0 45 |print_on% ....E| 00002f80 20 20 20 f4 20 63 61 6e 27 74 20 61 73 6b 20 66 | . can't ask f| 00002f90 6f 72 20 63 6f 6e 66 69 72 6d 61 74 69 6f 6e 20 |or confirmation | 00002fa0 6f 66 20 73 74 75 70 69 64 20 74 79 70 65 73 20 |of stupid types | 00002fb0 61 73 20 61 6e 20 61 66 66 69 72 6d 61 74 69 76 |as an affirmativ| 00002fc0 65 0d 10 ea 41 20 20 20 f4 20 63 6c 69 63 6b 20 |e...A . click | 00002fd0 77 69 6c 6c 20 70 72 6f 62 61 62 6c 79 20 73 68 |will probably sh| 00002fe0 75 74 20 64 6f 77 6e 20 74 68 65 20 74 72 61 6e |ut down the tran| 00002ff0 73 66 65 72 20 61 74 20 74 68 65 20 73 6f 75 72 |sfer at the sour| 00003000 63 65 0d 10 f4 15 20 20 20 6d 73 67 25 21 31 36 |ce.... msg%!16| 00003010 20 20 20 20 3d 20 32 0d 10 fe 2b 20 20 20 6d 73 | = 2...+ ms| 00003020 67 25 21 33 36 20 20 20 20 3d 20 2d 31 20 3a 20 |g%!36 = -1 : | 00003030 f4 20 66 69 6c 65 20 69 73 20 6e 6f 74 20 73 61 |. file is not sa| 00003040 66 65 0d 11 08 2e 20 20 20 c8 99 20 22 57 69 6d |fe.... .. "Wim| 00003050 70 5f 53 65 6e 64 4d 65 73 73 61 67 65 22 2c 20 |p_SendMessage", | 00003060 31 37 2c 20 6d 73 67 25 2c 20 6d 73 67 25 21 34 |17, msg%, msg%!4| 00003070 0d 11 12 07 20 20 cc 0d 11 1c 20 20 20 20 f2 6d |.... .... .m| 00003080 6f 61 6e 28 22 41 6c 72 65 61 64 79 20 70 72 69 |oan("Already pri| 00003090 6e 74 69 6e 67 22 29 0d 11 26 07 20 20 cd 0d 11 |nting")..&. ...| 000030a0 30 19 20 c9 20 4d 65 73 73 61 67 65 5f 50 72 69 |0. . Message_Pri| 000030b0 6e 74 49 6e 69 74 25 0d 11 3a 0c 20 20 f2 69 6e |ntInit%..:. .in| 000030c0 69 74 32 0d 11 44 12 20 20 70 6f 6c 6c 5f 6d 61 |it2..D. poll_ma| 000030d0 73 6b 25 3d 31 0d 11 4e 1c 20 c9 20 4d 65 73 73 |sk%=1..N. . Mess| 000030e0 61 67 65 5f 50 72 69 6e 74 54 79 70 65 4f 64 64 |age_PrintTypeOdd| 000030f0 25 0d 11 58 13 20 20 74 79 70 65 5f 73 74 61 74 |%..X. type_stat| 00003100 65 25 3d 31 0d 11 62 12 20 20 70 72 69 6e 74 5f |e%=1..b. print_| 00003110 72 65 66 25 3d 30 0d 11 6c 05 cb 0d 11 76 05 e1 |ref%=0..l....v..| 00003120 0d 11 80 05 3a 0d 11 8a 10 dd a4 63 68 65 63 6b |....:......check| 00003130 5f 74 79 70 65 0d 11 94 14 ea 20 4c 25 2c 70 73 |_type..... L%,ps| 00003140 72 25 2c 20 74 79 70 65 24 0d 11 9e 0d 41 6c 69 |r%, type$....Ali| 00003150 61 73 24 3d 22 22 0d 11 a8 40 f4 20 69 66 20 61 |as$=""...@. if a| 00003160 6e 20 41 6c 69 61 73 24 40 50 72 69 6e 74 54 79 |n Alias$@PrintTy| 00003170 70 65 5f 3c 46 74 79 70 65 25 3e 20 65 78 69 73 |pe_<Ftype%> exis| 00003180 74 73 20 74 68 65 6e 20 70 72 69 6e 74 20 76 69 |ts then print vi| 00003190 61 20 74 68 61 74 0d 11 b2 14 74 79 70 65 24 20 |a that....type$ | 000031a0 3d 20 c3 7e 46 74 79 70 65 25 0d 11 bc 2f e7 20 |= .~Ftype%.../. | 000031b0 a9 74 79 70 65 24 20 3c 20 33 20 8c 20 74 79 70 |.type$ < 3 . typ| 000031c0 65 24 20 3d 20 c4 33 2d a9 74 79 70 65 24 2c 22 |e$ = .3-.type$,"| 000031d0 30 22 29 2b 74 79 70 65 24 0d 11 c6 3b c8 99 22 |0")+type$...;.."| 000031e0 58 4f 53 5f 52 65 61 64 56 61 72 56 61 6c 22 2c |XOS_ReadVarVal",| 000031f0 22 41 6c 69 61 73 24 40 50 72 69 6e 74 54 79 70 |"Alias$@PrintTyp| 00003200 65 5f 22 2b 74 79 70 65 24 2c 2c 2d 31 20 b8 20 |e_"+type$,,-1 . | 00003210 2c 2c 4c 25 0d 11 d0 2e e7 20 4c 25 20 3c 20 30 |,,L%..... L% < 0| 00003220 20 8c 20 41 6c 69 61 73 24 3d 22 40 50 72 69 6e | . Alias$="@Prin| 00003230 74 54 79 70 65 5f 22 2b 74 79 70 65 24 3a 20 3d |tType_"+type$: =| 00003240 20 b9 0d 11 da 4d e7 20 46 74 79 70 65 25 20 3d | ....M. Ftype% =| 00003250 20 26 46 46 46 20 84 20 46 74 79 70 65 25 20 3d | &FFF . Ftype% =| 00003260 20 26 46 46 45 20 84 20 46 74 79 70 65 25 20 3d | &FFE . Ftype% =| 00003270 20 26 46 45 42 20 84 20 46 74 79 70 65 25 3d 4f | &FEB . Ftype%=O| 00003280 75 74 70 75 74 54 79 70 65 25 20 8c 20 3d b9 0d |utputType% . =..| 00003290 11 e4 35 f4 20 74 65 78 74 2c 20 65 78 65 63 20 |..5. text, exec | 000032a0 61 6e 64 20 6f 62 65 79 20 66 69 6c 65 73 20 61 |and obey files a| 000032b0 72 65 20 61 6c 6c 20 73 74 72 61 69 67 68 74 20 |re all straight | 000032c0 74 65 78 74 0d 11 ee 38 e7 20 46 74 79 70 65 25 |text...8. Ftype%| 000032d0 20 3d 20 26 31 30 30 30 20 8c 20 f2 6d 6f 61 6e | = &1000 . .moan| 000032e0 28 22 43 61 6e 6e 6f 74 20 70 72 69 6e 74 20 64 |("Cannot print d| 000032f0 69 72 65 63 74 6f 72 69 65 73 22 29 0d 11 f8 39 |irectories")...9| 00003300 e7 20 46 74 79 70 65 25 20 3d 20 26 32 30 30 30 |. Ftype% = &2000| 00003310 20 8c 20 f2 6d 6f 61 6e 28 22 43 61 6e 6e 6f 74 | . .moan("Cannot| 00003320 20 70 72 69 6e 74 20 61 70 70 6c 69 63 61 74 69 | print applicati| 00003330 6f 6e 73 22 29 0d 12 02 16 e7 20 46 74 79 70 65 |ons")..... Ftype| 00003340 25 20 3d 20 26 33 30 30 30 20 8c 0d 12 0c 1f 20 |% = &3000 ..... | 00003350 24 65 72 72 6f 72 5f 62 6c 6b 25 20 3d 20 22 61 |$error_blk% = "a| 00003360 6e 20 75 6e 74 79 70 65 64 22 0d 12 16 05 cc 0d |n untyped"......| 00003370 12 20 45 20 c8 99 22 58 4f 53 5f 52 65 61 64 56 |. E .."XOS_ReadV| 00003380 61 72 56 61 6c 22 2c 22 46 69 6c 65 24 54 79 70 |arVal","File$Typ| 00003390 65 5f 22 2b 74 79 70 65 24 2c 65 72 72 6f 72 5f |e_"+type$,error_| 000033a0 62 6c 6b 25 2c 31 30 30 20 b8 20 2c 2c 4c 25 3b |blk%,100 . ,,L%;| 000033b0 70 73 72 25 0d 12 2a 44 20 e7 20 70 73 72 25 20 |psr%..*D . psr% | 000033c0 80 20 31 20 8c 20 24 65 72 72 6f 72 5f 62 6c 6b |. 1 . $error_blk| 000033d0 25 3d 22 74 79 70 65 20 26 22 2b c3 7e 46 74 79 |%="type &"+.~Fty| 000033e0 70 65 25 20 8b 20 65 72 72 6f 72 5f 62 6c 6b 25 |pe% . error_blk%| 000033f0 3f 4c 25 20 3d 20 31 33 0d 12 34 05 cd 0d 12 3e |?L% = 13..4....>| 00003400 50 3d a4 63 6f 6e 66 69 72 6d 28 22 54 68 69 73 |P=.confirm("This| 00003410 20 69 73 20 61 20 22 2b 24 65 72 72 6f 72 5f 62 | is a "+$error_b| 00003420 6c 6b 25 2b 22 20 66 69 6c 65 3b 20 64 6f 20 79 |lk%+" file; do y| 00003430 6f 75 20 72 65 61 6c 6c 79 20 77 61 6e 74 20 74 |ou really want t| 00003440 6f 20 70 72 69 6e 74 20 69 74 3f 22 29 0d 12 48 |o print it?")..H| 00003450 05 3a 0d 12 52 17 dd a4 63 6f 6e 66 69 72 6d 28 |.:..R...confirm(| 00003460 6d 65 73 73 61 67 65 24 29 0d 12 5c 11 ea 20 53 |message$)..\.. S| 00003470 25 2c 20 61 63 74 69 6f 6e 25 0d 12 66 1c 53 25 |%, action%..f.S%| 00003480 3d a4 69 63 6f 6e 61 64 64 72 28 63 6f 6e 66 69 |=.iconaddr(confi| 00003490 72 6d 25 2c 30 29 0d 12 70 10 24 53 25 3d 6d 65 |rm%,0)..p.$S%=me| 000034a0 73 73 61 67 65 24 0d 12 7a 0f f2 67 65 74 70 6f |ssage$..z..getpo| 000034b0 69 6e 74 65 72 0d 12 84 3a c8 99 20 22 57 69 6d |inter...:.. "Wim| 000034c0 70 5f 43 72 65 61 74 65 4d 65 6e 75 22 2c 2c 63 |p_CreateMenu",,c| 000034d0 6f 6e 66 69 72 6d 25 2c 6d 6f 75 73 65 78 25 2d |onfirm%,mousex%-| 000034e0 32 30 30 2c 6d 6f 75 73 65 79 25 2b 32 30 30 0d |200,mousey%+200.| 000034f0 12 8e 17 63 6f 6e 66 69 72 6d 5f 61 6e 73 77 65 |...confirm_answe| 00003500 72 25 20 3d 20 32 0d 12 98 05 f5 0d 12 a2 2f 20 |r% = 2......../ | 00003510 c8 99 20 22 57 69 6d 70 5f 50 6f 6c 6c 22 2c 70 |.. "Wimp_Poll",p| 00003520 6f 6c 6c 5f 6d 61 73 6b 25 2c 65 76 65 6e 74 25 |oll_mask%,event%| 00003530 20 b8 20 61 63 74 69 6f 6e 25 0d 12 ac 13 20 f2 | . action%.... .| 00003540 64 65 73 70 61 74 63 68 5f 70 6f 6c 6c 0d 12 b6 |despatch_poll...| 00003550 1a fd 20 63 6f 6e 66 69 72 6d 5f 61 6e 73 77 65 |.. confirm_answe| 00003560 72 25 20 3c 3e 20 32 0d 12 c0 14 f2 63 6c 6f 73 |r% <> 2.....clos| 00003570 65 28 63 6f 6e 66 69 72 6d 25 29 0d 12 ca 14 3d |e(confirm%)....=| 00003580 63 6f 6e 66 69 72 6d 5f 61 6e 73 77 65 72 25 0d |confirm_answer%.| 00003590 12 d4 05 3a 0d 12 de 10 dd f2 65 6e 64 63 6f 6e |...:......endcon| 000035a0 66 69 72 6d 0d 12 e8 2d e7 20 63 6f 6e 66 69 72 |firm...-. confir| 000035b0 6d 5f 61 6e 73 77 65 72 25 20 3d 20 32 20 8c 20 |m_answer% = 2 . | 000035c0 63 6f 6e 66 69 72 6d 5f 61 6e 73 77 65 72 25 3d |confirm_answer%=| 000035d0 a3 0d 12 f2 2e f4 20 46 4e 63 6f 6e 66 69 72 6d |...... FNconfirm| 000035e0 20 63 6c 6f 73 65 73 20 74 68 65 20 77 69 6e 64 | closes the wind| 000035f0 6f 77 20 69 66 20 6e 65 63 65 73 73 61 72 79 0d |ow if necessary.| 00003600 12 fc 05 e1 0d 13 06 05 3a 0d 13 10 0f dd 20 a4 |........:..... .| 00003610 72 74 6f 7a 28 73 25 29 0d 13 1a 08 ea 20 6e 24 |rtoz(s%)..... n$| 00003620 0d 13 24 1a c8 95 3f 73 25 3a 6e 24 2b 3d bd 3f |..$...?s%:n$+=.?| 00003630 73 25 3a 73 25 2b 3d 31 3a ce 0d 13 2e 07 3d 6e |s%:s%+=1:.....=n| 00003640 24 0d 13 38 05 3a 0d 13 42 0b dd 20 f2 63 6f 70 |$..8.:..B.. .cop| 00003650 79 0d 13 4c 08 ea 20 4c 25 0d 13 56 07 ea 20 85 |y..L.. L%..V.. .| 00003660 0d 13 60 2c ee 20 85 20 ea 20 f7 20 85 3a f2 65 |..`,. . . . .:.e| 00003670 72 72 6f 72 28 9f 2c 20 f6 24 29 3a f2 73 74 6f |rror(., .$):.sto| 00003680 70 5f 70 72 69 6e 74 69 6e 67 3a e1 0d 13 6a 0d |p_printing:...j.| 00003690 e7 20 73 65 6e 74 25 20 8c 0d 13 74 15 20 e7 20 |. sent% ...t. . | 000036a0 96 28 2d 34 29 3e 3d 70 62 75 66 25 20 8c 0d 13 |.(-4)>=pbuf% ...| 000036b0 7e 15 20 20 f2 50 72 69 6e 74 65 72 5f 46 6f 6f |~. .Printer_Foo| 000036c0 74 65 72 0d 13 88 1b 20 20 d9 23 69 6e 5f 66 69 |ter.... .#in_fi| 000036d0 6c 65 25 3a 69 6e 5f 66 69 6c 65 25 3d 30 0d 13 |le%:in_file%=0..| 000036e0 92 2c 20 20 f2 45 73 63 4f 6e 3a d9 23 6f 75 74 |., .EscOn:.#out| 000036f0 5f 66 69 6c 65 25 3a 6f 75 74 5f 66 69 6c 65 25 |_file%:out_file%| 00003700 3d 30 3a f2 45 73 63 4f 66 66 0d 13 9c 14 20 20 |=0:.EscOff.... | 00003710 f2 73 74 6f 70 5f 70 72 69 6e 74 69 6e 67 0d 13 |.stop_printing..| 00003720 a6 06 20 cd 0d 13 b0 05 cc 0d 13 ba 2a 20 e7 20 |.. .........* . | 00003730 6c 6f 63 61 74 69 6f 6e 5f 6e 65 77 25 3d 31 20 |location_new%=1 | 00003740 84 20 6c 6f 63 61 74 69 6f 6e 5f 6e 65 77 25 3d |. location_new%=| 00003750 32 20 8c 0d 13 c4 0e 20 20 4c 25 3d 96 28 2d 34 |2 ..... L%=.(-4| 00003760 29 0d 13 ce 1b 20 20 e7 20 4c 25 3e 62 75 66 73 |).... . L%>bufs| 00003770 7a 25 20 4c 25 3d 62 75 66 73 7a 25 0d 13 d8 06 |z% L%=bufsz%....| 00003780 20 cc 0d 13 e2 0c 20 20 4c 25 3d 31 32 38 0d 13 | ..... L%=128..| 00003790 ec 06 20 cd 0d 13 f6 1c 20 73 65 6e 74 25 3d a4 |.. ..... sent%=.| 000037a0 50 72 69 6e 74 65 72 5f 53 65 6e 64 28 4c 25 29 |Printer_Send(L%)| 000037b0 0d 14 00 05 cd 0d 14 0a 05 e1 0d 14 14 05 3a 0d |..............:.| 000037c0 14 1e 13 dd f2 73 74 6f 70 5f 70 72 69 6e 74 69 |.....stop_printi| 000037d0 6e 67 0d 14 28 17 f2 73 65 74 5f 70 72 69 6e 74 |ng..(..set_print| 000037e0 5f 73 74 61 74 65 28 a3 29 0d 14 32 1d f2 63 68 |_state(.)..2..ch| 000037f0 61 6e 67 65 5f 69 63 6f 6e 3a f2 75 70 64 61 74 |ange_icon:.updat| 00003800 65 5f 69 63 6f 6e 0d 14 3c 31 e7 20 69 6e 5f 66 |e_icon..<1. in_f| 00003810 69 6c 65 25 20 c8 99 22 58 4f 53 5f 46 69 6e 64 |ile% .."XOS_Find| 00003820 22 2c 30 2c 69 6e 5f 66 69 6c 65 25 3a 69 6e 5f |",0,in_file%:in_| 00003830 66 69 6c 65 25 3d 30 0d 14 46 43 e7 20 6f 75 74 |file%=0..FC. out| 00003840 5f 66 69 6c 65 25 20 f2 45 73 63 4f 6e 3a c8 99 |_file% .EscOn:..| 00003850 22 58 4f 53 5f 46 69 6e 64 22 2c 30 2c 6f 75 74 |"XOS_Find",0,out| 00003860 5f 66 69 6c 65 25 3a 6f 75 74 5f 66 69 6c 65 25 |_file%:out_file%| 00003870 3d 30 3a f2 45 73 63 4f 66 66 0d 14 50 3a e7 20 |=0:.EscOff..P:. | 00003880 66 69 6c 65 6e 61 6d 24 20 3d 20 22 3c 50 72 69 |filenam$ = "<Pri| 00003890 6e 74 65 72 24 53 63 72 61 70 3e 22 20 8c 20 ff |nter$Scrap>" . .| 000038a0 28 22 72 65 6d 6f 76 65 20 22 2b 66 69 6c 65 6e |("remove "+filen| 000038b0 61 6d 24 29 0d 14 5a 39 e7 20 66 69 6c 65 6e 61 |am$)..Z9. filena| 000038c0 6d 24 20 3d 20 22 3c 50 72 69 6e 74 65 72 24 54 |m$ = "<Printer$T| 000038d0 65 6d 70 3e 22 20 8c 20 ff 28 22 72 65 6d 6f 76 |emp>" . .("remov| 000038e0 65 20 22 2b 66 69 6c 65 6e 61 6d 24 29 0d 14 64 |e "+filenam$)..d| 000038f0 2e f4 20 64 65 6c 65 74 65 20 74 68 65 20 73 63 |.. delete the sc| 00003900 72 61 70 20 66 69 6c 65 3a 20 6e 6f 77 20 66 69 |rap file: now fi| 00003910 6e 69 73 68 65 64 20 77 69 74 68 0d 14 6e 10 f2 |nished with..n..| 00003920 75 70 64 61 74 65 5f 69 63 6f 6e 0d 14 78 05 e1 |update_icon..x..| 00003930 0d 14 82 05 3a 0d 14 8c 40 dd 20 f2 6d 6f 75 73 |....:...@. .mous| 00003940 65 28 6d 6f 75 73 65 78 25 2c 6d 6f 75 73 65 79 |e(mousex%,mousey| 00003950 25 2c 62 75 74 74 6f 6e 73 25 2c 68 61 6e 64 6c |%,buttons%,handl| 00003960 65 25 2c 69 63 6f 6e 25 2c 6f 6c 64 62 75 74 74 |e%,icon%,oldbutt| 00003970 6f 6e 73 25 29 0d 14 96 11 c8 8e 20 62 75 74 74 |ons%)...... butt| 00003980 6f 6e 73 25 20 ca 0d 14 a0 1b 20 c9 20 34 3a 20 |ons% ..... . 4: | 00003990 f4 20 6c 65 66 74 20 68 61 6e 64 20 63 6c 69 63 |. left hand clic| 000039a0 6b 0d 14 aa 12 20 20 c8 8e 20 68 61 6e 64 6c 65 |k.... .. handle| 000039b0 25 20 ca 0d 14 b4 0c 20 20 20 c9 20 2d 32 3a 0d |% ..... . -2:.| 000039c0 14 be 15 20 20 20 20 f2 66 72 6f 6e 74 28 6d 61 |... .front(ma| 000039d0 69 6e 25 29 0d 14 c8 12 20 20 20 c9 20 63 6f 6e |in%).... . con| 000039e0 66 69 72 6d 25 3a 0d 14 d2 25 20 20 20 20 e7 20 |firm%:...% . | 000039f0 69 63 6f 6e 25 3d 31 20 8c 20 63 6f 6e 66 69 72 |icon%=1 . confir| 00003a00 6d 5f 61 6e 73 77 65 72 25 3d b9 0d 14 dc 25 20 |m_answer%=....% | 00003a10 20 20 20 e7 20 69 63 6f 6e 25 3d 32 20 8c 20 63 | . icon%=2 . c| 00003a20 6f 6e 66 69 72 6d 5f 61 6e 73 77 65 72 25 3d a3 |onfirm_answer%=.| 00003a30 0d 14 e6 07 20 20 cb 0d 14 f0 17 20 c9 20 32 3a |.... ..... . 2:| 00003a40 20 f4 20 6d 65 6e 75 20 62 75 74 74 6f 6e 0d 14 | . menu button..| 00003a50 fa 12 20 20 c8 8e 20 68 61 6e 64 6c 65 25 20 ca |.. .. handle% .| 00003a60 0d 15 04 1e 20 20 20 c9 20 2d 32 3a 20 f2 6d 65 |.... . -2: .me| 00003a70 6e 75 28 70 72 69 6e 74 6d 65 6e 75 25 29 0d 15 |nu(printmenu%)..| 00003a80 0e 06 20 cb 0d 15 18 05 cb 0d 15 22 05 e1 0d 15 |.. ........"....| 00003a90 2c 05 3a 0d 15 36 25 dd 20 f2 64 65 63 6f 64 65 |,.:..6%. .decode| 00003aa0 6d 65 6e 75 28 6d 65 6e 75 68 61 6e 64 6c 65 25 |menu(menuhandle%| 00003ab0 2c 6d 65 6e 75 73 25 29 0d 15 40 14 c8 8e 20 6d |,menus%)..@... m| 00003ac0 65 6e 75 68 61 6e 64 6c 65 25 20 ca 0d 15 4a 11 |enuhandle% ...J.| 00003ad0 20 c9 20 70 72 69 6e 74 6d 65 6e 75 25 0d 15 54 | . printmenu%..T| 00003ae0 23 20 20 e7 20 70 72 69 6e 74 5f 6f 6e 25 20 80 |# . print_on% .| 00003af0 20 28 21 6d 65 6e 75 73 25 3c 35 29 20 8c 20 e1 | (!menus%<5) . .| 00003b00 0d 15 5e 12 20 20 c8 8e 20 21 6d 65 6e 75 73 25 |..^. .. !menus%| 00003b10 20 ca 0d 15 68 0a 20 20 20 c9 20 31 0d 15 72 21 | ...h. . 1..r!| 00003b20 20 20 20 20 f2 74 69 63 6b 69 74 28 70 72 69 6e | .tickit(prin| 00003b30 74 6d 65 6e 75 25 2c 20 31 2c 20 34 29 0d 15 7c |tmenu%, 1, 4)..|| 00003b40 19 20 20 20 20 6c 6f 63 61 74 69 6f 6e 5f 6e 65 |. location_ne| 00003b50 77 25 20 3d 20 31 0d 15 86 0f 20 20 20 20 2a 46 |w% = 1.... *F| 00003b60 58 20 35 2c 31 0d 15 90 0a 20 20 20 c9 20 32 0d |X 5,1.... . 2.| 00003b70 15 9a 17 20 20 20 20 f2 50 72 69 6e 74 65 72 5f |... .Printer_| 00003b80 49 67 6e 6f 72 65 0d 15 a4 27 20 20 20 20 f2 64 |Ignore...' .d| 00003b90 65 63 6f 64 65 6d 65 6e 75 28 73 65 72 69 61 6c |ecodemenu(serial| 00003ba0 6d 25 2c 20 6d 65 6e 75 73 25 2b 34 29 0d 15 ae |m%, menus%+4)...| 00003bb0 21 20 20 20 20 f2 74 69 63 6b 69 74 28 70 72 69 |! .tickit(pri| 00003bc0 6e 74 6d 65 6e 75 25 2c 20 32 2c 20 34 29 0d 15 |ntmenu%, 2, 4)..| 00003bd0 b8 19 20 20 20 20 6c 6f 63 61 74 69 6f 6e 5f 6e |.. location_n| 00003be0 65 77 25 20 3d 20 32 0d 15 c2 24 20 20 20 20 c8 |ew% = 2...$ .| 00003bf0 99 20 22 4f 53 5f 42 79 74 65 22 2c 20 38 2c 20 |. "OS_Byte", 8, | 00003c00 62 61 75 64 5f 6e 65 77 25 2b 31 0d 15 cc 24 20 |baud_new%+1...$ | 00003c10 20 20 20 c8 99 20 22 4f 53 5f 42 79 74 65 22 2c | .. "OS_Byte",| 00003c20 20 37 2c 20 62 61 75 64 5f 6e 65 77 25 2b 31 0d | 7, baud_new%+1.| 00003c30 15 d6 24 20 20 20 20 c8 99 20 22 4f 53 5f 53 65 |..$ .. "OS_Se| 00003c40 72 69 61 6c 4f 70 22 2c 31 2c 64 61 74 61 5f 6e |rialOp",1,data_n| 00003c50 65 77 25 0d 15 e0 27 20 20 20 20 c8 99 20 22 4f |ew%...' .. "O| 00003c60 53 5f 53 65 72 69 61 6c 4f 70 22 2c 30 2c 58 4f |S_SerialOp",0,XO| 00003c70 4e 5f 6e 65 77 25 2c ac 20 31 0d 15 ea 22 20 20 |N_new%,. 1..." | 00003c80 20 20 f2 50 72 69 6e 74 65 72 5f 58 6f 6e 58 6f | .Printer_XonXo| 00003c90 66 66 28 58 4f 4e 5f 6e 65 77 25 29 0d 15 f4 0f |ff(XON_new%)....| 00003ca0 20 20 20 20 2a 46 58 20 35 2c 32 0d 15 fe 0a 20 | *FX 5,2.... | 00003cb0 20 20 c9 20 33 0d 16 08 29 20 20 20 20 f2 64 65 | . 3...) .de| 00003cc0 63 6f 64 65 6d 65 6e 75 28 6e 65 74 70 72 69 6e |codemenu(netprin| 00003cd0 74 6d 25 2c 20 6d 65 6e 75 73 25 2b 34 29 0d 16 |tm%, menus%+4)..| 00003ce0 12 21 20 20 20 20 f2 74 69 63 6b 69 74 28 70 72 |.! .tickit(pr| 00003cf0 69 6e 74 6d 65 6e 75 25 2c 20 33 2c 20 34 29 0d |intmenu%, 3, 4).| 00003d00 16 1c 19 20 20 20 20 6c 6f 63 61 74 69 6f 6e 5f |... location_| 00003d10 6e 65 77 25 20 3d 20 34 0d 16 26 27 20 20 20 20 |new% = 4..&' | 00003d20 c8 99 20 22 58 4f 53 5f 43 4c 49 22 2c 22 50 53 |.. "XOS_CLI","PS| 00003d30 20 22 2b 24 73 65 72 76 65 72 5f 6e 65 77 25 0d | "+$server_new%.| 00003d40 16 30 0f 20 20 20 20 2a 46 58 20 35 2c 34 0d 16 |.0. *FX 5,4..| 00003d50 3a 0a 20 20 20 c9 20 34 0d 16 44 17 20 20 20 20 |:. . 4..D. | 00003d60 6c 6f 63 61 74 69 6f 6e 5f 6e 65 77 25 3d 35 0d |location_new%=5.| 00003d70 16 4e 21 20 20 20 20 f2 74 69 63 6b 69 74 28 70 |.N! .tickit(p| 00003d80 72 69 6e 74 6d 65 6e 75 25 2c 20 34 2c 20 34 29 |rintmenu%, 4, 4)| 00003d90 0d 16 58 42 20 20 20 20 e7 20 a9 24 66 69 6c 65 |..XB . .$file| 00003da0 5f 6e 61 6d 65 25 3d 30 20 8c 20 24 66 69 6c 65 |_name%=0 . $file| 00003db0 5f 6e 61 6d 65 25 3d 22 3c 50 44 72 69 76 65 72 |_name%="<PDriver| 00003dc0 24 44 69 72 3e 2e 5e 2e 50 72 69 6e 74 44 61 74 |$Dir>.^.PrintDat| 00003dd0 61 22 0d 16 62 35 20 20 20 20 c8 99 20 22 58 4f |a"..b5 .. "XO| 00003de0 53 5f 43 4c 49 22 2c 22 53 65 74 20 50 72 69 6e |S_CLI","Set Prin| 00003df0 74 65 72 54 79 70 65 24 35 20 22 2b 24 66 69 6c |terType$5 "+$fil| 00003e00 65 5f 6e 61 6d 65 25 0d 16 6c 0e 20 20 20 20 f2 |e_name%..l. .| 00003e10 73 74 61 6d 70 0d 16 76 0f 20 20 20 20 2a 46 58 |stamp..v. *FX| 00003e20 20 35 2c 35 0d 16 80 0a 20 20 20 c9 20 35 0d 16 | 5,5.... . 5..| 00003e30 8a 13 20 20 20 20 f2 53 61 76 65 43 6f 6e 66 69 |.. .SaveConfi| 00003e40 67 0d 16 94 0a 20 20 20 c9 20 36 0d 16 9e 15 20 |g.... . 6.... | 00003e50 20 20 20 e7 20 70 72 69 6e 74 5f 6f 6e 25 20 8c | . print_on% .| 00003e60 0d 16 a8 11 20 20 20 20 20 2a 46 58 20 32 31 2c |.... *FX 21,| 00003e70 33 0d 16 b2 17 20 20 20 20 20 f2 73 74 6f 70 5f |3.... .stop_| 00003e80 70 72 69 6e 74 69 6e 67 0d 16 bc 09 20 20 20 20 |printing.... | 00003e90 cd 0d 16 c6 0a 20 20 20 c9 20 37 0d 16 d0 15 20 |..... . 7.... | 00003ea0 20 20 20 e7 20 70 72 69 6e 74 5f 6f 6e 25 20 8c | . print_on% .| 00003eb0 0d 16 da 11 20 20 20 20 20 2a 46 58 20 32 31 2c |.... *FX 21,| 00003ec0 33 0d 16 e4 17 20 20 20 20 20 f2 73 74 6f 70 5f |3.... .stop_| 00003ed0 70 72 69 6e 74 69 6e 67 0d 16 ee 09 20 20 20 20 |printing.... | 00003ee0 cd 0d 16 f8 12 20 20 20 20 f2 74 65 72 6d 69 6e |..... .termin| 00003ef0 61 74 65 0d 17 02 07 20 20 cb 0d 17 0c 12 20 20 |ate.... ..... | 00003f00 f2 63 68 61 6e 67 65 5f 69 63 6f 6e 0d 17 16 0f |.change_icon....| 00003f10 20 c9 20 73 65 72 69 61 6c 6d 25 0d 17 20 12 20 | . serialm%.. . | 00003f20 20 c8 8e 20 21 6d 65 6e 75 73 25 20 ca 0d 17 2a | .. !menus% ...*| 00003f30 0a 20 20 20 c9 20 30 0d 17 34 25 20 20 20 20 f2 |. . 0..4% .| 00003f40 64 65 63 6f 64 65 6d 65 6e 75 28 62 61 75 64 6d |decodemenu(baudm| 00003f50 25 2c 20 6d 65 6e 75 73 25 2b 34 29 0d 17 3e 0a |%, menus%+4)..>.| 00003f60 20 20 20 c9 20 31 0d 17 48 25 20 20 20 20 f2 64 | . 1..H% .d| 00003f70 65 63 6f 64 65 6d 65 6e 75 28 64 61 74 61 6d 25 |ecodemenu(datam%| 00003f80 2c 20 6d 65 6e 75 73 25 2b 34 29 0d 17 52 0a 20 |, menus%+4)..R. | 00003f90 20 20 c9 20 32 0d 17 5c 1f 20 20 20 20 58 4f 4e | . 2..\. XON| 00003fa0 5f 6e 65 77 25 20 3d 20 58 4f 4e 5f 6e 65 77 25 |_new% = XON_new%| 00003fb0 20 82 20 31 0d 17 66 26 20 20 20 20 f2 73 65 74 | . 1..f& .set| 00003fc0 5f 74 69 63 6b 28 73 65 72 69 61 6c 6d 25 2c 32 |_tick(serialm%,2| 00003fd0 2c 58 4f 4e 5f 6e 65 77 25 29 0d 17 70 07 20 20 |,XON_new%)..p. | 00003fe0 cb 0d 17 7a 0d 20 c9 20 62 61 75 64 6d 25 0d 17 |...z. . baudm%..| 00003ff0 84 17 20 20 e7 20 21 6d 65 6e 75 73 25 20 3c 3e |.. . !menus% <>| 00004000 20 2d 31 20 8c 0d 17 8e 23 20 20 20 f2 74 69 63 | -1 ....# .tic| 00004010 6b 69 74 28 62 61 75 64 6d 25 2c 20 21 6d 65 6e |kit(baudm%, !men| 00004020 75 73 25 2c 20 31 34 29 0d 17 98 18 20 20 20 62 |us%, 14).... b| 00004030 61 75 64 5f 6e 65 77 25 3d 21 6d 65 6e 75 73 25 |aud_new%=!menus%| 00004040 0d 17 a2 07 20 20 cd 0d 17 ac 0d 20 c9 20 64 61 |.... ..... . da| 00004050 74 61 6d 25 0d 17 b6 12 20 20 c8 8e 20 21 6d 65 |tam%.... .. !me| 00004060 6e 75 73 25 20 ca 0d 17 c0 0a 20 20 20 c9 20 30 |nus% ..... . 0| 00004070 0d 17 ca 25 20 20 20 20 f2 64 65 63 6f 64 65 6d |...% .decodem| 00004080 65 6e 75 28 62 69 74 73 6d 25 2c 20 6d 65 6e 75 |enu(bitsm%, menu| 00004090 73 25 2b 34 29 0d 17 d4 0a 20 20 20 c9 20 31 0d |s%+4).... . 1.| 000040a0 17 de 27 20 20 20 20 f2 64 65 63 6f 64 65 6d 65 |..' .decodeme| 000040b0 6e 75 28 70 61 72 69 74 79 6d 25 2c 20 6d 65 6e |nu(paritym%, men| 000040c0 75 73 25 2b 34 29 0d 17 e8 0a 20 20 20 c9 20 32 |us%+4).... . 2| 000040d0 0d 17 f2 25 20 20 20 20 f2 64 65 63 6f 64 65 6d |...% .decodem| 000040e0 65 6e 75 28 73 74 6f 70 6d 25 2c 20 6d 65 6e 75 |enu(stopm%, menu| 000040f0 73 25 2b 34 29 0d 17 fc 07 20 20 cb 0d 18 06 0d |s%+4).... .....| 00004100 20 c9 20 62 69 74 73 6d 25 0d 18 10 17 20 20 e7 | . bitsm%.... .| 00004110 20 21 6d 65 6e 75 73 25 20 3c 3e 20 2d 31 20 8c | !menus% <> -1 .| 00004120 0d 18 1a 30 20 20 20 64 61 74 61 5f 6e 65 77 25 |...0 data_new%| 00004130 3d 28 64 61 74 61 5f 6e 65 77 25 20 80 20 25 31 |=(data_new% . %1| 00004140 31 31 31 30 30 29 2b 33 2d 21 6d 65 6e 75 73 25 |11100)+3-!menus%| 00004150 0d 18 24 22 20 20 20 f2 74 69 63 6b 69 74 28 62 |..$" .tickit(b| 00004160 69 74 73 6d 25 2c 20 21 6d 65 6e 75 73 25 2c 20 |itsm%, !menus%, | 00004170 33 29 0d 18 2e 07 20 20 cd 0d 18 38 0f 20 c9 20 |3).... ...8. . | 00004180 70 61 72 69 74 79 6d 25 0d 18 42 17 20 20 e7 20 |paritym%..B. . | 00004190 21 6d 65 6e 75 73 25 20 3c 3e 20 2d 31 20 8c 0d |!menus% <> -1 ..| 000041a0 18 4c 12 20 20 20 e7 20 21 6d 65 6e 75 73 25 20 |.L. . !menus% | 000041b0 8c 0d 18 56 39 20 20 20 20 64 61 74 61 5f 6e 65 |...V9 data_ne| 000041c0 77 25 20 3d 20 28 64 61 74 61 5f 6e 65 77 25 20 |w% = (data_new% | 000041d0 80 20 25 31 31 31 29 2b 38 2b 28 28 21 6d 65 6e |. %111)+8+((!men| 000041e0 75 73 25 2d 31 29 3c 3c 34 29 0d 18 60 08 20 20 |us%-1)<<4)..`. | 000041f0 20 cc 0d 18 6a 27 20 20 20 20 64 61 74 61 5f 6e | ...j' data_n| 00004200 65 77 25 20 3d 20 64 61 74 61 5f 6e 65 77 25 20 |ew% = data_new% | 00004210 80 20 ac 28 31 3c 3c 33 29 0d 18 74 08 20 20 20 |. .(1<<3)..t. | 00004220 cd 0d 18 7e 24 20 20 20 f2 74 69 63 6b 69 74 28 |...~$ .tickit(| 00004230 70 61 72 69 74 79 6d 25 2c 20 21 6d 65 6e 75 73 |paritym%, !menus| 00004240 25 2c 20 34 29 0d 18 88 07 20 20 cd 0d 18 92 0d |%, 4).... .....| 00004250 20 c9 20 73 74 6f 70 6d 25 0d 18 9c 17 20 20 e7 | . stopm%.... .| 00004260 20 21 6d 65 6e 75 73 25 20 3c 3e 20 2d 31 20 8c | !menus% <> -1 .| 00004270 0d 18 a6 35 20 20 20 64 61 74 61 5f 6e 65 77 25 |...5 data_new%| 00004280 3d 28 64 61 74 61 5f 6e 65 77 25 20 80 20 25 31 |=(data_new% . %1| 00004290 31 31 30 31 31 29 20 82 20 28 21 6d 65 6e 75 73 |11011) . (!menus| 000042a0 25 3c 3c 32 29 0d 18 b0 22 20 20 20 f2 74 69 63 |%<<2)..." .tic| 000042b0 6b 69 74 28 73 74 6f 70 6d 25 2c 20 21 6d 65 6e |kit(stopm%, !men| 000042c0 75 73 25 2c 20 31 29 0d 18 ba 07 20 20 cd 0d 18 |us%, 1).... ...| 000042d0 c4 05 cb 0d 18 ce 10 f2 75 70 64 61 74 65 5f 69 |........update_i| 000042e0 63 6f 6e 0d 18 d8 05 e1 0d 18 e2 05 3a 0d 18 ec |con.........:...| 000042f0 12 dd 20 f2 75 70 64 61 74 65 5f 69 63 6f 6e 0d |.. .update_icon.| 00004300 18 f6 12 62 6c 6f 63 6b 25 21 30 20 20 3d 20 2d |...block%!0 = -| 00004310 32 0d 19 00 18 62 6c 6f 63 6b 25 21 34 20 20 3d |2....block%!4 =| 00004320 20 69 63 70 72 69 6e 74 25 0d 19 0a 11 62 6c 6f | icprint%....blo| 00004330 63 6b 25 21 38 20 20 3d 20 30 0d 19 14 11 62 6c |ck%!8 = 0....bl| 00004340 6f 63 6b 25 21 31 32 20 3d 20 30 0d 19 1e 22 c8 |ock%!12 = 0...".| 00004350 99 20 22 57 69 6d 70 5f 53 65 74 49 63 6f 6e 53 |. "Wimp_SetIconS| 00004360 74 61 74 65 22 2c 2c 62 6c 6f 63 6b 25 0d 19 28 |tate",,block%..(| 00004370 05 e1 0d 19 32 05 3a 0d 19 3c 24 dd 20 f2 74 69 |....2.:..<$. .ti| 00004380 63 6b 69 74 28 6d 65 6e 75 25 2c 20 69 74 65 6d |ckit(menu%, item| 00004390 25 2c 20 6e 69 74 65 6d 73 25 29 0d 19 46 08 ea |%, nitems%)..F..| 000043a0 20 49 25 0d 19 50 14 e3 20 49 25 3d 30 20 b8 20 | I%..P.. I%=0 . | 000043b0 6e 69 74 65 6d 73 25 0d 19 5a 1d 20 20 f2 73 65 |nitems%..Z. .se| 000043c0 74 5f 74 69 63 6b 28 6d 65 6e 75 25 2c 20 49 25 |t_tick(menu%, I%| 000043d0 2c 20 30 29 0d 19 64 05 ed 0d 19 6e 1e f2 73 65 |, 0)..d....n..se| 000043e0 74 5f 74 69 63 6b 28 6d 65 6e 75 25 2c 20 69 74 |t_tick(menu%, it| 000043f0 65 6d 25 2c 20 31 29 0d 19 78 05 e1 0d 19 82 05 |em%, 1)..x......| 00004400 3a 0d 19 8c 10 dd 20 f2 66 72 6f 6e 74 28 68 25 |:..... .front(h%| 00004410 29 0d 19 96 0a 21 71 25 3d 68 25 0d 19 a0 2b c8 |)....!q%=h%...+.| 00004420 99 20 22 57 69 6d 70 5f 47 65 74 57 69 6e 64 6f |. "Wimp_GetWindo| 00004430 77 53 74 61 74 65 22 2c 2c 71 25 20 3a 20 71 25 |wState",,q% : q%| 00004440 21 32 38 3d 2d 31 0d 19 aa 1c c8 99 20 22 57 69 |!28=-1...... "Wi| 00004450 6d 70 5f 4f 70 65 6e 57 69 6e 64 6f 77 22 2c 2c |mp_OpenWindow",,| 00004460 71 25 0d 19 b4 05 e1 0d 19 be 05 3a 0d 19 c8 37 |q%.........:...7| 00004470 dd 20 f2 6f 70 65 6e 28 68 61 6e 64 6c 65 25 2c |. .open(handle%,| 00004480 78 30 25 2c 79 30 25 2c 78 31 25 2c 79 31 25 2c |x0%,y0%,x1%,y1%,| 00004490 73 63 78 25 2c 73 63 79 25 2c 62 68 61 6e 64 6c |scx%,scy%,bhandl| 000044a0 65 25 29 0d 19 d2 0f 21 71 25 3d 68 61 6e 64 6c |e%)....!q%=handl| 000044b0 65 25 0d 19 dc 29 71 25 21 34 3d 78 30 25 3a 71 |e%...)q%!4=x0%:q| 000044c0 25 21 38 3d 79 30 25 3a 71 25 21 31 32 3d 78 31 |%!8=y0%:q%!12=x1| 000044d0 25 3a 71 25 21 31 36 3d 79 31 25 0d 19 e6 19 71 |%:q%!16=y1%....q| 000044e0 25 21 32 30 3d 73 63 78 25 3a 71 25 21 32 34 3d |%!20=scx%:q%!24=| 000044f0 73 63 79 25 0d 19 f0 12 71 25 21 32 38 3d 62 68 |scy%....q%!28=bh| 00004500 61 6e 64 6c 65 25 0d 19 fa 1c c8 99 20 22 57 69 |andle%...... "Wi| 00004510 6d 70 5f 4f 70 65 6e 57 69 6e 64 6f 77 22 2c 2c |mp_OpenWindow",,| 00004520 71 25 0d 1a 04 05 e1 0d 1a 0e 05 3a 0d 1a 18 15 |q%.........:....| 00004530 dd 20 f2 63 6c 6f 73 65 28 68 61 6e 64 6c 65 25 |. .close(handle%| 00004540 29 0d 1a 22 29 21 71 25 3d 68 61 6e 64 6c 65 25 |)..")!q%=handle%| 00004550 3a c8 99 20 22 57 69 6d 70 5f 43 6c 6f 73 65 57 |:.. "Wimp_CloseW| 00004560 69 6e 64 6f 77 22 2c 2c 71 25 0d 1a 2c 05 e1 0d |indow",,q%..,...| 00004570 1a 36 05 3a 0d 1a 40 11 dd 20 a4 77 69 6e 64 6f |.6.:..@.. .windo| 00004580 77 28 61 24 29 0d 1a 4a 08 ea 20 63 25 0d 1a 54 |w(a$)..J.. c%..T| 00004590 48 c8 99 20 22 57 69 6d 70 5f 4c 6f 61 64 54 65 |H.. "Wimp_LoadTe| 000045a0 6d 70 6c 61 74 65 22 2c 2c 71 25 2c 63 75 72 62 |mplate",,q%,curb| 000045b0 75 66 25 2c 65 6e 64 62 75 66 25 2c 2d 31 2c 61 |uf%,endbuf%,-1,a| 000045c0 24 2c 30 20 b8 20 2c 2c 63 75 72 62 75 66 25 2c |$,0 . ,,curbuf%,| 000045d0 2c 2c 2c 63 25 0d 1a 5e 31 e7 20 63 25 3d 30 20 |,,,c%..^1. c%=0 | 000045e0 8c 20 f2 6d 6f 61 6e 28 22 54 65 6d 70 6c 61 74 |. .moan("Templat| 000045f0 65 20 27 22 2b 61 24 2b 22 27 20 6e 6f 74 20 66 |e '"+a$+"' not f| 00004600 6f 75 6e 64 22 29 0d 1a 68 23 c8 99 20 22 57 69 |ound")..h#.. "Wi| 00004610 6d 70 5f 43 72 65 61 74 65 57 69 6e 64 6f 77 22 |mp_CreateWindow"| 00004620 2c 2c 71 25 20 b8 20 63 25 0d 1a 72 07 3d 63 25 |,,q% . c%..r.=c%| 00004630 0d 1a 7c 05 3a 0d 1a 86 16 dd 20 a4 69 63 6f 6e |..|.:..... .icon| 00004640 61 64 64 72 28 68 25 2c 69 25 29 0d 1a 90 2d 21 |addr(h%,i%)...-!| 00004650 71 25 3d 68 25 3a 71 25 21 34 3d 69 25 3a c8 99 |q%=h%:q%!4=i%:..| 00004660 20 22 57 69 6d 70 5f 47 65 74 49 63 6f 6e 53 74 | "Wimp_GetIconSt| 00004670 61 74 65 22 2c 2c 71 25 0d 1a 9a 38 e7 20 28 71 |ate",,q%...8. (q| 00004680 25 21 32 34 20 80 20 26 31 30 30 29 3d 30 20 8c |%!24 . &100)=0 .| 00004690 20 f2 6d 6f 61 6e 28 22 49 63 6f 6e 20 69 73 20 | .moan("Icon is | 000046a0 6e 6f 74 20 69 6e 64 69 72 65 63 74 65 64 22 29 |not indirected")| 000046b0 0d 1a a4 0a 3d 71 25 21 32 38 0d 1a ae 05 3a 0d |....=q%!28....:.| 000046c0 1a b8 0f dd 20 f2 6d 65 6e 75 28 6d 25 29 0d 1a |.... .menu(m%)..| 000046d0 c2 08 ea 20 59 25 0d 1a cc 10 59 25 20 3d 20 6d |... Y%....Y% = m| 000046e0 6f 75 73 65 79 25 0d 1a d6 15 e7 20 59 25 3c 34 |ousey%..... Y%<4| 000046f0 39 36 20 8c 20 59 25 3d 34 39 36 0d 1a e0 12 6d |96 . Y%=496....m| 00004700 65 6e 75 68 61 6e 64 6c 65 25 3d 6d 25 0d 1a ea |enuhandle%=m%...| 00004710 33 c8 99 20 22 57 69 6d 70 5f 43 72 65 61 74 65 |3.. "Wimp_Create| 00004720 4d 65 6e 75 22 2c 2c 6d 65 6e 75 68 61 6e 64 6c |Menu",,menuhandl| 00004730 65 25 2c 6d 6f 75 73 65 78 25 2d 36 36 2c 59 25 |e%,mousex%-66,Y%| 00004740 0d 1a f4 05 e1 0d 1a fe 05 3a 0d 1b 08 0d dd 20 |.........:..... | 00004750 f2 72 65 6d 65 6e 75 0d 1b 12 08 ea 20 59 25 0d |.remenu..... Y%.| 00004760 1b 1c 10 59 25 20 3d 20 6d 6f 75 73 65 79 25 0d |...Y% = mousey%.| 00004770 1b 26 19 e7 20 59 25 20 3c 20 33 30 30 20 8c 20 |.&.. Y% < 300 . | 00004780 59 25 20 3d 20 33 31 36 0d 1b 30 45 c8 99 20 22 |Y% = 316..0E.. "| 00004790 57 69 6d 70 5f 43 72 65 61 74 65 4d 65 6e 75 22 |Wimp_CreateMenu"| 000047a0 2c 2c 6d 65 6e 75 68 61 6e 64 6c 65 25 2c 6d 6f |,,menuhandle%,mo| 000047b0 75 73 65 78 25 2d 36 36 2c 59 25 20 3a f4 20 64 |usex%-66,Y% :. d| 000047c0 65 66 61 75 6c 74 20 63 6f 6f 72 64 73 0d 1b 3a |efault coords..:| 000047d0 05 e1 0d 1b 44 05 3a 0d 1b 4e 14 dd 20 a4 63 72 |....D.:..N.. .cr| 000047e0 6d 65 6e 75 28 6d 65 6e 75 24 29 0d 1b 58 37 e7 |menu(menu$)..X7.| 000047f0 20 6d 65 6e 75 66 72 65 65 25 2b 32 38 20 3e 20 | menufree%+28 > | 00004800 6d 65 6e 75 65 6e 64 25 20 8c 20 f2 6d 6f 61 6e |menuend% . .moan| 00004810 28 22 4d 65 6e 75 20 61 72 65 61 20 66 75 6c 6c |("Menu area full| 00004820 22 29 0d 1b 62 0b ea 20 6d 25 2c 69 25 0d 1b 6c |")..b.. m%,i%..l| 00004830 16 6d 65 6e 75 70 74 72 25 3d 6d 65 6e 75 66 72 |.menuptr%=menufr| 00004840 65 65 25 0d 1b 76 08 69 25 3d 30 0d 1b 80 3f e7 |ee%..v.i%=0...?.| 00004850 20 c0 6d 65 6e 75 24 2c 31 29 3d 22 23 22 20 8c | .menu$,1)="#" .| 00004860 20 69 25 3d 31 3a 6d 65 6e 75 74 69 74 6c 65 24 | i%=1:menutitle$| 00004870 3d a4 70 61 72 28 22 3b 22 29 20 8b 20 6d 65 6e |=.par(";") . men| 00004880 75 74 69 74 6c 65 24 3d 22 22 0d 1b 8a 18 24 6d |utitle$=""....$m| 00004890 65 6e 75 70 74 72 25 3d 6d 65 6e 75 74 69 74 6c |enuptr%=menutitl| 000048a0 65 24 0d 1b 94 4a 6d 65 6e 75 70 74 72 25 3f 31 |e$...Jmenuptr%?1| 000048b0 32 3d 60 74 66 63 6f 6c 3a 6d 65 6e 75 70 74 72 |2=`tfcol:menuptr| 000048c0 25 3f 31 33 3d 32 3a 6d 65 6e 75 70 74 72 25 3f |%?13=2:menuptr%?| 000048d0 31 34 3d 60 77 66 63 6f 6c 3a 6d 65 6e 75 70 74 |14=`wfcol:menupt| 000048e0 72 25 3f 31 35 3d 60 77 62 63 6f 6c 0d 1b 9e 33 |r%?15=`wbcol...3| 000048f0 6d 65 6e 75 70 74 72 25 21 31 36 3d 31 39 36 2d |menuptr%!16=196-| 00004900 32 34 3a 6d 65 6e 75 70 74 72 25 21 32 30 3d 34 |24:menuptr%!20=4| 00004910 34 3a 6d 65 6e 75 70 74 72 25 21 32 34 3d 30 0d |4:menuptr%!24=0.| 00004920 1b a8 24 6d 65 6e 75 70 74 72 25 2b 3d 32 38 3a |..$menuptr%+=28:| 00004930 6d 61 78 78 25 3d a9 6d 65 6e 75 74 69 74 6c 65 |maxx%=.menutitle| 00004940 24 2d 33 0d 1b b2 31 f5 20 69 74 65 6d 24 3d a4 |$-3...1. item$=.| 00004950 70 61 72 28 22 3b 22 29 3a f2 6d 65 6e 75 69 74 |par(";"):.menuit| 00004960 65 6d 28 69 74 65 6d 24 29 3a fd 20 69 74 65 6d |em(item$):. item| 00004970 24 3d 22 22 0d 1b bc 24 6d 25 3d 6d 65 6e 75 66 |$=""...$m%=menuf| 00004980 72 65 65 25 3a 6d 25 21 31 36 3d 28 6d 61 78 78 |ree%:m%!16=(maxx| 00004990 25 2a 38 2b 36 29 2a 32 0d 1b c6 16 6d 65 6e 75 |%*8+6)*2....menu| 000049a0 66 72 65 65 25 3d 6d 65 6e 75 70 74 72 25 0d 1b |free%=menuptr%..| 000049b0 d0 07 3d 6d 25 0d 1b da 05 3a 0d 1b e4 16 dd 20 |..=m%....:..... | 000049c0 f2 6d 65 6e 75 69 74 65 6d 28 74 65 78 74 24 29 |.menuitem(text$)| 000049d0 0d 1b ee 32 e7 20 74 65 78 74 24 3d 22 22 20 8c |...2. text$="" .| 000049e0 20 6d 65 6e 75 70 74 72 25 21 2d 32 34 3d 28 6d | menuptr%!-24=(m| 000049f0 65 6e 75 70 74 72 25 21 2d 32 34 29 84 26 38 30 |enuptr%!-24).&80| 00004a00 3a e1 0d 1b f8 36 e7 20 6d 65 6e 75 70 74 72 25 |:....6. menuptr%| 00004a10 2b 32 34 20 3e 20 6d 65 6e 75 65 6e 64 25 20 8c |+24 > menuend% .| 00004a20 20 f2 6d 6f 61 6e 28 22 4d 65 6e 75 20 61 72 65 | .moan("Menu are| 00004a30 61 20 66 75 6c 6c 22 29 0d 1c 02 0f ea 69 25 2c |a full").....i%,| 00004a40 66 6c 67 25 2c 56 25 0d 1c 0c 0c 66 6c 67 25 3d |flg%,V%....flg%=| 00004a50 26 30 30 0d 1c 16 12 69 25 3d a7 74 65 78 74 24 |&00....i%=.text$| 00004a60 2c 22 3e 22 29 0d 1c 20 36 e7 20 c2 74 65 78 74 |,">").. 6. .text| 00004a70 24 2c 31 29 3d 22 23 22 20 8c 20 74 65 78 74 24 |$,1)="#" . text$| 00004a80 3d c0 74 65 78 74 24 2c a9 74 65 78 74 24 2d 31 |=.text$,.text$-1| 00004a90 29 3a 66 6c 67 25 2b 3d 26 30 32 0d 1c 2a 3d e7 |):flg%+=&02..*=.| 00004aa0 69 25 3e 30 8c 73 75 62 70 74 72 25 3d a0 c1 74 |i%>0.subptr%=..t| 00004ab0 65 78 74 24 2c 69 25 2b 31 29 3a 74 65 78 74 24 |ext$,i%+1):text$| 00004ac0 3d c0 74 65 78 74 24 2c 69 25 2d 31 29 8b 73 75 |=.text$,i%-1).su| 00004ad0 62 70 74 72 25 3d 2d 31 0d 1c 34 13 6d 65 6e 75 |bptr%=-1..4.menu| 00004ae0 70 74 72 25 21 30 3d 66 6c 67 25 0d 1c 3e 16 6d |ptr%!0=flg%..>.m| 00004af0 65 6e 75 70 74 72 25 21 34 3d 73 75 62 70 74 72 |enuptr%!4=subptr| 00004b00 25 0d 1c 48 18 6d 65 6e 75 70 74 72 25 21 38 3d |%..H.menuptr%!8=| 00004b10 26 30 37 30 30 30 30 32 31 0d 1c 52 13 e7 c0 74 |&07000021..R...t| 00004b20 65 78 74 24 2c 31 29 3d 22 24 22 8c 0d 1c 5c 13 |ext$,1)="$"...\.| 00004b30 20 21 6d 65 6e 75 70 74 72 25 2b 3d 26 30 34 0d | !menuptr%+=&04.| 00004b40 1c 66 15 20 6d 65 6e 75 70 74 72 25 21 38 2b 3d |.f. menuptr%!8+=| 00004b50 26 31 30 38 0d 1c 70 13 20 69 25 3d a7 74 65 78 |&108..p. i%=.tex| 00004b60 74 24 2c 22 28 22 29 0d 1c 7a 34 20 e7 69 25 3e |t$,"(")..z4 .i%>| 00004b70 30 8c 4c 25 3d bb c1 74 65 78 74 24 2c 69 25 2b |0.L%=..text$,i%+| 00004b80 31 29 3a 74 65 78 74 24 3d c0 74 65 78 74 24 2c |1):text$=.text$,| 00004b90 69 25 2d 31 29 8b 4c 25 3d 31 32 0d 1c 84 0c 20 |i%-1).L%=12.... | 00004ba0 56 25 20 3d 20 2d 31 0d 1c 8e 1b 20 6d 65 6e 75 |V% = -1.... menu| 00004bb0 70 74 72 25 21 31 32 3d a0 c1 74 65 78 74 24 2c |ptr%!12=..text$,| 00004bc0 32 29 0d 1c 98 13 20 6d 65 6e 75 70 74 72 25 21 |2).... menuptr%!| 00004bd0 31 36 3d 2d 31 0d 1c a2 13 20 6d 65 6e 75 70 74 |16=-1.... menupt| 00004be0 72 25 21 32 30 3d 4c 25 0d 1c ac 13 20 74 65 78 |r%!20=L%.... tex| 00004bf0 74 24 3d c4 4c 25 2c 22 20 22 29 0d 1c b6 1a 20 |t$=.L%," ").... | 00004c00 e7 20 6d 61 78 78 25 3c 32 30 20 8c 20 6d 61 78 |. maxx%<20 . max| 00004c10 78 25 3d 32 30 0d 1c c0 05 cc 0d 1c ca 11 20 e7 |x%=20......... .| 00004c20 a9 74 65 78 74 24 3c 3d 31 32 8c 0d 1c d4 1a 20 |.text$<=12..... | 00004c30 20 24 28 6d 65 6e 75 70 74 72 25 2b 31 32 29 3d | $(menuptr%+12)=| 00004c40 74 65 78 74 24 0d 1c de 28 20 cc 20 49 25 3d a4 |text$...( . I%=.| 00004c50 77 6f 72 6b 73 70 61 63 65 28 a9 74 65 78 74 24 |workspace(.text$| 00004c60 2b 31 29 3a 24 49 25 3d 74 65 78 74 24 0d 1c e8 |+1):$I%=text$...| 00004c70 38 20 20 6d 65 6e 75 70 74 72 25 21 31 32 3d 49 |8 menuptr%!12=I| 00004c80 25 3a 6d 65 6e 75 70 74 72 25 21 31 36 3d 2d 31 |%:menuptr%!16=-1| 00004c90 3a 6d 65 6e 75 70 74 72 25 21 32 30 3d a9 74 65 |:menuptr%!20=.te| 00004ca0 78 74 24 2b 31 0d 1c f2 22 20 20 6d 65 6e 75 70 |xt$+1..." menup| 00004cb0 74 72 25 21 38 3d 6d 65 6e 75 70 74 72 25 21 38 |tr%!8=menuptr%!8| 00004cc0 20 84 20 26 31 30 30 0d 1c fc 06 20 cd 0d 1d 06 | . &100.... ....| 00004cd0 1f e7 a9 74 65 78 74 24 3e 6d 61 78 78 25 20 8c |...text$>maxx% .| 00004ce0 6d 61 78 78 25 3d a9 74 65 78 74 24 0d 1d 10 05 |maxx%=.text$....| 00004cf0 cd 0d 1d 1a 10 6d 65 6e 75 70 74 72 25 2b 3d 32 |.....menuptr%+=2| 00004d00 34 0d 1d 24 05 e1 0d 1d 2e 05 3a 0d 1d 38 14 dd |4..$......:..8..| 00004d10 20 a4 77 6f 72 6b 73 70 61 63 65 28 4c 25 29 0d | .workspace(L%).| 00004d20 1d 42 0b de 20 4c 25 20 4c 25 0d 1d 4c 08 3d 20 |.B.. L% L%..L.= | 00004d30 4c 25 0d 1d 56 05 3a 0d 1d 60 10 dd 20 a4 70 61 |L%..V.:..`.. .pa| 00004d40 72 28 73 65 70 24 29 0d 1d 6a 25 69 31 25 3d 69 |r(sep$)..j%i1%=i| 00004d50 25 2b 31 3a 69 25 3d a7 6d 65 6e 75 24 2b 73 65 |%+1:i%=.menu$+se| 00004d60 70 24 2c 73 65 70 24 2c 69 31 25 29 0d 1d 74 17 |p$,sep$,i1%)..t.| 00004d70 3d c1 6d 65 6e 75 24 2c 69 31 25 2c 69 25 2d 69 |=.menu$,i1%,i%-i| 00004d80 31 25 29 0d 1d 7e 05 3a 0d 1d 88 20 dd 20 f2 73 |1%)..~.:... . .s| 00004d90 68 61 64 65 28 6d 65 6e 75 68 61 6e 64 6c 65 25 |hade(menuhandle%| 00004da0 2c 20 69 74 65 6d 25 29 0d 1d 92 45 6d 65 6e 75 |, item%)...Emenu| 00004db0 68 61 6e 64 6c 65 25 21 28 32 38 2b 38 2b 32 34 |handle%!(28+8+24| 00004dc0 2a 69 74 65 6d 25 29 3d 6d 65 6e 75 68 61 6e 64 |*item%)=menuhand| 00004dd0 6c 65 25 21 28 32 38 2b 38 2b 32 34 2a 69 74 65 |le%!(28+8+24*ite| 00004de0 6d 25 29 82 26 34 30 30 30 30 30 3a e1 0d 1d 9c |m%).&400000:....| 00004df0 05 3a 0d 1d a6 5b dd 20 a4 73 68 61 64 65 5f 73 |.:...[. .shade_s| 00004e00 74 61 74 75 73 28 6d 65 6e 75 68 61 6e 64 6c 65 |tatus(menuhandle| 00004e10 25 2c 69 74 65 6d 25 29 20 3d 20 2d 28 28 6d 65 |%,item%) = -((me| 00004e20 6e 75 68 61 6e 64 6c 65 25 21 28 32 38 2b 38 2b |nuhandle%!(28+8+| 00004e30 32 34 2a 69 74 65 6d 25 29 20 80 20 26 34 30 30 |24*item%) . &400| 00004e40 30 30 30 29 3d 26 34 30 30 30 30 30 29 0d 1d b0 |000)=&400000)...| 00004e50 05 3a 0d 1d ba 2c dd 20 f2 73 65 74 5f 73 68 61 |.:...,. .set_sha| 00004e60 64 65 28 6d 65 6e 75 68 61 6e 64 6c 65 25 2c 20 |de(menuhandle%, | 00004e70 69 74 65 6d 25 2c 20 76 61 6c 75 65 25 29 0d 1d |item%, value%)..| 00004e80 c4 09 ea 20 73 74 25 0d 1d ce 2b 73 74 25 20 3d |... st%...+st% =| 00004e90 20 a4 73 68 61 64 65 5f 73 74 61 74 75 73 28 6d | .shade_status(m| 00004ea0 65 6e 75 68 61 6e 64 6c 65 25 2c 20 69 74 65 6d |enuhandle%, item| 00004eb0 25 29 0d 1d d8 30 e7 20 76 61 6c 75 65 25 20 3c |%)...0. value% <| 00004ec0 3e 20 73 74 25 20 8c 20 f2 73 68 61 64 65 28 6d |> st% . .shade(m| 00004ed0 65 6e 75 68 61 6e 64 6c 65 25 2c 20 69 74 65 6d |enuhandle%, item| 00004ee0 25 29 0d 1d e2 05 e1 0d 1d ec 05 3a 0d 1d f6 1e |%).........:....| 00004ef0 dd 20 f2 74 69 63 6b 28 6d 65 6e 75 68 61 6e 64 |. .tick(menuhand| 00004f00 6c 65 25 2c 69 74 65 6d 25 29 0d 1e 00 3b 6d 65 |le%,item%)...;me| 00004f10 6e 75 68 61 6e 64 6c 65 25 21 28 32 38 2b 32 34 |nuhandle%!(28+24| 00004f20 2a 69 74 65 6d 25 29 3d 6d 65 6e 75 68 61 6e 64 |*item%)=menuhand| 00004f30 6c 65 25 21 28 32 38 2b 32 34 2a 69 74 65 6d 25 |le%!(28+24*item%| 00004f40 29 82 26 30 31 0d 1e 0a 05 e1 0d 1e 14 05 3a 0d |).&01.........:.| 00004f50 1e 1e 44 dd 20 a4 74 69 63 6b 5f 73 74 61 74 75 |..D. .tick_statu| 00004f60 73 28 6d 65 6e 75 68 61 6e 64 6c 65 25 2c 20 69 |s(menuhandle%, i| 00004f70 74 65 6d 25 29 20 3d 20 6d 65 6e 75 68 61 6e 64 |tem%) = menuhand| 00004f80 6c 65 25 21 28 32 38 2b 32 34 2a 69 74 65 6d 25 |le%!(28+24*item%| 00004f90 29 80 31 0d 1e 28 05 3a 0d 1e 32 2b dd 20 f2 73 |).1..(.:..2+. .s| 00004fa0 65 74 5f 74 69 63 6b 28 6d 65 6e 75 68 61 6e 64 |et_tick(menuhand| 00004fb0 6c 65 25 2c 20 69 74 65 6d 25 2c 20 76 61 6c 75 |le%, item%, valu| 00004fc0 65 25 29 0d 1e 3c 4a e7 20 a4 74 69 63 6b 5f 73 |e%)..<J. .tick_s| 00004fd0 74 61 74 75 73 28 6d 65 6e 75 68 61 6e 64 6c 65 |tatus(menuhandle| 00004fe0 25 2c 20 69 74 65 6d 25 29 3c 3e 76 61 6c 75 65 |%, item%)<>value| 00004ff0 25 20 8c 20 f2 74 69 63 6b 28 6d 65 6e 75 68 61 |% . .tick(menuha| 00005000 6e 64 6c 65 25 2c 20 69 74 65 6d 25 29 0d 1e 46 |ndle%, item%)..F| 00005010 05 e1 0d 1e 50 05 3a 0d 1e 5a 1d dd 20 f2 73 65 |....P.:..Z.. .se| 00005020 74 5f 70 72 69 6e 74 5f 73 74 61 74 65 28 66 6c |t_print_state(fl| 00005030 61 67 25 29 0d 1e 64 23 f2 73 65 74 5f 73 68 61 |ag%)..d#.set_sha| 00005040 64 65 28 70 72 69 6e 74 6d 65 6e 75 25 2c 31 2c |de(printmenu%,1,| 00005050 2d 66 6c 61 67 25 29 0d 1e 6e 23 f2 73 65 74 5f |-flag%)..n#.set_| 00005060 73 68 61 64 65 28 70 72 69 6e 74 6d 65 6e 75 25 |shade(printmenu%| 00005070 2c 32 2c 2d 66 6c 61 67 25 29 0d 1e 78 23 f2 73 |,2,-flag%)..x#.s| 00005080 65 74 5f 73 68 61 64 65 28 70 72 69 6e 74 6d 65 |et_shade(printme| 00005090 6e 75 25 2c 33 2c 2d 66 6c 61 67 25 29 0d 1e 82 |nu%,3,-flag%)...| 000050a0 23 f2 73 65 74 5f 73 68 61 64 65 28 70 72 69 6e |#.set_shade(prin| 000050b0 74 6d 65 6e 75 25 2c 34 2c 2d 66 6c 61 67 25 29 |tmenu%,4,-flag%)| 000050c0 0d 1e 8c 23 f2 73 65 74 5f 73 68 61 64 65 28 70 |...#.set_shade(p| 000050d0 72 69 6e 74 6d 65 6e 75 25 2c 35 2c 2d 66 6c 61 |rintmenu%,5,-fla| 000050e0 67 25 29 0d 1e 96 26 f2 73 65 74 5f 73 68 61 64 |g%)...&.set_shad| 000050f0 65 28 70 72 69 6e 74 6d 65 6e 75 25 2c 36 2c 28 |e(printmenu%,6,(| 00005100 31 2b 66 6c 61 67 25 29 29 0d 1e a0 23 f2 73 65 |1+flag%))...#.se| 00005110 74 5f 73 68 61 64 65 28 70 72 69 6e 74 6d 65 6e |t_shade(printmen| 00005120 75 25 2c 37 2c 2d 66 6c 61 67 25 29 0d 1e aa 13 |u%,7,-flag%)....| 00005130 70 72 69 6e 74 5f 6f 6e 25 3d 66 6c 61 67 25 0d |print_on%=flag%.| 00005140 1e b4 2c 70 6f 6c 6c 5f 6d 61 73 6b 25 3d 28 70 |..,poll_mask%=(p| 00005150 6f 6c 6c 5f 6d 61 73 6b 25 20 80 20 ac 31 29 20 |oll_mask% . .1) | 00005160 84 20 28 31 2b 66 6c 61 67 25 29 0d 1e be 0d e7 |. (1+flag%).....| 00005170 20 66 6c 61 67 25 20 8c 0d 1e c8 17 20 2a 73 65 | flag% ..... *se| 00005180 74 20 24 50 72 69 6e 74 69 6e 67 20 22 54 22 0d |t $Printing "T".| 00005190 1e d2 05 cc 0d 1e dc 15 20 2a 75 6e 73 65 74 20 |........ *unset | 000051a0 24 50 72 69 6e 74 69 6e 67 0d 1e e6 05 cd 0d 1e |$Printing.......| 000051b0 f0 05 e1 0d 1e fa 05 3a 0d 1f 04 25 dd 20 a4 72 |.......:...%. .r| 000051c0 65 61 64 5f 69 63 6f 6e 5f 64 61 74 61 28 68 61 |ead_icon_data(ha| 000051d0 6e 64 6c 65 25 2c 20 69 63 6f 6e 25 29 0d 1f 0e |ndle%, icon%)...| 000051e0 19 21 69 63 6f 6e 5f 62 75 66 25 20 20 3d 20 68 |.!icon_buf% = h| 000051f0 61 6e 64 6c 65 25 0d 1f 18 17 69 63 6f 6e 5f 62 |andle%....icon_b| 00005200 75 66 25 21 34 20 3d 20 69 63 6f 6e 25 0d 1f 22 |uf%!4 = icon%.."| 00005210 27 c8 99 20 22 57 69 6d 70 5f 47 65 74 49 63 6f |'.. "Wimp_GetIco| 00005220 6e 53 74 61 74 65 22 2c 20 2c 20 69 63 6f 6e 5f |nState", , icon_| 00005230 62 75 66 25 0d 1f 2c 43 e7 20 69 63 6f 6e 5f 62 |buf%..,C. icon_b| 00005240 75 66 25 21 32 38 20 3c 20 63 75 72 62 75 66 25 |uf%!28 < curbuf%| 00005250 20 8c 20 3d 24 28 69 63 6f 6e 5f 62 75 66 25 21 | . =$(icon_buf%!| 00005260 32 38 29 20 8b 20 3d 20 24 28 69 63 6f 6e 5f 62 |28) . = $(icon_b| 00005270 75 66 25 2b 32 38 29 0d 1f 36 05 3a 0d 1f 40 32 |uf%+28)..6.:..@2| 00005280 dd 20 f2 73 65 74 5f 69 63 6f 6e 5f 73 74 61 74 |. .set_icon_stat| 00005290 65 28 68 61 6e 64 6c 65 25 2c 20 69 63 6f 6e 25 |e(handle%, icon%| 000052a0 2c 20 65 6f 72 25 2c 20 6d 61 73 6b 25 29 0d 1f |, eor%, mask%)..| 000052b0 4a 19 21 69 63 6f 6e 5f 62 75 66 25 20 20 3d 20 |J.!icon_buf% = | 000052c0 68 61 6e 64 6c 65 25 0d 1f 54 17 69 63 6f 6e 5f |handle%..T.icon_| 000052d0 62 75 66 25 21 34 20 3d 20 69 63 6f 6e 25 0d 1f |buf%!4 = icon%..| 000052e0 5e 16 69 63 6f 6e 5f 62 75 66 25 21 38 20 3d 20 |^.icon_buf%!8 = | 000052f0 65 6f 72 25 0d 1f 68 18 69 63 6f 6e 5f 62 75 66 |eor%..h.icon_buf| 00005300 25 21 31 32 20 3d 20 6d 61 73 6b 25 0d 1f 72 25 |%!12 = mask%..r%| 00005310 c8 99 20 22 57 69 6d 70 5f 53 65 74 49 63 6f 6e |.. "Wimp_SetIcon| 00005320 53 74 61 74 65 22 2c 2c 69 63 6f 6e 5f 62 75 66 |State",,icon_buf| 00005330 25 0d 1f 7c 05 e1 0d 1f 86 05 3a 0d 1f 90 0e dd |%..|......:.....| 00005340 20 a4 69 63 6f 6e 62 61 72 0d 1f 9a 08 ea 20 49 | .iconbar..... I| 00005350 25 0d 1f a4 13 69 63 6f 6e 5f 62 75 66 25 21 30 |%....icon_buf%!0| 00005360 20 3d 2d 32 0d 1f ae 12 69 63 6f 6e 5f 62 75 66 | =-2....icon_buf| 00005370 25 21 34 20 3d 30 0d 1f b8 14 69 63 6f 6e 5f 62 |%!4 =0....icon_b| 00005380 75 66 25 21 38 20 3d 2d 31 36 0d 1f c2 14 69 63 |uf%!8 =-16....ic| 00005390 6f 6e 5f 62 75 66 25 21 31 32 3d 31 34 34 0d 1f |on_buf%!12=144..| 000053a0 cc 14 69 63 6f 6e 5f 62 75 66 25 21 31 36 3d 20 |..icon_buf%!16= | 000053b0 38 36 0d 1f d6 47 69 63 6f 6e 5f 62 75 66 25 21 |86...Gicon_buf%!| 000053c0 32 30 3d 20 26 31 37 30 30 33 31 32 42 3a 20 20 |20= &1700312B: | 000053d0 f4 20 30 30 30 31 20 30 31 31 31 20 30 30 30 30 |. 0001 0111 0000| 000053e0 20 30 30 30 30 20 30 30 31 31 20 30 30 30 31 20 | 0000 0011 0001 | 000053f0 30 30 31 30 20 31 30 31 31 0d 1f e0 23 24 74 65 |0010 1011...#$te| 00005400 78 74 5f 62 75 66 66 65 72 25 20 20 20 3d 20 70 |xt_buffer% = p| 00005410 72 69 6e 74 65 72 5f 74 79 70 65 24 0d 1f ea 23 |rinter_type$...#| 00005420 24 76 61 6c 69 64 5f 62 75 66 66 65 72 25 20 20 |$valid_buffer% | 00005430 3d 20 22 53 21 22 2b 50 72 69 6e 74 65 72 24 0d |= "S!"+Printer$.| 00005440 1f f4 1e 69 63 6f 6e 5f 62 75 66 25 21 32 34 3d |...icon_buf%!24=| 00005450 20 74 65 78 74 5f 62 75 66 66 65 72 25 0d 1f fe | text_buffer%...| 00005460 20 69 63 6f 6e 5f 62 75 66 25 21 32 38 20 3d 20 | icon_buf%!28 = | 00005470 76 61 6c 69 64 5f 62 75 66 66 65 72 25 0d 20 08 |valid_buffer%. .| 00005480 25 69 63 6f 6e 5f 62 75 66 25 21 33 32 20 3d 20 |%icon_buf%!32 = | 00005490 a9 28 24 74 65 78 74 5f 62 75 66 66 65 72 25 29 |.($text_buffer%)| 000054a0 2b 31 0d 20 12 28 c8 99 20 22 57 69 6d 70 5f 43 |+1. .(.. "Wimp_C| 000054b0 72 65 61 74 65 49 63 6f 6e 22 2c 2c 69 63 6f 6e |reateIcon",,icon| 000054c0 5f 62 75 66 25 20 b8 20 49 25 0d 20 1c 07 3d 49 |_buf% . I%. ..=I| 000054d0 25 0d 20 26 05 3a 0d 20 30 12 dd 20 f2 63 68 61 |%. &.:. 0.. .cha| 000054e0 6e 67 65 5f 69 63 6f 6e 0d 20 3a 0e f2 73 65 74 |nge_icon. :..set| 000054f0 5f 70 74 79 70 65 0d 20 44 21 24 74 65 78 74 5f |_ptype. D!$text_| 00005500 62 75 66 66 65 72 25 20 3d 20 70 72 69 6e 74 65 |buffer% = printe| 00005510 72 5f 74 79 70 65 24 0d 20 4e 05 e1 0d 20 58 05 |r_type$. N... X.| 00005520 3a 0d 20 62 0f dd f2 73 65 74 5f 70 74 79 70 65 |:. b...set_ptype| 00005530 0d 20 6c 11 e7 20 70 72 69 6e 74 5f 6f 6e 25 20 |. l.. print_on% | 00005540 8c 0d 20 76 1f 20 70 72 69 6e 74 65 72 5f 74 79 |.. v. printer_ty| 00005550 70 65 24 20 3d 20 22 50 72 69 6e 74 69 6e 67 22 |pe$ = "Printing"| 00005560 0d 20 80 05 cc 0d 20 8a 1f c8 99 22 4f 53 5f 42 |. .... ...."OS_B| 00005570 79 74 65 22 2c 35 2c 6c 6f 63 61 74 69 6f 6e 5f |yte",5,location_| 00005580 6e 65 77 25 0d 20 94 16 c8 8e 20 6c 6f 63 61 74 |new%. .... locat| 00005590 69 6f 6e 5f 6e 65 77 25 20 ca 0d 20 9e 24 20 c9 |ion_new% .. .$ .| 000055a0 20 31 3a 20 70 72 69 6e 74 65 72 5f 74 79 70 65 | 1: printer_type| 000055b0 24 20 3d 20 22 50 61 72 61 6c 6c 65 6c 22 0d 20 |$ = "Parallel". | 000055c0 a8 22 20 c9 20 32 3a 20 70 72 69 6e 74 65 72 5f |." . 2: printer_| 000055d0 74 79 70 65 24 20 3d 20 22 53 65 72 69 61 6c 22 |type$ = "Serial"| 000055e0 0d 20 b2 26 20 c9 20 34 3a 20 70 72 69 6e 74 65 |. .& . 4: printe| 000055f0 72 5f 74 79 70 65 24 20 3d 20 24 73 65 72 76 65 |r_type$ = $serve| 00005600 72 5f 6e 65 77 25 0d 20 bc 09 20 c9 20 35 3a 0d |r_new%. .. . 5:.| 00005610 20 c6 2d 20 20 e7 20 a4 6c 6f 77 65 72 63 61 73 | .- . .lowercas| 00005620 65 28 c0 24 66 69 6c 65 5f 6e 61 6d 65 25 2c 35 |e(.$file_name%,5| 00005630 29 29 3d 22 6e 75 6c 6c 3a 22 20 8c 0d 20 d0 21 |))="null:" .. .!| 00005640 20 20 20 70 72 69 6e 74 65 72 5f 74 79 70 65 24 | printer_type$| 00005650 20 3d 20 22 54 6f 20 6e 75 6c 6c 3a 22 0d 20 da | = "To null:". .| 00005660 07 20 20 cc 0d 20 e4 20 20 20 20 70 72 69 6e 74 |. .. . print| 00005670 65 72 5f 74 79 70 65 24 20 3d 20 22 54 6f 20 66 |er_type$ = "To f| 00005680 69 6c 65 22 0d 20 ee 07 20 20 cd 0d 20 f8 30 20 |ile". .. .. .0 | 00005690 20 ff 28 22 73 65 74 20 50 72 69 6e 74 65 72 54 | .("set PrinterT| 000056a0 79 70 65 24 35 20 22 22 22 2b 24 66 69 6c 65 5f |ype$5 """+$file_| 000056b0 6e 61 6d 65 25 2b 22 22 22 22 29 0d 21 02 05 cb |name%+"""").!...| 000056c0 0d 21 0c 05 cd 0d 21 16 05 e1 0d 21 20 05 3a 0d |.!....!....! .:.| 000056d0 21 2a 11 dd 20 f2 67 65 74 70 6f 69 6e 74 65 72 |!*.. .getpointer| 000056e0 0d 21 34 20 c8 99 20 22 57 69 6d 70 5f 47 65 74 |.!4 .. "Wimp_Get| 000056f0 50 6f 69 6e 74 65 72 49 6e 66 6f 22 2c 2c 71 25 |PointerInfo",,q%| 00005700 0d 21 3e 2a 6d 6f 75 73 65 78 25 3d 21 71 25 3a |.!>*mousex%=!q%:| 00005710 6d 6f 75 73 65 79 25 3d 71 25 21 34 3a 62 75 74 |mousey%=q%!4:but| 00005720 74 6f 6e 73 25 3d 71 25 21 38 0d 21 48 1d 68 61 |tons%=q%!8.!H.ha| 00005730 6e 64 6c 65 25 3d 71 25 21 31 32 3a 69 63 6f 6e |ndle%=q%!12:icon| 00005740 25 3d 71 25 21 31 36 0d 21 52 05 e1 0d 21 5c 05 |%=q%!16.!R...!\.| 00005750 3a 0d 21 66 14 dd 20 f2 6d 6f 61 6e 28 72 65 70 |:.!f.. .moan(rep| 00005760 6f 72 74 24 29 0d 21 70 14 85 20 26 32 30 30 30 |ort$).!p.. &2000| 00005770 30 2c 72 65 70 6f 72 74 24 0d 21 7a 05 3a 0d 21 |0,report$.!z.:.!| 00005780 84 1b dd 20 f2 65 72 72 6f 72 28 65 72 72 25 2c |... .error(err%,| 00005790 20 72 65 70 6f 72 74 24 29 0d 21 8e 0b ea 20 73 | report$).!... s| 000057a0 74 6f 70 25 0d 21 98 0b f2 45 73 63 4f 66 66 0d |top%.!...EscOff.| 000057b0 21 a2 27 73 74 6f 70 25 3d 28 72 65 70 6f 72 74 |!.'stop%=(report| 000057c0 24 3c 3e 22 41 6c 72 65 61 64 79 20 70 72 69 6e |$<>"Already prin| 000057d0 74 69 6e 67 22 29 0d 21 ac 56 e7 20 28 65 72 72 |ting").!.V. (err| 000057e0 25 3c 26 31 30 31 30 30 20 84 20 65 72 72 25 3e |%<&10100 . err%>| 000057f0 26 32 30 30 30 30 29 20 80 20 65 72 72 25 3c 3e |&20000) . err%<>| 00005800 31 37 20 8c 20 72 65 70 6f 72 74 24 3d 72 65 70 |17 . report$=rep| 00005810 6f 72 74 24 2b 22 20 69 6e 74 65 72 6e 61 6c 20 |ort$+" internal | 00005820 65 72 72 6f 72 20 22 2b c3 28 9e 29 0d 21 b6 16 |error "+.(.).!..| 00005830 21 65 72 72 6f 72 5f 62 6c 6b 25 20 3d 20 65 72 |!error_blk% = er| 00005840 72 25 0d 21 c0 1b 24 28 65 72 72 6f 72 5f 62 6c |r%.!..$(error_bl| 00005850 6b 25 2b 34 29 3d 72 65 70 6f 72 74 24 0d 21 ca |k%+4)=report$.!.| 00005860 21 f2 7a 65 72 6f 5f 74 65 72 6d 69 6e 61 74 65 |!.zero_terminate| 00005870 28 65 72 72 6f 72 5f 62 6c 6b 25 2b 34 29 0d 21 |(error_blk%+4).!| 00005880 d4 22 e7 20 73 74 6f 70 25 20 e7 20 70 72 69 6e |.". stop% . prin| 00005890 74 5f 6f 6e 25 20 8c 20 2a 46 58 20 32 31 2c 33 |t_on% . *FX 21,3| 000058a0 0d 21 de 32 c8 99 20 22 57 69 6d 70 5f 52 65 70 |.!.2.. "Wimp_Rep| 000058b0 6f 72 74 45 72 72 6f 72 22 2c 20 65 72 72 6f 72 |ortError", error| 000058c0 5f 62 6c 6b 25 2c 20 31 2c 20 50 72 69 6e 74 65 |_blk%, 1, Printe| 000058d0 72 24 0d 21 e8 0f f2 65 6e 64 63 6f 6e 66 69 72 |r$.!...endconfir| 000058e0 6d 0d 21 f2 0d e7 20 73 74 6f 70 25 20 8c 0d 21 |m.!... stop% ..!| 000058f0 fc 1f 20 e7 20 70 72 69 6e 74 5f 6f 6e 25 20 f2 |.. . print_on% .| 00005900 73 74 6f 70 5f 70 72 69 6e 74 69 6e 67 0d 22 06 |stop_printing.".| 00005910 32 20 e7 20 69 6e 5f 66 69 6c 65 25 20 c8 99 22 |2 . in_file% .."| 00005920 58 4f 53 5f 46 69 6e 64 22 2c 30 2c 69 6e 5f 66 |XOS_Find",0,in_f| 00005930 69 6c 65 25 3a 69 6e 5f 66 69 6c 65 25 3d 30 0d |ile%:in_file%=0.| 00005940 22 10 44 20 e7 20 6f 75 74 5f 66 69 6c 65 25 20 |".D . out_file% | 00005950 f2 45 73 63 4f 6e 3a c8 99 22 58 4f 53 5f 46 69 |.EscOn:.."XOS_Fi| 00005960 6e 64 22 2c 30 2c 6f 75 74 5f 66 69 6c 65 25 3a |nd",0,out_file%:| 00005970 6f 75 74 5f 66 69 6c 65 25 3d 30 3a f2 45 73 63 |out_file%=0:.Esc| 00005980 4f 66 66 0d 22 1a 05 cd 0d 22 24 05 e1 0d 22 2e |Off."...."$...".| 00005990 05 3a 0d 22 38 18 dd f2 7a 65 72 6f 5f 74 65 72 |.:."8...zero_ter| 000059a0 6d 69 6e 61 74 65 28 53 25 29 0d 22 42 0f 53 25 |minate(S%)."B.S%| 000059b0 3f a9 24 53 25 20 3d 20 30 0d 22 4c 05 e1 0d 22 |?.$S% = 0."L..."| 000059c0 56 05 3a 0d 22 60 13 dd a4 6c 6f 77 65 72 63 61 |V.:."`...lowerca| 000059d0 73 65 28 53 24 29 0d 22 6a 0c ea 20 52 24 2c 20 |se(S$)."j.. R$, | 000059e0 43 25 0d 22 74 09 52 24 3d 22 22 0d 22 7e 0c c8 |C%."t.R$=""."~..| 000059f0 95 20 a9 53 24 3e 30 0d 22 88 11 20 43 25 20 3d |. .S$>0.".. C% =| 00005a00 20 97 c0 53 24 2c 31 29 0d 22 92 14 20 53 24 20 | ..S$,1).".. S$ | 00005a10 3d 20 c2 53 24 2c a9 53 24 2d 31 29 0d 22 9c 32 |= .S$,.S$-1).".2| 00005a20 20 e7 20 43 25 3e 3d 97 22 41 22 20 80 20 43 25 | . C%>=."A" . C%| 00005a30 3c 3d 97 22 5a 22 20 8c 20 43 25 20 3d 20 43 25 |<=."Z" . C% = C%| 00005a40 20 2d 20 97 22 41 22 20 2b 20 97 22 61 22 0d 22 | - ."A" + ."a"."| 00005a50 a6 0e 20 52 24 20 2b 3d 20 bd 43 25 0d 22 b0 05 |.. R$ += .C%."..| 00005a60 ce 0d 22 ba 07 3d 52 24 0d 22 c4 05 3a 0d 22 ce |.."..=R$."..:.".| 00005a70 0c dd 20 f2 73 74 61 6d 70 0d 22 d8 0b ea 20 6c |.. .stamp."... l| 00005a80 6f 61 64 25 0d 22 e2 07 ea 20 85 0d 22 ec 0b ee |oad%."... .."...| 00005a90 20 85 20 ea 20 e1 0d 22 f6 27 c8 99 20 22 4f 53 | . . ..".'.. "OS| 00005aa0 5f 46 69 6c 65 22 2c 35 2c 66 69 6c 65 5f 6e 61 |_File",5,file_na| 00005ab0 6d 65 25 20 b8 20 2c 2c 6c 6f 61 64 25 0d 23 00 |me% . ,,load%.#.| 00005ac0 53 e7 20 28 6c 6f 61 64 25 3e 3e 3e 38 29 20 3c |S. (load%>>>8) <| 00005ad0 3e 20 26 46 46 46 30 30 30 20 2b 20 4f 75 74 70 |> &FFF000 + Outp| 00005ae0 75 74 54 79 70 65 25 20 8c 20 c8 99 20 22 4f 53 |utType% . .. "OS| 00005af0 5f 46 69 6c 65 22 2c 31 31 2c 66 69 6c 65 5f 6e |_File",11,file_n| 00005b00 61 6d 65 25 2c 4f 75 74 70 75 74 54 79 70 65 25 |ame%,OutputType%| 00005b10 0d 23 0a 05 e1 0d 23 14 05 3a 0d 23 1e 0c dd 20 |.#....#..:.#... | 00005b20 f2 45 73 63 4f 6e 0d 23 28 0b 2a 46 58 20 32 32 |.EscOn.#(.*FX 22| 00005b30 39 0d 23 32 05 e1 0d 23 3c 05 3a 0d 23 46 0d dd |9.#2...#<.:.#F..| 00005b40 20 f2 45 73 63 4f 66 66 0d 23 50 0d 2a 46 58 20 | .EscOff.#P.*FX | 00005b50 32 32 39 2c 31 0d 23 5a 05 e1 0d ff |229,1.#Z....| 00005b5c