diff options
author | Matthias Clasen <mclasen@redhat.com> | 2022-10-08 09:22:26 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2022-10-12 15:35:00 -0400 |
commit | 60dafebd91cd9ef446238b1e970b34ead452c2ab (patch) | |
tree | d06775ec471ff5aaec6f08aa494376781eb203bb /gtk/gtkglarea.c | |
parent | 35370752d50d800e07ed6f8baf857ee1708e68b7 (diff) | |
download | gtk+-60dafebd91cd9ef446238b1e970b34ead452c2ab.tar.gz |
Deprecate gtk_snapshot_render apis
Move the implementations from gtksnapshot.c to
gtk/deprecated/gtkrender.c and deprecated these
functions. We want to get rid of them.
These functions are still used in some of our widgetry,
so use G_GNUC_BEGIN/END_IGNORE_DEPRECATIONS around
them.
Diffstat (limited to 'gtk/gtkglarea.c')
-rw-r--r-- | gtk/gtkglarea.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gtk/gtkglarea.c b/gtk/gtkglarea.c index 92016afe98..2810ed0c1a 100644 --- a/gtk/gtkglarea.c +++ b/gtk/gtkglarea.c @@ -29,6 +29,7 @@ #include "gtksnapshot.h" #include "gtknative.h" #include "gtkwidgetprivate.h" +#include "deprecated/gtkrender.h" #include <epoxy/gl.h> @@ -659,10 +660,12 @@ gtk_gl_area_draw_error_screen (GtkGLArea *area, pango_layout_set_alignment (layout, PANGO_ALIGN_CENTER); pango_layout_get_pixel_size (layout, NULL, &layout_height); +G_GNUC_BEGIN_IGNORE_DEPRECATIONS gtk_snapshot_render_layout (snapshot, gtk_widget_get_style_context (GTK_WIDGET (area)), 0, (height - layout_height) / 2, layout); +G_GNUC_END_IGNORE_DEPRECATIONS g_object_unref (layout); } |