diff options
author | Timm Bäder <mail@baedert.org> | 2018-07-07 14:34:18 +0200 |
---|---|---|
committer | Timm Bäder <mail@baedert.org> | 2018-07-08 09:41:15 +0200 |
commit | bb31ce11682aaa2753db549df03c862f9041bdbd (patch) | |
tree | 8911ee48aca51eb97e7ad3ea1d861b06368fc199 | |
parent | dbf32933bff50eda20684c4248ac158b76ec8b79 (diff) | |
download | gtk+-bb31ce11682aaa2753db549df03c862f9041bdbd.tar.gz |
renderborder: Remove some unused API
-rw-r--r-- | gtk/gtkrenderborder.c | 54 | ||||
-rw-r--r-- | gtk/gtkrenderborderprivate.h | 14 |
2 files changed, 0 insertions, 68 deletions
diff --git a/gtk/gtkrenderborder.c b/gtk/gtkrenderborder.c index be5993698a..f8e81253ea 100644 --- a/gtk/gtkrenderborder.c +++ b/gtk/gtkrenderborder.c @@ -856,18 +856,6 @@ snapshot_border (GtkSnapshot *snapshot, snapshot_frame_fill (snapshot, border_box, border_width, colors, hidden_side); } -gboolean -gtk_css_style_render_has_border (GtkCssStyle *style) -{ - if (_gtk_css_image_value_get_image (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_BORDER_IMAGE_SOURCE))) - return TRUE; - - return _gtk_css_number_value_get (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_BORDER_TOP_WIDTH), 100) > 0 - || _gtk_css_number_value_get (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_BORDER_RIGHT_WIDTH), 100) > 0 - || _gtk_css_number_value_get (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_BORDER_BOTTOM_WIDTH), 100) > 0 - || _gtk_css_number_value_get (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_BORDER_LEFT_WIDTH), 100) > 0; -} - void gtk_css_style_render_border (GtkCssStyle *style, cairo_t *cr, @@ -983,25 +971,6 @@ gtk_css_style_snapshot_border (GtkCssStyle *style, } gboolean -gtk_css_style_render_border_get_clip (GtkCssStyle *style, - gdouble x, - gdouble y, - gdouble width, - gdouble height, - GdkRectangle *out_clip) -{ - if (!gtk_css_style_render_has_border (style)) - return FALSE; - - out_clip->x = floor (x); - out_clip->y = floor (y); - out_clip->width = ceil (x + width) - out_clip->x; - out_clip->height = ceil (y + height) - out_clip->y; - - return TRUE; -} - -gboolean gtk_css_style_render_has_outline (GtkCssStyle *style) { return _gtk_css_number_value_get (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_OUTLINE_WIDTH), 100) > 0; @@ -1109,26 +1078,3 @@ gtk_css_style_snapshot_outline (GtkCssStyle *style, snapshot_border (snapshot, &border_box, border_width, colors, border_style); } } - -gboolean -gtk_css_style_render_outline_get_clip (GtkCssStyle *style, - gdouble x, - gdouble y, - gdouble width, - gdouble height, - GdkRectangle *out_clip) -{ - cairo_rectangle_t rect; - - if (!gtk_css_style_render_has_outline (style)) - return FALSE; - - compute_outline_rect (style, x, y, width, height, &rect); - - out_clip->x = floor (rect.x); - out_clip->y = floor (rect.y); - out_clip->width = ceil (rect.x + rect.width) - out_clip->x; - out_clip->height = ceil (rect.y + rect.height) - out_clip->y; - - return TRUE; -} diff --git a/gtk/gtkrenderborderprivate.h b/gtk/gtkrenderborderprivate.h index b9f94cf37c..c0bed70854 100644 --- a/gtk/gtkrenderborderprivate.h +++ b/gtk/gtkrenderborderprivate.h @@ -29,19 +29,12 @@ G_BEGIN_DECLS -gboolean gtk_css_style_render_has_border (GtkCssStyle *style); void gtk_css_style_render_border (GtkCssStyle *style, cairo_t *cr, gdouble x, gdouble y, gdouble width, gdouble height); -gboolean gtk_css_style_render_border_get_clip (GtkCssStyle *style, - gdouble x, - gdouble y, - gdouble width, - gdouble height, - GdkRectangle *out_clip) G_GNUC_WARN_UNUSED_RESULT; void gtk_css_style_snapshot_border (GtkCssStyle *style, GtkSnapshot *snapshot, gdouble width, @@ -58,13 +51,6 @@ void gtk_css_style_snapshot_outline (GtkCssStyle GtkSnapshot *snapshot, gdouble width, gdouble height); -gboolean gtk_css_style_render_outline_get_clip (GtkCssStyle *style, - gdouble x, - gdouble y, - gdouble width, - gdouble height, - GdkRectangle *out_clip) G_GNUC_WARN_UNUSED_RESULT; - G_END_DECLS |