axf:overflow-condense

(Auszug aus "XSL-FO ― Die Referenz" von 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

Category Overflow Extensions

The axf:overflow-condense specifies how to condense the overflowed text within the region.

Value:letter-spacing | font-stretch | font-size | line-height | auto | none
Initial:auto
Applies to:all block-level formatting objects
Inherited:yes
Percentages:N/A

Values have the following meanings.

letter-spacingCondenses the text by adjusting the letter spacing.
font-stretchCondenses the text by adjusting the font width.
font-sizeCondenses the text by adjusting the font size.
line-heightCondenses the text by adjusting the line height.
autoDependent on the system setting.
none Specifies not to condense the text. This can also be specified to the in-line element and is not inherited.

Condensing the text within the region can be specified with the properties of overflow="condense". The adjustment for condensing the text includes both the inline progression direction and the block progression direction. The system will process the specified method by combining the methods considered as suitable.

There is a difference in the condensation process between inline and block. The condensation process occurs in the inline when there is only one line with <fo:inline-container> or <fo:block-container keep-together.within-line="always"> etc. In other cases, the condensation process occurs in the block.

The length of the absolute value specified inside the block will not be adjusted. For example, in the following case, the length will not be adjusted.

<fo:block-container width="4in" overflow="condense" axf:overflow-condense="font-size"> this text will be condenced <fo:block font-size="24pt">no condenced text</fo:block> </fo:block-container>

Moreover, when the adjustment by font-size or font-stretch in the block takes place, text-align-last="justify" is set implicitly. Please specify text-align-last="left" etc., explicitly when justify is unnecessary.

XSL-FO sample:

<fo:root font-family="Arial Unicode MS" font-size="12pt" 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">

The

overflow

property is used determine the behavior of Formatter when the contents of an area format to a size greater than the area's defined boundaries. Antenna House has extended the value of this property to the following values.

overflow="replace" allows for replacement of overflowing contents, similar to how spreadsheets replace number too large to display in cells with "*****". The string to replace the overflow with is defined as the value of the extension element axf:overflow-replace.

overflow="condense" allows the text to be condensed according to the value of the axf:overflow-condense extension property.

These extended values only apply to block-container and inline-container elements.

overflow="none" (default)

rubber baby buggy bumpers

overflow="replace" axf:overflow-replace="#"

rubber baby buggy bumpers

overflow="condense" axf:overflow-condense="font-size"

rubber baby buggy bumpers

Download der Beispiele

Output:

Tipp der data2type-Redaktion:
Zum Thema XSL-FO bieten wir auch folgende Schulungen zur Vertiefung und professionellen Fortbildung an: