Added gm_color_table_get_hex function
This commit is contained in:
parent
fea7a2f2b0
commit
6469efbbdc
|
@ -222,6 +222,19 @@ gm_color_table_get(GmColorTable *table, const gchar *name, GdkColor *color) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const gchar *
|
||||||
|
gm_color_table_get_hex(GmColorTable *table, const gchar *name) {
|
||||||
|
GmColorTableItem *item;
|
||||||
|
|
||||||
|
item = g_hash_table_lookup(table->priv->colors, name);
|
||||||
|
|
||||||
|
if (item != NULL) {
|
||||||
|
return item->hex;
|
||||||
|
} else {
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
gm_color_table_set_bold(GmColorTable *table, gboolean bold) {
|
gm_color_table_set_bold(GmColorTable *table, gboolean bold) {
|
||||||
if (table->priv->bold != bold) {
|
if (table->priv->bold != bold) {
|
||||||
|
|
Reference in a new issue