]> www.fi.muni.cz Git - evince.git/commitdiff
Restore cairo context before rendering every page when printing a PDF
authorCarlos Garcia Campos <carlosgc@gnome.org>
Thu, 15 Feb 2007 11:56:11 +0000 (11:56 +0000)
committerCarlos Garcia Campos <carlosgc@src.gnome.org>
Thu, 15 Feb 2007 11:56:11 +0000 (11:56 +0000)
2007-02-15  Carlos Garcia Campos  <carlosgc@gnome.org>
* backend/pdf/ev-poppler.cc: (pdf_document_file_exporter_do_page):
Restore cairo context before rendering every page when printing a PDF
document into a PDF file.

svn path=/trunk/; revision=2327

ChangeLog
backend/pdf/ev-poppler.cc

index 1b7a182c1e84536d8934fbe4a830cbc86de0a310..f0fbff275f832f3297b2a2d479ef6ab4c2361f94 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2007-02-15  Carlos Garcia Campos  <carlosgc@gnome.org>
+
+       * backend/pdf/ev-poppler.cc: (pdf_document_file_exporter_do_page):
+
+       Restore cairo context before rendering every page when printing a PDF
+       document into a PDF file. 
+
 2007-02-13  Carlos Garcia Campos  <carlosgc@gnome.org>
 
        * backend/ps/gstypes.h:
index 5c7f495d3301f17e8fcdeb9296d588e99562fb06..7c2c5281fb25cac868fc30afb879b982a3cfb15f 100644 (file)
@@ -1577,11 +1577,15 @@ pdf_document_file_exporter_do_page (EvFileExporter *exporter, EvRenderContext *r
                        poppler_page_render_to_ps (poppler_page, ctx->ps_file);
                        break;
                case EV_FILE_FORMAT_PDF:
+#ifdef HAVE_CAIRO_PDF
+                       cairo_save (ctx->pdf_cairo);
+#endif
 #ifdef HAVE_POPPLER_PAGE_RENDER
                        poppler_page_render (poppler_page, ctx->pdf_cairo);
 #endif
 #ifdef HAVE_CAIRO_PDF
                        cairo_show_page (ctx->pdf_cairo);
+                       cairo_restore (ctx->pdf_cairo);
 #endif
                        break;
                default: