Home » Recent acquisitions » Acorn ADFS disks » adfs_ArchimedesWorld_199201.adf » January92 » !AWJan92/Goodies/IconFlags/!Iflags/!RunImage

!AWJan92/Goodies/IconFlags/!Iflags/!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 » Recent acquisitions » Acorn ADFS disks » adfs_ArchimedesWorld_199201.adf » January92
Filename: !AWJan92/Goodies/IconFlags/!Iflags/!RunImage
Read OK:
File size: 21AD bytes
Load address: 0000
Exec address: 0000
File contents
   10REM >$.!Iflags.!RunImage
   20
   30DIM q% 5000
   40DIM icon% 3000
   50extent%=icon%-1
   60DIM menu_menu% 2000
   70DIM menu_buffer% 200
   80DIM task% 4
   90DIM buffer% 12
  100$buffer%=""
  110
  120ON ERROR PROCerror
  130
  140alias$="<Iflags$Dir>"
  150$task%="TASK"
  160SYS "Wimp_Initialise",200,!task%,"Iflags" TO ,handle%
  170PROCsprites(alias$+".!Sprites")
  180iconh%=FNiconbar("!iflags")
  190info%=FNtemplates(alias$+".Templates")
  200zero$="00000000"
  210i%=0
  220esg%=0
  230forecol%=0
  240backcol%=0
  250PROCset_flagnum(i%)
  260PROCesg
  270PROCforcol
  280PROCbackcol
  290
  300bar0=FNmakemen("Icon Flags�[info%].Info�.Quit�")
  310menu0=FNmakemen("Main Menu�[info%].Info�[flag%].Flag Number�.Quit�")
  320
  330exit%=FALSE
  340mask%=%11100001100000110001
  350REPEAT
  360SYS"Wimp_Poll",,q% TO reason%
  370CASE reason% OF
  380  WHEN 2 : PROCopen_window
  390  WHEN 3 : PROCclose_window
  400  WHEN 6 : PROCmouse_click(q%!0,q%!4,q%!8,q%!12,q%!16)
  410  WHEN 8 : PROCkey_press(q%!0,q%!4,q%!24)
  420  WHEN 9 : PROCmenu_select(q%!0,q%!4)
  430ENDCASE
  440UNTIL exit%
  450SYS"Wimp_CloseDown",handle%,!task%
  460END
  470
  480DEF PROCkey_press(wh%,ih%,chr%)
  490  CASE chr% OF
  500    WHEN 13 :
  510      CASE wh% OF
  520        WHEN flag% :
  530          CASE ih% OF
  540            WHEN 0 : PROCget_num
  550          ENDCASE
  560      ENDCASE
  570  ENDCASE
  580ENDPROC
  590
  600DEF PROCmouse_click(xpos%,ypos%,button%,wh%,ih%)
  610CASE wh% OF
  620  WHEN -2 :
  630    CASE button% OF
  640      WHEN 2 : SYS"Wimp_CreateMenu",,bar0,xpos%-80,184:open%=0
  650      OTHERWISE PROCcreate_window
  660    ENDCASE
  670  WHEN main% :
  680    CASE button% OF
  690      WHEN 2 : SYS"Wimp_CreateMenu",,menu0,xpos%-100,ypos%+16:open%=1
  700    ENDCASE
  710    CASE ih% OF
  720      WHEN 0,1,2,3,4,5,6,7,8,9,10,11,21,22,23  : PROCcheck(wh%,ih%)
  730      WHEN 12,13,14,15 : PROCcheck(wh%,ih%):PROCbuttsel
  740      WHEN 16,17,18,19,20 : PROCcheck(wh%,ih%):PROCesg
  750      WHEN 24,25,26,27 : PROCcheck(wh%,ih%):PROCforcol
  760      WHEN 28,29,30,31 : PROCcheck(wh%,ih%):PROCbackcol
  770    ENDCASE
  780ENDCASE
  790ENDPROC
  800
  810DEF PROCmenu_select(select%,select1%)
  820SYS"Wimp_GetPointerInfo",,q%
  830stay%=(q%!8=1)
  840CASE open% OF
  850  WHEN 0 :
  860    CASE select% OF
  870      WHEN 1 : exit%=TRUE
  880    ENDCASE
  890  WHEN 1 :
  900    CASE select% OF
  910      WHEN 2 : exit%=TRUE
  920    ENDCASE
  930ENDCASE
  940IF stay% AND open%=0 SYS"Wimp_CreateMenu",,bar0,xpos%-80,184:open%=0
  950IF stay% AND open%=1 SYS"Wimp_CreateMenu",,menu0,xpos%-100,ypos%+16:open%=1
  960ENDPROC
  970
  980DEF PROCcreate_window
  990q%!0=main%
 1000q%!4=0
 1010q%!8=216
 1020q%!12=1236
 1030q%!16=1024
 1040q%!20=0
 1050q%!24=0
 1060q%!28=-1
 1070SYS "Wimp_OpenWindow",,q%
 1080PROCbuttsel
 1090ENDPROC
 1100
 1110DEF FNiconbar(spname$)
 1120q%!0=-1
 1130q%!4=0
 1140q%!8=0
 1150q%!12=63
 1160q%!16=64
 1170q%!20=&2102
 1180DIM q%!24 (LENspname$+1)
 1190$(q%!24)=spname$
 1200q%!28=sprite%
 1210q%!32=(LENspname$+1)
 1220SYS "Wimp_CreateIcon",,q% TO iconb%
 1230=iconb%
 1240
 1250DEF PROCsprites(file$)
 1260sp=OPENIN(file$)
 1270dim%=EXT#sp+16
 1280CLOSE#sp
 1290DIM sprite% dim%
 1300sprite%!0=dim%
 1310sprite%!4=0
 1320sprite%!8=16
 1330sprite%!12=16
 1340SYS "OS_SpriteOp",256+10,sprite%,file$
 1350ENDPROC
 1360
 1370DEF FNtemplates(file$)
 1380SYS "Wimp_OpenTemplate",,file$
 1390SYS "Wimp_LoadTemplate",,q%,icon%,icon%+extent%,-1,"info",0 TO ,,next%
 1400SYS "Wimp_CreateWindow",,q% TO info%
 1410SYS "Wimp_LoadTemplate",,q%,next%,icon%+extent%,-1,"flag",0 TO ,,next%
 1420SYS "Wimp_CreateWindow",,q% TO flag%
 1430SYS "Wimp_LoadTemplate",,q%,next%,icon%+extent%,-1,"main",0 TO ,,next%
 1440SYS "Wimp_CreateWindow",,q% TO main%
 1450SYS "Wimp_CloseTemplate"
 1460=info%
 1470
 1480DEF PROCclose_window
 1490q%!0=main%
 1500SYS "Wimp_CloseWindow",,q%
 1510ENDPROC
 1520:
 1530DEF PROCopen_window
 1540SYS "Wimp_OpenWindow",,q%
 1550ENDPROC
 1560
 1570DEF PROCerror
 1580SYS "Wimp_DragBox",,0
 1590q%!0=ERR
 1600error=TRUE
 1610CASE ERR OF
 1620  WHEN 222 : $(q%+4)="This file does not exist"+CHR$0:error=FALSE
 1630  OTHERWISE
 1640  $(q%+4)="(Internal error code "+STR$(ERL)+") "+REPORT$+CHR$0
 1650ENDCASE
 1660flags=1
 1670SYS "Wimp_ReportError",q%,flags,"!Iflags"
 1680ENDPROC
 1690
 1700DEF FNmakemen(menu_menu$)
 1710menu_menuptr%=0:menu_m%=menu_menu%
 1720menu_title$=LEFT$(menu_menu$,INSTR(menu_menu$,"�")-1)
 1730menu_menu$=RIGHT$(menu_menu$,LEN(menu_menu$)-INSTR(menu_menu$,"�"))
 1740menu_max%=0
 1750$menu_menu%=menu_title$
 1760menu_menu%?12=7
 1770menu_menu%?13=2
 1780menu_menu%?14=7
 1790menu_menu%?15=0
 1800menu_menu%!20=44
 1810menu_menu%!24=0
 1820menu_menu%+=28
 1830menu_menuptr%+=28
 1840WHILE menu_menu$<>""
 1850menu_text$=LEFT$(menu_menu$,INSTR(menu_menu$,"�")-1)
 1860menu_menu$=RIGHT$(menu_menu$,LEN(menu_menu$)-INSTR(menu_menu$,"�"))
 1870menu_tick%=INSTR(menu_text$,"!")
 1880menu_dots%=INSTR(menu_text$,"-")
 1890menu_write%=INSTR(menu_text$,"?")
 1900menu_shade%=INSTR(menu_text$,"@")
 1910menu_sub%=INSTR(menu_text$,"[")
 1920menu_last%=INSTR(menu_text$,"#")
 1930menu_t1$=RIGHT$(menu_text$,LEN(menu_text$)-INSTR(menu_text$,"."))
 1940menu_text$=LEFT$(menu_text$,INSTR(menu_text$,".")-1)
 1950menu_mi%=0
 1960IF menu_tick%>0 THEN menu_mi%=menu_mi% OR 1
 1970IF menu_dots%>0 THEN menu_mi%=menu_mi% OR 2
 1980IF menu_write%>0 THEN menu_mi%=menu_mi% OR 4
 1990IF menu_menu$="" THEN menu_mi%=menu_mi% OR 128
 2000IF menu_sub%>0 THEN
 2010menu_lbrack%=menu_sub%+1
 2020menu_rbrack%=INSTR(menu_text$,"]")
 2030menu_p%=EVAL(MID$(menu_text$,menu_lbrack%,menu_rbrack%-menu_lbrack%))
 2040ENDIF
 2050menu_ii%=%00000111000000000000000100110001
 2060IF menu_shade%>0 menu_ii%+=(1<<22)
 2070!menu_menu%=menu_mi%
 2080IF menu_sub%>0 THEN
 2090menu_menu%!4=menu_p%
 2100ELSE
 2110menu_menu%!4=0
 2120ENDIF
 2130menu_menu%!8=menu_ii%
 2140IF menu_write%>0 THEN
 2150menu_val%=EVAL(MID$(menu_text$,(INSTR(menu_text$,"?")+1),INSTR(menu_text$,",")-INSTR(menu_text$,"?")-1))
 2160menu_menu%!12=menu_val%
 2170menu_menu%!16=-1
 2180menu_len%=EVAL(MID$(menu_text$,INSTR(menu_text$,",")+1,INSTR(menu_text$,".")-INSTR(menu_text$,",")-1))
 2190menu_menu%!20=menu_len%
 2200ENDIF
 2210IF menu_write%=0 THEN
 2220menu_menu%!12=menu_buffer%
 2230menu_menu%!16=-1
 2240menu_menu%!20=LEN(menu_t1$)+1
 2250$(menu_buffer%)=menu_t1$
 2260menu_buffer%+=LEN(menu_t1$)+1
 2270ENDIF
 2280IF LEN(menu_t1$)>menu_max% menu_max%=LENmenu_t1$
 2290IF menu_max%<LENmenu_title$ menu_max%=LENmenu_title$
 2300menu_menuptr%+=24
 2310menu_menu%+=24
 2320ENDWHILE
 2330menu_m%!16=menu_max%*16+32
 2340=menu_menu%-menu_menuptr%
 2350
 2360DEF PROCcheck(wh%,inum%)
 2370i%=(i% EOR (1<<inum%))
 2380IF (i% AND (1<<inum%))=2^inum%:PROCset_icon(wh%,inum%)
 2390IF (i% AND (1<<inum%))=-(2^31):PROCset_icon(wh%,inum%)
 2400IF (i% AND (1<<inum%))=0:PROCreset_icon(wh%,inum%)
 2410PROCset_flagnum(i%)
 2420ENDPROC
 2430
 2440DEF PROCset_flagnum(i%)
 2450q%!0=main%
 2460q%!4=37
 2470SYS"Wimp_GetIconState",,q%
 2480q%!8=1<<0
 2490q%!12=1<<0
 2500option$=STR$~i%
 2510l%=LEN(option$)
 2520opt$="&"+LEFT$(zero$,8-l%)+option$
 2530$(q%!28)=opt$
 2540q%!36=LEN(opt$)
 2550SYS"Wimp_SetIconState",,q%
 2560ENDPROC
 2570
 2580DEF PROCget_num
 2590SYS "Wimp_CreateMenu",,-1
 2600q%!0=flag%
 2610q%!4=0
 2620SYS"Wimp_GetIconState",,q%
 2630a$=$(q%!28)
 2640IF a$="" a$="00000000"
 2650a$="&"+a$
 2660i%=EVAL(a$)
 2670FOR a%=0 TO 30
 2680IF (i% AND (1<<a%))=2^a% PROCset_icon(main%,a%) ELSE PROCreset_icon(main%,a%)
 2690NEXT
 2700IF (i% AND (1<<31))=-(2^31) PROCset_icon(main%,a%) ELSE PROCreset_icon(main%,a%)
 2710PROCset_flagnum(EVAL(a$))
 2720PROCforcol
 2730PROCbackcol
 2740PROCesg
 2750PROCbuttsel
 2760q%!0=flag%
 2770q%!4=0
 2780SYS"Wimp_GetIconState",,q%
 2790q%!8=1<<1
 2800q%!12=1<<1
 2810option$=""
 2820$(q%!28)=option$
 2830SYS"Wimp_SetIconState",,q%
 2840q%!0=flag%
 2850SYS "Wimp_CloseWindow",,q%
 2860ENDPROC
 2870
 2880DEF PROCset_icon(wh%,ih%)
 2890q%!0=wh%
 2900q%!4=ih%
 2910SYS"Wimp_GetIconState",,q%
 2920q%!8=1<<21
 2930q%!12=1<<21
 2940option$="sbopton,bopton"
 2950$(q%!32)=option$
 2960q%!36=LEN(option$)
 2970SYS"Wimp_SetIconState",,q%
 2980ENDPROC
 2990
 3000DEF PROCreset_icon(wh%,ih%)
 3010q%!0=wh%
 3020q%!4=ih%
 3030SYS"Wimp_GetIconState",,q%
 3040q%!8=1<<21
 3050q%!12=1<<21
 3060option$="sboptoff,boptoff"
 3070$(q%!32)=option$
 3080q%!36=LEN(option$)
 3090SYS"Wimp_SetIconState",,q%
 3100ENDPROC
 3110
 3120DEF PROCforcol
 3130forecol%=0
 3140IF (i% AND (1<<24))=2^24 forecol%+=1
 3150IF (i% AND (1<<25))=2^25 forecol%+=2
 3160IF (i% AND (1<<26))=2^26 forecol%+=4
 3170IF (i% AND (1<<27))=2^27 forecol%+=8
 3180q%!0=main%
 3190q%!4=35
 3200q%!8=forecol%<<28
 3210q%!12=%1111<<28
 3220SYS"Wimp_SetIconState",,q%
 3230ENDPROC
 3240
 3250DEF PROCbackcol
 3260backcol%=0
 3270IF (i% AND (1<<28))=2^28 backcol%+=1
 3280IF (i% AND (1<<29))=2^29 backcol%+=2
 3290IF (i% AND (1<<30))=2^30 backcol%+=4
 3300IF (i% AND (1<<31))=-(2^31) backcol%+=8
 3310q%!0=main%
 3320q%!4=36
 3330q%!8=backcol%<<28
 3340q%!12=%1111<<28
 3350SYS"Wimp_SetIconState",,q%
 3360ENDPROC
 3370
 3380DEF PROCesg
 3390esg%=0
 3400IF (i% AND (1<<16))=2^16 esg%+=1
 3410IF (i% AND (1<<17))=2^17 esg%+=2
 3420IF (i% AND (1<<18))=2^18 esg%+=4
 3430IF (i% AND (1<<19))=2^19 esg%+=8
 3440IF (i% AND (1<<20))=2^20 esg%+=16
 3450q%!0=main%
 3460q%!4=34
 3470SYS"Wimp_GetIconState",,q%
 3480q%!8=1<<0
 3490q%!12=1<<0
 3500option$=STR$(esg%)
 3510$(q%!28)=option$
 3520q%!36=LEN(option$)
 3530SYS"Wimp_SetIconState",,q%
 3540ENDPROC
 3550
 3560DEF PROCbuttsel
 3570butnum%=0
 3580IF (i% AND (1<<12))=2^12 butnum%+=1
 3590IF (i% AND (1<<13))=2^13 butnum%+=2
 3600IF (i% AND (1<<14))=2^14 butnum%+=4
 3610IF (i% AND (1<<15))=2^15 butnum%+=8
 3620PROCbuttons(butnum%):READ a$:a$=STR$(butnum%)+"  "+a$
 3630q%!0=main%
 3640q%!4=33
 3650SYS"Wimp_GetIconState",,q%
 3660q%!8=1<<0
 3670q%!12=1<<0
 3680option$=a$
 3690$(q%!28)=option$
 3700q%!36=LEN(option$)
 3710SYS"Wimp_SetIconState",,q%
 3720ENDPROC
 3730
 3740DEF PROCbuttons(type%)
 3750RESTORE +(type%+1)
 3760DATA "Never"
 3770DATA "Always"
 3780DATA "Auto repeat"
 3790DATA "Click"
 3800DATA "Release"
 3810DATA "Double Click"
 3820DATA "Click/Drag"
 3830DATA "Release/Drag"
 3840DATA "Double/Drag"
 3850DATA "Menu Icon"
 3860DATA "Double/Click/Drag"
 3870DATA "Reserved"
 3880DATA "Reserved"
 3890DATA "Reserved"
 3900DATA "Write/Click/Drag"
 3910DATA "Writeable"
 3920ENDPROC

� >$.!Iflags.!RunImage


� q% 5000
(� icon% 3000
2extent%=icon%-1
<� menu_menu% 2000
F� menu_buffer% 200
P
� task% 4
Z� buffer% 12
d$buffer%=""
n
x� � �error
�
�alias$="<Iflags$Dir>"
�$task%="TASK"
�7ș "Wimp_Initialise",200,!task%,"Iflags" � ,handle%
� �sprites(alias$+".!Sprites")
�iconh%=�iconbar("!iflags")
�)info%=�templates(alias$+".Templates")
�zero$="00000000"
�i%=0
�
esg%=0
�forecol%=0
�backcol%=0
��set_flagnum(i%)
�esg
�forcol
�backcol
"
,3bar0=�makemen("Icon Flags�[info%].Info�.Quit�")
6Gmenu0=�makemen("Main Menu�[info%].Info�[flag%].Flag Number�.Quit�")
@
Jexit%=�
Tmask%=%11100001100000110001
^�
hș"Wimp_Poll",,q% � reason%
rȎ reason% �
|  � 2 : �open_window
�  � 3 : �close_window
�4  � 6 : �mouse_click(q%!0,q%!4,q%!8,q%!12,q%!16)
�'  � 8 : �key_press(q%!0,q%!4,q%!24)
�#  � 9 : �menu_select(q%!0,q%!4)
��
�� exit%
�%ș"Wimp_CloseDown",handle%,!task%
��
�
�� �key_press(wh%,ih%,chr%)
�  Ȏ chr% �
�    � 13 :
�      Ȏ wh% �
        � flag% :
          Ȏ ih% �
            � 0 : �get_num
&          �
0      �
:  �
D�
N
X/� �mouse_click(xpos%,ypos%,button%,wh%,ih%)
bȎ wh% �
l  � -2 :
v    Ȏ button% �
�>      � 2 : ș"Wimp_CreateMenu",,bar0,xpos%-80,184:open%=0
�       �create_window
�	    �
�  � main% :
�    Ȏ button% �
�E      � 2 : ș"Wimp_CreateMenu",,menu0,xpos%-100,ypos%+16:open%=1
�	    �
�    Ȏ ih% �
�A      � 0,1,2,3,4,5,6,7,8,9,10,11,21,22,23  : �check(wh%,ih%)
�2      � 12,13,14,15 : �check(wh%,ih%):�buttsel
�1      � 16,17,18,19,20 : �check(wh%,ih%):�esg
�1      � 24,25,26,27 : �check(wh%,ih%):�forcol
�2      � 28,29,30,31 : �check(wh%,ih%):�backcol
	    �
�
�
 
*$� �menu_select(select%,select1%)
4ș"Wimp_GetPointerInfo",,q%
>stay%=(q%!8=1)
HȎ open% �
R  � 0 :
\    Ȏ select% �
f      � 1 : exit%=�
p	    �
z  � 1 :
�    Ȏ select% �
�      � 2 : exit%=�
�	    �
��
�D� stay% � open%=0 ș"Wimp_CreateMenu",,bar0,xpos%-80,184:open%=0
�K� stay% � open%=1 ș"Wimp_CreateMenu",,menu0,xpos%-100,ypos%+16:open%=1
��
�
�� �create_window
�q%!0=main%
�
q%!4=0
�q%!8=216
�q%!12=1236
q%!16=1024
q%!20=0
q%!24=0
$q%!28=-1
.ș "Wimp_OpenWindow",,q%
8�buttsel
B�
L
V� �iconbar(spname$)
`q%!0=-1
j
q%!4=0
t
q%!8=0
~q%!12=63
�q%!16=64
�q%!20=&2102
�� q%!24 (�spname$+1)
�$(q%!24)=spname$
�q%!28=sprite%
�q%!32=(�spname$+1)
�%ș "Wimp_CreateIcon",,q% � iconb%
�=iconb%
�
�� �sprites(file$)
�sp=�(file$)
�dim%=�#sp+16
�#sp

� sprite% dim%
sprite%!0=dim%
sprite%!4=0
(sprite%!8=16
2sprite%!12=16
<)ș "OS_SpriteOp",256+10,sprite%,file$
F�
P
Z� �templates(file$)
d!ș "Wimp_OpenTemplate",,file$
nHș "Wimp_LoadTemplate",,q%,icon%,icon%+extent%,-1,"info",0 � ,,next%
x&ș "Wimp_CreateWindow",,q% � info%
�Hș "Wimp_LoadTemplate",,q%,next%,icon%+extent%,-1,"flag",0 � ,,next%
�&ș "Wimp_CreateWindow",,q% � flag%
�Hș "Wimp_LoadTemplate",,q%,next%,icon%+extent%,-1,"main",0 � ,,next%
�&ș "Wimp_CreateWindow",,q% � main%
�ș "Wimp_CloseTemplate"
�
=info%
�
�� �close_window
�q%!0=main%
�ș "Wimp_CloseWindow",,q%
��
�:
�� �open_window
ș "Wimp_OpenWindow",,q%
�

"� �error
,ș "Wimp_DragBox",,0
6
q%!0=�
@error=�
J
Ȏ � �
T;  � 222 : $(q%+4)="This file does not exist"+�0:error=�
^  
h5  $(q%+4)="(Internal error code "+�(�)+") "+�$+�0
r�
|flags=1
�,ș "Wimp_ReportError",q%,flags,"!Iflags"
��
�
�� �makemen(menu_menu$)
�&menu_menuptr%=0:menu_m%=menu_menu%
�/menu_title$=�menu_menu$,�menu_menu$,"�")-1)
�:menu_menu$=�menu_menu$,�(menu_menu$)-�menu_menu$,"�"))
�menu_max%=0
�$menu_menu%=menu_title$
�menu_menu%?12=7
�menu_menu%?13=2
�menu_menu%?14=7
�menu_menu%?15=0
menu_menu%!20=44
menu_menu%!24=0
menu_menu%+=28
&menu_menuptr%+=28
0ȕ menu_menu$<>""
:.menu_text$=�menu_menu$,�menu_menu$,"�")-1)
D:menu_menu$=�menu_menu$,�(menu_menu$)-�menu_menu$,"�"))
Nmenu_tick%=�menu_text$,"!")
Xmenu_dots%=�menu_text$,"-")
b menu_write%=�menu_text$,"?")
l menu_shade%=�menu_text$,"@")
vmenu_sub%=�menu_text$,"[")
�menu_last%=�menu_text$,"#")
�8menu_t1$=�menu_text$,�(menu_text$)-�menu_text$,"."))
�.menu_text$=�menu_text$,�menu_text$,".")-1)
�menu_mi%=0
�*� menu_tick%>0 � menu_mi%=menu_mi% � 1
�*� menu_dots%>0 � menu_mi%=menu_mi% � 2
�+� menu_write%>0 � menu_mi%=menu_mi% � 4
�-� menu_menu$="" � menu_mi%=menu_mi% � 128
�� menu_sub%>0 �
�menu_lbrack%=menu_sub%+1
�!menu_rbrack%=�menu_text$,"]")
�Bmenu_p%=�(�menu_text$,menu_lbrack%,menu_rbrack%-menu_lbrack%))
��
.menu_ii%=%00000111000000000000000100110001
%� menu_shade%>0 menu_ii%+=(1<<22)
!menu_menu%=menu_mi%
 � menu_sub%>0 �
*menu_menu%!4=menu_p%
4�
>menu_menu%!4=0
H�
Rmenu_menu%!8=menu_ii%
\� menu_write%>0 �
fVmenu_val%=�(�menu_text$,(�menu_text$,"?")+1),�menu_text$,",")-�menu_text$,"?")-1))
pmenu_menu%!12=menu_val%
zmenu_menu%!16=-1
�Tmenu_len%=�(�menu_text$,�menu_text$,",")+1,�menu_text$,".")-�menu_text$,",")-1))
�menu_menu%!20=menu_len%
��
�� menu_write%=0 �
�menu_menu%!12=menu_buffer%
�menu_menu%!16=-1
�menu_menu%!20=�(menu_t1$)+1
�$(menu_buffer%)=menu_t1$
�menu_buffer%+=�(menu_t1$)+1
��
�/� �(menu_t1$)>menu_max% menu_max%=�menu_t1$
�3� menu_max%<�menu_title$ menu_max%=�menu_title$
�menu_menuptr%+=24
	menu_menu%+=24
	�
	menu_m%!16=menu_max%*16+32
	$=menu_menu%-menu_menuptr%
	.
	8� �check(wh%,inum%)
	Bi%=(i% � (1<<inum%))
	L4� (i% � (1<<inum%))=2^inum%:�set_icon(wh%,inum%)
	V4� (i% � (1<<inum%))=-(2^31):�set_icon(wh%,inum%)
	`0� (i% � (1<<inum%))=0:�reset_icon(wh%,inum%)
	j�set_flagnum(i%)
	t�
	~
	�� �set_flagnum(i%)
	�q%!0=main%
	�q%!4=37
	�ș"Wimp_GetIconState",,q%
	�
q%!8=1<<0
	�q%!12=1<<0
	�option$=�~i%
	�l%=�(option$)
	�!opt$="&"+�zero$,8-l%)+option$
	�$(q%!28)=opt$
	�q%!36=�(opt$)
	�ș"Wimp_SetIconState",,q%
�


� �get_num
ș "Wimp_CreateMenu",,-1
(q%!0=flag%
2
q%!4=0
<ș"Wimp_GetIconState",,q%
Fa$=$(q%!28)
P� a$="" a$="00000000"
Z
a$="&"+a$
di%=�(a$)
n� a%=0 � 30
xE� (i% � (1<<a%))=2^a% �set_icon(main%,a%) � �reset_icon(main%,a%)
��
�H� (i% � (1<<31))=-(2^31) �set_icon(main%,a%) � �reset_icon(main%,a%)
��set_flagnum(�(a$))
��forcol
��backcol
��esg
��buttsel
�q%!0=flag%
�
q%!4=0
�ș"Wimp_GetIconState",,q%
�
q%!8=1<<1
�q%!12=1<<1
�option$=""
$(q%!28)=option$
ș"Wimp_SetIconState",,q%
q%!0=flag%
"ș "Wimp_CloseWindow",,q%
,�
6
@� �set_icon(wh%,ih%)
Jq%!0=wh%
Tq%!4=ih%
^ș"Wimp_GetIconState",,q%
hq%!8=1<<21
rq%!12=1<<21
|option$="sbopton,bopton"
�$(q%!32)=option$
�q%!36=�(option$)
�ș"Wimp_SetIconState",,q%
��
�
�� �reset_icon(wh%,ih%)
�q%!0=wh%
�q%!4=ih%
�ș"Wimp_GetIconState",,q%
�q%!8=1<<21
�q%!12=1<<21
�option$="sboptoff,boptoff"
�$(q%!32)=option$
q%!36=�(option$)
ș"Wimp_SetIconState",,q%
�
&
0
� �forcol
:forecol%=0
D%� (i% � (1<<24))=2^24 forecol%+=1
N%� (i% � (1<<25))=2^25 forecol%+=2
X%� (i% � (1<<26))=2^26 forecol%+=4
b%� (i% � (1<<27))=2^27 forecol%+=8
lq%!0=main%
vq%!4=35
�q%!8=forecol%<<28
�q%!12=%1111<<28
�ș"Wimp_SetIconState",,q%
��
�
�� �backcol
�backcol%=0
�%� (i% � (1<<28))=2^28 backcol%+=1
�%� (i% � (1<<29))=2^29 backcol%+=2
�%� (i% � (1<<30))=2^30 backcol%+=4
�(� (i% � (1<<31))=-(2^31) backcol%+=8
�q%!0=main%
�q%!4=36

q%!8=backcol%<<28

q%!12=%1111<<28

ș"Wimp_SetIconState",,q%

 �

*

4
� �esg

>
esg%=0

H!� (i% � (1<<16))=2^16 esg%+=1

R!� (i% � (1<<17))=2^17 esg%+=2

\!� (i% � (1<<18))=2^18 esg%+=4

f!� (i% � (1<<19))=2^19 esg%+=8

p"� (i% � (1<<20))=2^20 esg%+=16

zq%!0=main%

�q%!4=34

�ș"Wimp_GetIconState",,q%

�
q%!8=1<<0

�q%!12=1<<0

�option$=�(esg%)

�$(q%!28)=option$

�q%!36=�(option$)

�ș"Wimp_SetIconState",,q%

��

�

�� �buttsel

�
butnum%=0

�$� (i% � (1<<12))=2^12 butnum%+=1
$� (i% � (1<<13))=2^13 butnum%+=2
$� (i% � (1<<14))=2^14 butnum%+=4
$� (i% � (1<<15))=2^15 butnum%+=8
$0�buttons(butnum%):� a$:a$=�(butnum%)+"  "+a$
.q%!0=main%
8q%!4=33
Bș"Wimp_GetIconState",,q%
L
q%!8=1<<0
Vq%!12=1<<0
`option$=a$
j$(q%!28)=option$
tq%!36=�(option$)
~ș"Wimp_SetIconState",,q%
��
�
�� �buttons(type%)
�� +(type%+1)
�
� "Never"
�� "Always"
�� "Auto repeat"
�
� "Click"
�� "Release"
�� "Double Click"
�� "Click/Drag"
�� "Release/Drag"
� "Double/Drag"

� "Menu Icon"
� "Double/Click/Drag"
� "Reserved"
(� "Reserved"
2� "Reserved"
<� "Write/Click/Drag"
F� "Writeable"
P�
�
00000000  0d 00 0a 1a f4 20 3e 24  2e 21 49 66 6c 61 67 73  |..... >$.!Iflags|
00000010  2e 21 52 75 6e 49 6d 61  67 65 0d 00 14 04 0d 00  |.!RunImage......|
00000020  1e 0d de 20 71 25 20 35  30 30 30 0d 00 28 10 de  |... q% 5000..(..|
00000030  20 69 63 6f 6e 25 20 33  30 30 30 0d 00 32 13 65  | icon% 3000..2.e|
00000040  78 74 65 6e 74 25 3d 69  63 6f 6e 25 2d 31 0d 00  |xtent%=icon%-1..|
00000050  3c 15 de 20 6d 65 6e 75  5f 6d 65 6e 75 25 20 32  |<.. menu_menu% 2|
00000060  30 30 30 0d 00 46 16 de  20 6d 65 6e 75 5f 62 75  |000..F.. menu_bu|
00000070  66 66 65 72 25 20 32 30  30 0d 00 50 0d de 20 74  |ffer% 200..P.. t|
00000080  61 73 6b 25 20 34 0d 00  5a 10 de 20 62 75 66 66  |ask% 4..Z.. buff|
00000090  65 72 25 20 31 32 0d 00  64 0f 24 62 75 66 66 65  |er% 12..d.$buffe|
000000a0  72 25 3d 22 22 0d 00 6e  04 0d 00 78 0e ee 20 85  |r%=""..n...x.. .|
000000b0  20 f2 65 72 72 6f 72 0d  00 82 04 0d 00 8c 19 61  | .error........a|
000000c0  6c 69 61 73 24 3d 22 3c  49 66 6c 61 67 73 24 44  |lias$="<Iflags$D|
000000d0  69 72 3e 22 0d 00 96 11  24 74 61 73 6b 25 3d 22  |ir>"....$task%="|
000000e0  54 41 53 4b 22 0d 00 a0  37 c8 99 20 22 57 69 6d  |TASK"...7.. "Wim|
000000f0  70 5f 49 6e 69 74 69 61  6c 69 73 65 22 2c 32 30  |p_Initialise",20|
00000100  30 2c 21 74 61 73 6b 25  2c 22 49 66 6c 61 67 73  |0,!task%,"Iflags|
00000110  22 20 b8 20 2c 68 61 6e  64 6c 65 25 0d 00 aa 20  |" . ,handle%... |
00000120  f2 73 70 72 69 74 65 73  28 61 6c 69 61 73 24 2b  |.sprites(alias$+|
00000130  22 2e 21 53 70 72 69 74  65 73 22 29 0d 00 b4 1e  |".!Sprites")....|
00000140  69 63 6f 6e 68 25 3d a4  69 63 6f 6e 62 61 72 28  |iconh%=.iconbar(|
00000150  22 21 69 66 6c 61 67 73  22 29 0d 00 be 29 69 6e  |"!iflags")...)in|
00000160  66 6f 25 3d a4 74 65 6d  70 6c 61 74 65 73 28 61  |fo%=.templates(a|
00000170  6c 69 61 73 24 2b 22 2e  54 65 6d 70 6c 61 74 65  |lias$+".Template|
00000180  73 22 29 0d 00 c8 14 7a  65 72 6f 24 3d 22 30 30  |s")....zero$="00|
00000190  30 30 30 30 30 30 22 0d  00 d2 08 69 25 3d 30 0d  |000000"....i%=0.|
000001a0  00 dc 0a 65 73 67 25 3d  30 0d 00 e6 0e 66 6f 72  |...esg%=0....for|
000001b0  65 63 6f 6c 25 3d 30 0d  00 f0 0e 62 61 63 6b 63  |ecol%=0....backc|
000001c0  6f 6c 25 3d 30 0d 00 fa  14 f2 73 65 74 5f 66 6c  |ol%=0.....set_fl|
000001d0  61 67 6e 75 6d 28 69 25  29 0d 01 04 08 f2 65 73  |agnum(i%).....es|
000001e0  67 0d 01 0e 0b f2 66 6f  72 63 6f 6c 0d 01 18 0c  |g.....forcol....|
000001f0  f2 62 61 63 6b 63 6f 6c  0d 01 22 04 0d 01 2c 33  |.backcol.."...,3|
00000200  62 61 72 30 3d a4 6d 61  6b 65 6d 65 6e 28 22 49  |bar0=.makemen("I|
00000210  63 6f 6e 20 46 6c 61 67  73 a4 5b 69 6e 66 6f 25  |con Flags.[info%|
00000220  5d 2e 49 6e 66 6f a4 2e  51 75 69 74 a4 22 29 0d  |].Info..Quit.").|
00000230  01 36 47 6d 65 6e 75 30  3d a4 6d 61 6b 65 6d 65  |.6Gmenu0=.makeme|
00000240  6e 28 22 4d 61 69 6e 20  4d 65 6e 75 a4 5b 69 6e  |n("Main Menu.[in|
00000250  66 6f 25 5d 2e 49 6e 66  6f a4 5b 66 6c 61 67 25  |fo%].Info.[flag%|
00000260  5d 2e 46 6c 61 67 20 4e  75 6d 62 65 72 a4 2e 51  |].Flag Number..Q|
00000270  75 69 74 a4 22 29 0d 01  40 04 0d 01 4a 0b 65 78  |uit.")..@...J.ex|
00000280  69 74 25 3d a3 0d 01 54  1f 6d 61 73 6b 25 3d 25  |it%=...T.mask%=%|
00000290  31 31 31 30 30 30 30 31  31 30 30 30 30 30 31 31  |1110000110000011|
000002a0  30 30 30 31 0d 01 5e 05  f5 0d 01 68 1f c8 99 22  |0001..^....h..."|
000002b0  57 69 6d 70 5f 50 6f 6c  6c 22 2c 2c 71 25 20 b8  |Wimp_Poll",,q% .|
000002c0  20 72 65 61 73 6f 6e 25  0d 01 72 10 c8 8e 20 72  | reason%..r... r|
000002d0  65 61 73 6f 6e 25 20 ca  0d 01 7c 18 20 20 c9 20  |eason% ...|.  . |
000002e0  32 20 3a 20 f2 6f 70 65  6e 5f 77 69 6e 64 6f 77  |2 : .open_window|
000002f0  0d 01 86 19 20 20 c9 20  33 20 3a 20 f2 63 6c 6f  |....  . 3 : .clo|
00000300  73 65 5f 77 69 6e 64 6f  77 0d 01 90 34 20 20 c9  |se_window...4  .|
00000310  20 36 20 3a 20 f2 6d 6f  75 73 65 5f 63 6c 69 63  | 6 : .mouse_clic|
00000320  6b 28 71 25 21 30 2c 71  25 21 34 2c 71 25 21 38  |k(q%!0,q%!4,q%!8|
00000330  2c 71 25 21 31 32 2c 71  25 21 31 36 29 0d 01 9a  |,q%!12,q%!16)...|
00000340  27 20 20 c9 20 38 20 3a  20 f2 6b 65 79 5f 70 72  |'  . 8 : .key_pr|
00000350  65 73 73 28 71 25 21 30  2c 71 25 21 34 2c 71 25  |ess(q%!0,q%!4,q%|
00000360  21 32 34 29 0d 01 a4 23  20 20 c9 20 39 20 3a 20  |!24)...#  . 9 : |
00000370  f2 6d 65 6e 75 5f 73 65  6c 65 63 74 28 71 25 21  |.menu_select(q%!|
00000380  30 2c 71 25 21 34 29 0d  01 ae 05 cb 0d 01 b8 0b  |0,q%!4).........|
00000390  fd 20 65 78 69 74 25 0d  01 c2 25 c8 99 22 57 69  |. exit%...%.."Wi|
000003a0  6d 70 5f 43 6c 6f 73 65  44 6f 77 6e 22 2c 68 61  |mp_CloseDown",ha|
000003b0  6e 64 6c 65 25 2c 21 74  61 73 6b 25 0d 01 cc 05  |ndle%,!task%....|
000003c0  e0 0d 01 d6 04 0d 01 e0  1e dd 20 f2 6b 65 79 5f  |.......... .key_|
000003d0  70 72 65 73 73 28 77 68  25 2c 69 68 25 2c 63 68  |press(wh%,ih%,ch|
000003e0  72 25 29 0d 01 ea 0f 20  20 c8 8e 20 63 68 72 25  |r%)....  .. chr%|
000003f0  20 ca 0d 01 f4 0e 20 20  20 20 c9 20 31 33 20 3a  | .....    . 13 :|
00000400  0d 01 fe 12 20 20 20 20  20 20 c8 8e 20 77 68 25  |....      .. wh%|
00000410  20 ca 0d 02 08 15 20 20  20 20 20 20 20 20 c9 20  | .....        . |
00000420  66 6c 61 67 25 20 3a 0d  02 12 16 20 20 20 20 20  |flag% :....     |
00000430  20 20 20 20 20 c8 8e 20  69 68 25 20 ca 0d 02 1c  |     .. ih% ....|
00000440  1e 20 20 20 20 20 20 20  20 20 20 20 20 c9 20 30  |.            . 0|
00000450  20 3a 20 f2 67 65 74 5f  6e 75 6d 0d 02 26 0f 20  | : .get_num..&. |
00000460  20 20 20 20 20 20 20 20  20 cb 0d 02 30 0b 20 20  |         ...0.  |
00000470  20 20 20 20 cb 0d 02 3a  07 20 20 cb 0d 02 44 05  |    ...:.  ...D.|
00000480  e1 0d 02 4e 04 0d 02 58  2f dd 20 f2 6d 6f 75 73  |...N...X/. .mous|
00000490  65 5f 63 6c 69 63 6b 28  78 70 6f 73 25 2c 79 70  |e_click(xpos%,yp|
000004a0  6f 73 25 2c 62 75 74 74  6f 6e 25 2c 77 68 25 2c  |os%,button%,wh%,|
000004b0  69 68 25 29 0d 02 62 0c  c8 8e 20 77 68 25 20 ca  |ih%)..b... wh% .|
000004c0  0d 02 6c 0c 20 20 c9 20  2d 32 20 3a 0d 02 76 14  |..l.  . -2 :..v.|
000004d0  20 20 20 20 c8 8e 20 62  75 74 74 6f 6e 25 20 ca  |    .. button% .|
000004e0  0d 02 80 3e 20 20 20 20  20 20 c9 20 32 20 3a 20  |...>      . 2 : |
000004f0  c8 99 22 57 69 6d 70 5f  43 72 65 61 74 65 4d 65  |.."Wimp_CreateMe|
00000500  6e 75 22 2c 2c 62 61 72  30 2c 78 70 6f 73 25 2d  |nu",,bar0,xpos%-|
00000510  38 30 2c 31 38 34 3a 6f  70 65 6e 25 3d 30 0d 02  |80,184:open%=0..|
00000520  8a 1a 20 20 20 20 20 20  7f 20 f2 63 72 65 61 74  |..      . .creat|
00000530  65 5f 77 69 6e 64 6f 77  0d 02 94 09 20 20 20 20  |e_window....    |
00000540  cb 0d 02 9e 0f 20 20 c9  20 6d 61 69 6e 25 20 3a  |.....  . main% :|
00000550  0d 02 a8 14 20 20 20 20  c8 8e 20 62 75 74 74 6f  |....    .. butto|
00000560  6e 25 20 ca 0d 02 b2 45  20 20 20 20 20 20 c9 20  |n% ....E      . |
00000570  32 20 3a 20 c8 99 22 57  69 6d 70 5f 43 72 65 61  |2 : .."Wimp_Crea|
00000580  74 65 4d 65 6e 75 22 2c  2c 6d 65 6e 75 30 2c 78  |teMenu",,menu0,x|
00000590  70 6f 73 25 2d 31 30 30  2c 79 70 6f 73 25 2b 31  |pos%-100,ypos%+1|
000005a0  36 3a 6f 70 65 6e 25 3d  31 0d 02 bc 09 20 20 20  |6:open%=1....   |
000005b0  20 cb 0d 02 c6 10 20 20  20 20 c8 8e 20 69 68 25  | .....    .. ih%|
000005c0  20 ca 0d 02 d0 41 20 20  20 20 20 20 c9 20 30 2c  | ....A      . 0,|
000005d0  31 2c 32 2c 33 2c 34 2c  35 2c 36 2c 37 2c 38 2c  |1,2,3,4,5,6,7,8,|
000005e0  39 2c 31 30 2c 31 31 2c  32 31 2c 32 32 2c 32 33  |9,10,11,21,22,23|
000005f0  20 20 3a 20 f2 63 68 65  63 6b 28 77 68 25 2c 69  |  : .check(wh%,i|
00000600  68 25 29 0d 02 da 32 20  20 20 20 20 20 c9 20 31  |h%)...2      . 1|
00000610  32 2c 31 33 2c 31 34 2c  31 35 20 3a 20 f2 63 68  |2,13,14,15 : .ch|
00000620  65 63 6b 28 77 68 25 2c  69 68 25 29 3a f2 62 75  |eck(wh%,ih%):.bu|
00000630  74 74 73 65 6c 0d 02 e4  31 20 20 20 20 20 20 c9  |ttsel...1      .|
00000640  20 31 36 2c 31 37 2c 31  38 2c 31 39 2c 32 30 20  | 16,17,18,19,20 |
00000650  3a 20 f2 63 68 65 63 6b  28 77 68 25 2c 69 68 25  |: .check(wh%,ih%|
00000660  29 3a f2 65 73 67 0d 02  ee 31 20 20 20 20 20 20  |):.esg...1      |
00000670  c9 20 32 34 2c 32 35 2c  32 36 2c 32 37 20 3a 20  |. 24,25,26,27 : |
00000680  f2 63 68 65 63 6b 28 77  68 25 2c 69 68 25 29 3a  |.check(wh%,ih%):|
00000690  f2 66 6f 72 63 6f 6c 0d  02 f8 32 20 20 20 20 20  |.forcol...2     |
000006a0  20 c9 20 32 38 2c 32 39  2c 33 30 2c 33 31 20 3a  | . 28,29,30,31 :|
000006b0  20 f2 63 68 65 63 6b 28  77 68 25 2c 69 68 25 29  | .check(wh%,ih%)|
000006c0  3a f2 62 61 63 6b 63 6f  6c 0d 03 02 09 20 20 20  |:.backcol....   |
000006d0  20 cb 0d 03 0c 05 cb 0d  03 16 05 e1 0d 03 20 04  | ............. .|
000006e0  0d 03 2a 24 dd 20 f2 6d  65 6e 75 5f 73 65 6c 65  |..*$. .menu_sele|
000006f0  63 74 28 73 65 6c 65 63  74 25 2c 73 65 6c 65 63  |ct(select%,selec|
00000700  74 31 25 29 0d 03 34 1f  c8 99 22 57 69 6d 70 5f  |t1%)..4..."Wimp_|
00000710  47 65 74 50 6f 69 6e 74  65 72 49 6e 66 6f 22 2c  |GetPointerInfo",|
00000720  2c 71 25 0d 03 3e 12 73  74 61 79 25 3d 28 71 25  |,q%..>.stay%=(q%|
00000730  21 38 3d 31 29 0d 03 48  0e c8 8e 20 6f 70 65 6e  |!8=1)..H... open|
00000740  25 20 ca 0d 03 52 0b 20  20 c9 20 30 20 3a 0d 03  |% ...R.  . 0 :..|
00000750  5c 14 20 20 20 20 c8 8e  20 73 65 6c 65 63 74 25  |\.    .. select%|
00000760  20 ca 0d 03 66 17 20 20  20 20 20 20 c9 20 31 20  | ...f.      . 1 |
00000770  3a 20 65 78 69 74 25 3d  b9 0d 03 70 09 20 20 20  |: exit%=...p.   |
00000780  20 cb 0d 03 7a 0b 20 20  c9 20 31 20 3a 0d 03 84  | ...z.  . 1 :...|
00000790  14 20 20 20 20 c8 8e 20  73 65 6c 65 63 74 25 20  |.    .. select% |
000007a0  ca 0d 03 8e 17 20 20 20  20 20 20 c9 20 32 20 3a  |.....      . 2 :|
000007b0  20 65 78 69 74 25 3d b9  0d 03 98 09 20 20 20 20  | exit%=.....    |
000007c0  cb 0d 03 a2 05 cb 0d 03  ac 44 e7 20 73 74 61 79  |.........D. stay|
000007d0  25 20 80 20 6f 70 65 6e  25 3d 30 20 c8 99 22 57  |% . open%=0 .."W|
000007e0  69 6d 70 5f 43 72 65 61  74 65 4d 65 6e 75 22 2c  |imp_CreateMenu",|
000007f0  2c 62 61 72 30 2c 78 70  6f 73 25 2d 38 30 2c 31  |,bar0,xpos%-80,1|
00000800  38 34 3a 6f 70 65 6e 25  3d 30 0d 03 b6 4b e7 20  |84:open%=0...K. |
00000810  73 74 61 79 25 20 80 20  6f 70 65 6e 25 3d 31 20  |stay% . open%=1 |
00000820  c8 99 22 57 69 6d 70 5f  43 72 65 61 74 65 4d 65  |.."Wimp_CreateMe|
00000830  6e 75 22 2c 2c 6d 65 6e  75 30 2c 78 70 6f 73 25  |nu",,menu0,xpos%|
00000840  2d 31 30 30 2c 79 70 6f  73 25 2b 31 36 3a 6f 70  |-100,ypos%+16:op|
00000850  65 6e 25 3d 31 0d 03 c0  05 e1 0d 03 ca 04 0d 03  |en%=1...........|
00000860  d4 14 dd 20 f2 63 72 65  61 74 65 5f 77 69 6e 64  |... .create_wind|
00000870  6f 77 0d 03 de 0e 71 25  21 30 3d 6d 61 69 6e 25  |ow....q%!0=main%|
00000880  0d 03 e8 0a 71 25 21 34  3d 30 0d 03 f2 0c 71 25  |....q%!4=0....q%|
00000890  21 38 3d 32 31 36 0d 03  fc 0e 71 25 21 31 32 3d  |!8=216....q%!12=|
000008a0  31 32 33 36 0d 04 06 0e  71 25 21 31 36 3d 31 30  |1236....q%!16=10|
000008b0  32 34 0d 04 10 0b 71 25  21 32 30 3d 30 0d 04 1a  |24....q%!20=0...|
000008c0  0b 71 25 21 32 34 3d 30  0d 04 24 0c 71 25 21 32  |.q%!24=0..$.q%!2|
000008d0  38 3d 2d 31 0d 04 2e 1c  c8 99 20 22 57 69 6d 70  |8=-1...... "Wimp|
000008e0  5f 4f 70 65 6e 57 69 6e  64 6f 77 22 2c 2c 71 25  |_OpenWindow",,q%|
000008f0  0d 04 38 0c f2 62 75 74  74 73 65 6c 0d 04 42 05  |..8..buttsel..B.|
00000900  e1 0d 04 4c 04 0d 04 56  17 dd 20 a4 69 63 6f 6e  |...L...V.. .icon|
00000910  62 61 72 28 73 70 6e 61  6d 65 24 29 0d 04 60 0b  |bar(spname$)..`.|
00000920  71 25 21 30 3d 2d 31 0d  04 6a 0a 71 25 21 34 3d  |q%!0=-1..j.q%!4=|
00000930  30 0d 04 74 0a 71 25 21  38 3d 30 0d 04 7e 0c 71  |0..t.q%!8=0..~.q|
00000940  25 21 31 32 3d 36 33 0d  04 88 0c 71 25 21 31 36  |%!12=63....q%!16|
00000950  3d 36 34 0d 04 92 0f 71  25 21 32 30 3d 26 32 31  |=64....q%!20=&21|
00000960  30 32 0d 04 9c 18 de 20  71 25 21 32 34 20 28 a9  |02..... q%!24 (.|
00000970  73 70 6e 61 6d 65 24 2b  31 29 0d 04 a6 14 24 28  |spname$+1)....$(|
00000980  71 25 21 32 34 29 3d 73  70 6e 61 6d 65 24 0d 04  |q%!24)=spname$..|
00000990  b0 11 71 25 21 32 38 3d  73 70 72 69 74 65 25 0d  |..q%!28=sprite%.|
000009a0  04 ba 16 71 25 21 33 32  3d 28 a9 73 70 6e 61 6d  |...q%!32=(.spnam|
000009b0  65 24 2b 31 29 0d 04 c4  25 c8 99 20 22 57 69 6d  |e$+1)...%.. "Wim|
000009c0  70 5f 43 72 65 61 74 65  49 63 6f 6e 22 2c 2c 71  |p_CreateIcon",,q|
000009d0  25 20 b8 20 69 63 6f 6e  62 25 0d 04 ce 0b 3d 69  |% . iconb%....=i|
000009e0  63 6f 6e 62 25 0d 04 d8  04 0d 04 e2 15 dd 20 f2  |conb%......... .|
000009f0  73 70 72 69 74 65 73 28  66 69 6c 65 24 29 0d 04  |sprites(file$)..|
00000a00  ec 0f 73 70 3d 8e 28 66  69 6c 65 24 29 0d 04 f6  |..sp=.(file$)...|
00000a10  10 64 69 6d 25 3d a2 23  73 70 2b 31 36 0d 05 00  |.dim%=.#sp+16...|
00000a20  08 d9 23 73 70 0d 05 0a  12 de 20 73 70 72 69 74  |..#sp..... sprit|
00000a30  65 25 20 64 69 6d 25 0d  05 14 12 73 70 72 69 74  |e% dim%....sprit|
00000a40  65 25 21 30 3d 64 69 6d  25 0d 05 1e 0f 73 70 72  |e%!0=dim%....spr|
00000a50  69 74 65 25 21 34 3d 30  0d 05 28 10 73 70 72 69  |ite%!4=0..(.spri|
00000a60  74 65 25 21 38 3d 31 36  0d 05 32 11 73 70 72 69  |te%!8=16..2.spri|
00000a70  74 65 25 21 31 32 3d 31  36 0d 05 3c 29 c8 99 20  |te%!12=16..<).. |
00000a80  22 4f 53 5f 53 70 72 69  74 65 4f 70 22 2c 32 35  |"OS_SpriteOp",25|
00000a90  36 2b 31 30 2c 73 70 72  69 74 65 25 2c 66 69 6c  |6+10,sprite%,fil|
00000aa0  65 24 0d 05 46 05 e1 0d  05 50 04 0d 05 5a 17 dd  |e$..F....P...Z..|
00000ab0  20 a4 74 65 6d 70 6c 61  74 65 73 28 66 69 6c 65  | .templates(file|
00000ac0  24 29 0d 05 64 21 c8 99  20 22 57 69 6d 70 5f 4f  |$)..d!.. "Wimp_O|
00000ad0  70 65 6e 54 65 6d 70 6c  61 74 65 22 2c 2c 66 69  |penTemplate",,fi|
00000ae0  6c 65 24 0d 05 6e 48 c8  99 20 22 57 69 6d 70 5f  |le$..nH.. "Wimp_|
00000af0  4c 6f 61 64 54 65 6d 70  6c 61 74 65 22 2c 2c 71  |LoadTemplate",,q|
00000b00  25 2c 69 63 6f 6e 25 2c  69 63 6f 6e 25 2b 65 78  |%,icon%,icon%+ex|
00000b10  74 65 6e 74 25 2c 2d 31  2c 22 69 6e 66 6f 22 2c  |tent%,-1,"info",|
00000b20  30 20 b8 20 2c 2c 6e 65  78 74 25 0d 05 78 26 c8  |0 . ,,next%..x&.|
00000b30  99 20 22 57 69 6d 70 5f  43 72 65 61 74 65 57 69  |. "Wimp_CreateWi|
00000b40  6e 64 6f 77 22 2c 2c 71  25 20 b8 20 69 6e 66 6f  |ndow",,q% . info|
00000b50  25 0d 05 82 48 c8 99 20  22 57 69 6d 70 5f 4c 6f  |%...H.. "Wimp_Lo|
00000b60  61 64 54 65 6d 70 6c 61  74 65 22 2c 2c 71 25 2c  |adTemplate",,q%,|
00000b70  6e 65 78 74 25 2c 69 63  6f 6e 25 2b 65 78 74 65  |next%,icon%+exte|
00000b80  6e 74 25 2c 2d 31 2c 22  66 6c 61 67 22 2c 30 20  |nt%,-1,"flag",0 |
00000b90  b8 20 2c 2c 6e 65 78 74  25 0d 05 8c 26 c8 99 20  |. ,,next%...&.. |
00000ba0  22 57 69 6d 70 5f 43 72  65 61 74 65 57 69 6e 64  |"Wimp_CreateWind|
00000bb0  6f 77 22 2c 2c 71 25 20  b8 20 66 6c 61 67 25 0d  |ow",,q% . flag%.|
00000bc0  05 96 48 c8 99 20 22 57  69 6d 70 5f 4c 6f 61 64  |..H.. "Wimp_Load|
00000bd0  54 65 6d 70 6c 61 74 65  22 2c 2c 71 25 2c 6e 65  |Template",,q%,ne|
00000be0  78 74 25 2c 69 63 6f 6e  25 2b 65 78 74 65 6e 74  |xt%,icon%+extent|
00000bf0  25 2c 2d 31 2c 22 6d 61  69 6e 22 2c 30 20 b8 20  |%,-1,"main",0 . |
00000c00  2c 2c 6e 65 78 74 25 0d  05 a0 26 c8 99 20 22 57  |,,next%...&.. "W|
00000c10  69 6d 70 5f 43 72 65 61  74 65 57 69 6e 64 6f 77  |imp_CreateWindow|
00000c20  22 2c 2c 71 25 20 b8 20  6d 61 69 6e 25 0d 05 aa  |",,q% . main%...|
00000c30  1b c8 99 20 22 57 69 6d  70 5f 43 6c 6f 73 65 54  |... "Wimp_CloseT|
00000c40  65 6d 70 6c 61 74 65 22  0d 05 b4 0a 3d 69 6e 66  |emplate"....=inf|
00000c50  6f 25 0d 05 be 04 0d 05  c8 13 dd 20 f2 63 6c 6f  |o%......... .clo|
00000c60  73 65 5f 77 69 6e 64 6f  77 0d 05 d2 0e 71 25 21  |se_window....q%!|
00000c70  30 3d 6d 61 69 6e 25 0d  05 dc 1d c8 99 20 22 57  |0=main%...... "W|
00000c80  69 6d 70 5f 43 6c 6f 73  65 57 69 6e 64 6f 77 22  |imp_CloseWindow"|
00000c90  2c 2c 71 25 0d 05 e6 05  e1 0d 05 f0 05 3a 0d 05  |,,q%.........:..|
00000ca0  fa 12 dd 20 f2 6f 70 65  6e 5f 77 69 6e 64 6f 77  |... .open_window|
00000cb0  0d 06 04 1c c8 99 20 22  57 69 6d 70 5f 4f 70 65  |...... "Wimp_Ope|
00000cc0  6e 57 69 6e 64 6f 77 22  2c 2c 71 25 0d 06 0e 05  |nWindow",,q%....|
00000cd0  e1 0d 06 18 04 0d 06 22  0c dd 20 f2 65 72 72 6f  |.......".. .erro|
00000ce0  72 0d 06 2c 18 c8 99 20  22 57 69 6d 70 5f 44 72  |r..,... "Wimp_Dr|
00000cf0  61 67 42 6f 78 22 2c 2c  30 0d 06 36 0a 71 25 21  |agBox",,0..6.q%!|
00000d00  30 3d 9f 0d 06 40 0b 65  72 72 6f 72 3d b9 0d 06  |0=...@.error=...|
00000d10  4a 0a c8 8e 20 9f 20 ca  0d 06 54 3b 20 20 c9 20  |J... . ...T;  . |
00000d20  32 32 32 20 3a 20 24 28  71 25 2b 34 29 3d 22 54  |222 : $(q%+4)="T|
00000d30  68 69 73 20 66 69 6c 65  20 64 6f 65 73 20 6e 6f  |his file does no|
00000d40  74 20 65 78 69 73 74 22  2b bd 30 3a 65 72 72 6f  |t exist"+.0:erro|
00000d50  72 3d a3 0d 06 5e 07 20  20 7f 0d 06 68 35 20 20  |r=...^.  ...h5  |
00000d60  24 28 71 25 2b 34 29 3d  22 28 49 6e 74 65 72 6e  |$(q%+4)="(Intern|
00000d70  61 6c 20 65 72 72 6f 72  20 63 6f 64 65 20 22 2b  |al error code "+|
00000d80  c3 28 9e 29 2b 22 29 20  22 2b f6 24 2b bd 30 0d  |.(.)+") "+.$+.0.|
00000d90  06 72 05 cb 0d 06 7c 0b  66 6c 61 67 73 3d 31 0d  |.r....|.flags=1.|
00000da0  06 86 2c c8 99 20 22 57  69 6d 70 5f 52 65 70 6f  |..,.. "Wimp_Repo|
00000db0  72 74 45 72 72 6f 72 22  2c 71 25 2c 66 6c 61 67  |rtError",q%,flag|
00000dc0  73 2c 22 21 49 66 6c 61  67 73 22 0d 06 90 05 e1  |s,"!Iflags".....|
00000dd0  0d 06 9a 04 0d 06 a4 1a  dd 20 a4 6d 61 6b 65 6d  |......... .makem|
00000de0  65 6e 28 6d 65 6e 75 5f  6d 65 6e 75 24 29 0d 06  |en(menu_menu$)..|
00000df0  ae 26 6d 65 6e 75 5f 6d  65 6e 75 70 74 72 25 3d  |.&menu_menuptr%=|
00000e00  30 3a 6d 65 6e 75 5f 6d  25 3d 6d 65 6e 75 5f 6d  |0:menu_m%=menu_m|
00000e10  65 6e 75 25 0d 06 b8 2f  6d 65 6e 75 5f 74 69 74  |enu%.../menu_tit|
00000e20  6c 65 24 3d c0 6d 65 6e  75 5f 6d 65 6e 75 24 2c  |le$=.menu_menu$,|
00000e30  a7 6d 65 6e 75 5f 6d 65  6e 75 24 2c 22 a4 22 29  |.menu_menu$,".")|
00000e40  2d 31 29 0d 06 c2 3a 6d  65 6e 75 5f 6d 65 6e 75  |-1)...:menu_menu|
00000e50  24 3d c2 6d 65 6e 75 5f  6d 65 6e 75 24 2c a9 28  |$=.menu_menu$,.(|
00000e60  6d 65 6e 75 5f 6d 65 6e  75 24 29 2d a7 6d 65 6e  |menu_menu$)-.men|
00000e70  75 5f 6d 65 6e 75 24 2c  22 a4 22 29 29 0d 06 cc  |u_menu$,"."))...|
00000e80  0f 6d 65 6e 75 5f 6d 61  78 25 3d 30 0d 06 d6 1b  |.menu_max%=0....|
00000e90  24 6d 65 6e 75 5f 6d 65  6e 75 25 3d 6d 65 6e 75  |$menu_menu%=menu|
00000ea0  5f 74 69 74 6c 65 24 0d  06 e0 13 6d 65 6e 75 5f  |_title$....menu_|
00000eb0  6d 65 6e 75 25 3f 31 32  3d 37 0d 06 ea 13 6d 65  |menu%?12=7....me|
00000ec0  6e 75 5f 6d 65 6e 75 25  3f 31 33 3d 32 0d 06 f4  |nu_menu%?13=2...|
00000ed0  13 6d 65 6e 75 5f 6d 65  6e 75 25 3f 31 34 3d 37  |.menu_menu%?14=7|
00000ee0  0d 06 fe 13 6d 65 6e 75  5f 6d 65 6e 75 25 3f 31  |....menu_menu%?1|
00000ef0  35 3d 30 0d 07 08 14 6d  65 6e 75 5f 6d 65 6e 75  |5=0....menu_menu|
00000f00  25 21 32 30 3d 34 34 0d  07 12 13 6d 65 6e 75 5f  |%!20=44....menu_|
00000f10  6d 65 6e 75 25 21 32 34  3d 30 0d 07 1c 12 6d 65  |menu%!24=0....me|
00000f20  6e 75 5f 6d 65 6e 75 25  2b 3d 32 38 0d 07 26 15  |nu_menu%+=28..&.|
00000f30  6d 65 6e 75 5f 6d 65 6e  75 70 74 72 25 2b 3d 32  |menu_menuptr%+=2|
00000f40  38 0d 07 30 15 c8 95 20  6d 65 6e 75 5f 6d 65 6e  |8..0... menu_men|
00000f50  75 24 3c 3e 22 22 0d 07  3a 2e 6d 65 6e 75 5f 74  |u$<>""..:.menu_t|
00000f60  65 78 74 24 3d c0 6d 65  6e 75 5f 6d 65 6e 75 24  |ext$=.menu_menu$|
00000f70  2c a7 6d 65 6e 75 5f 6d  65 6e 75 24 2c 22 a4 22  |,.menu_menu$,"."|
00000f80  29 2d 31 29 0d 07 44 3a  6d 65 6e 75 5f 6d 65 6e  |)-1)..D:menu_men|
00000f90  75 24 3d c2 6d 65 6e 75  5f 6d 65 6e 75 24 2c a9  |u$=.menu_menu$,.|
00000fa0  28 6d 65 6e 75 5f 6d 65  6e 75 24 29 2d a7 6d 65  |(menu_menu$)-.me|
00000fb0  6e 75 5f 6d 65 6e 75 24  2c 22 a4 22 29 29 0d 07  |nu_menu$,"."))..|
00000fc0  4e 1f 6d 65 6e 75 5f 74  69 63 6b 25 3d a7 6d 65  |N.menu_tick%=.me|
00000fd0  6e 75 5f 74 65 78 74 24  2c 22 21 22 29 0d 07 58  |nu_text$,"!")..X|
00000fe0  1f 6d 65 6e 75 5f 64 6f  74 73 25 3d a7 6d 65 6e  |.menu_dots%=.men|
00000ff0  75 5f 74 65 78 74 24 2c  22 2d 22 29 0d 07 62 20  |u_text$,"-")..b |
00001000  6d 65 6e 75 5f 77 72 69  74 65 25 3d a7 6d 65 6e  |menu_write%=.men|
00001010  75 5f 74 65 78 74 24 2c  22 3f 22 29 0d 07 6c 20  |u_text$,"?")..l |
00001020  6d 65 6e 75 5f 73 68 61  64 65 25 3d a7 6d 65 6e  |menu_shade%=.men|
00001030  75 5f 74 65 78 74 24 2c  22 40 22 29 0d 07 76 1e  |u_text$,"@")..v.|
00001040  6d 65 6e 75 5f 73 75 62  25 3d a7 6d 65 6e 75 5f  |menu_sub%=.menu_|
00001050  74 65 78 74 24 2c 22 5b  22 29 0d 07 80 1f 6d 65  |text$,"[")....me|
00001060  6e 75 5f 6c 61 73 74 25  3d a7 6d 65 6e 75 5f 74  |nu_last%=.menu_t|
00001070  65 78 74 24 2c 22 23 22  29 0d 07 8a 38 6d 65 6e  |ext$,"#")...8men|
00001080  75 5f 74 31 24 3d c2 6d  65 6e 75 5f 74 65 78 74  |u_t1$=.menu_text|
00001090  24 2c a9 28 6d 65 6e 75  5f 74 65 78 74 24 29 2d  |$,.(menu_text$)-|
000010a0  a7 6d 65 6e 75 5f 74 65  78 74 24 2c 22 2e 22 29  |.menu_text$,".")|
000010b0  29 0d 07 94 2e 6d 65 6e  75 5f 74 65 78 74 24 3d  |)....menu_text$=|
000010c0  c0 6d 65 6e 75 5f 74 65  78 74 24 2c a7 6d 65 6e  |.menu_text$,.men|
000010d0  75 5f 74 65 78 74 24 2c  22 2e 22 29 2d 31 29 0d  |u_text$,".")-1).|
000010e0  07 9e 0e 6d 65 6e 75 5f  6d 69 25 3d 30 0d 07 a8  |...menu_mi%=0...|
000010f0  2a e7 20 6d 65 6e 75 5f  74 69 63 6b 25 3e 30 20  |*. menu_tick%>0 |
00001100  8c 20 6d 65 6e 75 5f 6d  69 25 3d 6d 65 6e 75 5f  |. menu_mi%=menu_|
00001110  6d 69 25 20 84 20 31 0d  07 b2 2a e7 20 6d 65 6e  |mi% . 1...*. men|
00001120  75 5f 64 6f 74 73 25 3e  30 20 8c 20 6d 65 6e 75  |u_dots%>0 . menu|
00001130  5f 6d 69 25 3d 6d 65 6e  75 5f 6d 69 25 20 84 20  |_mi%=menu_mi% . |
00001140  32 0d 07 bc 2b e7 20 6d  65 6e 75 5f 77 72 69 74  |2...+. menu_writ|
00001150  65 25 3e 30 20 8c 20 6d  65 6e 75 5f 6d 69 25 3d  |e%>0 . menu_mi%=|
00001160  6d 65 6e 75 5f 6d 69 25  20 84 20 34 0d 07 c6 2d  |menu_mi% . 4...-|
00001170  e7 20 6d 65 6e 75 5f 6d  65 6e 75 24 3d 22 22 20  |. menu_menu$="" |
00001180  8c 20 6d 65 6e 75 5f 6d  69 25 3d 6d 65 6e 75 5f  |. menu_mi%=menu_|
00001190  6d 69 25 20 84 20 31 32  38 0d 07 d0 13 e7 20 6d  |mi% . 128..... m|
000011a0  65 6e 75 5f 73 75 62 25  3e 30 20 8c 0d 07 da 1c  |enu_sub%>0 .....|
000011b0  6d 65 6e 75 5f 6c 62 72  61 63 6b 25 3d 6d 65 6e  |menu_lbrack%=men|
000011c0  75 5f 73 75 62 25 2b 31  0d 07 e4 21 6d 65 6e 75  |u_sub%+1...!menu|
000011d0  5f 72 62 72 61 63 6b 25  3d a7 6d 65 6e 75 5f 74  |_rbrack%=.menu_t|
000011e0  65 78 74 24 2c 22 5d 22  29 0d 07 ee 42 6d 65 6e  |ext$,"]")...Bmen|
000011f0  75 5f 70 25 3d a0 28 c1  6d 65 6e 75 5f 74 65 78  |u_p%=.(.menu_tex|
00001200  74 24 2c 6d 65 6e 75 5f  6c 62 72 61 63 6b 25 2c  |t$,menu_lbrack%,|
00001210  6d 65 6e 75 5f 72 62 72  61 63 6b 25 2d 6d 65 6e  |menu_rbrack%-men|
00001220  75 5f 6c 62 72 61 63 6b  25 29 29 0d 07 f8 05 cd  |u_lbrack%)).....|
00001230  0d 08 02 2e 6d 65 6e 75  5f 69 69 25 3d 25 30 30  |....menu_ii%=%00|
00001240  30 30 30 31 31 31 30 30  30 30 30 30 30 30 30 30  |0001110000000000|
00001250  30 30 30 30 30 31 30 30  31 31 30 30 30 31 0d 08  |00000100110001..|
00001260  0c 25 e7 20 6d 65 6e 75  5f 73 68 61 64 65 25 3e  |.%. menu_shade%>|
00001270  30 20 6d 65 6e 75 5f 69  69 25 2b 3d 28 31 3c 3c  |0 menu_ii%+=(1<<|
00001280  32 32 29 0d 08 16 18 21  6d 65 6e 75 5f 6d 65 6e  |22)....!menu_men|
00001290  75 25 3d 6d 65 6e 75 5f  6d 69 25 0d 08 20 13 e7  |u%=menu_mi%.. ..|
000012a0  20 6d 65 6e 75 5f 73 75  62 25 3e 30 20 8c 0d 08  | menu_sub%>0 ...|
000012b0  2a 18 6d 65 6e 75 5f 6d  65 6e 75 25 21 34 3d 6d  |*.menu_menu%!4=m|
000012c0  65 6e 75 5f 70 25 0d 08  34 05 cc 0d 08 3e 12 6d  |enu_p%..4....>.m|
000012d0  65 6e 75 5f 6d 65 6e 75  25 21 34 3d 30 0d 08 48  |enu_menu%!4=0..H|
000012e0  05 cd 0d 08 52 19 6d 65  6e 75 5f 6d 65 6e 75 25  |....R.menu_menu%|
000012f0  21 38 3d 6d 65 6e 75 5f  69 69 25 0d 08 5c 15 e7  |!8=menu_ii%..\..|
00001300  20 6d 65 6e 75 5f 77 72  69 74 65 25 3e 30 20 8c  | menu_write%>0 .|
00001310  0d 08 66 56 6d 65 6e 75  5f 76 61 6c 25 3d a0 28  |..fVmenu_val%=.(|
00001320  c1 6d 65 6e 75 5f 74 65  78 74 24 2c 28 a7 6d 65  |.menu_text$,(.me|
00001330  6e 75 5f 74 65 78 74 24  2c 22 3f 22 29 2b 31 29  |nu_text$,"?")+1)|
00001340  2c a7 6d 65 6e 75 5f 74  65 78 74 24 2c 22 2c 22  |,.menu_text$,","|
00001350  29 2d a7 6d 65 6e 75 5f  74 65 78 74 24 2c 22 3f  |)-.menu_text$,"?|
00001360  22 29 2d 31 29 29 0d 08  70 1b 6d 65 6e 75 5f 6d  |")-1))..p.menu_m|
00001370  65 6e 75 25 21 31 32 3d  6d 65 6e 75 5f 76 61 6c  |enu%!12=menu_val|
00001380  25 0d 08 7a 14 6d 65 6e  75 5f 6d 65 6e 75 25 21  |%..z.menu_menu%!|
00001390  31 36 3d 2d 31 0d 08 84  54 6d 65 6e 75 5f 6c 65  |16=-1...Tmenu_le|
000013a0  6e 25 3d a0 28 c1 6d 65  6e 75 5f 74 65 78 74 24  |n%=.(.menu_text$|
000013b0  2c a7 6d 65 6e 75 5f 74  65 78 74 24 2c 22 2c 22  |,.menu_text$,","|
000013c0  29 2b 31 2c a7 6d 65 6e  75 5f 74 65 78 74 24 2c  |)+1,.menu_text$,|
000013d0  22 2e 22 29 2d a7 6d 65  6e 75 5f 74 65 78 74 24  |".")-.menu_text$|
000013e0  2c 22 2c 22 29 2d 31 29  29 0d 08 8e 1b 6d 65 6e  |,",")-1))....men|
000013f0  75 5f 6d 65 6e 75 25 21  32 30 3d 6d 65 6e 75 5f  |u_menu%!20=menu_|
00001400  6c 65 6e 25 0d 08 98 05  cd 0d 08 a2 15 e7 20 6d  |len%.......... m|
00001410  65 6e 75 5f 77 72 69 74  65 25 3d 30 20 8c 0d 08  |enu_write%=0 ...|
00001420  ac 1e 6d 65 6e 75 5f 6d  65 6e 75 25 21 31 32 3d  |..menu_menu%!12=|
00001430  6d 65 6e 75 5f 62 75 66  66 65 72 25 0d 08 b6 14  |menu_buffer%....|
00001440  6d 65 6e 75 5f 6d 65 6e  75 25 21 31 36 3d 2d 31  |menu_menu%!16=-1|
00001450  0d 08 c0 1f 6d 65 6e 75  5f 6d 65 6e 75 25 21 32  |....menu_menu%!2|
00001460  30 3d a9 28 6d 65 6e 75  5f 74 31 24 29 2b 31 0d  |0=.(menu_t1$)+1.|
00001470  08 ca 1c 24 28 6d 65 6e  75 5f 62 75 66 66 65 72  |...$(menu_buffer|
00001480  25 29 3d 6d 65 6e 75 5f  74 31 24 0d 08 d4 1f 6d  |%)=menu_t1$....m|
00001490  65 6e 75 5f 62 75 66 66  65 72 25 2b 3d a9 28 6d  |enu_buffer%+=.(m|
000014a0  65 6e 75 5f 74 31 24 29  2b 31 0d 08 de 05 cd 0d  |enu_t1$)+1......|
000014b0  08 e8 2f e7 20 a9 28 6d  65 6e 75 5f 74 31 24 29  |../. .(menu_t1$)|
000014c0  3e 6d 65 6e 75 5f 6d 61  78 25 20 6d 65 6e 75 5f  |>menu_max% menu_|
000014d0  6d 61 78 25 3d a9 6d 65  6e 75 5f 74 31 24 0d 08  |max%=.menu_t1$..|
000014e0  f2 33 e7 20 6d 65 6e 75  5f 6d 61 78 25 3c a9 6d  |.3. menu_max%<.m|
000014f0  65 6e 75 5f 74 69 74 6c  65 24 20 6d 65 6e 75 5f  |enu_title$ menu_|
00001500  6d 61 78 25 3d a9 6d 65  6e 75 5f 74 69 74 6c 65  |max%=.menu_title|
00001510  24 0d 08 fc 15 6d 65 6e  75 5f 6d 65 6e 75 70 74  |$....menu_menupt|
00001520  72 25 2b 3d 32 34 0d 09  06 12 6d 65 6e 75 5f 6d  |r%+=24....menu_m|
00001530  65 6e 75 25 2b 3d 32 34  0d 09 10 05 ce 0d 09 1a  |enu%+=24........|
00001540  1e 6d 65 6e 75 5f 6d 25  21 31 36 3d 6d 65 6e 75  |.menu_m%!16=menu|
00001550  5f 6d 61 78 25 2a 31 36  2b 33 32 0d 09 24 1d 3d  |_max%*16+32..$.=|
00001560  6d 65 6e 75 5f 6d 65 6e  75 25 2d 6d 65 6e 75 5f  |menu_menu%-menu_|
00001570  6d 65 6e 75 70 74 72 25  0d 09 2e 04 0d 09 38 17  |menuptr%......8.|
00001580  dd 20 f2 63 68 65 63 6b  28 77 68 25 2c 69 6e 75  |. .check(wh%,inu|
00001590  6d 25 29 0d 09 42 18 69  25 3d 28 69 25 20 82 20  |m%)..B.i%=(i% . |
000015a0  28 31 3c 3c 69 6e 75 6d  25 29 29 0d 09 4c 34 e7  |(1<<inum%))..L4.|
000015b0  20 28 69 25 20 80 20 28  31 3c 3c 69 6e 75 6d 25  | (i% . (1<<inum%|
000015c0  29 29 3d 32 5e 69 6e 75  6d 25 3a f2 73 65 74 5f  |))=2^inum%:.set_|
000015d0  69 63 6f 6e 28 77 68 25  2c 69 6e 75 6d 25 29 0d  |icon(wh%,inum%).|
000015e0  09 56 34 e7 20 28 69 25  20 80 20 28 31 3c 3c 69  |.V4. (i% . (1<<i|
000015f0  6e 75 6d 25 29 29 3d 2d  28 32 5e 33 31 29 3a f2  |num%))=-(2^31):.|
00001600  73 65 74 5f 69 63 6f 6e  28 77 68 25 2c 69 6e 75  |set_icon(wh%,inu|
00001610  6d 25 29 0d 09 60 30 e7  20 28 69 25 20 80 20 28  |m%)..`0. (i% . (|
00001620  31 3c 3c 69 6e 75 6d 25  29 29 3d 30 3a f2 72 65  |1<<inum%))=0:.re|
00001630  73 65 74 5f 69 63 6f 6e  28 77 68 25 2c 69 6e 75  |set_icon(wh%,inu|
00001640  6d 25 29 0d 09 6a 14 f2  73 65 74 5f 66 6c 61 67  |m%)..j..set_flag|
00001650  6e 75 6d 28 69 25 29 0d  09 74 05 e1 0d 09 7e 04  |num(i%)..t....~.|
00001660  0d 09 88 16 dd 20 f2 73  65 74 5f 66 6c 61 67 6e  |..... .set_flagn|
00001670  75 6d 28 69 25 29 0d 09  92 0e 71 25 21 30 3d 6d  |um(i%)....q%!0=m|
00001680  61 69 6e 25 0d 09 9c 0b  71 25 21 34 3d 33 37 0d  |ain%....q%!4=37.|
00001690  09 a6 1d c8 99 22 57 69  6d 70 5f 47 65 74 49 63  |....."Wimp_GetIc|
000016a0  6f 6e 53 74 61 74 65 22  2c 2c 71 25 0d 09 b0 0d  |onState",,q%....|
000016b0  71 25 21 38 3d 31 3c 3c  30 0d 09 ba 0e 71 25 21  |q%!8=1<<0....q%!|
000016c0  31 32 3d 31 3c 3c 30 0d  09 c4 10 6f 70 74 69 6f  |12=1<<0....optio|
000016d0  6e 24 3d c3 7e 69 25 0d  09 ce 11 6c 25 3d a9 28  |n$=.~i%....l%=.(|
000016e0  6f 70 74 69 6f 6e 24 29  0d 09 d8 21 6f 70 74 24  |option$)...!opt$|
000016f0  3d 22 26 22 2b c0 7a 65  72 6f 24 2c 38 2d 6c 25  |="&"+.zero$,8-l%|
00001700  29 2b 6f 70 74 69 6f 6e  24 0d 09 e2 11 24 28 71  |)+option$....$(q|
00001710  25 21 32 38 29 3d 6f 70  74 24 0d 09 ec 11 71 25  |%!28)=opt$....q%|
00001720  21 33 36 3d a9 28 6f 70  74 24 29 0d 09 f6 1d c8  |!36=.(opt$).....|
00001730  99 22 57 69 6d 70 5f 53  65 74 49 63 6f 6e 53 74  |."Wimp_SetIconSt|
00001740  61 74 65 22 2c 2c 71 25  0d 0a 00 05 e1 0d 0a 0a  |ate",,q%........|
00001750  04 0d 0a 14 0e dd 20 f2  67 65 74 5f 6e 75 6d 0d  |...... .get_num.|
00001760  0a 1e 1c c8 99 20 22 57  69 6d 70 5f 43 72 65 61  |..... "Wimp_Crea|
00001770  74 65 4d 65 6e 75 22 2c  2c 2d 31 0d 0a 28 0e 71  |teMenu",,-1..(.q|
00001780  25 21 30 3d 66 6c 61 67  25 0d 0a 32 0a 71 25 21  |%!0=flag%..2.q%!|
00001790  34 3d 30 0d 0a 3c 1d c8  99 22 57 69 6d 70 5f 47  |4=0..<..."Wimp_G|
000017a0  65 74 49 63 6f 6e 53 74  61 74 65 22 2c 2c 71 25  |etIconState",,q%|
000017b0  0d 0a 46 0f 61 24 3d 24  28 71 25 21 32 38 29 0d  |..F.a$=$(q%!28).|
000017c0  0a 50 19 e7 20 61 24 3d  22 22 20 61 24 3d 22 30  |.P.. a$="" a$="0|
000017d0  30 30 30 30 30 30 30 22  0d 0a 5a 0d 61 24 3d 22  |0000000"..Z.a$="|
000017e0  26 22 2b 61 24 0d 0a 64  0c 69 25 3d a0 28 61 24  |&"+a$..d.i%=.(a$|
000017f0  29 0d 0a 6e 0f e3 20 61  25 3d 30 20 b8 20 33 30  |)..n.. a%=0 . 30|
00001800  0d 0a 78 45 e7 20 28 69  25 20 80 20 28 31 3c 3c  |..xE. (i% . (1<<|
00001810  61 25 29 29 3d 32 5e 61  25 20 f2 73 65 74 5f 69  |a%))=2^a% .set_i|
00001820  63 6f 6e 28 6d 61 69 6e  25 2c 61 25 29 20 8b 20  |con(main%,a%) . |
00001830  f2 72 65 73 65 74 5f 69  63 6f 6e 28 6d 61 69 6e  |.reset_icon(main|
00001840  25 2c 61 25 29 0d 0a 82  05 ed 0d 0a 8c 48 e7 20  |%,a%)........H. |
00001850  28 69 25 20 80 20 28 31  3c 3c 33 31 29 29 3d 2d  |(i% . (1<<31))=-|
00001860  28 32 5e 33 31 29 20 f2  73 65 74 5f 69 63 6f 6e  |(2^31) .set_icon|
00001870  28 6d 61 69 6e 25 2c 61  25 29 20 8b 20 f2 72 65  |(main%,a%) . .re|
00001880  73 65 74 5f 69 63 6f 6e  28 6d 61 69 6e 25 2c 61  |set_icon(main%,a|
00001890  25 29 0d 0a 96 17 f2 73  65 74 5f 66 6c 61 67 6e  |%).....set_flagn|
000018a0  75 6d 28 a0 28 61 24 29  29 0d 0a a0 0b f2 66 6f  |um(.(a$)).....fo|
000018b0  72 63 6f 6c 0d 0a aa 0c  f2 62 61 63 6b 63 6f 6c  |rcol.....backcol|
000018c0  0d 0a b4 08 f2 65 73 67  0d 0a be 0c f2 62 75 74  |.....esg.....but|
000018d0  74 73 65 6c 0d 0a c8 0e  71 25 21 30 3d 66 6c 61  |tsel....q%!0=fla|
000018e0  67 25 0d 0a d2 0a 71 25  21 34 3d 30 0d 0a dc 1d  |g%....q%!4=0....|
000018f0  c8 99 22 57 69 6d 70 5f  47 65 74 49 63 6f 6e 53  |.."Wimp_GetIconS|
00001900  74 61 74 65 22 2c 2c 71  25 0d 0a e6 0d 71 25 21  |tate",,q%....q%!|
00001910  38 3d 31 3c 3c 31 0d 0a  f0 0e 71 25 21 31 32 3d  |8=1<<1....q%!12=|
00001920  31 3c 3c 31 0d 0a fa 0e  6f 70 74 69 6f 6e 24 3d  |1<<1....option$=|
00001930  22 22 0d 0b 04 14 24 28  71 25 21 32 38 29 3d 6f  |""....$(q%!28)=o|
00001940  70 74 69 6f 6e 24 0d 0b  0e 1d c8 99 22 57 69 6d  |ption$......"Wim|
00001950  70 5f 53 65 74 49 63 6f  6e 53 74 61 74 65 22 2c  |p_SetIconState",|
00001960  2c 71 25 0d 0b 18 0e 71  25 21 30 3d 66 6c 61 67  |,q%....q%!0=flag|
00001970  25 0d 0b 22 1d c8 99 20  22 57 69 6d 70 5f 43 6c  |%.."... "Wimp_Cl|
00001980  6f 73 65 57 69 6e 64 6f  77 22 2c 2c 71 25 0d 0b  |oseWindow",,q%..|
00001990  2c 05 e1 0d 0b 36 04 0d  0b 40 18 dd 20 f2 73 65  |,....6...@.. .se|
000019a0  74 5f 69 63 6f 6e 28 77  68 25 2c 69 68 25 29 0d  |t_icon(wh%,ih%).|
000019b0  0b 4a 0c 71 25 21 30 3d  77 68 25 0d 0b 54 0c 71  |.J.q%!0=wh%..T.q|
000019c0  25 21 34 3d 69 68 25 0d  0b 5e 1d c8 99 22 57 69  |%!4=ih%..^..."Wi|
000019d0  6d 70 5f 47 65 74 49 63  6f 6e 53 74 61 74 65 22  |mp_GetIconState"|
000019e0  2c 2c 71 25 0d 0b 68 0e  71 25 21 38 3d 31 3c 3c  |,,q%..h.q%!8=1<<|
000019f0  32 31 0d 0b 72 0f 71 25  21 31 32 3d 31 3c 3c 32  |21..r.q%!12=1<<2|
00001a00  31 0d 0b 7c 1c 6f 70 74  69 6f 6e 24 3d 22 73 62  |1..|.option$="sb|
00001a10  6f 70 74 6f 6e 2c 62 6f  70 74 6f 6e 22 0d 0b 86  |opton,bopton"...|
00001a20  14 24 28 71 25 21 33 32  29 3d 6f 70 74 69 6f 6e  |.$(q%!32)=option|
00001a30  24 0d 0b 90 14 71 25 21  33 36 3d a9 28 6f 70 74  |$....q%!36=.(opt|
00001a40  69 6f 6e 24 29 0d 0b 9a  1d c8 99 22 57 69 6d 70  |ion$)......"Wimp|
00001a50  5f 53 65 74 49 63 6f 6e  53 74 61 74 65 22 2c 2c  |_SetIconState",,|
00001a60  71 25 0d 0b a4 05 e1 0d  0b ae 04 0d 0b b8 1a dd  |q%..............|
00001a70  20 f2 72 65 73 65 74 5f  69 63 6f 6e 28 77 68 25  | .reset_icon(wh%|
00001a80  2c 69 68 25 29 0d 0b c2  0c 71 25 21 30 3d 77 68  |,ih%)....q%!0=wh|
00001a90  25 0d 0b cc 0c 71 25 21  34 3d 69 68 25 0d 0b d6  |%....q%!4=ih%...|
00001aa0  1d c8 99 22 57 69 6d 70  5f 47 65 74 49 63 6f 6e  |..."Wimp_GetIcon|
00001ab0  53 74 61 74 65 22 2c 2c  71 25 0d 0b e0 0e 71 25  |State",,q%....q%|
00001ac0  21 38 3d 31 3c 3c 32 31  0d 0b ea 0f 71 25 21 31  |!8=1<<21....q%!1|
00001ad0  32 3d 31 3c 3c 32 31 0d  0b f4 1e 6f 70 74 69 6f  |2=1<<21....optio|
00001ae0  6e 24 3d 22 73 62 6f 70  74 6f 66 66 2c 62 6f 70  |n$="sboptoff,bop|
00001af0  74 6f 66 66 22 0d 0b fe  14 24 28 71 25 21 33 32  |toff"....$(q%!32|
00001b00  29 3d 6f 70 74 69 6f 6e  24 0d 0c 08 14 71 25 21  |)=option$....q%!|
00001b10  33 36 3d a9 28 6f 70 74  69 6f 6e 24 29 0d 0c 12  |36=.(option$)...|
00001b20  1d c8 99 22 57 69 6d 70  5f 53 65 74 49 63 6f 6e  |..."Wimp_SetIcon|
00001b30  53 74 61 74 65 22 2c 2c  71 25 0d 0c 1c 05 e1 0d  |State",,q%......|
00001b40  0c 26 04 0d 0c 30 0d dd  20 f2 66 6f 72 63 6f 6c  |.&...0.. .forcol|
00001b50  0d 0c 3a 0e 66 6f 72 65  63 6f 6c 25 3d 30 0d 0c  |..:.forecol%=0..|
00001b60  44 25 e7 20 28 69 25 20  80 20 28 31 3c 3c 32 34  |D%. (i% . (1<<24|
00001b70  29 29 3d 32 5e 32 34 20  66 6f 72 65 63 6f 6c 25  |))=2^24 forecol%|
00001b80  2b 3d 31 0d 0c 4e 25 e7  20 28 69 25 20 80 20 28  |+=1..N%. (i% . (|
00001b90  31 3c 3c 32 35 29 29 3d  32 5e 32 35 20 66 6f 72  |1<<25))=2^25 for|
00001ba0  65 63 6f 6c 25 2b 3d 32  0d 0c 58 25 e7 20 28 69  |ecol%+=2..X%. (i|
00001bb0  25 20 80 20 28 31 3c 3c  32 36 29 29 3d 32 5e 32  |% . (1<<26))=2^2|
00001bc0  36 20 66 6f 72 65 63 6f  6c 25 2b 3d 34 0d 0c 62  |6 forecol%+=4..b|
00001bd0  25 e7 20 28 69 25 20 80  20 28 31 3c 3c 32 37 29  |%. (i% . (1<<27)|
00001be0  29 3d 32 5e 32 37 20 66  6f 72 65 63 6f 6c 25 2b  |)=2^27 forecol%+|
00001bf0  3d 38 0d 0c 6c 0e 71 25  21 30 3d 6d 61 69 6e 25  |=8..l.q%!0=main%|
00001c00  0d 0c 76 0b 71 25 21 34  3d 33 35 0d 0c 80 15 71  |..v.q%!4=35....q|
00001c10  25 21 38 3d 66 6f 72 65  63 6f 6c 25 3c 3c 32 38  |%!8=forecol%<<28|
00001c20  0d 0c 8a 13 71 25 21 31  32 3d 25 31 31 31 31 3c  |....q%!12=%1111<|
00001c30  3c 32 38 0d 0c 94 1d c8  99 22 57 69 6d 70 5f 53  |<28......"Wimp_S|
00001c40  65 74 49 63 6f 6e 53 74  61 74 65 22 2c 2c 71 25  |etIconState",,q%|
00001c50  0d 0c 9e 05 e1 0d 0c a8  04 0d 0c b2 0e dd 20 f2  |.............. .|
00001c60  62 61 63 6b 63 6f 6c 0d  0c bc 0e 62 61 63 6b 63  |backcol....backc|
00001c70  6f 6c 25 3d 30 0d 0c c6  25 e7 20 28 69 25 20 80  |ol%=0...%. (i% .|
00001c80  20 28 31 3c 3c 32 38 29  29 3d 32 5e 32 38 20 62  | (1<<28))=2^28 b|
00001c90  61 63 6b 63 6f 6c 25 2b  3d 31 0d 0c d0 25 e7 20  |ackcol%+=1...%. |
00001ca0  28 69 25 20 80 20 28 31  3c 3c 32 39 29 29 3d 32  |(i% . (1<<29))=2|
00001cb0  5e 32 39 20 62 61 63 6b  63 6f 6c 25 2b 3d 32 0d  |^29 backcol%+=2.|
00001cc0  0c da 25 e7 20 28 69 25  20 80 20 28 31 3c 3c 33  |..%. (i% . (1<<3|
00001cd0  30 29 29 3d 32 5e 33 30  20 62 61 63 6b 63 6f 6c  |0))=2^30 backcol|
00001ce0  25 2b 3d 34 0d 0c e4 28  e7 20 28 69 25 20 80 20  |%+=4...(. (i% . |
00001cf0  28 31 3c 3c 33 31 29 29  3d 2d 28 32 5e 33 31 29  |(1<<31))=-(2^31)|
00001d00  20 62 61 63 6b 63 6f 6c  25 2b 3d 38 0d 0c ee 0e  | backcol%+=8....|
00001d10  71 25 21 30 3d 6d 61 69  6e 25 0d 0c f8 0b 71 25  |q%!0=main%....q%|
00001d20  21 34 3d 33 36 0d 0d 02  15 71 25 21 38 3d 62 61  |!4=36....q%!8=ba|
00001d30  63 6b 63 6f 6c 25 3c 3c  32 38 0d 0d 0c 13 71 25  |ckcol%<<28....q%|
00001d40  21 31 32 3d 25 31 31 31  31 3c 3c 32 38 0d 0d 16  |!12=%1111<<28...|
00001d50  1d c8 99 22 57 69 6d 70  5f 53 65 74 49 63 6f 6e  |..."Wimp_SetIcon|
00001d60  53 74 61 74 65 22 2c 2c  71 25 0d 0d 20 05 e1 0d  |State",,q%.. ...|
00001d70  0d 2a 04 0d 0d 34 0a dd  20 f2 65 73 67 0d 0d 3e  |.*...4.. .esg..>|
00001d80  0a 65 73 67 25 3d 30 0d  0d 48 21 e7 20 28 69 25  |.esg%=0..H!. (i%|
00001d90  20 80 20 28 31 3c 3c 31  36 29 29 3d 32 5e 31 36  | . (1<<16))=2^16|
00001da0  20 65 73 67 25 2b 3d 31  0d 0d 52 21 e7 20 28 69  | esg%+=1..R!. (i|
00001db0  25 20 80 20 28 31 3c 3c  31 37 29 29 3d 32 5e 31  |% . (1<<17))=2^1|
00001dc0  37 20 65 73 67 25 2b 3d  32 0d 0d 5c 21 e7 20 28  |7 esg%+=2..\!. (|
00001dd0  69 25 20 80 20 28 31 3c  3c 31 38 29 29 3d 32 5e  |i% . (1<<18))=2^|
00001de0  31 38 20 65 73 67 25 2b  3d 34 0d 0d 66 21 e7 20  |18 esg%+=4..f!. |
00001df0  28 69 25 20 80 20 28 31  3c 3c 31 39 29 29 3d 32  |(i% . (1<<19))=2|
00001e00  5e 31 39 20 65 73 67 25  2b 3d 38 0d 0d 70 22 e7  |^19 esg%+=8..p".|
00001e10  20 28 69 25 20 80 20 28  31 3c 3c 32 30 29 29 3d  | (i% . (1<<20))=|
00001e20  32 5e 32 30 20 65 73 67  25 2b 3d 31 36 0d 0d 7a  |2^20 esg%+=16..z|
00001e30  0e 71 25 21 30 3d 6d 61  69 6e 25 0d 0d 84 0b 71  |.q%!0=main%....q|
00001e40  25 21 34 3d 33 34 0d 0d  8e 1d c8 99 22 57 69 6d  |%!4=34......"Wim|
00001e50  70 5f 47 65 74 49 63 6f  6e 53 74 61 74 65 22 2c  |p_GetIconState",|
00001e60  2c 71 25 0d 0d 98 0d 71  25 21 38 3d 31 3c 3c 30  |,q%....q%!8=1<<0|
00001e70  0d 0d a2 0e 71 25 21 31  32 3d 31 3c 3c 30 0d 0d  |....q%!12=1<<0..|
00001e80  ac 13 6f 70 74 69 6f 6e  24 3d c3 28 65 73 67 25  |..option$=.(esg%|
00001e90  29 0d 0d b6 14 24 28 71  25 21 32 38 29 3d 6f 70  |)....$(q%!28)=op|
00001ea0  74 69 6f 6e 24 0d 0d c0  14 71 25 21 33 36 3d a9  |tion$....q%!36=.|
00001eb0  28 6f 70 74 69 6f 6e 24  29 0d 0d ca 1d c8 99 22  |(option$)......"|
00001ec0  57 69 6d 70 5f 53 65 74  49 63 6f 6e 53 74 61 74  |Wimp_SetIconStat|
00001ed0  65 22 2c 2c 71 25 0d 0d  d4 05 e1 0d 0d de 04 0d  |e",,q%..........|
00001ee0  0d e8 0e dd 20 f2 62 75  74 74 73 65 6c 0d 0d f2  |.... .buttsel...|
00001ef0  0d 62 75 74 6e 75 6d 25  3d 30 0d 0d fc 24 e7 20  |.butnum%=0...$. |
00001f00  28 69 25 20 80 20 28 31  3c 3c 31 32 29 29 3d 32  |(i% . (1<<12))=2|
00001f10  5e 31 32 20 62 75 74 6e  75 6d 25 2b 3d 31 0d 0e  |^12 butnum%+=1..|
00001f20  06 24 e7 20 28 69 25 20  80 20 28 31 3c 3c 31 33  |.$. (i% . (1<<13|
00001f30  29 29 3d 32 5e 31 33 20  62 75 74 6e 75 6d 25 2b  |))=2^13 butnum%+|
00001f40  3d 32 0d 0e 10 24 e7 20  28 69 25 20 80 20 28 31  |=2...$. (i% . (1|
00001f50  3c 3c 31 34 29 29 3d 32  5e 31 34 20 62 75 74 6e  |<<14))=2^14 butn|
00001f60  75 6d 25 2b 3d 34 0d 0e  1a 24 e7 20 28 69 25 20  |um%+=4...$. (i% |
00001f70  80 20 28 31 3c 3c 31 35  29 29 3d 32 5e 31 35 20  |. (1<<15))=2^15 |
00001f80  62 75 74 6e 75 6d 25 2b  3d 38 0d 0e 24 30 f2 62  |butnum%+=8..$0.b|
00001f90  75 74 74 6f 6e 73 28 62  75 74 6e 75 6d 25 29 3a  |uttons(butnum%):|
00001fa0  f3 20 61 24 3a 61 24 3d  c3 28 62 75 74 6e 75 6d  |. a$:a$=.(butnum|
00001fb0  25 29 2b 22 20 20 22 2b  61 24 0d 0e 2e 0e 71 25  |%)+"  "+a$....q%|
00001fc0  21 30 3d 6d 61 69 6e 25  0d 0e 38 0b 71 25 21 34  |!0=main%..8.q%!4|
00001fd0  3d 33 33 0d 0e 42 1d c8  99 22 57 69 6d 70 5f 47  |=33..B..."Wimp_G|
00001fe0  65 74 49 63 6f 6e 53 74  61 74 65 22 2c 2c 71 25  |etIconState",,q%|
00001ff0  0d 0e 4c 0d 71 25 21 38  3d 31 3c 3c 30 0d 0e 56  |..L.q%!8=1<<0..V|
00002000  0e 71 25 21 31 32 3d 31  3c 3c 30 0d 0e 60 0e 6f  |.q%!12=1<<0..`.o|
00002010  70 74 69 6f 6e 24 3d 61  24 0d 0e 6a 14 24 28 71  |ption$=a$..j.$(q|
00002020  25 21 32 38 29 3d 6f 70  74 69 6f 6e 24 0d 0e 74  |%!28)=option$..t|
00002030  14 71 25 21 33 36 3d a9  28 6f 70 74 69 6f 6e 24  |.q%!36=.(option$|
00002040  29 0d 0e 7e 1d c8 99 22  57 69 6d 70 5f 53 65 74  |)..~..."Wimp_Set|
00002050  49 63 6f 6e 53 74 61 74  65 22 2c 2c 71 25 0d 0e  |IconState",,q%..|
00002060  88 05 e1 0d 0e 92 04 0d  0e 9c 15 dd 20 f2 62 75  |............ .bu|
00002070  74 74 6f 6e 73 28 74 79  70 65 25 29 0d 0e a6 10  |ttons(type%)....|
00002080  f7 20 2b 28 74 79 70 65  25 2b 31 29 0d 0e b0 0d  |. +(type%+1)....|
00002090  dc 20 22 4e 65 76 65 72  22 0d 0e ba 0e dc 20 22  |. "Never"..... "|
000020a0  41 6c 77 61 79 73 22 0d  0e c4 13 dc 20 22 41 75  |Always"..... "Au|
000020b0  74 6f 20 72 65 70 65 61  74 22 0d 0e ce 0d dc 20  |to repeat"..... |
000020c0  22 43 6c 69 63 6b 22 0d  0e d8 0f dc 20 22 52 65  |"Click"..... "Re|
000020d0  6c 65 61 73 65 22 0d 0e  e2 14 dc 20 22 44 6f 75  |lease"..... "Dou|
000020e0  62 6c 65 20 43 6c 69 63  6b 22 0d 0e ec 12 dc 20  |ble Click"..... |
000020f0  22 43 6c 69 63 6b 2f 44  72 61 67 22 0d 0e f6 14  |"Click/Drag"....|
00002100  dc 20 22 52 65 6c 65 61  73 65 2f 44 72 61 67 22  |. "Release/Drag"|
00002110  0d 0f 00 13 dc 20 22 44  6f 75 62 6c 65 2f 44 72  |..... "Double/Dr|
00002120  61 67 22 0d 0f 0a 11 dc  20 22 4d 65 6e 75 20 49  |ag"..... "Menu I|
00002130  63 6f 6e 22 0d 0f 14 19  dc 20 22 44 6f 75 62 6c  |con"..... "Doubl|
00002140  65 2f 43 6c 69 63 6b 2f  44 72 61 67 22 0d 0f 1e  |e/Click/Drag"...|
00002150  10 dc 20 22 52 65 73 65  72 76 65 64 22 0d 0f 28  |.. "Reserved"..(|
00002160  10 dc 20 22 52 65 73 65  72 76 65 64 22 0d 0f 32  |.. "Reserved"..2|
00002170  10 dc 20 22 52 65 73 65  72 76 65 64 22 0d 0f 3c  |.. "Reserved"..<|
00002180  18 dc 20 22 57 72 69 74  65 2f 43 6c 69 63 6b 2f  |.. "Write/Click/|
00002190  44 72 61 67 22 0d 0f 46  11 dc 20 22 57 72 69 74  |Drag"..F.. "Writ|
000021a0  65 61 62 6c 65 22 0d 0f  50 05 e1 0d ff           |eable"..P....|
000021ad