[gtk+/rendering-cleanup: 27/95] xxx: style: Draw text with pango_cairo_draw_layout()



commit cdb821ca91538eeb06b6da452b2e7730be5831a9
Author: Benjamin Otte <otte redhat com>
Date:   Wed Jul 21 14:17:49 2010 +0200

    xxx: style: Draw text with pango_cairo_draw_layout()
    
    Previous code was using pango_cairo_layout_path() + cairo_fill() which
    obviously destroyed all color markup, and that is BAD.

 gtk/gtkstyle.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/gtk/gtkstyle.c b/gtk/gtkstyle.c
index 22f678c..8fe4181 100644
--- a/gtk/gtkstyle.c
+++ b/gtk/gtkstyle.c
@@ -4435,8 +4435,7 @@ gtk_default_draw_layout (GtkStyle        *style,
   cairo_move_to (cr, x, y);
   gdk_cairo_set_source_color (cr, gc);
 
-  pango_cairo_layout_path (cr, layout);
-  cairo_fill (cr);
+  pango_cairo_show_layout (cr, layout);
 
   cairo_destroy (cr);
 }



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]