Changeset f7bd105 for stylesheets/xhtml


Ignore:
Timestamp:
12/19/2004 09:17:48 PM (19 years ago)
Author:
Manuel Canales Esparcia <manuel@…>
Branches:
10.0, 10.0-rc1, 10.1, 10.1-rc1, 11.0, 11.0-rc1, 11.0-rc2, 11.0-rc3, 11.1, 11.1-rc1, 11.2, 11.2-rc1, 11.3, 11.3-rc1, 12.0, 12.0-rc1, 12.1, 12.1-rc1, 6.1, 6.1.1, 6.3, 6.4, 6.5, 6.6, 6.7, 6.8, 7.0, 7.1, 7.2, 7.3, 7.4, 7.5, 7.5-systemd, 7.6, 7.6-systemd, 7.7, 7.7-systemd, 7.8, 7.8-systemd, 7.9, 7.9-systemd, 8.0, 8.1, 8.2, 8.3, 8.4, 9.0, 9.1, arm, bdubbs/gcc13, ml-11.0, multilib, renodr/libudev-from-systemd, s6-init, trunk, xry111/arm64, xry111/arm64-12.0, xry111/clfs-ng, xry111/lfs-next, xry111/loongarch, xry111/loongarch-12.0, xry111/loongarch-12.1, xry111/mips64el, xry111/pip3, xry111/rust-wip-20221008, xry111/update-glibc
Children:
faf3398
Parents:
6d3af72
Message:

Updated the stylesheets and Makefile.
Removed contrib/, index-pdf.xml and goTidy.

git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@4428 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

Location:
stylesheets/xhtml
Files:
2 added
6 edited

Legend:

Unmodified
Added
Removed
  • stylesheets/xhtml/lfs-admon.xsl

    r6d3af72 rf7bd105  
    2222      </xsl:choose>
    2323    </xsl:variable>
     24    <xsl:variable name="alt">
     25      <xsl:call-template name="gentext">
     26        <xsl:with-param name="key" select="$admon.type"/>
     27      </xsl:call-template>
     28    </xsl:variable>
    2429    <div class="{name(.)}">
    2530      <div class ="admonhead">
    26         <img alt="[{$admon.type}]">
     31        <img alt="[{$alt}]">
    2732          <xsl:attribute name="src">
    2833            <xsl:call-template name="admon.graphic"/>
     
    3035        </img>
    3136        <h3 class="admontitle">
    32           <xsl:value-of select="$admon.type"/>
    33           <xsl:if test="title">
    34             <xsl:text>: </xsl:text>
    35             <xsl:value-of select="title"/>
    36           </xsl:if>
     37          <xsl:apply-templates select="." mode="object.title.markup"/>
    3738        </h3>
    3839      </div>
  • stylesheets/xhtml/lfs-index.xsl

    r6d3af72 rf7bd105  
    1717
    1818    <!--Title-->
    19   <xsl:param name="index-title">Index of packages and important installed files</xsl:param>
     19  <xsl:param name="index-title">Index</xsl:param>
    2020 
    2121  <xsl:template match="index" mode="title.markup">
    22     <xsl:value-of select="$index-title"/>
    23   </xsl:template>
    24  
     22    <xsl:call-template name="gentext">
     23      <xsl:with-param name="key" select="$index-title"/>
     24    </xsl:call-template>
     25  </xsl:template>
     26
    2527  <xsl:template name="index.titlepage">
    2628    <div class="titlepage">
    2729      <h1 class="index">
    28         <xsl:value-of select="$index-title"/>
     30        <xsl:call-template name="gentext">
     31          <xsl:with-param name="key" select="$index-title"/>
     32        </xsl:call-template>
    2933      </h1>
    3034    </div>
     
    4347            <xsl:choose>
    4448              <xsl:when test="$divtitle = 'A'">
    45                 <xsl:text>Packages</xsl:text>
     49                <xsl:call-template name="gentext">
     50                  <xsl:with-param name="key">Packages</xsl:with-param>
     51                </xsl:call-template>
    4652             </xsl:when>
    4753             <xsl:when test="$divtitle = 'B'">
    48                 <xsl:text>Programs</xsl:text>
     54                <xsl:call-template name="gentext">
     55                  <xsl:with-param name="key">Programs</xsl:with-param>
     56                </xsl:call-template>
    4957             </xsl:when>
    5058             <xsl:when test="$divtitle = 'C'">
    51                 <xsl:text>Libraries</xsl:text>
     59                <xsl:call-template name="gentext">
     60                  <xsl:with-param name="key">Libraries</xsl:with-param>
     61                </xsl:call-template>
    5262             </xsl:when>
    5363             <xsl:when test="$divtitle = 'D'">
    54                 <xsl:text>Scripts</xsl:text>
     64                <xsl:call-template name="gentext">
     65                  <xsl:with-param name="key">Scripts</xsl:with-param>
     66                </xsl:call-template>
    5567             </xsl:when>
    5668              <xsl:when test="$divtitle = 'E'">
    57                   <xsl:text>Others</xsl:text>
     69                <xsl:call-template name="gentext">
     70                  <xsl:with-param name="key">Others</xsl:with-param>
     71                </xsl:call-template>
    5872              </xsl:when>
    5973             <xsl:otherwise>
     
    163177            </xsl:call-template>
    164178          </xsl:attribute>
    165           <xsl:text>description</xsl:text>
     179          <xsl:call-template name="gentext">
     180            <xsl:with-param name="key">description</xsl:with-param>
     181          </xsl:call-template>
    166182        </a>
    167183      </xsl:when>
  • stylesheets/xhtml/lfs-mixed.xsl

    r6d3af72 rf7bd105  
    1010      <xsl:when test="child::* = userinput">
    1111        <pre class="userinput">
    12           <kbd class="command">
    13             <xsl:value-of select="."/>
    14           </kbd>
     12            <xsl:apply-templates/>
    1513        </pre>
    1614      </xsl:when>
     
    2220    </xsl:choose>
    2321  </xsl:template>
     22 
     23  <xsl:template match="userinput">
     24    <xsl:choose>
     25      <xsl:when test="ancestor::screen">
     26        <kbd class="command">
     27          <xsl:apply-templates/>
     28        </kbd>
     29      </xsl:when>
     30      <xsl:otherwise>
     31        <xsl:apply-imports/>
     32      </xsl:otherwise>
     33    </xsl:choose>
     34  </xsl:template>
     35
    2436 
    2537  <!-- variablelist -->
     
    6173  </xsl:template>
    6274
    63    <!-- Sect1 attributes -->
    64   <xsl:template match="sect1">
    65     <div>
    66       <xsl:choose>
    67         <xsl:when test="@role">
    68           <xsl:attribute name="class">
    69             <xsl:value-of select="@role"/>
    70           </xsl:attribute>
    71         </xsl:when>
    72         <xsl:otherwise>
    73           <xsl:attribute name="class">
    74             <xsl:value-of select="name(.)"/>
    75           </xsl:attribute>
    76         </xsl:otherwise>
    77       </xsl:choose>
    78       <xsl:call-template name="language.attribute"/>
    79       <xsl:call-template name="sect1.titlepage"/>
    80       <xsl:apply-templates/>
    81       <xsl:call-template name="process.chunk.footnotes"/>
    82     </div>
     75    <!-- External URLs in italic font -->
     76  <xsl:template match="ulink" name="ulink">
     77    <a>
     78      <xsl:if test="@id">
     79        <xsl:attribute name="id">
     80          <xsl:value-of select="@id"/>
     81        </xsl:attribute>
     82      </xsl:if>
     83      <xsl:attribute name="href"><xsl:value-of select="@url"/></xsl:attribute>
     84       <i>
     85        <xsl:choose>
     86          <xsl:when test="count(child::node())=0">
     87            <xsl:value-of select="@url"/>
     88          </xsl:when>
     89          <xsl:otherwise>
     90            <xsl:apply-templates/>
     91          </xsl:otherwise>
     92        </xsl:choose>
     93      </i>
     94    </a>
    8395  </xsl:template>
    8496
    85     <!-- Sect2 attributes -->
    86   <xsl:template match="sect2">
    87     <div>
    88       <xsl:choose>
    89         <xsl:when test="@role">
    90           <xsl:attribute name="class">
    91             <xsl:value-of select="@role"/>
    92           </xsl:attribute>
    93         </xsl:when>
    94         <xsl:otherwise>
    95           <xsl:attribute name="class">
    96             <xsl:value-of select="name(.)"/>
    97           </xsl:attribute>
    98         </xsl:otherwise>
    99       </xsl:choose>
    100       <xsl:call-template name="language.attribute"/>
    101       <xsl:call-template name="sect2.titlepage"/>
    102       <xsl:apply-templates/>
    103       <xsl:call-template name="process.chunk.footnotes"/>
    104     </div>
    105   </xsl:template>
    10697
    10798</xsl:stylesheet>
  • stylesheets/xhtml/lfs-navigational.xsl

    r6d3af72 rf7bd105  
    6969                </xsl:attribute>
    7070                <xsl:attribute name="title">
    71                   <xsl:value-of select="$next/title"/>
     71                  <xsl:choose>
     72                    <xsl:when test="local-name($next)='index'">
     73                      <xsl:call-template name="gentext">
     74                        <xsl:with-param name="key">Index</xsl:with-param>
     75                      </xsl:call-template>
     76                    </xsl:when>
     77                    <xsl:otherwise>
     78                      <xsl:value-of select="$next/title"/>
     79                    </xsl:otherwise>
     80                  </xsl:choose>
    7281                </xsl:attribute>
    7382                <xsl:call-template name="navig.content">
     
    7685              </a>
    7786              <p>
    78                 <xsl:value-of select="$next/title"/>
     87                <xsl:choose>
     88                  <xsl:when test="local-name($next)='index'">
     89                    <xsl:call-template name="gentext">
     90                      <xsl:with-param name="key">Index</xsl:with-param>
     91                    </xsl:call-template>
     92                  </xsl:when>
     93                  <xsl:otherwise>
     94                    <xsl:value-of select="$next/title"/>
     95                  </xsl:otherwise>
     96                </xsl:choose>
    7997              </p>
    8098            </li>
     
    161179                </xsl:attribute>
    162180                <xsl:attribute name="title">
    163                   <xsl:value-of select="$next/title"/>
     181                  <xsl:choose>
     182                    <xsl:when test="local-name($next)='index'">
     183                      <xsl:call-template name="gentext">
     184                        <xsl:with-param name="key">Index</xsl:with-param>
     185                      </xsl:call-template>
     186                    </xsl:when>
     187                    <xsl:otherwise>
     188                      <xsl:value-of select="$next/title"/>
     189                    </xsl:otherwise>
     190                  </xsl:choose>
    164191                </xsl:attribute>
    165192                <xsl:call-template name="navig.content">
     
    168195              </a>
    169196              <p>
    170                 <xsl:value-of select="$next/title"/>
     197                <xsl:choose>
     198                  <xsl:when test="local-name($next)='index'">
     199                    <xsl:call-template name="gentext">
     200                      <xsl:with-param name="key">Index</xsl:with-param>
     201                    </xsl:call-template>
     202                  </xsl:when>
     203                  <xsl:otherwise>
     204                    <xsl:value-of select="$next/title"/>
     205                  </xsl:otherwise>
     206                </xsl:choose>
    171207              </p>
    172208            </li>
  • stylesheets/xhtml/lfs-titles.xsl

    r6d3af72 rf7bd105  
    88    <div class="titlepage">
    99      <h1 class="{name(.)}">
     10        <xsl:apply-templates select="." mode="label.markup"/>
     11        <xsl:text>. </xsl:text>
    1012        <xsl:value-of select="title"/>
    1113      </h1>
     
    1618    <div class="titlepage">
    1719      <h1 class="{name(.)}">
     20        <xsl:apply-templates select="." mode="label.markup"/>
     21        <xsl:text>. </xsl:text>
    1822        <xsl:value-of select="title"/>
    1923      </h1>
     
    2428    <div class="titlepage">
    2529      <h1 class="{name(.)}">
     30        <xsl:value-of select="title"/>
     31      </h1>
     32    </div>
     33  </xsl:template>
     34
     35  <xsl:template name="appendix.titlepage">
     36    <div class="titlepage">
     37      <h1 class="{name(.)}">
     38        <xsl:apply-templates select="." mode="label.markup"/>
     39        <xsl:text>. </xsl:text>
    2640        <xsl:value-of select="title"/>
    2741      </h1>
     
    3852          </xsl:if>
    3953          <h2 class="{name(.)}">
     54            <xsl:apply-templates select="." mode="label.markup"/>
     55            <xsl:text>. </xsl:text>
    4056            <xsl:value-of select="title"/>
    4157          </h2>
     
    4561        <div class="titlepage">
    4662          <h1 class="{name(.)}">
     63            <xsl:apply-templates select="." mode="label.markup"/>
     64            <xsl:text>. </xsl:text>
    4765            <xsl:value-of select="title"/>
    4866          </h1>
     
    6179          </xsl:if>
    6280          <h2 class="{name(.)}">
     81            <xsl:apply-templates select="." mode="label.markup"/>
     82            <xsl:text>. </xsl:text>
    6383            <xsl:value-of select="title"/>
    6484          </h2>
     
    7696  </xsl:template>
    7797
     98    <!-- Added the role param for proper punctuation in xref calls. -->
     99  <xsl:template match="*" mode="insert.title.markup">
     100    <xsl:param name="purpose"/>
     101    <xsl:param name="xrefstyle"/>
     102    <xsl:param name="title"/>
     103    <xsl:param name="role"/>
     104    <xsl:choose>
     105      <xsl:when test="$purpose = 'xref' and titleabbrev">
     106        <xsl:apply-templates select="." mode="titleabbrev.markup"/>
     107      </xsl:when>
     108      <xsl:otherwise>
     109        <xsl:copy-of select="$title"/>
     110        <xsl:value-of select="$role"/>
     111      </xsl:otherwise>
     112    </xsl:choose>
     113  </xsl:template>
     114
    78115</xsl:stylesheet>
  • stylesheets/xhtml/lfs-toc.xsl

    r6d3af72 rf7bd105  
    77    <!-- General settings -->
    88  <xsl:param name="generate.toc">
    9     appendix  toc
     9    appendix  nop
    1010    book      toc,title,figure,table,example,equation
    1111    chapter   nop
     
    9494        </a>
    9595      </xsl:when>
     96      <xsl:when test="local-name(.) = 'appendix'">
     97        <a>
     98          <xsl:attribute name="href">
     99            <xsl:call-template name="href.target">
     100              <xsl:with-param name="context" select="$toc-context"/>
     101            </xsl:call-template>
     102          </xsl:attribute>
     103          <xsl:variable name="label">
     104            <xsl:apply-templates select="." mode="label.markup"/>
     105          </xsl:variable>
     106          <xsl:copy-of select="$label"/>
     107          <xsl:if test="$label != ''">
     108            <xsl:value-of select="$autotoc.label.separator"/>
     109          </xsl:if>
     110          <xsl:apply-templates select="." mode="titleabbrev.markup"/>
     111        </a>
     112      </xsl:when>
    96113      <xsl:when test="local-name(.) = 'chapter' or local-name(.) = 'preface'">
    97114        <h4>
Note: See TracChangeset for help on using the changeset viewer.