Synthesize a list of subsections in the HV1 documentation for pages without nested...
authorDean Camera <dean@fourwalledcubicle.com>
Fri, 24 May 2013 15:29:05 +0000 (17:29 +0200)
committerDean Camera <dean@fourwalledcubicle.com>
Fri, 24 May 2013 15:29:05 +0000 (17:29 +0200)
LUFA/StudioIntegration/HV1/lufa_docbook_transform.xslt

index 24a5dfa..71150aa 100644 (file)
 
                        <xsl:apply-templates select="detaileddescription"/>
 
 
                        <xsl:apply-templates select="detaileddescription"/>
 
+                       <xsl:if test="not(innerpage) and count(detaileddescription//sect1)">
+                               <para>
+                                       <emphasis role="bold">Subsections:</emphasis>
+                                       <itemizedlist>
+                                               <xsl:for-each select="detaileddescription//sect1">
+                                                       <listitem>
+                                                               <link linkend="{@id}">
+                                                                       <xsl:value-of select="title"/>
+                                                               </link>
+                                                       </listitem>
+                                               </xsl:for-each>
+                                       </itemizedlist>
+                               </para>
+                       </xsl:if>
+
                        <xsl:for-each select="innerpage">
                                <xsl:apply-templates select="ancestor::*/compounddef[@kind = 'page' and @id = current()/@refid]"/>
                        </xsl:for-each>
                        <xsl:for-each select="innerpage">
                                <xsl:apply-templates select="ancestor::*/compounddef[@kind = 'page' and @id = current()/@refid]"/>
                        </xsl:for-each>