Technologies XML / XSL-FO / Référence / Attributs de XSL-FO / number-columns-repeated

(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

Section de la recommandation : 7.28.12

Catégorie : 7.28 Propriétés des tableaux

Description

Sur un élément <fo-table-column>, cet attribut définit le nombre de colonnes auxquelles un réglage s’applique. Normalement, un élément <fo-table-column> concerne une seule colonne, son ordre déterminant la colonne à formater. Pour appliquer le même format à plusieurs colonnes voisines, il suffit d’un élément <fo-table-column> avec number-columns-repeated égal au nombre de colonnes concernées.

Valeurs

Valeur numérique

Un nombre positif, éventuellement décimal, ou un entier négatif. En théorie, la recommandation du W3C autorise les valeurs décimales, qui seraient automatiquement arrondies à l’entier positif le plus proche. Même les entiers négatifs sont autorisés ; leur valeur serait automatiquement ramenée à 1 (une colonne).

Valeur par défaut : 1

Version XSL-FO : 1.0

Autorisé dans :

<fo:table-column>

Cet élément permet de définir les propriétés des cellules d’une même colonne.

Prise en charge :

Niveau de conformité

Antenna House

FOP

RenderX XEP

Altsoft XML2PDF

Compart DocBridge

De base

O

O

O

O

O

Exemple XSL-FO :

<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="5mm 5mm 5mm
                      5mm"/>
</fo:simple-page-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="Inhalt-Seiten">
<fo:flow flow-name="xsl-region-body">
<fo:table>
<fo:table-column column-width="20%" number-columns-repeated="2" background-color="#F38222"/>
<fo:table-column column-width="30%" number-columns-repeated="2" background-color="#4F491D"/>
<fo:table-body>
<fo:table-row>
<fo:table-cell text-align="center" border="black solid
                      1pt">
<fo:block>
Zeile 1
</fo:block>
<fo:block>
Spalte 1
</fo:block>
<fo:block>
Format 1: 20%
                breit, Orangener Hintergrund
</fo:block>
</fo:table-cell>
<fo:table-cell text-align="center" border="black solid
                      1pt">
<fo:block>
Zeile 1
</fo:block>
<fo:block>
Spalte 2
</fo:block>
<fo:block>
Format 1: 20% breit, Orangener Hintergrund
</fo:block>
</fo:table-cell>
<fo:table-cell text-align="center" border="black solid
                      1pt">
<fo:block>
Zeile 1
</fo:block>
<fo:block>
Spalte 3
</fo:block>
<fo:block>
Format 2: 30%
                breit, Grüner Hintergrund
</fo:block>
</fo:table-cell>
<fo:table-cell text-align="center" border="black solid
                      1pt">
<fo:block>
Zeile 1
</fo:block>
<fo:block>
Spalte 4
</fo:block>
<fo:block>
Format 2: 30% breit, Grüner Hintergrund
</fo:block>
</fo:table-cell>
</fo:table-row>
<fo:table-row>
<fo:table-cell text-align="center" border="black solid
                      1pt">
<fo:block>
Zeile 2
</fo:block>
<fo:block>
Spalte 1
</fo:block>
<fo:block>
Format 1: 20%
                breit, Orangener Hintergrund
</fo:block>
</fo:table-cell>
<fo:table-cell text-align="center" border="black solid
                      1pt">
<fo:block>
Zeile 2
</fo:block>
<fo:block>
Spalte 2
</fo:block>
<fo:block>
Format 1: 20% breit, Orangener Hintergrund
</fo:block>
</fo:table-cell>
<fo:table-cell text-align="center" border="black solid
                      1pt">
<fo:block>
Zeile 2
</fo:block>
<fo:block>
Spalte 3
</fo:block>
<fo:block>
Format 2: 30%
                breit, Grüner Hintergrund
</fo:block>
</fo:table-cell>
<fo:table-cell text-align="center" border="black solid
                      1pt">
<fo:block>
Zeile 2
</fo:block>
<fo:block>
Spalte 4
</fo:block>
<fo:block>
Format 2: 30% breit, Grüner Hintergrund
</fo:block>
</fo:table-cell>
</fo:table-row>
</fo:table-body>
</fo:table>
</fo:flow>
</fo:page-sequence>
</fo:root>

Télécharger les exemples

Dans la sortie :

Extrait de la recommandation du W3C :

Informations complémentaires en ligne sur

Présentation de la propriété dans la référence XSL-FO

haut de page