OK, nobody do an update! We have to keep Vincent working! ;)
-----Original Message-----
From: Vincent Hardy [mailto:[EMAIL PROTECTED]]
Sent: Monday, July 08, 2002 6:54 AM
To: Batik Users
Subject: Re: Why do I get: Unknown language: text/ecmascript
Hello again,
I just committed a fix for this problem, so I will not work after you
do a CVS update.
Cheers,
Vincent.
Vincent Hardy wrote:
>
> Hello,
>
> This is due to the input document having a null URL. I'll fix this for
> the RhinoClassLoader. In the meanwhile, you can set a dummy URL on the
> document, something like:
>
> ((SVGOMDocument)doc).setURLObject(new
> java.net.URL("file:/c:/temp/dummy.svg"));
>
> Vincent.
>
> J Aaron Farr wrote:
> >
> > Okay, I'm running a test here trying to load SVG which has been
generated by
> > the SVGGraphics2D converter to a SVGCanvas object. If anyone knows of
an
> > easier way let me know.
> >
> > If I use this method, everything works fine:
> >
> > String svg = generateSVG(doc);
> > System.out.println(svg);
> > StringReader sr = new StringReader(svg);
> > SAXSVGDocumentFactory df = new
> > SAXSVGDocumentFactory("org.apache.xerces.parsers.SAXParser");
> > SVGOMDocument svgDoc = df.createDocument(null,sr);
> >
> > svgCanvas.setSVGDocument(svgDoc);
> > // File f = new File("test.svg");
> > // svgCanvas.setURI(f.toURL().toString());
> >
> > java.lang.Exception: Unknown language: text/ecmascript
> > at
> >
org.apache.batik.bridge.BaseScriptingEnvironment.dispatchSVGLoadEvent(Unknow
n
> > Source)
> > at
org.apache.batik.bridge.UpdateManager.dispatchSVGLoadEvent(Unknown Source)
> >
> > at org.apache.batik.swing.svg.SVGLoadEventDispatcher.run(Unknown
Source)
> >
> > java.lang.NullPointerException
> >
> > at
java.net.URLClassLoader.getPermissions(URLClassLoader.java:422)
> >
> > at
org.apache.batik.script.rhino.RhinoClassLoader.getPermissions(Unknown
> > Source)
> >
> > at org.apache.batik.script.rhino.RhinoClassLoader.<init>(Unknown
Source)
> >
> > at org.apache.batik.script.rhino.RhinoInterpreter.<init>(Unknown
Source)
> >
> > at
> >
org.apache.batik.script.rhino.RhinoInterpreterFactory.createInterpreter(Unkn
own
> > Source)
> >
> > at
org.apache.batik.script.InterpreterPool.createInterpreter(Unknown Source)
> >
> > at org.apache.batik.bridge.BridgeContext.getInterpreter(Unknown
Source)
> >
> > at
> >
org.apache.batik.bridge.BaseScriptingEnvironment.dispatchSVGLoadEvent(Unknow
n
> > Source)
> >
> > at
org.apache.batik.bridge.UpdateManager.dispatchSVGLoadEvent(Unknown Source)
> >
> > at org.apache.batik.swing.svg.SVGLoadEventDispatcher.run(Unknown
Source)
> >
> > __________________________________________________
> > Do You Yahoo!?
> > Sign up for SBC Yahoo! Dial - First Month Free
> > http://sbc.yahoo.com
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]