Added "Since" and "Deprecated" tag to function example
[gtk-doc.git] / version-greater-or-equal.xsl
blob46871d26905524e0d2e80785b299554d698cd729
1 <?xml version='1.0'?> <!--*- mode: xml -*-->
2 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
3 version="1.0"
4 xmlns="http://www.w3.org/TR/xhtml1/transitional"
5 exclude-result-prefixes="#default">
6 <xsl:template name="version-greater-or-equal">
7 <xsl:param name="ver1"></xsl:param>
8 <xsl:param name="ver2"></xsl:param>
9 <xsl:variable name="vp1">
10 <xsl:choose>
11 <xsl:when test="contains($ver1, '.')">
12 <xsl:value-of select="substring-before($ver1, '.')"/>
13 </xsl:when>
14 <xsl:otherwise>
15 <xsl:value-of select="$ver1"/>
16 </xsl:otherwise>
17 </xsl:choose>
18 </xsl:variable>
19 <xsl:variable name="vp2">
20 <xsl:choose>
21 <xsl:when test="contains($ver2, '.')">
22 <xsl:value-of select="substring-before($ver2, '.')"/>
23 </xsl:when>
24 <xsl:otherwise>
25 <xsl:value-of select="$ver2"/>
26 </xsl:otherwise>
27 </xsl:choose>
28 </xsl:variable>
29 <xsl:choose>
30 <xsl:when test="$vp1 &gt; $vp2">
32 </xsl:when>
33 <xsl:when test="$vp1 &lt; $vp2">
35 </xsl:when>
36 <xsl:when test="$vp1 = $vp2">
37 <xsl:choose>
38 <xsl:when test="contains($ver1, '.') and contains($ver2, '.')">
39 <xsl:call-template name="version-greater-or-equal">
40 <xsl:with-param name="ver1" select="substring-after($ver1, '.')"/>
41 <xsl:with-param name="ver2" select="substring-after($ver2, '.')"/>
42 </xsl:call-template>
43 </xsl:when>
44 <xsl:when test="contains($ver2, '.')">
46 </xsl:when>
47 <xsl:otherwise>
49 </xsl:otherwise>
50 </xsl:choose>
51 </xsl:when>
52 </xsl:choose>
53 </xsl:template>
54 </xsl:stylesheet>