Rev 485 | Rev 2704 | Go to most recent revision | Only display areas with differences | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 485 | Rev 551 | ||
---|---|---|---|
1 | ; COLORREF.ASM - COLOR REFERENCE |
1 | ; COLORREF.ASM - COLOR REFERENCE |
2 | ; |
2 | ; |
3 | ; Compile with FASM for Menuet |
3 | ; Compile with FASM for Menuet |
4 | ; |
4 | ; |
5 | 5 | ||
6 | use32 |
6 | use32 |
7 | org 0x0 |
7 | org 0x0 |
8 | 8 | ||
9 | db 'MENUET01' ; 8 byte id |
9 | db 'MENUET01' ; 8 byte id |
10 | dd 0x01 ; header version |
10 | dd 0x01 ; header version |
11 | dd start ; start of code |
11 | dd start ; start of code |
12 | dd finis ; size of image |
12 | dd finis ; size of image |
13 | dd 0x1000 ; memory for app |
13 | dd 0x1000 ; memory for app |
14 | dd 0x1000 ; esp |
14 | dd 0x1000 ; esp |
15 | dd 0x0,0x0 ; I_Param , I_Icon |
15 | dd 0x0,0x0 ; I_Param , I_Icon |
16 | 16 | ||
17 | include 'lang.inc' |
17 | include 'lang.inc' |
18 | include '..\..\..\macros.inc' |
18 | include '..\..\..\macros.inc' |
19 | wide: dd 0 ; screen pixels width |
19 | wide: dd 0 ; screen pixels width |
20 | mouse: dd 0 ; 1=right,2=left [mouse click] |
20 | mouse: dd 0 ; 1=right,2=left [mouse click] |
21 | 21 | ||
22 | 22 | ||
23 | start: |
23 | start: |
24 | 24 | ||
25 | mov eax,14 ; get screen size |
25 | mov eax,14 ; get screen size |
26 | mcall |
26 | mcall |
27 | shr eax,16 ; get width into AX |
27 | shr eax,16 ; get width into AX |
28 | inc eax ; not 0 based |
28 | inc eax ; not 0 based |
29 | mov [wide],eax |
29 | mov [wide],eax |
30 | 30 | ||
31 | call draw_window |
31 | call draw_window |
32 | 32 | ||
33 | still: |
33 | still: |
34 | mov eax,23 ; wait for event w/timeout |
34 | mov eax,23 ; wait for event w/timeout |
35 | mov ebx,5 ; delay in hundredths |
35 | mov ebx,5 ; delay in hundredths |
36 | mcall |
36 | mcall |
37 | 37 | ||
38 | cmp eax,1 ; redraw request ? |
38 | cmp eax,1 ; redraw request ? |
39 | jne s1 |
39 | jne s1 |
40 | jmp red |
40 | jmp red |
41 | s1: cmp eax,2 ; key in buffer ? |
41 | s1: cmp eax,2 ; key in buffer ? |
42 | jne s2 |
42 | jne s2 |
43 | jmp key |
43 | jmp key |
44 | s2: cmp eax,3 ; button in buffer ? |
44 | s2: cmp eax,3 ; button in buffer ? |
45 | jne s3 |
45 | jne s3 |
46 | jmp button |
46 | jmp button |
47 | s3: mov eax,9 ; process info function |
47 | s3: mov eax,9 ; process info function |
48 | mov ebx,stat_table ; return data table |
48 | mov ebx,stat_table ; return data table |
49 | mov ecx,-1 ; who am i |
49 | mov ecx,-1 ; who am i |
50 | mcall |
50 | mcall |
51 | cmp ax,[stat_table+4] ; are we active? |
51 | cmp ax,[stat_table+4] ; are we active? |
52 | je active ; yep |
52 | je active ; yep |
53 | jmp still |
53 | jmp still |
54 | 54 | ||
55 | active: |
55 | active: |
56 | mov eax,37 ; mouse info function |
56 | mov eax,37 ; mouse info function |
57 | mov ebx,2 ; get buttons |
57 | mov ebx,2 ; get buttons |
58 | mcall |
58 | mcall |
59 | cmp eax,0 ; mouse click? |
59 | cmp eax,0 ; mouse click? |
60 | jne click |
60 | jne click |
61 | jmp still |
61 | jmp still |
62 | click: |
62 | click: |
63 | mov [mouse],eax ; save mouse click |
63 | mov [mouse],eax ; save mouse click |
64 | mov eax,37 ; mouse info |
64 | mov eax,37 ; mouse info |
65 | xor ebx,ebx ; get screen pos for mouse |
65 | xor ebx,ebx ; get screen pos for mouse |
66 | mcall ; into EAX |
66 | mcall ; into EAX |
67 | xor ebx,ebx |
67 | xor ebx,ebx |
68 | mov bx,ax ; BX=y screen position |
68 | mov bx,ax ; BX=y screen position |
69 | shr eax,16 ; AX=x screen position |
69 | shr eax,16 ; AX=x screen position |
70 | xchg eax,ebx ; EAX=y, EBX=x |
70 | xchg eax,ebx ; EAX=y, EBX=x |
71 | dec eax ; don't calc mouse scanline |
71 | dec eax ; don't calc mouse scanline |
72 | mov ecx,[wide] ; get pixels wide |
72 | mov ecx,[wide] ; get pixels wide |
73 | mul ecx |
73 | mul ecx |
74 | add ebx,eax ; add x |
74 | add ebx,eax ; add x |
75 | mov eax,35 ; get mouse pos pixel |
75 | mov eax,35 ; get mouse pos pixel |
76 | mcall ; EAX=mouse pixel color |
76 | mcall ; EAX=mouse pixel color |
77 | mov ebx,eax ; EBX has color |
77 | mov ebx,eax ; EBX has color |
78 | mov esi,colors ; color table |
78 | mov esi,colors ; color table |
79 | mov ecx,72 ; total colors |
79 | mov ecx,72 ; total colors |
80 | xor edx,edx ; init a counter |
80 | xor edx,edx ; init a counter |
81 | check: |
81 | check: |
82 | lodsd |
82 | lodsd |
83 | inc edx ; update counter |
83 | inc edx ; update counter |
84 | cmp ebx,eax ; color match? |
84 | cmp ebx,eax ; color match? |
85 | je _match ; yep |
85 | je _match ; yep |
86 | loop check ; check all colors |
86 | loop check ; check all colors |
87 | jmp still ; no match |
87 | jmp still ; no match |
88 | _match: |
88 | _match: |
89 | cmp [mouse],dword 1 ; right click? |
89 | cmp [mouse],dword 1 ; right click? |
90 | je right ; yep |
90 | je right ; yep |
91 | left: |
91 | left: |
92 | cmp [picks],edx ; changed left color yet? |
92 | cmp [picks],edx ; changed left color yet? |
93 | jne l1 ; no, do it |
93 | jne l1 ; no, do it |
94 | jmp still |
94 | jmp still |
95 | l1: mov [picks],edx ; update left pick color |
95 | l1: mov [picks],edx ; update left pick color |
96 | call clear ; erase old text |
96 | call clear ; erase old text |
97 | call draw_picks ; redraw colors and text |
97 | call draw_picks ; redraw colors and text |
98 | jmp still |
98 | jmp still |
99 | right: |
99 | right: |
100 | cmp [picks+4],edx ; changed right color yet? |
100 | cmp [picks+4],edx ; changed right color yet? |
101 | jne r1 ; no, do it |
101 | jne r1 ; no, do it |
102 | jmp still |
102 | jmp still |
103 | r1: mov [picks+4],edx ; update right pick color |
103 | r1: mov [picks+4],edx ; update right pick color |
104 | call clear ; erase old text |
104 | call clear ; erase old text |
105 | call draw_picks ; redraw colors and text |
105 | call draw_picks ; redraw colors and text |
106 | jmp still |
106 | jmp still |
107 | 107 | ||
108 | red: ; redraw |
108 | red: ; redraw |
109 | call draw_window |
109 | call draw_window |
110 | jmp still |
110 | jmp still |
111 | 111 | ||
112 | key: ; key |
112 | key: ; key |
113 | mov eax,2 ; just read it and ignore |
113 | mov eax,2 ; just read it and ignore |
114 | mcall |
114 | mcall |
115 | cmp al,0 ; key in buffer? |
115 | cmp al,0 ; key in buffer? |
116 | je k1 ; yep |
116 | je k1 ; yep |
117 | jmp still |
117 | jmp still |
118 | k1: cmp ah,'H' ; cap H ? |
118 | k1: cmp ah,'H' ; cap H ? |
119 | je k2 ; yep |
119 | je k2 ; yep |
120 | cmp ah,'h' ; locase h ? |
120 | cmp ah,'h' ; locase h ? |
121 | je k2 ; yep |
121 | je k2 ; yep |
122 | jmp still |
122 | jmp still |
123 | k2: call help ; show help screen |
123 | k2: call help ; show help screen |
124 | jmp still |
124 | jmp still |
125 | 125 | ||
126 | button: ; button |
126 | button: ; button |
127 | mov eax,17 ; get id |
127 | mov eax,17 ; get id |
128 | mcall |
128 | mcall |
129 | cmp ah,1 ; button id=1 ? |
129 | cmp ah,1 ; button id=1 ? |
130 | je close |
130 | je close |
131 | jmp still |
131 | jmp still |
132 | 132 | ||
133 | close: |
133 | close: |
134 | mov eax,-1 ; close this program |
134 | mov eax,-1 ; close this program |
135 | mcall |
135 | mcall |
136 | 136 | ||
137 | 137 | ||
138 | ; ********************************************* |
138 | ; ********************************************* |
139 | ; ******* WINDOW DEFINITIONS AND DRAW ******** |
139 | ; ******* WINDOW DEFINITIONS AND DRAW ******** |
140 | ; ********************************************* |
140 | ; ********************************************* |
141 | 141 | ||
142 | 142 | ||
143 | draw_window: |
143 | draw_window: |
144 | 144 | ||
145 | mov eax,12 ; tell os about windowdraw |
145 | mov eax,12 ; tell os about windowdraw |
146 | mov ebx,1 ; 1, start of draw |
146 | mov ebx,1 ; 1, start of draw |
147 | mcall |
147 | mcall |
148 | 148 | ||
149 | mov eax,0 ; DRAW WINDOW |
149 | mov eax,0 ; DRAW WINDOW |
150 | mov ebx,1*65536+200 ; [x start] *65536 + [x size] |
150 | mov ebx,1*65536+200 ; [x start] *65536 + [x size] |
151 | mov ecx,200*65536+240 ; [y start] *65536 + [y size] |
151 | mov ecx,200*65536+240 ; [y start] *65536 + [y size] |
152 | mov edx,0x13000000 ; work area color (type II) |
152 | mov edx,0x14000000 ; work area color (type II) |
153 | mov edi,title ; frame color |
153 | mov edi,title ; frame color |
154 | mcall |
154 | mcall |
155 | 155 | ||
156 | call palette ; display color palette |
156 | call palette ; display color palette |
157 | 157 | ||
158 | mov eax,12 ; tell os about windowdraw |
158 | mov eax,12 ; tell os about windowdraw |
159 | mov ebx,2 ; 2, end of draw |
159 | mov ebx,2 ; 2, end of draw |
160 | mcall |
160 | mcall |
161 | 161 | ||
162 | ret |
162 | ret |
163 | 163 | ||
164 | 164 | ||
165 | ; ********************************************* |
165 | ; ********************************************* |
166 | ; ******* COLOR PALETTE LAYOUT ROUTINES ****** |
166 | ; ******* COLOR PALETTE LAYOUT ROUTINES ****** |
167 | ; ********************************************* |
167 | ; ********************************************* |
168 | 168 | ||
169 | 169 | ||
170 | palette: |
170 | palette: |
171 | mov ebx,15*65536+18 ; LAYOUT: start x and width |
171 | mov ebx,15*65536+18 ; LAYOUT: start x and width |
172 | mov edx,32*65536+18 ; LAYOUT: start y and depth |
172 | mov edx,32*65536+18 ; LAYOUT: start y and depth |
173 | mov ecx,8 ; 8 rows |
173 | mov ecx,8 ; 8 rows |
174 | mov ebp,colors ; color table |
174 | mov ebp,colors ; color table |
175 | p1: push ecx |
175 | p1: push ecx |
176 | mov ecx,9 ; 9 columns |
176 | mov ecx,9 ; 9 columns |
177 | p2: push ecx |
177 | p2: push ecx |
178 | push edx |
178 | push edx |
179 | mov ecx,edx ; y coord |
179 | mov ecx,edx ; y coord |
180 | mov edx,[ebp] ; color |
180 | mov edx,[ebp] ; color |
181 | mov eax,13 ; draw bar function |
181 | mov eax,13 ; draw bar function |
182 | mcall |
182 | mcall |
183 | pop edx |
183 | pop edx |
184 | pop ecx |
184 | pop ecx |
185 | add ebx,19*65536 ; next column |
185 | add ebx,19*65536 ; next column |
186 | add ebp,4 ; next color |
186 | add ebp,4 ; next color |
187 | p3: loop p2 |
187 | p3: loop p2 |
188 | pop ecx |
188 | pop ecx |
189 | mov ebx,15*65536+18 ; restart x |
189 | mov ebx,15*65536+18 ; restart x |
190 | add edx,19*65536 ; next row |
190 | add edx,19*65536 ; next row |
191 | loop p1 |
191 | loop p1 |
192 | call draw_picks |
192 | call draw_picks |
193 | 193 | ||
194 | ret |
194 | ret |
195 | 195 | ||
196 | draw_picks: |
196 | draw_picks: |
197 | mov ebx,64*65536+24 ; draw x and width |
197 | mov ebx,64*65536+24 ; draw x and width |
198 | mov ecx,188*65536+42 ; draw y and depth |
198 | mov ecx,188*65536+42 ; draw y and depth |
199 | mov edx,0xc0c0c0 ; color grey |
199 | mov edx,0xc0c0c0 ; color grey |
200 | mov eax,13 ; draw bar function |
200 | mov eax,13 ; draw bar function |
201 | mcall |
201 | mcall |
202 | mov eax,[picks] ; first picked color |
202 | mov eax,[picks] ; first picked color |
203 | mov esi,22*65536+196 ; print at x and y |
203 | mov esi,22*65536+196 ; print at x and y |
204 | call do_hex ; print color number |
204 | call do_hex ; print color number |
205 | mov eax,[picks+4] ; second picked color |
205 | mov eax,[picks+4] ; second picked color |
206 | mov esi,22*65536+215 ; print at x and y |
206 | mov esi,22*65536+215 ; print at x and y |
207 | call do_hex ; print color number |
207 | call do_hex ; print color number |
208 | mov eax,[picks] ; first picked color |
208 | mov eax,[picks] ; first picked color |
209 | mov ebx,67*65536+18 ; x and width |
209 | mov ebx,67*65536+18 ; x and width |
210 | mov esi,191*65536+18 ; y and depth |
210 | mov esi,191*65536+18 ; y and depth |
211 | call do_color ; paint color 1 square |
211 | call do_color ; paint color 1 square |
212 | mov eax,[picks+4] ; second picked color |
212 | mov eax,[picks+4] ; second picked color |
213 | mov ebx,67*65536+18 ; x and width |
213 | mov ebx,67*65536+18 ; x and width |
214 | mov esi,209*65536+18 ; y and depth |
214 | mov esi,209*65536+18 ; y and depth |
215 | call do_color ; paint color 2 square |
215 | call do_color ; paint color 2 square |
216 | mov eax,[picks] ; first picked color |
216 | mov eax,[picks] ; first picked color |
217 | mov ebx,96*65536+196 ; x and y |
217 | mov ebx,96*65536+196 ; x and y |
218 | call do_name ; print color's name |
218 | call do_name ; print color's name |
219 | mov eax,[picks+4] ; second picked color |
219 | mov eax,[picks+4] ; second picked color |
220 | mov ebx,96*65536+215 ; x and y |
220 | mov ebx,96*65536+215 ; x and y |
221 | call do_name ; print color's name |
221 | call do_name ; print color's name |
222 | 222 | ||
223 | ret |
223 | ret |
224 | 224 | ||
225 | do_hex: |
225 | do_hex: |
226 | dec eax ; use 0 base |
226 | dec eax ; use 0 base |
227 | mov ecx,4 ; dword length |
227 | mov ecx,4 ; dword length |
228 | mul ecx ; calc pointer |
228 | mul ecx ; calc pointer |
229 | mov edi,colors ; color table |
229 | mov edi,colors ; color table |
230 | add edi,eax ; add offset |
230 | add edi,eax ; add offset |
231 | mov ecx,[edi] ; save color 1 |
231 | mov ecx,[edi] ; save color 1 |
232 | mov ebx,0x60100 ; print 6 hex digits |
232 | mov ebx,0x60100 ; print 6 hex digits |
233 | mov edx,esi ; copy color |
233 | mov edx,esi ; copy color |
234 | mov esi,0xe1e1e1 ; use white |
234 | mov esi,0xe1e1e1 ; use white |
235 | mov eax,47 ; print number function |
235 | mov eax,47 ; print number function |
236 | mcall |
236 | mcall |
237 | 237 | ||
238 | ret |
238 | ret |
239 | 239 | ||
240 | do_color: |
240 | do_color: |
241 | dec eax ; use 0 base |
241 | dec eax ; use 0 base |
242 | mov ecx,4 ; dword length |
242 | mov ecx,4 ; dword length |
243 | mul ecx ; calc pointer |
243 | mul ecx ; calc pointer |
244 | mov edi,colors ; color table |
244 | mov edi,colors ; color table |
245 | add edi,eax ; add offset |
245 | add edi,eax ; add offset |
246 | mov edx,[edi] ; color |
246 | mov edx,[edi] ; color |
247 | mov ecx,esi ; recover y an depth |
247 | mov ecx,esi ; recover y an depth |
248 | mov eax,13 ; draw bar function |
248 | mov eax,13 ; draw bar function |
249 | mcall |
249 | mcall |
250 | 250 | ||
251 | ret |
251 | ret |
252 | 252 | ||
253 | do_name: |
253 | do_name: |
254 | dec eax ; use 0 base |
254 | dec eax ; use 0 base |
255 | mov ecx,15 ; string length |
255 | mov ecx,15 ; string length |
256 | mul ecx ; calc pointer |
256 | mul ecx ; calc pointer |
257 | mov edx,names ; color table |
257 | mov edx,names ; color table |
258 | add edx,eax ; add offset |
258 | add edx,eax ; add offset |
259 | mov ecx,0xe1e1e1 ; color |
259 | mov ecx,0xe1e1e1 ; color |
260 | mov esi,15 |
260 | mov esi,15 |
261 | mov eax,4 ; print text function |
261 | mov eax,4 ; print text function |
262 | mcall |
262 | mcall |
263 | 263 | ||
264 | ret |
264 | ret |
265 | 265 | ||
266 | clear: |
266 | clear: |
267 | mov ebx,22*65536+36 ; x and width |
267 | mov ebx,22*65536+36 ; x and width |
268 | mov ecx,196*65536+26 ; y and depth |
268 | mov ecx,196*65536+26 ; y and depth |
269 | mov edx,0x000000 ; color |
269 | mov edx,0x000000 ; color |
270 | mov eax,13 ; draw bar funx |
270 | mov eax,13 ; draw bar funx |
271 | mcall |
271 | mcall |
272 | mov ebx,96*65536+90 ; x and width |
272 | mov ebx,96*65536+90 ; x and width |
273 | mov ecx,196*65536+26 ; y and depth |
273 | mov ecx,196*65536+26 ; y and depth |
274 | mov edx,0x000000 ; color |
274 | mov edx,0x000000 ; color |
275 | mov eax,13 ; draw bar funx |
275 | mov eax,13 ; draw bar funx |
276 | mcall |
276 | mcall |
277 | 277 | ||
278 | ret |
278 | ret |
279 | 279 | ||
280 | help: |
280 | help: |
281 | mov ebx,4*65536+192 ; x and width |
281 | mov ebx,4*65536+192 ; x and width |
282 | mov ecx,20*65536+216 ; y and depth |
282 | mov ecx,20*65536+216 ; y and depth |
283 | mov edx,0x465e8f ; dark denim color |
283 | mov edx,0x465e8f ; dark denim color |
284 | mov eax,13 ; write text funx |
284 | mov eax,13 ; write text funx |
285 | mcall |
285 | mcall |
286 | mov ebx,20*65536+40 ; starting x and y |
286 | mov ebx,20*65536+40 ; starting x and y |
287 | mov edx,text ; start of text |
287 | mov edx,text ; start of text |
288 | mov esi,27 ; width of text |
288 | mov esi,27 ; width of text |
289 | mov ecx,14 ; 14 text lines to do |
289 | mov ecx,14 ; 14 text lines to do |
290 | mov eax,4 ; write text funx |
290 | mov eax,4 ; write text funx |
291 | h1: push ecx |
291 | h1: push ecx |
292 | sub ebx,65537 ; drop shadow x and y |
292 | sub ebx,65537 ; drop shadow x and y |
293 | mov ecx,0x000000 ; black shadow |
293 | mov ecx,0x000000 ; black shadow |
294 | mcall |
294 | mcall |
295 | add ebx,65537 ; original x and y |
295 | add ebx,65537 ; original x and y |
296 | mov ecx,0xefefef ; white text |
296 | mov ecx,0xefefef ; white text |
297 | mcall |
297 | mcall |
298 | add edx,27 ; next line of text |
298 | add edx,27 ; next line of text |
299 | add bx,12 ; next row |
299 | add bx,12 ; next row |
300 | pop ecx |
300 | pop ecx |
301 | loop h1 |
301 | loop h1 |
302 | mov eax,10 ; wait on event |
302 | mov eax,10 ; wait on event |
303 | mcall |
303 | mcall |
304 | cmp eax,2 ; got a key? |
304 | cmp eax,2 ; got a key? |
305 | jne h2 ; nope |
305 | jne h2 ; nope |
306 | mov eax,2 ; yep, burn it |
306 | mov eax,2 ; yep, burn it |
307 | mcall |
307 | mcall |
308 | h2: mov ebx,4*65536+192 ; y and width |
308 | h2: mov ebx,4*65536+192 ; y and width |
309 | mov ecx,20*65536+216 ; x and depth |
309 | mov ecx,20*65536+216 ; x and depth |
310 | mov edx,0x00000 ; restore black bkg |
310 | mov edx,0x00000 ; restore black bkg |
311 | mov eax,13 ; draw bar funx |
311 | mov eax,13 ; draw bar funx |
312 | mcall |
312 | mcall |
313 | call palette ; redraw color palette |
313 | call palette ; redraw color palette |
314 | 314 | ||
315 | ret |
315 | ret |
316 | 316 | ||
317 | 317 | ||
318 | ; ********************************************* |
318 | ; ********************************************* |
319 | ; ********** DATA DEFINITIONS AREA *********** |
319 | ; ********** DATA DEFINITIONS AREA *********** |
320 | ; ********************************************* |
320 | ; ********************************************* |
321 | 321 | ||
322 | title db 'COLOR REFERENCE H>HELP',0 |
322 | title db 'COLOR REFERENCE H>HELP',0 |
323 | 323 | ||
324 | picks: |
324 | picks: |
325 | dd 31,2 ; selected top/bot colors |
325 | dd 31,2 ; selected top/bot colors |
326 | 326 | ||
327 | colors: |
327 | colors: |
328 | dd 0xe0e0e0 ; white |
328 | dd 0xe0e0e0 ; white |
329 | dd 0xe7e6a0 ; pale yellow |
329 | dd 0xe7e6a0 ; pale yellow |
330 | dd 0xe7e05a ; lemon yellow |
330 | dd 0xe7e05a ; lemon yellow |
331 | dd 0xe7c750 ; mustard |
331 | dd 0xe7c750 ; mustard |
332 | dd 0xe7b850 ; cadium yellow |
332 | dd 0xe7b850 ; cadium yellow |
333 | dd 0xbfa461 ; yellow ocre |
333 | dd 0xbfa461 ; yellow ocre |
334 | dd 0xe0c090 ; cream |
334 | dd 0xe0c090 ; cream |
335 | dd 0xe0b27b ; peach |
335 | dd 0xe0b27b ; peach |
336 | dd 0xe2986d ; dark peach |
336 | dd 0xe2986d ; dark peach |
337 | dd 0xebb2c0 ; pink |
337 | dd 0xebb2c0 ; pink |
338 | dd 0xe0b0a0 ; flesh |
338 | dd 0xe0b0a0 ; flesh |
339 | dd 0xc79790 ; artificial arm |
339 | dd 0xc79790 ; artificial arm |
340 | dd 0xb88688 ; deep blush |
340 | dd 0xb88688 ; deep blush |
341 | dd 0xc4a077 ; washed khaki |
341 | dd 0xc4a077 ; washed khaki |
342 | dd 0xb69269 ; khaki |
342 | dd 0xb69269 ; khaki |
343 | dd 0xa8845b ; dark khaki |
343 | dd 0xa8845b ; dark khaki |
344 | dd 0xab937a ; beige |
344 | dd 0xab937a ; beige |
345 | dd 0xa39370 ; poupon |
345 | dd 0xa39370 ; poupon |
346 | dd 0x988c00 ; camouflage |
346 | dd 0x988c00 ; camouflage |
347 | dd 0x98a024 ; pale olive |
347 | dd 0x98a024 ; pale olive |
348 | dd 0x838b00 ; olive |
348 | dd 0x838b00 ; olive |
349 | dd 0x6d7600 ; dark olive |
349 | dd 0x6d7600 ; dark olive |
350 | dd 0x5b6200 ; black olive |
350 | dd 0x5b6200 ; black olive |
351 | dd 0x94946a ; washed army |
351 | dd 0x94946a ; washed army |
352 | dd 0x74744a ; army |
352 | dd 0x74744a ; army |
353 | dd 0x66a696 ; pale teal |
353 | dd 0x66a696 ; pale teal |
354 | dd 0x409b90 ; faded teal |
354 | dd 0x409b90 ; faded teal |
355 | dd 0x008d8d ; pastel teal |
355 | dd 0x008d8d ; pastel teal |
356 | dd 0x007c7c ; teal |
356 | dd 0x007c7c ; teal |
357 | dd 0x006464 ; dark teal |
357 | dd 0x006464 ; dark teal |
358 | dd 0x00b8ca ; light turquoise |
358 | dd 0x00b8ca ; light turquoise |
359 | dd 0x00a0b2 ; turquoise |
359 | dd 0x00a0b2 ; turquoise |
360 | dd 0x00889a ; dark turquoise |
360 | dd 0x00889a ; dark turquoise |
361 | dd 0x575f8c ; medium cobalt |
361 | dd 0x575f8c ; medium cobalt |
362 | dd 0x4e4e7c ; cobalt |
362 | dd 0x4e4e7c ; cobalt |
363 | dd 0x00459a ; ultramarine |
363 | dd 0x00459a ; ultramarine |
364 | dd 0x400088 ; navy blue |
364 | dd 0x400088 ; navy blue |
365 | dd 0x4e00e7 ; true blue |
365 | dd 0x4e00e7 ; true blue |
366 | dd 0x508cec ; sky blue |
366 | dd 0x508cec ; sky blue |
367 | dd 0x6a73d0 ; mountain blue |
367 | dd 0x6a73d0 ; mountain blue |
368 | dd 0x677ab0 ; faded jeans |
368 | dd 0x677ab0 ; faded jeans |
369 | dd 0x576fa0 ; denim |
369 | dd 0x576fa0 ; denim |
370 | dd 0xd048c8 ; fuschia |
370 | dd 0xd048c8 ; fuschia |
371 | dd 0xb800e7 ; lavendar |
371 | dd 0xb800e7 ; lavendar |
372 | dd 0xa800a8 ; light violet |
372 | dd 0xa800a8 ; light violet |
373 | dd 0x780078 ; violet |
373 | dd 0x780078 ; violet |
374 | dd 0x520064 ; purple |
374 | dd 0x520064 ; purple |
375 | dd 0xb800b8 ; magenta |
375 | dd 0xb800b8 ; magenta |
376 | dd 0xa4307a ; rose |
376 | dd 0xa4307a ; rose |
377 | dd 0x90207f ; mauve |
377 | dd 0x90207f ; mauve |
378 | dd 0xe76e83 ; salmon |
378 | dd 0xe76e83 ; salmon |
379 | dd 0xea7a7d ; pastel orange |
379 | dd 0xea7a7d ; pastel orange |
380 | dd 0xe26830 ; orange |
380 | dd 0xe26830 ; orange |
381 | dd 0xac5800 ; burnt sienna |
381 | dd 0xac5800 ; burnt sienna |
382 | dd 0xcc0000 ; red orange |
382 | dd 0xcc0000 ; red orange |
383 | dd 0xac0000 ; cadium red |
383 | dd 0xac0000 ; cadium red |
384 | dd 0x880040 ; brick red |
384 | dd 0x880040 ; brick red |
385 | dd 0x780000 ; rust |
385 | dd 0x780000 ; rust |
386 | dd 0x683020 ; terra cotta |
386 | dd 0x683020 ; terra cotta |
387 | dd 0x7f4658 ; light maroon |
387 | dd 0x7f4658 ; light maroon |
388 | dd 0x702050 ; maroon |
388 | dd 0x702050 ; maroon |
389 | dd 0x7a5b5f ; umber blush |
389 | dd 0x7a5b5f ; umber blush |
390 | dd 0x584838 ; burnt umber |
390 | dd 0x584838 ; burnt umber |
391 | dd 0x8a5d1a ; cigar brown |
391 | dd 0x8a5d1a ; cigar brown |
392 | dd 0x64504a ; ice brown |
392 | dd 0x64504a ; ice brown |
393 | dd 0x564242 ; dark chocolate |
393 | dd 0x564242 ; dark chocolate |
394 | dd 0x00aa66 ; celery stalk |
394 | dd 0x00aa66 ; celery stalk |
395 | dd 0x107a30 ; forest green |
395 | dd 0x107a30 ; forest green |
396 | dd 0x365800 ; hooker's green |
396 | dd 0x365800 ; hooker's green |
397 | dd 0x8beb88 ; pastel lime |
397 | dd 0x8beb88 ; pastel lime |
398 | dd 0x7bbb64 ; lime |
398 | dd 0x7bbb64 ; lime |
399 | dd 0x4ba010 ; dark lime |
399 | dd 0x4ba010 ; dark lime |
400 | 400 | ||
401 | names: |
401 | names: |
402 | db 'WHITE ' |
402 | db 'WHITE ' |
403 | db 'PALE YELLOW ' |
403 | db 'PALE YELLOW ' |
404 | db 'LEMON YELLOW ' |
404 | db 'LEMON YELLOW ' |
405 | db 'MUSTARD ' |
405 | db 'MUSTARD ' |
406 | db 'CADIUM YELLOW ' |
406 | db 'CADIUM YELLOW ' |
407 | db 'YELLOW OCRE ' |
407 | db 'YELLOW OCRE ' |
408 | db 'CREAM ' |
408 | db 'CREAM ' |
409 | db 'PEACH ' |
409 | db 'PEACH ' |
410 | db 'DARK PEACH ' |
410 | db 'DARK PEACH ' |
411 | db 'PINK ' |
411 | db 'PINK ' |
412 | db 'FLESH ' |
412 | db 'FLESH ' |
413 | db 'ARTIFICIAL ARM ' |
413 | db 'ARTIFICIAL ARM ' |
414 | db 'DEEP BLUSH ' |
414 | db 'DEEP BLUSH ' |
415 | db 'WASHED KHAKI ' |
415 | db 'WASHED KHAKI ' |
416 | db 'KHAKI ' |
416 | db 'KHAKI ' |
417 | db 'DARK KHAKI ' |
417 | db 'DARK KHAKI ' |
418 | db 'BEIGE ' |
418 | db 'BEIGE ' |
419 | db 'POUPON ' |
419 | db 'POUPON ' |
420 | db 'CAMOUFLAGE ' |
420 | db 'CAMOUFLAGE ' |
421 | db 'PALE OLIVE ' |
421 | db 'PALE OLIVE ' |
422 | db 'OLIVE ' |
422 | db 'OLIVE ' |
423 | db 'DARK OLIVE ' |
423 | db 'DARK OLIVE ' |
424 | db 'BLACK OLIVE ' |
424 | db 'BLACK OLIVE ' |
425 | db 'WASHED ARMY ' |
425 | db 'WASHED ARMY ' |
426 | db 'ARMY ' |
426 | db 'ARMY ' |
427 | db 'PALE TEAL ' |
427 | db 'PALE TEAL ' |
428 | db 'FADED TEAL ' |
428 | db 'FADED TEAL ' |
429 | db 'PASTEL TEAL ' |
429 | db 'PASTEL TEAL ' |
430 | db 'TEAL ' |
430 | db 'TEAL ' |
431 | db 'DARK TEAL ' |
431 | db 'DARK TEAL ' |
432 | db 'LIGHT TURQUOISE' |
432 | db 'LIGHT TURQUOISE' |
433 | db 'TURQUOISE ' |
433 | db 'TURQUOISE ' |
434 | db 'DARK TURQUOISE ' |
434 | db 'DARK TURQUOISE ' |
435 | db 'MEDIUM COBALT ' |
435 | db 'MEDIUM COBALT ' |
436 | db 'COBALT ' |
436 | db 'COBALT ' |
437 | db 'ULTRAMARINE ' |
437 | db 'ULTRAMARINE ' |
438 | db 'NAVY BLUE ' |
438 | db 'NAVY BLUE ' |
439 | db 'TRUE BLUE ' |
439 | db 'TRUE BLUE ' |
440 | db 'SKY BLUE ' |
440 | db 'SKY BLUE ' |
441 | db 'MOUNTAIN BLUE ' |
441 | db 'MOUNTAIN BLUE ' |
442 | db 'FADED JEANS ' |
442 | db 'FADED JEANS ' |
443 | db 'DENIM ' |
443 | db 'DENIM ' |
444 | db 'FUSHIA ' |
444 | db 'FUSHIA ' |
445 | db 'LAVENDAR ' |
445 | db 'LAVENDAR ' |
446 | db 'LIGHT VIOLET ' |
446 | db 'LIGHT VIOLET ' |
447 | db 'VIOLET ' |
447 | db 'VIOLET ' |
448 | db 'PURPLE ' |
448 | db 'PURPLE ' |
449 | db 'MAGENTA ' |
449 | db 'MAGENTA ' |
450 | db 'ROSE ' |
450 | db 'ROSE ' |
451 | db 'MAUVE ' |
451 | db 'MAUVE ' |
452 | db 'SALMON ' |
452 | db 'SALMON ' |
453 | db 'PASTEL ORANGE ' |
453 | db 'PASTEL ORANGE ' |
454 | db 'ORANGE ' |
454 | db 'ORANGE ' |
455 | db 'BURNT SIENNA ' |
455 | db 'BURNT SIENNA ' |
456 | db 'RED ORANGE ' |
456 | db 'RED ORANGE ' |
457 | db 'CADIUM RED ' |
457 | db 'CADIUM RED ' |
458 | db 'BRICK RED ' |
458 | db 'BRICK RED ' |
459 | db 'RUST ' |
459 | db 'RUST ' |
460 | db 'TERRA COTTA ' |
460 | db 'TERRA COTTA ' |
461 | db 'LIGHT MAROON ' |
461 | db 'LIGHT MAROON ' |
462 | db 'MAROON ' |
462 | db 'MAROON ' |
463 | db 'UMBER BLUSH ' |
463 | db 'UMBER BLUSH ' |
464 | db 'BURNT UMBER ' |
464 | db 'BURNT UMBER ' |
465 | db 'CIGAR BROWN ' |
465 | db 'CIGAR BROWN ' |
466 | db 'ICE BROWN ' |
466 | db 'ICE BROWN ' |
467 | db 'DARK CHOCOLATE ' |
467 | db 'DARK CHOCOLATE ' |
468 | db 'CELERY STALK ' |
468 | db 'CELERY STALK ' |
469 | db 'FOREST GREEN ' |
469 | db 'FOREST GREEN ' |
470 | db "HOOKER'S GREEN " |
470 | db "HOOKER'S GREEN " |
471 | db 'PASTEL LIME ' |
471 | db 'PASTEL LIME ' |
472 | db 'LIME ' |
472 | db 'LIME ' |
473 | db 'DARK LIME ' |
473 | db 'DARK LIME ' |
474 | 474 | ||
475 | 475 | ||
476 | text: |
476 | text: |
477 | db 'TO SEE HOW COLORS COMPARE ' |
477 | db 'TO SEE HOW COLORS COMPARE ' |
478 | db 'TO ONE ANOTHER, LEFT CLICK ' |
478 | db 'TO ONE ANOTHER, LEFT CLICK ' |
479 | db 'THE FIRST COLOR AND RIGHT ' |
479 | db 'THE FIRST COLOR AND RIGHT ' |
480 | db 'CLICK THE SECOND. TO GET ' |
480 | db 'CLICK THE SECOND. TO GET ' |
481 | db "A SENSE OF A COLOR'S TRUE " |
481 | db "A SENSE OF A COLOR'S TRUE " |
482 | db 'HUE, RIGHT AND LEFT CLICK ' |
482 | db 'HUE, RIGHT AND LEFT CLICK ' |
483 | db 'THE SAME COLOR TO SEE IT ' |
483 | db 'THE SAME COLOR TO SEE IT ' |
484 | db 'ON THE NEUTRAL BACKGROUND. ' |
484 | db 'ON THE NEUTRAL BACKGROUND. ' |
485 | db 'TO USE A LIGHTER OR DARKER ' |
485 | db 'TO USE A LIGHTER OR DARKER ' |
486 | db 'VALUE OF A COLOR, ADD OR ' |
486 | db 'VALUE OF A COLOR, ADD OR ' |
487 | db 'SUBTRACT 0x10 OR 0x20 FROM ' |
487 | db 'SUBTRACT 0x10 OR 0x20 FROM ' |
488 | db 'EACH BYTE OF ITS HEX VALUE.' |
488 | db 'EACH BYTE OF ITS HEX VALUE.' |
489 | db ' ' |
489 | db ' ' |
490 | db ' ANY KEY ... ' |
490 | db ' ANY KEY ... ' |
491 | 491 | ||
492 | stat_table: |
492 | stat_table: |
493 | 493 | ||
494 | 494 | ||
495 | finis: |
495 | finis: |