r3871 - jhalfs/trunk/BLFS/xsl

pierre at higgs.linuxfromscratch.org pierre at higgs.linuxfromscratch.org
Wed Aug 24 08:21:50 PDT 2016


Author: pierre
Date: Wed Aug 24 08:21:49 2016
New Revision: 3871

Log:
With the double book, it may happen that <phrase> is used
inside <title>, and that generates an unwanted linefeed. So, use
normalize-space for titles when generating the package list

Modified:
   jhalfs/trunk/BLFS/xsl/gen_pkg_list.xsl

Modified: jhalfs/trunk/BLFS/xsl/gen_pkg_list.xsl
==============================================================================
--- jhalfs/trunk/BLFS/xsl/gen_pkg_list.xsl	Wed Aug 24 08:15:14 2016	(r3870)
+++ jhalfs/trunk/BLFS/xsl/gen_pkg_list.xsl	Wed Aug 24 08:21:49 2016	(r3871)
@@ -40,7 +40,7 @@
         <xsl:attribute name="id"><xsl:value-of select="@id"/></xsl:attribute>
         <xsl:text>&#xA;    </xsl:text>
         <xsl:element name="name">
-           <xsl:value-of select="title"/>
+           <xsl:value-of select="normalize-space(title)"/>
         </xsl:element>
         <xsl:text>&#xA;&#xA;</xsl:text>
         <xsl:apply-templates select="chapter"/>
@@ -61,7 +61,7 @@
         <xsl:attribute name="id"><xsl:value-of select="@id"/></xsl:attribute>
         <xsl:text>&#xA;      </xsl:text>
         <xsl:element name="name">
-          <xsl:value-of select="title"/>
+          <xsl:value-of select="normalize-space(title)"/>
         </xsl:element>
         <xsl:text>&#xA;</xsl:text>
         <xsl:apply-templates select=".//sect1">
@@ -89,7 +89,7 @@
         <xsl:text>      </xsl:text>
         <package><xsl:text>&#xA;        </xsl:text>
           <xsl:element name="name">
-            <xsl:value-of select="title"/>
+            <xsl:value-of select="normalize-space(title)"/>
             </xsl:element>
           <xsl:text>&#xA;</xsl:text>
 <!-- Do not use .//*, which would include self. -->


More information about the alfs-log mailing list