[...]
>     So I'm fairly sure that the problem is that
> Batik doesn't know the URL base to use to resolve
> xlink:href's in 'doc'.  There are two ways to solve
> this.
> First you can use the xml:base attribute to provide
> a
> base URL for resolution.  Second you can use
> TranscoderInput.setURI
> to provide a uri to go with your doc.
[...]
>     This looks like a bug from 1.5.1 where it would
> get an NPE
> when looking up the line number so it could generate
> a useful
> error message.  What version of Batik are you using?


I was using 1.5. I switched to 1.6 and there is no
more a NPE. 

I have other problems though:

1- If I trancode the same document, I get an output
file with a broken href/image picture not the real
image. The display of the file used to build the
document is fine in a browser (Firefox).

2- If I add xml:base="http://xml.apache.org"; to the
svg  root element the transcoder generates an empty
file. The svg source file displays correctly in
Firefox.

3- If I add xml:base="http://xml.apache.org"; to the
svg  image element I get the same results as in 1.

4- If I do transcoder.setURI("/http://xml.apache.org";)
same as 1 and 3;

For the base uri I set in the svg source or with
setURI(), I have tried also "/http://xml.apache.org/";
 or "/http://xml.apache.org/my-doc"; but with the same
results.

Some remarks:

1- I have noticed that if the initial heap size is too
low, I can get "broken images" with the transcoder and
the rasteriser. Here I have used a heap size that is
usually fine with this type of documents. I have also
used the rasterizer with the same heap size and the
result is always fine.

 I would prefer an Exception to be thrown rather than
a "broken image" pic when the transcoder cannot render
a document (whether because the link is broken or
because of memory problems).
Is it possible?

2- The rastizer seems to works always fine whether I
use absolute url link, xml:base + relative url link or
xml:base + absolute url link.

I badly need to solve this problem so your help is
really appreciated.




                
____________________________________________________ 
Yahoo! Sports 
Rekindle the Rivalries. Sign up for Fantasy Football 
http://football.fantasysports.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to