You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-users@xmlgraphics.apache.org by Kurt Dequick <ku...@tiscalinet.be> on 2003/01/27 22:14:16 UTC

showing dynamic documents ?

hello,

I'm new to this list (and also new to Java and SVG :-)
I'm using XSLT to create SVG. If I write the output to a file, I'm able 
to show the resulting SVG on screen.
[with svgCanvas.loadSVGDocument(svgFile.toURL().toString());]

But without an intermediate file I'm not able to show the SVG.
I found this code below doing a search on the internet, but although 
it doesn't fail, it also doesn't show the SVG drawing... 

DOMImplementation impl = 
SVGDOMImplementation.getDOMImplementation();
String svgNS = SVGDOMImplementation.SVG_NAMESPACE_URI;
SVGOMDocument outDoc =
     (SVGOMDocument)impl.createDocument(svgNS, "svg", null);

trans.transform
     (xmlSource,
      new 
javax.xml.transform.dom.DOMResult(outDoc.getDocumentElement(
)));

svgCanvas.setSVGDocument(outDoc);


what am I doing wrong ?

bye,
Kurt

--
http://www27.brinkster.com/kurtsmaze

 I'll never forget the afternoon I read Professor [Thomas 
 Henry] Huxley's essay on 'The Gaderene Swine'.
 
(Robert A Heinlein , from "To Sail Beyond the Sunset" , page 25)


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