summaryrefslogtreecommitdiffstats
path: root/src/xmldocvisitor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/xmldocvisitor.cpp')
-rw-r--r--src/xmldocvisitor.cpp294
1 files changed, 171 insertions, 123 deletions
diff --git a/src/xmldocvisitor.cpp b/src/xmldocvisitor.cpp
index 019bef1..73aac7c 100644
--- a/src/xmldocvisitor.cpp
+++ b/src/xmldocvisitor.cpp
@@ -1,13 +1,10 @@
/******************************************************************************
*
- *
- *
- *
- * Copyright (C) 1997-2015 by Dimitri van Heesch.
+ * Copyright (C) 1997-2020 by Dimitri van Heesch.
*
* Permission to use, copy, modify, and distribute this software and its
- * documentation under the terms of the GNU General Public License is hereby
- * granted. No representations are made about the suitability of this software
+ * documentation under the terms of the GNU General Public License is hereby
+ * granted. No representations are made about the suitability of this software
* for any purpose. It is provided "as is" without express or implied warranty.
* See the GNU General Public License for more details.
*
@@ -16,7 +13,7 @@
*
*/
-#include <qfileinfo.h>
+#include <qfileinfo.h>
#include "xmldocvisitor.h"
#include "docparser.h"
@@ -32,6 +29,7 @@
#include "config.h"
#include "htmlentity.h"
#include "emoji.h"
+#include "filedef.h"
static void visitCaption(XmlDocVisitor *parent, QList<DocNode> children)
{
@@ -40,9 +38,9 @@ static void visitCaption(XmlDocVisitor *parent, QList<DocNode> children)
for (cli.toFirst();(n=cli.current());++cli) n->accept(parent);
}
-static void visitPreStart(FTextStream &t, const char *cmd, bool doCaption,
- XmlDocVisitor *parent, QList<DocNode> children,
- const QCString &name, bool writeType, DocImage::Type type, const QCString &width,
+static void visitPreStart(FTextStream &t, const char *cmd, bool doCaption,
+ XmlDocVisitor *parent, QList<DocNode> children,
+ const QCString &name, bool writeType, DocImage::Type type, const QCString &width,
const QCString &height, bool inlineImage = FALSE)
{
t << "<" << cmd;
@@ -88,8 +86,8 @@ static void visitPostEnd(FTextStream &t, const char *cmd)
t << "</" << cmd << ">" << endl;
}
-XmlDocVisitor::XmlDocVisitor(FTextStream &t,CodeOutputInterface &ci)
- : DocVisitor(DocVisitor_XML), m_t(t), m_ci(ci), m_insidePre(FALSE), m_hide(FALSE)
+XmlDocVisitor::XmlDocVisitor(FTextStream &t,CodeOutputInterface &ci)
+ : DocVisitor(DocVisitor_XML), m_t(t), m_ci(ci), m_insidePre(FALSE), m_hide(FALSE)
{
}
@@ -159,7 +157,7 @@ void XmlDocVisitor::visit(DocEmoji *s)
void XmlDocVisitor::visit(DocURL *u)
{
if (m_hide) return;
- m_t << "<ulink url=\"";
+ m_t << "<ulink url=\"";
if (u->isEmail()) m_t << "mailto:";
filter(u->url());
m_t << "\">";
@@ -221,12 +219,12 @@ void XmlDocVisitor::visit(DocStyleChange *s)
if (s->enable()) m_t << "<small>"; else m_t << "</small>";
break;
case DocStyleChange::Preformatted:
- if (s->enable())
+ if (s->enable())
{
- m_t << "<preformatted>";
+ m_t << "<preformatted>";
m_insidePre=TRUE;
}
- else
+ else
{
m_t << "</preformatted>";
m_insidePre=FALSE;
@@ -254,17 +252,16 @@ void XmlDocVisitor::visit(DocVerbatim *s)
m_t << " filename=\"" << lang << "\">";
else
m_t << ">";
- Doxygen::parserManager->getCodeParser(lang)
- .parseCode(m_ci,s->context(),s->text(),langExt,
- s->isExample(),s->exampleFile());
- m_t << "</programlisting>";
+ getCodeParser(lang).parseCode(m_ci,s->context(),s->text(),langExt,
+ s->isExample(),s->exampleFile());
+ m_t << "</programlisting>";
break;
- case DocVerbatim::Verbatim:
+ case DocVerbatim::Verbatim:
m_t << "<verbatim>";
filter(s->text());
- m_t << "</verbatim>";
+ m_t << "</verbatim>";
break;
- case DocVerbatim::HtmlOnly:
+ case DocVerbatim::HtmlOnly:
if (s->isBlock())
{
m_t << "<htmlonly block=\"yes\">";
@@ -276,17 +273,17 @@ void XmlDocVisitor::visit(DocVerbatim *s)
filter(s->text());
m_t << "</htmlonly>";
break;
- case DocVerbatim::RtfOnly:
+ case DocVerbatim::RtfOnly:
m_t << "<rtfonly>";
filter(s->text());
m_t << "</rtfonly>";
break;
- case DocVerbatim::ManOnly:
+ case DocVerbatim::ManOnly:
m_t << "<manonly>";
filter(s->text());
m_t << "</manonly>";
break;
- case DocVerbatim::LatexOnly:
+ case DocVerbatim::LatexOnly:
m_t << "<latexonly>";
filter(s->text());
m_t << "</latexonly>";
@@ -296,7 +293,7 @@ void XmlDocVisitor::visit(DocVerbatim *s)
filter(s->text());
m_t << "</docbookonly>";
break;
- case DocVerbatim::XmlOnly:
+ case DocVerbatim::XmlOnly:
m_t << s->text();
break;
case DocVerbatim::Dot:
@@ -330,12 +327,11 @@ void XmlDocVisitor::visit(DocInclude *inc)
switch(inc->type())
{
case DocInclude::IncWithLines:
- {
+ {
m_t << "<programlisting filename=\"" << inc->file() << "\">";
QFileInfo cfi( inc->file() );
FileDef *fd = createFileDef( cfi.dirPath().utf8(), cfi.fileName().utf8() );
- Doxygen::parserManager->getCodeParser(inc->extension())
- .parseCode(m_ci,inc->context(),
+ getCodeParser(inc->extension()).parseCode(m_ci,inc->context(),
inc->text(),
langExt,
inc->isExample(),
@@ -348,13 +344,12 @@ void XmlDocVisitor::visit(DocInclude *inc)
TRUE // show line numbers
);
delete fd;
- m_t << "</programlisting>";
+ m_t << "</programlisting>";
}
- break;
- case DocInclude::Include:
+ break;
+ case DocInclude::Include:
m_t << "<programlisting filename=\"" << inc->file() << "\">";
- Doxygen::parserManager->getCodeParser(inc->extension())
- .parseCode(m_ci,inc->context(),
+ getCodeParser(inc->extension()).parseCode(m_ci,inc->context(),
inc->text(),
langExt,
inc->isExample(),
@@ -366,12 +361,12 @@ void XmlDocVisitor::visit(DocInclude *inc)
0, // memberDef
FALSE // show line numbers
);
- m_t << "</programlisting>";
+ m_t << "</programlisting>";
break;
- case DocInclude::DontInclude:
- case DocInclude::DontIncWithLines:
+ case DocInclude::DontInclude:
+ case DocInclude::DontIncWithLines:
break;
- case DocInclude::HtmlInclude:
+ case DocInclude::HtmlInclude:
if (inc->isBlock())
{
m_t << "<htmlonly block=\"yes\">";
@@ -388,35 +383,51 @@ void XmlDocVisitor::visit(DocInclude *inc)
filter(inc->text());
m_t << "</latexonly>";
break;
- case DocInclude::VerbInclude:
+ case DocInclude::RtfInclude:
+ m_t << "<rtfonly>";
+ filter(inc->text());
+ m_t << "</rtfonly>";
+ break;
+ case DocInclude::ManInclude:
+ m_t << "<manonly>";
+ filter(inc->text());
+ m_t << "</manonly>";
+ break;
+ case DocInclude::XmlInclude:
+ filter(inc->text());
+ break;
+ case DocInclude::DocbookInclude:
+ m_t << "<docbookonly>";
+ filter(inc->text());
+ m_t << "</docbookonly>";
+ break;
+ case DocInclude::VerbInclude:
m_t << "<verbatim>";
filter(inc->text());
- m_t << "</verbatim>";
+ m_t << "</verbatim>";
break;
case DocInclude::Snippet:
m_t << "<programlisting filename=\"" << inc->file() << "\">";
- Doxygen::parserManager->getCodeParser(inc->extension())
- .parseCode(m_ci,
+ getCodeParser(inc->extension()).parseCode(m_ci,
inc->context(),
extractBlock(inc->text(),inc->blockId()),
langExt,
inc->isExample(),
inc->exampleFile()
);
- m_t << "</programlisting>";
+ m_t << "</programlisting>";
break;
case DocInclude::SnipWithLines:
{
m_t << "<programlisting filename=\"" << inc->file() << "\">";
QFileInfo cfi( inc->file() );
FileDef *fd = createFileDef( cfi.dirPath().utf8(), cfi.fileName().utf8() );
- Doxygen::parserManager->getCodeParser(inc->extension())
- .parseCode(m_ci,
+ getCodeParser(inc->extension()).parseCode(m_ci,
inc->context(),
extractBlock(inc->text(),inc->blockId()),
langExt,
inc->isExample(),
- inc->exampleFile(),
+ inc->exampleFile(),
fd,
lineBlock(inc->text(),inc->blockId()),
-1, // endLine
@@ -425,11 +436,11 @@ void XmlDocVisitor::visit(DocInclude *inc)
TRUE // show line number
);
delete fd;
- m_t << "</programlisting>";
+ m_t << "</programlisting>";
}
break;
- case DocInclude::SnippetDoc:
- case DocInclude::IncludeDoc:
+ case DocInclude::SnippetDoc:
+ case DocInclude::IncludeDoc:
err("Internal inconsistency: found switch SnippetDoc / IncludeDoc in file: %s"
"Please create a bug report\n",__FILE__);
break;
@@ -440,7 +451,7 @@ void XmlDocVisitor::visit(DocIncOperator *op)
{
//printf("DocIncOperator: type=%d first=%d, last=%d text='%s'\n",
// op->type(),op->isFirst(),op->isLast(),op->text().data());
- if (op->isFirst())
+ if (op->isFirst())
{
if (!m_hide)
{
@@ -452,10 +463,10 @@ void XmlDocVisitor::visit(DocIncOperator *op)
QCString locLangExt = getFileNameExtension(op->includeFileName());
if (locLangExt.isEmpty()) locLangExt = m_langExt;
SrcLangExt langExt = getLanguageFromFileName(locLangExt);
- if (op->type()!=DocIncOperator::Skip)
+ if (op->type()!=DocIncOperator::Skip)
{
popEnabled();
- if (!m_hide)
+ if (!m_hide)
{
FileDef *fd = 0;
if (!op->includeFileName().isEmpty())
@@ -464,26 +475,25 @@ void XmlDocVisitor::visit(DocIncOperator *op)
fd = createFileDef( cfi.dirPath().utf8(), cfi.fileName().utf8() );
}
- Doxygen::parserManager->getCodeParser(locLangExt)
- .parseCode(m_ci,op->context(),
- op->text(),langExt,op->isExample(),
- op->exampleFile(),
- fd, // fileDef
- op->line(), // startLine
- -1, // endLine
- FALSE, // inline fragment
- 0, // memberDef
- op->showLineNo() // show line numbers
- );
+ getCodeParser(locLangExt).parseCode(m_ci,op->context(),
+ op->text(),langExt,op->isExample(),
+ op->exampleFile(),
+ fd, // fileDef
+ op->line(), // startLine
+ -1, // endLine
+ FALSE, // inline fragment
+ 0, // memberDef
+ op->showLineNo() // show line numbers
+ );
if (fd) delete fd;
}
pushEnabled();
m_hide=TRUE;
}
- if (op->isLast())
+ if (op->isLast())
{
popEnabled();
- if (!m_hide) m_t << "</programlisting>";
+ if (!m_hide) m_t << "</programlisting>";
}
else
{
@@ -563,13 +573,13 @@ void XmlDocVisitor::visitPre(DocAutoListItem *)
m_t << "<listitem>";
}
-void XmlDocVisitor::visitPost(DocAutoListItem *)
+void XmlDocVisitor::visitPost(DocAutoListItem *)
{
if (m_hide) return;
m_t << "</listitem>";
}
-void XmlDocVisitor::visitPre(DocPara *)
+void XmlDocVisitor::visitPre(DocPara *)
{
if (m_hide) return;
m_t << "<para>";
@@ -597,21 +607,21 @@ void XmlDocVisitor::visitPre(DocSimpleSect *s)
m_t << "<simplesect kind=\"";
switch(s->type())
{
- case DocSimpleSect::See:
+ case DocSimpleSect::See:
m_t << "see"; break;
- case DocSimpleSect::Return:
+ case DocSimpleSect::Return:
m_t << "return"; break;
- case DocSimpleSect::Author:
+ case DocSimpleSect::Author:
m_t << "author"; break;
- case DocSimpleSect::Authors:
+ case DocSimpleSect::Authors:
m_t << "authors"; break;
- case DocSimpleSect::Version:
+ case DocSimpleSect::Version:
m_t << "version"; break;
- case DocSimpleSect::Since:
+ case DocSimpleSect::Since:
m_t << "since"; break;
- case DocSimpleSect::Date:
+ case DocSimpleSect::Date:
m_t << "date"; break;
- case DocSimpleSect::Note:
+ case DocSimpleSect::Note:
m_t << "note"; break;
case DocSimpleSect::Warning:
m_t << "warning"; break;
@@ -627,9 +637,9 @@ void XmlDocVisitor::visitPre(DocSimpleSect *s)
m_t << "remark"; break;
case DocSimpleSect::Attention:
m_t << "attention"; break;
- case DocSimpleSect::User:
+ case DocSimpleSect::User:
m_t << "par"; break;
- case DocSimpleSect::Rcs:
+ case DocSimpleSect::Rcs:
m_t << "rcs"; break;
case DocSimpleSect::Unknown: break;
}
@@ -672,7 +682,7 @@ void XmlDocVisitor::visitPre(DocSimpleListItem *)
m_t << "<listitem>";
}
-void XmlDocVisitor::visitPost(DocSimpleListItem *)
+void XmlDocVisitor::visitPost(DocSimpleListItem *)
{
if (m_hide) return;
m_t << "</listitem>\n";
@@ -689,7 +699,7 @@ void XmlDocVisitor::visitPre(DocSection *s)
m_t << "</title>" << endl;
}
-void XmlDocVisitor::visitPost(DocSection *s)
+void XmlDocVisitor::visitPost(DocSection *s)
{
m_t << "</sect" << s->level() << ">\n";
}
@@ -697,18 +707,18 @@ void XmlDocVisitor::visitPost(DocSection *s)
void XmlDocVisitor::visitPre(DocHtmlList *s)
{
if (m_hide) return;
- if (s->type()==DocHtmlList::Ordered)
- m_t << "<orderedlist>\n";
- else
+ if (s->type()==DocHtmlList::Ordered)
+ m_t << "<orderedlist>\n";
+ else
m_t << "<itemizedlist>\n";
}
-void XmlDocVisitor::visitPost(DocHtmlList *s)
+void XmlDocVisitor::visitPost(DocHtmlList *s)
{
if (m_hide) return;
- if (s->type()==DocHtmlList::Ordered)
- m_t << "</orderedlist>\n";
- else
+ if (s->type()==DocHtmlList::Ordered)
+ m_t << "</orderedlist>\n";
+ else
m_t << "</itemizedlist>\n";
}
@@ -718,7 +728,7 @@ void XmlDocVisitor::visitPre(DocHtmlListItem *)
m_t << "<listitem>\n";
}
-void XmlDocVisitor::visitPost(DocHtmlListItem *)
+void XmlDocVisitor::visitPost(DocHtmlListItem *)
{
if (m_hide) return;
m_t << "</listitem>\n";
@@ -730,7 +740,7 @@ void XmlDocVisitor::visitPre(DocHtmlDescList *)
m_t << "<variablelist>\n";
}
-void XmlDocVisitor::visitPost(DocHtmlDescList *)
+void XmlDocVisitor::visitPost(DocHtmlDescList *)
{
if (m_hide) return;
m_t << "</variablelist>\n";
@@ -742,7 +752,7 @@ void XmlDocVisitor::visitPre(DocHtmlDescTitle *)
m_t << "<varlistentry><term>";
}
-void XmlDocVisitor::visitPost(DocHtmlDescTitle *)
+void XmlDocVisitor::visitPost(DocHtmlDescTitle *)
{
if (m_hide) return;
m_t << "</term></varlistentry>\n";
@@ -754,7 +764,7 @@ void XmlDocVisitor::visitPre(DocHtmlDescData *)
m_t << "<listitem>";
}
-void XmlDocVisitor::visitPost(DocHtmlDescData *)
+void XmlDocVisitor::visitPost(DocHtmlDescData *)
{
if (m_hide) return;
m_t << "</listitem>\n";
@@ -763,11 +773,11 @@ void XmlDocVisitor::visitPost(DocHtmlDescData *)
void XmlDocVisitor::visitPre(DocHtmlTable *t)
{
if (m_hide) return;
- m_t << "<table rows=\"" << t->numRows()
+ m_t << "<table rows=\"" << t->numRows()
<< "\" cols=\"" << t->numColumns() << "\">" ;
}
-void XmlDocVisitor::visitPost(DocHtmlTable *)
+void XmlDocVisitor::visitPost(DocHtmlTable *)
{
if (m_hide) return;
m_t << "</table>\n";
@@ -779,7 +789,7 @@ void XmlDocVisitor::visitPre(DocHtmlRow *)
m_t << "<row>\n";
}
-void XmlDocVisitor::visitPost(DocHtmlRow *)
+void XmlDocVisitor::visitPost(DocHtmlRow *)
{
if (m_hide) return;
m_t << "</row>\n";
@@ -788,13 +798,51 @@ void XmlDocVisitor::visitPost(DocHtmlRow *)
void XmlDocVisitor::visitPre(DocHtmlCell *c)
{
if (m_hide) return;
- if (c->isHeading()) m_t << "<entry thead=\"yes\">"; else m_t << "<entry thead=\"no\">";
+ if (c->isHeading()) m_t << "<entry thead=\"yes\""; else m_t << "<entry thead=\"no\"";
+ HtmlAttribListIterator li(c->attribs());
+ HtmlAttrib *opt;
+ for (li.toFirst();(opt=li.current());++li)
+ {
+ if (opt->name=="colspan" || opt->name=="rowspan")
+ {
+ m_t << " " << opt->name << "=\"" << opt->value.toInt() << "\"";
+ }
+ else if (opt->name=="align" &&
+ (opt->value=="right" || opt->value=="left" || opt->value=="center"))
+ {
+ m_t << " align=\"" << opt->value << "\"";
+ }
+ else if (opt->name=="class") // handle markdown generated attributes
+ {
+ if (opt->value.left(13)=="markdownTable") // handle markdown generated attributes
+ {
+ if (opt->value.right(5)=="Right")
+ {
+ m_t << " align='right'";
+ }
+ else if (opt->value.right(4)=="Left")
+ {
+ m_t << " align='left'";
+ }
+ else if (opt->value.right(6)=="Center")
+ {
+ m_t << " align='center'";
+ }
+ // skip 'markdownTable*' value ending with "None"
+ }
+ else if (!opt->value.isEmpty())
+ {
+ m_t << " class=\"" << convertToXML(opt->value) << "\"";
+ }
+ }
+ }
+ m_t << ">";
}
-void XmlDocVisitor::visitPost(DocHtmlCell *)
+void XmlDocVisitor::visitPost(DocHtmlCell *)
{
if (m_hide) return;
- m_t << "</entry>";
+ m_t << "</entry>";
}
void XmlDocVisitor::visitPre(DocHtmlCaption *)
@@ -803,7 +851,7 @@ void XmlDocVisitor::visitPre(DocHtmlCaption *)
m_t << "<caption>";
}
-void XmlDocVisitor::visitPost(DocHtmlCaption *)
+void XmlDocVisitor::visitPost(DocHtmlCaption *)
{
if (m_hide) return;
m_t << "</caption>\n";
@@ -815,7 +863,7 @@ void XmlDocVisitor::visitPre(DocInternal *)
m_t << "<internal>";
}
-void XmlDocVisitor::visitPost(DocInternal *)
+void XmlDocVisitor::visitPost(DocInternal *)
{
if (m_hide) return;
m_t << "</internal>" << endl;
@@ -827,7 +875,7 @@ void XmlDocVisitor::visitPre(DocHRef *href)
m_t << "<ulink url=\"" << convertToXML(href->url(), TRUE) << "\">";
}
-void XmlDocVisitor::visitPost(DocHRef *)
+void XmlDocVisitor::visitPost(DocHRef *)
{
if (m_hide) return;
m_t << "</ulink>";
@@ -839,7 +887,7 @@ void XmlDocVisitor::visitPre(DocHtmlHeader *header)
m_t << "<heading level=\"" << header->level() << "\">";
}
-void XmlDocVisitor::visitPost(DocHtmlHeader *)
+void XmlDocVisitor::visitPost(DocHtmlHeader *)
{
if (m_hide) return;
m_t << "</heading>\n";
@@ -864,7 +912,7 @@ void XmlDocVisitor::visitPre(DocImage *img)
// copy the image to the output dir
FileDef *fd;
bool ambig;
- if (url.isEmpty() && (fd=findFileDef(Doxygen::imageNameDict,img->name(),ambig)))
+ if (url.isEmpty() && (fd=findFileDef(Doxygen::imageNameLinkedMap,img->name(),ambig)))
{
QFile inImage(fd->absFilePath());
QFile outImage(Config_getString(XML_OUTPUT)+"/"+baseName.data());
@@ -882,7 +930,7 @@ void XmlDocVisitor::visitPre(DocImage *img)
}
}
-void XmlDocVisitor::visitPost(DocImage *)
+void XmlDocVisitor::visitPost(DocImage *)
{
if (m_hide) return;
visitPostEnd(m_t, "image");
@@ -894,7 +942,7 @@ void XmlDocVisitor::visitPre(DocDotFile *df)
visitPreStart(m_t, "dotfile", FALSE, this, df->children(), df->file(), FALSE, DocImage::Html, df->width(), df->height());
}
-void XmlDocVisitor::visitPost(DocDotFile *)
+void XmlDocVisitor::visitPost(DocDotFile *)
{
if (m_hide) return;
visitPostEnd(m_t, "dotfile");
@@ -906,7 +954,7 @@ void XmlDocVisitor::visitPre(DocMscFile *df)
visitPreStart(m_t, "mscfile", FALSE, this, df->children(), df->file(), FALSE, DocImage::Html, df->width(), df->height());
}
-void XmlDocVisitor::visitPost(DocMscFile *)
+void XmlDocVisitor::visitPost(DocMscFile *)
{
if (m_hide) return;
visitPostEnd(m_t, "mscfile");
@@ -930,7 +978,7 @@ void XmlDocVisitor::visitPre(DocLink *lnk)
startLink(lnk->ref(),lnk->file(),lnk->anchor());
}
-void XmlDocVisitor::visitPost(DocLink *)
+void XmlDocVisitor::visitPost(DocLink *)
{
if (m_hide) return;
endLink();
@@ -939,14 +987,14 @@ void XmlDocVisitor::visitPost(DocLink *)
void XmlDocVisitor::visitPre(DocRef *ref)
{
if (m_hide) return;
- if (!ref->file().isEmpty())
+ if (!ref->file().isEmpty())
{
startLink(ref->ref(),ref->file(),ref->isSubPage() ? QCString() : ref->anchor());
}
if (!ref->hasLinkText()) filter(ref->targetTitle());
}
-void XmlDocVisitor::visitPost(DocRef *ref)
+void XmlDocVisitor::visitPost(DocRef *ref)
{
if (m_hide) return;
if (!ref->file().isEmpty()) endLink();
@@ -959,7 +1007,7 @@ void XmlDocVisitor::visitPre(DocSecRefItem *ref)
m_t << "<tocitem id=\"" << ref->file() << "_1" << ref->anchor() << "\">";
}
-void XmlDocVisitor::visitPost(DocSecRefItem *)
+void XmlDocVisitor::visitPost(DocSecRefItem *)
{
if (m_hide) return;
m_t << "</tocitem>" << endl;
@@ -971,7 +1019,7 @@ void XmlDocVisitor::visitPre(DocSecRefList *)
m_t << "<toclist>" << endl;
}
-void XmlDocVisitor::visitPost(DocSecRefList *)
+void XmlDocVisitor::visitPost(DocSecRefList *)
{
if (m_hide) return;
m_t << "</toclist>" << endl;
@@ -983,7 +1031,7 @@ void XmlDocVisitor::visitPost(DocSecRefList *)
// m_t << "<language langid=\"" << l->id() << "\">";
//}
//
-//void XmlDocVisitor::visitPost(DocLanguage *)
+//void XmlDocVisitor::visitPost(DocLanguage *)
//{
// if (m_hide) return;
// m_t << "</language>" << endl;
@@ -995,13 +1043,13 @@ void XmlDocVisitor::visitPre(DocParamSect *s)
m_t << "<parameterlist kind=\"";
switch(s->type())
{
- case DocParamSect::Param:
+ case DocParamSect::Param:
m_t << "param"; break;
- case DocParamSect::RetVal:
+ case DocParamSect::RetVal:
m_t << "retval"; break;
- case DocParamSect::Exception:
+ case DocParamSect::Exception:
m_t << "exception"; break;
- case DocParamSect::TemplateParam:
+ case DocParamSect::TemplateParam:
m_t << "templateparam"; break;
default:
ASSERT(0);
@@ -1028,18 +1076,18 @@ void XmlDocVisitor::visitPre(DocParamList *pl)
{
if (pl->paramTypes().count()>0)
{
- QListIterator<DocNode> li(pl->paramTypes());
+ QListIterator<DocNode> li2(pl->paramTypes());
DocNode *type;
m_t << "<parametertype>";
- for (li.toFirst();(type=li.current());++li)
+ for (li2.toFirst();(type=li2.current());++li2)
{
if (type->kind()==DocNode::Kind_Word)
{
- visit((DocWord*)type);
+ visit((DocWord*)type);
}
else if (type->kind()==DocNode::Kind_LinkedWord)
{
- visit((DocLinkedWord*)type);
+ visit((DocLinkedWord*)type);
}
else if (type->kind()==DocNode::Kind_Sep)
{
@@ -1070,11 +1118,11 @@ void XmlDocVisitor::visitPre(DocParamList *pl)
m_t << ">";
if (param->kind()==DocNode::Kind_Word)
{
- visit((DocWord*)param);
+ visit((DocWord*)param);
}
else if (param->kind()==DocNode::Kind_LinkedWord)
{
- visit((DocLinkedWord*)param);
+ visit((DocLinkedWord*)param);
}
m_t << "</parametername>" << endl;
}
@@ -1116,7 +1164,7 @@ void XmlDocVisitor::visitPre(DocInternalRef *ref)
startLink(0,ref->file(),ref->anchor());
}
-void XmlDocVisitor::visitPost(DocInternalRef *)
+void XmlDocVisitor::visitPost(DocInternalRef *)
{
if (m_hide) return;
endLink();
@@ -1165,7 +1213,7 @@ void XmlDocVisitor::visitPost(DocParBlock *)
void XmlDocVisitor::filter(const char *str)
-{
+{
m_t << convertToXML(str);
}