scaling of graphics
- Hi there I've got a question concerning auto scaling of graphics.
We have an automated publishing traject where we make use of a lot of
graphics. These graphics need to be scaled if their dimensions are bigger
than the page.
Problem is, that I do not know these dimensions, they can differ for each
Is there some way of testing the dimensions of the graphics in XSL fo or
should I have another script that reads in all these dimensions for me?
Mind, that the dimensions are not specified in the XML, but can only come
from the graphic itself.
- ronald heller wrote:
> Is there some way of testing the dimensions of the graphics in XSL fo orYou'll probably have to do the latter. I don't think there are any
> should I have another script that reads in all these dimensions for me?
functions, properties, etc. which return an image's dimensions.
If you had the dimensions coded in a quick-and-dirty well-formed XML
document, you could use this as input to the transformation. Something like:
Then you can use the XSLT document() function to get dimensions for a
particular image, compare to the page size, and clip or scale accordingly.
Interesting problem. I'd be interested in knowing if anyone else on the
list has any brainstorms.
John E. Simpson | "I can levitate birds. No one cares."
http://www.flixml.org | (Steven Wright)
XML Q&A: www.xml.com |