return RrColorNew(inst, xcol.red >> 8, xcol.green >> 8, xcol.blue >> 8);
}
return RrColorNew(inst, xcol.red >> 8, xcol.green >> 8, xcol.blue >> 8);
}
RrColor *RrColorNew(const RrInstance *inst, gint r, gint g, gint b)
{
/* this should be replaced with something far cooler */
RrColor *RrColorNew(const RrInstance *inst, gint r, gint g, gint b)
{
/* this should be replaced with something far cooler */
g_assert(g_hash_table_lookup(RrColorHash(c->inst), &c->key));
g_hash_table_remove(RrColorHash(c->inst), &c->key);
g_assert(g_hash_table_lookup(RrColorHash(c->inst), &c->key));
g_hash_table_remove(RrColorHash(c->inst), &c->key);
if (c->pixel) XFreeColors(RrDisplay(c->inst), RrColormap(c->inst),
&c->pixel, 1, 0);
if (c->gc) XFreeGC(RrDisplay(c->inst), c->gc);
if (c->pixel) XFreeColors(RrDisplay(c->inst), RrColormap(c->inst),
&c->pixel, 1, 0);
if (c->gc) XFreeGC(RrDisplay(c->inst), c->gc);