posts - 431,  comments - 344,  trackbacks - 0
在学习XSL-FO之前,你应该已经掌握了XMLXML命名空间的基本知识。

1.什么是XSL-FO

XSL-FO 是用于将结果格式化成XML数据的语言,XSL-FO全称为(Extensible Stylesheet Language Formatting Objects:扩展格式化对象样式表语言),XSL-FO W3C的推荐标准,XSL-FO 现在通常被称为XSL

XSL-FO 是用于格式化数据的

XSL是一种基于XML的标记语言,它对输出到屏幕、纸张或其它媒体上的XML数据的格式化作了具体的描述。

XSL-FO现在通常叫做XSL

样式化包括信息的转换格式化。当万维网联盟(W3C)做出第一份XSL工作草案时,它包括了XML文档的转换和格式化的语法。后来,W3CXSL工作组把原草案分成了以下几块参考标准:

l         XSLT,用于转换XML文档的语言

l         XSL XSL-FO,用于格式化XML文档的语言

l         XPath,用于将XML文档中的元素和属性进行定位的语言

该教程剩下的部分是关于格式化XML文档的语言的:XSL-FO,也称为XSL

XSL-FO是一个网络标准

20011015XSL-FO已经成为了W3C的推荐标准。它通常被称为XSL

2XSL-FO文档

XSL-FO文档是包含输出信息的XML文件。它们包含了与输出的布局和输出的内容相关的信息。XSL-FO文档以扩展名“a .fo” “a .fob” 的文件保存在文件里。XSL-FO文档也通常以“an .xml” 扩展名来保存。因为这样做可以使它们能更容易被XML编辑器访问。

XSL-FO文档结构

<?xml version="1.0" encoding="UTF-8"?>

<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
<fo:layout-master-set>
 <fo:simple-page-master master-name="A4">
    <!-- Page template goes here -->
 </fo:simple-page-master>
</fo:layout-master-set>

<fo:page-sequence master-reference="A4">
 <!-- Page content goes here -->
</fo:page-sequence>

</fo:root>

结构说明

XSL-FO 文档是XML文档,所以必须在文档的起始处包含一份XML声明:

        <?xml version="1.0" encoding="UTF-8"?>

<fo:root> 元素是XSL-FO文档的根元素。根元素也给XSL-FO声明了命名空间:

<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
       <!-- The full XSL-FO document goes here -->
</fo:root>

<fo:layout-master-set> 元素包含了一个或多个页面模板:

<fo:layout-master-set>
       <!-- All page templates go here -->
</fo:layout-master-set>

每个<fo:simple-page-master>元素包含着一个单独的页面模板。每个模板都包含一个独立的名称:

<fo:simple-page-master master-name="A4">
       <!-- One page template goes here -->
</fo:simple-page-master>

一个或多个<fo:page-sequence>元素描述了页面内容。Master-reference 属性指的是同名的“simple-page-master” 模板。

<fo:page-sequence master-reference="A4">
       <!-- Page content goes here -->
</fo:page-sequence>

注意:事实上,master-reference = "A4" 并未真正地描述预定义页面格式。它只是一个名称而已。你可以随意命名,如:"MyPage""MyTemplate" 等等这样的名称。

3XSL-FO 区域

XSL格式化模型定义了大量的矩形域(块状区)来显示结果。所有的结果(文本、图片,等等)都会被格式化以后放入这些区域里,并且,它将会在目标媒体上显示或打印出来。让我们进一步看看下面的区域:

l         Pages  页面

l         Regions  区域

l         Block areas  块状区域

l         Line areas  行区域

l         Inline areas  行内区域

XSL-FO 页面

XSL-FO 结果被格式化成页面形式。打印出来的结果通常会被写进很多独立的页面。浏览器的输出的结果通常会显示长长的一页。XSL-FO页面包含区域。

XSL-FO 区域

每张XSL-FO页面都包含大量的区域。

l         region-body   区域 主体(页面的主体)

l         region-before   区域头部(页面页首)

l         region-after  区域尾部(页面的页脚)

l         region-start  区域左端(左工具条)

l         region-end  区域右端(右工具条)

XSL-FO 区域包含块状区域。

XSL-FO 块状区域

XSL-FO 块状区域定义了小块状元素(通常是以新的一行作为起始的元素),例如图表、表格和列表。XSL-FO 块状区域可以包含其它的块状区域,但是大多数情况下,它们通常包含行区域。

XSL-FO 行区域

XSL-FO 行区域定义了块状区域内部的文本行。XSL-FO 行区域包含行内区域。

XSL-FO Inline 行内区域

XSL-FO 行内区域定义了行内的文本内容(段首粗体圆点、单字符、图形,等等)。

4XSL-FO 输出

XSL-FO <fo:flow> 元素中定义输出结果。

XSL-FO 页面、流程和区域

“块状区域”的内容首先进入“页面”,然后再由指定的媒体输出。XSL-FO 的输出结果通常被嵌套在<fo:block>元素、<fo:flow>元素、以及<fo:page-sequence>元素中,具体如下:

<fo:page-sequence>
 <fo:flow flow-name="xsl-region-body">
    <fo:block>
      <!-- Output goes here -->
    </fo:block>
 </fo:flow>
</fo:page-sequence>

XSL-FO 案例

下面列举一个关于XSL-FO的实际案例:

<?xml version="1.0" encoding="UTF-8"?>

<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
<fo:layout-master-set>
 <fo:simple-page-master master-name="A4">
 </fo:simple-page-master>
</fo:layout-master-set>

<fo:page-sequence master-reference="A4">
 <fo:flow flow-name="xsl-region-body">
    <fo:block>Hello w3pop.com</fo:block>
 </fo:flow>
</fo:page-sequence>

</fo:root>

上述代码应该输出下述结果:

Hello w3pop.com

5XSL-FO 流程

XSL-FO 将被来自<fo:flow>元素中的数据所填充。XSL-FO 使用<fo:page-sequence>元素来定义结果页面。每个结果页面都包含了定义页面布局的页面主体元素。每个结果页面都包含一个定义输出结果<fo:flow>元素。每个结果页面都会按照一定顺序打印(或显示)。

XSL-FO 流程

XSL-FO 将被来自<fo:flow>元素中的内容所填充。<fo:flow> 元素包含了需要在页面上打印的所有元素。当页面被印满时,相同的页面主体元素会被反复地使用,直到所有的文本内容都被打印出来为止。

流程流向哪里?

<fo:flow> 元素包含“flow-name(流程名称)属性。“flow-name(流程名称)的属性值定义了<fo:flow>元素的内容将流向何处。所有合法值如下:

l         xsl-region-body :流向区域主体

l         xsl-region-before :流向区域最上端

l         xsl-region-after :流向区域最下端

l         xsl-region-start :流向区域左端

l         xsl-region-end :流向区域右端

6XSL-FO 页面

XSL-FO 使用名为 “Page Masters [ 页面主体 ] ” 的页面模板来定义页面的布局。

XSL-FO 页面模板
XSL-FO 使用名为“Page Masters [ 页面主体 ] ” 的页面模板来定义页面的布局。每块模板必须包含一个独立的名称:

<fo:simple-page-master master-name="intro">
 <fo:region-body margin="5in" />
</fo:simple-page-master>

<fo:simple-page-master master-name="left">
 <fo:region-body margin-left="2in" margin-right="3in" />
</fo:simple-page-master>

<fo:simple-page-master master-name="right">
 <fo:region-body margin-left="3in" margin-right="2in" />
</fo:simple-page-master>

在上述案例中,三个<fo:simple-page-master>元素,定义了三块不同的模板。每块模板都包含不同的名称。第一块模板称为“intro”,它是用于介绍页面的模板。第二和第三块模板称作"left" "right"。它们是用于定义奇数页面和偶数页面。

XSL-FO 页面大小

XSL-FO 使用下述属性来定义页面的尺寸:

a)         page-width 定义了页面的宽度

b)        page-height 定义了页面的高度

XSL-FO 页面边界

XSL-FO 用下述属性来定义页面边界:

a)         margin-top 定义顶边界

b)        margin-bottom 定义底边界

c)        margin-left 定义左边界

d)        margin-right 定义右边界

e)         margin 定义所有四个边界

XSL-FO 页面区域

XSL-FO 使用以下元素来定义页面的区域:

a)         region-body 定义主体区域

b)        region-before 定义顶端区域(页眉)

c)        region-after 定义底端区域(页脚)

d)        region-start 定义左端区域(左端工具条)

e)         region-end 定义右端区域(右端工具条)

前端区域(region-before),后端区域(region-after),起始区域(region-start),终止区域(region-end)是主体区域的一部分。为了避免文本在主体区域内溢出,主体区域的边界尺寸至少要和上述这些区域一样。

Margin Top

M
a
r
g
i
n

L
e
f
t

REGION BEFORE

R
E
G
I
O
N

S
T
A
R
T

 

 

 

 

 

REGION BODY

 

 

 

 

 

 

R
E
G
I
O
N

E
N
D

REGION AFTER

M
a
r
g
i
n

R
i
g
h
t

Margin Bottom

XSL-FO例子

下面列举了一份XSL-FO文档的部分内容:

<fo:simple-page-master master-name="A4"
 page-width="297mm" page-height="210mm"
 margin-top="1cm"   margin-bottom="1cm"
 margin-left="1cm" margin-right="1cm">
 <fo:region-body   margin="3cm"/>
 <fo:region-before extent="2cm"/>
 <fo:region-after extent="2cm"/>
 <fo:region-start extent="2cm"/>
 <fo:region-end    extent="2cm"/>
</fo:simple-page-master>

上述代码定义了名称为"A4"“Simple Page Master”模板。这张页面宽297毫米,高210毫米。页面的上下左右边界都是1厘米。主体部分的四条边上包含了宽为3厘米的边界。主体的上下左右部分都是2厘米。在上述案例中,主体宽度 = 页面自身宽度 - 左右边界宽度 - 区域主体边界宽度,具体如下:

       297mm - (2 x 1cm) - (2 x 3cm) = 297mm - 20mm - 60mm = 217mm.

注意:区域(左端区域和右端区域)并不在计算范围之内。如同前面所说的那样,这些区域只是主体的一部分。

7XSL-FO 块状区域

XSL-FO 结果将输入块状区域。

XSL-FO 页面、流程 以及 块状区域

“块状区域”的内容首先进入“页面”,然后再由指定的媒体输出。XSL-FO 的输出结果通常被嵌套在<fo:block>元素、<fo:flow>元素、以及<fo:page-sequence>元素中,具体如下:

<fo:page-sequence>
 <fo:flow flow-name="xsl-region-body">
    <fo:block>
      <!-- Output goes here -->
    </fo:block>
 </fo:flow>
</fo:page-sequence>

Block 区域属性
块状区域包含矩形框内的结果序列:

<fo:block
 border-width="1mm">
This block of output will have a one millimeter border around it.
</fo:block>

因为块状区域的是矩形框,它们共享很多共同的区域性质:

l         space before and space after 最上端边界和最下端边界

l         margin 边界

l         border 边框

l         padding 补白

Space before [顶端空间]space after [底端空间]是用来分隔其它块状区域的空白空间。margin [边界]是块状区域外部的空白区域。border [边框]是矩形框的四条边;它们可以有不同的宽度;它们也可以填充不同的颜色和背景图片,padding [补白]是位于边框和内容区域之间的地方。content [内容]区域包含了类似于文本、图片、图表等实际存在的内容。

块状区域边界

l         margin四边边界

l         margin-top顶部边界

l         margin-bottom底部边界

l         margin-left左边界

l         margin-right右边界

块状区域边框

边框样式属性:

l         border-style边框样式

l         border-before-style顶端边框样式

l         border-after-style底端边框样式

l         border-start-style左端边框样式

l         border-end-style右端边框样式

l         border-top-style (same as border-before) 顶端边框样式(和 border-before 相同)

l         border-bottom-style (same as border-after) 底端边框样式(边 border-after 相同)

l         border-left-style (same as border-start) 左端边框样式(和 border-start 相同)

l         border-right-style (same as border-end) 右端边框样式(和 border-end 相同)

边框颜色属性:

l         border-color边框颜色

l         border-before-color顶端边框颜色

l         border-after-color底端边框颜色

l         border-start-color左端边框颜色

l         border-end-color右端边框颜色

l         border-top-color (same as border-before) 顶端边框颜色(和 border-before 相同)

l         border-bottom-color (same as border-after) 底端边框颜色(和 border-after 相同)

l         border-left-color (same as border-start) 左端边框颜色(和 border-start 相同)

l         border-right-color (same as border-end) 右端边框颜色(和 border-end 相同)

边框宽度属性:

l         border-width边框宽度

l         border-before-width顶端边框宽度

l         border-after-width底端边框宽度

l         border-start-width左端边框宽度

l         border-end-width右端边框宽度

l         border-top-width (same as border-before) 顶端边框宽度(和 border-before 相同)

l         border-bottom-width (same as border-after) 底端边框宽度(和 border-after 相同)

l         border-left-width (same as border-start) 左端边框宽度(和 border-start 相同)

l         border-right-width (same as border-end) 右端边框宽度(和 border-end 相同)

块状区域补白:

l         padding补白

l         padding-before顶端补白

l         padding-after底端补白

l         padding-start左端补白

l         padding-end右端补白

l         padding-top (same as padding-before) 顶端补白(和 padding-before 相同)

l         padding-bottom (same as padding-after) 底端补白(和 padding-after 相同)

l         padding-left (same as padding-start) 左端补白(和 padding-start 相同)

l         padding-right (same as padding-end) 右端补白(和 padding-end 相同)

块状区域背景

l         background-color背景颜色

l         background-image背景图形

l         background-repeat背景重复

l         background-attachment (scroll or fixed) 背景滚动设置(scroll:随页面滚动而滚动;fixed:不随页面滚动而滚动)

块状区域样式属性
块状区域包含了可以单独定义样式的结果序列:

<fo:block
 font-size="12pt"
 font-family="sans-serif">
This block of output will be written in a 12pt sans-serif font.
</fo:block>

字体属性:

l         font-family字体

l         font-weight字体粗细

l         font-style字形

l         font-size字体尺寸

l         font-variant字体变量

文本属性:

l         text-align文本排列

l         text-align-last文本排列持续

l         text-indent文本缩进

l         start-indent顶端缩进

l         end-indent底端缩进

l         wrap-option (defines word wrap) 嵌套选项(定义自动换行)

l         break-before (defines page breaks) 页面左端换行(定义页面换行)

l         break-after (defines page breaks) 页面右端换行(定义页面换行)

l         reference-orientation (defines text rotation in 90" increments) 参考定位(定义90度内的文本旋转)

举例

<fo:block
    font-size="14pt" font-family="verdana" color="red"
    space-before="5mm" space-after="5mm">
W3Schools
</fo:block>

<fo:block
    text-indent="5mm"
    font-family="verdana" font-size="12pt"
    space-before="5mm" space-after="5mm">
At w3pop.com you will find all the Web-building tutorials you
need, from basic HTML and XHTML to advanced XML, XSL, Multimedia
and WAP.
</fo:block>

Result:
结果

W3Schools

   At w3pop.com you will find all the Web-building tutorials you need, from basic HTML and XHTML to advanced XML, XSL, Multimedia and WAP.

从上述案例中,你会发现,要创建一份包含多个标题和段落的文档需要使用大量的代码。一般情况下,XSL-FO文档不需要将格式化信息和内容结合起来。只需要使用XSLT的一小部分功能,我们就可以把格式化信息放入模板中,书写一份整洁的内容了。当你学完这份教程之后,你就会掌握更多关于把XSL-FOXSLT模板结合起来使用的方法。

8XSL-FO 列表

XSL-FO用列表块区定义列表

XSL-FO列表区

用于创建列表的XSL-FO对象有以下四个:

l         fo:list-block (含有整个列表)

l         fo:list-item (含有列表里的每一项)

l        fo:list-item-label (含有列表项的标签,典型的例子如:一个<fo:block>元素含有一个数字,字符,等等.)

l         fo:list-item-body (含有列表项的内容和主体,典型的例子如:一个或多个<fo:block>对象)

一份XSL-FO列表的例子:

<fo:list-block>

<fo:list-item>
 <fo:list-item-label>
   <fo:block>*</fo:block>
 </fo:list-item-label>
 <fo:list-item-body>
   <fo:block>Volvo</fo:block>
 </fo:list-item-body>
</fo:list-item>

<fo:list-item>

 <fo:list-item-label>
   <fo:block>*</fo:block>
 </fo:list-item-label>
 <fo:list-item-body>
   <fo:block>Saab</fo:block>
 </fo:list-item-body>
</fo:list-item>

</fo:list-block>

The output from this code would be:
这份代码应该输出如下结果:

 * Volvo
 * Saab

9XSL-FO 表格

XSL-FO 使用<fo:table-and-caption>元素定义表格。

XSL-FO 表格

XSL-FO 的表格模式和HTML表格模式相差不大。下面列举9个可以用于创建表格的XSL-FO对象:

l         fo:table-and-caption

l         fo:table

l         fo:table-caption

l         fo:table-column

l         fo:table-header

l         fo:table-footer

l         fo:table-body

l         fo:table-row

l         fo:table-cell

XSL-FO使用<fo:table-and-caption>元素来定义一张表格。它包含了一个<fo:table>元素和一个可选择的<fo:caption>元素。<fo:table>元素包含了几个可选择的<fo:table-column>元素,一个可选择的<fo:table-footer>元素。这些元素都包含一个或多个的<fo:table-row>元素以及一个或多个的<fo:table-cell>元素:

<fo:table-and-caption>
<fo:table>
<fo:table-column column-width="25mm"/>
<fo:table-column column-width="25mm"/>
<fo:table-header>
 <fo:table-row>
    <fo:table-cell>
      <fo:block font-weight="bold">Car</fo:block>
    </fo:table-cell>
    <fo:table-cell>
      <fo:block font-weight="bold">Price</fo:block>
    </fo:table-cell>
 </fo:table-row>
</fo:table-header>
<fo:table-body>
 <fo:table-row>
    <fo:table-cell>
      <fo:block>Volvo</fo:block>
    </fo:table-cell>
    <fo:table-cell>
      <fo:block>$50000</fo:block>
    </fo:table-cell>
 </fo:table-row>
 <fo:table-row>
    <fo:table-cell>
      <fo:block>SAAB</fo:block>
    </fo:table-cell>
    <fo:table-cell>
      <fo:block>$48000</fo:block>
    </fo:table-cell>
 </fo:table-row>
</fo:table-body>
</fo:table>
</fo:table-and-caption>

The output from this code would something like this:
上述代码将输出如下结果:

Car

Price

Volvo

$50000

SAAB

$48000

10XSL-FO XSLT

XSL-FO XSLT 可以进行功能互补。

还记得下面这个案例吗?

<fo:block
    font-size="14pt" font-family="verdana" color="red"
    space-before="5mm" space-after="5mm">
W3Schools
</fo:block>

<fo:block
    text-indent="5mm"
    font-family="verdana" font-size="12pt"
    space-before="5mm" space-after="5mm">
At w3pop.com you will find all the Web-building tutorials you
need, from basic HTML and XHTML to advanced XML, XSL, Multimedia
and WAP.
</fo:block>

Result:
结果

W3Schools

   At w3pop.com you will find all the Web-building tutorials you need, from basic HTML and XHTML to advanced XML, XSL, Multimedia and WAP.

XSLT中得到一些帮助
从文档中删除XSL-FO信息的方法:

<header>
W3Schools
</header>

<paragraph>
At W3pop.com you will find all the Web-building tutorials you
need, from basic HTML and XHTML to advanced XML, XSL, Multimedia
and WAP.
</paragraph>

Add an XSLT transformation:
添加一条 XSLT 转换信息的方法:

<xsl:template match="header">
<fo:block
    font-size="14pt" font-family="verdana" color="red"
    space-before="5mm" space-after="5mm">
    <xsl:apply-templates/>
</fo:block>
</xsl:template>
<xsl:template match="paragraph">
<fo:block
    text-indent="5mm"
    font-family="verdana" font-size="12pt"
    space-before="5mm" space-after="5mm">

    <xsl:apply-templates/>
</fo:block>
</xsl:template>

And the result will be the same:
结果仍然相同:

W3Schools

At W3pop.com you will find all the Web-building tutorials you need, from basic HTML and XHTML to advanced XML, XSL, Multimedia and WAP.

11XSL-FO 软件

XSL-FO 需要格式化软件来输出结果。

XSL-FO 处理器

XSL-FO 处理器是用于格式化XML文档输出结果的软件程序。大多数XSL-FO 处理器可以输出PDF文档,并进行高质量的打印。当然,它还可以HTML等其它形式输出。下面的部分介绍一些知名的XSL-FO处理器。

1)        XSL FormatterXSL Formatter 是一种用于格式化XML文档的软件,从而可以打印输出高质量的PDF文件。在2002年的一月,全球市场上推出了相同产品的V2版本。在欧洲举办的XML 2002, XML 2003 峰会上,XSL Formatter被公认为品质最佳的产品。在拥有4XSL-FO软件开发经验的基础之上,, Antenna House又从头开发全新的Formatter。这种Formatter将增加一些更显著实用的功能,并为将来的继续发展提供了坚实的基础。

2)        XincXinc Lunasil 公司推出的XSL-FO处理器。Xinc的特点是:运行速度快,多路处理,并有记忆效果。包含摆动装置的XSL-FO阅读器可以浏览和打印XSL-FO文件,只需要点击鼠标就可以操做PDF文件;通过XincJava APIJava应用程序接口),Xinc可以作为服务器组件使用;通过XincCOM(串行通讯端口)分界面,它也可在Microsoft服务器环境下使用。它的新特点如下:连字符号连接、基础连接、PDF输出、内存 / 速度最优化和简单的COM界面。

3)        ScripturaInventive Designers Scriptura 是基于XSLT XSL-FO 跨平台文档设计器和问题处理器。Scriptura 包含一个 WYSIWYG(即见及所得)的工具和引擎。在该引擎中使用的 XSL-FO formatter 已经不再以 Apache FOP 为基础了,而是设计者们重新开始书写。这个版本的新特点是:支持圆点、编号列表、“break-before [ 顶部换行 ]” “break-after [ 底部换行 ]” 特性;扩展的条形码选项、改进的数字、货币格式。免费的体验版本可以通过下载获取。

XSL格式化对象参考资料

将具体描述转化为表达式的过程称为格式化:

Object
对象

Description
描述

basic-link

Represents the start resource of a link
顶端资源链接

bidi-override

Overrides the default Unicode BIDI direction
忽略默认统一字符编码标准BIDI的用法

block

Defines a block of output (e.g. paragraphs and titles)
定义输出组件(比如:段落、标题)

block-container

Defines a block-level reference-area
定义一个block层次等级参考面

character

Specifies a character that will be mapped to a glyph for presentation
指定将被映射为字形表达式的字符

color-profile

Defines a color-profile for a stylesheet
定义样式表的轮廓颜色

conditional-page-master-reference

Specifies a page-master to be used when the conditions defined are true
当条件为true真时,允许使用page-master [ 页面主体 ]

declarations

Groups global declarations for a stylesheet
群组一个通用的样式

external-graphic

Used for a graphic where the graphics data resides outside of the XML result tree
用于图形数据位于XML结果树的外部的图形

float

Typically used to position an image in a separate area at the beginning of a page OR to position an image to one side, with the content flowing along-side of the image
常用于在页面起始处的一个单独区域里指定一个图形的位置,或者将内容浮动于图形的周围

flow

Contains all elements to be printed to a page
包含所有要打印在页面上的元素

footnote

Defines a footnote within the region-body of a page
在页面区域主体上定义脚注

footnote-body

Defines the content of the footnote
定义脚注内容

initial-property-set

Formats the first line of an <fo:block>
格式化<fo:block>元素的第一行

inline

Formats a part of a text with a background or enclosing it in a border
通过背景属性或将其嵌入一个边框来定义文本的一部分格式

inline-container

Defines an inline reference-area
定义行内参数区域

instream-foreign-object

Used for inline graphics or for "generic" objects where the object's data resides as descendants of <fo:instream-foreign-object>
用于行内图形或类对象。在其中,对象的数据以<fo:instream-foreign-object>的孙类元素形式存在

layout-master-set

Holds all masters used in a document
保留文档中所有使用的master[ 主体 ]

leader

Used to generate "." to separate titles from page numbers in table of contents, or to create input fields in forms, or to create horizontal rules
通过定义 “.” 为分割页面中的标题,或者建立一个表单输入字段或一个平行法则

list-block

Defines a list
定义一张列表

list-item

Contains each item in the list
包含列表的每个项

list-item-body

Contains the content/body of the list-item
包含列表项的内容 / 主体

list-item-label

Contains the label for the list-item (typically a number, character, etc.)
包含列表项的标签(一般是一个数字、字符,等等)

marker

Used with <fo:retrieve-marker> to create running headers or footers
使用<fo:retrieve-marker>来创建运行标题或运行页脚

multi-case

Contains (within an <fo:multi-switch>) each alternative sub-tree of XSL-FO objects. The parent <fo:multi-switch> will choose which alternative to show and hide the rest
在<fo:multi-switch>中,包含了每一个可用于替代XSL-FO对象的子树的对象。父级 <fo:multi-switch> 会选择其中一个来决定 “显示或隐藏” 剩余的部分。

multi-properties

Used to switch between two or more property-sets
用于在两个或更多的属性集之间进行转换

multi-property-set

Specifies an alternative property-set that will be applied depending on the state of the user agent
根据用户的代理状态,指定一个应用属性集的替代元素

multi-switch

Holds one or more <fo:multi-case> objects and controls the switching between them (activated by <fo:multi-toggle>)
保留一个或多个<fo:multi-case>对象,控制它们(由 <fo:multi-toggle> 触发)彼此之间的转换

multi-toggle

Used to switch to another <fo:multi-case>
用于转换成另一个 <fo:multi-toggle>元素

page-number

Represents the current page-number
指示当前页码

page-number-citation

References the page-number for the page that contains the first normal area returned by the cited object
为包含由site对象所返回的第一标准区域指定页码

page-sequence

A container for page output elements. There will be one <fo:page-sequence> object for each page layout
指定一个页面结果元素的容器。这里,<fo:page-sequence>对象适用于所有的页面布局

page-sequence-master

Specifies which simple-page-masters are to be used and in which order
指定使用的“simple-page-masters [简单页面主体] ” 以及使用顺序

region-after

Defines a page footer
定义页脚

region-before

Defines a page header
定义页眉

region-body

Defines a page body
定义页面主体

region-end

Defines the right sidebar of a page
定义页面右工具条

region-start

Defines the left sidebar of a page
定义页面左工具条

repeatable-page-master-alternatives

Specifies repetition of a set of simple-page-masters
指定一组 “simple-page-masters” 循环

repeatable-page-master-reference

Specifies repetition of a single simple-page-master
指定单个 “simple-page-masters” 循环

retrieve-marker

Used with <fo:marker> to create running headers or footers
使用 <fo:marker> 创建运行的标题与页脚

root

The root (top) node for XSL-FO documents
指定XSL-FO文档的根目录节点

simple-page-master

Defines the size and shape of a page
定义页面的尺寸与形状

single-page-master-reference

Specifies a page-master to be used at a given point in the sequence of pages
在一个页面序列的给定点中指定 page-master [ 页面主体 ]

static-content

Contains static content (e.g. headers and footers) that will be repeated on many pages
指定在多个页面中重复使用或出现的静态内容(如:页眉和页脚)

table

Formats the tabular material of a table
格式化表格的列表材料

table-and-caption

Formats a table and its caption
格式化表格及其标题

table-body

Container for table rows and table cells
指定表格行和单元格的容器

table-caption

Contains the caption for a table
指定表格标题

table-cell

Defines a table cell
定义一个单元格

table-column

Formats the columns of a table
格式化表格列

table-footer

Defines a table footer
定义表格页脚

table-header

Defines a table header
定义表格页眉

table-row

Defines a table row
定义表格行

title

Defines a title for a page-sequence
定义页面序列的标题

wrapper

Specifies inherited properties for a group of XSL-FO objects
指定XSL-FO对象组的继承属性

posted on 2008-01-18 14:36 周锐 阅读(1347) 评论(0)  编辑  收藏 所属分类: HTMLXMLXSLT

只有注册用户登录后才能发表评论。


网站导航: