summaryrefslogtreecommitdiffstats
path: root/addon/doxmlparser/test
diff options
context:
space:
mode:
authordimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2002-10-20 18:23:06 (GMT)
committerdimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2002-10-20 18:23:06 (GMT)
commit7c34dd2b1594925d0a012e9ba290bf9c80574db5 (patch)
tree63a7ba72ad4f8318f818aebfef29beee5811c241 /addon/doxmlparser/test
parent2c6d31c8bf31028ba2f822c31f4812c2cecab306 (diff)
downloadDoxygen-7c34dd2b1594925d0a012e9ba290bf9c80574db5.zip
Doxygen-7c34dd2b1594925d0a012e9ba290bf9c80574db5.tar.gz
Doxygen-7c34dd2b1594925d0a012e9ba290bf9c80574db5.tar.bz2
Release-1.2.18-20021020
Diffstat (limited to 'addon/doxmlparser/test')
-rw-r--r--addon/doxmlparser/test/main.cpp28
1 files changed, 27 insertions, 1 deletions
diff --git a/addon/doxmlparser/test/main.cpp b/addon/doxmlparser/test/main.cpp
index 47854b2..7ac7720 100644
--- a/addon/doxmlparser/test/main.cpp
+++ b/addon/doxmlparser/test/main.cpp
@@ -47,6 +47,7 @@ QString linkedTextToString(ILinkedTextIterator *ti)
*/
void DumpDoc(IDoc *doc,int level)
{
+ if (doc==0) return;
QString indent;
indent.fill(' ',level);
//printf(" doc node kind=`%d'\n",doc->kind());
@@ -374,6 +375,29 @@ void DumpDoc(IDoc *doc,int level)
InPrint(("<section/>\n"));
}
break;
+ case IDoc::Preformatted:
+ {
+ InPrint(("<preformatted>\n"));
+ IDocPreformatted *pf = dynamic_cast<IDocPreformatted*>(doc);
+ ASSERT(pf!=0);
+ IDocIterator *di = pf->contents();
+ IDoc *pdoc;
+ for (di->toFirst();(pdoc=di->current());di->toNext())
+ {
+ DumpDoc(pdoc,level+1);
+ }
+ di->release();
+ InPrint(("<preformatted/>\n"));
+ }
+ break;
+ case IDoc::Symbol:
+ {
+ IDocSymbol *sym = dynamic_cast<IDocSymbol*>(doc);
+ ASSERT(sym!=0);
+ InPrint(("<symbol type=%s letter=%c/>\n",
+ sym->typeString()->latin1(),sym->letter()));
+ }
+ break;
case IDoc::Root:
{
InPrint(("<root>\n"));
@@ -391,6 +415,7 @@ void DumpDoc(IDoc *doc,int level)
break;
default:
+ printf("Found unsupported node type %d!\n",doc->kind());
break;
}
}
@@ -463,7 +488,7 @@ int main(int argc,char **argv)
IDoxygen *dox = createObjectModel();
- dox->setDebugLevel(0);
+ dox->setDebugLevel(4);
if (!dox->readXMLDir(argv[1]))
{
@@ -478,6 +503,7 @@ int main(int argc,char **argv)
{
printf("Compound name=%s id=%s kind=%s\n",
comp->name()->latin1(),comp->id()->latin1(),comp->kindString()->latin1());
+
ISectionIterator *sli = comp->sections();
ISection *sec;
for (sli->toFirst();(sec=sli->current());sli->toNext())