3 <!-- Copyright (C) 2000, HELM Team -->
5 <!-- This file is part of HELM, an Hypertextual, Electronic -->
6 <!-- Library of Mathematics, developed at the Computer Science -->
7 <!-- Department, University of Bologna, Italy. -->
9 <!-- HELM is free software; you can redistribute it and/or -->
10 <!-- modify it under the terms of the GNU General Public License -->
11 <!-- as published by the Free Software Foundation; either version 2 -->
12 <!-- of the License, or (at your option) any later version. -->
14 <!-- HELM is distributed in the hope that it will be useful, -->
15 <!-- but WITHOUT ANY WARRANTY; without even the implied warranty of -->
16 <!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -->
17 <!-- GNU General Public License for more details. -->
19 <!-- You should have received a copy of the GNU General Public License -->
20 <!-- along with HELM; if not, write to the Free Software -->
21 <!-- Foundation, Inc., 59 Temple Place - Suite 330, Boston, -->
22 <!-- MA 02111-1307, USA. -->
24 <!-- For details, see the HELM World-Wide-Web page, -->
25 <!-- http://cs.unibo.it/helm/. -->
27 <xsl:stylesheet version="0.1" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
28 xmlns:ht="http://www.cs.unibo.it/helm/namespaces/helm-theory">
30 <!-- ALL REQUIRED PARAMS ARE ALREADY DEFINED INSIDE links_library.xsl -->
32 <!-- <xsl:import href="links_library.xsl"/> -->
34 <xsl:template match="/">
37 <body bgcolor="white">
38 <xsl:apply-templates/>
43 <xsl:template match="occurs">
44 <xsl:variable name="no_main" select="count(main)"/>
45 <xsl:variable name="no_concl" select="count(in_conclusion)"/>
46 <xsl:variable name="no_main_hyp" select="count(main_hypothesis)"/>
47 <xsl:variable name="no_in_hyp" select="count(in_hypothesis)"/>
48 <xsl:variable name="no_body" select="count(in_body)"/>
49 <h1>Occurrences of <xsl:value-of select="@who"/></h1>
52 <xsl:if test="$no_main != 0">
53 <li><a href ="#main">Head position in conclusion
54 (<xsl:value-of select="$no_main"/>)</a></li>
56 <xsl:if test="$no_concl != 0">
57 <li><a href ="#concl">In conclusion
58 (<xsl:value-of select="$no_concl"/>)</a></li>
60 <xsl:if test="$no_main_hyp != 0">
61 <li><a href ="#main_hyp">Head position in some hypothesis
62 (<xsl:value-of select="$no_main_hyp"/>)</a></li>
64 <xsl:if test="$no_in_hyp != 0">
65 <li><a href ="#hyp">In hypotheses
66 (<xsl:value-of select="$no_in_hyp"/>)</a></li>
68 <xsl:if test="$no_body != 0">
69 <li><a href ="#body">In the body
70 (<xsl:value-of select="$no_body"/>)</a></li>
74 <xsl:when test="$no_main = 0"/>
75 <xsl:when test="15 > $no_main">
76 <h2><a name="main">Head position inside conclusion:</a></h2>
77 <xsl:for-each select="main">
78 <div style="margin: 0.25cm 0cm 0.25cm 0.75cm">
79 <ht:OBJECT uri="{@uri}" mode="typeonly"/>
83 <xsl:when test="$no_main >= 15">
84 <h2><a name="main">Head position inside conclusion:</a></h2>
85 <xsl:for-each select="main">
86 <div style="margin: 0cm 0cm 0cm 0.75cm">
87 <ht:OBJECT uri="{@uri}" mode="linkonly"/>
93 <xsl:when test="$no_concl = 0"/>
94 <xsl:when test="15 > $no_concl">
95 <h2><a name="concl">Inside conclusion:</a></h2>
96 <xsl:for-each select="in_conclusion">
97 <div style="margin: 0.25cm 0cm 0.25cm 0.75cm">
98 <ht:OBJECT uri="{@uri}" mode="typeonly"/>
102 <xsl:when test="$no_concl >= 15">
103 <h2><a name="concl">Inside conclusion:</a></h2>
104 <xsl:for-each select="in_conclusion">
105 <div style="margin: 0cm 0cm 0cm 0.75cm">
106 <ht:OBJECT uri="{@uri}" mode="linkonly"/>
112 <xsl:when test="$no_main_hyp = 0"/>
113 <xsl:when test="15 > $no_main_hyp">
114 <h2><a name="main_hyp">Head position inside an hypothesis:</a></h2>
115 <xsl:for-each select="main_hypothesis">
116 <div style="margin: 0.25cm 0cm 0.25cm 0.75cm">
117 <ht:OBJECT uri="{@uri}" mode="typeonly"/>
121 <xsl:when test="$no_main_hyp >= 15">
122 <h2><a name="main_hyp">Head position inside an hypothesis:</a></h2>
123 <xsl:for-each select="main_hypothesis">
124 <div style="margin: 0cm 0cm 0cm 0.75cm">
125 <ht:OBJECT uri="{@uri}" mode="linkonly"/>
131 <xsl:when test="$no_in_hyp = 0"/>
132 <xsl:when test="15 > $no_in_hyp">
133 <h2><a name="hyp">Inside an hypothesis:</a></h2>
134 <xsl:for-each select="in_hypothesis">
135 <div style="margin: 0.25cm 0cm 0.25cm 0.75cm">
136 <ht:OBJECT uri="{@uri}" mode="typeonly"/>
140 <xsl:when test="$no_in_hyp >= 15">
141 <h2><a name="hyp">Inside an hypothesis:</a></h2>
142 <xsl:for-each select="in_hypothesis">
143 <div style="margin: 0cm 0cm 0cm 0.75cm">
144 <ht:OBJECT uri="{@uri}" mode="linkonly"/>
149 <xsl:if test="in_body">
150 <h2><a name="body">Inside the body:</a></h2>
151 <xsl:for-each select="in_body">
152 <div style="margin: 0cm 0cm 0cm 0.75cm">
153 <ht:OBJECT uri="{@uri}" mode="linkonly"/>
160 <xsl:template match="occurs">
162 <h2>Head position inside conclusion:</h2>
163 <xsl:for-each select="main">
164 <div style="margin: 0.25cm 0cm 0.25cm 0.75cm">
165 <ht:OBJECT uri="{@uri}" mode="typeonly"/>
169 <xsl:if test="in_conclusion">
170 <h2>Inside conclusion:</h2>
171 <xsl:for-each select="in_conclusion">
172 <div style="margin: 0.25cm 0cm 0.25cm 0.75cm">
173 <ht:OBJECT uri="{@uri}" mode="typeonly"/>
177 <xsl:if test="main_hypothesis">
178 <h2>Head position inside an hypothesis:</h2>
179 <xsl:for-each select="main_hypothesis">
180 <div style="margin: 0.25cm 0cm 0.25cm 0.75cm">
181 <ht:OBJECT uri="{@uri}" mode="typeonly"/>
185 <xsl:if test="in_hypothesis">
186 <h2>Inside an hypothesis:</h2>
187 <xsl:for-each select="in_hypothesis">
188 <div style="margin: 0.25cm 0cm 0.25cm 0.75cm">
189 <ht:OBJECT uri="{@uri}" mode="typeonly"/>
193 <xsl:if test="in_body">
194 <h2>Inside the body:</h2>
195 <xsl:for-each select="in_body">
196 <div style="margin: 0cm 0cm 0cm 0.75cm">
197 <ht:OBJECT uri="{@uri}" mode="linkonly"/>