2 <xsl:stylesheet version="1.0"
3 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
4 xmlns:exsl="http://exslt.org/common"
5 extension-element-prefixes="exsl"
6 exclude-result-prefixes="exsl">
8 <!-- Import the resto of the site stylesheets -->
9 <xsl:import href="site.xsl"/>
11 <xsl:variable name="apirefs" select="document('libxml2-refs.xml')"/>
12 <xsl:variable name="module" select="$apirefs/apirefs/@name"/>
13 <xsl:key name="refhref" match="reference" use="@name"/>
15 <xsl:template match="ref" mode="anchor">
16 <xsl:variable name="name" select="@name"/>
17 <xsl:for-each select="document('libxml2-refs.xml')">
18 <a href="{key('refhref', $name)/@href}"><xsl:value-of select="$name"/></a>
21 <xsl:template match="type" mode="reflist">
22 <h2>Type <xsl:value-of select="@name"/>:</h2>
24 <xsl:for-each select="ref">
25 <xsl:apply-templates mode="anchor" select="."/>
31 <xsl:template match="letter" mode="reflist">
32 <h2>Letter <xsl:value-of select="@name"/>:</h2>
34 <xsl:for-each select="ref">
35 <xsl:apply-templates mode="anchor" select="."/>
41 <xsl:template match="file" mode="reflist">
42 <h2><a name="{@name}">Module <xsl:value-of select="@name"/></a>:</h2>
44 <xsl:for-each select="ref">
45 <xsl:apply-templates mode="anchor" select="."/>
51 <xsl:template match="letter" mode="wordlist">
52 <h2>Letter <xsl:value-of select="@name"/>:</h2>
54 <xsl:for-each select="word">
55 <dt><xsl:value-of select="@name"/></dt>
57 <xsl:for-each select="ref">
58 <xsl:apply-templates mode="anchor" select="."/>
67 <xsl:template match="constructors">
68 <xsl:message>Generating API Constructors</xsl:message>
69 <xsl:variable name="title">List of constructors for <xsl:value-of select="$module"/></xsl:variable>
70 <xsl:document href="APIconstructors.html" method="html" version="4.01" encoding="ISO-8859-1">
73 <xsl:call-template name="style"/>
74 <xsl:element name="title">
75 <xsl:value-of select="$title"/>
78 <body bgcolor="#8b7765" text="#000000" link="#000000" vlink="#000000">
79 <xsl:call-template name="titlebox">
80 <xsl:with-param name="title" select="$title"/>
82 <table border="0" cellpadding="4" cellspacing="0" width="100%" align="center">
84 <td bgcolor="#8b7765">
85 <table border="0" cellspacing="0" cellpadding="2" width="100%">
87 <td valign="top" width="200" bgcolor="#8b7765">
88 <xsl:call-template name="toc"/>
90 <td valign="top" bgcolor="#8b7765">
91 <table border="0" cellspacing="0" cellpadding="1" width="100%">
94 <table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000">
97 <table border="0" cellpadding="3" cellspacing="1" width="100%">
99 <td bgcolor="#fffacd">
100 <xsl:apply-templates mode="reflist" select="type"/>
101 <p><a href="bugs.html">Daniel Veillard</a></p>
121 <xsl:template match="files">
122 <xsl:message>Generating API List of synbols per file</xsl:message>
123 <xsl:variable name="title">List of Symbols per Module for <xsl:value-of select="$module"/></xsl:variable>
124 <xsl:document href="APIfiles.html" method="html" version="4.01" encoding="ISO-8859-1">
127 <xsl:call-template name="style"/>
128 <xsl:element name="title">
129 <xsl:value-of select="$title"/>
132 <body bgcolor="#8b7765" text="#000000" link="#000000" vlink="#000000">
133 <xsl:call-template name="titlebox">
134 <xsl:with-param name="title" select="$title"/>
136 <table border="0" cellpadding="4" cellspacing="0" width="100%" align="center">
138 <td bgcolor="#8b7765">
139 <table border="0" cellspacing="0" cellpadding="2" width="100%">
141 <td valign="top" width="200" bgcolor="#8b7765">
142 <xsl:call-template name="toc"/>
144 <td valign="top" bgcolor="#8b7765">
145 <table border="0" cellspacing="0" cellpadding="1" width="100%">
148 <table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000">
151 <table border="0" cellpadding="3" cellspacing="1" width="100%">
153 <td bgcolor="#fffacd">
154 <xsl:apply-templates mode="reflist" select="file"/>
155 <p><a href="bugs.html">Daniel Veillard</a></p>
175 <xsl:template match="functions">
176 <xsl:message>Generating API Functions by Type</xsl:message>
177 <xsl:variable name="title">List of function manipulating types in <xsl:value-of select="$module"/></xsl:variable>
178 <xsl:document href="APIfunctions.html" method="html" version="4.01" encoding="ISO-8859-1">
181 <xsl:call-template name="style"/>
182 <xsl:element name="title">
183 <xsl:value-of select="$title"/>
186 <body bgcolor="#8b7765" text="#000000" link="#000000" vlink="#000000">
187 <xsl:call-template name="titlebox">
188 <xsl:with-param name="title" select="$title"/>
190 <table border="0" cellpadding="4" cellspacing="0" width="100%" align="center">
192 <td bgcolor="#8b7765">
193 <table border="0" cellspacing="0" cellpadding="2" width="100%">
195 <td valign="top" width="200" bgcolor="#8b7765">
196 <xsl:call-template name="toc"/>
198 <td valign="top" bgcolor="#8b7765">
199 <table border="0" cellspacing="0" cellpadding="1" width="100%">
202 <table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000">
205 <table border="0" cellpadding="3" cellspacing="1" width="100%">
207 <td bgcolor="#fffacd">
208 <xsl:apply-templates mode="reflist" select="type"/>
209 <p><a href="bugs.html">Daniel Veillard</a></p>
229 <xsl:template match="alpha">
230 <xsl:message>Generating API Alphabetic list</xsl:message>
231 <xsl:variable name="title">Alphabetic List of Symbols in <xsl:value-of select="$module"/></xsl:variable>
232 <xsl:document href="APIsymbols.html" method="html" version="4.01" encoding="ISO-8859-1">
235 <xsl:call-template name="style"/>
236 <xsl:element name="title">
237 <xsl:value-of select="$title"/>
240 <body bgcolor="#8b7765" text="#000000" link="#000000" vlink="#000000">
241 <xsl:call-template name="titlebox">
242 <xsl:with-param name="title" select="$title"/>
244 <table border="0" cellpadding="4" cellspacing="0" width="100%" align="center">
246 <td bgcolor="#8b7765">
247 <table border="0" cellspacing="0" cellpadding="2" width="100%">
249 <td valign="top" width="200" bgcolor="#8b7765">
250 <xsl:call-template name="toc"/>
252 <td valign="top" bgcolor="#8b7765">
253 <table border="0" cellspacing="0" cellpadding="1" width="100%">
256 <table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000">
259 <table border="0" cellpadding="3" cellspacing="1" width="100%">
261 <td bgcolor="#fffacd">
262 <xsl:apply-templates mode="reflist" select="letter"/>
263 <p><a href="bugs.html">Daniel Veillard</a></p>
283 <xsl:template name="apichunks">
285 <xsl:for-each select="/apirefs/index/chunks/chunk">
286 <xsl:variable name="name" select="@name"/>
287 <xsl:variable name="start" select="@start"/>
288 <xsl:variable name="end" select="@end"/>
289 <xsl:variable name="block" select="concat($start, '-', $end)"/>
290 <a href="API{$name}.html"><xsl:value-of select="$block"/></a>
296 <xsl:template match="chunk">
297 <xsl:variable name="name" select="@name"/>
298 <xsl:variable name="start" select="@start"/>
299 <xsl:variable name="end" select="@end"/>
300 <xsl:variable name="block" select="concat($start, '-', $end)"/>
301 <xsl:variable name="target" select="/apirefs/index/chunk[@name = $name]"/>
302 <xsl:variable name="title">API Alphabetic Index <xsl:value-of select="$block"/> for <xsl:value-of select="$module"/></xsl:variable>
303 <xsl:document href="API{$name}.html" method="html" version="4.01" encoding="ISO-8859-1">
306 <xsl:call-template name="style"/>
307 <xsl:element name="title">
308 <xsl:value-of select="$title"/>
311 <body bgcolor="#8b7765" text="#000000" link="#000000" vlink="#000000">
312 <xsl:call-template name="titlebox">
313 <xsl:with-param name="title" select="$title"/>
315 <table border="0" cellpadding="4" cellspacing="0" width="100%" align="center">
317 <td bgcolor="#8b7765">
318 <table border="0" cellspacing="0" cellpadding="2" width="100%">
320 <td valign="top" width="200" bgcolor="#8b7765">
321 <xsl:call-template name="toc"/>
323 <td valign="top" bgcolor="#8b7765">
324 <table border="0" cellspacing="0" cellpadding="1" width="100%">
327 <table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000">
330 <table border="0" cellpadding="3" cellspacing="1" width="100%">
332 <td bgcolor="#fffacd">
333 <xsl:call-template name="apichunks"/>
334 <xsl:apply-templates mode="wordlist"
335 select="$target/letter"/>
336 <xsl:call-template name="apichunks"/>
337 <p><a href="bugs.html">Daniel Veillard</a></p>
358 <xsl:template match="index">
359 <xsl:message>Generating API Index</xsl:message>
360 <xsl:apply-templates select="chunks/chunk"/>
363 <xsl:template match="apirefs">
364 <xsl:message>Generating API Cross References</xsl:message>
365 <xsl:apply-templates select="constructors"/>
366 <xsl:apply-templates select="functions"/>
367 <xsl:apply-templates select="alpha"/>
368 <xsl:apply-templates select="files"/>
369 <xsl:apply-templates select="index"/>
372 <xsl:template match="/">
373 <xsl:apply-templates select="$apirefs/apirefs"/>