xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Richard Mixon (qwest)" <rnmi...@qwest.net>
Subject Error FOP/BATIK ... PDFXMLHandler:253 - svg graphic could not be built"
Date Thu, 03 Feb 2005 02:51:02 GMT
My build of FOP from 2004/05/29 works fine on Sun Java 1.4.1_02 with
Tomcat 5.0.19, but when I move toSun Java 1.5.1 and Tomcat 5.5.7 I get
the URI I/O error listed below. This build included a Batik.jar with
files dates 10/11/2003.

The exception message below seems to indicate it is choking on the
SmileyFace.gif file - but I am not sure why. I google the archives and
could not really find a problem with Java 1.5 and FOP/Batik.

I went and downloaded the latest CVS of FOP, but it looks like the
Driver class my code depended on is now gone. I could not find any doc
on how to use the new APIs.

I found one Wiki page
(http://wiki.apache.org/xmlgraphics-fop/SvgNotes/PdfTranscoderTrueTypeEm
bedding), but it expects a pure SVG file. I have been wrapping my svg
graphic with FO markup (see below the exception for how it normally
appears)

Any ideas on how to either fix the current problem, or do an SVG to PDF
transform with the new API?

Thank you in advance - Richard


19:34:42,179 ERROR [TP-Processor1] PDFXMLHandler:253 - svg graphic could
not be built: file://c:/jakarta-tomcat-5.5.7/webapps/stars/.:-1
An I/O error occured while processing the URI
'file://c/jakarta-tomcat-5.5.7/webapps/stars/images/allTimeBest/SmileyFa
ce.gif' specified on the element <image>
org.apache.batik.bridge.BridgeException:
file://c:/jakarta-tomcat-5.5.7/webapps/stars/.:-1
An I/O error occured while processing the URI
'file://c/jakarta-tomcat-5.5.7/webapps/stars/images/allTimeBest/SmileyFa
ce.gif' specified on the element <image>
	at org.apache.batik.bridge.SVGImageElementBridge.openStream(Unknown
Source)
	at
org.apache.batik.bridge.SVGImageElementBridge.createImageGraphicsNode(Un
known Source)
	at
org.apache.batik.bridge.SVGImageElementBridge.buildImageGraphicsNode(Unk
nown Source)
	at
org.apache.batik.bridge.SVGImageElementBridge.createGraphicsNode(Unknown
Source)
	at org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(Unknown Source)
	at org.apache.batik.bridge.GVTBuilder.buildComposite(Unknown Source)
	at org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(Unknown Source)
	at org.apache.batik.bridge.GVTBuilder.buildComposite(Unknown Source)
	at org.apache.batik.bridge.GVTBuilder.build(Unknown Source)
	at
org.apache.fop.render.pdf.PDFXMLHandler$SVGHandler.renderSVGDocument(PDF
XMLHandler.java:251)
	at
org.apache.fop.render.pdf.PDFXMLHandler.handleXML(PDFXMLHandler.java:156
)
	at
org.apache.fop.render.AbstractRenderer.renderXML(AbstractRenderer.java:7
66)
	at
org.apache.fop.render.pdf.PDFRenderer.renderDocument(PDFRenderer.java:12
40)
	at
org.apache.fop.render.pdf.PDFRenderer.renderForeignObject(PDFRenderer.ja
va:1206)
	at
org.apache.fop.render.AbstractRenderer.renderViewport(AbstractRenderer.j
ava:675)
	at
org.apache.fop.render.pdf.PDFRenderer.renderViewport(PDFRenderer.java:12
65)
	at
org.apache.fop.render.AbstractRenderer.renderInlineArea(AbstractRenderer
.java:623)
	at
org.apache.fop.render.AbstractRenderer.renderLineArea(AbstractRenderer.j
ava:609)
	at
org.apache.fop.render.pdf.PDFRenderer.renderLineArea(PDFRenderer.java:85
5)
	at
org.apache.fop.render.AbstractRenderer.renderBlocks(AbstractRenderer.jav
a:546)
	at
org.apache.fop.render.pdf.PDFRenderer.renderBlocks(PDFRenderer.java:503)
	at
org.apache.fop.render.AbstractRenderer.renderBlock(AbstractRenderer.java
:587)
	at
org.apache.fop.render.AbstractRenderer.renderBlocks(AbstractRenderer.jav
a:537)
	at
org.apache.fop.render.pdf.PDFRenderer.renderBlocks(PDFRenderer.java:503)
	at
org.apache.fop.render.AbstractRenderer.renderFlow(AbstractRenderer.java:
462)
	at
org.apache.fop.render.AbstractRenderer.renderMainReference(AbstractRende
rer.java:445)
	at
org.apache.fop.render.AbstractRenderer.renderBodyRegion(AbstractRenderer
.java:381)
	at
org.apache.fop.render.AbstractRenderer.renderRegionViewport(AbstractRend
erer.java:327)
	at
org.apache.fop.render.AbstractRenderer.renderPageAreas(AbstractRenderer.
java:299)
	at
org.apache.fop.render.pdf.PDFRenderer.renderPage(PDFRenderer.java:436)
	at
org.apache.fop.area.RenderPagesModel.checkPreparedPages(RenderPagesModel
.java:118)
	at
org.apache.fop.area.RenderPagesModel.addPage(RenderPagesModel.java:97)
	at org.apache.fop.area.AreaTree.addPage(AreaTree.java:111)
	at
org.apache.fop.layoutmgr.PageLayoutManager.finishPage(PageLayoutManager.
java:507)
	at
org.apache.fop.layoutmgr.PageLayoutManager.doLayout(PageLayoutManager.ja
va:203)
	at
org.apache.fop.layoutmgr.PageLayoutManager.run(PageLayoutManager.java:17
8)
	at org.apache.fop.apps.Document.format(Document.java:219)
	at
org.apache.fop.apps.Document.foPageSequenceComplete(Document.java:123)
	at
org.apache.fop.fo.FOTreeHandler.notifyPageSequenceComplete(FOTreeHandler
.java:501)
	at
org.apache.fop.fo.FOTreeHandler.endPageSequence(FOTreeHandler.java:187)
	at org.apache.fop.fo.pagination.PageSequence.end(PageSequence.java:312)
	at org.apache.fop.fo.FOTreeBuilder.endElement(FOTreeBuilder.java:260)
	at
org.apache.fop.tools.ProxyContentHandler.endElement(ProxyContentHandler.
java:94)
	at
com.sun.org.apache.xml.internal.serializer.ToXMLSAXHandler.endElement(To
XMLSAXHandler.java:262)
	at
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(
AbstractSAXParser.java:633)
	at
com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanEnd
Element(XMLNSDocumentScannerImpl.java:719)
	at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$F
ragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:16
85)
	at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.s
canDocument(XMLDocumentFragmentScannerImpl.java:368)
	at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML1
1Configuration.java:834)
	at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML1
1Configuration.java:764)
	at
com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.jav
a:148)
	at
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Abstr
actSAXParser.java:1242)
	at
com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transformId
entity(TransformerImpl.java:557)
	at
com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(T
ransformerImpl.java:638)
	at
com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(T
ransformerImpl.java:279)
	at com.ltoj.webapp.action.SVG2PDFServlet.doGet(SVG2PDFServlet.java:166)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:252)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:173)
	at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatc
her.java:673)
	at
org.apache.catalina.core.ApplicationDispatcher.processRequest(Applicatio
nDispatcher.java:464)
	at
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDisp
atcher.java:399)
	at
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispat
cher.java:302)
	at
org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java
:691)
	at
org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:6
58)
	at
org.apache.struts.taglib.logic.ForwardTag.doForward(ForwardTag.java:123)
	at
org.apache.struts.taglib.logic.ForwardTag.doEndTag(ForwardTag.java:107)
	at
org.apache.jsp.WEB_002dINF.pages.run_jsp._jspx_meth_logic$1el_forward_0(
org.apache.jsp.WEB_002dINF.pages.run_jsp:12343)
	at
org.apache.jsp.WEB_002dINF.pages.run_jsp._jspService(org.apache.jsp.WEB_
002dINF.pages.run_jsp:990)
	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:99)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja
va:325)
	at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:252)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:173)
	at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatc
her.java:673)
	at
org.apache.catalina.core.ApplicationDispatcher.processRequest(Applicatio
nDispatcher.java:464)
	at
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDisp
atcher.java:399)
	at
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispat
cher.java:302)
	at
org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.jav
a:1056)
	at
org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProc
essor.java:261)
	at
org.apache.struts.action.RequestProcessor.processForwardConfig(RequestPr
ocessor.java:388)
	at
org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(Tiles
RequestProcessor.java:316)
	at
org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:
231)
	at
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1158)
	at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:397)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:252)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:173)
	at
com.ltoj.webapp.filter.BreadCrumbFilter.doFilter(BreadCrumbFilter.java:9
4)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:202)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:173)
	at com.ltoj.webapp.filter.ActionFilter.doFilter(ActionFilter.java:431)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:202)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:173)
	at
com.atlassian.util.profiling.filters.ProfilingFilter.doFilter(ProfilingF
ilter.java:132)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:202)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:173)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:214)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.java:178)
	at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authenticator
Base.java:482)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:126)
	at
org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve
.java:130)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:105)
	at
org.apache.catalina.valves.FastCommonAccessLogValve.invoke(FastCommonAcc
essLogValve.java:481)
	at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:526
)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java:107)
	at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:1
48)
	at
org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:306)
	at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:385)
	at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:745)
	at
org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:
675)
	at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:868)
	at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool
.java:684)
	at java.lang.Thread.run(Thread.java:595)


FO MARKUP NORMALLLY WRAPPED AROUND SVG GRAPHIC:

<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"
         xmlns:xlink="http://www.w3.org/1999/xlink"
         xmlns:xsl="http://www.w3.org/1999/Transform"
>
  <fo:layout-master-set>
    <fo:simple-page-master
  margin-right="0.5in"
  margin-left="0.5in"
  margin-bottom="0.5in"
  margin-top="0.5in"
  page-width="11.0in"
  page-height="8.5in"
  master-name="first">
      <fo:region-body margin-top="0in" margin-bottom=".25in"/>
      <fo:region-before extent="0in"/>
      <fo:region-after extent=".25in"/>
    </fo:simple-page-master>
  </fo:layout-master-set>
  <fo:page-sequence master-reference="first">
    <!-- Break footer into three parts (left/middle/right), one label
list embedded in another label list -->
    <fo:static-content flow-name="xsl-region-after">
      <!-- One list embedded in another list to give a left, center and
right footer -->
      <fo:list-block line-height="12pt" font-size="9pt"
provisional-label-separation="0pt"
provisional-distance-between-starts="3.4in">
        <fo:list-item>
          <fo:list-item-label end-indent="label-end()">
            <fo:block text-align="left">
              Produced Wed, 2 Feb 2005 19:45 by From LtoJ&#x2122;
Software, LLC
            </fo:block>
          </fo:list-item-label>
          <fo:list-item-body start-indent="body-start()">
            <fo:list-block line-height="12pt" font-size="9pt"
provisional-label-separation="0pt"
provisional-distance-between-starts="3.33in">
              <fo:list-item>
                <fo:list-item-label end-indent="label-end()">
                  <fo:block text-align="center">

                  </fo:block>
                </fo:list-item-label>
                <fo:list-item-body start-indent="body-start()">
                  <fo:block text-align="right">
                    Page <fo:page-number/>
                  </fo:block>
                </fo:list-item-body>
              </fo:list-item>
            </fo:list-block>
          </fo:list-item-body>
        </fo:list-item>
      </fo:list-block>
    </fo:static-content>
      <fo:flow flow-name="xsl-region-body">
        <fo:block content-width="10in" content-height="7.5in">
          <fo:instream-foreign-object>
    <svg:svg
        width="713"
        height="516"
        preserveAspectRatio="xMinYMin meet"
        onload="getSVGDoc(evt)"
        xmlns:svg="http://www.w3.org/2000/svg"
        >
       <SNIP - REST OF SVG GRAPHIC OMMITTED>
    </svg:svg>
        </fo:instream-foreign-object>
      </fo:block>
    </fo:flow>
  </fo:page-sequence>


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


Mime
View raw message