From: Carlos Garcia Campos Date: Thu, 15 Feb 2007 11:56:11 +0000 (+0000) Subject: Restore cairo context before rendering every page when printing a PDF X-Git-Tag: EVINCE_0_8_0~49 X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=commitdiff_plain;h=d8ed4cd9b3f558e51091632282aaaf39146fcb9b;p=evince.git Restore cairo context before rendering every page when printing a PDF 2007-02-15 Carlos Garcia Campos * 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 --- diff --git a/ChangeLog b/ChangeLog index 1b7a182c..f0fbff27 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2007-02-15 Carlos Garcia Campos + + * 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 * backend/ps/gstypes.h: diff --git a/backend/pdf/ev-poppler.cc b/backend/pdf/ev-poppler.cc index 5c7f495d..7c2c5281 100644 --- a/backend/pdf/ev-poppler.cc +++ b/backend/pdf/ev-poppler.cc @@ -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: