Use color: inherit to reset label color to its default, thanks knome for the hint!

master
Landry Breuil 2016-05-14 16:22:59 +02:00
parent 423ec0cb64
commit d776f762f2
1 changed files with 5 additions and 1 deletions

View File

@ -525,7 +525,11 @@ static void set_label_csscolor(GtkWidget* label, GdkRGBA* color)
} }
else else
{ {
css = g_strdup_printf(".label { color: black; }"); #if GTK_CHECK_VERSION (3, 20, 0)
css = g_strdup_printf("label { color: inherit; }");
#else
css = g_strdup_printf(".label { color: inherit; }");
#endif
} }
css_provider = gtk_css_provider_new (); css_provider = gtk_css_provider_new ();
gtk_css_provider_load_from_data (css_provider, css, strlen(css), NULL); gtk_css_provider_load_from_data (css_provider, css, strlen(css), NULL);