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 Paulo Soares <ps...@consiste.pt> on 2002/04/23 15:55:53 UTC

Rendering SVG to a Graphics2D

I'm a developer with the iText library (http://www.lowagie.com/iText) that
generates PDF documents. Recently a class that extends Graphics2D was added
to the library with the result that anything drawn ends up in the PDF. Is it
possible to write an SVG to a Graphics2D and thus generate a PDF? I know of
FOP and I could use it to generate a PDF and then import it but I'm adding
shading and transparency to the library and that's something that FOP
doesn't support.

Best Regards,
Paulo Soares


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


Re: Rendering SVG to a Graphics2D

Posted by Vincent Hardy <vi...@sun.com>.
Paulo,

Paulo Soares wrote:
> 
> I'm a developer with the iText library (http://www.lowagie.com/iText) that
> generates PDF documents. Recently a class that extends Graphics2D was added
> to the library with the result that anything drawn ends up in the PDF. Is it
> possible to write an SVG to a Graphics2D and thus generate a PDF? I know of
> FOP and I could use it to generate a PDF and then import it but I'm adding
> shading and transparency to the library and that's something that FOP
> doesn't support.
> 

You could build a GVT tree from your SVG document (with the 
GVTBuilder) and then paint that tree into your custom Graphics2D.

Vincent.

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