Show theme colour value

This commit is contained in:
James Booth
2016-01-21 02:00:12 +00:00
parent 6b65a9be15
commit 37171fe692
4 changed files with 106 additions and 85 deletions

View File

@@ -404,7 +404,6 @@ prefs_free_string(char *pref)
}
}
void
prefs_set_string(preference_t pref, char *value)
{

View File

@@ -557,6 +557,20 @@ _theme_prep_fgnd(char *setting, char *def, GString *lookup_str, gboolean *bold)
g_free(val);
}
char*
theme_get_string(char *str)
{
return g_key_file_get_string(theme, "colours", str, NULL);
}
void
theme_free_string(char *str)
{
if (str) {
g_free(str);
}
}
int
theme_attrs(theme_item_t attrs)
{

View File

@@ -131,7 +131,8 @@ gboolean theme_load(const char *const theme_name);
GSList* theme_list(void);
void theme_close(void);
int theme_attrs(theme_item_t attrs);
char* theme_get_string(char *str);
void theme_free_string(char *str);
theme_item_t theme_main_presence_attrs(const char *const presence);
theme_item_t theme_roster_unread_presence_attrs(const char *const presence);
theme_item_t theme_roster_active_presence_attrs(const char *const presence);