<xsl:text>)</xsl:text>
<xsl:text>▀</xsl:text>
<xsl:call-template name="italic">
- <xsl:with-param name="node" select="exsl:node-set(normalize-space(.))"/>
+ <xsl:with-param name="node" select="."/>
<xsl:with-param name="context" select="."/>
</xsl:call-template>
</xsl:template>
<xsl:text> </xsl:text>
<!-- * If we have a group of Synopfragments, we only want to output a -->
<!-- * line of space before the first; so when we find a Synopfragment -->
- <!-- * whose first preceding sibling is another Synopfragment, we back -->
- <!-- * use the pinch-together template to close up the line of space -->
+ <!-- * which has another Synopfragment as a following sibling, we use-->
+ <!-- * the pinch-together template to close up the line of space -->
<!-- * that would otherwise be generated by the .HP macro -->
- <xsl:if test="preceding-sibling::*[1][self::synopfragment]">
+ <xsl:if test="following-sibling::*[self::synopfragment]">
<xsl:call-template name="pinch.together"/>
</xsl:if>
<xsl:text>.HP </xsl:text>
- <!-- * For each Synopfragment, make a hanging paragraph, with the -->
- <!-- * indent calculated from the length of the generated number -->
- <!-- * used as a reference + pluse 3 characters (for the open and -->
- <!-- * close parens around the number, plus a space). -->
- <xsl:value-of select="string-length (normalize-space ($snum)) + 3"/>
+ <xsl:text>\w'</xsl:text>
+ <xsl:text>(</xsl:text>
+ <xsl:value-of select="$snum"/>
+ <xsl:text>)</xsl:text>
+ <xsl:text>\ 'u</xsl:text>
<xsl:text> </xsl:text>
<xsl:text>(</xsl:text>
<xsl:value-of select="$snum"/>
<xsl:text>)</xsl:text>
- <xsl:text> </xsl:text>
+ <xsl:text>\ </xsl:text>
<xsl:apply-templates/>
</xsl:template>
<xsl:if test="$man.hyphenate != 0">
<xsl:text>.hy 0 </xsl:text>
</xsl:if>
+ <xsl:call-template name="synopsis-block-start"/>
<xsl:text>.HP </xsl:text>
- <xsl:value-of select="string-length (normalize-space (command)) + 1"/>
+ <xsl:text>\w'</xsl:text>
+ <xsl:variable name="command">
+ <xsl:apply-templates select="command"/>
+ </xsl:variable>
+ <xsl:call-template name="string.subst">
+ <xsl:with-param name="string" select="normalize-space($command)"/>
+ <xsl:with-param name="target" select="' '"/>
+ <xsl:with-param name="replacement" select="'\ '"/>
+ </xsl:call-template>
+ <xsl:text>\ 'u</xsl:text>
<xsl:text> </xsl:text>
- <xsl:call-template name="verbatim-block-start"/>
<xsl:apply-templates/>
<xsl:text> </xsl:text>
- <xsl:call-template name="verbatim-block-end"/>
+ <xsl:call-template name="synopsis-block-end"/>
<!-- * if justification is enabled by default, turn it back on -->
<xsl:if test="$man.justify != 0">
<xsl:text>.ad </xsl:text>
<xsl:variable name="funcprototype">
<xsl:apply-templates select="funcdef"/>
</xsl:variable>
+ <xsl:call-template name="synopsis-block-start"/>
<xsl:text>.HP </xsl:text>
- <!-- * Hang Paragraph by length of string value of <funcdef> + 1 -->
- <!-- * (because funcdef is always followed by one open paren char) -->
- <xsl:value-of select="string-length (normalize-space ($funcprototype.string.value)) + 1"/>
+ <xsl:text>\w'</xsl:text>
+ <xsl:variable name="funcdef">
+ <xsl:apply-templates select="funcdef"/>
+ </xsl:variable>
+ <xsl:call-template name="string.subst">
+ <xsl:with-param name="string" select="normalize-space($funcdef)"/>
+ <xsl:with-param name="target" select="' '"/>
+ <xsl:with-param name="replacement" select="'\ '"/>
+ </xsl:call-template>
+ <xsl:text>('u</xsl:text>
<xsl:text> </xsl:text>
- <xsl:call-template name="verbatim-block-start"/>
<xsl:text>.</xsl:text>
<xsl:value-of select="$man.font.funcprototype"/>
<xsl:text> </xsl:text>
<xsl:apply-templates select="paramdef" mode="kr-paramdef-list"/>
<xsl:text>.RE </xsl:text>
</xsl:if>
- <xsl:call-template name="verbatim-block-end"/>
+ <xsl:call-template name="synopsis-block-end"/>
</xsl:template>
<xsl:template match="funcdef">