From 973b85ff8b57115d30847fe93041a7a875bbe7b4 Mon Sep 17 00:00:00 2001 From: cristy Date: Tue, 27 Mar 2012 14:56:21 +0000 Subject: [PATCH] --- coders/pango.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/coders/pango.c b/coders/pango.c index 75fc60661..5752790c5 100644 --- a/coders/pango.c +++ b/coders/pango.c @@ -326,7 +326,7 @@ static Image *ReadPANGOImage(const ImageInfo *image_info, if (image->columns == 0) { pango_layout_get_pixel_extents(layout,NULL,&extent); - image->columns=extent.x+extent.width; + image->columns=extent.x+extent.width+2*page.x; } else { @@ -337,7 +337,7 @@ static Image *ReadPANGOImage(const ImageInfo *image_info, if (image->rows == 0) { pango_layout_get_pixel_extents(layout,NULL,&extent); - image->rows=extent.y+extent.height; + image->rows=extent.y+extent.height+2*page.y; } else { @@ -364,6 +364,7 @@ static Image *ReadPANGOImage(const ImageInfo *image_info, cairo_set_operator(cairo_image,CAIRO_OPERATOR_CLEAR); cairo_paint(cairo_image); cairo_set_operator(cairo_image,CAIRO_OPERATOR_OVER); + cairo_translate(cairo_image,page.x,page.y); pango_cairo_show_layout(cairo_image,layout); cairo_destroy(cairo_image); cairo_surface_destroy(surface); -- 2.40.0