3 * Menu description for selecting color mapping
5 static struct IntuiText colortext
[] = {
6 { 0, 1, JAM2
, 20, 0, NULL
, (UBYTE
*)"grey", NULL
},
7 { 0, 1, JAM2
, 20, 0, NULL
, (UBYTE
*)"red", NULL
},
8 { 0, 1, JAM2
, 20, 0, NULL
, (UBYTE
*)"green", NULL
},
9 { 0, 1, JAM2
, 20, 0, NULL
, (UBYTE
*)"blue", NULL
},
10 { 0, 1, JAM2
, 20, 0, NULL
, (UBYTE
*)"rainbow",NULL
}
13 #define ColNum (sizeof(colortext)/sizeof(struct IntuiText))
14 #define ColXMask ((1<<ColNum)-1)
15 #define ColorExclude(entry) (ColXMask^( 1<<entry))
17 #define COLMEMFLAGS ( CHECKIT | ITEMTEXT | HIGHCOMP | ITEMENABLED )
19 extern void SetHourGlassCol();
20 extern void SetRainbow();
23 struct MenuItem coloritems
[] = {
24 { &coloritems
[1], /* next item */
25 10, 0, 80 , 10, /* x,y,w,h */
27 ColorExclude(0), /* mutual exclude bits */
28 (APTR
) &colortext
[0], /* grey */
29 NULL
, /* highlight image */
30 'h', /* command byte ? */
31 NULL
, /* submenu item */
32 0 /* next select for select dragging */
34 { &coloritems
[2], /* next item */
35 10, 10, 80 , 10, /* x,y,w,h */
37 ColorExclude(1), /* mutual exclude bits */
38 (APTR
) &colortext
[1], /* red */
39 NULL
, /* highlight image */
40 'h', /* command byte ? */
41 NULL
, /* submenu item */
42 0 /* next select for select dragging */
44 { &coloritems
[3], /* next item */
45 10, 20, 80 , 10, /* x,y,w,h */
47 ColorExclude(2), /* mutual exclude bits */
49 NULL
, /* highlight image */
50 'h', /* command byte ? */
51 NULL
, /* submenu item */
52 0 /* next select for select dragging */
54 { &coloritems
[4], /* next item */
55 10, 30, 80 , 10, /* x,y,w,h */
57 ColorExclude(3), /* mutual exclude bits */
59 NULL
, /* highlight image */
60 'h', /* command byte ? */
61 NULL
, /* submenu item */
62 0 /* next select for select dragging */
64 { NULL
, /* next item */
65 10, 40, 80 , 10, /* x,y,w,h */
67 ColorExclude(4), /* mutual exclude bits */
69 NULL
, /* highlight image */
70 'h', /* command byte ? */
71 NULL
, /* submenu item */
72 0 /* next select for select dragging */
82 for( which
= 0; which
< ColNum
; which
++ ) {
83 if( Selected(coloritems
[which
]))
91 SetMono( 0xf, 0xf, 0xf );
100 SetMono( 0x0, 0x0, 0xf );