diff options
Diffstat (limited to 'gtk/gtkcssstyle.c')
-rw-r--r-- | gtk/gtkcssstyle.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/gtk/gtkcssstyle.c b/gtk/gtkcssstyle.c index d6ff5cbb84..effc2fb4d3 100644 --- a/gtk/gtkcssstyle.c +++ b/gtk/gtkcssstyle.c @@ -126,11 +126,17 @@ gtk_css_style_print (GtkCssStyle *style, gboolean skip_initial) { guint i; + GtkCssStyle *default_style; gboolean retval = FALSE; g_return_val_if_fail (GTK_IS_CSS_STYLE (style), FALSE); g_return_val_if_fail (string != NULL, FALSE); + default_style = gtk_css_static_style_get_default (); + + if (style == default_style) + g_string_append_printf (string, "%*sDEFAULT STYLE\n", indent, ""); + for (i = 0; i < _gtk_css_style_property_get_n_properties (); i++) { GtkCssSection *section; @@ -143,7 +149,6 @@ gtk_css_style_print (GtkCssStyle *style, if (skip_initial) { GtkCssValue *initial = _gtk_css_style_property_get_initial_value (prop); - GtkCssStyle *default_style = gtk_css_static_style_get_default (); GtkCssValue *computed = _gtk_css_value_compute (initial, i, GTK_STYLE_PROVIDER (gtk_settings_get_default ()), default_style, |