You've already forked linux-packaging-mono
Imported Upstream version 5.4.0.167
Former-commit-id: 5624ac747d633e885131e8349322922b6a59baaa
This commit is contained in:
parent
e49d6f06c0
commit
536cd135cc
348
external/api-doc-tools/mdoc/Resources/defaulttemplate.xsl
vendored
Normal file
348
external/api-doc-tools/mdoc/Resources/defaulttemplate.xsl
vendored
Normal file
@@ -0,0 +1,348 @@
|
||||
<?xml version="1.0"?>
|
||||
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
||||
<xsl:output
|
||||
encoding="UTF-8"
|
||||
indent="yes"
|
||||
method="xml"
|
||||
omit-xml-declaration="yes"
|
||||
/>
|
||||
|
||||
<xsl:template match="Page">
|
||||
<html>
|
||||
<head>
|
||||
<title>
|
||||
<xsl:value-of select="Title" />
|
||||
</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<xsl:call-template name="create-default-style" />
|
||||
<xsl:call-template name="create-default-script" />
|
||||
</head>
|
||||
<body>
|
||||
<!-- HEADER -->
|
||||
<xsl:call-template name="create-default-collection-title" />
|
||||
<xsl:call-template name="create-index" />
|
||||
<xsl:call-template name="create-default-title" />
|
||||
<xsl:call-template name="create-default-summary" />
|
||||
<xsl:call-template name="create-default-signature" />
|
||||
<xsl:call-template name="create-default-remarks" />
|
||||
<xsl:call-template name="create-default-members" />
|
||||
<hr size="1" />
|
||||
<xsl:call-template name="create-default-copyright" />
|
||||
</body>
|
||||
</html>
|
||||
</xsl:template>
|
||||
|
||||
<!-- IDENTITY TRANSFORMATION -->
|
||||
<xsl:template match="@*|node()">
|
||||
<xsl:copy>
|
||||
<xsl:apply-templates select="@*|node()" />
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-default-style">
|
||||
<style>
|
||||
a { text-decoration: none }
|
||||
|
||||
div.SideBar {
|
||||
padding-left: 1em;
|
||||
padding-right: 1em;
|
||||
right: 0;
|
||||
float: right;
|
||||
border: thin solid black;
|
||||
background-color: #f2f2f2;
|
||||
}
|
||||
|
||||
.CollectionTitle { font-weight: bold }
|
||||
.PageTitle { font-size: 150%; font-weight: bold }
|
||||
|
||||
.Summary { }
|
||||
.Signature { }
|
||||
.Remarks { }
|
||||
.Members { }
|
||||
.Copyright { }
|
||||
|
||||
.Section { font-size: 125%; font-weight: bold }
|
||||
p.Summary {
|
||||
margin-left: 1em;
|
||||
}
|
||||
.SectionBox { margin-left: 2em }
|
||||
.NamespaceName { font-size: 105%; font-weight: bold }
|
||||
.NamespaceSumary { }
|
||||
.MemberName { font-size: 115%; font-weight: bold; margin-top: 1em }
|
||||
.Subsection { font-size: 105%; font-weight: bold }
|
||||
.SubsectionBox { margin-left: 2em; margin-bottom: 1em }
|
||||
|
||||
.CodeExampleTable { background-color: #f5f5dd; border: thin solid black; padding: .25em; }
|
||||
|
||||
.TypesListing {
|
||||
border-collapse: collapse;
|
||||
}
|
||||
|
||||
td {
|
||||
vertical-align: top;
|
||||
}
|
||||
th {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.TypesListing td {
|
||||
margin: 0px;
|
||||
padding: .25em;
|
||||
border: solid gray 1px;
|
||||
}
|
||||
|
||||
.TypesListing th {
|
||||
margin: 0px;
|
||||
padding: .25em;
|
||||
background-color: #f2f2f2;
|
||||
border: solid gray 1px;
|
||||
}
|
||||
|
||||
div.Footer {
|
||||
border-top: 1px solid gray;
|
||||
margin-top: 1.5em;
|
||||
padding-top: 0.6em;
|
||||
text-align: center;
|
||||
color: gray;
|
||||
}
|
||||
|
||||
span.NotEntered /* Documentation for this section has not yet been entered */ {
|
||||
font-style: italic;
|
||||
color: red;
|
||||
}
|
||||
|
||||
div.Header {
|
||||
background: #B0C4DE;
|
||||
border: double;
|
||||
border-color: white;
|
||||
border-width: 7px;
|
||||
padding: 0.5em;
|
||||
}
|
||||
|
||||
div.Header * {
|
||||
font-size: smaller;
|
||||
}
|
||||
|
||||
div.Note {
|
||||
}
|
||||
|
||||
i.ParamRef {
|
||||
}
|
||||
|
||||
i.subtitle {
|
||||
}
|
||||
|
||||
ul.TypeMembersIndex {
|
||||
text-align: left;
|
||||
background: #F8F8F8;
|
||||
}
|
||||
|
||||
ul.TypeMembersIndex li {
|
||||
display: inline;
|
||||
margin: 0.5em;
|
||||
}
|
||||
|
||||
table.HeaderTable {
|
||||
}
|
||||
|
||||
table.SignatureTable {
|
||||
}
|
||||
|
||||
table.Documentation, table.Enumeration, table.TypeDocumentation {
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table.Documentation tr th, table.TypeMembers tr th, table.Enumeration tr th, table.TypeDocumentation tr th {
|
||||
background: whitesmoke;
|
||||
padding: 0.8em;
|
||||
border: 1px solid gray;
|
||||
text-align: left;
|
||||
vertical-align: bottom;
|
||||
}
|
||||
|
||||
table.Documentation tr td, table.TypeMembers tr td, table.Enumeration tr td, table.TypeDocumentation tr td {
|
||||
padding: 0.5em;
|
||||
border: 1px solid gray;
|
||||
text-align: left;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
table.TypeMembers {
|
||||
border: 1px solid #C0C0C0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table.TypeMembers tr td {
|
||||
background: #F8F8F8;
|
||||
border: white;
|
||||
}
|
||||
|
||||
table.Documentation {
|
||||
}
|
||||
|
||||
table.TypeMembers {
|
||||
}
|
||||
|
||||
div.CodeExample {
|
||||
width: 100%;
|
||||
border: 1px solid #DDDDDD;
|
||||
background-color: #F8F8F8;
|
||||
}
|
||||
|
||||
div.CodeExample p {
|
||||
margin: 0.5em;
|
||||
border-bottom: 1px solid #DDDDDD;
|
||||
}
|
||||
|
||||
div.CodeExample div {
|
||||
margin: 0.5em;
|
||||
}
|
||||
|
||||
h4 {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
div.Signature {
|
||||
border: 1px solid #C0C0C0;
|
||||
background: #F2F2F2;
|
||||
padding: 1em;
|
||||
}
|
||||
</style>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-default-script">
|
||||
<script type="text/JavaScript">
|
||||
function toggle_display (block) {
|
||||
var w = document.getElementById (block);
|
||||
var t = document.getElementById (block + ":toggle");
|
||||
if (w.style.display == "none") {
|
||||
w.style.display = "block";
|
||||
t.innerHTML = "⊟";
|
||||
} else {
|
||||
w.style.display = "none";
|
||||
t.innerHTML = "⊞";
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-index">
|
||||
<xsl:if test="
|
||||
count(PageTitle/@id) > 0 and
|
||||
(count(Signature/@id) > 0 or count(Signature/div/@id) > 0) and
|
||||
count(Remarks/@id) > 0 and
|
||||
count(Members/@id) > 0
|
||||
">
|
||||
<div class="SideBar">
|
||||
<p>
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
<xsl:text>#</xsl:text>
|
||||
<xsl:value-of select="PageTitle/@id" />
|
||||
</xsl:attribute>
|
||||
<xsl:text>Overview</xsl:text>
|
||||
</a>
|
||||
</p>
|
||||
<p>
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
<xsl:text>#</xsl:text>
|
||||
<xsl:value-of select="Signature/@id" />
|
||||
<xsl:value-of select="Signature/div/@id" />
|
||||
</xsl:attribute>
|
||||
<xsl:text>Signature</xsl:text>
|
||||
</a>
|
||||
</p>
|
||||
<p>
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
<xsl:text>#</xsl:text>
|
||||
<xsl:value-of select="Remarks/@id" />
|
||||
</xsl:attribute>
|
||||
<xsl:text>Remarks</xsl:text>
|
||||
</a>
|
||||
</p>
|
||||
<p>
|
||||
<a href="#Members">Members</a>
|
||||
</p>
|
||||
<p>
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
<xsl:text>#</xsl:text>
|
||||
<xsl:value-of select="Members/@id" />
|
||||
</xsl:attribute>
|
||||
<xsl:text>Member Details</xsl:text>
|
||||
</a>
|
||||
</p>
|
||||
</div>
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-default-collection-title">
|
||||
<div class="CollectionTitle">
|
||||
<xsl:apply-templates select="CollectionTitle/node()" />
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-default-title">
|
||||
<h1 class="PageTitle">
|
||||
<xsl:if test="count(PageTitle/@id) > 0">
|
||||
<xsl:attribute name="id">
|
||||
<xsl:value-of select="PageTitle/@id" />
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
<xsl:apply-templates select="PageTitle/node()" />
|
||||
</h1>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-default-summary">
|
||||
<p class="Summary">
|
||||
<xsl:if test="count(Summary/@id) > 0">
|
||||
<xsl:attribute name="id">
|
||||
<xsl:value-of select="Summary/@id" />
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
<xsl:apply-templates select="Summary/node()" />
|
||||
</p>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-default-signature">
|
||||
<div>
|
||||
<xsl:if test="count(Signature/@id) > 0">
|
||||
<xsl:attribute name="id">
|
||||
<xsl:value-of select="Signature/@id" />
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
<xsl:apply-templates select="Signature/node()" />
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-default-remarks">
|
||||
<div class="Remarks">
|
||||
<xsl:if test="count(Remarks/@id) > 0">
|
||||
<xsl:attribute name="id">
|
||||
<xsl:value-of select="Remarks/@id" />
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
<xsl:apply-templates select="Remarks/node()" />
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-default-members">
|
||||
<div class="Members">
|
||||
<xsl:if test="count(Members/@id) > 0">
|
||||
<xsl:attribute name="id">
|
||||
<xsl:value-of select="Members/@id" />
|
||||
</xsl:attribute>
|
||||
</xsl:if>
|
||||
<xsl:apply-templates select="Members/node()" />
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="create-default-copyright">
|
||||
<div class="Copyright">
|
||||
<xsl:apply-templates select="Copyright/node()" />
|
||||
</div>
|
||||
</xsl:template>
|
||||
</xsl:stylesheet>
|
||||
1180
external/api-doc-tools/mdoc/Resources/monodoc-ecma.xsd
vendored
Normal file
1180
external/api-doc-tools/mdoc/Resources/monodoc-ecma.xsd
vendored
Normal file
File diff suppressed because it is too large
Load Diff
303
external/api-doc-tools/mdoc/Resources/msitomsx.xsl
vendored
Normal file
303
external/api-doc-tools/mdoc/Resources/msitomsx.xsl
vendored
Normal file
@@ -0,0 +1,303 @@
|
||||
<?xml version="1.0"?>
|
||||
<!--
|
||||
Converts the "Microsoft Internal XML Documentation Format" into the
|
||||
"Microsoft XML Documentation Format".
|
||||
|
||||
The "Microsoft Internal XML Documentation Format" (msidoc) is whatever XML
|
||||
format is used within Microsoft to document the BCL, as deduced from reading
|
||||
their ECMA documentation dump.
|
||||
|
||||
The "Microsoft XML Documentation Format" (msxdoc) is what 'gmcs /doc'
|
||||
produces, and is documented in ECMA 334 §E.
|
||||
|
||||
msidoc is similar, but not identical to, msxdoc. For example, where msxdoc
|
||||
uses <see cref="FOO"/>, msidoc uses
|
||||
<codeEntityReference>FOO</codeEntityReference>. They also introduce
|
||||
additional "wrapping" elements in various places (e.g. <content/>), useful
|
||||
extensions (such as documenting method overload lists), and other oddities.
|
||||
-->
|
||||
<xsl:stylesheet
|
||||
version="1.0"
|
||||
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
|
||||
xmlns:authoring="http://ddue.schemas.microsoft.com/authoring/2003/5"
|
||||
exclude-result-prefixes="msxsl authoring"
|
||||
>
|
||||
|
||||
<xsl:output omit-xml-declaration="yes" />
|
||||
|
||||
<xsl:template match="assembly" />
|
||||
<xsl:template match="authoring:changeHistory" />
|
||||
<xsl:template match="authoring:clsCompliantAlternative" />
|
||||
<xsl:template match="authoring:internalOnly" />
|
||||
<xsl:template match="authoring:notesForCallers" />
|
||||
<xsl:template match="authoring:notesForImplementers" />
|
||||
<xsl:template match="authoring:notesForInheritors" />
|
||||
<xsl:template match="authoring:overload" />
|
||||
<xsl:template match="authoring:platformNotes" />
|
||||
<xsl:template match="authoring:relatedTopics" />
|
||||
<xsl:template match="authoring:sections" />
|
||||
|
||||
<xsl:template match="member">
|
||||
<!-- skip Overload: members, as these have no msxdoc equivalent. -->
|
||||
<xsl:if test="not (starts-with (@name, 'Overload:'))">
|
||||
<member name="{@name}">
|
||||
<xsl:apply-templates />
|
||||
</member>
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:remarks">
|
||||
<remarks>
|
||||
<xsl:apply-templates />
|
||||
<xsl:for-each select="../authoring:notesForInheritors">
|
||||
<block subset="none" type="overrides">
|
||||
<xsl:apply-templates />
|
||||
</block>
|
||||
</xsl:for-each>
|
||||
<xsl:for-each select="../authoring:notesForImplementers">
|
||||
<block subset="none" type="behaviors">
|
||||
<xsl:apply-templates />
|
||||
</block>
|
||||
</xsl:for-each>
|
||||
<xsl:for-each select="../authoring:notesForCallers">
|
||||
<block subset="none" type="usage">
|
||||
<xsl:apply-templates />
|
||||
</block>
|
||||
</xsl:for-each>
|
||||
</remarks>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:dduexml" >
|
||||
<xsl:apply-templates />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:codeEntityReference">
|
||||
<see cref="{.}" />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:equivalentCodeEntity">
|
||||
<seealso cref="{authoring:codeEntityReference}" />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:codeInline">
|
||||
<c>
|
||||
<xsl:apply-templates />
|
||||
</c>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:codeReference">
|
||||
<code src="{.}" />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:parameters">
|
||||
<xsl:apply-templates />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:parameter">
|
||||
<param name="{authoring:parameterReference}">
|
||||
<xsl:for-each select="*">
|
||||
<xsl:if test="not (position () = 1)">
|
||||
<xsl:apply-templates />
|
||||
</xsl:if>
|
||||
</xsl:for-each>
|
||||
</param>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:genericParameters">
|
||||
<xsl:apply-templates />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:genericParameter">
|
||||
<typeparam name="{authoring:parameterReference}">
|
||||
<xsl:for-each select="*">
|
||||
<xsl:if test="not (position () = 1)">
|
||||
<xsl:apply-templates />
|
||||
</xsl:if>
|
||||
</xsl:for-each>
|
||||
</typeparam>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:parameterReference">
|
||||
<paramref name="{.}" />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:returnValue">
|
||||
<returns>
|
||||
<xsl:apply-templates />
|
||||
</returns>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:exceptions">
|
||||
<xsl:apply-templates />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:exception">
|
||||
<exception cref="{authoring:codeEntityReference}">
|
||||
<xsl:apply-templates select="authoring:content" />
|
||||
</exception>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:codeExamples">
|
||||
<xsl:apply-templates />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:codeExample">
|
||||
<xsl:choose>
|
||||
<xsl:when test="count(authoring:legacy) > 0">
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<example>
|
||||
<xsl:apply-templates select="authoring:description/authoring:content" />
|
||||
<xsl:apply-templates select="authoring:codeReference" />
|
||||
</example>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:content">
|
||||
<xsl:apply-templates />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:languageKeyword">
|
||||
<see langword="{.}" />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:table">
|
||||
<list type="table">
|
||||
<xsl:apply-templates />
|
||||
</list>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:tableHeader">
|
||||
<listheader>
|
||||
<xsl:for-each select="authoring:row/authoring:entry">
|
||||
<xsl:choose>
|
||||
<xsl:when test="position() = 1">
|
||||
<term>
|
||||
<xsl:apply-templates />
|
||||
</term>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<description>
|
||||
<xsl:apply-templates />
|
||||
</description>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:for-each>
|
||||
</listheader>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:row">
|
||||
<item>
|
||||
<xsl:for-each select="authoring:entry">
|
||||
<xsl:choose>
|
||||
<xsl:when test="position() = 1">
|
||||
<term>
|
||||
<xsl:apply-templates />
|
||||
</term>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<description>
|
||||
<xsl:apply-templates />
|
||||
</description>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:for-each>
|
||||
</item>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:list">
|
||||
<list type="{@class}">
|
||||
<xsl:apply-templates />
|
||||
</list>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:listItem">
|
||||
<item><term>
|
||||
<xsl:apply-templates />
|
||||
</term></item>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:alert">
|
||||
<block subset="none" type="note">
|
||||
<xsl:apply-templates />
|
||||
</block>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:permissions">
|
||||
<xsl:apply-templates />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:permission">
|
||||
<permission cref="{authoring:codeEntityReference}">
|
||||
<xsl:apply-templates select="authoring:content" />
|
||||
</permission>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:threadSafety">
|
||||
<threadsafe>
|
||||
<xsl:apply-templates />
|
||||
</threadsafe>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:embeddedLabel">
|
||||
<i>
|
||||
<xsl:value-of select="." />
|
||||
<xsl:text>:</xsl:text>
|
||||
</i>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:externalLink">
|
||||
<format type="text/html">
|
||||
<a href="{authoring:linkUri}">
|
||||
<xsl:value-of select="authoring:linkText" />
|
||||
</a>
|
||||
</format>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:legacyLink">
|
||||
<i>
|
||||
<xsl:value-of select="." />
|
||||
</i>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:legacyItalic">
|
||||
<i>
|
||||
<xsl:value-of select="." />
|
||||
</i>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="authoring:token">
|
||||
<xsl:choose>
|
||||
<xsl:when test=". = 'compact_v20_long'">
|
||||
<xsl:text>.NET Compact Framework version 2.0</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:when test=". = 'compact_v35_long'">
|
||||
<xsl:text>.NET Compact Framework version 3.5</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:when test=". = 'dnprdnext'">
|
||||
<xsl:text>.NET Framework version 2.0</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:when test=". = 'vbprvbext'">
|
||||
<xsl:text>Microsoft Visual Basic 2005</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:when test=". = 'vbprvblong'">
|
||||
<xsl:text>Visual Basic 2005</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:text>UNKNOWN_TOKEN(</xsl:text>
|
||||
<xsl:value-of select="." />
|
||||
<xsl:text>)</xsl:text>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:template>
|
||||
|
||||
<!-- cute trick to remove the xmlns attributes on copied nodes. -->
|
||||
<xsl:template match="*">
|
||||
<xsl:element name="{local-name()}">
|
||||
<xsl:apply-templates />
|
||||
</xsl:element>
|
||||
</xsl:template>
|
||||
</xsl:stylesheet>
|
||||
|
||||
198
external/api-doc-tools/mdoc/Resources/overview.xsl
vendored
Normal file
198
external/api-doc-tools/mdoc/Resources/overview.xsl
vendored
Normal file
@@ -0,0 +1,198 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
<!--
|
||||
Based on Mono's /monodoc/browser/mono-ecma.xsl file.
|
||||
-->
|
||||
|
||||
<xsl:stylesheet
|
||||
version="1.0"
|
||||
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
|
||||
exclude-result-prefixes="msxsl"
|
||||
>
|
||||
|
||||
<xsl:output omit-xml-declaration="yes" />
|
||||
|
||||
<xsl:include href="stylesheet.xsl"/>
|
||||
|
||||
<xsl:param name="namespace" select="''"/>
|
||||
|
||||
<xsl:variable name="max-types">50</xsl:variable>
|
||||
|
||||
<xsl:template match="Overview">
|
||||
<Page>
|
||||
|
||||
<Title>
|
||||
<xsl:value-of select="Title"/>
|
||||
<xsl:if test="not($namespace='' or $namespace='all' or count(Types/Namespace)=1)">
|
||||
<xsl:value-of select="': '"/>
|
||||
<xsl:value-of select="$namespace"/>
|
||||
</xsl:if>
|
||||
</Title>
|
||||
|
||||
<CollectionTitle>
|
||||
<xsl:if test="not($namespace='' or $namespace='all')">
|
||||
<a href="../index.{$ext}"><xsl:value-of select="Title"/></a>
|
||||
</xsl:if>
|
||||
</CollectionTitle>
|
||||
|
||||
<PageTitle>
|
||||
<xsl:choose>
|
||||
<xsl:when test="not($namespace='' or $namespace='all')">
|
||||
<xsl:call-template name="GetNamespaceName">
|
||||
<xsl:with-param name="ns" select="$namespace" />
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="Title"/>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</PageTitle>
|
||||
|
||||
<!--
|
||||
<SideBar>
|
||||
<xsl:if test="not($namespace='')">
|
||||
<p style="font-weight: bold; border-bottom: thin solid black"><a href="../index.{$ext}"><xsl:value-of select="Assembly"/></a></p>
|
||||
<xsl:for-each select="Types/Namespace">
|
||||
<xsl:sort select="@Name"/>
|
||||
<div>
|
||||
<a href="../{@Name}/index.{$ext}">
|
||||
<xsl:value-of select="@Name"/>
|
||||
</a>
|
||||
</div>
|
||||
</xsl:for-each>
|
||||
</xsl:if>
|
||||
<xsl:if test="$namespace=''">
|
||||
<div class="AssemblyRemarks" style="margin-top: 1em; margin-bottom: 1em">
|
||||
<xsl:apply-templates select="Remarks" mode="notoppara"/>
|
||||
</div>
|
||||
</xsl:if>
|
||||
</SideBar>
|
||||
-->
|
||||
|
||||
<Summary>
|
||||
<xsl:if test="$namespace=''">
|
||||
<div class="AssemblyRemarks" style="margin-top: 1em; margin-bottom: 1em">
|
||||
<xsl:apply-templates select="Remarks" mode="notoppara"/>
|
||||
</div>
|
||||
</xsl:if>
|
||||
</Summary>
|
||||
|
||||
<Signature>
|
||||
</Signature>
|
||||
|
||||
<Remarks>
|
||||
<xsl:choose>
|
||||
<xsl:when test="Types/Namespace[@Name=$namespace][count(Type)>0] and $namespace != ''">
|
||||
<!-- show all types within namespace -->
|
||||
<h2 class="Section"><xsl:call-template name="GetNamespaceName" /></h2>
|
||||
<xsl:call-template name="CreateNamespaceDetails">
|
||||
<xsl:with-param name="ns" select="Types/Namespace[@Name=$namespace]" />
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
<xsl:when test="count(Types//Type) < $max-types">
|
||||
<!-- index; show all types -->
|
||||
<xsl:for-each select="Types/Namespace">
|
||||
<xsl:sort select="@Name"/>
|
||||
<h2 class="Section"><xsl:call-template name="CreateNamespaceLink" /></h2>
|
||||
<xsl:call-template name="CreateNamespaceDetails">
|
||||
<xsl:with-param name="ns" select="." />
|
||||
</xsl:call-template>
|
||||
</xsl:for-each>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<!-- index; show only namespaces -->
|
||||
<xsl:for-each select="Types/Namespace">
|
||||
<xsl:sort select="@Name"/>
|
||||
<h2 class="Section"><xsl:call-template name="CreateNamespaceLink" /></h2>
|
||||
<p><xsl:apply-templates select="document(concat('ns-',@Name,'.xml'), .)/Namespace/Docs/summary" mode="notoppara"/></p>
|
||||
</xsl:for-each>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
|
||||
</Remarks>
|
||||
|
||||
<Members>
|
||||
</Members>
|
||||
|
||||
<xsl:copy-of select="Copyright"/>
|
||||
|
||||
</Page>
|
||||
|
||||
</xsl:template>
|
||||
<xsl:template name="CreateNamespaceDetails">
|
||||
<xsl:param name="ns" />
|
||||
<p><xsl:apply-templates select="document(concat('ns-',$ns/@Name,'.xml'), .)/Namespace/Docs/remarks" mode="notoppara"/></p>
|
||||
|
||||
<table class="TypesListing" style="margin-top: 1em">
|
||||
|
||||
<tr>
|
||||
<th>Type</th>
|
||||
<th>Description</th>
|
||||
</tr>
|
||||
|
||||
<xsl:for-each select="$ns/Type">
|
||||
<xsl:sort select="@Name"/>
|
||||
<tr valign="top">
|
||||
<td>
|
||||
<xsl:variable name="path">
|
||||
<xsl:choose>
|
||||
<xsl:when test="$namespace=parent::Namespace/@Name">.</xsl:when>
|
||||
<xsl:otherwise><xsl:value-of select="parent::Namespace/@Name"/></xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:variable>
|
||||
|
||||
<a href="{$path}/{@Name}.{$ext}">
|
||||
<xsl:choose>
|
||||
<xsl:when test="@DisplayName != ''">
|
||||
<xsl:value-of select="translate (@DisplayName, '+', '.')"/>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="translate (@Name, '+', '.')"/>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<xsl:variable name="docdir">
|
||||
<xsl:choose>
|
||||
<xsl:when test="parent::Namespace/@Name = ''">.</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="parent::Namespace/@Name" />
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:variable>
|
||||
<xsl:apply-templates select="document(concat($docdir, '/', @Name, '.xml'), .)/Type/Docs/summary" mode="notoppara"/>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:for-each>
|
||||
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="GetNamespaceName">
|
||||
<xsl:param name="ns" select="@Name" />
|
||||
<xsl:choose>
|
||||
<xsl:when test="$ns = ''">
|
||||
<xsl:text>Root</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="$ns" />
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
<xsl:text> Namespace</xsl:text>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="CreateNamespaceLink">
|
||||
<xsl:choose>
|
||||
<xsl:when test="@Name =''">
|
||||
<xsl:call-template name="GetNamespaceName" />
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<a href="{@Name}/index.{$ext}"><xsl:call-template name="GetNamespaceName" /></a>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
|
||||
366
external/api-doc-tools/mdoc/Resources/stylesheet.xsl
vendored
Normal file
366
external/api-doc-tools/mdoc/Resources/stylesheet.xsl
vendored
Normal file
@@ -0,0 +1,366 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
<!--
|
||||
Based on Mono's /monodoc/browser/mono-ecma.xsl file.
|
||||
-->
|
||||
|
||||
<xsl:stylesheet
|
||||
version="1.0"
|
||||
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
|
||||
exclude-result-prefixes="msxsl"
|
||||
>
|
||||
<xsl:include href="mdoc-html-utils.xsl" />
|
||||
<xsl:include href="mdoc-sections-css.xsl" />
|
||||
|
||||
<!-- TEMPLATE PARAMETERS -->
|
||||
|
||||
<xsl:param name="ext" select="'xml'"/>
|
||||
<xsl:param name="basepath" select="'./'"/>
|
||||
|
||||
<xsl:param name="Index" />
|
||||
|
||||
<!-- The namespace that the current type belongs to. -->
|
||||
<xsl:variable name="mono-docs">http://www.go-mono.com/docs/monodoc.ashx?link=</xsl:variable>
|
||||
|
||||
<!-- THE MAIN RENDERING TEMPLATE -->
|
||||
|
||||
<xsl:template match="Type">
|
||||
<xsl:variable name="cref">
|
||||
<xsl:text>T:</xsl:text>
|
||||
<xsl:call-template name="GetEscapedTypeName">
|
||||
<xsl:with-param name="typename" select="@FullName" />
|
||||
</xsl:call-template>
|
||||
</xsl:variable>
|
||||
|
||||
<Page>
|
||||
|
||||
<Title>
|
||||
<xsl:value-of select="translate (@FullName, '+', '.')" />
|
||||
</Title>
|
||||
|
||||
<CollectionTitle>
|
||||
<xsl:variable name="namespace" select="substring-before (@FullName, @Name)" />
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
<xsl:if test="string-length($namespace)">
|
||||
<xsl:value-of select="$basepath" />
|
||||
</xsl:if>
|
||||
<xsl:text>index.</xsl:text>
|
||||
<xsl:value-of select="$ext" />
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="AssemblyInfo/AssemblyName" />
|
||||
</a>
|
||||
<xsl:text> : </xsl:text>
|
||||
<a href="index.{$ext}"><xsl:value-of select="$TypeNamespace"/> Namespace</a>
|
||||
</CollectionTitle>
|
||||
|
||||
<PageTitle>
|
||||
<xsl:attribute name="id">
|
||||
<xsl:value-of select="$cref" />
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="translate (@Name, '+', '.')"/>
|
||||
<xsl:text xml:space="preserve"> </xsl:text>
|
||||
<xsl:if test="count(Docs/typeparam) > 0">Generic</xsl:if>
|
||||
<xsl:text xml:space="preserve"> </xsl:text>
|
||||
<xsl:call-template name="GetTypeDescription" />
|
||||
</PageTitle>
|
||||
|
||||
<!--
|
||||
<SideBar>
|
||||
<p style="font-weight: bold; border-bottom: thin solid black"><a href="index.{$ext}"><xsl:value-of select="$TypeNamespace"/></a></p>
|
||||
|
||||
<xsl:for-each select="document('index.xml',.)/Overview/Types/Namespace[@Name=$TypeNamespace]/Type">
|
||||
<xsl:sort select="@Name"/>
|
||||
<div>
|
||||
<a href="../{parent::Namespace/@Name}/{@Name}.{$ext}">
|
||||
<xsl:value-of select="@Name"/>
|
||||
</a>
|
||||
</div>
|
||||
</xsl:for-each>
|
||||
</SideBar>
|
||||
-->
|
||||
|
||||
<!-- TYPE OVERVIEW -->
|
||||
|
||||
<Summary id="Summary">
|
||||
<xsl:attribute name="id">
|
||||
<xsl:value-of select="concat ($cref, ':Summary')" />
|
||||
</xsl:attribute>
|
||||
<!-- summary -->
|
||||
<xsl:apply-templates select="Docs/summary" mode="notoppara"/>
|
||||
</Summary>
|
||||
|
||||
<Signature>
|
||||
<xsl:call-template name="CreateTypeSignature" />
|
||||
</Signature>
|
||||
|
||||
<Remarks>
|
||||
<xsl:attribute name="id">
|
||||
<xsl:value-of select="concat ($cref, ':Docs')" />
|
||||
</xsl:attribute>
|
||||
<xsl:call-template name="DisplayDocsInformation">
|
||||
<xsl:with-param name="linkid" select="concat ($cref, ':Docs')" />
|
||||
</xsl:call-template>
|
||||
|
||||
<!-- MEMBER LISTING -->
|
||||
<xsl:if test="not(Base/BaseTypeName='System.Delegate' or Base/BaseTypeName='System.MulticastDelegate' or Base/BaseTypeName='System.Enum')">
|
||||
<xsl:call-template name="CreateH2Section">
|
||||
<xsl:with-param name="name" select="'Members'"/>
|
||||
<xsl:with-param name="id" select="'Members'"/>
|
||||
<xsl:with-param name="child-id" select="'_Members'"/>
|
||||
<xsl:with-param name="content">
|
||||
<xsl:if test="Base/BaseTypeName">
|
||||
<p>
|
||||
See Also: Inherited members from
|
||||
<xsl:apply-templates select="Base/BaseTypeName" mode="typelink"><xsl:with-param name="wrt" select="$TypeNamespace"/></xsl:apply-templates>.
|
||||
</p>
|
||||
</xsl:if>
|
||||
|
||||
<!-- list each type of member (public, then protected) -->
|
||||
|
||||
<xsl:call-template name="ListAllMembers">
|
||||
<xsl:with-param name="html-anchor" select="true()" />
|
||||
</xsl:call-template>
|
||||
</xsl:with-param>
|
||||
</xsl:call-template>
|
||||
</xsl:if>
|
||||
|
||||
</Remarks>
|
||||
|
||||
<Members>
|
||||
<!-- MEMBER DETAILS -->
|
||||
<xsl:attribute name="id">
|
||||
<xsl:value-of select="concat ($cref, ':Members')" />
|
||||
</xsl:attribute>
|
||||
<xsl:if test="not(Base/BaseTypeName='System.Delegate' or Base/BaseTypeName='System.MulticastDelegate' or Base/BaseTypeName='System.Enum')">
|
||||
<xsl:variable name="Type" select="."/>
|
||||
|
||||
<xsl:call-template name="CreateH2Section">
|
||||
<xsl:with-param name="name" select="'Member Details'"/>
|
||||
<xsl:with-param name="id" select="'MemberDetails'"/>
|
||||
<xsl:with-param name="child-id" select="'_MemberDetails'"/>
|
||||
<xsl:with-param name="content">
|
||||
<xsl:for-each select="Members/Member[MemberType != 'ExtensionMethod']">
|
||||
|
||||
<xsl:variable name="linkid">
|
||||
<xsl:call-template name="GetLinkId">
|
||||
<xsl:with-param name="type" select="../.." />
|
||||
<xsl:with-param name="member" select="." />
|
||||
</xsl:call-template>
|
||||
</xsl:variable>
|
||||
|
||||
<xsl:call-template name="CreateH3Section">
|
||||
<xsl:with-param name="id" select="$linkid" />
|
||||
<xsl:with-param name="child-id" select="concat($linkid, ':member')" />
|
||||
<xsl:with-param name="class" select="MemberName" />
|
||||
<xsl:with-param name="name">
|
||||
<xsl:choose>
|
||||
<xsl:when test="MemberType='Constructor'">
|
||||
<xsl:call-template name="GetConstructorName">
|
||||
<xsl:with-param name="type" select="../.." />
|
||||
<xsl:with-param name="ctor" select="." />
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
<xsl:when test="@MemberName='op_Implicit' or @MemberName='op_Explicit'">
|
||||
<xsl:text>Conversion</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="@MemberName"/>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
<xsl:text xml:space="preserve"> </xsl:text>
|
||||
<xsl:if test="count(Docs/typeparam) > 0">
|
||||
<xsl:text>Generic </xsl:text>
|
||||
</xsl:if>
|
||||
<xsl:value-of select="MemberType" />
|
||||
</xsl:with-param>
|
||||
<xsl:with-param name="ref" select="." />
|
||||
<xsl:with-param name="content">
|
||||
<xsl:call-template name="CreateMemberOverview" />
|
||||
<xsl:call-template name="CreateMemberSignature">
|
||||
<xsl:with-param name="linkid" select="$linkid" />
|
||||
</xsl:call-template>
|
||||
<xsl:call-template name="DisplayDocsInformation">
|
||||
<xsl:with-param name="linkid" select="$linkid" />
|
||||
</xsl:call-template>
|
||||
<hr size="1"/>
|
||||
</xsl:with-param>
|
||||
</xsl:call-template>
|
||||
</xsl:for-each>
|
||||
</xsl:with-param>
|
||||
</xsl:call-template>
|
||||
</xsl:if>
|
||||
|
||||
</Members>
|
||||
|
||||
<Copyright>
|
||||
</Copyright>
|
||||
|
||||
</Page>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="GetLinkTarget">
|
||||
<xsl:param name="type" />
|
||||
<xsl:param name="cref" />
|
||||
<xsl:param name="xmltarget" select="false()"/>
|
||||
<!-- Search for type in the index.xml file. -->
|
||||
<xsl:variable name="typeentry-rtf">
|
||||
<xsl:call-template name="FindTypeInIndex">
|
||||
<xsl:with-param name="type" select="$type" />
|
||||
</xsl:call-template>
|
||||
</xsl:variable>
|
||||
<xsl:variable name="typeentry" select="msxsl:node-set($typeentry-rtf)" />
|
||||
|
||||
<xsl:choose>
|
||||
<xsl:when test="$xmltarget and count($typeentry/Type)">
|
||||
<xsl:value-of select="concat($typeentry/Type/@Namespace, '/', $typeentry/Type/@Name, '.xml')" />
|
||||
</xsl:when>
|
||||
<xsl:when test="$xmltarget" />
|
||||
<xsl:when test="starts-with ($cref, 'N:')">
|
||||
<xsl:variable name="namespace">
|
||||
<xsl:call-template name="FindNamespaceInIndex">
|
||||
<xsl:with-param name="namespace" select="substring-after ($cref, 'N:')" />
|
||||
</xsl:call-template>
|
||||
</xsl:variable>
|
||||
<xsl:if test="string($namespace) != ''">
|
||||
<xsl:if test="$TypeNamespace != ''">
|
||||
<xsl:value-of select="$basepath" />
|
||||
</xsl:if>
|
||||
<xsl:value-of select="concat ($namespace, '/index.', $ext)" />
|
||||
</xsl:if>
|
||||
</xsl:when>
|
||||
<xsl:when test="count($typeentry/Type)">
|
||||
<xsl:if test="string-length ($typeentry/Type/@Namespace)">
|
||||
<xsl:value-of select="$basepath" />
|
||||
<xsl:value-of select="$typeentry/Type/@Namespace" />
|
||||
<xsl:text>/</xsl:text>
|
||||
</xsl:if>
|
||||
<xsl:value-of select="$typeentry/Type/@Name"/>
|
||||
<xsl:text>.</xsl:text>
|
||||
<xsl:value-of select="$ext" />
|
||||
<xsl:if test="string-length ($cref) > 0 and substring ($cref, 1, 2) != 'T:'">
|
||||
<xsl:text>#</xsl:text>
|
||||
<xsl:call-template name="GetActualCref">
|
||||
<xsl:with-param name="cref" select="$cref" />
|
||||
</xsl:call-template>
|
||||
</xsl:if>
|
||||
</xsl:when>
|
||||
|
||||
<xsl:when test="starts-with($type, 'System.') or
|
||||
starts-with($type, 'Cairo.') or starts-with ($type, 'Commons.Xml.') or
|
||||
starts-with($type, 'Mono.GetOptions.') or starts-with($type,'Mono.Math.') or
|
||||
starts-with($type, 'Mono.Posix.') or starts-with($type, 'Mono.Remoting.') or
|
||||
starts-with($type, 'Mono.Security.') or starts-with($type, 'Mono.Unix.') or
|
||||
starts-with($type, 'Mono.Xml.')">
|
||||
<xsl:value-of select="$mono-docs" />
|
||||
<xsl:value-of select="$cref" />
|
||||
</xsl:when>
|
||||
<!--<xsl:otherwise>javascript:alert("Documentation not found for <xsl:value-of select="$type"/>.")</xsl:otherwise>-->
|
||||
</xsl:choose>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="FindTypeInIndex">
|
||||
<xsl:param name="type" />
|
||||
|
||||
<xsl:for-each select="$Index//Type">
|
||||
<xsl:variable name="nsp">
|
||||
<xsl:choose>
|
||||
<xsl:when test="string-length (parent::Namespace/@Name) = 0" />
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="parent::Namespace/@Name" />
|
||||
<xsl:text>.</xsl:text>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:variable>
|
||||
<xsl:if test="concat($nsp, translate(@Name, '+', '.')) = $type">
|
||||
<Type Name="{@Name}" Namespace="{parent::Namespace/@Name}" />
|
||||
</xsl:if>
|
||||
</xsl:for-each>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="FindNamespaceInIndex">
|
||||
<xsl:param name="namespace" />
|
||||
|
||||
<xsl:for-each select="$Index//Namespace">
|
||||
<xsl:if test="@Name = $namespace">
|
||||
<xsl:value-of select="@Name" />
|
||||
</xsl:if>
|
||||
</xsl:for-each>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="GetActualCref">
|
||||
<xsl:param name="cref" />
|
||||
|
||||
<xsl:variable name="fullname">
|
||||
<xsl:choose>
|
||||
<xsl:when test="starts-with($cref, 'C:') or starts-with($cref, 'T:')">
|
||||
<xsl:choose>
|
||||
<xsl:when test="contains($cref, '(')">
|
||||
<xsl:value-of select="substring (substring-before ($cref, '('), 3)" />
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="substring($cref, 3)" />
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:call-template name="GetTypeName">
|
||||
<xsl:with-param name="type" select="substring($cref, 3)"/>
|
||||
</xsl:call-template>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:variable>
|
||||
|
||||
<xsl:variable name="escaped-type">
|
||||
<xsl:call-template name="GetEscapedTypeName">
|
||||
<xsl:with-param name="typename">
|
||||
<xsl:call-template name="ToBrackets">
|
||||
<xsl:with-param name="s" select="$fullname" />
|
||||
</xsl:call-template>
|
||||
</xsl:with-param>
|
||||
</xsl:call-template>
|
||||
</xsl:variable>
|
||||
|
||||
<xsl:value-of select="substring ($cref, 1, 2)" />
|
||||
<xsl:value-of select="$escaped-type" />
|
||||
<xsl:value-of select="substring-after ($cref, $fullname)" />
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="CreateCodeBlock">
|
||||
<xsl:param name="language" />
|
||||
<xsl:param name="content" />
|
||||
<table class="CodeExampleTable">
|
||||
<tr><td><b><font size="-1"><xsl:value-of select="$language"/> Example</font></b></td></tr>
|
||||
<tr><td>
|
||||
<pre>
|
||||
<xsl:attribute name="class">
|
||||
<xsl:call-template name="GetCodeClass">
|
||||
<xsl:with-param name="lang" select="$language" />
|
||||
</xsl:call-template>
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="$content" />
|
||||
</pre>
|
||||
</td></tr>
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="CreateEditLink">
|
||||
<!-- ignore -->
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="CreateExpandedToggle">
|
||||
<xsl:text>⊟</xsl:text>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="GetCodeClass">
|
||||
<xsl:param name="lang" />
|
||||
|
||||
<xsl:choose>
|
||||
<xsl:when test="$lang = 'C#' or $lang = 'csharp'">
|
||||
<xsl:text>code-csharp</xsl:text>
|
||||
</xsl:when>
|
||||
</xsl:choose>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
Reference in New Issue
Block a user