Here was the question:
1 |
How can we define an exact image size? |
1 |
The image height and width values change the apperance of the image but not in a way I'd expect. When I call the logo.gif image up in Photoshop it tells me it 221 pixels wide by 96 pixels tall or 3.069 inches by 1.333 inches. Both of these lines produce the same results but the image looks slightly skewed. I changed the image to be exactly 3" by 1" or 216px by 72px |
1 |
This creates an image that is about 2 7/8" by 15/16" |
1 |
fo:external-graphic src="file:images/logo.gif" width="3in" height="1in" |
1 |
this line creates the same thing... |
1 |
fo:external-graphic src="file:images/logo.gif" width="216px" height="72px" |
1 2 |
Is there something I need to set to zero, like cellspacing=0 or cellpadding=0 ? |
And here was the answer:
This problem come down to image resolutiosn. Here’s an FO faq entry that talks about image resolution. I think this is where your problem is coming from:
http://xml.apache.org/fop/graphics.html#resolution
Here’s a link to the fo:external-graphic description in the spec:
http://www.w3.org/TR/xsl/slice6.html#fo_external-graphic
To attributes that look relevant are “scaling” and “scaling-method”.