]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetTOC.cpp
DocBook: escape IDs for InsetRef.
[lyx.git] / src / insets / InsetTOC.cpp
index a3739d74f51a4deb52de231c760e1c0b3cbd8b9e..4469b88939d72b9d259b86a600f110032d7e9e48 100644 (file)
@@ -128,11 +128,10 @@ int InsetTOC::plaintext(odocstringstream & os,
 }
 
 
-int InsetTOC::docbook(odocstream & os, OutputParams const &) const
+void InsetTOC::docbook(XMLStream &, OutputParams const &) const
 {
-       if (getCmdName() == "tableofcontents")
-               os << "<toc></toc>";
-       return 0;
+       // TOC are generated automatically by the DocBook processor.
+       return;
 }
 
 
@@ -169,7 +168,7 @@ void InsetTOC::makeTOCWithDepth(XMLStream & xs,
                        continue;
 
                // First, we need to manage increases and decreases of depth
-               // If there's no depth to deal with, we artifically set it to 1.
+               // If there's no depth to deal with, we artificially set it to 1.
                int const depth = it->depth();
 
                // Ignore stuff above the tocdepth