]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
FIX: Finally maybe fix the count thing
authorarved <arved@unknown>
Tue, 21 Mar 2000 10:53:47 +0000 (10:53 +0000)
committerarved <arved@unknown>
Tue, 21 Mar 2000 10:53:47 +0000 (10:53 +0000)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@193308 13f79535-47bb-0310-9956-ffa450edef68

src/org/apache/fop/pdf/PDFPages.java

index 4e4b29c67b8f089fe0cee44b081fb8a43db56547..7453f6be3aff9190d1a005662ce8d70d691bd2f4 100644 (file)
@@ -88,8 +88,10 @@ public class PDFPages extends PDFObject {
      * @param page the PDFPage to add.
      */
     public void addPage(PDFPage page) {
+       this.count++;
        this.kids.addElement(page);
        page.setParent(this);
+        this.incrementCount();
     }
 
     /**
@@ -101,6 +103,14 @@ public class PDFPages extends PDFObject {
        return this.count;
     }
 
+    /**
+     * increment the count of /Page objects
+     */
+    public void incrementCount() {
+       this.count++;
+        // System.out.println("Incrementing count to " + this.getCount());
+    }
+
     /**
      * represent the object in PDF
      *