XML technologies / XSL-FO / Reference / Attributes in XSL-FO / allowed-height-scale
(Excerpt from "XSL-FO ― Die Referenz" by Manuel Montero Pineda & Steffen Herkert, 2016, dpunkt.verlag)
A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z
Recommendation section: 7.15.1
Category: 7.15 Area Dimension Properties
Description
This attribute specifies a list of permitted scaling factors for the height of an included graphic (<fo:external-graphic>). If the formatter determines the scaling factor automatically, this provides the possible percentage values.
Values
any | This value imposes no restrictions. |
Percentage | A list of percentage values can be specified, separated by spaces. The list need not be sorted because the formatter uses the nearest possible value. |
Inherited: | yes |
Default value: any
XSL-FO version: 1.1
Allowed in:
This element inserts external graphics into the document. Attributes provide numerous configuration options. | |
This element allows inline graphics or other inline objects to be inserted into the document. |
Support:
Conformance level | Antenna House | FOP | RenderX XEP | Altsoft XML2PDF | Compart DocBridge |
Extended | Y | N | - | N | N |
XSL-FO example:
<fo:root font-family="Arial" font-size="10pt" line-height="1.2em" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:cpfo="http://www.compart.net/xmlns/cpfo" xmlns:svg="http://www.w3.org/2000/svg" xmlns:axf="http://www.antennahouse.com/names/XSL/Extensions">
<fo:layout-master-set>
<fo:simple-page-master master-name="Inhalt-Seiten" margin="0mm 0mm 0mm
0mm" page-height="150mm" page-width="148mm">
<fo:region-body margin="10mm 15mm 10mm
25mm"/>
</fo:simple-page-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="Inhalt-Seiten" font-size="10pt">
<fo:flow flow-name="xsl-region-body">
<fo:block height="30mm">
<fo:external-graphic id="AllowedHeightScale" src="../Abbildungen/fo_ref_square_50mm.jpg" content-height="scale-to-fit" allowed-height-scale="150% 101% 100% 30% 10%
3%" padding="10mm"/>
</fo:block>
<fo:block>
Höhe:
<fo:scaling-value-citation ref-id="AllowedHeightScale" scale-option="height"/>
%
</fo:block>
<fo:block>
Breite:
<fo:scaling-value-citation ref-id="AllowedHeightScale" scale-option="width"/>
%
</fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>In the output:
Excerpt from the W3C Recommendation: