Home » Personal collection » Acorn ADFS disks » Greaseweazled » adfs_RiscOs_Apps_1.adf » !PrinterDM/Library

!PrinterDM/Library

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 » Greaseweazled » adfs_RiscOs_Apps_1.adf
Filename: !PrinterDM/Library
Read OK:
File size: 27F0 bytes
Load address: FFFFFB41
Exec address: C759D3A1
Duplicates

There is 1 duplicate copy of this file in the archive:

File contents
   10REM >Library V.1.12 for dot matrix printer driver
   20REM Purpose: printer-specific parts of the printer application
   30REM Authors: A.Thompson, NReeves, DSeal, NRaine
   40REM *******************************************************
   50REM initialise the dot matrix printer driver specific parts
   60REM *******************************************************
   70:
   80DEFPROCPrinter_initialise
   90LOCAL P%
  100IF VersionNumber$ <> "1.12" THEN PROCmoan("Incompatible !RunImage and Library")
  110PrinterClass$="PrinterDM"
  120FullPrinterClass$="dot matrix"
  130OutputType%=&FF4
  140PrData_expected% = 1
  150REM define printer class dependent fields in printer data area
  160    dump_depth_field% = FNp_field(1)
  170     interlace_field% = FNp_field(1)
  180          mono_field% = FNp_field(2)
  190 line_prologue_field% = FNp_field(20)
  200 line_epilogue_field% = FNp_field(20)
  210line_interlace_field% = FNp_field(20)
  220  job_epilogue_field% = FNp_field(20)
  230  job_prologue_field% = FNp_field(20)
  240   printer_data_size% = FNp_field(0)
  250REM define class dependent icons in main window
  260main_line%=2
  270main_mono%=3
  280printer_data_list% = 0:P%=0
  290PROCPrinter_read_config_file
  300REM now convert to circular list
  310P%!list_pointer_field%=printer_data_list%
  320ENDPROC
  330:
  340REM *****************
  350REM set initial state
  360REM *****************
  370DEFPROCPrinter_set_initial_state
  380LOCAL D%
  390REM set default state
  400D%=printer_data_list%
  410WHILE D%!list_pointer_field%<>printer_data_list% AND D%!printer_number_field%<>printer_config%
  420 D%=D%!list_pointer_field%
  430ENDWHILE
  440IF D%!printer_number_field%=printer_config% THEN printer_data_list%=D%
  450PROCPrinter_set_description
  460PROCPrinter_set_module_data
  470ENDPROC
  480:
  490DEFPROCPrinter_CloseFiles
  500ENDPROC
  510:
  520REM ********
  530REM shutdown
  540REM ********
  550DEFPROCPrinter_terminate
  560ENDPROC
  570:
  580REM **************************************
  590REM the printer-specific template loading
  600REM **************************************
  610DEFPROCPrinter_load_templates
  620PROCset_icon_state(main%, main_line%, line_new% << 21, 1<<21)
  630PROCset_icon_state(main%, main_mono%, mono_new% << 21, 1<<21)
  640ENDPROC
  650:
  660REM ***********************************
  670REM the printer-specific event handler
  680REM ***********************************
  690DEFFNPrinter_process_event(action%, E%)
  700LOCAL res%
  710res%=FALSE
  720CASE action% OF
  730 WHEN 17,18:
  740  CASE E%!16 OF
  750   WHEN &502:
  760    IF E%!32 = main% AND E%!36 >= -1 THEN PROChelpreply("Printer setup.|MClick SELECT or ADJUST to alter the settings.",E%!8,E%!4):res% = TRUE
  770  ENDCASE
  780 WHEN 6
  790  IF E%!12=main% THEN
  800   CASE TRUE OF
  810    WHEN (E%!8 AND %101)<>0:
  820     CASE E%!16 OF
  830      WHEN main_description%:
  840       IF E%!8 AND 1 THEN
  850        res% = printer_data_list%
  860        REPEAT printer_data_list% = printer_data_list%!list_pointer_field%
  870        UNTIL printer_data_list%!list_pointer_field% = res%
  880       ELSE
  890        printer_data_list% = printer_data_list%!list_pointer_field%
  900       ENDIF
  910       PROCPrinter_set_description
  920       PROCPrinter_set_module_data
  930       printer_new% = printer_data_list%!printer_number_field%
  940       res%=TRUE
  950      WHEN main_line%
  960       !q%=main%
  970       q%!4=main_line%
  980       SYS "Wimp_GetIconState",,q%
  990       line_new% = (q%!24 >> 21) AND 1
 1000      WHEN main_mono%
 1010       !q%=main%
 1020       q%!4=main_mono%
 1030       SYS "Wimp_GetIconState",,q%
 1040       mono_new% = (q%!24 >> 21) AND 1
 1050       PROCPrinter_set_module_data
 1060     ENDCASE
 1070   ENDCASE
 1080  ENDIF
 1090ENDCASE
 1100=res%
 1110:
 1120REM *****************************************************************
 1130REM read the configuration file with all the individual printer info
 1140REM *****************************************************************
 1150DEFPROCPrinter_read_config_file
 1160LOCAL H%,ptr%
 1170DIM defaults% printer_data_size%
 1180FOR H%=0 TO printer_data_size%-4 STEP 4:defaults%!H%=0:NEXT
 1190printer_data% = defaults%
 1200H%=OPENIN"<PDriver$dir>.PrData"
 1210IF H%=0 ERROR 100,"Can't read printer data file"
 1220REPEAT
 1230 ptr% = PTR#H%
 1240 PROCPrinter_process_line(H%)
 1250UNTIL EOF#H%
 1260CLOSE#H%
 1270ENDPROC
 1280:
 1290REM *********************************************
 1300REM process one line from the configuration file
 1310REM *********************************************
 1320DEFPROCPrinter_process_line(H%)
 1330LOCAL I%,J%,tag$
 1340$buf%=GET$#H%
 1350I%=0
 1360WHILE FNtagchar(buf%?I%): I% += 1:ENDWHILE
 1370IF buf%?I% = ASC":" THEN
 1380 REM got a tag
 1390 tag$=FNlowercase(LEFT$($buf%,I%))
 1400 I% += 1
 1410 WHILE buf%?I%=ASC" ": I% += 1:ENDWHILE
 1420 CASE tag$ OF
 1430  WHEN "version"
 1440   PrData_version% = FNread
 1450  WHEN "printer_name"
 1460   REM build a name
 1470   tag$=LEFT$($(buf%+I%),40)
 1480   DIM description% LENtag$+1
 1490   $description% = tag$
 1500   REM now add a block to our list of printer data blocks
 1510   DIM printer_data% printer_data_size%
 1520   FOR I%=0 TO printer_data_size%-4 STEP 4
 1530     printer_data%!I% = defaults%!I%
 1540   NEXT
 1550   printer_data%!description_field% = description%
 1560   IF P%=0 THEN
 1570    printer_data_list% = printer_data%
 1580   ELSE
 1590    P%!list_pointer_field% = printer_data%
 1600   ENDIF
 1610   P% = printer_data%
 1620  WHEN "pxres","pyres","features","pxres_halftone","pyres_halftone","printer_number"
 1630   REM note that all tags are the same as their respective field names
 1640   printer_data%!EVAL(tag$+"_field%") = FNread
 1650  WHEN "dump_depth","interlace"
 1660   printer_data%?EVAL(tag$+"_field%") = FNread
 1670  WHEN "line_prologue","line_epilogue","line_interlace","job_prologue","job_epilogue"
 1680   WHILE buf%?I%=ASC" ":I%+=1:ENDWHILE
 1690   J% = EVAL(tag$+"_field%")
 1700   SYS "OS_GSTrans",buf%+I%,printer_data%+1+J%,20 TO ,,I%
 1710   printer_data%?J% = I%
 1720  WHEN "page_width","page_height","page_bottom","page_top","page_left","page_right"
 1730     page_desc%(page_number%,EVAL(tag$+"_field%")) = FNread
 1740     page_ptrs%(page_number%,EVAL(tag$+"_field%")) = ptr%+I%
 1750  WHEN "page_number"
 1760     page_number% = FNread
 1770  WHEN "server","page_name","file","page_selection"
 1780   REM read a string
 1790   J% = I%
 1800   WHILE buf%?J%>=ASC" " AND buf%?J%<>ASC";"
 1810    J% += 1
 1820   ENDWHILE
 1830   REM from I% to J% is the string
 1840   CASE tag$ OF
 1850   WHEN "server"
 1860    server_ptr% = ptr% + I%
 1870    server_config$ = MID$($buf%, I%+1, J%-I%)
 1880   WHEN "file"
 1890    file_ptr% = ptr% + I%
 1900    file_config$ = MID$($buf%, I%+1, J%-I%)
 1910    $file_name%=file_config$
 1920    SYS "XOS_CLI","set PrinterType$5 "+file_config$
 1930   WHEN "page_name"
 1940    page_names$(page_number%)=MID$($buf%, I%+1, J%-I%)
 1950    page_ptrs%(page_number%,page_name_field%) = ptr%+I%
 1960   WHEN "page_selection"
 1970    page_selection$(page_number%)=MID$($buf%, I%+1, J%-I%)
 1980   ENDCASE
 1990  WHEN "start_page_number"
 2000   page_number_config% = FNread
 2010   page_number_ptr% = ptr% + I%
 2020  WHEN "printer"
 2030   printer_config% = FNread
 2040   printer_new% = printer_config%
 2050   printer_ptr% = ptr% + I%
 2060  WHEN "location"
 2070   location_config% = FNread
 2080   location_ptr% = ptr% + I%
 2090  WHEN "baud"
 2100   baud_config% = FNread
 2110   baud_ptr% = ptr% + I%
 2120  WHEN "data"
 2130   data_config% = FNread
 2140   data_ptr% = ptr% + I%
 2150  WHEN "xon"
 2160   XON_config% = FNread
 2170   XON_new% = XON_config%
 2180   XON_ptr% = ptr% + I%
 2190  WHEN "line"
 2200   line_config% = FNread
 2210   line_new% = line_config%
 2220   line_ptr% = ptr% + I%
 2230  WHEN "mono"
 2240   mono_config% = FNread
 2250   mono_new% = mono_config%
 2260   mono_ptr% = ptr% + I%
 2270 ENDCASE
 2280ENDIF
 2290ENDPROC
 2300:
 2310DEFFNread=FNread_integer_expression(RIGHT$($buf%,LEN$buf%-I%))
 2320:
 2330REM ***************************************
 2340REM convert a string to an integer
 2350REM ***************************************
 2360DEFFNread_integer_expression(S$)
 2370LOCAL R%, T%, E$, P%
 2380E$=""
 2390REM get rid of any comment
 2400WHILE LEFT$(S$,1) <> ";" AND LENS$ <> 0
 2410 E$ += LEFT$(S$,1)
 2420 S$ = RIGHT$(S$,LENS$-1)
 2430ENDWHILE
 2440SYS"XOS_EvaluateExpression",E$,buf%,256 TO ,T%,R%;P%
 2450IF T% <> 0 OR (P% AND 1) ERROR 100, "Integer value needed for "+tag$
 2460=R%
 2470:
 2480REM ***************************************
 2490REM allow only alphanumerics in tag fields
 2500REM ***************************************
 2510DEFFNtagchar(C%)
 2520IF (C% >= ASC"A" AND C% <= ASC"Z") THEN =TRUE
 2530IF (C% >= ASC"a" AND C% <= ASC"z") THEN =TRUE
 2540=  (C% >= ASC"0" AND C% <= ASC"9") OR C% = ASC"_"
 2550:
 2560REM *********************************************************************
 2570REM set the printer driver module's state to reflect the current settings
 2580REM *********************************************************************
 2590DEFPROCPrinter_set_module_data
 2600LOCAL A%,B%,C%,D%,E%,F%
 2610A%=defaults%!pxres_field%
 2620B%=defaults%!pyres_field%
 2630C%=defaults%!features_field%
 2640D%=defaults%!pxres_halftone_field%
 2650E%=defaults%!pyres_halftone_field%
 2660F%=defaults%!printer_number_field%
 2670SYS "PDriver_SetInfo",,A%,B%,C%,,D%,E%,F%
 2680msg%!0=20
 2690msg%!12=0
 2700msg%!16=Message_SetPrinter%
 2710SYS "Wimp_SendMessage", 18, msg%, 0
 2720defaults%?mono_field% = mono_new%
 2730SYS "PDriver_SetPrinter",defaults%+dump_depth_field%
 2740ENDPROC
 2750:
 2760REM ***************************************
 2770REM set the description field in our window
 2780REM ***************************************
 2790DEFPROCPrinter_set_description
 2800LOCAL S%, S$
 2810FOR S% = 0 TO printer_data_size%-4 STEP 4
 2820defaults%!S% = printer_data_list%!S%
 2830NEXT
 2840PROCPrinter_set_icon(main_description%,$(defaults%!description_field%))
 2850SYS "XOS_CLI","SET Printer$"+" """+$(defaults%!description_field%)+""""
 2860ENDPROC
 2870:
 2880DEF PROCPrinter_change_page_size
 2890OSCLI("Set PDriver$DMextra """+page_selection$(page_number%)+"""")
 2900ENDPROC
 2910:
 2920DEFPROCPrinter_set_icon(I%,S$)
 2930LOCAL S%
 2940S%=FNiconaddr(main%,I%)
 2950$S% = S$
 2960PROCzero_terminate(S%)
 2970PROCset_icon_state(main%,I%,0,0): REM force redraw
 2980ENDPROC
 2990:
 3000DEF PROCPrinter_AmendConfig
 3010IF line_config% <> line_new% THEN
 3020 PTR#out_file%=line_ptr%
 3030 BPUT#out_file%,STR$line_new%;
 3040 line_config% = line_new%
 3050ENDIF
 3060IF mono_config% <> mono_new% THEN
 3070 PTR#out_file%=mono_ptr%
 3080 BPUT#out_file%,STR$mono_new%;
 3090 mono_config% = mono_new%
 3100ENDIF
 3110ENDPROC
 3120:
 3130DEF PROCPrinter_Ignore
 3140ENDPROC
 3150:
 3160DEF PROCPrinter_XonXoff(flag%)
 3170IF flag% THEN
 3180 *fx 2,2
 3190ELSE
 3200 *fx 2,0
 3210ENDIF
 3220ENDPROC
 3230:
 3240DEF PROCPrinter_Location(loc%)
 3250REM The current printer location setting doesn't affect this printer driver
 3260ENDPROC
 3270:
 3280DEF PROCPrinter_Header
 3290line_print%=line_new%
 3300`ext%=EXT#in_file%
 3310ENDPROC
 3320:
 3330DEF PROCPrinter_Footer
 3340ENDPROC
 3350:
 3360DEF FNPrinter_Send(len%)
 3370PROCEscOn
 3380LOCAL L%,C%
 3390L%=`ext% - PTR#in_file%
 3400IF line_print% AND Ftype%<>OutputType% THEN
 3410 WHILE len%>1 AND L%>0
 3420  C%=BGET#in_file%: L%-=1
 3430  IF C%=10 BPUT#out_file%,13:len%-=1
 3440  BPUT#out_file%,C%:len%-=1
 3450  IF C%=13 BPUT#out_file%,10:len%-=1
 3460 ENDWHILE
 3470ELSE
 3480 IF len%>=L% len%=L%
 3490 SYS "OS_GBPB", 4, in_file%, buf%, len%: L%-=len%
 3500 SYS "OS_GBPB", 2, out_file%, buf%, len%
 3510ENDIF
 3520PROCEscOff
 3530=(L%<=0)
 3540>*FX 229,1

3� >Library V.1.12 for dot matrix printer driver
@� Purpose: printer-specific parts of the printer application
1� Authors: A.Thompson, NReeves, DSeal, NRaine
(=� *******************************************************
2=� initialise the dot matrix printer driver specific parts
<=� *******************************************************
F:
P��Printer_initialise
Z� P%
dL� VersionNumber$ <> "1.12" � �moan("Incompatible !RunImage and Library")
nPrinterClass$="PrinterDM"
x"FullPrinterClass$="dot matrix"
�OutputType%=&FF4
�PrData_expected% = 1
�@� define printer class dependent fields in printer data area
�'    dump_depth_field% = �p_field(1)
�'     interlace_field% = �p_field(1)
�'          mono_field% = �p_field(2)
�( line_prologue_field% = �p_field(20)
�( line_epilogue_field% = �p_field(20)
�(line_interlace_field% = �p_field(20)
�(  job_epilogue_field% = �p_field(20)
�(  job_prologue_field% = �p_field(20)
�'   printer_data_size% = �p_field(0)
�1� define class dependent icons in main window
main_line%=2
main_mono%=3
printer_data_list% = 0:P%=0
"�Printer_read_config_file
,"� now convert to circular list
6-P%!list_pointer_field%=printer_data_list%
@�
J:
T� *****************
^� set initial state
h� *****************
r��Printer_set_initial_state
|� D%
�� set default state
�D%=printer_data_list%
�]ȕ D%!list_pointer_field%<>printer_data_list% � D%!printer_number_field%<>printer_config%
� D%=D%!list_pointer_field%
��
�F� D%!printer_number_field%=printer_config% � printer_data_list%=D%
��Printer_set_description
��Printer_set_module_data
��
�:
���Printer_CloseFiles
��
�:
� ********
� shutdown
� ********
&��Printer_terminate
0�
::
D,� **************************************
N+� the printer-specific template loading
X,� **************************************
b��Printer_load_templates
l>�set_icon_state(main%, main_line%, line_new% << 21, 1<<21)
v>�set_icon_state(main%, main_mono%, mono_new% << 21, 1<<21)
��
�:
�)� ***********************************
�(� the printer-specific event handler
�)� ***********************************
�(ݤPrinter_process_event(action%, E%)
�
� res%
�
res%=�
�Ȏ action% �
�
 � 17,18:
�  Ȏ E%!16 �
�   � &502:
��    � E%!32 = main% � E%!36 >= -1 � �helpreply("Printer setup.|MClick SELECT or ADJUST to alter the settings.",E%!8,E%!4):res% = �
  �
 � 6
  � E%!12=main% �
 
   Ȏ � �
*    � (E%!8 � %101)<>0:
4     Ȏ E%!16 �
>      � main_description%:
H       � E%!8 � 1 �
R%        res% = printer_data_list%
\I        � printer_data_list% = printer_data_list%!list_pointer_field%
f;        � printer_data_list%!list_pointer_field% = res%
p       �
zG        printer_data_list% = printer_data_list%!list_pointer_field%
�       �
�#       �Printer_set_description
�#       �Printer_set_module_data
�B       printer_new% = printer_data_list%!printer_number_field%
�       res%=�
�      � main_line%
�       !q%=main%
�       q%!4=main_line%
�%       ș "Wimp_GetIconState",,q%
�(       line_new% = (q%!24 >> 21) � 1
�      � main_mono%
�       !q%=main%
�       q%!4=main_mono%
%       ș "Wimp_GetIconState",,q%
(       mono_new% = (q%!24 >> 21) � 1
#       �Printer_set_module_data
$
     �
.   �
8  �
B�
L	=res%
V:
`G� *****************************************************************
jF� read the configuration file with all the individual printer info
tG� *****************************************************************
~��Printer_read_config_file
�
� H%,ptr%
�"� defaults% printer_data_size%
�6� H%=0 � printer_data_size%-4 � 4:defaults%!H%=0:�
�printer_data% = defaults%
�H%=�"<PDriver$dir>.PrData"
�/� H%=0 � 100,"Can't read printer data file"
��
� ptr% = �#H%
� �Printer_process_line(H%)
�
� �#H%
��#H%
��
:

3� *********************************************
2� process one line from the configuration file
3� *********************************************
(��Printer_process_line(H%)
2� I%,J%,tag$
<$buf%=�#H%
FI%=0
P#ȕ �tagchar(buf%?I%): I% += 1:�
Z� buf%?I% = �":" �
d � got a tag
n  tag$=�lowercase(�$buf%,I%))
x I% += 1
� ȕ buf%?I%=�" ": I% += 1:�
� Ȏ tag$ �
�  � "version"
�   PrData_version% = �read
�  � "printer_name"
�   � build a name
�   tag$=�$(buf%+I%),40)
�   � description% �tag$+1
�   $description% = tag$
�;   � now add a block to our list of printer data blocks
�)   � printer_data% printer_data_size%
�(   � I%=0 � printer_data_size%-4 � 4
�(     printer_data%!I% = defaults%!I%
   �
6   printer_data%!description_field% = description%
   � P%=0 �
"*    printer_data_list% = printer_data%
,   �
6.    P%!list_pointer_field% = printer_data%
@   �
J   P% = printer_data%
TU  � "pxres","pyres","features","pxres_halftone","pyres_halftone","printer_number"
^H   � note that all tags are the same as their respective field names
h.   printer_data%!�(tag$+"_field%") = �read
r   � "dump_depth","interlace"
|.   printer_data%?�(tag$+"_field%") = �read
�V  � "line_prologue","line_epilogue","line_interlace","job_prologue","job_epilogue"
�   ȕ buf%?I%=�" ":I%+=1:�
�   J% = �(tag$+"_field%")
�;   ș "OS_GSTrans",buf%+I%,printer_data%+1+J%,20 � ,,I%
�   printer_data%?J% = I%
�T  � "page_width","page_height","page_bottom","page_top","page_left","page_right"
�;     page_desc%(page_number%,�(tag$+"_field%")) = �read
�=     page_ptrs%(page_number%,�(tag$+"_field%")) = ptr%+I%
�  � "page_number"
�     page_number% = �read
�4  � "server","page_name","file","page_selection"
�   � read a string
�   J% = I%
'   ȕ buf%?J%>=�" " � buf%?J%<>�";"
    J% += 1
   �
&$   � from I% to J% is the string
0   Ȏ tag$ �
:   � "server"
D    server_ptr% = ptr% + I%
N-    server_config$ = �$buf%, I%+1, J%-I%)
X   � "file"
b    file_ptr% = ptr% + I%
l+    file_config$ = �$buf%, I%+1, J%-I%)
v     $file_name%=file_config$
�6    ș "XOS_CLI","set PrinterType$5 "+file_config$
�   � "page_name"
�6    page_names$(page_number%)=�$buf%, I%+1, J%-I%)
�;    page_ptrs%(page_number%,page_name_field%) = ptr%+I%
�   � "page_selection"
�:    page_selection$(page_number%)=�$buf%, I%+1, J%-I%)
�   �
�  � "start_page_number"
�"   page_number_config% = �read
�#   page_number_ptr% = ptr% + I%
�  � "printer"
�   printer_config% = �read
�%   printer_new% = printer_config%
   printer_ptr% = ptr% + I%
  � "location"
   location_config% = �read
     location_ptr% = ptr% + I%
*  � "baud"
4   baud_config% = �read
>   baud_ptr% = ptr% + I%
H  � "data"
R   data_config% = �read
\   data_ptr% = ptr% + I%
f
  � "xon"
p   XON_config% = �read
z   XON_new% = XON_config%
�   XON_ptr% = ptr% + I%
�  � "line"
�   line_config% = �read
�   line_new% = line_config%
�   line_ptr% = ptr% + I%
�  � "mono"
�   mono_config% = �read
�   mono_new% = mono_config%
�   mono_ptr% = ptr% + I%
� �
��
��
�:
	6ݤread=�read_integer_expression(�$buf%,�$buf%-I%))
	:
	-� ***************************************
	$$� convert a string to an integer
	.-� ***************************************
	8!ݤread_integer_expression(S$)
	B� R%, T%, E$, P%
	L	E$=""
	V� get rid of any comment
	`ȕ �S$,1) <> ";" � �S$ <> 0
	j E$ += �S$,1)
	t S$ = �S$,�S$-1)
	~�
	�6ș"XOS_EvaluateExpression",E$,buf%,256 � ,T%,R%;P%
	�@� T% <> 0 � (P% � 1) � 100, "Integer value needed for "+tag$
	�=R%
	�:
	�-� ***************************************
	�,� allow only alphanumerics in tag fields
	�-� ***************************************
	�ݤtagchar(C%)
	�$� (C% >= �"A" � C% <= �"Z") � =�
	�$� (C% >= �"a" � C% <= �"z") � =�
	�,=  (C% >= �"0" � C% <= �"9") � C% = �"_"
	�:
K� *********************************************************************

K� set the printer driver module's state to reflect the current settings
K� *********************************************************************
��Printer_set_module_data
(� A%,B%,C%,D%,E%,F%
2A%=defaults%!pxres_field%
<B%=defaults%!pyres_field%
F C%=defaults%!features_field%
P&D%=defaults%!pxres_halftone_field%
Z&E%=defaults%!pyres_halftone_field%
d&F%=defaults%!printer_number_field%
n,ș "PDriver_SetInfo",,A%,B%,C%,,D%,E%,F%
x
msg%!0=20
�
msg%!12=0
�msg%!16=Message_SetPrinter%
�&ș "Wimp_SendMessage", 18, msg%, 0
�%defaults%?mono_field% = mono_new%
�7ș "PDriver_SetPrinter",defaults%+dump_depth_field%
��
�:
�-� ***************************************
�-� set the description field in our window
�-� ***************************************
���Printer_set_description
�� S%, S$
�'� S% = 0 � printer_data_size%-4 � 4
(defaults%!S% = printer_data_list%!S%
�
H�Printer_set_icon(main_description%,$(defaults%!description_field%))
"Jș "XOS_CLI","SET Printer$"+" """+$(defaults%!description_field%)+""""
,�
6:
@� �Printer_change_page_size
JB�("Set PDriver$DMextra """+page_selection$(page_number%)+"""")
T�
^:
h��Printer_set_icon(I%,S$)
r� S%
|S%=�iconaddr(main%,I%)
�$S% = S$
��zero_terminate(S%)
�1�set_icon_state(main%,I%,0,0): � force redraw
��
�:
�� �Printer_AmendConfig
�!� line_config% <> line_new% �
� �#out_file%=line_ptr%
� �#out_file%,�line_new%;
� line_config% = line_new%
��
�!� mono_config% <> mono_new% �
� �#out_file%=mono_ptr%
 �#out_file%,�mono_new%;
 mono_config% = mono_new%
�
&�
0:
:� �Printer_Ignore
D�
N:
X� �Printer_XonXoff(flag%)
b
� flag% �
l *fx 2,2
v�
� *fx 2,0
��
��
�:
�� �Printer_Location(loc%)
�M� The current printer location setting doesn't affect this printer driver
��
�:
�� �Printer_Header
�line_print%=line_new%
�`ext%=�#in_file%
��
�:

� �Printer_Footer

�

:

 � �Printer_Send(len%)

*
�EscOn

4� L%,C%

>L%=`ext% - �#in_file%

H)� line_print% � Ftype%<>OutputType% �

R ȕ len%>1 � L%>0

\  C%=�#in_file%: L%-=1

f$  � C%=10 �#out_file%,13:len%-=1

p  �#out_file%,C%:len%-=1

z$  � C%=13 �#out_file%,10:len%-=1

� �

��

� � len%>=L% len%=L%

�4 ș "OS_GBPB", 4, in_file%, buf%, len%: L%-=len%

�+ ș "OS_GBPB", 2, out_file%, buf%, len%

��

��EscOff

�=(L%<=0)

�>*FX 229,1
�
00000000  0d 00 0a 33 f4 20 3e 4c  69 62 72 61 72 79 20 56  |...3. >Library V|
00000010  2e 31 2e 31 32 20 66 6f  72 20 64 6f 74 20 6d 61  |.1.12 for dot ma|
00000020  74 72 69 78 20 70 72 69  6e 74 65 72 20 64 72 69  |trix printer dri|
00000030  76 65 72 0d 00 14 40 f4  20 50 75 72 70 6f 73 65  |ver...@. Purpose|
00000040  3a 20 70 72 69 6e 74 65  72 2d 73 70 65 63 69 66  |: printer-specif|
00000050  69 63 20 70 61 72 74 73  20 6f 66 20 74 68 65 20  |ic parts of the |
00000060  70 72 69 6e 74 65 72 20  61 70 70 6c 69 63 61 74  |printer applicat|
00000070  69 6f 6e 0d 00 1e 31 f4  20 41 75 74 68 6f 72 73  |ion...1. Authors|
00000080  3a 20 41 2e 54 68 6f 6d  70 73 6f 6e 2c 20 4e 52  |: A.Thompson, NR|
00000090  65 65 76 65 73 2c 20 44  53 65 61 6c 2c 20 4e 52  |eeves, DSeal, NR|
000000a0  61 69 6e 65 0d 00 28 3d  f4 20 2a 2a 2a 2a 2a 2a  |aine..(=. ******|
000000b0  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
000000e0  2a 0d 00 32 3d f4 20 69  6e 69 74 69 61 6c 69 73  |*..2=. initialis|
000000f0  65 20 74 68 65 20 64 6f  74 20 6d 61 74 72 69 78  |e the dot matrix|
00000100  20 70 72 69 6e 74 65 72  20 64 72 69 76 65 72 20  | printer driver |
00000110  73 70 65 63 69 66 69 63  20 70 61 72 74 73 0d 00  |specific parts..|
00000120  3c 3d f4 20 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |<=. ************|
00000130  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00000150  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 0d 00 46 05 3a  |***********..F.:|
00000160  0d 00 50 18 dd f2 50 72  69 6e 74 65 72 5f 69 6e  |..P...Printer_in|
00000170  69 74 69 61 6c 69 73 65  0d 00 5a 08 ea 20 50 25  |itialise..Z.. P%|
00000180  0d 00 64 4c e7 20 56 65  72 73 69 6f 6e 4e 75 6d  |..dL. VersionNum|
00000190  62 65 72 24 20 3c 3e 20  22 31 2e 31 32 22 20 8c  |ber$ <> "1.12" .|
000001a0  20 f2 6d 6f 61 6e 28 22  49 6e 63 6f 6d 70 61 74  | .moan("Incompat|
000001b0  69 62 6c 65 20 21 52 75  6e 49 6d 61 67 65 20 61  |ible !RunImage a|
000001c0  6e 64 20 4c 69 62 72 61  72 79 22 29 0d 00 6e 1d  |nd Library")..n.|
000001d0  50 72 69 6e 74 65 72 43  6c 61 73 73 24 3d 22 50  |PrinterClass$="P|
000001e0  72 69 6e 74 65 72 44 4d  22 0d 00 78 22 46 75 6c  |rinterDM"..x"Ful|
000001f0  6c 50 72 69 6e 74 65 72  43 6c 61 73 73 24 3d 22  |lPrinterClass$="|
00000200  64 6f 74 20 6d 61 74 72  69 78 22 0d 00 82 14 4f  |dot matrix"....O|
00000210  75 74 70 75 74 54 79 70  65 25 3d 26 46 46 34 0d  |utputType%=&FF4.|
00000220  00 8c 18 50 72 44 61 74  61 5f 65 78 70 65 63 74  |...PrData_expect|
00000230  65 64 25 20 3d 20 31 0d  00 96 40 f4 20 64 65 66  |ed% = 1...@. def|
00000240  69 6e 65 20 70 72 69 6e  74 65 72 20 63 6c 61 73  |ine printer clas|
00000250  73 20 64 65 70 65 6e 64  65 6e 74 20 66 69 65 6c  |s dependent fiel|
00000260  64 73 20 69 6e 20 70 72  69 6e 74 65 72 20 64 61  |ds in printer da|
00000270  74 61 20 61 72 65 61 0d  00 a0 27 20 20 20 20 64  |ta area...'    d|
00000280  75 6d 70 5f 64 65 70 74  68 5f 66 69 65 6c 64 25  |ump_depth_field%|
00000290  20 3d 20 a4 70 5f 66 69  65 6c 64 28 31 29 0d 00  | = .p_field(1)..|
000002a0  aa 27 20 20 20 20 20 69  6e 74 65 72 6c 61 63 65  |.'     interlace|
000002b0  5f 66 69 65 6c 64 25 20  3d 20 a4 70 5f 66 69 65  |_field% = .p_fie|
000002c0  6c 64 28 31 29 0d 00 b4  27 20 20 20 20 20 20 20  |ld(1)...'       |
000002d0  20 20 20 6d 6f 6e 6f 5f  66 69 65 6c 64 25 20 3d  |   mono_field% =|
000002e0  20 a4 70 5f 66 69 65 6c  64 28 32 29 0d 00 be 28  | .p_field(2)...(|
000002f0  20 6c 69 6e 65 5f 70 72  6f 6c 6f 67 75 65 5f 66  | line_prologue_f|
00000300  69 65 6c 64 25 20 3d 20  a4 70 5f 66 69 65 6c 64  |ield% = .p_field|
00000310  28 32 30 29 0d 00 c8 28  20 6c 69 6e 65 5f 65 70  |(20)...( line_ep|
00000320  69 6c 6f 67 75 65 5f 66  69 65 6c 64 25 20 3d 20  |ilogue_field% = |
00000330  a4 70 5f 66 69 65 6c 64  28 32 30 29 0d 00 d2 28  |.p_field(20)...(|
00000340  6c 69 6e 65 5f 69 6e 74  65 72 6c 61 63 65 5f 66  |line_interlace_f|
00000350  69 65 6c 64 25 20 3d 20  a4 70 5f 66 69 65 6c 64  |ield% = .p_field|
00000360  28 32 30 29 0d 00 dc 28  20 20 6a 6f 62 5f 65 70  |(20)...(  job_ep|
00000370  69 6c 6f 67 75 65 5f 66  69 65 6c 64 25 20 3d 20  |ilogue_field% = |
00000380  a4 70 5f 66 69 65 6c 64  28 32 30 29 0d 00 e6 28  |.p_field(20)...(|
00000390  20 20 6a 6f 62 5f 70 72  6f 6c 6f 67 75 65 5f 66  |  job_prologue_f|
000003a0  69 65 6c 64 25 20 3d 20  a4 70 5f 66 69 65 6c 64  |ield% = .p_field|
000003b0  28 32 30 29 0d 00 f0 27  20 20 20 70 72 69 6e 74  |(20)...'   print|
000003c0  65 72 5f 64 61 74 61 5f  73 69 7a 65 25 20 3d 20  |er_data_size% = |
000003d0  a4 70 5f 66 69 65 6c 64  28 30 29 0d 00 fa 31 f4  |.p_field(0)...1.|
000003e0  20 64 65 66 69 6e 65 20  63 6c 61 73 73 20 64 65  | define class de|
000003f0  70 65 6e 64 65 6e 74 20  69 63 6f 6e 73 20 69 6e  |pendent icons in|
00000400  20 6d 61 69 6e 20 77 69  6e 64 6f 77 0d 01 04 10  | main window....|
00000410  6d 61 69 6e 5f 6c 69 6e  65 25 3d 32 0d 01 0e 10  |main_line%=2....|
00000420  6d 61 69 6e 5f 6d 6f 6e  6f 25 3d 33 0d 01 18 1f  |main_mono%=3....|
00000430  70 72 69 6e 74 65 72 5f  64 61 74 61 5f 6c 69 73  |printer_data_lis|
00000440  74 25 20 3d 20 30 3a 50  25 3d 30 0d 01 22 1d f2  |t% = 0:P%=0.."..|
00000450  50 72 69 6e 74 65 72 5f  72 65 61 64 5f 63 6f 6e  |Printer_read_con|
00000460  66 69 67 5f 66 69 6c 65  0d 01 2c 22 f4 20 6e 6f  |fig_file..,". no|
00000470  77 20 63 6f 6e 76 65 72  74 20 74 6f 20 63 69 72  |w convert to cir|
00000480  63 75 6c 61 72 20 6c 69  73 74 0d 01 36 2d 50 25  |cular list..6-P%|
00000490  21 6c 69 73 74 5f 70 6f  69 6e 74 65 72 5f 66 69  |!list_pointer_fi|
000004a0  65 6c 64 25 3d 70 72 69  6e 74 65 72 5f 64 61 74  |eld%=printer_dat|
000004b0  61 5f 6c 69 73 74 25 0d  01 40 05 e1 0d 01 4a 05  |a_list%..@....J.|
000004c0  3a 0d 01 54 17 f4 20 2a  2a 2a 2a 2a 2a 2a 2a 2a  |:..T.. *********|
000004d0  2a 2a 2a 2a 2a 2a 2a 2a  0d 01 5e 17 f4 20 73 65  |********..^.. se|
000004e0  74 20 69 6e 69 74 69 61  6c 20 73 74 61 74 65 0d  |t initial state.|
000004f0  01 68 17 f4 20 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |.h.. ***********|
00000500  2a 2a 2a 2a 2a 2a 0d 01  72 1f dd f2 50 72 69 6e  |******..r...Prin|
00000510  74 65 72 5f 73 65 74 5f  69 6e 69 74 69 61 6c 5f  |ter_set_initial_|
00000520  73 74 61 74 65 0d 01 7c  08 ea 20 44 25 0d 01 86  |state..|.. D%...|
00000530  17 f4 20 73 65 74 20 64  65 66 61 75 6c 74 20 73  |.. set default s|
00000540  74 61 74 65 0d 01 90 19  44 25 3d 70 72 69 6e 74  |tate....D%=print|
00000550  65 72 5f 64 61 74 61 5f  6c 69 73 74 25 0d 01 9a  |er_data_list%...|
00000560  5d c8 95 20 44 25 21 6c  69 73 74 5f 70 6f 69 6e  |].. D%!list_poin|
00000570  74 65 72 5f 66 69 65 6c  64 25 3c 3e 70 72 69 6e  |ter_field%<>prin|
00000580  74 65 72 5f 64 61 74 61  5f 6c 69 73 74 25 20 80  |ter_data_list% .|
00000590  20 44 25 21 70 72 69 6e  74 65 72 5f 6e 75 6d 62  | D%!printer_numb|
000005a0  65 72 5f 66 69 65 6c 64  25 3c 3e 70 72 69 6e 74  |er_field%<>print|
000005b0  65 72 5f 63 6f 6e 66 69  67 25 0d 01 a4 1e 20 44  |er_config%.... D|
000005c0  25 3d 44 25 21 6c 69 73  74 5f 70 6f 69 6e 74 65  |%=D%!list_pointe|
000005d0  72 5f 66 69 65 6c 64 25  0d 01 ae 05 ce 0d 01 b8  |r_field%........|
000005e0  46 e7 20 44 25 21 70 72  69 6e 74 65 72 5f 6e 75  |F. D%!printer_nu|
000005f0  6d 62 65 72 5f 66 69 65  6c 64 25 3d 70 72 69 6e  |mber_field%=prin|
00000600  74 65 72 5f 63 6f 6e 66  69 67 25 20 8c 20 70 72  |ter_config% . pr|
00000610  69 6e 74 65 72 5f 64 61  74 61 5f 6c 69 73 74 25  |inter_data_list%|
00000620  3d 44 25 0d 01 c2 1c f2  50 72 69 6e 74 65 72 5f  |=D%.....Printer_|
00000630  73 65 74 5f 64 65 73 63  72 69 70 74 69 6f 6e 0d  |set_description.|
00000640  01 cc 1c f2 50 72 69 6e  74 65 72 5f 73 65 74 5f  |....Printer_set_|
00000650  6d 6f 64 75 6c 65 5f 64  61 74 61 0d 01 d6 05 e1  |module_data.....|
00000660  0d 01 e0 05 3a 0d 01 ea  18 dd f2 50 72 69 6e 74  |....:......Print|
00000670  65 72 5f 43 6c 6f 73 65  46 69 6c 65 73 0d 01 f4  |er_CloseFiles...|
00000680  05 e1 0d 01 fe 05 3a 0d  02 08 0e f4 20 2a 2a 2a  |......:..... ***|
00000690  2a 2a 2a 2a 2a 0d 02 12  0e f4 20 73 68 75 74 64  |*****..... shutd|
000006a0  6f 77 6e 0d 02 1c 0e f4  20 2a 2a 2a 2a 2a 2a 2a  |own..... *******|
000006b0  2a 0d 02 26 17 dd f2 50  72 69 6e 74 65 72 5f 74  |*..&...Printer_t|
000006c0  65 72 6d 69 6e 61 74 65  0d 02 30 05 e1 0d 02 3a  |erminate..0....:|
000006d0  05 3a 0d 02 44 2c f4 20  2a 2a 2a 2a 2a 2a 2a 2a  |.:..D,. ********|
000006e0  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
000006f0  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 0d 02  |**************..|
00000700  4e 2b f4 20 74 68 65 20  70 72 69 6e 74 65 72 2d  |N+. the printer-|
00000710  73 70 65 63 69 66 69 63  20 74 65 6d 70 6c 61 74  |specific templat|
00000720  65 20 6c 6f 61 64 69 6e  67 0d 02 58 2c f4 20 2a  |e loading..X,. *|
00000730  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00000750  2a 2a 2a 2a 2a 0d 02 62  1c dd f2 50 72 69 6e 74  |*****..b...Print|
00000760  65 72 5f 6c 6f 61 64 5f  74 65 6d 70 6c 61 74 65  |er_load_template|
00000770  73 0d 02 6c 3e f2 73 65  74 5f 69 63 6f 6e 5f 73  |s..l>.set_icon_s|
00000780  74 61 74 65 28 6d 61 69  6e 25 2c 20 6d 61 69 6e  |tate(main%, main|
00000790  5f 6c 69 6e 65 25 2c 20  6c 69 6e 65 5f 6e 65 77  |_line%, line_new|
000007a0  25 20 3c 3c 20 32 31 2c  20 31 3c 3c 32 31 29 0d  |% << 21, 1<<21).|
000007b0  02 76 3e f2 73 65 74 5f  69 63 6f 6e 5f 73 74 61  |.v>.set_icon_sta|
000007c0  74 65 28 6d 61 69 6e 25  2c 20 6d 61 69 6e 5f 6d  |te(main%, main_m|
000007d0  6f 6e 6f 25 2c 20 6d 6f  6e 6f 5f 6e 65 77 25 20  |ono%, mono_new% |
000007e0  3c 3c 20 32 31 2c 20 31  3c 3c 32 31 29 0d 02 80  |<< 21, 1<<21)...|
000007f0  05 e1 0d 02 8a 05 3a 0d  02 94 29 f4 20 2a 2a 2a  |......:...). ***|
00000800  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00000820  0d 02 9e 28 f4 20 74 68  65 20 70 72 69 6e 74 65  |...(. the printe|
00000830  72 2d 73 70 65 63 69 66  69 63 20 65 76 65 6e 74  |r-specific event|
00000840  20 68 61 6e 64 6c 65 72  0d 02 a8 29 f4 20 2a 2a  | handler...). **|
00000850  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00000870  2a 0d 02 b2 28 dd a4 50  72 69 6e 74 65 72 5f 70  |*...(..Printer_p|
00000880  72 6f 63 65 73 73 5f 65  76 65 6e 74 28 61 63 74  |rocess_event(act|
00000890  69 6f 6e 25 2c 20 45 25  29 0d 02 bc 0a ea 20 72  |ion%, E%)..... r|
000008a0  65 73 25 0d 02 c6 0a 72  65 73 25 3d a3 0d 02 d0  |es%....res%=....|
000008b0  10 c8 8e 20 61 63 74 69  6f 6e 25 20 ca 0d 02 da  |... action% ....|
000008c0  0d 20 c9 20 31 37 2c 31  38 3a 0d 02 e4 10 20 20  |. . 17,18:....  |
000008d0  c8 8e 20 45 25 21 31 36  20 ca 0d 02 ee 0e 20 20  |.. E%!16 .....  |
000008e0  20 c9 20 26 35 30 32 3a  0d 02 f8 86 20 20 20 20  | . &502:....    |
000008f0  e7 20 45 25 21 33 32 20  3d 20 6d 61 69 6e 25 20  |. E%!32 = main% |
00000900  80 20 45 25 21 33 36 20  3e 3d 20 2d 31 20 8c 20  |. E%!36 >= -1 . |
00000910  f2 68 65 6c 70 72 65 70  6c 79 28 22 50 72 69 6e  |.helpreply("Prin|
00000920  74 65 72 20 73 65 74 75  70 2e 7c 4d 43 6c 69 63  |ter setup.|MClic|
00000930  6b 20 53 45 4c 45 43 54  20 6f 72 20 41 44 4a 55  |k SELECT or ADJU|
00000940  53 54 20 74 6f 20 61 6c  74 65 72 20 74 68 65 20  |ST to alter the |
00000950  73 65 74 74 69 6e 67 73  2e 22 2c 45 25 21 38 2c  |settings.",E%!8,|
00000960  45 25 21 34 29 3a 72 65  73 25 20 3d 20 b9 0d 03  |E%!4):res% = ...|
00000970  02 07 20 20 cb 0d 03 0c  08 20 c9 20 36 0d 03 16  |..  ..... . 6...|
00000980  15 20 20 e7 20 45 25 21  31 32 3d 6d 61 69 6e 25  |.  . E%!12=main%|
00000990  20 8c 0d 03 20 0d 20 20  20 c8 8e 20 b9 20 ca 0d  | ... .   .. . ..|
000009a0  03 2a 1b 20 20 20 20 c9  20 28 45 25 21 38 20 80  |.*.    . (E%!8 .|
000009b0  20 25 31 30 31 29 3c 3e  30 3a 0d 03 34 13 20 20  | %101)<>0:..4.  |
000009c0  20 20 20 c8 8e 20 45 25  21 31 36 20 ca 0d 03 3e  |   .. E%!16 ...>|
000009d0  1e 20 20 20 20 20 20 c9  20 6d 61 69 6e 5f 64 65  |.      . main_de|
000009e0  73 63 72 69 70 74 69 6f  6e 25 3a 0d 03 48 17 20  |scription%:..H. |
000009f0  20 20 20 20 20 20 e7 20  45 25 21 38 20 80 20 31  |      . E%!8 . 1|
00000a00  20 8c 0d 03 52 25 20 20  20 20 20 20 20 20 72 65  | ...R%        re|
00000a10  73 25 20 3d 20 70 72 69  6e 74 65 72 5f 64 61 74  |s% = printer_dat|
00000a20  61 5f 6c 69 73 74 25 0d  03 5c 49 20 20 20 20 20  |a_list%..\I     |
00000a30  20 20 20 f5 20 70 72 69  6e 74 65 72 5f 64 61 74  |   . printer_dat|
00000a40  61 5f 6c 69 73 74 25 20  3d 20 70 72 69 6e 74 65  |a_list% = printe|
00000a50  72 5f 64 61 74 61 5f 6c  69 73 74 25 21 6c 69 73  |r_data_list%!lis|
00000a60  74 5f 70 6f 69 6e 74 65  72 5f 66 69 65 6c 64 25  |t_pointer_field%|
00000a70  0d 03 66 3b 20 20 20 20  20 20 20 20 fd 20 70 72  |..f;        . pr|
00000a80  69 6e 74 65 72 5f 64 61  74 61 5f 6c 69 73 74 25  |inter_data_list%|
00000a90  21 6c 69 73 74 5f 70 6f  69 6e 74 65 72 5f 66 69  |!list_pointer_fi|
00000aa0  65 6c 64 25 20 3d 20 72  65 73 25 0d 03 70 0c 20  |eld% = res%..p. |
00000ab0  20 20 20 20 20 20 cc 0d  03 7a 47 20 20 20 20 20  |      ...zG     |
00000ac0  20 20 20 70 72 69 6e 74  65 72 5f 64 61 74 61 5f  |   printer_data_|
00000ad0  6c 69 73 74 25 20 3d 20  70 72 69 6e 74 65 72 5f  |list% = printer_|
00000ae0  64 61 74 61 5f 6c 69 73  74 25 21 6c 69 73 74 5f  |data_list%!list_|
00000af0  70 6f 69 6e 74 65 72 5f  66 69 65 6c 64 25 0d 03  |pointer_field%..|
00000b00  84 0c 20 20 20 20 20 20  20 cd 0d 03 8e 23 20 20  |..       ....#  |
00000b10  20 20 20 20 20 f2 50 72  69 6e 74 65 72 5f 73 65  |     .Printer_se|
00000b20  74 5f 64 65 73 63 72 69  70 74 69 6f 6e 0d 03 98  |t_description...|
00000b30  23 20 20 20 20 20 20 20  f2 50 72 69 6e 74 65 72  |#       .Printer|
00000b40  5f 73 65 74 5f 6d 6f 64  75 6c 65 5f 64 61 74 61  |_set_module_data|
00000b50  0d 03 a2 42 20 20 20 20  20 20 20 70 72 69 6e 74  |...B       print|
00000b60  65 72 5f 6e 65 77 25 20  3d 20 70 72 69 6e 74 65  |er_new% = printe|
00000b70  72 5f 64 61 74 61 5f 6c  69 73 74 25 21 70 72 69  |r_data_list%!pri|
00000b80  6e 74 65 72 5f 6e 75 6d  62 65 72 5f 66 69 65 6c  |nter_number_fiel|
00000b90  64 25 0d 03 ac 11 20 20  20 20 20 20 20 72 65 73  |d%....       res|
00000ba0  25 3d b9 0d 03 b6 16 20  20 20 20 20 20 c9 20 6d  |%=.....      . m|
00000bb0  61 69 6e 5f 6c 69 6e 65  25 0d 03 c0 14 20 20 20  |ain_line%....   |
00000bc0  20 20 20 20 21 71 25 3d  6d 61 69 6e 25 0d 03 ca  |    !q%=main%...|
00000bd0  1a 20 20 20 20 20 20 20  71 25 21 34 3d 6d 61 69  |.       q%!4=mai|
00000be0  6e 5f 6c 69 6e 65 25 0d  03 d4 25 20 20 20 20 20  |n_line%...%     |
00000bf0  20 20 c8 99 20 22 57 69  6d 70 5f 47 65 74 49 63  |  .. "Wimp_GetIc|
00000c00  6f 6e 53 74 61 74 65 22  2c 2c 71 25 0d 03 de 28  |onState",,q%...(|
00000c10  20 20 20 20 20 20 20 6c  69 6e 65 5f 6e 65 77 25  |       line_new%|
00000c20  20 3d 20 28 71 25 21 32  34 20 3e 3e 20 32 31 29  | = (q%!24 >> 21)|
00000c30  20 80 20 31 0d 03 e8 16  20 20 20 20 20 20 c9 20  | . 1....      . |
00000c40  6d 61 69 6e 5f 6d 6f 6e  6f 25 0d 03 f2 14 20 20  |main_mono%....  |
00000c50  20 20 20 20 20 21 71 25  3d 6d 61 69 6e 25 0d 03  |     !q%=main%..|
00000c60  fc 1a 20 20 20 20 20 20  20 71 25 21 34 3d 6d 61  |..       q%!4=ma|
00000c70  69 6e 5f 6d 6f 6e 6f 25  0d 04 06 25 20 20 20 20  |in_mono%...%    |
00000c80  20 20 20 c8 99 20 22 57  69 6d 70 5f 47 65 74 49  |   .. "Wimp_GetI|
00000c90  63 6f 6e 53 74 61 74 65  22 2c 2c 71 25 0d 04 10  |conState",,q%...|
00000ca0  28 20 20 20 20 20 20 20  6d 6f 6e 6f 5f 6e 65 77  |(       mono_new|
00000cb0  25 20 3d 20 28 71 25 21  32 34 20 3e 3e 20 32 31  |% = (q%!24 >> 21|
00000cc0  29 20 80 20 31 0d 04 1a  23 20 20 20 20 20 20 20  |) . 1...#       |
00000cd0  f2 50 72 69 6e 74 65 72  5f 73 65 74 5f 6d 6f 64  |.Printer_set_mod|
00000ce0  75 6c 65 5f 64 61 74 61  0d 04 24 0a 20 20 20 20  |ule_data..$.    |
00000cf0  20 cb 0d 04 2e 08 20 20  20 cb 0d 04 38 07 20 20  | .....   ...8.  |
00000d00  cd 0d 04 42 05 cb 0d 04  4c 09 3d 72 65 73 25 0d  |...B....L.=res%.|
00000d10  04 56 05 3a 0d 04 60 47  f4 20 2a 2a 2a 2a 2a 2a  |.V.:..`G. ******|
00000d20  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00000d50  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 0d 04 6a 46 f4  |***********..jF.|
00000d60  20 72 65 61 64 20 74 68  65 20 63 6f 6e 66 69 67  | read the config|
00000d70  75 72 61 74 69 6f 6e 20  66 69 6c 65 20 77 69 74  |uration file wit|
00000d80  68 20 61 6c 6c 20 74 68  65 20 69 6e 64 69 76 69  |h all the indivi|
00000d90  64 75 61 6c 20 70 72 69  6e 74 65 72 20 69 6e 66  |dual printer inf|
00000da0  6f 0d 04 74 47 f4 20 2a  2a 2a 2a 2a 2a 2a 2a 2a  |o..tG. *********|
00000db0  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00000de0  2a 2a 2a 2a 2a 2a 2a 2a  0d 04 7e 1e dd f2 50 72  |********..~...Pr|
00000df0  69 6e 74 65 72 5f 72 65  61 64 5f 63 6f 6e 66 69  |inter_read_confi|
00000e00  67 5f 66 69 6c 65 0d 04  88 0d ea 20 48 25 2c 70  |g_file..... H%,p|
00000e10  74 72 25 0d 04 92 22 de  20 64 65 66 61 75 6c 74  |tr%...". default|
00000e20  73 25 20 70 72 69 6e 74  65 72 5f 64 61 74 61 5f  |s% printer_data_|
00000e30  73 69 7a 65 25 0d 04 9c  36 e3 20 48 25 3d 30 20  |size%...6. H%=0 |
00000e40  b8 20 70 72 69 6e 74 65  72 5f 64 61 74 61 5f 73  |. printer_data_s|
00000e50  69 7a 65 25 2d 34 20 88  20 34 3a 64 65 66 61 75  |ize%-4 . 4:defau|
00000e60  6c 74 73 25 21 48 25 3d  30 3a ed 0d 04 a6 1d 70  |lts%!H%=0:.....p|
00000e70  72 69 6e 74 65 72 5f 64  61 74 61 25 20 3d 20 64  |rinter_data% = d|
00000e80  65 66 61 75 6c 74 73 25  0d 04 b0 1e 48 25 3d 8e  |efaults%....H%=.|
00000e90  22 3c 50 44 72 69 76 65  72 24 64 69 72 3e 2e 50  |"<PDriver$dir>.P|
00000ea0  72 44 61 74 61 22 0d 04  ba 2f e7 20 48 25 3d 30  |rData".../. H%=0|
00000eb0  20 85 20 31 30 30 2c 22  43 61 6e 27 74 20 72 65  | . 100,"Can't re|
00000ec0  61 64 20 70 72 69 6e 74  65 72 20 64 61 74 61 20  |ad printer data |
00000ed0  66 69 6c 65 22 0d 04 c4  05 f5 0d 04 ce 10 20 70  |file"......... p|
00000ee0  74 72 25 20 3d 20 8f 23  48 25 0d 04 d8 1e 20 f2  |tr% = .#H%.... .|
00000ef0  50 72 69 6e 74 65 72 5f  70 72 6f 63 65 73 73 5f  |Printer_process_|
00000f00  6c 69 6e 65 28 48 25 29  0d 04 e2 0a fd 20 c5 23  |line(H%)..... .#|
00000f10  48 25 0d 04 ec 08 d9 23  48 25 0d 04 f6 05 e1 0d  |H%.....#H%......|
00000f20  05 00 05 3a 0d 05 0a 33  f4 20 2a 2a 2a 2a 2a 2a  |...:...3. ******|
00000f30  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00000f50  2a 2a 2a 2a 2a 2a 2a 0d  05 14 32 f4 20 70 72 6f  |*******...2. pro|
00000f60  63 65 73 73 20 6f 6e 65  20 6c 69 6e 65 20 66 72  |cess one line fr|
00000f70  6f 6d 20 74 68 65 20 63  6f 6e 66 69 67 75 72 61  |om the configura|
00000f80  74 69 6f 6e 20 66 69 6c  65 0d 05 1e 33 f4 20 2a  |tion file...3. *|
00000f90  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00000fb0  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 0d 05 28 1e  |************..(.|
00000fc0  dd f2 50 72 69 6e 74 65  72 5f 70 72 6f 63 65 73  |..Printer_proces|
00000fd0  73 5f 6c 69 6e 65 28 48  25 29 0d 05 32 10 ea 20  |s_line(H%)..2.. |
00000fe0  49 25 2c 4a 25 2c 74 61  67 24 0d 05 3c 0e 24 62  |I%,J%,tag$..<.$b|
00000ff0  75 66 25 3d be 23 48 25  0d 05 46 08 49 25 3d 30  |uf%=.#H%..F.I%=0|
00001000  0d 05 50 23 c8 95 20 a4  74 61 67 63 68 61 72 28  |..P#.. .tagchar(|
00001010  62 75 66 25 3f 49 25 29  3a 20 49 25 20 2b 3d 20  |buf%?I%): I% += |
00001020  31 3a ce 0d 05 5a 16 e7  20 62 75 66 25 3f 49 25  |1:...Z.. buf%?I%|
00001030  20 3d 20 97 22 3a 22 20  8c 0d 05 64 10 20 f4 20  | = .":" ...d. . |
00001040  67 6f 74 20 61 20 74 61  67 0d 05 6e 20 20 74 61  |got a tag..n  ta|
00001050  67 24 3d a4 6c 6f 77 65  72 63 61 73 65 28 c0 24  |g$=.lowercase(.$|
00001060  62 75 66 25 2c 49 25 29  29 0d 05 78 0c 20 49 25  |buf%,I%))..x. I%|
00001070  20 2b 3d 20 31 0d 05 82  1f 20 c8 95 20 62 75 66  | += 1.... .. buf|
00001080  25 3f 49 25 3d 97 22 20  22 3a 20 49 25 20 2b 3d  |%?I%=." ": I% +=|
00001090  20 31 3a ce 0d 05 8c 0e  20 c8 8e 20 74 61 67 24  | 1:..... .. tag$|
000010a0  20 ca 0d 05 96 11 20 20  c9 20 22 76 65 72 73 69  | .....  . "versi|
000010b0  6f 6e 22 0d 05 a0 1e 20  20 20 50 72 44 61 74 61  |on"....   PrData|
000010c0  5f 76 65 72 73 69 6f 6e  25 20 3d 20 a4 72 65 61  |_version% = .rea|
000010d0  64 0d 05 aa 16 20 20 c9  20 22 70 72 69 6e 74 65  |d....  . "printe|
000010e0  72 5f 6e 61 6d 65 22 0d  05 b4 15 20 20 20 f4 20  |r_name"....   . |
000010f0  62 75 69 6c 64 20 61 20  6e 61 6d 65 0d 05 be 1b  |build a name....|
00001100  20 20 20 74 61 67 24 3d  c0 24 28 62 75 66 25 2b  |   tag$=.$(buf%+|
00001110  49 25 29 2c 34 30 29 0d  05 c8 1d 20 20 20 de 20  |I%),40)....   . |
00001120  64 65 73 63 72 69 70 74  69 6f 6e 25 20 a9 74 61  |description% .ta|
00001130  67 24 2b 31 0d 05 d2 1b  20 20 20 24 64 65 73 63  |g$+1....   $desc|
00001140  72 69 70 74 69 6f 6e 25  20 3d 20 74 61 67 24 0d  |ription% = tag$.|
00001150  05 dc 3b 20 20 20 f4 20  6e 6f 77 20 61 64 64 20  |..;   . now add |
00001160  61 20 62 6c 6f 63 6b 20  74 6f 20 6f 75 72 20 6c  |a block to our l|
00001170  69 73 74 20 6f 66 20 70  72 69 6e 74 65 72 20 64  |ist of printer d|
00001180  61 74 61 20 62 6c 6f 63  6b 73 0d 05 e6 29 20 20  |ata blocks...)  |
00001190  20 de 20 70 72 69 6e 74  65 72 5f 64 61 74 61 25  | . printer_data%|
000011a0  20 70 72 69 6e 74 65 72  5f 64 61 74 61 5f 73 69  | printer_data_si|
000011b0  7a 65 25 0d 05 f0 28 20  20 20 e3 20 49 25 3d 30  |ze%...(   . I%=0|
000011c0  20 b8 20 70 72 69 6e 74  65 72 5f 64 61 74 61 5f  | . printer_data_|
000011d0  73 69 7a 65 25 2d 34 20  88 20 34 0d 05 fa 28 20  |size%-4 . 4...( |
000011e0  20 20 20 20 70 72 69 6e  74 65 72 5f 64 61 74 61  |    printer_data|
000011f0  25 21 49 25 20 3d 20 64  65 66 61 75 6c 74 73 25  |%!I% = defaults%|
00001200  21 49 25 0d 06 04 08 20  20 20 ed 0d 06 0e 36 20  |!I%....   ....6 |
00001210  20 20 70 72 69 6e 74 65  72 5f 64 61 74 61 25 21  |  printer_data%!|
00001220  64 65 73 63 72 69 70 74  69 6f 6e 5f 66 69 65 6c  |description_fiel|
00001230  64 25 20 3d 20 64 65 73  63 72 69 70 74 69 6f 6e  |d% = description|
00001240  25 0d 06 18 0f 20 20 20  e7 20 50 25 3d 30 20 8c  |%....   . P%=0 .|
00001250  0d 06 22 2a 20 20 20 20  70 72 69 6e 74 65 72 5f  |.."*    printer_|
00001260  64 61 74 61 5f 6c 69 73  74 25 20 3d 20 70 72 69  |data_list% = pri|
00001270  6e 74 65 72 5f 64 61 74  61 25 0d 06 2c 08 20 20  |nter_data%..,.  |
00001280  20 cc 0d 06 36 2e 20 20  20 20 50 25 21 6c 69 73  | ...6.    P%!lis|
00001290  74 5f 70 6f 69 6e 74 65  72 5f 66 69 65 6c 64 25  |t_pointer_field%|
000012a0  20 3d 20 70 72 69 6e 74  65 72 5f 64 61 74 61 25  | = printer_data%|
000012b0  0d 06 40 08 20 20 20 cd  0d 06 4a 19 20 20 20 50  |..@.   ...J.   P|
000012c0  25 20 3d 20 70 72 69 6e  74 65 72 5f 64 61 74 61  |% = printer_data|
000012d0  25 0d 06 54 55 20 20 c9  20 22 70 78 72 65 73 22  |%..TU  . "pxres"|
000012e0  2c 22 70 79 72 65 73 22  2c 22 66 65 61 74 75 72  |,"pyres","featur|
000012f0  65 73 22 2c 22 70 78 72  65 73 5f 68 61 6c 66 74  |es","pxres_halft|
00001300  6f 6e 65 22 2c 22 70 79  72 65 73 5f 68 61 6c 66  |one","pyres_half|
00001310  74 6f 6e 65 22 2c 22 70  72 69 6e 74 65 72 5f 6e  |tone","printer_n|
00001320  75 6d 62 65 72 22 0d 06  5e 48 20 20 20 f4 20 6e  |umber"..^H   . n|
00001330  6f 74 65 20 74 68 61 74  20 61 6c 6c 20 74 61 67  |ote that all tag|
00001340  73 20 61 72 65 20 74 68  65 20 73 61 6d 65 20 61  |s are the same a|
00001350  73 20 74 68 65 69 72 20  72 65 73 70 65 63 74 69  |s their respecti|
00001360  76 65 20 66 69 65 6c 64  20 6e 61 6d 65 73 0d 06  |ve field names..|
00001370  68 2e 20 20 20 70 72 69  6e 74 65 72 5f 64 61 74  |h.   printer_dat|
00001380  61 25 21 a0 28 74 61 67  24 2b 22 5f 66 69 65 6c  |a%!.(tag$+"_fiel|
00001390  64 25 22 29 20 3d 20 a4  72 65 61 64 0d 06 72 20  |d%") = .read..r |
000013a0  20 20 c9 20 22 64 75 6d  70 5f 64 65 70 74 68 22  |  . "dump_depth"|
000013b0  2c 22 69 6e 74 65 72 6c  61 63 65 22 0d 06 7c 2e  |,"interlace"..|.|
000013c0  20 20 20 70 72 69 6e 74  65 72 5f 64 61 74 61 25  |   printer_data%|
000013d0  3f a0 28 74 61 67 24 2b  22 5f 66 69 65 6c 64 25  |?.(tag$+"_field%|
000013e0  22 29 20 3d 20 a4 72 65  61 64 0d 06 86 56 20 20  |") = .read...V  |
000013f0  c9 20 22 6c 69 6e 65 5f  70 72 6f 6c 6f 67 75 65  |. "line_prologue|
00001400  22 2c 22 6c 69 6e 65 5f  65 70 69 6c 6f 67 75 65  |","line_epilogue|
00001410  22 2c 22 6c 69 6e 65 5f  69 6e 74 65 72 6c 61 63  |","line_interlac|
00001420  65 22 2c 22 6a 6f 62 5f  70 72 6f 6c 6f 67 75 65  |e","job_prologue|
00001430  22 2c 22 6a 6f 62 5f 65  70 69 6c 6f 67 75 65 22  |","job_epilogue"|
00001440  0d 06 90 1e 20 20 20 c8  95 20 62 75 66 25 3f 49  |....   .. buf%?I|
00001450  25 3d 97 22 20 22 3a 49  25 2b 3d 31 3a ce 0d 06  |%=." ":I%+=1:...|
00001460  9a 1d 20 20 20 4a 25 20  3d 20 a0 28 74 61 67 24  |..   J% = .(tag$|
00001470  2b 22 5f 66 69 65 6c 64  25 22 29 0d 06 a4 3b 20  |+"_field%")...; |
00001480  20 20 c8 99 20 22 4f 53  5f 47 53 54 72 61 6e 73  |  .. "OS_GSTrans|
00001490  22 2c 62 75 66 25 2b 49  25 2c 70 72 69 6e 74 65  |",buf%+I%,printe|
000014a0  72 5f 64 61 74 61 25 2b  31 2b 4a 25 2c 32 30 20  |r_data%+1+J%,20 |
000014b0  b8 20 2c 2c 49 25 0d 06  ae 1c 20 20 20 70 72 69  |. ,,I%....   pri|
000014c0  6e 74 65 72 5f 64 61 74  61 25 3f 4a 25 20 3d 20  |nter_data%?J% = |
000014d0  49 25 0d 06 b8 54 20 20  c9 20 22 70 61 67 65 5f  |I%...T  . "page_|
000014e0  77 69 64 74 68 22 2c 22  70 61 67 65 5f 68 65 69  |width","page_hei|
000014f0  67 68 74 22 2c 22 70 61  67 65 5f 62 6f 74 74 6f  |ght","page_botto|
00001500  6d 22 2c 22 70 61 67 65  5f 74 6f 70 22 2c 22 70  |m","page_top","p|
00001510  61 67 65 5f 6c 65 66 74  22 2c 22 70 61 67 65 5f  |age_left","page_|
00001520  72 69 67 68 74 22 0d 06  c2 3b 20 20 20 20 20 70  |right"...;     p|
00001530  61 67 65 5f 64 65 73 63  25 28 70 61 67 65 5f 6e  |age_desc%(page_n|
00001540  75 6d 62 65 72 25 2c a0  28 74 61 67 24 2b 22 5f  |umber%,.(tag$+"_|
00001550  66 69 65 6c 64 25 22 29  29 20 3d 20 a4 72 65 61  |field%")) = .rea|
00001560  64 0d 06 cc 3d 20 20 20  20 20 70 61 67 65 5f 70  |d...=     page_p|
00001570  74 72 73 25 28 70 61 67  65 5f 6e 75 6d 62 65 72  |trs%(page_number|
00001580  25 2c a0 28 74 61 67 24  2b 22 5f 66 69 65 6c 64  |%,.(tag$+"_field|
00001590  25 22 29 29 20 3d 20 70  74 72 25 2b 49 25 0d 06  |%")) = ptr%+I%..|
000015a0  d6 15 20 20 c9 20 22 70  61 67 65 5f 6e 75 6d 62  |..  . "page_numb|
000015b0  65 72 22 0d 06 e0 1d 20  20 20 20 20 70 61 67 65  |er"....     page|
000015c0  5f 6e 75 6d 62 65 72 25  20 3d 20 a4 72 65 61 64  |_number% = .read|
000015d0  0d 06 ea 34 20 20 c9 20  22 73 65 72 76 65 72 22  |...4  . "server"|
000015e0  2c 22 70 61 67 65 5f 6e  61 6d 65 22 2c 22 66 69  |,"page_name","fi|
000015f0  6c 65 22 2c 22 70 61 67  65 5f 73 65 6c 65 63 74  |le","page_select|
00001600  69 6f 6e 22 0d 06 f4 16  20 20 20 f4 20 72 65 61  |ion"....   . rea|
00001610  64 20 61 20 73 74 72 69  6e 67 0d 06 fe 0e 20 20  |d a string....  |
00001620  20 4a 25 20 3d 20 49 25  0d 07 08 27 20 20 20 c8  | J% = I%...'   .|
00001630  95 20 62 75 66 25 3f 4a  25 3e 3d 97 22 20 22 20  |. buf%?J%>=." " |
00001640  80 20 62 75 66 25 3f 4a  25 3c 3e 97 22 3b 22 0d  |. buf%?J%<>.";".|
00001650  07 12 0f 20 20 20 20 4a  25 20 2b 3d 20 31 0d 07  |...    J% += 1..|
00001660  1c 08 20 20 20 ce 0d 07  26 24 20 20 20 f4 20 66  |..   ...&$   . f|
00001670  72 6f 6d 20 49 25 20 74  6f 20 4a 25 20 69 73 20  |rom I% to J% is |
00001680  74 68 65 20 73 74 72 69  6e 67 0d 07 30 10 20 20  |the string..0.  |
00001690  20 c8 8e 20 74 61 67 24  20 ca 0d 07 3a 11 20 20  | .. tag$ ...:.  |
000016a0  20 c9 20 22 73 65 72 76  65 72 22 0d 07 44 1f 20  | . "server"..D. |
000016b0  20 20 20 73 65 72 76 65  72 5f 70 74 72 25 20 3d  |   server_ptr% =|
000016c0  20 70 74 72 25 20 2b 20  49 25 0d 07 4e 2d 20 20  | ptr% + I%..N-  |
000016d0  20 20 73 65 72 76 65 72  5f 63 6f 6e 66 69 67 24  |  server_config$|
000016e0  20 3d 20 c1 24 62 75 66  25 2c 20 49 25 2b 31 2c  | = .$buf%, I%+1,|
000016f0  20 4a 25 2d 49 25 29 0d  07 58 0f 20 20 20 c9 20  | J%-I%)..X.   . |
00001700  22 66 69 6c 65 22 0d 07  62 1d 20 20 20 20 66 69  |"file"..b.    fi|
00001710  6c 65 5f 70 74 72 25 20  3d 20 70 74 72 25 20 2b  |le_ptr% = ptr% +|
00001720  20 49 25 0d 07 6c 2b 20  20 20 20 66 69 6c 65 5f  | I%..l+    file_|
00001730  63 6f 6e 66 69 67 24 20  3d 20 c1 24 62 75 66 25  |config$ = .$buf%|
00001740  2c 20 49 25 2b 31 2c 20  4a 25 2d 49 25 29 0d 07  |, I%+1, J%-I%)..|
00001750  76 20 20 20 20 20 24 66  69 6c 65 5f 6e 61 6d 65  |v     $file_name|
00001760  25 3d 66 69 6c 65 5f 63  6f 6e 66 69 67 24 0d 07  |%=file_config$..|
00001770  80 36 20 20 20 20 c8 99  20 22 58 4f 53 5f 43 4c  |.6    .. "XOS_CL|
00001780  49 22 2c 22 73 65 74 20  50 72 69 6e 74 65 72 54  |I","set PrinterT|
00001790  79 70 65 24 35 20 22 2b  66 69 6c 65 5f 63 6f 6e  |ype$5 "+file_con|
000017a0  66 69 67 24 0d 07 8a 14  20 20 20 c9 20 22 70 61  |fig$....   . "pa|
000017b0  67 65 5f 6e 61 6d 65 22  0d 07 94 36 20 20 20 20  |ge_name"...6    |
000017c0  70 61 67 65 5f 6e 61 6d  65 73 24 28 70 61 67 65  |page_names$(page|
000017d0  5f 6e 75 6d 62 65 72 25  29 3d c1 24 62 75 66 25  |_number%)=.$buf%|
000017e0  2c 20 49 25 2b 31 2c 20  4a 25 2d 49 25 29 0d 07  |, I%+1, J%-I%)..|
000017f0  9e 3b 20 20 20 20 70 61  67 65 5f 70 74 72 73 25  |.;    page_ptrs%|
00001800  28 70 61 67 65 5f 6e 75  6d 62 65 72 25 2c 70 61  |(page_number%,pa|
00001810  67 65 5f 6e 61 6d 65 5f  66 69 65 6c 64 25 29 20  |ge_name_field%) |
00001820  3d 20 70 74 72 25 2b 49  25 0d 07 a8 19 20 20 20  |= ptr%+I%....   |
00001830  c9 20 22 70 61 67 65 5f  73 65 6c 65 63 74 69 6f  |. "page_selectio|
00001840  6e 22 0d 07 b2 3a 20 20  20 20 70 61 67 65 5f 73  |n"...:    page_s|
00001850  65 6c 65 63 74 69 6f 6e  24 28 70 61 67 65 5f 6e  |election$(page_n|
00001860  75 6d 62 65 72 25 29 3d  c1 24 62 75 66 25 2c 20  |umber%)=.$buf%, |
00001870  49 25 2b 31 2c 20 4a 25  2d 49 25 29 0d 07 bc 08  |I%+1, J%-I%)....|
00001880  20 20 20 cb 0d 07 c6 1b  20 20 c9 20 22 73 74 61  |   .....  . "sta|
00001890  72 74 5f 70 61 67 65 5f  6e 75 6d 62 65 72 22 0d  |rt_page_number".|
000018a0  07 d0 22 20 20 20 70 61  67 65 5f 6e 75 6d 62 65  |.."   page_numbe|
000018b0  72 5f 63 6f 6e 66 69 67  25 20 3d 20 a4 72 65 61  |r_config% = .rea|
000018c0  64 0d 07 da 23 20 20 20  70 61 67 65 5f 6e 75 6d  |d...#   page_num|
000018d0  62 65 72 5f 70 74 72 25  20 3d 20 70 74 72 25 20  |ber_ptr% = ptr% |
000018e0  2b 20 49 25 0d 07 e4 11  20 20 c9 20 22 70 72 69  |+ I%....  . "pri|
000018f0  6e 74 65 72 22 0d 07 ee  1e 20 20 20 70 72 69 6e  |nter"....   prin|
00001900  74 65 72 5f 63 6f 6e 66  69 67 25 20 3d 20 a4 72  |ter_config% = .r|
00001910  65 61 64 0d 07 f8 25 20  20 20 70 72 69 6e 74 65  |ead...%   printe|
00001920  72 5f 6e 65 77 25 20 3d  20 70 72 69 6e 74 65 72  |r_new% = printer|
00001930  5f 63 6f 6e 66 69 67 25  0d 08 02 1f 20 20 20 70  |_config%....   p|
00001940  72 69 6e 74 65 72 5f 70  74 72 25 20 3d 20 70 74  |rinter_ptr% = pt|
00001950  72 25 20 2b 20 49 25 0d  08 0c 12 20 20 c9 20 22  |r% + I%....  . "|
00001960  6c 6f 63 61 74 69 6f 6e  22 0d 08 16 1f 20 20 20  |location"....   |
00001970  6c 6f 63 61 74 69 6f 6e  5f 63 6f 6e 66 69 67 25  |location_config%|
00001980  20 3d 20 a4 72 65 61 64  0d 08 20 20 20 20 20 6c  | = .read..     l|
00001990  6f 63 61 74 69 6f 6e 5f  70 74 72 25 20 3d 20 70  |ocation_ptr% = p|
000019a0  74 72 25 20 2b 20 49 25  0d 08 2a 0e 20 20 c9 20  |tr% + I%..*.  . |
000019b0  22 62 61 75 64 22 0d 08  34 1b 20 20 20 62 61 75  |"baud"..4.   bau|
000019c0  64 5f 63 6f 6e 66 69 67  25 20 3d 20 a4 72 65 61  |d_config% = .rea|
000019d0  64 0d 08 3e 1c 20 20 20  62 61 75 64 5f 70 74 72  |d..>.   baud_ptr|
000019e0  25 20 3d 20 70 74 72 25  20 2b 20 49 25 0d 08 48  |% = ptr% + I%..H|
000019f0  0e 20 20 c9 20 22 64 61  74 61 22 0d 08 52 1b 20  |.  . "data"..R. |
00001a00  20 20 64 61 74 61 5f 63  6f 6e 66 69 67 25 20 3d  |  data_config% =|
00001a10  20 a4 72 65 61 64 0d 08  5c 1c 20 20 20 64 61 74  | .read..\.   dat|
00001a20  61 5f 70 74 72 25 20 3d  20 70 74 72 25 20 2b 20  |a_ptr% = ptr% + |
00001a30  49 25 0d 08 66 0d 20 20  c9 20 22 78 6f 6e 22 0d  |I%..f.  . "xon".|
00001a40  08 70 1a 20 20 20 58 4f  4e 5f 63 6f 6e 66 69 67  |.p.   XON_config|
00001a50  25 20 3d 20 a4 72 65 61  64 0d 08 7a 1d 20 20 20  |% = .read..z.   |
00001a60  58 4f 4e 5f 6e 65 77 25  20 3d 20 58 4f 4e 5f 63  |XON_new% = XON_c|
00001a70  6f 6e 66 69 67 25 0d 08  84 1b 20 20 20 58 4f 4e  |onfig%....   XON|
00001a80  5f 70 74 72 25 20 3d 20  70 74 72 25 20 2b 20 49  |_ptr% = ptr% + I|
00001a90  25 0d 08 8e 0e 20 20 c9  20 22 6c 69 6e 65 22 0d  |%....  . "line".|
00001aa0  08 98 1b 20 20 20 6c 69  6e 65 5f 63 6f 6e 66 69  |...   line_confi|
00001ab0  67 25 20 3d 20 a4 72 65  61 64 0d 08 a2 1f 20 20  |g% = .read....  |
00001ac0  20 6c 69 6e 65 5f 6e 65  77 25 20 3d 20 6c 69 6e  | line_new% = lin|
00001ad0  65 5f 63 6f 6e 66 69 67  25 0d 08 ac 1c 20 20 20  |e_config%....   |
00001ae0  6c 69 6e 65 5f 70 74 72  25 20 3d 20 70 74 72 25  |line_ptr% = ptr%|
00001af0  20 2b 20 49 25 0d 08 b6  0e 20 20 c9 20 22 6d 6f  | + I%....  . "mo|
00001b00  6e 6f 22 0d 08 c0 1b 20  20 20 6d 6f 6e 6f 5f 63  |no"....   mono_c|
00001b10  6f 6e 66 69 67 25 20 3d  20 a4 72 65 61 64 0d 08  |onfig% = .read..|
00001b20  ca 1f 20 20 20 6d 6f 6e  6f 5f 6e 65 77 25 20 3d  |..   mono_new% =|
00001b30  20 6d 6f 6e 6f 5f 63 6f  6e 66 69 67 25 0d 08 d4  | mono_config%...|
00001b40  1c 20 20 20 6d 6f 6e 6f  5f 70 74 72 25 20 3d 20  |.   mono_ptr% = |
00001b50  70 74 72 25 20 2b 20 49  25 0d 08 de 06 20 cb 0d  |ptr% + I%.... ..|
00001b60  08 e8 05 cd 0d 08 f2 05  e1 0d 08 fc 05 3a 0d 09  |.............:..|
00001b70  06 36 dd a4 72 65 61 64  3d a4 72 65 61 64 5f 69  |.6..read=.read_i|
00001b80  6e 74 65 67 65 72 5f 65  78 70 72 65 73 73 69 6f  |nteger_expressio|
00001b90  6e 28 c2 24 62 75 66 25  2c a9 24 62 75 66 25 2d  |n(.$buf%,.$buf%-|
00001ba0  49 25 29 29 0d 09 10 05  3a 0d 09 1a 2d f4 20 2a  |I%))....:...-. *|
00001bb0  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00001bd0  2a 2a 2a 2a 2a 2a 0d 09  24 24 f4 20 63 6f 6e 76  |******..$$. conv|
00001be0  65 72 74 20 61 20 73 74  72 69 6e 67 20 74 6f 20  |ert a string to |
00001bf0  61 6e 20 69 6e 74 65 67  65 72 0d 09 2e 2d f4 20  |an integer...-. |
00001c00  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00001c20  2a 2a 2a 2a 2a 2a 2a 0d  09 38 21 dd a4 72 65 61  |*******..8!..rea|
00001c30  64 5f 69 6e 74 65 67 65  72 5f 65 78 70 72 65 73  |d_integer_expres|
00001c40  73 69 6f 6e 28 53 24 29  0d 09 42 14 ea 20 52 25  |sion(S$)..B.. R%|
00001c50  2c 20 54 25 2c 20 45 24  2c 20 50 25 0d 09 4c 09  |, T%, E$, P%..L.|
00001c60  45 24 3d 22 22 0d 09 56  1c f4 20 67 65 74 20 72  |E$=""..V.. get r|
00001c70  69 64 20 6f 66 20 61 6e  79 20 63 6f 6d 6d 65 6e  |id of any commen|
00001c80  74 0d 09 60 1f c8 95 20  c0 53 24 2c 31 29 20 3c  |t..`... .S$,1) <|
00001c90  3e 20 22 3b 22 20 80 20  a9 53 24 20 3c 3e 20 30  |> ";" . .S$ <> 0|
00001ca0  0d 09 6a 11 20 45 24 20  2b 3d 20 c0 53 24 2c 31  |..j. E$ += .S$,1|
00001cb0  29 0d 09 74 14 20 53 24  20 3d 20 c2 53 24 2c a9  |)..t. S$ = .S$,.|
00001cc0  53 24 2d 31 29 0d 09 7e  05 ce 0d 09 88 36 c8 99  |S$-1)..~.....6..|
00001cd0  22 58 4f 53 5f 45 76 61  6c 75 61 74 65 45 78 70  |"XOS_EvaluateExp|
00001ce0  72 65 73 73 69 6f 6e 22  2c 45 24 2c 62 75 66 25  |ression",E$,buf%|
00001cf0  2c 32 35 36 20 b8 20 2c  54 25 2c 52 25 3b 50 25  |,256 . ,T%,R%;P%|
00001d00  0d 09 92 40 e7 20 54 25  20 3c 3e 20 30 20 84 20  |...@. T% <> 0 . |
00001d10  28 50 25 20 80 20 31 29  20 85 20 31 30 30 2c 20  |(P% . 1) . 100, |
00001d20  22 49 6e 74 65 67 65 72  20 76 61 6c 75 65 20 6e  |"Integer value n|
00001d30  65 65 64 65 64 20 66 6f  72 20 22 2b 74 61 67 24  |eeded for "+tag$|
00001d40  0d 09 9c 07 3d 52 25 0d  09 a6 05 3a 0d 09 b0 2d  |....=R%....:...-|
00001d50  f4 20 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |. **************|
00001d60  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
00001d70  2a 2a 2a 2a 2a 2a 2a 2a  2a 0d 09 ba 2c f4 20 61  |*********...,. a|
00001d80  6c 6c 6f 77 20 6f 6e 6c  79 20 61 6c 70 68 61 6e  |llow only alphan|
00001d90  75 6d 65 72 69 63 73 20  69 6e 20 74 61 67 20 66  |umerics in tag f|
00001da0  69 65 6c 64 73 0d 09 c4  2d f4 20 2a 2a 2a 2a 2a  |ields...-. *****|
00001db0  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00001dd0  2a 2a 0d 09 ce 11 dd a4  74 61 67 63 68 61 72 28  |**......tagchar(|
00001de0  43 25 29 0d 09 d8 24 e7  20 28 43 25 20 3e 3d 20  |C%)...$. (C% >= |
00001df0  97 22 41 22 20 80 20 43  25 20 3c 3d 20 97 22 5a  |."A" . C% <= ."Z|
00001e00  22 29 20 8c 20 3d b9 0d  09 e2 24 e7 20 28 43 25  |") . =....$. (C%|
00001e10  20 3e 3d 20 97 22 61 22  20 80 20 43 25 20 3c 3d  | >= ."a" . C% <=|
00001e20  20 97 22 7a 22 29 20 8c  20 3d b9 0d 09 ec 2c 3d  | ."z") . =....,=|
00001e30  20 20 28 43 25 20 3e 3d  20 97 22 30 22 20 80 20  |  (C% >= ."0" . |
00001e40  43 25 20 3c 3d 20 97 22  39 22 29 20 84 20 43 25  |C% <= ."9") . C%|
00001e50  20 3d 20 97 22 5f 22 0d  09 f6 05 3a 0d 0a 00 4b  | = ."_"....:...K|
00001e60  f4 20 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |. **************|
00001e70  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00001ea0  2a 2a 2a 2a 2a 2a 2a 0d  0a 0a 4b f4 20 73 65 74  |*******...K. set|
00001eb0  20 74 68 65 20 70 72 69  6e 74 65 72 20 64 72 69  | the printer dri|
00001ec0  76 65 72 20 6d 6f 64 75  6c 65 27 73 20 73 74 61  |ver module's sta|
00001ed0  74 65 20 74 6f 20 72 65  66 6c 65 63 74 20 74 68  |te to reflect th|
00001ee0  65 20 63 75 72 72 65 6e  74 20 73 65 74 74 69 6e  |e current settin|
00001ef0  67 73 0d 0a 14 4b f4 20  2a 2a 2a 2a 2a 2a 2a 2a  |gs...K. ********|
00001f00  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
00001f30  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 0d 0a 1e  |*************...|
00001f40  1d dd f2 50 72 69 6e 74  65 72 5f 73 65 74 5f 6d  |...Printer_set_m|
00001f50  6f 64 75 6c 65 5f 64 61  74 61 0d 0a 28 17 ea 20  |odule_data..(.. |
00001f60  41 25 2c 42 25 2c 43 25  2c 44 25 2c 45 25 2c 46  |A%,B%,C%,D%,E%,F|
00001f70  25 0d 0a 32 1d 41 25 3d  64 65 66 61 75 6c 74 73  |%..2.A%=defaults|
00001f80  25 21 70 78 72 65 73 5f  66 69 65 6c 64 25 0d 0a  |%!pxres_field%..|
00001f90  3c 1d 42 25 3d 64 65 66  61 75 6c 74 73 25 21 70  |<.B%=defaults%!p|
00001fa0  79 72 65 73 5f 66 69 65  6c 64 25 0d 0a 46 20 43  |yres_field%..F C|
00001fb0  25 3d 64 65 66 61 75 6c  74 73 25 21 66 65 61 74  |%=defaults%!feat|
00001fc0  75 72 65 73 5f 66 69 65  6c 64 25 0d 0a 50 26 44  |ures_field%..P&D|
00001fd0  25 3d 64 65 66 61 75 6c  74 73 25 21 70 78 72 65  |%=defaults%!pxre|
00001fe0  73 5f 68 61 6c 66 74 6f  6e 65 5f 66 69 65 6c 64  |s_halftone_field|
00001ff0  25 0d 0a 5a 26 45 25 3d  64 65 66 61 75 6c 74 73  |%..Z&E%=defaults|
00002000  25 21 70 79 72 65 73 5f  68 61 6c 66 74 6f 6e 65  |%!pyres_halftone|
00002010  5f 66 69 65 6c 64 25 0d  0a 64 26 46 25 3d 64 65  |_field%..d&F%=de|
00002020  66 61 75 6c 74 73 25 21  70 72 69 6e 74 65 72 5f  |faults%!printer_|
00002030  6e 75 6d 62 65 72 5f 66  69 65 6c 64 25 0d 0a 6e  |number_field%..n|
00002040  2c c8 99 20 22 50 44 72  69 76 65 72 5f 53 65 74  |,.. "PDriver_Set|
00002050  49 6e 66 6f 22 2c 2c 41  25 2c 42 25 2c 43 25 2c  |Info",,A%,B%,C%,|
00002060  2c 44 25 2c 45 25 2c 46  25 0d 0a 78 0d 6d 73 67  |,D%,E%,F%..x.msg|
00002070  25 21 30 3d 32 30 0d 0a  82 0d 6d 73 67 25 21 31  |%!0=20....msg%!1|
00002080  32 3d 30 0d 0a 8c 1f 6d  73 67 25 21 31 36 3d 4d  |2=0....msg%!16=M|
00002090  65 73 73 61 67 65 5f 53  65 74 50 72 69 6e 74 65  |essage_SetPrinte|
000020a0  72 25 0d 0a 96 26 c8 99  20 22 57 69 6d 70 5f 53  |r%...&.. "Wimp_S|
000020b0  65 6e 64 4d 65 73 73 61  67 65 22 2c 20 31 38 2c  |endMessage", 18,|
000020c0  20 6d 73 67 25 2c 20 30  0d 0a a0 25 64 65 66 61  | msg%, 0...%defa|
000020d0  75 6c 74 73 25 3f 6d 6f  6e 6f 5f 66 69 65 6c 64  |ults%?mono_field|
000020e0  25 20 3d 20 6d 6f 6e 6f  5f 6e 65 77 25 0d 0a aa  |% = mono_new%...|
000020f0  37 c8 99 20 22 50 44 72  69 76 65 72 5f 53 65 74  |7.. "PDriver_Set|
00002100  50 72 69 6e 74 65 72 22  2c 64 65 66 61 75 6c 74  |Printer",default|
00002110  73 25 2b 64 75 6d 70 5f  64 65 70 74 68 5f 66 69  |s%+dump_depth_fi|
00002120  65 6c 64 25 0d 0a b4 05  e1 0d 0a be 05 3a 0d 0a  |eld%.........:..|
00002130  c8 2d f4 20 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |.-. ************|
00002140  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
00002150  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 0d 0a d2 2d f4  |***********...-.|
00002160  20 73 65 74 20 74 68 65  20 64 65 73 63 72 69 70  | set the descrip|
00002170  74 69 6f 6e 20 66 69 65  6c 64 20 69 6e 20 6f 75  |tion field in ou|
00002180  72 20 77 69 6e 64 6f 77  0d 0a dc 2d f4 20 2a 2a  |r window...-. **|
00002190  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
*
000021b0  2a 2a 2a 2a 2a 0d 0a e6  1d dd f2 50 72 69 6e 74  |*****......Print|
000021c0  65 72 5f 73 65 74 5f 64  65 73 63 72 69 70 74 69  |er_set_descripti|
000021d0  6f 6e 0d 0a f0 0c ea 20  53 25 2c 20 53 24 0d 0a  |on..... S%, S$..|
000021e0  fa 27 e3 20 53 25 20 3d  20 30 20 b8 20 70 72 69  |.'. S% = 0 . pri|
000021f0  6e 74 65 72 5f 64 61 74  61 5f 73 69 7a 65 25 2d  |nter_data_size%-|
00002200  34 20 88 20 34 0d 0b 04  28 64 65 66 61 75 6c 74  |4 . 4...(default|
00002210  73 25 21 53 25 20 3d 20  70 72 69 6e 74 65 72 5f  |s%!S% = printer_|
00002220  64 61 74 61 5f 6c 69 73  74 25 21 53 25 0d 0b 0e  |data_list%!S%...|
00002230  05 ed 0d 0b 18 48 f2 50  72 69 6e 74 65 72 5f 73  |.....H.Printer_s|
00002240  65 74 5f 69 63 6f 6e 28  6d 61 69 6e 5f 64 65 73  |et_icon(main_des|
00002250  63 72 69 70 74 69 6f 6e  25 2c 24 28 64 65 66 61  |cription%,$(defa|
00002260  75 6c 74 73 25 21 64 65  73 63 72 69 70 74 69 6f  |ults%!descriptio|
00002270  6e 5f 66 69 65 6c 64 25  29 29 0d 0b 22 4a c8 99  |n_field%)).."J..|
00002280  20 22 58 4f 53 5f 43 4c  49 22 2c 22 53 45 54 20  | "XOS_CLI","SET |
00002290  50 72 69 6e 74 65 72 24  22 2b 22 20 22 22 22 2b  |Printer$"+" """+|
000022a0  24 28 64 65 66 61 75 6c  74 73 25 21 64 65 73 63  |$(defaults%!desc|
000022b0  72 69 70 74 69 6f 6e 5f  66 69 65 6c 64 25 29 2b  |ription_field%)+|
000022c0  22 22 22 22 0d 0b 2c 05  e1 0d 0b 36 05 3a 0d 0b  |""""..,....6.:..|
000022d0  40 1f dd 20 f2 50 72 69  6e 74 65 72 5f 63 68 61  |@.. .Printer_cha|
000022e0  6e 67 65 5f 70 61 67 65  5f 73 69 7a 65 0d 0b 4a  |nge_page_size..J|
000022f0  42 ff 28 22 53 65 74 20  50 44 72 69 76 65 72 24  |B.("Set PDriver$|
00002300  44 4d 65 78 74 72 61 20  22 22 22 2b 70 61 67 65  |DMextra """+page|
00002310  5f 73 65 6c 65 63 74 69  6f 6e 24 28 70 61 67 65  |_selection$(page|
00002320  5f 6e 75 6d 62 65 72 25  29 2b 22 22 22 22 29 0d  |_number%)+"""").|
00002330  0b 54 05 e1 0d 0b 5e 05  3a 0d 0b 68 1d dd f2 50  |.T....^.:..h...P|
00002340  72 69 6e 74 65 72 5f 73  65 74 5f 69 63 6f 6e 28  |rinter_set_icon(|
00002350  49 25 2c 53 24 29 0d 0b  72 08 ea 20 53 25 0d 0b  |I%,S$)..r.. S%..|
00002360  7c 1a 53 25 3d a4 69 63  6f 6e 61 64 64 72 28 6d  ||.S%=.iconaddr(m|
00002370  61 69 6e 25 2c 49 25 29  0d 0b 86 0c 24 53 25 20  |ain%,I%)....$S% |
00002380  3d 20 53 24 0d 0b 90 17  f2 7a 65 72 6f 5f 74 65  |= S$.....zero_te|
00002390  72 6d 69 6e 61 74 65 28  53 25 29 0d 0b 9a 31 f2  |rminate(S%)...1.|
000023a0  73 65 74 5f 69 63 6f 6e  5f 73 74 61 74 65 28 6d  |set_icon_state(m|
000023b0  61 69 6e 25 2c 49 25 2c  30 2c 30 29 3a 20 f4 20  |ain%,I%,0,0): . |
000023c0  66 6f 72 63 65 20 72 65  64 72 61 77 0d 0b a4 05  |force redraw....|
000023d0  e1 0d 0b ae 05 3a 0d 0b  b8 1a dd 20 f2 50 72 69  |.....:..... .Pri|
000023e0  6e 74 65 72 5f 41 6d 65  6e 64 43 6f 6e 66 69 67  |nter_AmendConfig|
000023f0  0d 0b c2 21 e7 20 6c 69  6e 65 5f 63 6f 6e 66 69  |...!. line_confi|
00002400  67 25 20 3c 3e 20 6c 69  6e 65 5f 6e 65 77 25 20  |g% <> line_new% |
00002410  8c 0d 0b cc 1a 20 cf 23  6f 75 74 5f 66 69 6c 65  |..... .#out_file|
00002420  25 3d 6c 69 6e 65 5f 70  74 72 25 0d 0b d6 1c 20  |%=line_ptr%.... |
00002430  d5 23 6f 75 74 5f 66 69  6c 65 25 2c c3 6c 69 6e  |.#out_file%,.lin|
00002440  65 5f 6e 65 77 25 3b 0d  0b e0 1d 20 6c 69 6e 65  |e_new%;.... line|
00002450  5f 63 6f 6e 66 69 67 25  20 3d 20 6c 69 6e 65 5f  |_config% = line_|
00002460  6e 65 77 25 0d 0b ea 05  cd 0d 0b f4 21 e7 20 6d  |new%........!. m|
00002470  6f 6e 6f 5f 63 6f 6e 66  69 67 25 20 3c 3e 20 6d  |ono_config% <> m|
00002480  6f 6e 6f 5f 6e 65 77 25  20 8c 0d 0b fe 1a 20 cf  |ono_new% ..... .|
00002490  23 6f 75 74 5f 66 69 6c  65 25 3d 6d 6f 6e 6f 5f  |#out_file%=mono_|
000024a0  70 74 72 25 0d 0c 08 1c  20 d5 23 6f 75 74 5f 66  |ptr%.... .#out_f|
000024b0  69 6c 65 25 2c c3 6d 6f  6e 6f 5f 6e 65 77 25 3b  |ile%,.mono_new%;|
000024c0  0d 0c 12 1d 20 6d 6f 6e  6f 5f 63 6f 6e 66 69 67  |.... mono_config|
000024d0  25 20 3d 20 6d 6f 6e 6f  5f 6e 65 77 25 0d 0c 1c  |% = mono_new%...|
000024e0  05 cd 0d 0c 26 05 e1 0d  0c 30 05 3a 0d 0c 3a 15  |....&....0.:..:.|
000024f0  dd 20 f2 50 72 69 6e 74  65 72 5f 49 67 6e 6f 72  |. .Printer_Ignor|
00002500  65 0d 0c 44 05 e1 0d 0c  4e 05 3a 0d 0c 58 1d dd  |e..D....N.:..X..|
00002510  20 f2 50 72 69 6e 74 65  72 5f 58 6f 6e 58 6f 66  | .Printer_XonXof|
00002520  66 28 66 6c 61 67 25 29  0d 0c 62 0d e7 20 66 6c  |f(flag%)..b.. fl|
00002530  61 67 25 20 8c 0d 0c 6c  0c 20 2a 66 78 20 32 2c  |ag% ...l. *fx 2,|
00002540  32 0d 0c 76 05 cc 0d 0c  80 0c 20 2a 66 78 20 32  |2..v...... *fx 2|
00002550  2c 30 0d 0c 8a 05 cd 0d  0c 94 05 e1 0d 0c 9e 05  |,0..............|
00002560  3a 0d 0c a8 1d dd 20 f2  50 72 69 6e 74 65 72 5f  |:..... .Printer_|
00002570  4c 6f 63 61 74 69 6f 6e  28 6c 6f 63 25 29 0d 0c  |Location(loc%)..|
00002580  b2 4d f4 20 54 68 65 20  63 75 72 72 65 6e 74 20  |.M. The current |
00002590  70 72 69 6e 74 65 72 20  6c 6f 63 61 74 69 6f 6e  |printer location|
000025a0  20 73 65 74 74 69 6e 67  20 64 6f 65 73 6e 27 74  | setting doesn't|
000025b0  20 61 66 66 65 63 74 20  74 68 69 73 20 70 72 69  | affect this pri|
000025c0  6e 74 65 72 20 64 72 69  76 65 72 0d 0c bc 05 e1  |nter driver.....|
000025d0  0d 0c c6 05 3a 0d 0c d0  15 dd 20 f2 50 72 69 6e  |....:..... .Prin|
000025e0  74 65 72 5f 48 65 61 64  65 72 0d 0c da 19 6c 69  |ter_Header....li|
000025f0  6e 65 5f 70 72 69 6e 74  25 3d 6c 69 6e 65 5f 6e  |ne_print%=line_n|
00002600  65 77 25 0d 0c e4 14 60  65 78 74 25 3d a2 23 69  |ew%....`ext%=.#i|
00002610  6e 5f 66 69 6c 65 25 0d  0c ee 05 e1 0d 0c f8 05  |n_file%.........|
00002620  3a 0d 0d 02 15 dd 20 f2  50 72 69 6e 74 65 72 5f  |:..... .Printer_|
00002630  46 6f 6f 74 65 72 0d 0d  0c 05 e1 0d 0d 16 05 3a  |Footer.........:|
00002640  0d 0d 20 19 dd 20 a4 50  72 69 6e 74 65 72 5f 53  |.. .. .Printer_S|
00002650  65 6e 64 28 6c 65 6e 25  29 0d 0d 2a 0a f2 45 73  |end(len%)..*..Es|
00002660  63 4f 6e 0d 0d 34 0b ea  20 4c 25 2c 43 25 0d 0d  |cOn..4.. L%,C%..|
00002670  3e 19 4c 25 3d 60 65 78  74 25 20 2d 20 8f 23 69  |>.L%=`ext% - .#i|
00002680  6e 5f 66 69 6c 65 25 0d  0d 48 29 e7 20 6c 69 6e  |n_file%..H). lin|
00002690  65 5f 70 72 69 6e 74 25  20 80 20 46 74 79 70 65  |e_print% . Ftype|
000026a0  25 3c 3e 4f 75 74 70 75  74 54 79 70 65 25 20 8c  |%<>OutputType% .|
000026b0  0d 0d 52 15 20 c8 95 20  6c 65 6e 25 3e 31 20 80  |..R. .. len%>1 .|
000026c0  20 4c 25 3e 30 0d 0d 5c  1a 20 20 43 25 3d 9a 23  | L%>0..\.  C%=.#|
000026d0  69 6e 5f 66 69 6c 65 25  3a 20 4c 25 2d 3d 31 0d  |in_file%: L%-=1.|
000026e0  0d 66 24 20 20 e7 20 43  25 3d 31 30 20 d5 23 6f  |.f$  . C%=10 .#o|
000026f0  75 74 5f 66 69 6c 65 25  2c 31 33 3a 6c 65 6e 25  |ut_file%,13:len%|
00002700  2d 3d 31 0d 0d 70 1c 20  20 d5 23 6f 75 74 5f 66  |-=1..p.  .#out_f|
00002710  69 6c 65 25 2c 43 25 3a  6c 65 6e 25 2d 3d 31 0d  |ile%,C%:len%-=1.|
00002720  0d 7a 24 20 20 e7 20 43  25 3d 31 33 20 d5 23 6f  |.z$  . C%=13 .#o|
00002730  75 74 5f 66 69 6c 65 25  2c 31 30 3a 6c 65 6e 25  |ut_file%,10:len%|
00002740  2d 3d 31 0d 0d 84 06 20  ce 0d 0d 8e 05 cc 0d 0d  |-=1.... ........|
00002750  98 17 20 e7 20 6c 65 6e  25 3e 3d 4c 25 20 6c 65  |.. . len%>=L% le|
00002760  6e 25 3d 4c 25 0d 0d a2  34 20 c8 99 20 22 4f 53  |n%=L%...4 .. "OS|
00002770  5f 47 42 50 42 22 2c 20  34 2c 20 69 6e 5f 66 69  |_GBPB", 4, in_fi|
00002780  6c 65 25 2c 20 62 75 66  25 2c 20 6c 65 6e 25 3a  |le%, buf%, len%:|
00002790  20 4c 25 2d 3d 6c 65 6e  25 0d 0d ac 2b 20 c8 99  | L%-=len%...+ ..|
000027a0  20 22 4f 53 5f 47 42 50  42 22 2c 20 32 2c 20 6f  | "OS_GBPB", 2, o|
000027b0  75 74 5f 66 69 6c 65 25  2c 20 62 75 66 25 2c 20  |ut_file%, buf%, |
000027c0  6c 65 6e 25 0d 0d b6 05  cd 0d 0d c0 0b f2 45 73  |len%..........Es|
000027d0  63 4f 66 66 0d 0d ca 0c  3d 28 4c 25 3c 3d 30 29  |cOff....=(L%<=0)|
000027e0  0d 0d d4 0e 3e 2a 46 58  20 32 32 39 2c 31 0d ff  |....>*FX 229,1..|
000027f0
!PrinterDM/Library.m0
!PrinterDM/Library.m1
!PrinterDM/Library.m2
!PrinterDM/Library.m4
!PrinterDM/Library.m5