Christer Sandberg wrote:
This is our SVG width and height:

<svg  width="252.836" height="52.828" ...
Up to this point, I have no experience with SVG, but I was surprised to see that there is no unit of measurement (cm, mm, pt, px) in the height & width.

When I added some println() statements to PDFRenderer, both in 0.20.1 and 0.20.4, this i what I got.

0.20.1: w = 252836, h = 52828
0.20.4: w = 252000, h = 52000
Interesting. It rounds "down" instead of up.

The difference between those two, to me, seems to be the way you fetch the SVG size. In 0.20.4 via the BridgeContext and in 0.20.4 via SVGSVGElement.

After snooping around a little bit in the Batik sources I found a line with a // FIXME or something like that (I'm at home now and dosen't have the Batik sources here, but I think it was in BridgeContext or one of the instances it uses), where the float values are casted to an int loosing the decimals. Changing the width of the SVG seem to help but this would possible break some of the layout in our reports which are made for the election of the Swedish government. I will try to see if there's an error in the size of our generated SVG files. We use Illustrator to convert from EPS, and then we're tweaking them a bit.

Good luck!

Web Developer - Medata, Inc. -
PGP Public Key:

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

Reply via email to