diff options
Diffstat (limited to 'src/org/apache/fop')
-rw-r--r-- | src/org/apache/fop/render/pdf/PDFRenderer.java | 3 | ||||
-rw-r--r-- | src/org/apache/fop/render/pdf/fonts/LazyFont.java | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/org/apache/fop/render/pdf/PDFRenderer.java b/src/org/apache/fop/render/pdf/PDFRenderer.java index ff59db46e..01dacee24 100644 --- a/src/org/apache/fop/render/pdf/PDFRenderer.java +++ b/src/org/apache/fop/render/pdf/PDFRenderer.java @@ -153,6 +153,7 @@ public class PDFRenderer extends PrintRenderer { public void stopRenderer(OutputStream stream) throws IOException { + FontSetup.addToResources(this.pdfDoc, fontInfo); pdfDoc.outputTrailer(stream); } @@ -684,7 +685,7 @@ public class PDFRenderer extends PrintRenderer { this.pdfDoc.setIDReferences(idReferences); this.renderPage(page); - FontSetup.addToResources(this.pdfDoc, fontInfo); + //FontSetup.addToResources(this.pdfDoc, fontInfo); // TODO: this needs to be implemented renderRootExtensions(page); diff --git a/src/org/apache/fop/render/pdf/fonts/LazyFont.java b/src/org/apache/fop/render/pdf/fonts/LazyFont.java index 80faae2de..e9fc2caee 100644 --- a/src/org/apache/fop/render/pdf/fonts/LazyFont.java +++ b/src/org/apache/fop/render/pdf/fonts/LazyFont.java @@ -33,6 +33,7 @@ public class LazyFont extends Font implements FontDescriptor { private void load(){ if(! isMetricsLoaded){ + isMetricsLoaded = true; try{ FontReader reader = new FontReader(metricsFileName); reader.useKerning(useKerning); @@ -41,7 +42,6 @@ public class LazyFont extends Font implements FontDescriptor { if(realFont instanceof FontDescriptor){ realFontDescriptor = (FontDescriptor) realFont; } - isMetricsLoaded = true; // System.out.println("Metrics " + metricsFileName + " loaded."); } catch (Exception ex) { MessageHandler.error("Failed to read font metrics file " |