XML technologies / XSL-FO / Reference / Attributes in XSL-FO / character

(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.17.1

Category: 7.17 Character Properties

Description

In <fo:character>, this specifies a Unicode character to receive special formatting. This enables microtypographic adjustments such as creating ligatures. Another use is borrowing and inserting characters from other fonts when they are absent from the current font.

Values

character

a character according to the Unicode standard

XSL-FO version: 1.0

Allowed in:

<fo:character>

This element provides separate rendering of individual characters.

Support:

Conformance level

Antenna House

FOP

RenderX XEP

Altsoft XML2PDF

Compart DocBridge

Basic

Y

Y

Y

Y

Y

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="297mm" page-width="210mm">
<fo:region-body margin="26mm 55mm 41mm
                        55mm"/>
<fo:region-before extent="5mm"/>
<fo:region-after extent="30mm"/>
</fo:simple-page-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="Inhalt-Seiten" force-page-count="no-force">
<fo:static-content flow-name="xsl-region-after">
<fo:block text-align="center" margin="5mm
                    10mm">
<fo:page-number/>
</fo:block>
</fo:static-content>
<fo:flow flow-name="xsl-region-body">
<fo:block-container background-color="#F38222" absolute-position="fixed" top="48mm" right="20mm" width="80mm" height="12mm">
<fo:block text-align="center" vertical-align="middle" padding-top="2mm">
fo:character
                character="T" letter-spacing="-0.25em"
</fo:block>
</fo:block-container>
<fo:block-container background-color="#F38222" absolute-position="fixed" top="100mm" right="20mm" width="80mm" height="8mm">
<fo:block text-align="center" vertical-align="middle" padding-top="2mm">
normale Schriftausprägung
</fo:block>
</fo:block-container>
<fo:block space-after="20mm" font-size="25pt" line-height="1.2em">
Als Gregor Samsa eines Morgens aus unruhigen 
<fo:inline font-weight="bold">
<fo:character character="T" letter-spacing="-0.25em"/>
r
</fo:inline>
äumen...
</fo:block>
<fo:block font-size="25pt" line-height="1.2em">
Als Gregor Samsa eines Morgens aus unruhigen 
<fo:inline font-weight="bold">
Tr
</fo:inline>
äumen...
</fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>

Download the examples

In the output:

Excerpt from the W3C Recommendation:

More information online about

Rendering of the property in the XSL-FO reference

back to top