aboutsummaryrefslogtreecommitdiffstats
path: root/src/java/org/apache/fop/pdf/PDFRoot.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/java/org/apache/fop/pdf/PDFRoot.java')
-rw-r--r--src/java/org/apache/fop/pdf/PDFRoot.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/java/org/apache/fop/pdf/PDFRoot.java b/src/java/org/apache/fop/pdf/PDFRoot.java
index 0a0f03d6d..66e58c5f0 100644
--- a/src/java/org/apache/fop/pdf/PDFRoot.java
+++ b/src/java/org/apache/fop/pdf/PDFRoot.java
@@ -52,6 +52,8 @@ public class PDFRoot extends PDFDictionary {
private final PDFDocument document;
+ private PDFDPartRoot dPartRoot;
+
private static final PDFName[] PAGEMODE_NAMES = new PDFName[] {
new PDFName("UseNone"),
@@ -318,4 +320,12 @@ public class PDFRoot extends PDFDictionary {
public PDFDictionary getMarkInfo() {
return (PDFDictionary)get("MarkInfo");
}
+
+ public PDFDPartRoot getDPartRoot() {
+ if (dPartRoot == null) {
+ dPartRoot = getDocument().getFactory().makeDPartRoot();
+ put("DPartRoot", dPartRoot.makeReference());
+ }
+ return dPartRoot;
+ }
}