xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marcin Tustin <marcin.tus...@gmail.com>
Subject Certain fonts cause FOP to crash
Date Wed, 25 Jan 2012 13:15:27 GMT
Hi all,

I'm new to FOP. I'm using it to format documents to PCL.

The issue I've encountered is that certain fonts cause FOP to crash,
with the errors below (there is far more debug output, but this is the
stuff that seems most relevant). Is this a known issue? Is there a
workaround or solution?

I am performing the output by adapting the
org.docx4j.convert.out.pdf.viaXSLFO.Conversion class. I have attached
my code for completeness. This works just fine for documents with
certain other fonts.

24404 [main] DEBUG org.apache.fop.render.pcl.PCLDocumentHandler  -
Don't know how to handle extension object. Ignoring:
org.apache.xmlgraphics.xmp.Metadata@5e10
11d8 (org.apache.xmlgraphics.xmp.Metadata)
24407 [main] DEBUG org.apache.fop.render.pcl.PCLDocumentHandler  -
page size: java.awt.Dimension[width=595276,height=841890]
24407 [main] DEBUG org.apache.fop.render.pcl.PCLDocumentHandler  -
logical page: java.awt.Rectangle[x=17040,y=0,width=561120,height=841680]
24441 [main] DEBUG org.apache.xmlgraphics.image.loader.ImageManager  -
Chosen pipeline: null
24472 [main] ERROR org.apache.fop.apps.FOUserAgent  - Error while
rendering page 1. Reason: java.lang.RuntimeException:
org.apache.fop.render.intermediate.IFExc
eption: Error while painting marks using a bitmap
Exception in thread "main"
org.docx4j.openpackaging.exceptions.Docx4JException: FOP issues
        at org.docx4j.convert.out.pdf.viaXSLFO.PclConversion.output(PclConversion.java:236)
        at CreatePcl.main(CreatePcl.java:110)
Caused by: java.lang.RuntimeException:
org.apache.fop.render.intermediate.IFException: Error while painting
marks using a bitmap
        at org.apache.fop.render.intermediate.IFRenderer.handleIFException(IFRenderer.java:189)
        at org.apache.fop.render.intermediate.IFRenderer.access$200(IFRenderer.java:105)
        at org.apache.fop.render.intermediate.IFRenderer$TextUtil.flush(IFRenderer.java:1149)
        at org.apache.fop.render.intermediate.IFRenderer.renderText(IFRenderer.java:1020)
        at org.apache.fop.render.AbstractRenderer.renderInlineArea(AbstractRenderer.java:620)
        at org.apache.fop.render.intermediate.IFRenderer.renderInlineArea(IFRenderer.java:912)
        at org.apache.fop.render.AbstractRenderer.renderInlineParent(AbstractRenderer.java:711)
        at org.apache.fop.render.intermediate.IFRenderer.renderInlineParent(IFRenderer.java:929)
        at org.apache.fop.render.AbstractRenderer.renderInlineArea(AbstractRenderer.java:628)
        at org.apache.fop.render.intermediate.IFRenderer.renderInlineArea(IFRenderer.java:912)
        at org.apache.fop.render.AbstractRenderer.renderLineArea(AbstractRenderer.java:609)
        at org.apache.fop.render.AbstractRenderer.renderBlocks(AbstractRenderer.java:544)
        at org.apache.fop.render.AbstractRenderer.renderBlock(AbstractRenderer.java:581)
        at org.apache.fop.render.intermediate.IFRenderer.renderBlock(IFRenderer.java:976)
        at org.apache.fop.render.AbstractRenderer.renderBlocks(AbstractRenderer.java:534)
        at org.apache.fop.render.AbstractRenderer.renderFlow(AbstractRenderer.java:432)
        at org.apache.fop.render.AbstractPathOrientedRenderer.renderFlow(AbstractPathOrientedRenderer.java:665)
        at org.apache.fop.render.AbstractRenderer.renderMainReference(AbstractRenderer.java:411)
        at org.apache.fop.render.AbstractRenderer.renderBodyRegion(AbstractRenderer.java:345)
        at org.apache.fop.render.AbstractRenderer.renderRegionViewport(AbstractRenderer.java:292)
        at org.apache.fop.render.intermediate.IFRenderer.renderRegionViewport(IFRenderer.java:731)
        at org.apache.fop.render.AbstractRenderer.renderPageAreas(AbstractRenderer.java:265)
        at org.apache.fop.render.AbstractRenderer.renderPage(AbstractRenderer.java:230)
        at org.apache.fop.render.intermediate.IFRenderer.renderPage(IFRenderer.java:580)
        at org.apache.fop.area.RenderPagesModel.renderPage(RenderPagesModel.java:183)
        at org.apache.fop.area.RenderPagesModel.checkPreparedPages(RenderPagesModel.java:164)
        at org.apache.fop.area.RenderPagesModel.addPage(RenderPagesModel.java:137)
        at org.apache.fop.layoutmgr.AbstractPageSequenceLayoutManager.finishPage(AbstractPageSequenceLayoutManager.java:312)
        at org.apache.fop.layoutmgr.PageSequenceLayoutManager.finishPage(PageSequenceLayoutManager.java:167)
        at org.apache.fop.layoutmgr.PageSequenceLayoutManager.activateLayout(PageSequenceLayoutManager.java:109)
        at org.apache.fop.area.AreaTreeHandler.endPageSequence(AreaTreeHandler.java:238)
        at org.apache.fop.fo.pagination.PageSequence.endOfNode(PageSequence.java:120)
        at org.apache.fop.fo.FOTreeBuilder$MainFOHandler.endElement(FOTreeBuilder.java:349)
        at org.apache.fop.fo.FOTreeBuilder.endElement(FOTreeBuilder.java:177)
        at org.apache.xalan.transformer.TransformerIdentityImpl.endElement(TransformerIdentityImpl.java:1102)
        at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(Unknown
Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(Unknown
Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown
Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown
Source)
        at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown
Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown
Source)
        at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown
Source)
        at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown
Source)
        at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown
Source)
        at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown
Source)
        at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:485)
        at org.docx4j.convert.out.pdf.viaXSLFO.PclConversion.output(PclConversion.java:224)
        ... 1 more
Caused by: org.apache.fop.render.intermediate.IFException: Error while
painting marks using a bitmap
        at org.apache.fop.render.pcl.PCLPainter.paintMarksAsBitmap(PCLPainter.java:310)
        at org.apache.fop.render.pcl.PCLPainter.drawTextAsBitmap(PCLPainter.java:490)
        at org.apache.fop.render.pcl.PCLPainter.drawText(PCLPainter.java:330)
        at org.apache.fop.render.intermediate.IFRenderer$TextUtil.flush(IFRenderer.java:1146)
        ... 45 more
Caused by: org.apache.xmlgraphics.image.loader.ImageException: Cannot
convert image org.apache.xmlgraphics.image.loader.impl.ImageGraphics2D:
null (null) (no su
itable converter combination available)
        at org.apache.xmlgraphics.image.loader.ImageManager.convertImage(ImageManager.java:353)
        at org.apache.fop.render.intermediate.AbstractIFPainter.drawImage(AbstractIFPainter.java:209)
        at org.apache.fop.render.pcl.PCLPainter.paintMarksAsBitmap(PCLPainter.java:305)
        ... 48 more



-- 
Marcin Tustin
Tel: 07773 787 105

Mime
View raw message