Hi Bob,
first thanks a lot for your time and your explanations.
I think, may be it can really easy be done by something like that.
dockbook snippet:
<para>
Some general text...
<variablelist>
<varlistentry role="REC">
<term>REC-XX</term>
<listitem>
<para>
Bla bla
</para>
</listitem>
</varlistentry>
<varlistentry role="REC">
<term>REC-XX</term>
<listitem>
<para>
Bla bla bla
</para>
</listitem>
</varlistentry>
<varlistentry role="REQ">
<term>REQ-XX</term>
<listitem>
<para>
Bla bla bla
</para>
</listitem>
</varlistentry>
</variablelist>
</para>
And then use an general (not output specific template) similar to:
<xsl:template match="[EMAIL PROTECTED] = 'REC']" mode="object.term.markup">
<fo:block xsl:use-attribute-sets="special.varlistentry.term.attributes">
<xsl:text>MYREC-</xsl:text>
<xsl:variable name="rec-number">
<xsl:number count="[EMAIL PROTECTED] = 'REC']" level="any"/>
</xsl:variable>
<xsl:number value="$rec-number" format="01"/>
</fo:block>
</xsl:template>
same for REQs.
What is your opinion? Can this work? My template is wrong, do have an hint
or a resource where I can find more informations.
Thanks a lot in advance,
Halm
Bob Stayton wrote:
> Hi,
> Yes, this can work in a similar fashion for HTML output, as it uses
> mode="object.title.markup" too.
>
> Regarding learning XSLT, I use Michael Kay's XSLT Programmer's Reference
> (2nd edition, not 3rd edition which covers XSLT 2.0). I'm sure there
> must be online XSLT manuals as well, but I've not used them.
>
> The reference to mode="title.markup" is to a feature of the DocBook XSL
> stylesheets that generates just the title for an element, as explained a
> bit more in my book:
>
> http://www.sagehill.net/docbookxsl/ReplaceTemplate.html#UtilityTemplates
>
> It wasn't clear from your example if these REC and REQ items had titles,
> so I said you could use this if you need to display the title.
>
> Bob Stayton
> Sagehill Enterprises
> [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]