3 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
5 xmlns:monodoc="monodoc:///extensions"
6 exclude-result-prefixes="monodoc"
8 <xsl:output omit-xml-declaration="yes" />
10 <xsl:template match="/clause">
11 <div class="header" id="ecmaspec">
12 <div class="subtitle">ECMA-334 C# Language Specification</div>
13 <div class="title"><xsl:value-of select="@number"/>: <xsl:value-of select="@title"/>
14 <xsl:if test="@informative"> (informative) </xsl:if></div>
16 <xsl:apply-templates />
19 <xsl:template match="paragraph">
21 <xsl:apply-templates />
25 <xsl:template match="keyword">
26 <span class="keyword"> <xsl:apply-templates/></span> <xsl:text> </xsl:text>
29 <xsl:template match="hyperlink">
30 <a href="ecmaspec:{.}">
31 <xsl:value-of select="." />
35 <xsl:template match="list">
37 <xsl:for-each select="list_item|list">
38 <li><xsl:apply-templates /></li>
43 <xsl:template match="code_example">
44 <div class="code_example">
45 <div class="code_ex_title">Code example</div>
47 <xsl:value-of select="monodoc:Colorize(string(descendant-or-self::text()), string('csharp'))" disable-output-escaping="yes" />
52 <xsl:template match="symbol">
54 <xsl:apply-templates />
58 <xsl:template match="grammar_production">
59 <dl class="nt_{name/non_terminal/.}">
60 <dt><xsl:value-of select="name/non_terminal/." /></dt>
62 <xsl:for-each select="rhs">
64 <xsl:apply-templates select="node()" />
70 <xsl:template match="non_terminal">
71 <span class="non_terminal"><xsl:text> </xsl:text><xsl:value-of select="." /></span>
74 <xsl:template match="terminal">
75 <span class="terminal"><xsl:text> </xsl:text><xsl:value-of select="." /></span>
78 <xsl:template match="opt">
79 <xsl:text> (</xsl:text><span class="opt">optional</span><xsl:text>) </xsl:text>
82 <xsl:template match="note|example">
84 <xsl:apply-templates />
88 <xsl:template match="table_line">
89 <xsl:apply-templates /><br />
92 <xsl:template match="@*|node()">
94 <xsl:apply-templates select="@*|node()"/>