Commit b874e6c3 authored by Alexander Larsson's avatar Alexander Larsson Committed by Benjamin Otte

css: Support GtkBackgroundPosition in cssvalue

parent ca075596
......@@ -347,6 +347,17 @@ _gtk_css_value_new_from_background_size (const GtkCssBackgroundSize *v)
return value;
}
GtkCssValue *
_gtk_css_value_new_from_background_position (const GtkCssBackgroundPosition *v)
{
GtkCssValue *value;
value = _gtk_css_value_new (GTK_TYPE_CSS_BACKGROUND_POSITION);
value->u.ptr = g_boxed_copy0 (GTK_TYPE_CSS_BACKGROUND_POSITION, v);
return value;
}
GtkCssValue *
_gtk_css_value_new_take_symbolic_color (GtkSymbolicColor *v)
{
......@@ -564,6 +575,13 @@ _gtk_css_value_get_background_size (GtkCssValue *value)
return value->u.ptr;
}
GtkCssBackgroundPosition *
_gtk_css_value_get_background_position (GtkCssValue *value)
{
g_return_val_if_fail (_gtk_css_value_holds (value, GTK_TYPE_CSS_BACKGROUND_POSITION), NULL);
return value->u.ptr;
}
GtkCssBorderImageRepeat *
_gtk_css_value_get_border_image_repeat (GtkCssValue *value)
{
......
......@@ -61,6 +61,7 @@ GtkCssValue *_gtk_css_value_new_take_shadow (GtkShadow
GtkCssValue *_gtk_css_value_new_take_image (GtkCssImage *v);
GtkCssValue *_gtk_css_value_new_from_number (const GtkCssNumber *v);
GtkCssValue *_gtk_css_value_new_from_background_size (const GtkCssBackgroundSize *v);
GtkCssValue *_gtk_css_value_new_from_background_position (const GtkCssBackgroundPosition *v);
void _gtk_css_value_to_gvalue (GtkCssValue *value,
GValue *g_value);
void _gtk_css_value_init_gvalue (GtkCssValue *value,
......@@ -80,6 +81,7 @@ GtkSymbolicColor *_gtk_css_value_get_symbolic_color (GtkCssValue
GtkCssImage *_gtk_css_value_get_image (GtkCssValue *value);
GtkBorderStyle _gtk_css_value_get_border_style (GtkCssValue *value);
GtkCssBackgroundSize *_gtk_css_value_get_background_size (GtkCssValue *value);
GtkCssBackgroundPosition *_gtk_css_value_get_background_position (GtkCssValue *value);
GtkCssBorderCornerRadius *_gtk_css_value_get_border_corner_radius (GtkCssValue *value);
GtkCssBorderImageRepeat *_gtk_css_value_get_border_image_repeat (GtkCssValue *value);
PangoFontDescription * _gtk_css_value_get_font_description (GtkCssValue *value);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment