You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by Swapan Golla <sg...@yahoo.com> on 2003/03/06 22:51:21 UTC

Batik Extension/FOP problem

Hi All,
       I am trying to use batik extensions through
FOP. I added BatikElementMapping and BatikObj objects
into my FOP src and then registered them in the driver
class but I am still getting some exceptions. Can
anybody help me out ? I am trying to embed the
flowText.svg ( provided by batik distribution ) into a
simple fo document and then trying to convert into a
pdf.

Swapan.


[ERROR] svg graphic could not be built: null
java.lang.ClassCastException
at
org.apache.batik.bridge.CSSUtilities.getComputedStyle(CSSUtilities.java:96)
at
org.apache.batik.bridge.CSSUtilities.convertDisplay(CSSUtilities.java:509)
at
org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(GVTBuilder.java:176)
at
org.apache.batik.bridge.GVTBuilder.buildComposite(GVTBuilder.java:148)
at
org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(GVTBuilder.java:188)
at
org.apache.batik.bridge.GVTBuilder.buildComposite(GVTBuilder.java:148)
at
org.apache.batik.bridge.GVTBuilder.build(GVTBuilder.java:76)
at
org.apache.fop.render.pdf.PDFRenderer.renderSVGDocument(PDFRenderer.java:513)
at
org.apache.fop.render.pdf.PDFRenderer.renderSVGArea(PDFRenderer.java:472)
at
org.apache.fop.svg.SVGArea.render(SVGArea.java:58)
at
org.apache.fop.render.pdf.PDFRenderer.renderForeignObjectArea(PDFRenderer.java:456)
at
org.apache.fop.layout.inline.ForeignObjectArea.render(ForeignObjectArea.java:46)
at
org.apache.fop.render.AbstractRenderer.renderAreaContainer(AbstractRenderer.java:408)
at
org.apache.fop.layout.ColumnArea.render(ColumnArea.java:29)
at
org.apache.fop.render.AbstractRenderer.renderSpanArea(AbstractRenderer.java:57).....................


__________________________________________________
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, more
http://taxes.yahoo.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


RE: Batik Extension/FOP problem

Posted by Thomas E Deweese <th...@kodak.com>.
>>>>> "SG" == Swapan Golla <sg...@yahoo.com> writes:

SG> I am trying to use batik extensions through FOP. I added
SG> BatikElementMapping and BatikObj objects into my FOP src and then
SG> registered them in the driver class but I am still getting some
SG> exceptions. Can anybody help me out ? 

    I don't know, The error you are getting is indicative of passing a
non Batik DOM node into Batik.  Is it possible that you are
mis-mapping the elements from FOP?  the batik:flowText element needs
to become a bati.extension.svg.FlowTextElement the others need to be
mapped likewise.  Just mapping them to generic elements won't work.

SG> I am trying to embed the flowText.svg ( provided by batik
SG> distribution ) into a simple fo document and then trying to
SG> convert into a pdf.

SG> Swapan.


SG> [ERROR] svg graphic could not be built: null
SG> java.lang.ClassCastException at
SG> org.apache.batik.bridge.CSSUtilities.getComputedStyle(CSSUtilities.java:96)
SG> at
SG> org.apache.batik.bridge.CSSUtilities.convertDisplay(CSSUtilities.java:509)
SG> at
SG> org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(GVTBuilder.java:176)
SG> at
SG> org.apache.batik.bridge.GVTBuilder.buildComposite(GVTBuilder.java:148)
SG> at
SG> org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(GVTBuilder.java:188)
SG> at
SG> org.apache.batik.bridge.GVTBuilder.buildComposite(GVTBuilder.java:148)
SG> at org.apache.batik.bridge.GVTBuilder.build(GVTBuilder.java:76) at
SG> org.apache.fop.render.pdf.PDFRenderer.renderSVGDocument(PDFRenderer.java:513)
SG> at
SG> org.apache.fop.render.pdf.PDFRenderer.renderSVGArea(PDFRenderer.java:472)
SG> at org.apache.fop.svg.SVGArea.render(SVGArea.java:58) at
SG> org.apache.fop.render.pdf.PDFRenderer.renderForeignObjectArea(PDFRenderer.java:456)
SG> at
SG> org.apache.fop.layout.inline.ForeignObjectArea.render(ForeignObjectArea.java:46)
SG> at
SG> org.apache.fop.render.AbstractRenderer.renderAreaContainer(AbstractRenderer.java:408)
SG> at org.apache.fop.layout.ColumnArea.render(ColumnArea.java:29) at
SG> org.apache.fop.render.AbstractRenderer.renderSpanArea(AbstractRenderer.java:57).....................


SG> __________________________________________________ Do you Yahoo!?
SG> Yahoo! Tax Center - forms, calculators, tips, more
SG> http://taxes.yahoo.com/

SG> ---------------------------------------------------------------------
SG> To unsubscribe, e-mail: batik-dev-unsubscribe@xml.apache.org For
SG> additional commands, e-mail: batik-dev-help@xml.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-dev-help@xml.apache.org


RE: Batik Extension/FOP problem

Posted by Thomas E Deweese <th...@kodak.com>.
>>>>> "SG" == Swapan Golla <sg...@yahoo.com> writes:

SG> I am trying to use batik extensions through FOP. I added
SG> BatikElementMapping and BatikObj objects into my FOP src and then
SG> registered them in the driver class but I am still getting some
SG> exceptions. Can anybody help me out ? 

    I don't know, The error you are getting is indicative of passing a
non Batik DOM node into Batik.  Is it possible that you are
mis-mapping the elements from FOP?  the batik:flowText element needs
to become a bati.extension.svg.FlowTextElement the others need to be
mapped likewise.  Just mapping them to generic elements won't work.

SG> I am trying to embed the flowText.svg ( provided by batik
SG> distribution ) into a simple fo document and then trying to
SG> convert into a pdf.

SG> Swapan.


SG> [ERROR] svg graphic could not be built: null
SG> java.lang.ClassCastException at
SG> org.apache.batik.bridge.CSSUtilities.getComputedStyle(CSSUtilities.java:96)
SG> at
SG> org.apache.batik.bridge.CSSUtilities.convertDisplay(CSSUtilities.java:509)
SG> at
SG> org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(GVTBuilder.java:176)
SG> at
SG> org.apache.batik.bridge.GVTBuilder.buildComposite(GVTBuilder.java:148)
SG> at
SG> org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(GVTBuilder.java:188)
SG> at
SG> org.apache.batik.bridge.GVTBuilder.buildComposite(GVTBuilder.java:148)
SG> at org.apache.batik.bridge.GVTBuilder.build(GVTBuilder.java:76) at
SG> org.apache.fop.render.pdf.PDFRenderer.renderSVGDocument(PDFRenderer.java:513)
SG> at
SG> org.apache.fop.render.pdf.PDFRenderer.renderSVGArea(PDFRenderer.java:472)
SG> at org.apache.fop.svg.SVGArea.render(SVGArea.java:58) at
SG> org.apache.fop.render.pdf.PDFRenderer.renderForeignObjectArea(PDFRenderer.java:456)
SG> at
SG> org.apache.fop.layout.inline.ForeignObjectArea.render(ForeignObjectArea.java:46)
SG> at
SG> org.apache.fop.render.AbstractRenderer.renderAreaContainer(AbstractRenderer.java:408)
SG> at org.apache.fop.layout.ColumnArea.render(ColumnArea.java:29) at
SG> org.apache.fop.render.AbstractRenderer.renderSpanArea(AbstractRenderer.java:57).....................


SG> __________________________________________________ Do you Yahoo!?
SG> Yahoo! Tax Center - forms, calculators, tips, more
SG> http://taxes.yahoo.com/

SG> ---------------------------------------------------------------------
SG> To unsubscribe, e-mail: batik-dev-unsubscribe@xml.apache.org For
SG> additional commands, e-mail: batik-dev-help@xml.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org