有没有办法以 XSL-Fo 格式创建嵌套列表?
Is there a way to create nested list in XSL-Fo format ?
我希望输出如下所示:
a. Pets' names and preferences
i. Charlie
1. Tuna
2. Scratching
ii. Fluffy
1. Corn
2. Running
但是找不到嵌套的方法<fo:list-item>.
在 fo:list-item-body
内嵌套 fo:list-block
。
fo:list-item-body
(https://www.w3.org/TR/xsl11/#fo_list-item-body) can contain any of the %block;
FOs (https://www.w3.org/TR/xsl11/#block.fo.list), and fo:list-block
(https://www.w3.org/TR/xsl11/#fo_list-block) 是一个。
你最终会得到像这样的 FO 嵌套:
fo:list-block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:list-block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:list-block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:block
您需要在每个 fo:list-block
上正确设置 provisional-distance-between-starts
(https://www.w3.org/TR/xsl11/#provisional-distance-between-starts) and provisional-label-separation
(https://www.w3.org/TR/xsl11/#provisional-label-separation),以便列表项按照您想要的方式缩进。
我希望输出如下所示:
a. Pets' names and preferences
i. Charlie
1. Tuna
2. Scratching
ii. Fluffy
1. Corn
2. Running
但是找不到嵌套的方法<fo:list-item>.
在 fo:list-item-body
内嵌套 fo:list-block
。
fo:list-item-body
(https://www.w3.org/TR/xsl11/#fo_list-item-body) can contain any of the %block;
FOs (https://www.w3.org/TR/xsl11/#block.fo.list), and fo:list-block
(https://www.w3.org/TR/xsl11/#fo_list-block) 是一个。
你最终会得到像这样的 FO 嵌套:
fo:list-block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:list-block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:list-block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:block
fo:list-item
fo:list-item-label
fo:block
fo:list-item-body
fo:block
您需要在每个 fo:list-block
上正确设置 provisional-distance-between-starts
(https://www.w3.org/TR/xsl11/#provisional-distance-between-starts) and provisional-label-separation
(https://www.w3.org/TR/xsl11/#provisional-label-separation),以便列表项按照您想要的方式缩进。