]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
Correct inline writing when object has an object number.
authorJeremias Maerki <jeremias@apache.org>
Mon, 21 Jan 2008 10:40:38 +0000 (10:40 +0000)
committerJeremias Maerki <jeremias@apache.org>
Mon, 21 Jan 2008 10:40:38 +0000 (10:40 +0000)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@613835 13f79535-47bb-0310-9956-ffa450edef68

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

index 6ad6ff9eb5347ed2657d4d6769b4bf7f956a5d76..26d449591b6e9e8e4f6be74aa8c07a9e9a81c288 100644 (file)
@@ -85,7 +85,7 @@ public class PDFName extends PDFObject {
             writer.write(getObjectID());
         }
 
-        outputInline(stream, writer);
+        writer.write(toString());
         
         if (hasObjectNumber()) {
             writer.write("\nendobj\n");
@@ -97,7 +97,11 @@ public class PDFName extends PDFObject {
     
     /** {@inheritDoc} */
     public void outputInline(OutputStream out, Writer writer) throws IOException {
-        writer.write(toString());
+        if (hasObjectNumber()) {
+            writer.write(referencePDF());
+        } else {
+            writer.write(toString());
+        }
     }
     
 }