Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Helman2014-11-28 13:37:15 +0000
committerSebastian Helman2014-11-28 13:50:39 +0000
commitd00d382ff245fc4f7c1bd7d6f6b5e8e9ece7d90d (patch)
tree53c5b34c0ce4670db9811d6780c615aeb9bee303 /org.eclipse.jubula.documentation.xsl
parenta7e0fa9ac1e4808ffe40706f2a6e9cfa0cec509d (diff)
downloadorg.eclipse.jubula.core-d00d382ff245fc4f7c1bd7d6f6b5e8e9ece7d90d.tar.gz
org.eclipse.jubula.core-d00d382ff245fc4f7c1bd7d6f6b5e8e9ece7d90d.tar.xz
org.eclipse.jubula.core-d00d382ff245fc4f7c1bd7d6f6b5e8e9ece7d90d.zip
Created empty structure for reference manual
Signed-off-by: Sebastian Helman <Sebastian.Helman@bredex.de>
Diffstat (limited to 'org.eclipse.jubula.documentation.xsl')
-rw-r--r--org.eclipse.jubula.documentation.xsl/custom/jubulatemplates.xsl59
1 files changed, 59 insertions, 0 deletions
diff --git a/org.eclipse.jubula.documentation.xsl/custom/jubulatemplates.xsl b/org.eclipse.jubula.documentation.xsl/custom/jubulatemplates.xsl
index 652202d33..ce01fbf53 100644
--- a/org.eclipse.jubula.documentation.xsl/custom/jubulatemplates.xsl
+++ b/org.eclipse.jubula.documentation.xsl/custom/jubulatemplates.xsl
@@ -54,6 +54,65 @@ http://www.sagehill.net/docbookxsl/HTMLHeaders.html#BreadCrumbs
<xsl:call-template name="generate.breadcrumbs"/>
</xsl:template>
+<xsl:template name="section.heading">
+ <xsl:param name="section" select="."/>
+ <xsl:param name="level" select="1"/>
+ <xsl:param name="allow-anchors" select="1"/>
+ <xsl:param name="title"/>
+ <xsl:param name="class" select="'title'"/>
+
+ <xsl:variable name="id">
+ <xsl:choose>
+ <!-- Make sure the subtitle doesn't get the same id as the title -->
+ <xsl:when test="self::d:subtitle">
+ <xsl:call-template name="object.id">
+ <xsl:with-param name="object" select="."/>
+ </xsl:call-template>
+ </xsl:when>
+ <!-- if title is in an *info wrapper, get the grandparent -->
+ <xsl:when test="contains(local-name(..), 'info')">
+ <xsl:call-template name="object.id">
+ <xsl:with-param name="object" select="../.."/>
+ </xsl:call-template>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:call-template name="object.id">
+ <xsl:with-param name="object" select=".."/>
+ </xsl:call-template>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:variable>
+
+ <!-- HTML H level is one higher than section level -->
+ <xsl:variable name="hlevel">
+ <xsl:choose>
+ <!-- Anything nested deeper than 3 levels down becomes H4 -->
+ <xsl:when test="$level &gt; 3">4</xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="$level + 1"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:variable>
+ <xsl:element name="h{$hlevel}">
+ <xsl:attribute name="class"><xsl:value-of select="$class"/></xsl:attribute>
+ <xsl:if test="$css.decoration != '0'">
+ <xsl:if test="$hlevel&lt;3">
+ <xsl:attribute name="style">clear: both</xsl:attribute>
+ </xsl:if>
+ </xsl:if>
+ <xsl:if test="$allow-anchors != 0 and $generate.id.attributes = 0">
+ <xsl:call-template name="anchor">
+ <xsl:with-param name="node" select="$section"/>
+ <xsl:with-param name="conditional" select="0"/>
+ </xsl:call-template>
+ </xsl:if>
+ <xsl:if test="$generate.id.attributes != 0 and not(local-name(.) = 'appendix')">
+ <xsl:attribute name="id"><xsl:value-of select="$id"/></xsl:attribute>
+ </xsl:if>
+ <xsl:copy-of select="$title"/>
+ </xsl:element>
+</xsl:template>
+
<xsl:template match="d:para[@role='warning']">
<xsl:variable name="href">
<xsl:call-template name="relative.path.link">

Back to the top