Technologies XML / XSL-FO / Référence / Extensions XSL d’Antenna House Formatter / Propriétés / text-emphasis-style

(Extrait de « XSL-FO ― Die Referenz » de 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

Catégorie Décoration des caractères et du texte >> Signes d’emphase

Définit le style des signes d’emphase. [CSS3-TextDecor] Style des signes d’emphase : la propriété ‘text-emphasis-style’

Valeur :

none | [ [ filled | open ] || [ dot | circle | double-circle | triangle | sesame ] ] | <string>

Valeur initiale :

none

S’applique à :

tous les éléments

Hérité :

yes

Pourcentages :

N/A

Les valeurs ont les significations suivantes.

none

Aucun signe d’emphase.

filled

Définit un caractère avec color-fill.

open

Définit un caractère avec un contour sans color-fill.

dot

Définit un point plein. filled dot correspond à U+2022 •, open dot correspond à U+25E6 ◦.

circle

Définit un cercle. filled circle correspond à U+25CF ●, open circle correspond à U+25CB ○.

double-circle

Définit un double cercle. filled double-circle correspond à U+25C9 ◉, open double-circle correspond à U+25CE ◎.

triangle

Définit un triangle. filled triangle correspond à U+25B2 ▲, open triangle correspond à U+25B3 △.

sesame

Définit un point en forme de graine de sésame. filled sesame correspond à U+FE45 ﹅, open sesame correspond à U+FE46 ﹆.

<string>

Définit une chaîne de caractères quelconque. Si plusieurs caractères sont spécifiés, ils sont tous affichés, mais leur chevauchement n’est pas pris en compte.

Lorsque filled ou open n’est pas spécifié, la valeur est traitée comme filled. Lorsque filled ou open est spécifié, la valeur est traitée comme circle en écriture verticale.

Exemple XSL-FO :

<fo:root xml:lang="en" 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">
<axf:document-info name="document-title" value="Example of ruby and emphasis marks"/>
<axf:document-info name="author" value="Antenna House, Inc."/>
<fo:layout-master-set>
<fo:simple-page-master page-height="297mm" page-width="210mm" margin-top="10mm" margin-left="20mm" margin-right="20mm" margin-bottom="10mm" master-name="PageMaster1">
<fo:region-after extent="7mm"/>
<fo:region-body margin-top="0mm" margin-left="0mm" margin-right="0mm" margin-bottom="10mm"/>
</fo:simple-page-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="PageMaster1">
<fo:static-content flow-name="xsl-region-after">
<fo:block font-size="0.8em" text-align="right" color="green">
<fo:basic-link external-destination="http://www.antennahouse.com/">
Antenna House, Inc.
</fo:basic-link>
</fo:block>
</fo:static-content>
<fo:flow flow-name="xsl-region-body" font-family="serif" font-size="1em" line-height="1.4" axf:hyphenate-hyphenated-word="false" hyphenate="true">
<fo:block span="all" font-family="sans-serif" font-size="2em" font-weight="bold" line-height="2" space-before="1em" space-after="1em" space-before.conditionality="retain" space-after.conditionality="retain" background-color="#EEEEEE">
<fo:block start-indent="1em" end-indent="1em">
Example of ruby and emphasis marks 
</fo:block>
</fo:block>
<fo:block span="all" space-before="1em" space-after="1em" space-after.conditionality="retain" text-indent="0em" border="1pt solid #9999FF" start-indent="0.5em" end-indent="0.5em" padding="0.5em" text-align="justify">
It's possible to add emphasis marks to text using axf:text-emphasis-style. The space from the base character, font and size of the emphasis marks can be specified. Emphasis marks can be applied only to the script of Latn, Cyrl, Grek and Zyyy besides CJK. Emphasis marks can be put on the base characters of ruby, but they cannot be put on ruby characters.
</fo:block>
<fo:block space-before="1em" font-family="sans-serif" font-size="1.2em" font-weight="bold" text-indent="0em" line-height="2" keep-with-next.within-column="always">
Emphasis marks
</fo:block>
<fo:block font-size="2.5em" space-before="0.5em" axf:text-emphasis-style="circle" axf:text-emphasis-font-size="0.5">
<fo:block>
ルビと圏点
</fo:block>
</fo:block>
<fo:block space-before="1em" font-family="sans-serif" font-size="1.2em" font-weight="bold" text-indent="0em" line-height="2" keep-with-next.within-column="always">
Using ruby and emphasis marks together
</fo:block>
<fo:block>
Ruby and emphasis marks can be used together. When the ruby and emphasis marks are put on the same side, emphasis marks will be put outside of ruby.
</fo:block>
<fo:block font-size="2.5em" space-before="1em" axf:text-emphasis-style="circle" axf:text-emphasis-font-size="0.5">
<fo:block>
ルビと
<axf:ruby>
<axf:ruby-base>
圏点
</axf:ruby-base>
<axf:ruby-text>
けんてん
</axf:ruby-text>
</axf:ruby>
</fo:block>
</fo:block>
<fo:block space-before="1em" font-family="sans-serif" font-size="1.2em" font-weight="bold" text-indent="0em" line-height="2" keep-with-next.within-column="always">
Using ruby and emphasis marks together (Align emphasis marks)
</fo:block>
<fo:block>
Emphasis marks can be aligned by the setting of axf:text-emphasis-offset.
</fo:block>
<fo:block font-size="2.5em" space-before="1em" axf:text-emphasis-style="circle" axf:text-emphasis-font-size="0.5" axf:text-emphasis-offset="0.5em">
<fo:block>
ルビと
<axf:ruby>
<axf:ruby-base>
圏点
</axf:ruby-base>
<axf:ruby-text>
けんてん
</axf:ruby-text>
</axf:ruby>
</fo:block>
</fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>

Télécharger les exemples

Résultat :

haut de page