aboutsummaryrefslogtreecommitdiffstats
path: root/stylesheets/xhtml/lfs-mixed.xsl
diff options
context:
space:
mode:
authorManuel Canales Esparcia <manuel@linuxfromscratch.org>2005-09-18 13:44:20 +0000
committerManuel Canales Esparcia <manuel@linuxfromscratch.org>2005-09-18 13:44:20 +0000
commitcb87df64723790d8412c04c567ab3b237a24c05d (patch)
treeccfde5d56d134c7a562e3c641e0742e5eb2eb793 /stylesheets/xhtml/lfs-mixed.xsl
parentd13319a59ba661132e09499e88427ad8383b9031 (diff)
Updated the stylesheets to the new version. But some fixes are needed yet.LFS-RNG
git-svn-id: http://svn.linuxfromscratch.org/LFS/branches/LFS-RNG/BOOK@6874 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
Diffstat (limited to 'stylesheets/xhtml/lfs-mixed.xsl')
-rw-r--r--stylesheets/xhtml/lfs-mixed.xsl102
1 files changed, 51 insertions, 51 deletions
diff --git a/stylesheets/xhtml/lfs-mixed.xsl b/stylesheets/xhtml/lfs-mixed.xsl
index 7ecdeed7f..50e4140f1 100644
--- a/stylesheets/xhtml/lfs-mixed.xsl
+++ b/stylesheets/xhtml/lfs-mixed.xsl
@@ -2,7 +2,6 @@
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns="http://www.w3.org/1999/xhtml"
- xmlns:xlink="http://www.w3.org/1999/xlink"
version="1.0">
<!-- screen -->
@@ -34,34 +33,42 @@
</xsl:choose>
</xsl:template>
+ <!-- segementedlist -->
+ <xsl:template match="seg">
+ <xsl:variable name="segnum" select="count(preceding-sibling::seg)+1"/>
+ <xsl:variable name="seglist" select="ancestor::segmentedlist"/>
+ <xsl:variable name="segtitles" select="$seglist/segtitle"/>
+ <!-- Note: segtitle is only going to be the right thing in a well formed
+ SegmentedList. If there are too many Segs or too few SegTitles,
+ you'll get something odd...maybe an error -->
+ <div class="seg">
+ <strong>
+ <span class="segtitle">
+ <xsl:apply-templates select="$segtitles[$segnum=position()]" mode="segtitle-in-seg"/>
+ <xsl:text>: </xsl:text>
+ </span>
+ </strong>
+ <span class="seg">
+ <xsl:apply-templates/>
+ </span>
+ </div>
+ </xsl:template>
+
<!-- variablelist -->
<xsl:template match="variablelist">
- <div class="{name(.)}">
- <xsl:if test="title | bridgehead">
- <xsl:choose>
- <xsl:when test="@role = 'materials'">
- <h2>
- <xsl:value-of select="title | bridgehead"/>
- </h2>
- </xsl:when>
- <xsl:otherwise>
- <h3>
- <xsl:value-of select="title | bridgehead"/>
- </h3>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:if>
- <dl>
- <xsl:if test="@role">
- <xsl:attribute name="class">
- <xsl:value-of select="@role"/>
- </xsl:attribute>
- </xsl:if>
- <xsl:apply-templates select="varlistentry"/>
- </dl>
- </div>
+ <xsl:choose>
+ <xsl:when test="@role">
+ <div class="{@role}">
+ <xsl:apply-imports/>
+ </div>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:apply-imports/>
+ </xsl:otherwise>
+ </xsl:choose>
</xsl:template>
+
<!-- Body attributes -->
<xsl:template name="body.attributes">
@@ -74,32 +81,25 @@
</xsl:template>
<!-- External URLs in italic font -->
- <xsl:template match="link" name="ulink">
- <xsl:choose>
- <xsl:when test="@xlink:href">
- <a>
- <xsl:if test="@xml:id">
- <xsl:attribute name="id">
- <xsl:value-of select="@xml:id"/>
- </xsl:attribute>
- </xsl:if>
- <xsl:attribute name="href"><xsl:value-of select="@xlink:href"/></xsl:attribute>
- <i>
- <xsl:choose>
- <xsl:when test="count(child::node())=0">
- <xsl:value-of select="@xlink:href"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-templates/>
- </xsl:otherwise>
- </xsl:choose>
- </i>
- </a>
- </xsl:when>
- <xsl:otherwise>
- <xsl:call-template name="link"/>
- </xsl:otherwise>
- </xsl:choose>
+ <xsl:template match="ulink" name="ulink">
+ <a>
+ <xsl:if test="@id">
+ <xsl:attribute name="id">
+ <xsl:value-of select="@id"/>
+ </xsl:attribute>
+ </xsl:if>
+ <xsl:attribute name="href"><xsl:value-of select="@url"/></xsl:attribute>
+ <i>
+ <xsl:choose>
+ <xsl:when test="count(child::node())=0">
+ <xsl:value-of select="@url"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:apply-templates/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </i>
+ </a>
</xsl:template>
<!-- The <code> xhtml tag have look issues in some browsers, like Konqueror and.