Debian Codegraph @

docbook-xsl-ns/slides/xhtml/plain-titlepage.xsl

raw symbols SCIP
1 <?xml version="1.0" encoding="UTF-8"?>
2 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:d="http://docbook.org/ns/docbook" xmlns:exsl="http://exslt.org/common" xmlns:dbs="http://docbook.org/ns/docbook-slides" xmlns="http://www.w3.org/1999/xhtml" version="1.0" exclude-result-prefixes="exsl d">
3
4 <!-- This stylesheet was created by template/titlepage.xsl-->
5
6 <xsl:template name="slides.titlepage.recto">
7 <xsl:choose>
8 <xsl:when test="d:slidesinfo/d:title">
9 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:slidesinfo/d:title"/>
10 </xsl:when>
11 <xsl:when test="d:docinfo/d:title">
12 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:docinfo/d:title"/>
13 </xsl:when>
14 <xsl:when test="d:info/d:title">
15 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:info/d:title"/>
16 </xsl:when>
17 <xsl:when test="d:title">
18 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:title"/>
19 </xsl:when>
20 </xsl:choose>
21
22 <xsl:choose>
23 <xsl:when test="d:slidesinfo/d:subtitle">
24 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:slidesinfo/d:subtitle"/>
25 </xsl:when>
26 <xsl:when test="d:docinfo/d:subtitle">
27 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:docinfo/d:subtitle"/>
28 </xsl:when>
29 <xsl:when test="d:info/d:subtitle">
30 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:info/d:subtitle"/>
31 </xsl:when>
32 <xsl:when test="d:subtitle">
33 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:subtitle"/>
34 </xsl:when>
35 </xsl:choose>
36
37 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:slidesinfo/d:corpauthor"/>
38 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:docinfo/d:corpauthor"/>
39 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:info/d:corpauthor"/>
40 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:slidesinfo/d:authorgroup"/>
41 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:docinfo/d:authorgroup"/>
42 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:info/d:authorgroup"/>
43 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:slidesinfo/d:author"/>
44 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:docinfo/d:author"/>
45 <xsl:apply-templates mode="slides.titlepage.recto.auto.mode" select="d:info/d:author"/>
46 </xsl:template>
47
48 <xsl:template name="slides.titlepage.verso">
49 </xsl:template>
50
51 <xsl:template name="slides.titlepage.separator">
52 </xsl:template>
53
54 <xsl:template name="slides.titlepage.before.recto">
55 </xsl:template>
56
57 <xsl:template name="slides.titlepage.before.verso">
58 </xsl:template>
59
60 <xsl:template name="slides.titlepage">
61 <div class="slide cover title">
62 <xsl:variable name="recto.content">
63 <xsl:call-template name="slides.titlepage.before.recto"/>
64 <xsl:call-template name="slides.titlepage.recto"/>
65 </xsl:variable>
66 <xsl:variable name="recto.elements.count">
67 <xsl:choose>
68 <xsl:when test="function-available('exsl:node-set')"><xsl:value-of select="count(exsl:node-set($recto.content)/*)"/></xsl:when>
69 <xsl:when test="contains(system-property('xsl:vendor'), 'Apache Software Foundation')">
70 <!--Xalan quirk--><xsl:value-of select="count(exsl:node-set($recto.content)/*)"/></xsl:when>
71 <xsl:otherwise>1</xsl:otherwise>
72 </xsl:choose>
73 </xsl:variable>
74 <xsl:if test="(normalize-space($recto.content) != '') or ($recto.elements.count &gt; 0)">
75 <div><xsl:copy-of select="$recto.content"/></div>
76 </xsl:if>
77 <xsl:variable name="verso.content">
78 <xsl:call-template name="slides.titlepage.before.verso"/>
79 <xsl:call-template name="slides.titlepage.verso"/>
80 </xsl:variable>
81 <xsl:variable name="verso.elements.count">
82 <xsl:choose>
83 <xsl:when test="function-available('exsl:node-set')"><xsl:value-of select="count(exsl:node-set($verso.content)/*)"/></xsl:when>
84 <xsl:when test="contains(system-property('xsl:vendor'), 'Apache Software Foundation')">
85 <!--Xalan quirk--><xsl:value-of select="count(exsl:node-set($verso.content)/*)"/></xsl:when>
86 <xsl:otherwise>1</xsl:otherwise>
87 </xsl:choose>
88 </xsl:variable>
89 <xsl:if test="(normalize-space($verso.content) != '') or ($verso.elements.count &gt; 0)">
90 <div><xsl:copy-of select="$verso.content"/></div>
91 </xsl:if>
92 <xsl:call-template name="slides.titlepage.separator"/>
93 </div>
94 </xsl:template>
95
96 <xsl:template match="*" mode="slides.titlepage.recto.mode">
97 <!-- if an element isn't found in this mode, -->
98 <!-- try the generic titlepage.mode -->
99 <xsl:apply-templates select="." mode="titlepage.mode"/>
100 </xsl:template>
101
102 <xsl:template match="*" mode="slides.titlepage.verso.mode">
103 <!-- if an element isn't found in this mode, -->
104 <!-- try the generic titlepage.mode -->
105 <xsl:apply-templates select="." mode="titlepage.mode"/>
106 </xsl:template>
107
108 <xsl:template match="d:title" mode="slides.titlepage.recto.auto.mode">
109 <div xsl:use-attribute-sets="slides.titlepage.recto.style">
110 <xsl:apply-templates select="." mode="slides.titlepage.recto.mode"/>
111 </div>
112 </xsl:template>
113
114 <xsl:template match="d:subtitle" mode="slides.titlepage.recto.auto.mode">
115 <div xsl:use-attribute-sets="slides.titlepage.recto.style">
116 <xsl:apply-templates select="." mode="slides.titlepage.recto.mode"/>
117 </div>
118 </xsl:template>
119
120 <xsl:template match="d:corpauthor" mode="slides.titlepage.recto.auto.mode">
121 <div xsl:use-attribute-sets="slides.titlepage.recto.style">
122 <xsl:apply-templates select="." mode="slides.titlepage.recto.mode"/>
123 </div>
124 </xsl:template>
125
126 <xsl:template match="d:authorgroup" mode="slides.titlepage.recto.auto.mode">
127 <div xsl:use-attribute-sets="slides.titlepage.recto.style">
128 <xsl:apply-templates select="." mode="slides.titlepage.recto.mode"/>
129 </div>
130 </xsl:template>
131
132 <xsl:template match="d:author" mode="slides.titlepage.recto.auto.mode">
133 <div xsl:use-attribute-sets="slides.titlepage.recto.style">
134 <xsl:apply-templates select="." mode="slides.titlepage.recto.mode"/>
135 </div>
136 </xsl:template>
137
138 </xsl:stylesheet>