mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-27 14:10:30 +00:00
cssvalue: Add contains_variables()
We'll need this to know which values to recompute for animations. It will be used in the next commit, it's separate to avoid the diff being too large.
This commit is contained in:
parent
2437a551ec
commit
df77f22740
@ -402,10 +402,13 @@ _gtk_css_array_value_new_from_array (GtkCssValue **values,
|
||||
for (i = 0; i < n_values; i ++)
|
||||
{
|
||||
if (!gtk_css_value_is_computed (values[i]))
|
||||
{
|
||||
result->is_computed = FALSE;
|
||||
break;
|
||||
}
|
||||
result->is_computed = FALSE;
|
||||
|
||||
if (gtk_css_value_contains_variables (values[i]))
|
||||
result->contains_variables = TRUE;
|
||||
|
||||
if (!result->is_computed && result->contains_variables)
|
||||
break;
|
||||
}
|
||||
|
||||
return result;
|
||||
@ -467,3 +470,4 @@ _gtk_css_array_value_get_n_values (const GtkCssValue *value)
|
||||
return value->n_values;
|
||||
}
|
||||
|
||||
|
||||
|
@ -163,9 +163,9 @@ static const GtkCssValueClass GTK_CSS_VALUE_BG_SIZE = {
|
||||
gtk_css_value_bg_size_print
|
||||
};
|
||||
|
||||
static GtkCssValue auto_singleton = { >K_CSS_VALUE_BG_SIZE, 1, TRUE, FALSE, FALSE, NULL, NULL };
|
||||
static GtkCssValue cover_singleton = { >K_CSS_VALUE_BG_SIZE, 1, TRUE, TRUE, FALSE, NULL, NULL };
|
||||
static GtkCssValue contain_singleton = { >K_CSS_VALUE_BG_SIZE, 1, TRUE, FALSE, TRUE, NULL, NULL };
|
||||
static GtkCssValue auto_singleton = { >K_CSS_VALUE_BG_SIZE, 1, TRUE, FALSE, FALSE, FALSE, NULL, NULL };
|
||||
static GtkCssValue cover_singleton = { >K_CSS_VALUE_BG_SIZE, 1, TRUE, FALSE, TRUE, FALSE, NULL, NULL };
|
||||
static GtkCssValue contain_singleton = { >K_CSS_VALUE_BG_SIZE, 1, TRUE, FALSE, FALSE, TRUE, NULL, NULL };
|
||||
|
||||
GtkCssValue *
|
||||
_gtk_css_bg_size_value_new (GtkCssValue *x,
|
||||
|
@ -260,3 +260,4 @@ _gtk_css_border_value_get_left (const GtkCssValue *value)
|
||||
return value->values[GTK_CSS_LEFT];
|
||||
}
|
||||
|
||||
|
||||
|
@ -484,9 +484,9 @@ _gtk_css_color_value_resolve (GtkCssValue *color,
|
||||
return value;
|
||||
}
|
||||
|
||||
static GtkCssValue transparent_black_singleton = { >K_CSS_VALUE_COLOR, 1, TRUE, COLOR_TYPE_LITERAL, NULL,
|
||||
static GtkCssValue transparent_black_singleton = { >K_CSS_VALUE_COLOR, 1, TRUE, FALSE, COLOR_TYPE_LITERAL, NULL,
|
||||
.sym_col.rgba = {0, 0, 0, 0} };
|
||||
static GtkCssValue white_singleton = { >K_CSS_VALUE_COLOR, 1, TRUE, COLOR_TYPE_LITERAL, NULL,
|
||||
static GtkCssValue white_singleton = { >K_CSS_VALUE_COLOR, 1, TRUE, FALSE, COLOR_TYPE_LITERAL, NULL,
|
||||
.sym_col.rgba = {1, 1, 1, 1} };
|
||||
|
||||
|
||||
@ -620,7 +620,7 @@ _gtk_css_color_value_new_mix (GtkCssValue *color1,
|
||||
GtkCssValue *
|
||||
_gtk_css_color_value_new_current_color (void)
|
||||
{
|
||||
static GtkCssValue current_color = { >K_CSS_VALUE_COLOR, 1, FALSE, COLOR_TYPE_CURRENT_COLOR, NULL, };
|
||||
static GtkCssValue current_color = { >K_CSS_VALUE_COLOR, 1, FALSE, FALSE, COLOR_TYPE_CURRENT_COLOR, NULL, };
|
||||
|
||||
return _gtk_css_value_ref (¤t_color);
|
||||
}
|
||||
|
@ -110,14 +110,14 @@ static const GtkCssValueClass GTK_CSS_VALUE_CORNER = {
|
||||
};
|
||||
|
||||
static GtkCssValue corner_singletons[] = {
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, FALSE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, FALSE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, FALSE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, FALSE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, FALSE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, FALSE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, FALSE, NULL, NULL },
|
||||
{ >K_CSS_VALUE_CORNER, 1, TRUE, FALSE, NULL, NULL },
|
||||
};
|
||||
|
||||
static inline void
|
||||
@ -226,3 +226,4 @@ gtk_css_corner_value_is_zero (const GtkCssValue *corner)
|
||||
return gtk_css_dimension_value_is_zero (corner->x) &&
|
||||
gtk_css_dimension_value_is_zero (corner->y);
|
||||
}
|
||||
|
||||
|
@ -407,3 +407,4 @@ _gtk_css_ease_value_transform (const GtkCssValue *ease,
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
@ -87,16 +87,16 @@ static const GtkCssValueClass GTK_CSS_VALUE_BORDER_STYLE = {
|
||||
};
|
||||
|
||||
static GtkCssValue border_style_values[] = {
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_NONE, "none" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_SOLID, "solid" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_INSET, "inset" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_OUTSET, "outset" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_HIDDEN, "hidden" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_DOTTED, "dotted" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_DASHED, "dashed" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_DOUBLE, "double" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_GROOVE, "groove" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, GTK_BORDER_STYLE_RIDGE, "ridge" }
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_NONE, "none" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_SOLID, "solid" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_INSET, "inset" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_OUTSET, "outset" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_HIDDEN, "hidden" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_DOTTED, "dotted" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_DASHED, "dashed" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_DOUBLE, "double" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_GROOVE, "groove" },
|
||||
{ >K_CSS_VALUE_BORDER_STYLE, 1, TRUE, FALSE, GTK_BORDER_STYLE_RIDGE, "ridge" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -145,22 +145,22 @@ static const GtkCssValueClass GTK_CSS_VALUE_BLEND_MODE = {
|
||||
};
|
||||
|
||||
static GtkCssValue blend_mode_values[] = {
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_DEFAULT, "normal" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_MULTIPLY, "multiply" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_SCREEN, "screen" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_OVERLAY, "overlay" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_DARKEN, "darken" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_LIGHTEN, "lighten" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_COLOR_DODGE, "color-dodge" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_COLOR_BURN, "color-burn" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_HARD_LIGHT, "hard-light" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_SOFT_LIGHT, "soft-light" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_DIFFERENCE, "difference" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_EXCLUSION, "exclusion" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_COLOR, "color" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_HUE, "hue" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_SATURATION, "saturation" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, GSK_BLEND_MODE_LUMINOSITY, "luminosity" }
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_DEFAULT, "normal" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_MULTIPLY, "multiply" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_SCREEN, "screen" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_OVERLAY, "overlay" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_DARKEN, "darken" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_LIGHTEN, "lighten" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_COLOR_DODGE, "color-dodge" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_COLOR_BURN, "color-burn" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_HARD_LIGHT, "hard-light" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_SOFT_LIGHT, "soft-light" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_DIFFERENCE, "difference" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_EXCLUSION, "exclusion" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_COLOR, "color" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_HUE, "hue" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_SATURATION, "saturation" },
|
||||
{ >K_CSS_VALUE_BLEND_MODE, 1, TRUE, FALSE, GSK_BLEND_MODE_LUMINOSITY, "luminosity" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -296,15 +296,15 @@ static const GtkCssValueClass GTK_CSS_VALUE_FONT_SIZE = {
|
||||
};
|
||||
|
||||
static GtkCssValue font_size_values[] = {
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, GTK_CSS_FONT_SIZE_SMALLER, "smaller" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, GTK_CSS_FONT_SIZE_LARGER, "larger" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, GTK_CSS_FONT_SIZE_XX_SMALL, "xx-small" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, GTK_CSS_FONT_SIZE_X_SMALL, "x-small" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, GTK_CSS_FONT_SIZE_SMALL, "small" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, GTK_CSS_FONT_SIZE_MEDIUM, "medium" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, GTK_CSS_FONT_SIZE_LARGE, "large" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, GTK_CSS_FONT_SIZE_X_LARGE, "x-large" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, GTK_CSS_FONT_SIZE_XX_LARGE, "xx-large" }
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, FALSE, GTK_CSS_FONT_SIZE_SMALLER, "smaller" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, FALSE, GTK_CSS_FONT_SIZE_LARGER, "larger" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, FALSE, GTK_CSS_FONT_SIZE_XX_SMALL, "xx-small" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, FALSE, GTK_CSS_FONT_SIZE_X_SMALL, "x-small" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, FALSE, GTK_CSS_FONT_SIZE_SMALL, "small" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, FALSE, GTK_CSS_FONT_SIZE_MEDIUM, "medium" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, FALSE, GTK_CSS_FONT_SIZE_LARGE, "large" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, FALSE, GTK_CSS_FONT_SIZE_X_LARGE, "x-large" },
|
||||
{ >K_CSS_VALUE_FONT_SIZE, 1, FALSE, FALSE, GTK_CSS_FONT_SIZE_XX_LARGE, "xx-large" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -353,9 +353,9 @@ static const GtkCssValueClass GTK_CSS_VALUE_FONT_STYLE = {
|
||||
};
|
||||
|
||||
static GtkCssValue font_style_values[] = {
|
||||
{ >K_CSS_VALUE_FONT_STYLE, 1, TRUE, PANGO_STYLE_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_STYLE, 1, TRUE, PANGO_STYLE_OBLIQUE, "oblique" },
|
||||
{ >K_CSS_VALUE_FONT_STYLE, 1, TRUE, PANGO_STYLE_ITALIC, "italic" }
|
||||
{ >K_CSS_VALUE_FONT_STYLE, 1, TRUE, FALSE, PANGO_STYLE_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_STYLE, 1, TRUE, FALSE, PANGO_STYLE_OBLIQUE, "oblique" },
|
||||
{ >K_CSS_VALUE_FONT_STYLE, 1, TRUE, FALSE, PANGO_STYLE_ITALIC, "italic" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -452,8 +452,8 @@ static const GtkCssValueClass GTK_CSS_VALUE_FONT_WEIGHT = {
|
||||
};
|
||||
|
||||
static GtkCssValue font_weight_values[] = {
|
||||
{ >K_CSS_VALUE_FONT_WEIGHT, 1, FALSE, BOLDER, "bolder" },
|
||||
{ >K_CSS_VALUE_FONT_WEIGHT, 1, FALSE, LIGHTER, "lighter" },
|
||||
{ >K_CSS_VALUE_FONT_WEIGHT, 1, FALSE, FALSE, BOLDER, "bolder" },
|
||||
{ >K_CSS_VALUE_FONT_WEIGHT, 1, FALSE, FALSE, LIGHTER, "lighter" },
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -502,15 +502,15 @@ static const GtkCssValueClass GTK_CSS_VALUE_FONT_STRETCH = {
|
||||
};
|
||||
|
||||
static GtkCssValue font_stretch_values[] = {
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, PANGO_STRETCH_ULTRA_CONDENSED, "ultra-condensed" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, PANGO_STRETCH_EXTRA_CONDENSED, "extra-condensed" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, PANGO_STRETCH_CONDENSED, "condensed" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, PANGO_STRETCH_SEMI_CONDENSED, "semi-condensed" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, PANGO_STRETCH_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, PANGO_STRETCH_SEMI_EXPANDED, "semi-expanded" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, PANGO_STRETCH_EXPANDED, "expanded" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, PANGO_STRETCH_EXTRA_EXPANDED, "extra-expanded" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, PANGO_STRETCH_ULTRA_EXPANDED, "ultra-expanded" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, FALSE, PANGO_STRETCH_ULTRA_CONDENSED, "ultra-condensed" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, FALSE, PANGO_STRETCH_EXTRA_CONDENSED, "extra-condensed" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, FALSE, PANGO_STRETCH_CONDENSED, "condensed" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, FALSE, PANGO_STRETCH_SEMI_CONDENSED, "semi-condensed" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, FALSE, PANGO_STRETCH_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, FALSE, PANGO_STRETCH_SEMI_EXPANDED, "semi-expanded" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, FALSE, PANGO_STRETCH_EXPANDED, "expanded" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, FALSE, PANGO_STRETCH_EXTRA_EXPANDED, "extra-expanded" },
|
||||
{ >K_CSS_VALUE_FONT_STRETCH, 1, TRUE, FALSE, PANGO_STRETCH_ULTRA_EXPANDED, "ultra-expanded" },
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -559,9 +559,9 @@ static const GtkCssValueClass GTK_CSS_VALUE_TEXT_DECORATION_STYLE = {
|
||||
};
|
||||
|
||||
static GtkCssValue text_decoration_style_values[] = {
|
||||
{ >K_CSS_VALUE_TEXT_DECORATION_STYLE, 1, TRUE, GTK_CSS_TEXT_DECORATION_STYLE_SOLID, "solid" },
|
||||
{ >K_CSS_VALUE_TEXT_DECORATION_STYLE, 1, TRUE, GTK_CSS_TEXT_DECORATION_STYLE_DOUBLE, "double" },
|
||||
{ >K_CSS_VALUE_TEXT_DECORATION_STYLE, 1, TRUE, GTK_CSS_TEXT_DECORATION_STYLE_WAVY, "wavy" },
|
||||
{ >K_CSS_VALUE_TEXT_DECORATION_STYLE, 1, TRUE, FALSE, GTK_CSS_TEXT_DECORATION_STYLE_SOLID, "solid" },
|
||||
{ >K_CSS_VALUE_TEXT_DECORATION_STYLE, 1, TRUE, FALSE, GTK_CSS_TEXT_DECORATION_STYLE_DOUBLE, "double" },
|
||||
{ >K_CSS_VALUE_TEXT_DECORATION_STYLE, 1, TRUE, FALSE, GTK_CSS_TEXT_DECORATION_STYLE_WAVY, "wavy" },
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -610,9 +610,9 @@ static const GtkCssValueClass GTK_CSS_VALUE_AREA = {
|
||||
};
|
||||
|
||||
static GtkCssValue area_values[] = {
|
||||
{ >K_CSS_VALUE_AREA, 1, TRUE, GTK_CSS_AREA_BORDER_BOX, "border-box" },
|
||||
{ >K_CSS_VALUE_AREA, 1, TRUE, GTK_CSS_AREA_PADDING_BOX, "padding-box" },
|
||||
{ >K_CSS_VALUE_AREA, 1, TRUE, GTK_CSS_AREA_CONTENT_BOX, "content-box" }
|
||||
{ >K_CSS_VALUE_AREA, 1, TRUE, FALSE, GTK_CSS_AREA_BORDER_BOX, "border-box" },
|
||||
{ >K_CSS_VALUE_AREA, 1, TRUE, FALSE, GTK_CSS_AREA_PADDING_BOX, "padding-box" },
|
||||
{ >K_CSS_VALUE_AREA, 1, TRUE, FALSE, GTK_CSS_AREA_CONTENT_BOX, "content-box" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -667,10 +667,10 @@ static const GtkCssValueClass GTK_CSS_VALUE_DIRECTION = {
|
||||
};
|
||||
|
||||
static GtkCssValue direction_values[] = {
|
||||
{ >K_CSS_VALUE_DIRECTION, 1, TRUE, GTK_CSS_DIRECTION_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_DIRECTION, 1, TRUE, GTK_CSS_DIRECTION_REVERSE, "reverse" },
|
||||
{ >K_CSS_VALUE_DIRECTION, 1, TRUE, GTK_CSS_DIRECTION_ALTERNATE, "alternate" },
|
||||
{ >K_CSS_VALUE_DIRECTION, 1, TRUE, GTK_CSS_DIRECTION_ALTERNATE_REVERSE, "alternate-reverse" }
|
||||
{ >K_CSS_VALUE_DIRECTION, 1, TRUE, FALSE, GTK_CSS_DIRECTION_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_DIRECTION, 1, TRUE, FALSE, GTK_CSS_DIRECTION_REVERSE, "reverse" },
|
||||
{ >K_CSS_VALUE_DIRECTION, 1, TRUE, FALSE, GTK_CSS_DIRECTION_ALTERNATE, "alternate" },
|
||||
{ >K_CSS_VALUE_DIRECTION, 1, TRUE, FALSE, GTK_CSS_DIRECTION_ALTERNATE_REVERSE, "alternate-reverse" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -728,8 +728,8 @@ static const GtkCssValueClass GTK_CSS_VALUE_PLAY_STATE = {
|
||||
};
|
||||
|
||||
static GtkCssValue play_state_values[] = {
|
||||
{ >K_CSS_VALUE_PLAY_STATE, 1, TRUE, GTK_CSS_PLAY_STATE_RUNNING, "running" },
|
||||
{ >K_CSS_VALUE_PLAY_STATE, 1, TRUE, GTK_CSS_PLAY_STATE_PAUSED, "paused" }
|
||||
{ >K_CSS_VALUE_PLAY_STATE, 1, TRUE, FALSE, GTK_CSS_PLAY_STATE_RUNNING, "running" },
|
||||
{ >K_CSS_VALUE_PLAY_STATE, 1, TRUE, FALSE, GTK_CSS_PLAY_STATE_PAUSED, "paused" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -784,10 +784,10 @@ static const GtkCssValueClass GTK_CSS_VALUE_FILL_MODE = {
|
||||
};
|
||||
|
||||
static GtkCssValue fill_mode_values[] = {
|
||||
{ >K_CSS_VALUE_FILL_MODE, 1, TRUE, GTK_CSS_FILL_NONE, "none" },
|
||||
{ >K_CSS_VALUE_FILL_MODE, 1, TRUE, GTK_CSS_FILL_FORWARDS, "forwards" },
|
||||
{ >K_CSS_VALUE_FILL_MODE, 1, TRUE, GTK_CSS_FILL_BACKWARDS, "backwards" },
|
||||
{ >K_CSS_VALUE_FILL_MODE, 1, TRUE, GTK_CSS_FILL_BOTH, "both" }
|
||||
{ >K_CSS_VALUE_FILL_MODE, 1, TRUE, FALSE, GTK_CSS_FILL_NONE, "none" },
|
||||
{ >K_CSS_VALUE_FILL_MODE, 1, TRUE, FALSE, GTK_CSS_FILL_FORWARDS, "forwards" },
|
||||
{ >K_CSS_VALUE_FILL_MODE, 1, TRUE, FALSE, GTK_CSS_FILL_BACKWARDS, "backwards" },
|
||||
{ >K_CSS_VALUE_FILL_MODE, 1, TRUE, FALSE, GTK_CSS_FILL_BOTH, "both" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -842,9 +842,9 @@ static const GtkCssValueClass GTK_CSS_VALUE_ICON_STYLE = {
|
||||
};
|
||||
|
||||
static GtkCssValue icon_style_values[] = {
|
||||
{ >K_CSS_VALUE_ICON_STYLE, 1, TRUE, GTK_CSS_ICON_STYLE_REQUESTED, "requested" },
|
||||
{ >K_CSS_VALUE_ICON_STYLE, 1, TRUE, GTK_CSS_ICON_STYLE_REGULAR, "regular" },
|
||||
{ >K_CSS_VALUE_ICON_STYLE, 1, TRUE, GTK_CSS_ICON_STYLE_SYMBOLIC, "symbolic" }
|
||||
{ >K_CSS_VALUE_ICON_STYLE, 1, TRUE, FALSE, GTK_CSS_ICON_STYLE_REQUESTED, "requested" },
|
||||
{ >K_CSS_VALUE_ICON_STYLE, 1, TRUE, FALSE, GTK_CSS_ICON_STYLE_REGULAR, "regular" },
|
||||
{ >K_CSS_VALUE_ICON_STYLE, 1, TRUE, FALSE, GTK_CSS_ICON_STYLE_SYMBOLIC, "symbolic" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -899,9 +899,9 @@ static const GtkCssValueClass GTK_CSS_VALUE_FONT_KERNING = {
|
||||
};
|
||||
|
||||
static GtkCssValue font_kerning_values[] = {
|
||||
{ >K_CSS_VALUE_FONT_KERNING, 1, TRUE, GTK_CSS_FONT_KERNING_AUTO, "auto" },
|
||||
{ >K_CSS_VALUE_FONT_KERNING, 1, TRUE, GTK_CSS_FONT_KERNING_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_KERNING, 1, TRUE, GTK_CSS_FONT_KERNING_NONE, "none" }
|
||||
{ >K_CSS_VALUE_FONT_KERNING, 1, TRUE, FALSE, GTK_CSS_FONT_KERNING_AUTO, "auto" },
|
||||
{ >K_CSS_VALUE_FONT_KERNING, 1, TRUE, FALSE, GTK_CSS_FONT_KERNING_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_KERNING, 1, TRUE, FALSE, GTK_CSS_FONT_KERNING_NONE, "none" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -956,9 +956,9 @@ static const GtkCssValueClass GTK_CSS_VALUE_FONT_VARIANT_POSITION = {
|
||||
};
|
||||
|
||||
static GtkCssValue font_variant_position_values[] = {
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_POSITION, 1, TRUE, GTK_CSS_FONT_VARIANT_POSITION_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_POSITION, 1, TRUE, GTK_CSS_FONT_VARIANT_POSITION_SUB, "sub" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_POSITION, 1, TRUE, GTK_CSS_FONT_VARIANT_POSITION_SUPER, "super" }
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_POSITION, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_POSITION_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_POSITION, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_POSITION_SUB, "sub" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_POSITION, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_POSITION_SUPER, "super" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -1013,13 +1013,13 @@ static const GtkCssValueClass GTK_CSS_VALUE_FONT_VARIANT_CAPS = {
|
||||
};
|
||||
|
||||
static GtkCssValue font_variant_caps_values[] = {
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, GTK_CSS_FONT_VARIANT_CAPS_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, GTK_CSS_FONT_VARIANT_CAPS_SMALL_CAPS, "small-caps" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, GTK_CSS_FONT_VARIANT_CAPS_ALL_SMALL_CAPS, "all-small-caps" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, GTK_CSS_FONT_VARIANT_CAPS_PETITE_CAPS, "petite-caps" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, GTK_CSS_FONT_VARIANT_CAPS_ALL_PETITE_CAPS, "all-petite-caps" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, GTK_CSS_FONT_VARIANT_CAPS_UNICASE, "unicase" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, GTK_CSS_FONT_VARIANT_CAPS_TITLING_CAPS, "titling-caps" }
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_CAPS_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_CAPS_SMALL_CAPS, "small-caps" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_CAPS_ALL_SMALL_CAPS, "all-small-caps" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_CAPS_PETITE_CAPS, "petite-caps" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_CAPS_ALL_PETITE_CAPS, "all-petite-caps" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_CAPS_UNICASE, "unicase" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_CAPS, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_CAPS_TITLING_CAPS, "titling-caps" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -1074,8 +1074,8 @@ static const GtkCssValueClass GTK_CSS_VALUE_FONT_VARIANT_ALTERNATE = {
|
||||
};
|
||||
|
||||
static GtkCssValue font_variant_alternate_values[] = {
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_ALTERNATE, 1, TRUE, GTK_CSS_FONT_VARIANT_ALTERNATE_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_ALTERNATE, 1, TRUE, GTK_CSS_FONT_VARIANT_ALTERNATE_HISTORICAL_FORMS, "historical-forms" }
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_ALTERNATE, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_ALTERNATE_NORMAL, "normal" },
|
||||
{ >K_CSS_VALUE_FONT_VARIANT_ALTERNATE, 1, TRUE, FALSE, GTK_CSS_FONT_VARIANT_ALTERNATE_HISTORICAL_FORMS, "historical-forms" }
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
@ -1583,10 +1583,10 @@ static const GtkCssValueClass GTK_CSS_VALUE_TEXT_TRANSFORM = {
|
||||
};
|
||||
|
||||
static GtkCssValue text_transform_values[] = {
|
||||
{ >K_CSS_VALUE_TEXT_TRANSFORM, 1, TRUE, GTK_CSS_TEXT_TRANSFORM_NONE, "none" },
|
||||
{ >K_CSS_VALUE_TEXT_TRANSFORM, 1, TRUE, GTK_CSS_TEXT_TRANSFORM_LOWERCASE, "lowercase" },
|
||||
{ >K_CSS_VALUE_TEXT_TRANSFORM, 1, TRUE, GTK_CSS_TEXT_TRANSFORM_UPPERCASE, "uppercase" },
|
||||
{ >K_CSS_VALUE_TEXT_TRANSFORM, 1, TRUE, GTK_CSS_TEXT_TRANSFORM_CAPITALIZE, "capitalize" },
|
||||
{ >K_CSS_VALUE_TEXT_TRANSFORM, 1, TRUE, FALSE, GTK_CSS_TEXT_TRANSFORM_NONE, "none" },
|
||||
{ >K_CSS_VALUE_TEXT_TRANSFORM, 1, TRUE, FALSE, GTK_CSS_TEXT_TRANSFORM_LOWERCASE, "lowercase" },
|
||||
{ >K_CSS_VALUE_TEXT_TRANSFORM, 1, TRUE, FALSE, GTK_CSS_TEXT_TRANSFORM_UPPERCASE, "uppercase" },
|
||||
{ >K_CSS_VALUE_TEXT_TRANSFORM, 1, TRUE, FALSE, GTK_CSS_TEXT_TRANSFORM_CAPITALIZE, "capitalize" },
|
||||
};
|
||||
|
||||
GtkCssValue *
|
||||
|
@ -723,7 +723,7 @@ static const GtkCssValueClass GTK_CSS_VALUE_FILTER = {
|
||||
gtk_css_value_filter_print
|
||||
};
|
||||
|
||||
static GtkCssValue filter_none_singleton = { >K_CSS_VALUE_FILTER, 1, TRUE, 0, { { GTK_CSS_FILTER_NONE } } };
|
||||
static GtkCssValue filter_none_singleton = { >K_CSS_VALUE_FILTER, 1, TRUE, FALSE, 0, { { GTK_CSS_FILTER_NONE } } };
|
||||
|
||||
static GtkCssValue *
|
||||
gtk_css_filter_value_alloc (guint n_filters)
|
||||
|
@ -136,7 +136,7 @@ static const GtkCssValueClass GTK_CSS_VALUE_IMAGE = {
|
||||
GtkCssValue *
|
||||
_gtk_css_image_value_new (GtkCssImage *image)
|
||||
{
|
||||
static GtkCssValue image_none_singleton = { >K_CSS_VALUE_IMAGE, 1, TRUE, NULL };
|
||||
static GtkCssValue image_none_singleton = { >K_CSS_VALUE_IMAGE, 1, TRUE, FALSE, NULL };
|
||||
GtkCssValue *value;
|
||||
|
||||
if (image == NULL)
|
||||
|
@ -366,38 +366,38 @@ gtk_css_dimension_value_new (double value,
|
||||
GtkCssUnit unit)
|
||||
{
|
||||
static GtkCssValue number_singletons[] = {
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_NUMBER, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_NUMBER, 1 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_NUMBER, 96 }} }, /* DPI default */
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_NUMBER, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_NUMBER, 1 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_NUMBER, 96 }} }, /* DPI default */
|
||||
};
|
||||
static GtkCssValue px_singletons[] = {
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 1 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 2 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 3 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 4 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 5 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 6 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 7 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 8 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 16 }} }, /* Icon size default */
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 32 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PX, 64 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 1 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 2 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 3 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 4 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 5 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 6 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 7 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 8 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 16 }} }, /* Icon size default */
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 32 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PX, 64 }} },
|
||||
};
|
||||
static GtkCssValue percent_singletons[] = {
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_PERCENT, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PERCENT, 50 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PERCENT, 100 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PERCENT, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, FALSE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PERCENT, 50 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, FALSE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_PERCENT, 100 }} },
|
||||
};
|
||||
static GtkCssValue second_singletons[] = {
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_S, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_S, 1 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_S, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_S, 1 }} },
|
||||
};
|
||||
static GtkCssValue deg_singletons[] = {
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_DEG, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_DEG, 90 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_DEG, 180 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, TYPE_DIMENSION, {{ GTK_CSS_DEG, 270 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_DEG, 0 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_DEG, 90 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_DEG, 180 }} },
|
||||
{ >K_CSS_VALUE_NUMBER, 1, TRUE, FALSE, TYPE_DIMENSION, {{ GTK_CSS_DEG, 270 }} },
|
||||
};
|
||||
GtkCssValue *result;
|
||||
|
||||
|
@ -140,28 +140,28 @@ static struct {
|
||||
GtkCssValue values[4];
|
||||
} background_repeat_values[4] = {
|
||||
{ "no-repeat",
|
||||
{ { >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_NO_REPEAT, GTK_CSS_REPEAT_STYLE_NO_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_NO_REPEAT, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_NO_REPEAT, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_NO_REPEAT, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
{ { >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_NO_REPEAT, GTK_CSS_REPEAT_STYLE_NO_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_NO_REPEAT, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_NO_REPEAT, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_NO_REPEAT, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
} },
|
||||
{ "repeat",
|
||||
{ { >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_NO_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
{ { >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_NO_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
} },
|
||||
{ "round",
|
||||
{ { >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_NO_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
{ { >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_NO_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
} },
|
||||
{ "space",
|
||||
{ { >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_NO_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
{ { >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_NO_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BACKGROUND_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
} }
|
||||
};
|
||||
|
||||
@ -234,28 +234,28 @@ static struct {
|
||||
GtkCssValue values[4];
|
||||
} border_repeat_values[4] = {
|
||||
{ "stretch",
|
||||
{ { >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_STRETCH, GTK_CSS_REPEAT_STYLE_STRETCH },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_STRETCH, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_STRETCH, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_STRETCH, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
{ { >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_STRETCH, GTK_CSS_REPEAT_STYLE_STRETCH },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_STRETCH, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_STRETCH, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_STRETCH, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
} },
|
||||
{ "repeat",
|
||||
{ { >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_STRETCH },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
{ { >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_STRETCH },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_REPEAT, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
} },
|
||||
{ "round",
|
||||
{ { >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_STRETCH },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
{ { >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_STRETCH },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_ROUND, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
} },
|
||||
{ "space",
|
||||
{ { >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_STRETCH },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
{ { >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_STRETCH },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_REPEAT },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_ROUND },
|
||||
{ >K_CSS_VALUE_BORDER_REPEAT, 1, TRUE, FALSE, GTK_CSS_REPEAT_STYLE_SPACE, GTK_CSS_REPEAT_STYLE_SPACE }
|
||||
} }
|
||||
};
|
||||
|
||||
|
@ -226,3 +226,4 @@ _gtk_css_ident_value_get (const GtkCssValue *value)
|
||||
return value->string;
|
||||
}
|
||||
|
||||
|
||||
|
@ -801,7 +801,7 @@ static const GtkCssValueClass GTK_CSS_VALUE_TRANSFORM = {
|
||||
gtk_css_value_transform_print
|
||||
};
|
||||
|
||||
static GtkCssValue transform_none_singleton = { >K_CSS_VALUE_TRANSFORM, 1, TRUE, 0, { { GTK_CSS_TRANSFORM_NONE } } };
|
||||
static GtkCssValue transform_none_singleton = { >K_CSS_VALUE_TRANSFORM, 1, TRUE, FALSE, 0, { { GTK_CSS_TRANSFORM_NONE } } };
|
||||
|
||||
static GtkCssValue *
|
||||
gtk_css_transform_value_alloc (guint n_transforms)
|
||||
|
@ -367,3 +367,9 @@ gtk_css_value_is_computed (const GtkCssValue *value)
|
||||
{
|
||||
return value->is_computed;
|
||||
}
|
||||
|
||||
gboolean
|
||||
gtk_css_value_contains_variables (const GtkCssValue *value)
|
||||
{
|
||||
return value->contains_variables;
|
||||
}
|
||||
|
@ -37,7 +37,8 @@ typedef struct _GtkCssValueClass GtkCssValueClass;
|
||||
#define GTK_CSS_VALUE_BASE \
|
||||
const GtkCssValueClass *class; \
|
||||
int ref_count; \
|
||||
guint is_computed: 1;
|
||||
guint is_computed: 1; \
|
||||
guint contains_variables: 1;
|
||||
|
||||
struct _GtkCssValueClass {
|
||||
const char *type_name;
|
||||
@ -93,6 +94,7 @@ char * _gtk_css_value_to_string (const GtkCssValue
|
||||
void _gtk_css_value_print (const GtkCssValue *value,
|
||||
GString *string);
|
||||
gboolean gtk_css_value_is_computed (const GtkCssValue *value) G_GNUC_PURE;
|
||||
gboolean gtk_css_value_contains_variables (const GtkCssValue *value) G_GNUC_PURE;
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user