You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by ni...@apache.org on 2003/10/14 23:31:16 UTC

cvs commit: xml-forrest/src/resources/fresh-site/src/documentation skinconf.xml

nicolaken    2003/10/14 14:31:16

  Modified:    src/resources/skins/common/xslt/html document2html.xsl
               src/resources/skins/krysalis-site/xslt/html
                        document2html.xsl
               src/resources/fresh-site/src/documentation skinconf.xml
  Log:
  Made location of minitoc configurable as "page", "menu", or "both"
  
  Revision  Changes    Path
  1.36      +3 -1      xml-forrest/src/resources/skins/common/xslt/html/document2html.xsl
  
  Index: document2html.xsl
  ===================================================================
  RCS file: /home/cvs/xml-forrest/src/resources/skins/common/xslt/html/document2html.xsl,v
  retrieving revision 1.35
  retrieving revision 1.36
  diff -u -r1.35 -r1.36
  --- document2html.xsl	27 Sep 2003 14:40:25 -0000	1.35
  +++ document2html.xsl	14 Oct 2003 21:31:16 -0000	1.36
  @@ -30,6 +30,8 @@
     <xsl:variable name="disable-xml-link" select="$config/disable-xml-link"/>  
     <!-- Get the section depth to use when generating the minitoc (default is 2) -->
     <xsl:variable name="config-max-depth" select="$config/toc/@level"/>
  +  <!-- Get the location where to generate the minitoc -->
  +  <xsl:variable name="minitoc-location" select="$config/toc/@location"/>
     <!-- Whether to obfuscate email links -->
     <xsl:variable name="obfuscate-mail-links" select="$config/obfuscate-mail-links"/>
   
  
  
  
  1.13      +11 -2     xml-forrest/src/resources/skins/krysalis-site/xslt/html/document2html.xsl
  
  Index: document2html.xsl
  ===================================================================
  RCS file: /home/cvs/xml-forrest/src/resources/skins/krysalis-site/xslt/html/document2html.xsl,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- document2html.xsl	13 Oct 2003 08:45:54 -0000	1.12
  +++ document2html.xsl	14 Oct 2003 21:31:16 -0000	1.13
  @@ -62,7 +62,7 @@
   
     <xsl:template match="body">
   
  -    <xsl:if test="section and not($notoc='true')">
  +    <xsl:if test="section and $max-depth&gt;0 and not($notoc='true') and ($minitoc-location='menu' or $minitoc-location='both')">
         <toc>
           <xsl:for-each select="section">
             <tocc>
  @@ -90,6 +90,15 @@
           </xsl:for-each>
         </toc>
       </xsl:if>
  +    
  +   <xsl:if test="$max-depth&gt;0 and not($notoc='true') and ($minitoc-location='page' or $minitoc-location='both')" >
  +      <xsl:call-template name="minitoc">
  +        <xsl:with-param name="tocroot" select="."/>
  +        <xsl:with-param name="depth">1</xsl:with-param>
  +      </xsl:call-template>
  +    </xsl:if>
  +    <xsl:apply-templates/>
  +    
       <xsl:apply-templates/>
     </xsl:template>
   
  
  
  
  1.19      +7 -3      xml-forrest/src/resources/fresh-site/src/documentation/skinconf.xml
  
  Index: skinconf.xml
  ===================================================================
  RCS file: /home/cvs/xml-forrest/src/resources/fresh-site/src/documentation/skinconf.xml,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- skinconf.xml	27 Sep 2003 10:52:55 -0000	1.18
  +++ skinconf.xml	14 Oct 2003 21:31:16 -0000	1.19
  @@ -53,7 +53,7 @@
     <!ELEMENT width (#PCDATA)>
     <!ELEMENT height (#PCDATA)>
     <!ELEMENT toc EMPTY>
  -  <!ATTLIST toc level CDATA #IMPLIED>
  +  <!ATTLIST toc level CDATA #IMPLIED location CDATA #IMPLIED>
     ]>
   
   <skinconfig>
  @@ -111,11 +111,15 @@
       <link3 name="" href=""/>
     </trail>
   
  -  <!-- Configure how many "section" levels need to be included in the
  +  <!-- Configure the TOC, ie the Table of Contents.
  +  @level
  +  how many "section" levels need to be included in the
     generated Table of Contents (TOC). By default, if no toc element is provided
     below, then 2 levels are included. Level 0 does not generate any TOC at all.
  +  @location (page,menu,both)
  +  Where to show the TOC.
     -->
  -  <toc level="2"/>
  +  <toc level="2" location="page"/>
   
     <!-- Credits are typically rendered as a set of small clickable images in the
     page footer -->