如何在XSL-FO中创建书签?

时间:2013-04-23 13:43:34

标签: xsl-fo

我有XML章节,一章内可以有任意数量的章节。如何创建相同的书签。:

      1. Chapter 1
       1.1 chapter 1.1
         1.1.1 Chapter 1.1.1
       1.2 Chapter 1.2

      2.Chapter 2
        2.1 Chapter 2.1
        2.2 Chapter 2.2

我尝试使用:

<fo:bookmark-tree>
    <fo:bookmark
        internal-destination="toc">
        <fo:bookmark-title>  
         Table Of Contents
        </fo:bookmark-title>
        <fo:bookmark
           internal-destination="CHAPTER/LONG-NAME"
           starting-state="show">
           <fo:bookmark-title>
           <xsl:for-each select="//CHAPTER">
            <xsl:number format="1. " count="CHAPTER" level=""multiple/>
           <xsl:value-of select="LONG-NAME"/>
           </xsl:for-each>
        <xsl:apply-templates
            select="CHAPTER/LONG-NAME"/>
            </fo:bookmark-title>`
            </fo:bookmark>
    </fo:bookmark>
    </fo:bookmark-tree>

但我能够实现两个子书签: 一个目录作为标题 第二个以“所有章节的长名”作为标题。

如何重复fo:每个章节的书签标签??

0 个答案:

没有答案
相关问题