View | Details | Raw Unified | Return to bug 53764
Collapse All | Expand All

(-)a/build.xml (+26 lines)
Lines 2293-2298 run JMeter unless all the JMeter jars are added. Link Here
2293
    </javadoc>
2293
    </javadoc>
2294
</target>
2294
</target>
2295
  <target name="docs-newsite" depends="init-docs" description="Generate browsable HTML documentation in web-site format.">
2296
    <mkdir dir="docs-new" />
2297
    <xslt style="xdocs/stylesheets/website-style.xsl" basedir="${src.docs}" destdir="docs-new"
2298
      excludes="extending.xml" includes="*.xml">
2299
      <param name="relative-path" expression="." />
2300
      <param name="subdir" expression="" />
2301
      <param name="year" expression="${year}" />
2302
    </xslt>
2303
    <xslt style="xdocs/stylesheets/website-style.xsl" basedir="${src.docs}/usermanual" destdir="docs-new/usermanual"
2304
      excludes="extending.xml" includes="*.xml">
2305
      <param name="relative-path" expression=".." />
2306
      <param name="subdir" expression="usermanual" />
2307
      <param name="year" expression="${year}" />
2308
    </xslt>
2309
    <copy todir="docs-new/images">
2310
      <fileset dir="${src.images}" excludes="logo.xcf,logo.svg"/>
2311
    </copy>
2312
    <copy todir="docs-new/css">
2313
      <fileset dir="${src.css}"/>
2314
    </copy>
2315
    <echo level="info">Remove superfluos &amp;amp;</echo>
2316
    <replace encoding="iso-8859-1" dir="docs-new" includes="**/*.html" token="&amp;amp;" value="&amp;"/>
2317
    <echo level="info">Removing unnecessary &lt;/br> tags</echo>
2318
    <replace encoding="iso-8859-1" dir="${dest.docs}/" includes="**/*.html" token="&lt;/br>" value=""/>
2319
  </target>
2320
2295
  <target name="docs-site" depends="init-docs" if="AnakiaTask.present" description="Generate browsable HTML documentation in web-site format.">
2321
  <target name="docs-site" depends="init-docs" if="AnakiaTask.present" description="Generate browsable HTML documentation in web-site format.">
2296
    <taskdef name="anakia" classpathref="anakia.classpath" classname="org.apache.velocity.anakia.AnakiaTask"/>
2322
    <taskdef name="anakia" classpathref="anakia.classpath" classname="org.apache.velocity.anakia.AnakiaTask"/>
2297
    <!-- The extending pages are rather out of date (and not linked from elsewhere) -->
2323
    <!-- The extending pages are rather out of date (and not linked from elsewhere) -->
(-)a/xdocs/css/new-style.css (+367 lines)
Line 0 Link Here
1
/*
2
   Licensed to the Apache Software Foundation (ASF) under one or more
3
   contributor license agreements.  See the NOTICE file distributed with
4
   this work for additional information regarding copyright ownership.
5
   The ASF licenses this file to You under the Apache License, Version 2.0
6
   (the "License"); you may not use this file except in compliance with
7
   the License.  You may obtain a copy of the License at
8
9
       http://www.apache.org/licenses/LICENSE-2.0
10
11
   Unless required by applicable law or agreed to in writing, software
12
   distributed under the License is distributed on an "AS IS" BASIS,
13
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
   See the License for the specific language governing permissions and
15
   limitations under the License.
16
*/
17
.main {
18
  font-family: DejaVu Sans;
19
  width: 60em;
20
}
21
22
img {
23
  border: 0;
24
}
25
26
.menu, h1, h2, h3, h4, h5, .go-top, .title {
27
  font-family: "Special Elite";
28
}
29
30
h1, h2, h3, h4, h5, .title {
31
  border-bottom: 0.2rem solid orange;
32
}
33
34
.title>.title {
35
  border-bottom: 0px;
36
}
37
38
.footer {
39
  background-color: #444;
40
  border-top: 1px solid black;
41
  color: white;
42
  margin-top: 3em;
43
  padding: 2em 0 1em;
44
  text-align: center;
45
  box-shadow: 0 -8px 21px 0 rgba(0, 0, 0, 0.2);
46
}
47
48
.menu {
49
  border: 1px solid lightgray;
50
  box-shadow: 5px 5px 10px rgba(20, 20, 20, 0.3);
51
  list-style: outside none none;
52
  margin: 0.5em;
53
  padding: 0.5em;
54
}
55
56
.menu+.menu {
57
  margin-top: 1.5em;
58
}
59
60
.menu img {
61
  margin-left: 0.3em;
62
  vertical-align: middle;
63
}
64
65
.banner>iframe {
66
  width: 140px;
67
}
68
69
body {
70
  margin: 0px;
71
  padding: 0px;
72
}
73
74
.section
75
          pre {
76
  background: none repeat scroll 0 0 lightblue;
77
  border: 1px solid gray;
78
  padding: 0.3rem;
79
  margin: 0.3rem;
80
  font-family: dejavu sans mono;
81
  overflow: auto;
82
  font-family: dejavu sans mono;
83
}
84
85
.code {
86
  background: none repeat scroll 0 0 lightblue;
87
  padding: 0.1em;
88
  font-family: dejavu sans mono;
89
}
90
91
.required-Yes>span {
92
  font-weight: bold;
93
}
94
95
.deprecated, .note {
96
  background: none repeat scroll 0 0 #fee;
97
  border: 1px solid #dbb;
98
  margin: 1em;
99
  padding: 1em;
100
}
101
102
.component {
103
  background: none repeat scroll 0 0 #fff;
104
  margin: 1em;
105
  padding: 0.4em;
106
}
107
108
.subsection {
109
  background: none repeat scroll 0 0 white;
110
  margin: 1em;
111
  padding: 1em;
112
}
113
114
.screenshot {
115
  margin: 2em;
116
  padding: 0;
117
}
118
119
.figure {
120
  margin: 1em 2em;
121
}
122
123
.figure>a>img, .screenshot>a>img {
124
  box-shadow: 10px 10px 10px 0 rgba(50, 50, 50, 0.25);
125
  overflow: auto;
126
}
127
128
.img-too-big {
129
  width: 100%;
130
}
131
132
.clear {
133
  clear: both;
134
}
135
136
.nostyle {
137
  border: 1px solid black;
138
}
139
140
.title {
141
  font-size: 120%;
142
  font-weight: bold;
143
}
144
145
.example {
146
  background: none repeat scroll 0 0 lightgray;
147
  border: 1px solid gray;
148
  clear: both;
149
  padding: 1em;
150
  margin: 1em;
151
}
152
153
.property .name, .property
154
          .description, .property
155
          .required {
156
  display: inline-block;
157
}
158
159
.property .name {
160
  font-style: italic;
161
  vertical-align: top;
162
  width: 20%;
163
}
164
165
.property .description {
166
  vertical-align: top;
167
  width: 60%;
168
}
169
170
.property .required {
171
  vertical-align: top;
172
  width: 20%;
173
}
174
175
.property+.property {
176
  margin-top: 0.5em;
177
}
178
179
.required.req-false {
180
  font-weight: lighter;
181
}
182
183
.go-top {
184
  margin: 1em 0;
185
  font-size: 120%;
186
}
187
188
.properties {
189
  background: none repeat scroll 0 0 lightgoldenrodyellow;
190
  border: 1px solid darksalmon;
191
  margin: 1em;
192
  padding: 1em;
193
}
194
195
.properties .title {
196
  font-size: 100%;
197
}
198
199
th {
200
  border-bottom: 1px solid black;
201
  font-family: "Special Elite";
202
  text-align: left;
203
}
204
205
td {
206
  vertical-align: top;
207
}
208
209
tr+tr {
210
  margin-top: 0.2em;
211
}
212
213
table {
214
  border-bottom: 2px solid;
215
  border-top: 2px solid;
216
}
217
218
.nav {
219
  display: inline-block;
220
  max-width: 20em;
221
  vertical-align: top;
222
  width: 33%;
223
}
224
225
.main {
226
  display: inline-block;
227
  margin-left: 2em;
228
  max-width: 60em;
229
  width: 60%;
230
}
231
232
.header {
233
  clear: both;
234
  display: table;
235
  margin-bottom: 2em;
236
  width: 100%;
237
  box-shadow: 0px 5px 33px 0px rgba(0, 0, 0, 0.2);
238
  padding: 1em 0em 2em;
239
  border-bottom: 1px solid gray;
240
}
241
242
.header>div {
243
  display: table-cell;
244
  vertical-align: middle;
245
}
246
247
.header>div+.header>div {
248
  text-align: center;
249
}
250
251
.sectionlink {
252
  display: none;
253
}
254
255
:hover>.sectionlink {
256
  display: inline;
257
  color: orange;
258
}
259
260
.pagelinks {
261
  list-style: none;
262
}
263
264
.pagelinks li {
265
  display: inline-block;
266
  margin: 1em;
267
}
268
269
.pagelinks>li {
270
  border: 1px solid #bbb;
271
  box-shadow: 5px 5px 5px rgba(20, 20, 20, 0.2);
272
  padding: 0.5em 1em;
273
}
274
275
.pagelinks li {
276
  display: inline-block;
277
  margin: 1em;
278
  font-family: "Special Elite";
279
}
280
281
.section-index {
282
  font-family: "Special Elite";
283
  margin:;
284
  list-style: none;
285
}
286
287
.section-index>li {
288
  margin: 1em;
289
  padding: 1em;
290
  border: 1px solid #bbb;
291
  box-shadow: 5px 5px 5px rgba(20, 20, 20, 0.2);
292
}
293
294
.hidden {
295
  display: none;
296
}
297
298
@media screen and (max-width: 900px) {
299
  .nav {
300
    display: block;
301
    width: 100%;
302
    max-width: 100%;
303
  }
304
  .main {
305
    display: block;
306
    width: 100%;
307
    max-width: 100%;
308
    margin-left: 0.5em;
309
  }
310
  .section-index, pagelinks {
311
    padding-left: 0px;
312
    margin-left: 0px;
313
  }
314
  .figure {
315
    margin: 1em 0px;
316
  }
317
  .properties {
318
    margin: 1rem 0px;
319
  }
320
  .property .name, .property
321
          .description, .property
322
          .required {
323
    display: block;
324
    width: 100%;
325
  }
326
  .property .required {
327
    border-bottom: 1px solid #ddd;
328
  }
329
  .property .required::before {
330
    content: 'R: ';
331
  }
332
  .property .name::before {
333
    content: 'N: ';
334
  }
335
  .property .description::before {
336
    content: 'D: ';
337
  }
338
  .header {
339
    display: block;
340
  }
341
  .header span {
342
    display: inline;
343
  }
344
  .pagelinks li {
345
    margin: 0.5rem;
346
  }
347
  .header>div {
348
    display: inline-block;
349
    vertical-align: middle;
350
    width: 50%
351
  }
352
  .header>div+.header>div {
353
    text-align: center;
354
  }
355
  .menu ul {
356
    display: none;
357
  }
358
  .menu li:hover>ul {
359
    display: block;
360
  }
361
  .section-index ul {
362
    display: none;
363
  }
364
  .section-index li:hover>ul {
365
    display: block;
366
  }
367
}
(-)a/xdocs/stylesheets/website-style.xsl (+560 lines)
Line 0 Link Here
1
<?xml version="1.0" encoding="UTF-8"?>
2
<!-- Licensed to the Apache Software Foundation (ASF) under one or more contributor
3
  license agreements. See the NOTICE file distributed with this work for additional
4
  information regarding copyright ownership. The ASF licenses this file to
5
  You under the Apache License, Version 2.0 (the "License"); you may not use
6
  this file except in compliance with the License. You may obtain a copy of
7
  the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required
8
  by applicable law or agreed to in writing, software distributed under the
9
  License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS
10
  OF ANY KIND, either express or implied. See the License for the specific
11
  language governing permissions and limitations under the License. -->
12
<!-- Content Stylesheet for "jmeter-site" -->
13
14
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
15
  version="3.0"
16
>
17
18
  <!-- Defined parameters (overrideable) -->
19
  <xsl:param name="relative-path" select="'.'" />
20
  <xsl:param name="subdir" select="''" />
21
  <xsl:param name="imgdir" select="concat($relative-path, '/images')" />
22
  <xsl:param name="sshotdir" select="concat($imgdir, '/screenshots')" />
23
  <xsl:param name="cssdir" select="concat($relative-path, '/css')" />
24
  <xsl:param name="jakarta-site" select="'http://jakarta.apache.org'" />
25
  <xsl:param name="year" select="'2015'" />
26
  <xsl:param name="max-img-width" select="'600'" />
27
28
  <!-- Output method -->
29
  <xsl:output method="html" html-version="5.0" encoding="iso-8859-15"
30
    indent="no" doctype-system="about:legacy-compat" />
31
32
  <xsl:template match="document">
33
    <xsl:variable name="project" select="document('project.xml')/project" />
34
    <html lang="en">
35
      <head>
36
        <title>
37
          <xsl:value-of select="$project/title" />
38
          -
39
          <xsl:value-of select="properties/title" />
40
        </title>
41
        <xsl:for-each select="properties/author">
42
          <xsl:variable name="name">
43
            <xsl:value-of select="." />
44
          </xsl:variable>
45
          <xsl:variable name="email">
46
            <xsl:value-of select="@email" />
47
          </xsl:variable>
48
          <meta name="author" value="{$name}" />
49
          <meta name="email" value="{$email}" />
50
        </xsl:for-each>
51
        <!-- VIEWPORT -->
52
        <meta name="viewport" content="width=device-width, initial-scale=1" />
53
        <link
54
          href='http://fonts.googleapis.com/css?family=Special+Elite:400normal'
55
          rel='stylesheet' type='text/css'
56
        ></link>
57
        <link rel="stylesheet" type="text/css"
58
          href="{concat($cssdir, '/new-style.css')}"
59
        ></link>
60
      </head>
61
      <body role="document">
62
        <a href="#content" class="hidden" >Main content</a>
63
        <div class="header">
64
          <xsl:comment>
65
            APACHE LOGO
66
          </xsl:comment>
67
          <div>
68
            <a href="http://www.apache.org">
69
              <img title="Apache Software Foundation" width="290"
70
                height="75" src="{$imgdir}/asf-logo.png" alt="Logo ASF" />
71
            </a>
72
          </div>
73
          <xsl:if test="$project/logo">
74
            <xsl:variable name="alt">
75
              <xsl:value-of select="$project/logo" />
76
            </xsl:variable>
77
            <xsl:variable name="home">
78
              <xsl:value-of select="$project/@href" />
79
            </xsl:variable>
80
            <xsl:variable name="src">
81
              <xsl:value-of
82
                select="concat($relative-path, $project/logo/@href)" />
83
            </xsl:variable>
84
            <xsl:comment>
85
              PROJECT LOGO
86
            </xsl:comment>
87
            <div>
88
              <a href="{$home}">
89
                <img src="{$src}" alt="{$alt}" />
90
              </a>
91
            </div>
92
          </xsl:if>
93
          <div>
94
            <div>
95
              <a href="https://twitter.com/share" class="twitter-share-button"
96
                data-text="Powerful Load Testing with Apache #JMeter"
97
                data-via="ApacheJMeter" data-lang="en-gb" data-size="large"
98
              >Tweet</a>
99
              <script><![CDATA[
100
            (function(d,s,id){
101
              var js,
102
                  fjs=d.getElementsByTagName(s)[0],
103
                  p=/^http:/.test(d.location)?'http':'https';
104
              if (!d.getElementById(id)) {
105
                  js=d.createElement(s);
106
                  js.id=id;
107
                  js.src=p+'://platform.twitter.com/widgets.js';
108
                  fjs.parentNode.insertBefore(js,fjs);
109
              }
110
            })(document, 'script', 'twitter-wjs');]]>
111
              </script>
112
            </div>
113
            <div>
114
              <a href="https://twitter.com/ApacheJMeter" class="twitter-follow-button"
115
                data-show-count="false" data-lang="en-gb" data-size="large"
116
              >Follow</a>
117
              <script><![CDATA[(function(d,s,id){
118
                var js,
119
                    fjs=d.getElementsByTagName(s)[0],
120
                    p=/^http:/.test(d.location)?'http':'https';
121
                if (!d.getElementById(id)) {
122
                    js=d.createElement(s);
123
                    js.id=id;
124
                    js.src=p+'://platform.twitter.com/widgets.js';
125
                    fjs.parentNode.insertBefore(js,fjs);
126
                }
127
            })(document, 'script', 'twitter-wjs');]]>
128
              </script>
129
            </div>
130
          </div>
131
          <div class="banner">
132
            <iframe src="http://www.apache.org/ads/button.html"
133
              style="border-width:0;" frameborder="0" scrolling="no"
134
            ></iframe>
135
            <div class="clear"></div>
136
          </div>
137
        </div>
138
        <div class="nav">
139
          <xsl:apply-templates select="$project/body/menu" />
140
        </div>
141
        <div class="main">
142
          <a name="content" />
143
          <xsl:call-template name="pagelinks" />
144
          <xsl:if test="@index">
145
            <xsl:call-template name="section-index" />
146
          </xsl:if>
147
          <xsl:apply-templates select="body/section"></xsl:apply-templates>
148
          <xsl:call-template name="pagelinks" />
149
        </div>
150
        <div class="footer">
151
          <div class="copyright">
152
            Copyright &amp;copy;
153
            1999 &amp;ndash;
154
            <xsl:value-of select="$year" />
155
            , Apache Software Foundation
156
          </div>
157
          <div class="trademarks">Apache, Apache JMeter, JMeter, the Apache
158
            feather, and the Apache JMeter logo are
159
            trademarks of the
160
            Apache Software Foundation.
161
          </div>
162
        </div>
163
      </body>
164
    </html>
165
  </xsl:template>
166
167
  <xsl:template name="pagelinks">
168
    <xsl:if test="@prev or @next">
169
      <ul class="pagelinks">
170
        <xsl:if test="@prev">
171
          <li>
172
            <a href="{@prev}">&lt; Prev</a>
173
          </li>
174
        </xsl:if>
175
        <li>
176
          <a href="{concat($relative-path, '/index.html')}">Index</a>
177
        </li>
178
        <xsl:if test="@next">
179
          <li>
180
            <a href="{@next}">Next &gt;</a>
181
          </li>
182
        </xsl:if>
183
      </ul>
184
    </xsl:if>
185
  </xsl:template>
186
187
  <xsl:template name="section-index">
188
    <ul class="section-index">
189
      <xsl:for-each select="body/section">
190
        <li>
191
          <a href="#{@anchor}">
192
            <xsl:value-of select="@name" />
193
          </a>
194
          <ul>
195
            <xsl:for-each select="component">
196
              <li>
197
                <a href="#{translate(normalize-space(@name), ' ', '_')}">
198
                  <xsl:value-of select="@name" />
199
                  <xsl:if test="@was">
200
                    (was:
201
                    <xsl:value-of select="@was" />
202
                    )
203
                  </xsl:if>
204
                </a>
205
              </li>
206
            </xsl:for-each>
207
          </ul>
208
        </li>
209
      </xsl:for-each>
210
    </ul>
211
  </xsl:template>
212
213
  <xsl:template name="image">
214
    <xsl:param name="srcdir" />
215
    <xsl:param name="image" />
216
    <xsl:param name="width" />
217
    <xsl:param name="height" />
218
    <xsl:variable name="name" select="concat($srcdir, '/', $image)" />
219
    <xsl:choose>
220
    <xsl:when test="$width &gt; $max-img-width">
221
      <a href="{$name}"><img src="{$name}" class="img-too-big" /></a>
222
    </xsl:when>
223
    <xsl:otherwise>
224
      <a href="{$name}"><img src="{$name}" width="{$width}" height="{$height}" /></a>
225
    </xsl:otherwise>
226
    </xsl:choose>
227
  </xsl:template>
228
229
  <!-- Process a menu for the navigation bar -->
230
  <xsl:template match="menu">
231
    <ul class="menu">
232
      <li>
233
        <div class="menu-title">
234
          <xsl:value-of select="@name" />
235
        </div>
236
        <ul>
237
          <xsl:apply-templates select="item" />
238
        </ul>
239
      </li>
240
    </ul>
241
  </xsl:template>
242
243
  <!-- Process a menu item for the navigation bar -->
244
  <xsl:template match="item">
245
    <xsl:variable name="href">
246
      <xsl:choose>
247
        <xsl:when test="starts-with(@href, 'http')">
248
          <xsl:value-of select="@href" />
249
        </xsl:when>
250
        <xsl:when test="starts-with(@href, '/site')">
251
          <xsl:value-of select="concat($jakarta-site, @href)" />
252
        </xsl:when>
253
        <xsl:otherwise>
254
          <xsl:value-of select="concat($relative-path, @href)" />
255
        </xsl:otherwise>
256
      </xsl:choose>
257
    </xsl:variable>
258
    <li>
259
      <a href="{$href}">
260
        <xsl:value-of select="@name" />
261
        <xsl:if test="@icon">
262
          <img src="{concat($imgdir, '/', @icon)}" />
263
        </xsl:if>
264
      </a>
265
    </li>
266
  </xsl:template>
267
268
  <xsl:template match="section">
269
    <div class="section">
270
      <h1>
271
        <xsl:value-of select="@name" />
272
        <xsl:if test="@anchor">
273
          <xsl:call-template name="sectionlink">
274
            <xsl:with-param name="anchor" select="@anchor" />
275
          </xsl:call-template>
276
        </xsl:if>
277
      </h1>
278
      <xsl:apply-templates />
279
    </div>
280
  </xsl:template>
281
282
  <xsl:template match="ch_section">
283
    <h2 class="ch_section">
284
      <xsl:apply-templates />
285
    </h2>
286
  </xsl:template>
287
288
  <xsl:template match="ch_title">
289
    <h2 class="ch_title">
290
      <xsl:apply-templates />
291
    </h2>
292
  </xsl:template>
293
294
  <xsl:template match="ch_category">
295
    <h2 class="ch_category">
296
      <xsl:apply-templates />
297
    </h2>
298
  </xsl:template>
299
300
  <xsl:template match="subsection">
301
    <div class="subsection">
302
      <h2>
303
        <xsl:value-of select="@name" />
304
        <xsl:if test="@anchor">
305
          <xsl:call-template name="sectionlink">
306
            <xsl:with-param name="anchor" select="@anchor" />
307
          </xsl:call-template>
308
        </xsl:if>
309
      </h2>
310
      <xsl:apply-templates />
311
    </div>
312
  </xsl:template>
313
314
  <xsl:template match="source">
315
    <pre class="source">
316
      <xsl:apply-templates />
317
    </pre>
318
  </xsl:template>
319
320
  <xsl:template match="code">
321
    <span class="code">
322
      <xsl:apply-templates />
323
    </span>
324
  </xsl:template>
325
326
  <xsl:template match="description">
327
    <div class="description">
328
      <xsl:apply-templates />
329
    </div>
330
  </xsl:template>
331
332
  <xsl:template match="component">
333
    <div class="component">
334
      <h2>
335
        <xsl:value-of select="@name" />
336
        <xsl:if test="@was">
337
          <a name="{@was}">
338
            (was:
339
            <xsl:value-of select="@was" />
340
            )
341
          </a>
342
        </xsl:if>
343
        <xsl:if test="@name">
344
          <xsl:call-template name="sectionlink">
345
            <xsl:with-param name="anchor" select="@name" />
346
          </xsl:call-template>
347
        </xsl:if>
348
      </h2>
349
      <xsl:if test="@useinstead">
350
        <div class="deprecated">
351
          *** This element is deprecated. Use
352
          <a
353
            href="{concat($relative-path, '/usermanual/component_reference.html#', translate(normalize-space(@useinstead), ' ', '_'))}"
354
          >
355
            <xsl:value-of select="@useinstead" />
356
          </a>
357
          instead ***
358
        </div>
359
      </xsl:if>
360
      <xsl:if test="@screenshot != ''">
361
        <div class="screenshot">
362
          <xsl:call-template name="image">
363
            <xsl:with-param name="srcdir" select="$sshotdir" />
364
            <xsl:with-param name="image" select="@screenshot" />
365
            <xsl:with-param name="width" select="@width" />
366
            <xsl:with-param name="height" select="@height" />
367
          </xsl:call-template>
368
        </div>
369
      </xsl:if>
370
      <xsl:apply-templates />
371
      <div class="go-top">
372
        <a href="#">^</a>
373
      </div>
374
    </div>
375
  </xsl:template>
376
377
  <xsl:template name="sectionlink">
378
    <xsl:param name="anchor" />
379
    <a name="{translate(normalize-space($anchor), ' ', '_')}" />
380
    <a class="sectionlink" href="#{translate(normalize-space($anchor), ' ', '_')}"
381
      title="Link to here"
382
    >&amp;para;</a>
383
  </xsl:template>
384
385
  <xsl:template match="properties">
386
    <div class="properties">
387
      <h3>
388
        Parameters
389
        <xsl:if test="name(..) = 'component'">
390
          <xsl:call-template name="sectionlink">
391
            <xsl:with-param name="anchor"
392
              select="concat(translate(normalize-space(../@name), ' ', '_'), '_parms')" />
393
          </xsl:call-template>
394
        </xsl:if>
395
      </h3>
396
      <div class="property title">
397
        <div class="name title">Attribute</div>
398
        <div class="description title">Description</div>
399
        <div class="required title">Required</div>
400
      </div>
401
      <xsl:apply-templates />
402
    </div>
403
  </xsl:template>
404
405
  <xsl:template match="property">
406
    <div class="property">
407
      <div
408
        class="name req-{contains('yYtT', substring(normalize-space(@required), 1, 1))}"
409
      >
410
        <xsl:value-of select="@name" />
411
      </div>
412
      <div
413
        class="description req-{contains('yYtT', substring(normalize-space(@required), 1, 1))}"
414
      >
415
        <xsl:apply-templates />
416
      </div>
417
      <div
418
        class="required req-{contains('yYtT', substring(normalize-space(@required), 1, 1))}"
419
      >
420
        <xsl:choose>
421
          <xsl:when test="@required">
422
            <xsl:value-of select="@required" />
423
          </xsl:when>
424
          <xsl:otherwise>
425
            No
426
          </xsl:otherwise>
427
        </xsl:choose>
428
      </div>
429
    </div>
430
  </xsl:template>
431
432
  <xsl:template match="note">
433
    <div class="clear"></div>
434
    <div class="note">
435
      <xsl:apply-templates />
436
    </div>
437
    <div class="clear"></div>
438
  </xsl:template>
439
440
  <xsl:template name="complink">
441
    <xsl:param name="name" />
442
    <a
443
      href="{concat($relative-path, '/usermanual/component_reference.html#', translate(@name, ' ', '_'))}"
444
    >
445
      <xsl:value-of select="@name" />
446
    </a>
447
  </xsl:template>
448
449
  <xsl:template match="complink">
450
    <xsl:call-template name="complink">
451
      <xsl:with-param name="name" select="@name" />
452
    </xsl:call-template>
453
  </xsl:template>
454
455
  <xsl:template match="figure">
456
    <div class="figure">
457
      <xsl:call-template name="image">
458
        <xsl:with-param name="srcdir" select="$sshotdir" />
459
        <xsl:with-param name="image" select="@image" />
460
        <xsl:with-param name="width" select="@width" />
461
        <xsl:with-param name="height" select="@height" />
462
      </xsl:call-template>
463
      <figcaption>
464
        <xsl:apply-templates />
465
      </figcaption>
466
    </div>
467
  </xsl:template>
468
469
  <xsl:template match="bugzilla">
470
    <a href="http://bz.apache.org/bugzilla/show_bug.cgi?id={./text()}">
471
      Bug
472
      <xsl:value-of select="./text()" />
473
    </a>
474
  </xsl:template>
475
476
  <xsl:template match="bug">
477
    <a href="http://bz.apache.org/bugzilla/show_bug.cgi?id={./text()}">
478
      Bug
479
      <xsl:value-of select="./text()" />
480
    </a>
481
    -
482
  </xsl:template>
483
484
  <xsl:template match="links">
485
    <div class="links">
486
      <div class="title">See also:</div>
487
      <ul class="links">
488
        <xsl:for-each select="link|complink">
489
          <li>
490
            <xsl:choose>
491
              <xsl:when test="name(.) = 'link'">
492
                <a href="{@href}">
493
                  <xsl:apply-templates />
494
                </a>
495
              </xsl:when>
496
              <xsl:when test="name(.) = 'complink'">
497
                <xsl:call-template name="complink">
498
                  <xsl:with-param name="name" select="@name" />
499
                </xsl:call-template>
500
              </xsl:when>
501
            </xsl:choose>
502
          </li>
503
        </xsl:for-each>
504
      </ul>
505
    </div>
506
  </xsl:template>
507
508
  <xsl:template match="link">
509
    <li>
510
      <a href="{@href}">
511
        <xsl:apply-templates />
512
      </a>
513
    </li>
514
  </xsl:template>
515
516
  <xsl:template match="example">
517
    <div class="example">
518
      <div class="title">
519
        <xsl:value-of select="@title" />
520
        <xsl:if test="@anchor">
521
          <xsl:call-template name="sectionlink">
522
            <xsl:with-param name="anchor" select="@anchor" />
523
          </xsl:call-template>
524
        </xsl:if>
525
      </div>
526
      <xsl:apply-templates />
527
    </div>
528
  </xsl:template>
529
530
  <xsl:template match="table">
531
    <table>
532
      <xsl:apply-templates />
533
    </table>
534
  </xsl:template>
535
536
  <xsl:template
537
    match="h1|h2|h3|h4|h5|p|b|em|ul|ol|li|a|i|pre|br|tt|tr|th|td|dl|dt|dd|sup|u|strong|thead|tbody|form|select|option|input|font|center|img|body|style|div|hr"
538
  >
539
    <xsl:copy>
540
      <xsl:apply-templates select="@*|*|text()" />
541
    </xsl:copy>
542
  </xsl:template>
543
544
545
  <!-- Process everything else by just passing it through -->
546
  <xsl:template match="*">
547
    <div class="nostyle">
548
      <xsl:copy>
549
        <xsl:apply-templates select="@*|*|text()" />
550
      </xsl:copy>
551
    </div>
552
  </xsl:template>
553
554
  <xsl:template match="@*">
555
    <xsl:copy>
556
      <xsl:apply-templates select="@*|*|text()" />
557
    </xsl:copy>
558
  </xsl:template>
559
560
</xsl:stylesheet>

Return to bug 53764