[gtk+] cssvalue: Get rid of unused functions
- From: Benjamin Otte <otte src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] cssvalue: Get rid of unused functions
- Date: Tue, 17 Apr 2012 07:12:26 +0000 (UTC)
commit 8e3e3d582f7df902caa3c3e0ec9f503d1c6d9fd0
Author: Benjamin Otte <otte redhat com>
Date: Mon Mar 26 07:26:45 2012 +0200
cssvalue: Get rid of unused functions
gtk/gtkcssvalue.c | 40 ----------------------------------------
gtk/gtkcssvalueprivate.h | 4 ----
gtk/gtkstyleproperties.c | 4 ++--
3 files changed, 2 insertions(+), 46 deletions(-)
---
diff --git a/gtk/gtkcssvalue.c b/gtk/gtkcssvalue.c
index 8030cd4..b79c4ee 100644
--- a/gtk/gtkcssvalue.c
+++ b/gtk/gtkcssvalue.c
@@ -260,17 +260,6 @@ g_boxed_copy0 (GType boxed_type,
}
GtkCssValue *
-_gtk_css_value_new_from_border (const GtkBorder *border)
-{
- GtkCssValue *value;
-
- value = gtk_css_value_new (GTK_TYPE_BORDER);
- value->u.ptr = g_boxed_copy0 (GTK_TYPE_BORDER, border);
-
- return value;
-}
-
-GtkCssValue *
_gtk_css_value_new_take_pattern (cairo_pattern_t *v)
{
GtkCssValue *value;
@@ -282,17 +271,6 @@ _gtk_css_value_new_take_pattern (cairo_pattern_t *v)
}
GtkCssValue *
-_gtk_css_value_new_from_pattern (const cairo_pattern_t *v)
-{
- GtkCssValue *value;
-
- value = gtk_css_value_new (CAIRO_GOBJECT_TYPE_PATTERN);
- value->u.ptr = g_boxed_copy0 (CAIRO_GOBJECT_TYPE_PATTERN, v);
-
- return value;
-}
-
-GtkCssValue *
_gtk_css_value_new_take_shadow (GtkShadow *v)
{
GtkCssValue *value;
@@ -304,17 +282,6 @@ _gtk_css_value_new_take_shadow (GtkShadow *v)
}
GtkCssValue *
-_gtk_css_value_new_take_font_description (PangoFontDescription *v)
-{
- GtkCssValue *value;
-
- value = gtk_css_value_new (PANGO_TYPE_FONT_DESCRIPTION);
- value->u.ptr = v;
-
- return value;
-}
-
-GtkCssValue *
_gtk_css_value_new_take_image (GtkCssImage *v)
{
GtkCssValue *value;
@@ -651,13 +618,6 @@ _gtk_css_value_get_border_corner_radius (const GtkCssValue *value)
return value->u.ptr;
}
-PangoFontDescription *
-_gtk_css_value_get_font_description (const GtkCssValue *value)
-{
- g_return_val_if_fail (_gtk_css_value_holds (value, PANGO_TYPE_FONT_DESCRIPTION), 0);
- return value->u.ptr;
-}
-
PangoStyle
_gtk_css_value_get_pango_style (const GtkCssValue *value)
{
diff --git a/gtk/gtkcssvalueprivate.h b/gtk/gtkcssvalueprivate.h
index b87dc57..047f9ea 100644
--- a/gtk/gtkcssvalueprivate.h
+++ b/gtk/gtkcssvalueprivate.h
@@ -71,13 +71,10 @@ GtkCssValue *_gtk_css_value_new_from_gvalue (const GValue
GtkCssValue *_gtk_css_value_new_take_gvalue (GValue *g_value);
GtkCssValue *_gtk_css_value_new_from_int (gint val);
GtkCssValue *_gtk_css_value_new_take_string (char *string);
-GtkCssValue *_gtk_css_value_new_take_font_description (PangoFontDescription *v);
GtkCssValue *_gtk_css_value_new_from_rgba (const GdkRGBA *v);
GtkCssValue *_gtk_css_value_new_from_color (const GdkColor *v);
GtkCssValue *_gtk_css_value_new_take_symbolic_color (GtkSymbolicColor *v);
-GtkCssValue *_gtk_css_value_new_from_border (const GtkBorder *border);
GtkCssValue *_gtk_css_value_new_take_pattern (cairo_pattern_t *v);
-GtkCssValue *_gtk_css_value_new_from_pattern (const cairo_pattern_t *v);
GtkCssValue *_gtk_css_value_new_take_shadow (GtkShadow *v);
GtkCssValue *_gtk_css_value_new_take_image (GtkCssImage *v);
GtkCssValue *_gtk_css_value_new_from_number (const GtkCssNumber *v);
@@ -104,7 +101,6 @@ const GtkCssBackgroundSize *_gtk_css_value_get_background_size (const
const GtkCssBackgroundPosition *_gtk_css_value_get_background_position (const GtkCssValue *value);
const GtkCssBorderCornerRadius *_gtk_css_value_get_border_corner_radius (const GtkCssValue *value);
const GtkCssBorderImageRepeat *_gtk_css_value_get_border_image_repeat (const GtkCssValue *value);
-PangoFontDescription * _gtk_css_value_get_font_description (const GtkCssValue *value);
PangoStyle _gtk_css_value_get_pango_style (const GtkCssValue *value);
PangoVariant _gtk_css_value_get_pango_variant (const GtkCssValue *value);
PangoWeight _gtk_css_value_get_pango_weight (const GtkCssValue *value);
diff --git a/gtk/gtkstyleproperties.c b/gtk/gtkstyleproperties.c
index 5446d99..52187ef 100644
--- a/gtk/gtkstyleproperties.c
+++ b/gtk/gtkstyleproperties.c
@@ -911,8 +911,8 @@ gtk_style_properties_merge (GtkStyleProperties *props,
PangoFontDescription *font_desc_to_merge;
/* Handle merging of font descriptions */
- font_desc = _gtk_css_value_get_font_description (value->value);
- font_desc_to_merge = _gtk_css_value_get_font_description (data->value);
+ font_desc = _gtk_css_value_get_boxed (value->value);
+ font_desc_to_merge = _gtk_css_value_get_boxed (data->value);
pango_font_description_merge (font_desc, font_desc_to_merge, replace);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]