output "sp" before simpara output, not after it (outputting it
authorMichael Smith <xmldoc@users.sourceforge.net>
Mon, 3 Mar 2008 05:07:39 +0000 (05:07 +0000)
committerMichael Smith <xmldoc@users.sourceforge.net>
Mon, 3 Mar 2008 05:07:39 +0000 (05:07 +0000)
after results in undesirable whitespace in particular cases; for
example, in the hg/mercurial docs

xsl/manpages/block.xsl

index 350837f0fbae725930162cf04767e15a7e76279c..4d4b32a492ad7307c78e6349002cc649d3ebc069 100644 (file)
 </xsl:template>
 
 <xsl:template match="simpara">
+  <xsl:if test="not(ancestor::authorblurb) and
+                not(ancestor::personblurb)">
+    <xsl:text>.sp&#10;</xsl:text>
+  </xsl:if>
   <xsl:variable name="content">
     <xsl:apply-templates/>
   </xsl:variable>
   <xsl:value-of select="normalize-space($content)"/>
   <xsl:text>&#10;</xsl:text>
-  <xsl:if test="not(ancestor::authorblurb) and
-                not(ancestor::personblurb)">
-    <xsl:text>.sp&#10;</xsl:text>
-  </xsl:if>
 </xsl:template>
 
 <!-- ==================================================================== -->