diff options
author | Vincent Hennebert <vhennebert@apache.org> | 2009-09-18 17:10:42 +0000 |
---|---|---|
committer | Vincent Hennebert <vhennebert@apache.org> | 2009-09-18 17:10:42 +0000 |
commit | 0e5a789b6b0604bb9c6cc9b782c22f490917e9f9 (patch) | |
tree | 70af78b83ebd8d83f4576c8b9329113ee34aae0f /src/java/org/apache/fop/pdf/PDFFactory.java | |
parent | c5d9b312e01efc7f96a30043d73945594504c7d0 (diff) | |
parent | 9b49126cd645f4377d1bb56d5078a8d4a0cd491e (diff) | |
download | xmlgraphics-fop-0e5a789b6b0604bb9c6cc9b782c22f490917e9f9.tar.gz xmlgraphics-fop-0e5a789b6b0604bb9c6cc9b782c22f490917e9f9.zip |
Merged changes from Trunk up to revision 816269
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/Temp_Accessibility@816718 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/fop/pdf/PDFFactory.java')
-rw-r--r-- | src/java/org/apache/fop/pdf/PDFFactory.java | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/java/org/apache/fop/pdf/PDFFactory.java b/src/java/org/apache/fop/pdf/PDFFactory.java index 087ae4277..db2e99875 100644 --- a/src/java/org/apache/fop/pdf/PDFFactory.java +++ b/src/java/org/apache/fop/pdf/PDFFactory.java @@ -174,22 +174,24 @@ public class PDFFactory { * PDFDocument later using addObject(). * * @param resources resources object to use - * @param pageWidth width of the page in points - * @param pageHeight height of the page in points * @param pageIndex index of the page (zero-based) + * @param mediaBox the MediaBox area + * @param cropBox the CropBox area + * @param bleedBox the BleedBox area + * @param trimBox the TrimBox area * @param currentPageParentKey the integer key in the structural parent tree * * @return the created /Page object */ - public PDFPage makePage(PDFResources resources, - int pageWidth, int pageHeight, int pageIndex, + public PDFPage makePage(PDFResources resources, int pageIndex, + Rectangle2D mediaBox, Rectangle2D cropBox, + Rectangle2D bleedBox, Rectangle2D trimBox, int currentPageParentKey) { /* * create a PDFPage with the next object number, the given * resources, contents and dimensions */ - PDFPage page = new PDFPage(resources, // old numPages - pageWidth, pageHeight, pageIndex); + PDFPage page = new PDFPage(resources, pageIndex, mediaBox, cropBox, bleedBox, trimBox); if (currentPageParentKey > -1) { //Accessibility is enabled page.setStructParents(currentPageParentKey); @@ -217,7 +219,8 @@ public class PDFFactory { */ public PDFPage makePage(PDFResources resources, int pageWidth, int pageHeight, int pageIndex) { - return makePage(resources, pageWidth, pageHeight, pageIndex, -1); + Rectangle2D mediaBox = new Rectangle2D.Double(0, 0, pageWidth, pageHeight); + return makePage(resources, pageIndex, mediaBox, mediaBox, mediaBox, mediaBox, -1); } /** |