You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-commits@xmlgraphics.apache.org by je...@apache.org on 2010/10/21 08:44:32 UTC

svn commit: r1025850 - /xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java

Author: jeremias
Date: Thu Oct 21 06:44:32 2010
New Revision: 1025850

URL: http://svn.apache.org/viewvc?rev=1025850&view=rev
Log:
Wrap the whole page stream in a q..Q pair to avoid problems when the page streams are combined later with additional content.

Modified:
    xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java

Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java?rev=1025850&r1=1025849&r2=1025850&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/svg/PDFDocumentGraphics2D.java Thu Oct 21 06:44:32 2010
@@ -256,6 +256,7 @@ public class PDFDocumentGraphics2D exten
         if (!pdfContext.isPagePending()) {
             return; //ignore
         }
+        currentStream.write("Q\n");
         //Finish page
         PDFStream pdfStream = this.pdfDoc.getFactory().makeStream(
                 PDFFilterList.CONTENT_FILTER, false);
@@ -321,6 +322,7 @@ public class PDFDocumentGraphics2D exten
         pdfContext.setCurrentPage(page);
         pageRef = page.referencePDF();
 
+        currentStream.write("q\n");
         AffineTransform at = new AffineTransform(1.0, 0.0, 0.0, -1.0,
                                                  0.0, height);
         currentStream.write("1 0 0 -1 0 " + height + " cm\n");



---------------------------------------------------------------------
To unsubscribe, e-mail: fop-commits-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-commits-help@xmlgraphics.apache.org