I have 3 randlist in a row within a paragraph, the first should be at left the
next two indented diffently. Can anyone give me a clue how to get this
accomplished?
Here is my xsl:
<xsl:template match="randlist">
<fo:list-block>
<xsl:apply-templates/>
</fo:list-block>
</xsl:template>
<xsl:template match="item">
<fo:list-item>
<fo:list-item-label end-indent="label-end()">
<fo:block>
<xsl:if test="parent::randlist">
<fo:character character="•"/> <!-- this is a bullet -->
</xsl:if>
<xsl:if test="parent::seqlist">
<xsl:number count="item" format="1"/><!-- this numbers 123 -->
</xsl:if>
</fo:block>
</fo:list-item-label>
<fo:list-item-body start-indent="body-start()">
<fo:block>
<xsl:apply-templates/>
</fo:block>
</fo:list-item-body>
</fo:list-item>
</xsl:template>
Here is my xml:
<step1 id="step1-6">
<title>step1 title</title>
<para>This is a step 1.
<randlist id="randlist-6">
<item>Be careful not to short out battery terminal. </item>
<item>Do not smoke or use open flame near batteries. </item>
<item>Batteries may explode from spark.</item>
</randlist>
<randlist id="randlist-7">
<item>Sub-unordered list items start with a bullet indented 7mm for the left
type limit.</item>
<item>The items within a sub-unordered list shall not be separated with a blank
line.</item>
</randlist>
<randlist id="randlist-8">
<item>Subsub-unordered list items start with a bullet indented 14mm for the
left type limit.</item>
<item>The items within a sub-unordered list shall not be separated with a blank
line.</item>
</randlist>
</para>
<step2 id="step2-2">
<title>This is a sample title for a step 2</title>
<para>This is a step 2.</para>
</step2>
</step1>
Desired result:
1. step1 title</title>
This is a step 1.
° Be careful not to short out battery terminal.
° Do not smoke or use open flame near batteries.
° Batteries may explode from spark.</item>
° Sub-unordered list items start with a bullet indented 7mm for
the left type limit.
° The items within a sub-unordered list shall not be separated
with a blank line.
° Subsub-unordered list items start with a bullet indented
14mm for the left type limit.
° The items within a sub-unordered list shall not be
separated with a blank line.
1.1 This is a sample title for a step 2</title>
This is a step 2.
Thanks in advance for the help!
Confidentiality Notice
The information contained in this e-mail is confidential and intended for use
only by the person(s) or organization listed in the address. If you have
received this communication in error, please contact the sender at O'Neil &
Associates, Inc., immediately. Any copying, dissemination, or distribution of
this communication, other than by the intended recipient, is strictly
prohibited.
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list