[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [docbook-apps] Q and A sets with olinks: no generated text
Hi,
The xrefstyle mechanism works with number
labels and titles, but a qandaentry question does not have a title, just one or
more para and other elements. A question can be very long and complex, so
the stylesheet doesn't try to use it for xrefs.
But if you restrict your questions to a
single para, then you could create a customization to use them in xrefs.
If you look at the template in fo/xref.xsl that starts with:
<xsl:template match="qandaentry"
mode="xref-to">
That is the first template called when
generating the text for an xref. It applies templates in
mode="object.xref.markup" which uses the gentext mechanism. In your case,
you should create your own template that matches on question in
mode="object.xref.markup" for processing the question.
<xsl:template match="question"
mode="object.xref.markup">
<xsl:call-template
name="gentext">
<xsl:with-param name="key" select="'question'"/> </xsl:call-template> <xsl:text> </xsl:text> <xsl:apply-templates select="para[1]/node()"/> </xsl:template>
The select in the second-to-last line
selects the content of the first para of the question. If you just
processed the para element itself, then you would get a para block output, not
an inline output.
|
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]