[xsl] external-graphic attributes question

Subject: [xsl] external-graphic attributes question
From: "Trevor Nicholls" <trevor@xxxxxxxxxxxxxxxxxx>
Date: Wed, 13 Jul 2011 01:40:44 +1200
I am looking at a piece of XSL-FO which defines a block graphic for a PDF
document and which is probably overspecified.

The generated fo contains the following:

<fo:block text-align="center" display-align="center">
  <fo:external-graphic vertical-align="middle" src="url({$src})"
height="{$h}" width="{$w}" content-height="scale-to-fit"
content-width="scale-to-fit" />
</fo:block>

When I look at the derivations of $h and $w it appears that they will always
be either the actual dimensions of the graphic file, or values (scaled up or
down) which preserve the original aspect ratio. Is there any point in
supplying both height and width together with content height and content
width?

Thanks
Trevor

Current Thread