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 Lars Eirik Rønning <la...@gmail.com> on 2008/06/12 09:58:57 UTC

SVG to PDF using FOP

Hi.
I have used the batik rasterizer.jar to generate pdf files from svg.
I would like to do this using the regular pdftranscoder , that is not using
the batik-rasterizer.
When i look at FOP i see that there are lots of classes which is not found
within my batik project.
FopFactory is one of these.

I guess that the batik implemention wraps the functionality of the
pdftranscoder in some way, but i would very much like to know how i can use
batik to get a pdf.

I tried to add the dependency fop version 0.93 but this seems to depend on
earlier versions of batik.

is ther an easy way to programmatically transcode to pdf without having to
use the rasterizer.jar?

Thanks for helping guys.

Re: SVG to PDF using FOP

Posted by Lars Eirik Rønning <la...@gmail.com>.
Thanks Jeremias.
I will have try this today!

On Thu, Jun 12, 2008 at 4:33 PM, Jeremias Maerki <de...@jeremias-maerki.ch>
wrote:

> Im' not sure if I've understood you correctly. The PDF Transcoder is a
> plug-in for Batik. pdf-transcoder.jar (bundled with Batik) is a subset
> of Apache FOP. Classes like FopFactory are only used when you convert
> XSL-FO to PDF.
>
> If you want to programmatically transcoder SVG files to PDF, please read
> the basics about the Transcoder API:
> http://xmlgraphics.apache.org/batik/using/transcoder.html
> Then, instead of JPEGTranscoder or PNGTranscoder, instantiate
> org.apache.fop.svg.PDFTranscoder. The pattern remains the same.
>
> For this, the batik-rasterizer.jar is not needed but some other JARs
> from Batik's lib directory are. The alternative is that you download FOP
> 0.95beta. You've tried 0.93 but that is already a bit old.
>
> I hope that helps.
>
> On 12.06.2008 09:58:57 Lars Eirik Rønning wrote:
> > Hi.
> > I have used the batik rasterizer.jar to generate pdf files from svg.
> > I would like to do this using the regular pdftranscoder , that is not
> using
> > the batik-rasterizer.
> > When i look at FOP i see that there are lots of classes which is not
> found
> > within my batik project.
> > FopFactory is one of these.
> >
> > I guess that the batik implemention wraps the functionality of the
> > pdftranscoder in some way, but i would very much like to know how i can
> use
> > batik to get a pdf.
> >
> > I tried to add the dependency fop version 0.93 but this seems to depend
> on
> > earlier versions of batik.
> >
> > is ther an easy way to programmatically transcode to pdf without having
> to
> > use the rasterizer.jar?
> >
> > Thanks for helping guys.
>
>
>
>
> Jeremias Maerki
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org
>
>

Re: SVG to PDF using FOP

Posted by Jeremias Maerki <de...@jeremias-maerki.ch>.
Im' not sure if I've understood you correctly. The PDF Transcoder is a
plug-in for Batik. pdf-transcoder.jar (bundled with Batik) is a subset
of Apache FOP. Classes like FopFactory are only used when you convert
XSL-FO to PDF.

If you want to programmatically transcoder SVG files to PDF, please read
the basics about the Transcoder API:
http://xmlgraphics.apache.org/batik/using/transcoder.html
Then, instead of JPEGTranscoder or PNGTranscoder, instantiate
org.apache.fop.svg.PDFTranscoder. The pattern remains the same.

For this, the batik-rasterizer.jar is not needed but some other JARs
from Batik's lib directory are. The alternative is that you download FOP
0.95beta. You've tried 0.93 but that is already a bit old.

I hope that helps.

On 12.06.2008 09:58:57 Lars Eirik Rønning wrote:
> Hi.
> I have used the batik rasterizer.jar to generate pdf files from svg.
> I would like to do this using the regular pdftranscoder , that is not using
> the batik-rasterizer.
> When i look at FOP i see that there are lots of classes which is not found
> within my batik project.
> FopFactory is one of these.
> 
> I guess that the batik implemention wraps the functionality of the
> pdftranscoder in some way, but i would very much like to know how i can use
> batik to get a pdf.
> 
> I tried to add the dependency fop version 0.93 but this seems to depend on
> earlier versions of batik.
> 
> is ther an easy way to programmatically transcode to pdf without having to
> use the rasterizer.jar?
> 
> Thanks for helping guys.




Jeremias Maerki


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