OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Re: [docbook-apps] refentry, man(nroff), & comments in lists


On Thu, Nov 06, 2003 at 03:11:07PM -0500, Sam Steingold wrote:
> Hi, I am still having the problem that I cannot make xsltproc always
> pass comments from docbook sources to the nroff output.
> 
> my stylesheet is:
> 
> <!-- here we just convert comments into < ! - - ... - - >
>   for further processing with sed(1) (see Makefile) -->
> <xsl:template match="comment()">
>  <xsl:text>&#60;!--</xsl:text> <!-- #\< ! - - -->
>  <xsl:variable name="content">
>   <xsl:call-template name="string.subst">
>    <xsl:with-param name="string"><xsl:value-of select="."/></xsl:with-param>
>    <xsl:with-param name="target" select="'&#10;'"/>
>    <xsl:with-param name="replacement" select="'--&#62;&#10;&#60;!--'"/>
>   </xsl:call-template>
>  </xsl:variable>
>  <xsl:value-of select="normalize-space($content)"/>
>  <xsl:text>--&#62;</xsl:text> <!-- - - #\> -->
> </xsl:template>
> 
> document snippet:
> 
> <refsection id="environment"><title>Environment</title>
> <variablelist>
> 
> <!-- #ifdef MSDOS -->
> <varlistentry><term><envar>COMSPEC</envar> (OS/2 implementation only)</term>
>  <listitem><simpara>is used to find the command interpreter called by
>    <ulink url="impnotes.html#shell"><function>shell</function></ulink>.
> </simpara></listitem></varlistentry>
> <!-- #endif -->
> 
> ..
> 
> </variablelist>
> </refsection>
> 
> this is converted to
> 
> .TP
> \fBCOMSPEC\fR (OS/2 implementation only)
> is used to find the command interpreter called by \fBshell\fR\&.
> 
> the above stylesheet works fine for comments embedded in a <para>, but
> not for lists.
> 
> is it possible to fix this bug?

It is likely that the template for variablelist is
explicitly selecting its children to process rather than
just doing a general apply-templates. That selection
probably only includes elements, not other node types like
comment().  You need to find where it is selecting its
content and make sure comment() is included.   It looks
like it might be in the template for variablelists in
html/lists.xsl.

-- 

Bob Stayton                                 400 Encinal Street
Publications Architect                      Santa Cruz, CA  95060
Technical Publications                      voice: (831) 427-7796
The SCO Group                               fax:   (831) 429-1887
                                            email: bobs@sco.com


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]