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 "Wagenbreth, IT BK Zust, DD" <S....@deutschepost.de> on 2001/06/25 11:15:31 UTC
svg_output for document
Hello!
I want to design a SVG-grafik with Java2D-methods on an SVGGraphics2D.
Because I rotated one of the SVGGraphics2D, I created 2 paint-methods and put the 2 different SVGGraphics2Ds
into
doc.getDocumentElement().appendChild(paint1(g).getRoot());
doc.getDocumentElement().appendChild(paint2(g).getRoot());
Is there any way to get out the SVG-Code?
The stream(..) method is only defined for class org.apache.batik.svggen.SVGGraphics2D
___________________________________________________________________________
java-code:
DOMImplementation impl = SVGDOMImplementation.getDOMImplementation();
String namespaceURI = SVGDOMImplementation.SVG_NAMESPACE_URI;
Document doc = impl.createDocument(namespaceURI, "svg", null);
SVGGraphics2D g = new SVGGraphics2D(doc);
doc.getDocumentElement().appendChild(paint1(g).getRoot());
doc.getDocumentElement().appendChild(paint2(g).getRoot());
public SVGGraphics2D paint1(SVGGraphics2D g){
//paint...
return g;
}
public SVGGraphics2D paint2(SVGGraphics2D g){
g.rotate(...);
//paint...
return g;
}
___________________________________________________________________________
Thanks a lot for your help!
Greetings
Susanne
---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-users-help@xml.apache.org