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 Martin Morawetz <ma...@kreativezone.at> on 2006/02/02 19:30:00 UTC

Trying to transcode SVG to EPS

Hello,

Trying to transcode an SVG to an EPS file using
following code:

public boolean transform(CharArrayWriter charArrayWriter , Writer writer)
	{
	EPSTranscoder trans = new EPSTranscoder();
	TranscoderInput input = new
		TranscoderInput(charArrayWriter.toString());
	TranscoderOutput output = new TranscoderOutput(writer);
		try
		{
		trans.transcode(input, output);
		writer.flush();
		}
	catch(TranscoderException e)
		{
		return false;
		}
	catch(IOException e)
		{
		return false;
		}

	return true;
	}

produces following exception:

[class org.apache.batik.transcoder.TranscoderException]: null
Enclosed Exception:
Unable to make sense of URL for connection
   at 
org.apache.batik.transcoder.XMLAbstractTranscoder.transcode(XMLAbstractTranscoder.java:126)
   at 
com.company.svggenerator.transform.EpsTransformer.transform(EpsTransformer.java:267)
       :
       :

I use batik 1.6 and a current pdf-transcoder.jar from the batik 1.6 zipfile.
I also have fop 0.20.5 in the classpath.


Any ideas?

-- 

Regards
Martin

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


Re: Trying to transcode SVG to EPS

Posted by Jeremias Maerki <de...@jeremias-maerki.ch>.
D'oh! Looks like we forgot to update a file. If you scroll down just a
little you'll see FOP 0.91 beta from 23 Dec 2005.

See also: http://xmlgraphics.apache.org/fop/relnotes.html

On 02.02.2006 21:41:05 Tracey Zellmann wrote:
> What do you believe is the "latest" release of FOP?
> 
> per http://mirrors.combose.com/apache/xmlgraphics/fop/
> 
>  The "latest release" distribution of FOP is version 0.20.5.
> 
> ----- Original Message ----- 
> From: "Jeremias Maerki" <de...@jeremias-maerki.ch>
> To: <ba...@xmlgraphics.apache.org>
> Sent: Thursday, February 02, 2006 2:08 PM
> Subject: Re: Trying to transcode SVG to EPS
> 
> 
> > Having Batik 1.6, pdf-transcoder.jar and FOP 0.20.5 together in the same
> > classpath begs for trouble. On the other side, I would have expected a
> > different error message if there was really something going wrong with
> > these very incompatible packages.
> >
> > Do other transcoders work? Run the whole thing again without FOP in the
> > classpath. Consider upgrading to the latest FOP release. If nothing
> > helps, please post the full stack trace.
> >
> > On a side-note: Finally someone who uses the EPSTranscoder. *g*
> >
> > On 02.02.2006 19:30:00 Martin Morawetz wrote:
> >> Hello,
> >>
> >> Trying to transcode an SVG to an EPS file using
> >> following code:
> >>
> >> public boolean transform(CharArrayWriter charArrayWriter , Writer writer)
> >> {
> >> EPSTranscoder trans = new EPSTranscoder();
> >> TranscoderInput input = new
> >> TranscoderInput(charArrayWriter.toString());
> >> TranscoderOutput output = new TranscoderOutput(writer);
> >> try
> >> {
> >> trans.transcode(input, output);
> >> writer.flush();
> >> }
> >> catch(TranscoderException e)
> >> {
> >> return false;
> >> }
> >> catch(IOException e)
> >> {
> >> return false;
> >> }
> >>
> >> return true;
> >> }
> >>
> >> produces following exception:
> >>
> >> [class org.apache.batik.transcoder.TranscoderException]: null
> >> Enclosed Exception:
> >> Unable to make sense of URL for connection
> >>    at
> >> org.apache.batik.transcoder.XMLAbstractTranscoder.transcode(XMLAbstractTranscoder.java:126)
> >>    at
> >> com.company.svggenerator.transform.EpsTransformer.transform(EpsTransformer.java:267)
> >>        :
> >>        :
> >>
> >> I use batik 1.6 and a current pdf-transcoder.jar from the batik 1.6 
> >> zipfile.
> >> I also have fop 0.20.5 in the classpath.
> >>
> >>
> >> Any ideas?
> >
> >
> >
> > Jeremias Maerki



Jeremias Maerki


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


Re: Trying to transcode SVG to EPS

Posted by Tracey Zellmann <tr...@comcast.net>.
What do you believe is the "latest" release of FOP?

per http://mirrors.combose.com/apache/xmlgraphics/fop/

 The "latest release" distribution of FOP is version 0.20.5.

----- Original Message ----- 
From: "Jeremias Maerki" <de...@jeremias-maerki.ch>
To: <ba...@xmlgraphics.apache.org>
Sent: Thursday, February 02, 2006 2:08 PM
Subject: Re: Trying to transcode SVG to EPS


> Having Batik 1.6, pdf-transcoder.jar and FOP 0.20.5 together in the same
> classpath begs for trouble. On the other side, I would have expected a
> different error message if there was really something going wrong with
> these very incompatible packages.
>
> Do other transcoders work? Run the whole thing again without FOP in the
> classpath. Consider upgrading to the latest FOP release. If nothing
> helps, please post the full stack trace.
>
> On a side-note: Finally someone who uses the EPSTranscoder. *g*
>
> On 02.02.2006 19:30:00 Martin Morawetz wrote:
>> Hello,
>>
>> Trying to transcode an SVG to an EPS file using
>> following code:
>>
>> public boolean transform(CharArrayWriter charArrayWriter , Writer writer)
>> {
>> EPSTranscoder trans = new EPSTranscoder();
>> TranscoderInput input = new
>> TranscoderInput(charArrayWriter.toString());
>> TranscoderOutput output = new TranscoderOutput(writer);
>> try
>> {
>> trans.transcode(input, output);
>> writer.flush();
>> }
>> catch(TranscoderException e)
>> {
>> return false;
>> }
>> catch(IOException e)
>> {
>> return false;
>> }
>>
>> return true;
>> }
>>
>> produces following exception:
>>
>> [class org.apache.batik.transcoder.TranscoderException]: null
>> Enclosed Exception:
>> Unable to make sense of URL for connection
>>    at
>> org.apache.batik.transcoder.XMLAbstractTranscoder.transcode(XMLAbstractTranscoder.java:126)
>>    at
>> com.company.svggenerator.transform.EpsTransformer.transform(EpsTransformer.java:267)
>>        :
>>        :
>>
>> I use batik 1.6 and a current pdf-transcoder.jar from the batik 1.6 
>> zipfile.
>> I also have fop 0.20.5 in the classpath.
>>
>>
>> Any ideas?
>
>
>
> Jeremias Maerki
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org
>
> 



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


Re: Trying to transcode SVG to EPS

Posted by Jeremias Maerki <de...@jeremias-maerki.ch>.
Having Batik 1.6, pdf-transcoder.jar and FOP 0.20.5 together in the same
classpath begs for trouble. On the other side, I would have expected a
different error message if there was really something going wrong with
these very incompatible packages.

Do other transcoders work? Run the whole thing again without FOP in the
classpath. Consider upgrading to the latest FOP release. If nothing
helps, please post the full stack trace.

On a side-note: Finally someone who uses the EPSTranscoder. *g*

On 02.02.2006 19:30:00 Martin Morawetz wrote:
> Hello,
> 
> Trying to transcode an SVG to an EPS file using
> following code:
> 
> public boolean transform(CharArrayWriter charArrayWriter , Writer writer)
> 	{
> 	EPSTranscoder trans = new EPSTranscoder();
> 	TranscoderInput input = new
> 		TranscoderInput(charArrayWriter.toString());
> 	TranscoderOutput output = new TranscoderOutput(writer);
> 		try
> 		{
> 		trans.transcode(input, output);
> 		writer.flush();
> 		}
> 	catch(TranscoderException e)
> 		{
> 		return false;
> 		}
> 	catch(IOException e)
> 		{
> 		return false;
> 		}
> 
> 	return true;
> 	}
> 
> produces following exception:
> 
> [class org.apache.batik.transcoder.TranscoderException]: null
> Enclosed Exception:
> Unable to make sense of URL for connection
>    at 
> org.apache.batik.transcoder.XMLAbstractTranscoder.transcode(XMLAbstractTranscoder.java:126)
>    at 
> com.company.svggenerator.transform.EpsTransformer.transform(EpsTransformer.java:267)
>        :
>        :
> 
> I use batik 1.6 and a current pdf-transcoder.jar from the batik 1.6 zipfile.
> I also have fop 0.20.5 in the classpath.
> 
> 
> Any ideas?



Jeremias Maerki


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