122 |
#define SET_FUNCTION(rop2) { if (rop2 != ROP2_COPY) XSetFunction(display, gc, rop2_map[rop2]); } |
#define SET_FUNCTION(rop2) { if (rop2 != ROP2_COPY) XSetFunction(display, gc, rop2_map[rop2]); } |
123 |
#define RESET_FUNCTION(rop2) { if (rop2 != ROP2_COPY) XSetFunction(display, gc, GXcopy); } |
#define RESET_FUNCTION(rop2) { if (rop2 != ROP2_COPY) XSetFunction(display, gc, GXcopy); } |
124 |
|
|
125 |
void |
static void |
126 |
mwm_hide_decorations(void) |
mwm_hide_decorations(void) |
127 |
{ |
{ |
128 |
PropMotifWmHints motif_hints; |
PropMotifWmHints motif_hints; |
144 |
(unsigned char *) &motif_hints, PROP_MOTIF_WM_HINTS_ELEMENTS); |
(unsigned char *) &motif_hints, PROP_MOTIF_WM_HINTS_ELEMENTS); |
145 |
} |
} |
146 |
|
|
147 |
PixelColour |
static PixelColour |
148 |
split_colour15(uint32 colour) |
split_colour15(uint32 colour) |
149 |
{ |
{ |
150 |
PixelColour rv; |
PixelColour rv; |
157 |
return rv; |
return rv; |
158 |
} |
} |
159 |
|
|
160 |
PixelColour |
static PixelColour |
161 |
split_colour16(uint32 colour) |
split_colour16(uint32 colour) |
162 |
{ |
{ |
163 |
PixelColour rv; |
PixelColour rv; |
170 |
return rv; |
return rv; |
171 |
} |
} |
172 |
|
|
173 |
PixelColour |
static PixelColour |
174 |
split_colour24(uint32 colour) |
split_colour24(uint32 colour) |
175 |
{ |
{ |
176 |
PixelColour rv; |
PixelColour rv; |
180 |
return rv; |
return rv; |
181 |
} |
} |
182 |
|
|
183 |
uint32 |
static uint32 |
184 |
make_colour16(PixelColour pc) |
make_colour16(PixelColour pc) |
185 |
{ |
{ |
186 |
pc.red = (pc.red * 0x1f) / 0xff; |
pc.red = (pc.red * 0x1f) / 0xff; |
189 |
return (pc.red << 11) | (pc.green << 5) | pc.blue; |
return (pc.red << 11) | (pc.green << 5) | pc.blue; |
190 |
} |
} |
191 |
|
|
192 |
uint32 |
static uint32 |
193 |
make_colour24(PixelColour pc) |
make_colour24(PixelColour pc) |
194 |
{ |
{ |
195 |
return (pc.red << 16) | (pc.green << 8) | pc.blue; |
return (pc.red << 16) | (pc.green << 8) | pc.blue; |
196 |
} |
} |
197 |
|
|
198 |
uint32 |
static uint32 |
199 |
make_colour32(PixelColour pc) |
make_colour32(PixelColour pc) |
200 |
{ |
{ |
201 |
return (pc.red << 16) | (pc.green << 8) | pc.blue; |
return (pc.red << 16) | (pc.green << 8) | pc.blue; |