summaryrefslogtreecommitdiff
path: root/common/doc/doxygen_to_devhelp.xsl
blob: 1aca34dca5b27b12e30b66f5b549f3ca7798a038 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<xsl:stylesheet
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:fo="http://www.w3.org/1999/XSL/Format"
    version="1.0">

<xsl:output method="xml" version="1.0" indent="yes"/>

<xsl:param name="prefix"></xsl:param>
<xsl:param name="booktitle"></xsl:param>
<xsl:param name="bookpart"></xsl:param>

<xsl:template match="/">
  <book title="ONEPLAY: {$booktitle}"
        name="oneplay-{$bookpart}"
	link="html/index.html">
  <chapters>
    <xsl:apply-templates select="doxygenindex/compound[@kind='group']"/>
  </chapters>
  <functions>
    <xsl:apply-templates select="doxygenindex/compound[@kind='group']/member[@kind='function']"/>
  </functions>
  </book>
</xsl:template>

<xsl:template match="compound[@kind='group']">
  <xsl:param name="name"><xsl:value-of select="name"/></xsl:param>
  <xsl:param name="refid"><xsl:value-of select="@refid"/></xsl:param>
  <xsl:param name="link"><xsl:value-of select="$refid"/>.html</xsl:param>
  <sub name="{$name}" link="html/{$link}"/>
</xsl:template>

<xsl:template match="member">
  <xsl:param name="name"><xsl:value-of select="name"/></xsl:param>
  <xsl:param name="refid"><xsl:value-of select="@refid"/></xsl:param>
  <xsl:param name="before"><xsl:value-of select="substring-before($refid,'_1')"/></xsl:param>
  <xsl:param name="after"><xsl:value-of select="substring-after($refid,'_1')"/></xsl:param>
  <xsl:param name="link"><xsl:value-of select="$before"/>.html#<xsl:value-of select="$after"/></xsl:param>
  <function name="{$name}" link="html/{$link}"/>
</xsl:template>

</xsl:stylesheet>