+ uint_least32_t t = -1;
+
+ t = (t << 8) + scale16to8(c->red);
+ t = (t << 8) + scale16to8(c->green);
+ t = (t << 8) + scale16to8(c->blue);
+
+ return t & 0xffffffff;
+}
+
+void ewmh_icon_prepare_cmap(XColor *map, unsigned n)
+{
+ unsigned i;
+
+ for (i = 0; i < n; i++) {
+ map[i].pixel = wm_pixel(&map[i]);
+ }