Browse Source

externalise gettext functions, remove unnessesary import rules

svn path=/branches/test/; revision=30913
tags/stw2018
paul 4 years ago
parent
commit
78ea515b2e

+ 0
- 2
activities/education/education.xsl View File

@@ -4,9 +4,7 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../../tools/xsltsl/countries.xsl" />
9
-  <xsl:import href="../../tools/xsltsl/translations.xsl" />
10 8
   <xsl:import href="../../fsfe.xsl" />
11 9
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
12 10
 

+ 0
- 2
activities/ftf/avm-gpl-violation.xsl View File

@@ -2,8 +2,6 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../../tools/xsltsl/tagging.xsl" />
6
-  
7 5
   <xsl:import href="../../fsfe.xsl" />
8 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
9 7
 

+ 0
- 2
activities/os/os.xsl View File

@@ -2,8 +2,6 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../../tools/xsltsl/tagging.xsl" />
6
-  
7 5
   <xsl:import href="../../fsfe.xsl" />
8 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
9 7
   

+ 0
- 2
at/at.xsl View File

@@ -4,9 +4,7 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../tools/xsltsl/countries.xsl" />
9
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
10 8
   <xsl:import href="../fsfe.xsl" />
11 9
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
12 10
 

+ 26
- 0
build/xslt/gettext.xsl View File

@@ -0,0 +1,26 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+
3
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4
+  
5
+  <!-- this template is to be called to get texts contained in "tools/texts-xx.xml" files -->
6
+  <xsl:template name="fsfe-gettext">
7
+    <xsl:param name="id" />
8
+    
9
+    <xsl:choose>
10
+      <xsl:when test="/buildinfo/textset/text[@id=$id]">
11
+        <xsl:apply-templates select="/buildinfo/textset/text[@id=$id]/node()" />
12
+      </xsl:when>
13
+      <xsl:otherwise>
14
+        <xsl:apply-templates select="/buildinfo/textsetbackup/text[@id=$id]/node()" />
15
+      </xsl:otherwise>
16
+    </xsl:choose>
17
+    
18
+  </xsl:template>
19
+  
20
+  <!-- this template is to be called to get texts contained in "tools/texts-content-xx.xml" files -->
21
+  <xsl:template name="gettext">
22
+    <xsl:param name="id" />
23
+    <xsl:value-of select="/buildinfo/textset/text[@id=$id] |
24
+                          /buildinfo/textsetbackup/text[ @id=$id and not(@id=/buildinfo/textset/text/@id) ]"/>
25
+  </xsl:template>
26
+</xsl:stylesheet>

+ 0
- 2
campaigns/askyourcandidates/askyourcandidates.xsl View File

@@ -2,8 +2,6 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../../tools/xsltsl/tagging.xsl" />
6
-  
7 5
   <xsl:import href="../../fsfe.xsl" />
8 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
9 7
   

+ 0
- 2
campaigns/ilovefs/2012/ilovefs.xsl View File

@@ -2,8 +2,6 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../../../tools/xsltsl/tagging.xsl" />
6
-  
7 5
   <xsl:import href="../../../fsfe.xsl" />
8 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
9 7
   

+ 0
- 2
campaigns/ilovefs/2012/unperfekthaus.xsl View File

@@ -2,8 +2,6 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../../../tools/xsltsl/tagging.xsl" />
6
-  
7 5
   <xsl:import href="../../../fsfe.xsl" />
8 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
9 7
   

+ 0
- 2
campaigns/ilovefs/2013/ilovefs.xsl View File

@@ -2,8 +2,6 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../../../tools/xsltsl/tagging.xsl" />
6
-  
7 5
   <xsl:import href="../../../fsfe.xsl" />
8 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
9 7
   

+ 0
- 2
campaigns/ilovefs/2014/ilovefs.xsl View File

@@ -2,8 +2,6 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../../../tools/xsltsl/tagging.xsl" />
6
-  
7 5
   <xsl:import href="../../../fsfe.xsl" />
8 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
9 7
   

+ 0
- 2
campaigns/nledu/nledu.xsl View File

@@ -2,8 +2,6 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../../tools/xsltsl/tagging.xsl" />
6
-  
7 5
   <xsl:import href="../../fsfe.xsl" />
8 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
9 7
   

+ 0
- 2
de/de.xsl View File

@@ -4,9 +4,7 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../tools/xsltsl/countries.xsl" />
9
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
10 8
   <xsl:import href="../fsfe.xsl" />
11 9
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
12 10
 

+ 1
- 1
drm.info/xslt/drm_info_body.xsl View File

@@ -9,9 +9,9 @@
9 9
   <xsl:include href="../../build/xslt/footer_sitenav.xsl" />
10 10
   <xsl:include href="../../build/xslt/footer_sourcelink.xsl" />
11 11
   <xsl:include href="../../build/xslt/footer_legal.xsl" />
12
+  <xsl:include href="../../build/xslt/gettext.xsl" />
12 13
 
13 14
   <xsl:include href="../../tools/xsltsl/static-elements.xsl" />
14
-  <xsl:include href="../../tools/xsltsl/translations.xsl" />
15 15
 
16 16
   <xsl:template name="page-body">
17 17
     <xsl:element name="body">

+ 0
- 2
ee/ee.xsl View File

@@ -4,9 +4,7 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../tools/xsltsl/countries.xsl" />
9
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
10 8
   <xsl:import href="../fsfe.xsl" />
11 9
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
12 10
 

+ 0
- 1
events/events.xsl View File

@@ -4,7 +4,6 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
 
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../fsfe.xsl" />
9 8
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
10 9
   

+ 1
- 1
fellowship/default.xsl View File

@@ -6,7 +6,7 @@
6 6
   xmlns:str="http://exslt.org/strings"
7 7
   extension-element-prefixes="str">
8 8
 
9
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
9
+  <xsl:import href="../build/xslt/gettext.xsl" />
10 10
   <xsl:import href="../tools/xsltsl/static-elements.xsl" />
11 11
 
12 12
   <!-- HTML 5 compatibility doctype, since our XSLT parser doesn't support disabling output escaping -->

+ 0
- 1
fellowship/index.xsl View File

@@ -4,7 +4,6 @@
4 4
   <xsl:import href="default.xsl" />
5 5
   <xsl:import href="xsl/quotes.xsl" />
6 6
   <xsl:import href="../tools/xsltsl/tagging.xsl" />
7
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
8 7
 
9 8
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
10 9
 

+ 0
- 1
fellowship/testimonials.xsl View File

@@ -4,7 +4,6 @@
4 4
   <xsl:import href="default.xsl" />
5 5
   <xsl:import href="xsl/quotes.xsl" />
6 6
   <xsl:import href="../tools/xsltsl/tagging.xsl" />
7
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
8 7
 
9 8
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
10 9
 

+ 0
- 2
fi/fi.xsl View File

@@ -4,9 +4,7 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../tools/xsltsl/countries.xsl" />
9
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
10 8
   <xsl:import href="../fsfe.xsl" />
11 9
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
12 10
 

+ 0
- 2
fr/fr.xsl View File

@@ -4,9 +4,7 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../tools/xsltsl/countries.xsl" />
9
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
10 8
   <xsl:import href="../fsfe.xsl" />
11 9
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
12 10
 

+ 1
- 1
fsfe.xsl View File

@@ -6,7 +6,7 @@
6 6
   xmlns:str="http://exslt.org/strings"
7 7
   extension-element-prefixes="str">
8 8
 
9
-  <xsl:import href="tools/xsltsl/translations.xsl" />
9
+  <xsl:import href="build/xslt/gettext.xsl" />
10 10
   <xsl:import href="tools/xsltsl/static-elements.xsl" />
11 11
   <xsl:import href="tools/xsltsl/tagging.xsl" />
12 12
 

+ 0
- 2
ilovefstest/2013/ilovefs.xsl View File

@@ -2,8 +2,6 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../../tools/xsltsl/tagging.xsl" />
6
-  
7 5
   <xsl:import href="../../fsfe.xsl" />
8 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
9 7
   

+ 1
- 3
index.xsl View File

@@ -2,11 +2,9 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="tools/xsltsl/tagging.xsl" />
6
-  <xsl:import href="tools/xsltsl/translations.xsl" />
7 5
   <xsl:import href="tools/xsltsl/static-elements.xsl" />
8
-  
9 6
   <xsl:import href="fsfe.xsl" />
7
+
10 8
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
11 9
   
12 10
   <xsl:template match="body">

+ 0
- 2
it/it.xsl View File

@@ -4,9 +4,7 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../tools/xsltsl/countries.xsl" />
9
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
10 8
   <xsl:import href="../fsfe.xsl" />
11 9
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
12 10
 

+ 0
- 1
news/legal-news.xsl View File

@@ -1,7 +1,6 @@
1 1
 <?xml version="1.0" encoding="UTF-8"?>
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
5 4
   
6 5
   <xsl:import href="../fsfe.xsl" />
7 6
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />

+ 1
- 2
news/newsletter.xsl View File

@@ -2,10 +2,9 @@
2 2
 
3 3
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4 4
   
5
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
6 5
   <xsl:import href="../tools/xsltsl/static-elements.xsl" />
7
-  
8 6
   <xsl:import href="../fsfe.xsl" />
7
+
9 8
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
10 9
 
11 10
   <xsl:template match="body">

+ 1
- 1
pdfreaders/xslt/pdfreaders_body.xsl View File

@@ -9,9 +9,9 @@
9 9
   <xsl:include href="../../build/xslt/footer_sitenav.xsl" />
10 10
   <xsl:include href="../../build/xslt/footer_sourcelink.xsl" />
11 11
   <xsl:include href="../../build/xslt/footer_legal.xsl" />
12
+  <xsl:include href="../../build/xslt/gettext.xsl" />
12 13
 
13 14
   <xsl:include href="../../tools/xsltsl/static-elements.xsl" />
14
-  <xsl:include href="../../tools/xsltsl/translations.xsl" />
15 15
 
16 16
   <xsl:template name="page-body">
17 17
     <xsl:element name="body">

+ 1
- 1
support/default.xsl View File

@@ -4,7 +4,7 @@
4 4
   xmlns:str="http://exslt.org/strings"
5 5
   extension-element-prefixes="str">
6 6
 
7
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
7
+  <xsl:import href="../build/xslt/gettext.xsl" />
8 8
   <xsl:import href="../tools/xsltsl/static-elements.xsl" />
9 9
   <xsl:import href="../tools/xsltsl/tagging.xsl" />
10 10
 

+ 0
- 1
tags/tagged.xsl View File

@@ -4,7 +4,6 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../fsfe.xsl" />
9 8
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
10 9
   

+ 0
- 1
tags/tags.xsl View File

@@ -4,7 +4,6 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../fsfe.xsl" />
9 8
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
10 9
   

+ 0
- 142
tools/xsltsl/quotes.xsl View File

@@ -1,142 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-
3
-<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4
-  
5
-  <xsl:import href="translations.xsl" />
6
-  
7
-  <xsl:output method="xml" encoding="UTF-8" indent="yes" />
8
-  
9
-  <xsl:template name="quote-box">
10
-    <xsl:param name="tag" select="''"/> <!-- if left empty, all quotes will be selected -->
11
-    
12
-    <div id="cb1-back">
13
-      <xsl:call-template name="first-quote">
14
-        <xsl:with-param name="tag" select="$tag" />
15
-      </xsl:call-template>
16
-    </div>
17
-    
18
-    <div id="cb1-front">
19
-      <!-- -->
20
-    </div>
21
-    
22
-    <!-- javascript code for rotating quotes -->
23
-    <script type="text/javascript">
24
-      
25
-      var quotes = [
26
-        <xsl:choose>
27
-          <xsl:when test="count(/buildinfo/textset/quotes/quote[@tag=$tag or $tag=''])>0">
28
-            <xsl:call-template name="get-js-quotes">
29
-              <xsl:with-param name="quotes-xpath" select="/buildinfo/textset/quotes/quote[@tag=$tag or $tag='']" />
30
-            </xsl:call-template>
31
-          </xsl:when>
32
-          <xsl:otherwise>
33
-            <xsl:call-template name="get-js-quotes">
34
-              <xsl:with-param name="quotes-xpath" select="/buildinfo/textsetbackup/quotes/quote[@tag=$tag or $tag='']" />
35
-            </xsl:call-template>
36
-          </xsl:otherwise>
37
-        </xsl:choose>
38
-      ];
39
-      
40
-      var index = 0;
41
-      function changeImage () {
42
-        
43
-        var oldIndex = index;
44
-        index = (index+1)%quotes.length;
45
-        
46
-        var newContent = 
47
-          "&lt;a href='/join/join.html'&gt;" +
48
-          "&lt;img src='"+quotes[index]['photo']+"' /&gt;" +
49
-          "&lt;p&gt;"+quotes[index]['text']+"&lt;br/&gt;"+
50
-          "&lt;strong&gt;"+quotes[index]['author']+"&lt;/strong&gt;&lt;/p&gt;"+
51
-          "&lt;/a&gt;";
52
-        
53
-        $('#cb1-front').html($('#cb1-back').html());
54
-        $('#cb1-front').fadeIn(0);
55
-        
56
-        $('#cb1-back').fadeOut(0);
57
-        $('#cb1-back').html(newContent);
58
-        
59
-        $('#cb1-front').fadeOut('slow', function() {
60
-          $('#cb1-back').fadeIn('slow', function() {});
61
-        });
62
-        
63
-        setTimeout("changeImage();",10000);
64
-        
65
-      }
66
-      
67
-      setTimeout("changeImage();",10000);
68
-    </script>
69
-    
70
-  </xsl:template>
71
-  
72
-  
73
-  <xsl:template name="get-js-quotes">
74
-    <xsl:param name="quotes-xpath" />
75
-    
76
-    <xsl:for-each select="$quotes-xpath">
77
-      <xsl:sort select="@pos" data-type="number" />
78
-      {
79
-        'photo':  "<xsl:call-template name="get-quote-photo"><xsl:with-param name="id" select="@id" /></xsl:call-template>",
80
-        'text':   "<xsl:call-template name="get-quote-text-escaped"><xsl:with-param name="id" select="@id" /></xsl:call-template>",
81
-        'author': "<xsl:call-template name="get-quote-author-escaped"><xsl:with-param name="id" select="@id" /></xsl:call-template>"
82
-      },
83
-    </xsl:for-each>
84
-    
85
-  </xsl:template>
86
-  
87
-  
88
-  <xsl:template name="first-quote">
89
-    <xsl:param name="tag" />
90
-    
91
-    <xsl:choose>
92
-      <xsl:when test="count(/buildinfo/textset/quotes/quote[@tag=$tag or $tag=''])>0">
93
-        <xsl:call-template name="display-first-quote">
94
-          <xsl:with-param name="quotes-xpath" select="/buildinfo/textset/quotes/quote[@tag=$tag or $tag='']" />
95
-        </xsl:call-template>
96
-      </xsl:when>
97
-      <xsl:otherwise >
98
-        <xsl:call-template name="display-first-quote">
99
-          <xsl:with-param name="quotes-xpath" select="/buildinfo/textsetbackup/quotes/quote[@tag=$tag or $tag='']" />
100
-        </xsl:call-template>
101
-      </xsl:otherwise>
102
-    </xsl:choose>
103
-    
104
-  </xsl:template>
105
-  
106
-  
107
-  <xsl:template name="display-first-quote">
108
-    <xsl:param name="quotes-xpath" />
109
-    
110
-    <xsl:for-each select="$quotes-xpath">
111
-      <xsl:sort select="@pos" data-type="number" />
112
-      
113
-      <xsl:if test="position() = 1">
114
-        
115
-        <a href="/join/join.html">
116
-          <xsl:element name="img">
117
-            <xsl:attribute name="src">
118
-              <xsl:call-template name="get-quote-photo">
119
-                <xsl:with-param name="id" select="@id" />
120
-              </xsl:call-template>
121
-            </xsl:attribute>
122
-          </xsl:element>
123
-          <p>
124
-            <xsl:call-template name="get-quote-text">
125
-              <xsl:with-param name="id" select="@id" />
126
-            </xsl:call-template>
127
-            <br/>
128
-            <strong>
129
-              <xsl:call-template name="get-quote-author">
130
-                <xsl:with-param name="id" select="@id" />
131
-              </xsl:call-template>
132
-            </strong>
133
-          </p>
134
-        </a>
135
-        
136
-      </xsl:if>
137
-      
138
-    </xsl:for-each>
139
-    
140
-  </xsl:template>
141
-  
142
-</xsl:stylesheet>

+ 0
- 102
tools/xsltsl/translations.xsl View File

@@ -28,106 +28,4 @@
28 28
                             /buildinfo/textsetbackup/text[ @id=$id and not(@id=/buildinfo/textset/text/@id) ]"/>
29 29
       
30 30
     </xsl:template>
31
-    
32
-    <!-- this template is to be called to get the text of _quotes_ contained in "tools/texts-xx.xml" files -->
33
-    <xsl:template name="get-quote-text">
34
-      <xsl:param name="id" />
35
-      
36
-      <xsl:choose>
37
-        <xsl:when test="/buildinfo/textset/quotes/quote[@id=$id]/txt">
38
-          <xsl:value-of select="normalize-space(/buildinfo/textset/quotes/quote[@id=$id]/txt)"/>
39
-        </xsl:when>
40
-        <xsl:otherwise>
41
-          <xsl:value-of select="normalize-space(/buildinfo/textsetbackup/quotes/quote[@id=$id]/txt)"/>
42
-        </xsl:otherwise>
43
-      </xsl:choose>
44
-      
45
-    </xsl:template>
46
-
47
-    <!-- this template is to be called to get the text of _quotes_ contained in "tools/texts-xx.xml" files -->
48
-    <xsl:template name="get-quote-text-escaped">
49
-      <xsl:param name="id" />
50
-      
51
-      <xsl:choose>
52
-        <xsl:when test="/buildinfo/textset/quotes/quote[@id=$id]/txt">
53
-          <xsl:call-template name="escapeQuote">
54
-            <xsl:with-param name="pText" select="normalize-space(/buildinfo/textset/quotes/quote[@id=$id]/txt)"/>
55
-          </xsl:call-template>
56
-        </xsl:when>
57
-        <xsl:otherwise>
58
-          <xsl:call-template name="escapeQuote">
59
-            <xsl:with-param name="pText" select="normalize-space(/buildinfo/textsetbackup/quotes/quote[@id=$id]/txt)"/>
60
-          </xsl:call-template>
61
-        </xsl:otherwise>
62
-      </xsl:choose>
63
-      
64
-    </xsl:template>
65
-    
66
-    <!-- this template is to be called to get the image of _quotes_ contained in "tools/texts-xx.xml" files -->
67
-    <xsl:template name="get-quote-photo">
68
-      <xsl:param name="id" />
69
-      
70
-      <xsl:choose>
71
-        <xsl:when test="/buildinfo/textset/quotes/quote[@id=$id]/photo">
72
-          <xsl:value-of select="normalize-space(/buildinfo/textset/quotes/quote[@id=$id]/photo)" />
73
-        </xsl:when>
74
-        <xsl:otherwise>
75
-          <xsl:value-of select="normalize-space(/buildinfo/textsetbackup/quotes/quote[@id=$id]/photo)" />
76
-        </xsl:otherwise>
77
-      </xsl:choose>
78
-      
79
-    </xsl:template>
80
-    
81
-    <!-- this template is to be called to get the author's nam of _quotes_ contained in "tools/texts-xx.xml" files -->
82
-    <xsl:template name="get-quote-author">
83
-      <xsl:param name="id" />
84
-      
85
-      <xsl:choose>
86
-        <xsl:when test="/buildinfo/textset/quotes/quote[@id=$id]/author">
87
-          <xsl:value-of select="normalize-space(/buildinfo/textset/quotes/quote[@id=$id]/author)"/>
88
-        </xsl:when>
89
-        <xsl:otherwise>
90
-          <xsl:value-of select="normalize-space(/buildinfo/textsetbackup/quotes/quote[@id=$id]/author)"/>
91
-        </xsl:otherwise>
92
-      </xsl:choose>
93
-      
94
-    </xsl:template>
95
-
96
-    <xsl:template name="get-quote-author-escaped">
97
-      <xsl:param name="id" />
98
-      
99
-      <xsl:choose>
100
-        <xsl:when test="/buildinfo/textset/quotes/quote[@id=$id]/author">
101
-          <xsl:call-template name="escapeQuote">
102
-            <xsl:with-param name="pText" select="normalize-space(/buildinfo/textset/quotes/quote[@id=$id]/author)"/>
103
-          </xsl:call-template>
104
-        </xsl:when>
105
-        <xsl:otherwise>
106
-          <xsl:call-template name="escapeQuote">
107
-            <xsl:with-param name="pText" select="normalize-space(/buildinfo/textsetbackup/quotes/quote[@id=$id]/author)"/>
108
-          </xsl:call-template>
109
-        </xsl:otherwise>
110
-      </xsl:choose>
111
-      
112
-    </xsl:template>
113
-
114
-
115
-   <xsl:template name="escapeQuote">
116
-      <xsl:param name="pText" select="."/>
117
-
118
-      <xsl:if test="string-length($pText) >0">
119
-       <xsl:value-of select=
120
-        "substring-before(concat($pText, '&quot;'), '&quot;')"/>
121
-
122
-       <xsl:if test="contains($pText, '&quot;')">
123
-        <xsl:text>\"</xsl:text>
124
-
125
-        <xsl:call-template name="escapeQuote">
126
-          <xsl:with-param name="pText" select=
127
-          "substring-after($pText, '&quot;')"/>
128
-        </xsl:call-template>
129
-       </xsl:if>
130
-      </xsl:if>
131
-    </xsl:template>
132
-
133 31
 </xsl:stylesheet>

+ 0
- 2
uk/uk.xsl View File

@@ -4,9 +4,7 @@
4 4
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 5
   xmlns:dt="http://xsltsl.org/date-time">
6 6
   
7
-  <xsl:import href="../tools/xsltsl/tagging.xsl" />
8 7
   <xsl:import href="../tools/xsltsl/countries.xsl" />
9
-  <xsl:import href="../tools/xsltsl/translations.xsl" />
10 8
   <xsl:import href="../fsfe.xsl" />
11 9
   <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
12 10
 

Loading…
Cancel
Save