summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDimitri van Heesch <dimitri@stack.nl>2017-12-24 09:32:52 (GMT)
committerGitHub <noreply@github.com>2017-12-24 09:32:52 (GMT)
commit8acdd3ca5719be461674847341a6d9f93a27f367 (patch)
treea921c2c182a3a609bb86f68475c878a29180ff37
parent2ceb8cd0748701376362fee28ecf2b4b80fc47a6 (diff)
parentfe760977e2cb643b94fbf21847e0c81e8a080966 (diff)
downloadDoxygen-8acdd3ca5719be461674847341a6d9f93a27f367.zip
Doxygen-8acdd3ca5719be461674847341a6d9f93a27f367.tar.gz
Doxygen-8acdd3ca5719be461674847341a6d9f93a27f367.tar.bz2
Merge pull request #625 from mosra/xml-tableofcontents
Expose TOC placeholder in XML output
-rw-r--r--src/xmlgen.cpp4
-rw-r--r--templates/xml/compound.xsd1
-rw-r--r--testing/043/mypage.xml1
-rw-r--r--testing/043_page.dox2
4 files changed, 8 insertions, 0 deletions
diff --git a/src/xmlgen.cpp b/src/xmlgen.cpp
index a2ed2ba..6e8c4cc 100644
--- a/src/xmlgen.cpp
+++ b/src/xmlgen.cpp
@@ -1827,6 +1827,10 @@ static void generateXMLForPage(PageDef *pd,FTextStream &ti,bool isExample)
}
}
writeInnerPages(pd->getSubPages(),t);
+ if(pd->showToc())
+ {
+ t << " <tableofcontents/>" << endl;
+ }
t << " <briefdescription>" << endl;
writeXMLDocBlock(t,pd->briefFile(),pd->briefLine(),pd,0,pd->briefDescription());
t << " </briefdescription>" << endl;
diff --git a/templates/xml/compound.xsd b/templates/xml/compound.xsd
index efe1481..82538e6 100644
--- a/templates/xml/compound.xsd
+++ b/templates/xml/compound.xsd
@@ -29,6 +29,7 @@
<xsd:element name="innergroup" type="refType" minOccurs="0" maxOccurs="unbounded" />
<xsd:element name="templateparamlist" type="templateparamlistType" minOccurs="0" />
<xsd:element name="sectiondef" type="sectiondefType" minOccurs="0" maxOccurs="unbounded" />
+ <xsd:element name="tableofcontents" minOccurs="0" maxOccurs="1" />
<xsd:element name="briefdescription" type="descriptionType" minOccurs="0" />
<xsd:element name="detaileddescription" type="descriptionType" minOccurs="0" />
<xsd:element name="inheritancegraph" type="graphType" minOccurs="0" />
diff --git a/testing/043/mypage.xml b/testing/043/mypage.xml
index 589df5b..79fb7ae 100644
--- a/testing/043/mypage.xml
+++ b/testing/043/mypage.xml
@@ -4,6 +4,7 @@
<compoundname>mypage</compoundname>
<title>Page Title</title>
<innerpage refid="another">Another Page</innerpage>
+ <tableofcontents/>
<briefdescription>
<para>Page brief description. </para>
</briefdescription>
diff --git a/testing/043_page.dox b/testing/043_page.dox
index 096f998..38c1894 100644
--- a/testing/043_page.dox
+++ b/testing/043_page.dox
@@ -4,6 +4,8 @@
/** \page mypage Page Title
* \brief Page brief description.
*
+ * @tableofcontents
+ *
* Text at page level. See \ref mysect for more.
* \section mysect Section Title.
* Text at section level. See \ref mysubsect for more.