summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--INSTALL4
-rw-r--r--README4
-rw-r--r--VERSION2
-rw-r--r--addon/xmlparse/dochandler.cpp1
-rw-r--r--doc/config.doc27
-rw-r--r--packages/rpm/doxygen.spec2
-rw-r--r--src/classdef.cpp23
-rw-r--r--src/classdef.h1
-rw-r--r--src/code.l5
-rw-r--r--src/config.l30
-rw-r--r--src/doc.l2
-rw-r--r--src/dot.cpp22
-rw-r--r--src/doxygen.cpp301
-rw-r--r--src/doxygen.h12
-rw-r--r--src/filedef.cpp21
-rw-r--r--src/filedef.h2
-rw-r--r--src/groupdef.cpp37
-rw-r--r--src/groupdef.h19
-rw-r--r--src/index.cpp40
-rw-r--r--src/latexgen.cpp19
-rw-r--r--src/memberdef.cpp17
-rw-r--r--src/memberdef.h1
-rw-r--r--src/membergroup.cpp5
-rw-r--r--src/membergroup.h1
-rw-r--r--src/memberlist.cpp21
-rw-r--r--src/memberlist.h1
-rw-r--r--src/membername.h47
-rw-r--r--src/namespacedef.cpp19
-rw-r--r--src/namespacedef.h1
-rw-r--r--src/page.h10
-rw-r--r--src/pre.l8
-rw-r--r--src/rtfgen.cpp86
-rw-r--r--src/translator_en.h14
-rw-r--r--src/util.cpp181
-rw-r--r--src/util.h9
35 files changed, 587 insertions, 408 deletions
diff --git a/INSTALL b/INSTALL
index 29449f1..e1eba20 100644
--- a/INSTALL
+++ b/INSTALL
@@ -1,6 +1,6 @@
-DOXYGEN Version 1.2.11.1
+DOXYGEN Version 1.2.11-20011014
Please read the installation section of the manual for instructions.
--------
-Dimitri van Heesch (07 October 2001)
+Dimitri van Heesch (14 October 2001)
diff --git a/README b/README
index e14ca17..90f939f 100644
--- a/README
+++ b/README
@@ -1,4 +1,4 @@
-DOXYGEN Version 1.2.11.1
+DOXYGEN Version 1.2.11_20011014
Please read INSTALL for compilation instructions.
@@ -17,4 +17,4 @@ to subscribe to the lists or to visit the archives.
Enjoy,
-Dimitri van Heesch (dimitri@stack.nl) (07 October 2001)
+Dimitri van Heesch (dimitri@stack.nl) (14 October 2001)
diff --git a/VERSION b/VERSION
index 85e0796..431edf0 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-1.2.11.1
+1.2.11-20011014
diff --git a/addon/xmlparse/dochandler.cpp b/addon/xmlparse/dochandler.cpp
index 86e4065..53a300a 100644
--- a/addon/xmlparse/dochandler.cpp
+++ b/addon/xmlparse/dochandler.cpp
@@ -783,6 +783,7 @@ void CodeLineHandler::endLineNumber()
printf("end linenumber\n");
m_parent->setDelegate(0);
}
+
//----------------------------------------------------------------------
// ProgramListingHandler
//----------------------------------------------------------------------
diff --git a/doc/config.doc b/doc/config.doc
index b9f0e56..a84184e 100644
--- a/doc/config.doc
+++ b/doc/config.doc
@@ -119,6 +119,7 @@ followed by the descriptions of the tags grouped by category.
<li> \refitem cfg_hide_scope_names HIDE_SCOPE_NAMES
<li> \refitem cfg_hide_undoc_classes HIDE_UNDOC_CLASSES
<li> \refitem cfg_hide_undoc_members HIDE_UNDOC_MEMBERS
+<li> \refitem cfg_hide_undoc_relations HIDE_UNDOC_RELATIONS
<li> \refitem cfg_html_align_members HTML_ALIGN_MEMBERS
<li> \refitem cfg_html_footer HTML_FOOTER
<li> \refitem cfg_html_header HTML_HEADER
@@ -318,13 +319,6 @@ followed by the descriptions of the tags grouped by category.
to \c NO (the default) then the documentation will be excluded.
Set it to \c YES to include the internal documentation.
-\anchor cfg_class_diagrams
-<dt>\c CLASS_DIAGRAMS <dd>
- \addindex CLASS_DIAGRAMS
- If the \c CLASS_DIAGRAMS tag is set to \c YES (the default) doxygen will
- generate a class diagram (in HTML and \f$\mbox{\LaTeX}\f$) for classes with base or
- super classes. Setting the tag to \c NO turns the diagrams off.
-
\anchor cfg_source_browser
<dt>\c SOURCE_BROWSER <dd>
\addindex SOURCE_BROWSER
@@ -1133,9 +1127,19 @@ TAGFILES = file1=loc1 "file2 = loc2" ... </pre>
</dl>
\subsection config_dot Dot options
-\anchor cfg_have_dot
+\anchor cfg_class_diagrams
<dl>
+<dt>\c CLASS_DIAGRAMS <dd>
+ \addindex CLASS_DIAGRAMS
+ If the \c CLASS_DIAGRAMS tag is set to \c YES (the default) doxygen will
+ generate a class diagram (in HTML and \f$\mbox{\LaTeX}\f$) for classes with base or
+ super classes. Setting the tag to \c NO turns the diagrams off.
+ Note that this option is superceded by the HAVE_DOT option below.
+ This is only a fallback. It is recommended to install and use dot,
+ since it yield more powerful graphs.
+
+\anchor cfg_have_dot
<dt>\c HAVE_DOT <dd>
\addindex HAVE_DOT
If you set the \c HAVE_DOT tag to \c YES then doxygen will assume the dot tool is
@@ -1166,6 +1170,13 @@ TAGFILES = file1=loc1 "file2 = loc2" ... </pre>
If the \c TEMPLATE_RELATIONS and \c HAVE_DOT tags are set to \c YES then
doxygen will show the relations between templates and their instances.
+\anchor cfg_hide_undoc_relations
+<dt>\c HIDE_UNDOC_RELATIONS <dd>
+ \addindex HIDE_UNDOC_RELATIONS
+ If set to YES, the inheritance and collaboration graphs will hide
+ inheritance and usage relations if the target is undocumented
+ or is not a class.
+
\anchor cfg_include_graph
<dt>\c INCLUDE_GRAPH <dd>
\addindex INCLUDE_GRAPH
diff --git a/packages/rpm/doxygen.spec b/packages/rpm/doxygen.spec
index 57cbd40..18b7384 100644
--- a/packages/rpm/doxygen.spec
+++ b/packages/rpm/doxygen.spec
@@ -1,5 +1,5 @@
Name: doxygen
-Version: 1.2.11.1
+Version: 1.2.11_20011014
Summary: documentation system for C, C++ and IDL
Release: 4
Source: doxygen-%{version}.src.tar.gz
diff --git a/src/classdef.cpp b/src/classdef.cpp
index 69d15ca..8111928 100644
--- a/src/classdef.cpp
+++ b/src/classdef.cpp
@@ -2354,3 +2354,26 @@ QCString ClassDef::className() const
}
return className;
};
+
+void ClassDef::addListReferences()
+{
+ addRefItem(todoId(),testId(),bugId(),
+ theTranslator->trClass(TRUE,TRUE),
+ getOutputFileBase(),name()
+ );
+ MemberGroupListIterator mgli(*m_memberGroupList);
+ MemberGroup *mg;
+ for (;(mg=mgli.current());++mgli)
+ {
+ mg->addListReferences(this);
+ }
+ constructors.addListReferences(this);
+ typedefMembers.addListReferences(this);
+ enumMembers.addListReferences(this);
+ enumValMembers.addListReferences(this);
+ functionMembers.addListReferences(this);
+ relatedMembers.addListReferences(this);
+ variableMembers.addListReferences(this);
+ propertyMembers.addListReferences(this);
+}
+
diff --git a/src/classdef.h b/src/classdef.h
index 5756c9f..e42ef6b 100644
--- a/src/classdef.h
+++ b/src/classdef.h
@@ -272,6 +272,7 @@ class ClassDef : public Definition
void addMembersToTemplateInstance(ClassDef *cd,const char *templSpec);
void setClassIsArtificial() { m_artificial = TRUE; }
void setIsStatic(bool b) { m_isStatic=b; }
+ void addListReferences();
/*! Creates a new compound definition.
* \param outerScope class, file or namespace in which this class is
diff --git a/src/code.l b/src/code.l
index d5af17f..1a662af 100644
--- a/src/code.l
+++ b/src/code.l
@@ -1091,11 +1091,6 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
int s=0;while (!isId(yytext[s])) s++;
int e=yyleng-1;while (!isId(yytext[e])) e--;
QCString varname = ((QCString)yytext).mid(s,e-s+1);
- //QCString text=yytext;
- //QCString tmp=varname.copy();
- //g_code->codify(text.left(s+1));
- //generateClassLink(*g_code,tmp.data());
- //g_code->codify(text.right(yyleng-e-1));
addType();
g_name=varname;
}
diff --git a/src/config.l b/src/config.l
index 006bd7e..456330b 100644
--- a/src/config.l
+++ b/src/config.l
@@ -1307,13 +1307,6 @@ void Config::create()
FALSE
);
cb = addBool(
- "CLASS_DIAGRAMS",
- "If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will \n"
- "generate a class diagram (in Html and LaTeX) for classes with base or \n"
- "super classes. Setting the tag to NO turns the diagrams off. \n",
- TRUE
- );
- cb = addBool(
"SOURCE_BROWSER",
"If the SOURCE_BROWSER tag is set to YES then a list of source files will \n"
"be generated. Documented entities will be cross-referenced with these sources. \n",
@@ -1717,8 +1710,10 @@ void Config::create()
"If the GENERATE_TREEVIEW tag is set to YES, a side panel will be\n"
"generated containing a tree-like index structure (just like the one that \n"
"is generated for HTML Help). For this to work a browser that supports \n"
- "JavaScript and frames is required (for instance Netscape 4.0+ \n"
- "or Internet explorer 4.0+). ",
+ "JavaScript and frames is required (for instance Mozilla, Netscape 4.0+, \n"
+ "or Internet explorer 4.0+). Note that for large projects the tree generation \n"
+ "can take a very long time. In such cases it is better to disable this feature. \n"
+ "Windows users are probably better off using the HTML help feature. \n",
FALSE
);
cb->addDependency("GENERATE_HTML");
@@ -2021,6 +2016,15 @@ void Config::create()
addInfo( "Dot","Configuration options related to the dot tool ");
//-----------------------------------------------------------------------------------------------
cb = addBool(
+ "CLASS_DIAGRAMS",
+ "If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will \n"
+ "generate a inheritance diagram (in Html, RTF and LaTeX) for classes with base or \n"
+ "super classes. Setting the tag to NO turns the diagrams off. Note that this \n"
+ "option is superceded by the HAVE_DOT option below. This is only a fallback. It is \n"
+ "recommended to install and use dot, since it yield more powerful graphs. \n",
+ TRUE
+ );
+ cb = addBool(
"HAVE_DOT",
"If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is \n"
"available from the path. This tool is part of Graphviz, a graph visualization \n"
@@ -2054,6 +2058,14 @@ void Config::create()
);
cb->addDependency("HAVE_DOT");
cb = addBool(
+ "HIDE_UNDOC_RELATIONS",
+ "If set to YES, the inheritance and collaboration graphs will hide \n"
+ "inheritance and usage relations if the target is undocumented \n"
+ "or is not a class. \n",
+ TRUE
+ );
+ cb->addDependency("HAVE_DOT");
+ cb = addBool(
"INCLUDE_GRAPH",
"If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT \n"
"tags are set to YES then doxygen will generate a graph for each documented \n"
diff --git a/src/doc.l b/src/doc.l
index 41b6ade..3b06654 100644
--- a/src/doc.l
+++ b/src/doc.l
@@ -2223,7 +2223,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
<DocScan>{CMD}("\\"|"@"|"<"|">"|"&"|"$"|"#"|"%") {
outDoc->docify(&yytext[1]);
}
-<DocScan,DocEmphasis,DocBold,DocCode>"%"[a-zA-Z_0-9\-]+ {
+<DocScan,DocEmphasis,DocBold,DocCode>"%"[a-z_A-Z][a-z_A-Z0-9:\-]* {
outDoc->docify(yytext+1);
}
<DocEmphasis>{FILEMASK} {
diff --git a/src/dot.cpp b/src/dot.cpp
index 1b1bc96..48bf311 100644
--- a/src/dot.cpp
+++ b/src/dot.cpp
@@ -1530,6 +1530,7 @@ void generateGraphLegend(const char *path)
return;
}
QTextStream dotText(&dotFile);
+#if 0
dotText << "digraph inheritance\n";
dotText << "{\n";
dotText << " Node7 [shape=\"box\",label=\"Inherited\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"black\",style=\"filled\" fontcolor=\"white\"];\n";
@@ -1546,6 +1547,27 @@ void generateGraphLegend(const char *path)
dotText << " Node14 -> Node7 [dir=back,color=\"darkorchid3\",fontsize=10,style=\"dashed\",label=\"m_usedClass\",fontname=\"doxfont\"];\n";
dotText << " Node14 [shape=\"box\",label=\"Used\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"black\",URL=\"$class_used.html\"];\n";
dotText << "}\n";
+#endif
+ dotText << "digraph inheritance\n";
+ dotText << "{\n";
+ dotText << " Node9 [shape=\"box\",label=\"Inherited\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"black\",style=\"filled\" fontcolor=\"white\"];\n";
+ dotText << " Node10 -> Node9 [dir=back,color=\"midnightblue\",fontsize=10,style=\"solid\",fontname=\"doxfont\"];\n";
+ dotText << " Node10 [shape=\"box\",label=\"PublicBase\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"black\",URL=\"$classPublicBase.html\"];\n";
+ dotText << " Node11 -> Node10 [dir=back,color=\"midnightblue\",fontsize=10,style=\"solid\",fontname=\"doxfont\"];\n";
+ dotText << " Node11 [shape=\"box\",label=\"Truncated\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"red\",URL=\"$classTruncated.html\"];\n";
+ dotText << " Node13 -> Node9 [dir=back,color=\"darkgreen\",fontsize=10,style=\"solid\",fontname=\"doxfont\"];\n";
+ dotText << " Node13 [shape=\"box\",label=\"ProtectedBase\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"black\",URL=\"$classProtectedBase.html\"];\n";
+ dotText << " Node14 -> Node9 [dir=back,color=\"firebrick4\",fontsize=10,style=\"solid\",fontname=\"doxfont\"];\n";
+ dotText << " Node14 [shape=\"box\",label=\"PrivateBase\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"black\",URL=\"$classPrivateBase.html\"];\n";
+ dotText << " Node15 -> Node9 [dir=back,color=\"midnightblue\",fontsize=10,style=\"solid\",fontname=\"doxfont\"];\n";
+ dotText << " Node15 [shape=\"box\",label=\"Undocumented\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"grey75\"];\n";
+ dotText << " Node16 -> Node9 [dir=back,color=\"midnightblue\",fontsize=10,style=\"solid\",fontname=\"doxfont\"];\n";
+ dotText << " Node16 [shape=\"box\",label=\"Templ< int >\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"black\",URL=\"$classTempl.html\"];\n";
+ dotText << " Node17 -> Node16 [dir=back,color=\"orange\",fontsize=10,style=\"dashed\",label=\"< int >\",fontname=\"doxfont\"];\n";
+ dotText << " Node17 [shape=\"box\",label=\"Templ< T >\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"black\",URL=\"$classTempl.html\"];\n";
+ dotText << " Node18 -> Node9 [dir=back,color=\"darkorchid3\",fontsize=10,style=\"dashed\",label=\"m_usedClass\",fontname=\"doxfont\"];\n";
+ dotText << " Node18 [shape=\"box\",label=\"Used\",fontsize=10,height=0.2,width=0.4,fontname=\"doxfont\",color=\"black\",URL=\"$classUsed.html\"];\n";
+ dotText << "}\n";
dotFile.close();
QDir d(path);
diff --git a/src/doxygen.cpp b/src/doxygen.cpp
index cebde46..1605da3 100644
--- a/src/doxygen.cpp
+++ b/src/doxygen.cpp
@@ -85,8 +85,8 @@ MemberNameSDict Doxygen::functionNameSDict(10000);
FileNameList Doxygen::inputNameList; // all input files
FileNameDict *Doxygen::inputNameDict;
-GroupList Doxygen::groupList; // all groups
-GroupDict Doxygen::groupDict(257);
+//GroupList Doxygen::groupList; // all groups
+GroupSDict Doxygen::groupSDict(17);
FormulaList Doxygen::formulaList; // all formulas
FormulaDict Doxygen::formulaDict(1009); // all formulas
@@ -132,7 +132,7 @@ void clearAll()
//Doxygen::memberNameList.clear();
//Doxygen::functionNameList.clear();
Doxygen::inputNameList.clear();
- Doxygen::groupList.clear();
+ //Doxygen::groupList.clear();
Doxygen::formulaList.clear();
Doxygen::classSDict.clear();
//Doxygen::memberNameDict.clear();
@@ -143,7 +143,7 @@ void clearAll()
Doxygen::exampleNameDict->clear();
Doxygen::imageNameDict->clear();
Doxygen::dotFileNameDict->clear();
- Doxygen::groupDict.clear();
+ //Doxygen::groupDict.clear();
Doxygen::formulaDict.clear();
Doxygen::formulaNameDict.clear();
Doxygen::tagDestinationDict.clear();
@@ -175,8 +175,8 @@ void statistics()
//Doxygen::typedefDict.statistics();
fprintf(stderr,"--- namespaceAliasDict stats ----\n");
Doxygen::namespaceAliasDict.statistics();
- fprintf(stderr,"--- groupDict stats ----\n");
- Doxygen::groupDict.statistics();
+ //fprintf(stderr,"--- groupDict stats ----\n");
+ //Doxygen::groupDict.statistics();
fprintf(stderr,"--- formulaDict stats ----\n");
Doxygen::formulaDict.statistics();
fprintf(stderr,"--- formulaNameDict stats ----\n");
@@ -203,79 +203,6 @@ QCString spaces;
//----------------------------------------------------------------------------
-static void addRelatedPage(const char *name,const QCString &ptitle,
- const QCString &doc,QList<QCString> *anchors,
- const char *fileName,int startLine,
- int todoId,int testId,int bugId,GroupDef *gd=0,
- TagInfo *tagInfo=0
- )
-{
- PageInfo *pi=0;
- if ((pi=Doxygen::pageSDict->find(name)) && !tagInfo)
- {
- // append documentation block to the page.
- pi->doc+="\n\n"+doc;
- }
- else // new page
- {
- QCString baseName=name;
- if (baseName.right(4)==".tex")
- baseName=baseName.left(baseName.length()-4);
- else if (baseName.right(5)==".html")
- baseName=baseName.left(baseName.length()-5);
-
- QCString title=ptitle.stripWhiteSpace();
- pi=new PageInfo(fileName,startLine,baseName,doc,title);
- pi->todoId=todoId;
- pi->testId=testId;
- pi->bugId=bugId;
- if (tagInfo)
- {
- pi->reference = tagInfo->tagName;
- }
-
- QCString pageName;
- if (Config_getBool("CASE_SENSE_NAMES"))
- pageName=pi->name.copy();
- else
- pageName=pi->name.lower();
- //setFileNameForSections(anchors,pageName,pi);
- pi->fileName = pageName;
- pi->addSections(anchors);
-
- Doxygen::pageSDict->append(baseName,pi);
-
- if (gd) gd->addPage(pi);
-
- if (!pi->title.isEmpty())
- {
- //outputList->writeTitle(pi->name,pi->title);
-
- // a page name is a label as well!
- SectionInfo *si=new SectionInfo(
- pi->name,pi->title,SectionInfo::Section,pi->reference);
- if (gd)
- {
- si->fileName=gd->getOutputFileBase();
- }
- else if (pi->inGroup)
- {
- si->fileName=pi->inGroup->getOutputFileBase().copy();
- }
- else
- {
- si->fileName=pageName;
- }
- //printf("si->label=`%s' si->definition=%s si->fileName=`%s'\n",
- // si->label.data(),si->definition?si->definition->name().data():"<none>",
- // si->fileName.data());
- //printf(" SectionInfo: sec=%p sec->fileName=%s\n",si,si->fileName.data());
- //printf("Adding section info %s\n",pi->name.data());
- Doxygen::sectionDict.insert(pageName,si);
- }
- }
-}
-
static void addRelatedPage(Entry *root)
{
GroupDef *gd=0;
@@ -283,7 +210,7 @@ static void addRelatedPage(Entry *root)
Grouping *g;
for (;(g=gli.current());++gli)
{
- if (!g->groupname.isEmpty() && (gd=Doxygen::groupDict[g->groupname])) break;
+ if (!g->groupname.isEmpty() && (gd=Doxygen::groupSDict[g->groupname])) break;
}
addRelatedPage(root->name,root->args,root->doc,root->anchors,
root->fileName,root->startLine,root->todoId,
@@ -291,107 +218,6 @@ static void addRelatedPage(Entry *root)
);
}
-//----------------------------------------------------------------------------
-
-static void addRefItem(int todoId,int testId,int bugId,const char *prefix,
- const char *name,const char *title,const char *args=0)
-{
-
- //printf("addRefItem(%s) todoId=%d testId=%d bugId=%d\n",name,todoId,testId,bugId);
-
- ////////////////////////////////////////////////////////////
- // add item to the todo list
- ////////////////////////////////////////////////////////////
-
- if (todoId>0 && Config_getBool("GENERATE_TODOLIST"))
- {
- RefItem *item = todoList.getRefItem(todoId);
- ASSERT(item!=0);
- if (item->written) return;
-
- QCString doc;
- doc += "<dl><dt>\\anchor ";
- doc += item->listAnchor;
- doc += "\n";
- doc += prefix;
- doc += " \\_internalref ";
- doc += name;
- doc += " \"";
- doc += title;
- doc += "\"";
- if (args) doc += args;
- doc += "</dt>\n<dd>";
- doc += item->text;
- doc += "</dd></dl>\n";
- //printf("Todo page: %s\n",doc.data());
- addRelatedPage("todo",theTranslator->trTodoList(),doc,0,"generated",1,0,0,0);
-
- item->written=TRUE;
- }
-
- ////////////////////////////////////////////////////////////
- // add item to the test list
- ////////////////////////////////////////////////////////////
-
- if (testId>0 && Config_getBool("GENERATE_TESTLIST"))
- {
- RefItem *item = testList.getRefItem(testId);
- ASSERT(item!=0);
- if (item->written) return;
-
- QCString doc;
- doc += "<dl><dt>\\anchor ";
- doc += item->listAnchor;
- doc += "\n";
- doc += prefix;
- doc += " \\_internalref ";
- doc += name;
- doc += " \"";
- doc += title;
- doc += "\"";
- if (args) doc += args;
- doc += "</dt>\n<dd>";
- doc += item->text;
- doc += "</dd></dl>\n";
- //printf("Test page: %s\n",doc.data());
- addRelatedPage("test",theTranslator->trTestList(),doc,0,"generated",1,0,0,0);
-
- item->written=TRUE;
- }
-
- ////////////////////////////////////////////////////////////
- // add item to the bug list
- ////////////////////////////////////////////////////////////
-
- if (bugId>0 && Config_getBool("GENERATE_BUGLIST"))
- {
- RefItem *item = bugList.getRefItem(bugId);
- ASSERT(item!=0);
- if (item->written) return;
-
- QCString doc;
- doc += "<dl><dt>\\anchor ";
- doc += item->listAnchor;
- doc += "\n";
- doc += prefix;
- doc += " \\_internalref ";
- doc += name;
- doc += " \"";
- doc += title;
- doc += "\"";
- if (args) doc += args;
- doc += "</dt>\n<dd>";
- doc += item->text;
- doc += "</dd></dl>\n";
- //printf("Bug page: %s\n",doc.data());
- addRelatedPage("bug",theTranslator->trBugList(),doc,0,"generated",1,0,0,0);
-
- item->written=TRUE;
- }
-}
-
-//----------------------------------------------------------------------------
-
static void buildGroupList(Entry *root)
{
@@ -401,7 +227,7 @@ static void buildGroupList(Entry *root)
GroupDef *gd;
- if ((gd=Doxygen::groupDict[root->name]))
+ if ((gd=Doxygen::groupSDict[root->name]))
{
if ( root->groupdoctype==Entry::GROUPDOC_NORMAL )
{
@@ -438,8 +264,9 @@ static void buildGroupList(Entry *root)
gd->setBriefDescription(root->brief);
gd->setDocumentation(root->doc);
gd->addSectionsToDefinition(root->anchors);
- Doxygen::groupList.append(gd);
- Doxygen::groupDict.insert(root->name,gd);
+ //Doxygen::groupList.append(gd);
+ //Doxygen::groupDict.insert(root->name,gd);
+ Doxygen::groupSDict.append(root->name,gd);
gd->setRefItems(root->todoId,root->testId,root->bugId);
}
}
@@ -457,7 +284,7 @@ static void organizeSubGroups(Entry *root)
{
GroupDef *gd;
- if ((gd=Doxygen::groupDict[root->name]))
+ if ((gd=Doxygen::groupSDict[root->name]))
{
addGroupToGroups(root,gd);
}
@@ -507,7 +334,7 @@ static void buildFileList(Entry *root)
for (;(g=gli.current());++gli)
{
GroupDef *gd=0;
- if (!g->groupname.isEmpty() && (gd=Doxygen::groupDict[g->groupname]))
+ if (!g->groupname.isEmpty() && (gd=Doxygen::groupSDict[g->groupname]))
{
gd->addFile(fd);
//printf("File %s: in group %s\n",fd->name().data(),s->data());
@@ -1158,7 +985,7 @@ static void findUsingDirectives(Entry *root)
for (;(g=gli.current());++gli)
{
GroupDef *gd=0;
- if (!g->groupname.isEmpty() && (gd=Doxygen::groupDict[g->groupname]))
+ if (!g->groupname.isEmpty() && (gd=Doxygen::groupSDict[g->groupname]))
gd->addNamespace(nd);
}
@@ -1500,7 +1327,7 @@ static MemberDef *addVariableToFile(
// merge ingroup specifiers
if (md->getGroupDef()==0 && root->groups->first())
{
- GroupDef *gd=Doxygen::groupDict[root->groups->first()->groupname.data()];
+ GroupDef *gd=Doxygen::groupSDict[root->groups->first()->groupname.data()];
md->setGroupDef(gd, root->groups->first()->pri, root->fileName, root->startLine, root->doc.length() != 0);
}
else if (md->getGroupDef()!=0 && root->groups->count()==0)
@@ -2078,7 +1905,7 @@ static void buildFunctionList(Entry *root)
// merge ingroup specifiers
if (md->getGroupDef()==0 && root->groups->first())
{
- GroupDef *gd=Doxygen::groupDict[root->groups->first()->groupname.data()];
+ GroupDef *gd=Doxygen::groupSDict[root->groups->first()->groupname.data()];
md->setGroupDef(gd, root->groups->first()->pri, root->fileName, root->startLine, root->doc.length() != 0);
}
else if (md->getGroupDef()!=0 && root->groups->count()==0)
@@ -2544,17 +2371,13 @@ static void findUsedClassesForClass(Entry *root,
usedCd = new ClassDef(
masterCd->getDefFileName(),masterCd->getDefLine(),
usedName,ClassDef::Class);
- //usedCd->setIsTemplateBaseClass(count);
Doxygen::hiddenClasses.append(usedName,usedCd);
}
- if (isArtificial) usedCd->setClassIsArtificial();
- instanceCd->addUsedClass(usedCd,md->name());
-
- //if (m_usesImplClassDict==0) m_usesImplClassDict = new UsesClassDict(257);
- //UsesClassDef *ucd = new UsesClassDef(cd);
- //m_usesImplClassDict->insert(cd->name(),ucd);
- //ucd->templSpecifiers = templSpec;
- //ucd->addAccessor(md->name());
+ if (usedCd)
+ {
+ if (isArtificial) usedCd->setClassIsArtificial();
+ instanceCd->addUsedClass(usedCd,md->name());
+ }
}
}
}
@@ -2596,7 +2419,7 @@ static void findUsedClassesForClass(Entry *root,
if (!found && !type.isEmpty()) // used class is not documented in any scope
{
ClassDef *usedCd = Doxygen::hiddenClasses.find(type);
- if (usedCd==0)
+ if (usedCd==0 && !Config_getBool("HIDE_UNDOC_RELATIONS"))
{
Debug::print(Debug::Classes,0," New undocumented used class `%s'\n", type.data());
usedCd = new ClassDef(
@@ -2604,8 +2427,11 @@ static void findUsedClassesForClass(Entry *root,
type,ClassDef::Class);
Doxygen::hiddenClasses.append(type,usedCd);
}
- if (isArtificial) usedCd->setClassIsArtificial();
- instanceCd->addUsedClass(usedCd,md->name());
+ if (usedCd)
+ {
+ if (isArtificial) usedCd->setClassIsArtificial();
+ instanceCd->addUsedClass(usedCd,md->name());
+ }
}
}
}
@@ -2653,8 +2479,11 @@ static void findBaseClassesForClass(
// find a documented base class in the correct scope
if (!findClassRelation(root,instanceCd,&tbi,templateNames,DocumentedOnly,isArtificial))
{
- // no documented base class -> try to find an undocumented one
- findClassRelation(root,instanceCd,&tbi,templateNames,Undocumented,isArtificial);
+ if (!Config_getBool("HIDE_UNDOC_RELATIONS"))
+ {
+ // no documented base class -> try to find an undocumented one
+ findClassRelation(root,instanceCd,&tbi,templateNames,Undocumented,isArtificial);
+ }
}
}
else if (mode==TemplateInstances)
@@ -3233,16 +3062,17 @@ static void computeMemberReferences()
{
nd->computeAnchors();
}
- GroupDef *gd=Doxygen::groupList.first();
- while (gd)
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
+ GroupDef *gd;
+ for (gli.toFirst();(gd=gli.current());++gli)
{
gd->computeAnchors();
- gd=Doxygen::groupList.next();
}
}
//----------------------------------------------------------------------
+#if 0
static void addClassMemberTodoTestBugReferences(Definition *compound)
{
MemberNameSDict::Iterator mnli(Doxygen::memberNameSDict);
@@ -3308,8 +3138,9 @@ static void addFileMemberTodoTestBugReferences(Definition *compound)
}
}
}
+#endif
-static void addTodoTestBugReferences()
+static void addListReferences()
{
MemberNameSDict::Iterator mnli(Doxygen::memberNameSDict);
MemberName *mn=0;
@@ -3337,11 +3168,7 @@ static void addTodoTestBugReferences()
ClassDef *cd=0;
for (cli.toFirst();(cd=cli.current());++cli)
{
- addRefItem(cd->todoId(),cd->testId(),cd->bugId(),
- theTranslator->trClass(TRUE,TRUE),
- cd->getOutputFileBase(),cd->name()
- );
- addClassMemberTodoTestBugReferences(cd);
+ cd->addListReferences();
}
FileName *fn=Doxygen::inputNameList.first();
while (fn)
@@ -3349,10 +3176,7 @@ static void addTodoTestBugReferences()
FileDef *fd=fn->first();
while (fd)
{
- addRefItem(fd->todoId(),fd->testId(),fd->bugId(),
- theTranslator->trFile(TRUE,TRUE),
- fd->getOutputFileBase(),fd->name());
- addFileMemberTodoTestBugReferences(fd);
+ fd->addListReferences();
fd=fn->next();
}
fn=Doxygen::inputNameList.next();
@@ -3361,21 +3185,15 @@ static void addTodoTestBugReferences()
NamespaceDef *nd=0;
for (nli.toFirst();(nd=nli.current());++nli)
{
- addRefItem(nd->todoId(),nd->testId(),nd->bugId(),
- theTranslator->trNamespace(TRUE,TRUE),
- nd->getOutputFileBase(),nd->name());
- addFileMemberTodoTestBugReferences(nd);
+ nd->addListReferences();
}
- GroupDef *gd=Doxygen::groupList.first();
- while (gd)
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
+ GroupDef *gd;
+ for (gli.toFirst();(gd=gli.current());++gli)
{
- addRefItem(gd->todoId(),gd->testId(),gd->bugId(),
- theTranslator->trGroup(TRUE,TRUE),
- gd->getOutputFileBase(),gd->groupTitle());
- addFileMemberTodoTestBugReferences(gd);
- gd=Doxygen::groupList.next();
+ gd->addListReferences();
}
- PageSDictIterator pdi(*Doxygen::pageSDict);
+ PageSDict::Iterator pdi(*Doxygen::pageSDict);
PageInfo *pi=0;
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
@@ -3383,8 +3201,6 @@ static void addTodoTestBugReferences()
theTranslator->trPage(TRUE,TRUE),
pi->name,pi->title);
}
- addClassMemberTodoTestBugReferences(0);
- addFileMemberTodoTestBugReferences(0);
}
//----------------------------------------------------------------------
@@ -5276,11 +5092,11 @@ static void addMembersToMemberGroup()
nd->addMembersToMemberGroup();
}
// for each group
- GroupDef *gd=Doxygen::groupList.first();
- while (gd)
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
+ GroupDef *gd;
+ for (gli.toFirst();(gd=gli.current());++gli)
{
gd->addMembersToMemberGroup();
- gd=Doxygen::groupList.next();
}
}
@@ -5315,11 +5131,11 @@ static void distributeMemberGroupDocumentation()
nd->distributeMemberGroupDocumentation();
}
// for each group
- GroupDef *gd=Doxygen::groupList.first();
- while (gd)
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
+ GroupDef *gd;
+ for (gli.toFirst();(gd=gli.current());++gli)
{
gd->distributeMemberGroupDocumentation();
- gd=Doxygen::groupList.next();
}
}
@@ -5640,7 +5456,7 @@ static void resolveUserReferences()
static void generatePageDocs()
{
if (documentedPages==0) return;
- PageSDictIterator pdi(*Doxygen::pageSDict);
+ PageSDict::Iterator pdi(*Doxygen::pageSDict);
PageInfo *pi=0;
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
@@ -5733,7 +5549,7 @@ static void buildExampleList(Entry *root)
static void generateExampleDocs()
{
outputList->disable(OutputGenerator::Man);
- PageSDictIterator pdi(*Doxygen::exampleSDict);
+ PageSDict::Iterator pdi(*Doxygen::exampleSDict);
PageInfo *pi=0;
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
@@ -5754,9 +5570,9 @@ static void generateExampleDocs()
static void generateGroupDocs()
{
- GroupListIterator gli(Doxygen::groupList);
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
GroupDef *gd;
- for (;(gd=gli.current());++gli)
+ for (gli.toFirst();(gd=gli.current());++gli)
{
if (!gd->isReference())
{
@@ -6758,6 +6574,9 @@ void readConfiguration(int argc, char **argv)
void parseInput()
{
+
+ Doxygen::classSDict.setAutoDelete(TRUE);
+
Doxygen::inputNameDict = new FileNameDict(1009);
Doxygen::includeNameDict = new FileNameDict(1009);
Doxygen::exampleNameDict = new FileNameDict(1009);
@@ -7195,7 +7014,7 @@ void parseInput()
addSourceReferences();
msg("Adding todo/test/bug list items...\n");
- addTodoTestBugReferences();
+ addListReferences();
}
diff --git a/src/doxygen.h b/src/doxygen.h
index 913337c..af3d208 100644
--- a/src/doxygen.h
+++ b/src/doxygen.h
@@ -67,13 +67,10 @@ class Doxygen
static FileNameDict *includeNameDict;
static FileNameDict *exampleNameDict;
static FileNameDict *inputNameDict;
+ static FileNameList inputNameList;
static FileNameDict *imageNameDict;
static FileNameDict *dotFileNameDict;
static QStrList tagfileList;
- //static MemberNameList memberNameList;
- //static MemberNameList functionNameList;
- //static MemberNameDict memberNameDict;
- //static MemberNameDict functionNameDict;
static MemberNameSDict memberNameSDict;
static MemberNameSDict functionNameSDict;
static FileList fileList;
@@ -81,12 +78,9 @@ class Doxygen
static ClassDef unrelatedClass;
static QTextStream tagFile;
static SectionDict sectionDict;
- static FileNameList inputNameList;
static StringDict namespaceAliasDict;
- static GroupList groupList;
- static GroupDict groupDict;
- //static NamespaceList namespaceList;
- //static NamespaceDict namespaceDict;
+ //static GroupList groupList;
+ static GroupSDict groupSDict;
static NamespaceSDict namespaceSDict;
static FormulaList formulaList;
static FormulaDict formulaDict;
diff --git a/src/filedef.cpp b/src/filedef.cpp
index 37d6b20..9384952 100644
--- a/src/filedef.cpp
+++ b/src/filedef.cpp
@@ -654,3 +654,24 @@ bool FileDef::generateSourceFile() const
extension!=".doc" && extension!=".txt" && extension!=".dox";
}
+
+void FileDef::addListReferences()
+{
+ addRefItem(todoId(),testId(),bugId(),
+ theTranslator->trFile(TRUE,TRUE),
+ getOutputFileBase(),name()
+ );
+ MemberGroupListIterator mgli(*memberGroupList);
+ MemberGroup *mg;
+ for (;(mg=mgli.current());++mgli)
+ {
+ mg->addListReferences(this);
+ }
+ docDefineMembers.addListReferences(this);
+ docProtoMembers.addListReferences(this);
+ docTypedefMembers.addListReferences(this);
+ docEnumMembers.addListReferences(this);
+ docFuncMembers.addListReferences(this);
+ docVarMembers.addListReferences(this);
+}
+
diff --git a/src/filedef.h b/src/filedef.h
index 79525b0..77c8aa8 100644
--- a/src/filedef.h
+++ b/src/filedef.h
@@ -146,6 +146,8 @@ class FileDef : public Definition
void addMembersToMemberGroup();
void distributeMemberGroupDocumentation();
+ void addListReferences();
+
//void generateXML(QTextStream &t);
//void generateXMLSection(QTextStream &t,MemberList *ml,const char *type);
diff --git a/src/groupdef.cpp b/src/groupdef.cpp
index 3f21215..ec43b56 100644
--- a/src/groupdef.cpp
+++ b/src/groupdef.cpp
@@ -62,7 +62,6 @@ GroupDef::GroupDef(const char *df,int dl,const char *na,const char *t) :
docProtoMembers.setInGroup(TRUE);
docTypedefMembers.setInGroup(TRUE);
docEnumMembers.setInGroup(TRUE);
- docEnumValMembers.setInGroup(TRUE);
docFuncMembers.setInGroup(TRUE);
docVarMembers.setInGroup(TRUE);
@@ -290,8 +289,6 @@ void GroupDef::removeMember(MemberDef *md)
docEnumMembers.remove(md);
break;
case MemberDef::EnumValue:
- decEnumValMembers.remove(md);
- docEnumValMembers.remove(md);
break;
case MemberDef::Prototype:
decProtoMembers.remove(md);
@@ -527,7 +524,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
}
}
PageInfo *pi=0;
- PageSDictIterator pdi(*pageDict);
+ PageSDict::Iterator pdi(*pageDict);
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
if (!pi->isReference())
@@ -590,7 +587,7 @@ void addClassToGroups(Entry *root,ClassDef *cd)
for (;(g=gli.current());++gli)
{
GroupDef *gd=0;
- if (!g->groupname.isEmpty() && (gd=Doxygen::groupDict[g->groupname]))
+ if (!g->groupname.isEmpty() && (gd=Doxygen::groupSDict[g->groupname]))
{
gd->addClass(cd);
//printf("Compound %s: in group %s\n",cd->name().data(),s->data());
@@ -607,7 +604,7 @@ void addNamespaceToGroups(Entry *root,NamespaceDef *nd)
{
GroupDef *gd=0;
//printf("group `%s'\n",s->data());
- if (!g->groupname.isEmpty() && (gd=Doxygen::groupDict[g->groupname]))
+ if (!g->groupname.isEmpty() && (gd=Doxygen::groupSDict[g->groupname]))
{
gd->addNamespace(nd);
//printf("Namespace %s: in group %s\n",nd->name().data(),s->data());
@@ -622,7 +619,7 @@ void addGroupToGroups(Entry *root,GroupDef *subGroup)
for (;(g=gli.current());++gli)
{
GroupDef *gd=0;
- if (!g->groupname.isEmpty() && (gd=Doxygen::groupDict[g->groupname]) &&
+ if (!g->groupname.isEmpty() && (gd=Doxygen::groupSDict[g->groupname]) &&
!gd->containsGroup(subGroup) )
{
gd->addGroup(subGroup);
@@ -645,7 +642,7 @@ void addMemberToGroups(Entry *root,MemberDef *md)
{
GroupDef *gd=0;
if (!g->groupname.isEmpty() &&
- (gd=Doxygen::groupDict[g->groupname]) &&
+ (gd=Doxygen::groupSDict[g->groupname]) &&
g->pri >= pri)
{
if( fgd && g->pri == pri ) {
@@ -724,7 +721,7 @@ void addExampleToGroups(Entry *root,PageInfo *eg)
for (;(g=gli.current());++gli)
{
GroupDef *gd=0;
- if (!g->groupname.isEmpty() && (gd=Doxygen::groupDict[g->groupname]))
+ if (!g->groupname.isEmpty() && (gd=Doxygen::groupSDict[g->groupname]))
{
gd->addExample(eg);
//printf("Example %s: in group %s\n",eg->name().data(),s->data());
@@ -736,3 +733,25 @@ QCString GroupDef::getOutputFileBase() const
{
return convertNameToFile(fileName);
}
+
+void GroupDef::addListReferences()
+{
+ addRefItem(todoId(),testId(),bugId(),
+ theTranslator->trGroup(TRUE,TRUE),
+ getOutputFileBase(),name()
+ );
+ MemberGroupListIterator mgli(*memberGroupList);
+ MemberGroup *mg;
+ for (;(mg=mgli.current());++mgli)
+ {
+ mg->addListReferences(this);
+ }
+ docDefineMembers.addListReferences(this);
+ docProtoMembers.addListReferences(this);
+ docTypedefMembers.addListReferences(this);
+ docEnumMembers.addListReferences(this);
+ docFuncMembers.addListReferences(this);
+ docVarMembers.addListReferences(this);
+}
+
+
diff --git a/src/groupdef.h b/src/groupdef.h
index 0adc59d..458d314 100644
--- a/src/groupdef.h
+++ b/src/groupdef.h
@@ -19,8 +19,7 @@
#define GROUPDEF_H
#include "qtbc.h"
-#include <qlist.h>
-#include <qdict.h>
+#include "sortdict.h"
#include "definition.h"
#include "memberlist.h"
#include "memberdef.h"
@@ -76,6 +75,8 @@ class GroupDef : public Definition
void addMembersToMemberGroup();
void distributeMemberGroupDocumentation();
+ void addListReferences();
+
bool visited; // number of times accessed for output - KPW
friend void writeGroupTreeNode(OutputList&, GroupDef*,bool);
@@ -91,8 +92,8 @@ class GroupDef : public Definition
FileList *fileList; // list of files in the group
ClassSDict *classSDict; // list of classes in the group
NamespaceList *namespaceList; // list of namespaces in the group
- GroupList *groupList; // list of sub groups.
- GroupList *parentGroupList; // list of parent groups.
+ GroupList *groupList; // list of sub groups.
+ GroupList *parentGroupList; // list of parent groups.
PageSDict *pageDict; // list of pages in the group
PageSDict *exampleDict; // list of examples in the group
@@ -113,7 +114,6 @@ class GroupDef : public Definition
MemberList docProtoMembers;
MemberList docTypedefMembers;
MemberList docEnumMembers;
- MemberList docEnumValMembers;
MemberList docFuncMembers;
MemberList docVarMembers;
@@ -122,14 +122,15 @@ class GroupDef : public Definition
MemberGroupDict *memberGroupDict;
};
-class GroupList : public QList<GroupDef>
+class GroupSDict : public SDict<GroupDef>
{
+ public:
+ GroupSDict(uint size) : SDict<GroupDef>(size) {}
+ virtual ~GroupSDict() {}
};
-class GroupListIterator : public QListIterator<GroupDef>
+class GroupList : public QList<GroupDef>
{
- public:
- GroupListIterator(const GroupList &l) : QListIterator<GroupDef>(l) {}
};
void addClassToGroups(Entry *root,ClassDef *cd);
diff --git a/src/index.cpp b/src/index.cpp
index 5caca70..3a9fa12 100644
--- a/src/index.cpp
+++ b/src/index.cpp
@@ -350,10 +350,12 @@ void writeClassTree(OutputList &ol,BaseClassList *bcl,bool hideSuper,int level)
{
// UGLY HACK!
ol.pushGeneratorState();
- ol.disableAllBut(OutputGenerator::Latex);
+ ol.disable(OutputGenerator::Man);
+ ol.disable(OutputGenerator::Html);
if (level<6) ol.startIndexList();
ol.enableAll();
ol.disable(OutputGenerator::Latex);
+ ol.disable(OutputGenerator::RTF);
ol.startItemList();
ol.popGeneratorState();
}
@@ -408,10 +410,12 @@ void writeClassTree(OutputList &ol,BaseClassList *bcl,bool hideSuper,int level)
{
// UGLY HACK!
ol.pushGeneratorState();
- ol.disableAllBut(OutputGenerator::Latex);
+ ol.disable(OutputGenerator::Man);
+ ol.disable(OutputGenerator::Html);
if (level<6) ol.endIndexList();
ol.enableAll();
ol.disable(OutputGenerator::Latex);
+ ol.disable(OutputGenerator::RTF);
ol.endItemList();
ol.popGeneratorState();
}
@@ -571,10 +575,12 @@ static void writeClassTreeForList(OutputList &ol,ClassSDict *cl,bool &started)
{
// UGLY HACK!
ol.pushGeneratorState();
- ol.disableAllBut(OutputGenerator::Latex);
+ ol.disable(OutputGenerator::Html);
+ ol.disable(OutputGenerator::Man);
ol.startIndexList();
ol.enableAll();
ol.disable(OutputGenerator::Latex);
+ ol.disable(OutputGenerator::RTF);
ol.startItemList();
ol.popGeneratorState();
}
@@ -651,10 +657,12 @@ void writeClassHierarchy(OutputList &ol)
{
// UGLY HACK!
ol.pushGeneratorState();
- ol.disableAllBut(OutputGenerator::Latex);
+ ol.disable(OutputGenerator::Html);
+ ol.disable(OutputGenerator::Man);
ol.endIndexList();
ol.enableAll();
ol.disable(OutputGenerator::Latex);
+ ol.disable(OutputGenerator::RTF);
ol.endItemList();
ol.popGeneratorState();
}
@@ -2025,7 +2033,7 @@ void writeExampleIndex(OutputList &ol)
//ol.newParagraph();
ol.endTextBlock();
ol.startItemList();
- PageSDictIterator pdi(*Doxygen::exampleSDict);
+ PageSDict::Iterator pdi(*Doxygen::exampleSDict);
PageInfo *pi=0;
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
@@ -2063,7 +2071,7 @@ void writeExampleIndex(OutputList &ol)
void countRelatedPages(int &docPages,int &indexPages)
{
docPages=indexPages=0;
- PageSDictIterator pdi(*Doxygen::pageSDict);
+ PageSDict::Iterator pdi(*Doxygen::pageSDict);
PageInfo *pi=0;
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
@@ -2129,7 +2137,7 @@ void writePageIndex(OutputList &ol)
//ol.newParagraph();
ol.endTextBlock();
ol.startItemList();
- PageSDictIterator pdi(*Doxygen::pageSDict);
+ PageSDict::Iterator pdi(*Doxygen::pageSDict);
PageInfo *pi=0;
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
@@ -2180,9 +2188,9 @@ void writePageIndex(OutputList &ol)
int countGroups()
{
int count=0;
- GroupListIterator gli(Doxygen::groupList);
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
GroupDef *gd;
- for (;(gd=gli.current());++gli)
+ for (gli.toFirst();(gd=gli.current());++gli)
{
if (!gd->isReference())
{
@@ -2237,8 +2245,6 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
ftvHelp = FTVHelp::getInstance();
}
- GroupDef *subgd = 0;
- GroupListIterator gli(*gd->groupList);
if (!gd->visited && (!gd->isASubGroup() || subLevel))
{
//printf("gd->name()=%s #members=%d\n",gd->name().data(),gd->countMembers());
@@ -2251,7 +2257,6 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
numSubItems += gd->docDefineMembers.count();
numSubItems += gd->docTypedefMembers.count();
numSubItems += gd->docEnumMembers.count();
- numSubItems += gd->docEnumValMembers.count();
numSubItems += gd->docFuncMembers.count();
numSubItems += gd->docVarMembers.count();
numSubItems += gd->docProtoMembers.count();
@@ -2293,7 +2298,7 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
//ol.writeEndAnnoItem(gd->getOutputFileBase());
// write pages
- PageSDictIterator pli(*gd->pageDict);
+ PageSDict::Iterator pli(*gd->pageDict);
PageInfo *pi = 0;
for (pli.toFirst();(pi=pli.current());++pli)
{
@@ -2316,6 +2321,8 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
if (hasSubGroups)
{
ol.startItemList();
+ QListIterator<GroupDef> gli(*gd->groupList);
+ GroupDef *subgd = 0;
for (gli.toLast();(subgd=gli.current());--gli)
{
writeGroupTreeNode(ol,subgd,TRUE);
@@ -2338,7 +2345,6 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
MemInfo(&gd->docDefineMembers, theTranslator->trDefines()),
MemInfo(&gd->docTypedefMembers, theTranslator->trTypedefs()),
MemInfo(&gd->docEnumMembers, theTranslator->trEnumerations()),
- MemInfo(&gd->docEnumValMembers, theTranslator->trEnumerationValues()),
MemInfo(&gd->docFuncMembers, theTranslator->trFunctions()),
MemInfo(&gd->docVarMembers, theTranslator->trVariables()),
MemInfo(&gd->docProtoMembers, theTranslator->trFuncProtos()),
@@ -2491,7 +2497,7 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
ftvHelp->incContentsDepth();
}
- PageSDictIterator eli(*(gd->exampleDict));
+ PageSDict::Iterator eli(*(gd->exampleDict));
PageInfo *pi=eli.toFirst();
while (pi)
{
@@ -2521,9 +2527,9 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
void writeGroupHierarchy(OutputList &ol)
{
ol.startItemList();
- GroupListIterator gli(Doxygen::groupList);
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
GroupDef *gd;
- for (;(gd=gli.current());++gli)
+ for (gli.toFirst();(gd=gli.current());++gli)
{
writeGroupTreeNode(ol,gd,FALSE);
}
diff --git a/src/latexgen.cpp b/src/latexgen.cpp
index da50b21..1e42ee8 100644
--- a/src/latexgen.cpp
+++ b/src/latexgen.cpp
@@ -504,9 +504,10 @@ void LatexGenerator::startIndexSection(IndexSections is)
break;
case isModuleDocumentation:
{
- GroupDef *gd=Doxygen::groupList.first();
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
+ GroupDef *gd;
bool found=FALSE;
- while (gd && !found)
+ for (gli.toFirst();(gd=gli.current()) && !found;++gli)
{
if (!gd->isReference())
{
@@ -514,7 +515,6 @@ void LatexGenerator::startIndexSection(IndexSections is)
t << "{"; //Module Documentation}\n";
found=TRUE;
}
- gd=Doxygen::groupList.next();
}
}
break;
@@ -659,25 +659,24 @@ void LatexGenerator::endIndexSection(IndexSections is)
break;
case isModuleDocumentation:
{
- GroupDef *gd=Doxygen::groupList.first();
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
+ GroupDef *gd;
bool found=FALSE;
- while (gd && !found)
+ for (gli.toFirst();(gd=gli.current()) && !found;++gli)
{
if (!gd->isReference())
{
t << "}\n\\input{" << gd->getOutputFileBase() << "}\n";
found=TRUE;
}
- gd=Doxygen::groupList.next();
}
- while (gd)
+ for (;(gd=gli.current());++gli)
{
if (!gd->isReference())
{
if (compactLatex) t << "\\input"; else t << "\\include";
t << "{" << gd->getOutputFileBase() << "}\n";
}
- gd=Doxygen::groupList.next();
}
}
break;
@@ -759,7 +758,7 @@ void LatexGenerator::endIndexSection(IndexSections is)
case isExampleDocumentation:
{
t << "}\n";
- PageSDictIterator pdi(*Doxygen::exampleSDict);
+ PageSDict::Iterator pdi(*Doxygen::exampleSDict);
PageInfo *pi=pdi.toFirst();
if (pi)
{
@@ -775,7 +774,7 @@ void LatexGenerator::endIndexSection(IndexSections is)
case isPageDocumentation:
{
t << "}\n";
- PageSDictIterator pdi(*Doxygen::pageSDict);
+ PageSDict::Iterator pdi(*Doxygen::pageSDict);
PageInfo *pi=pdi.toFirst();
bool first=TRUE;
for (pdi.toFirst();(pi=pdi.current());++pdi)
diff --git a/src/memberdef.cpp b/src/memberdef.cpp
index b7631f8..7b8245a 100644
--- a/src/memberdef.cpp
+++ b/src/memberdef.cpp
@@ -1675,3 +1675,20 @@ void MemberDef::setInitializer(const char *initializer)
init=init.left(p+1);
initLines=init.contains('\n');
}
+
+void MemberDef::addListReference(Definition *d)
+{
+ visited=TRUE;
+ QCString memLabel;
+ if (Config_getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ memLabel=theTranslator->trGlobal(TRUE,TRUE);
+ }
+ else
+ {
+ memLabel=theTranslator->trMember(TRUE,TRUE);
+ }
+ addRefItem(todoId(),testId(),bugId(),memLabel,
+ d->getOutputFileBase()+":"+anchor(),name(),argsString());
+}
+
diff --git a/src/memberdef.h b/src/memberdef.h
index d81470c..64cb11f 100644
--- a/src/memberdef.h
+++ b/src/memberdef.h
@@ -230,6 +230,7 @@ class MemberDef : public Definition
MemberDef *createTemplateInstanceMember(ArgumentList *formalArgs,
ArgumentList *actualArgs);
void setTemplateMaster(MemberDef *mt) { m_templateMaster=mt; }
+ void addListReference(Definition *d);
bool visited;
diff --git a/src/membergroup.cpp b/src/membergroup.cpp
index 0ffe1b3..1f5dffd 100644
--- a/src/membergroup.cpp
+++ b/src/membergroup.cpp
@@ -204,3 +204,8 @@ void MemberGroup::setInGroup(bool b)
{
memberList->setInGroup(b);
}
+
+void MemberGroup::addListReferences(Definition *def)
+{
+ memberList->addListReferences(def);
+}
diff --git a/src/membergroup.h b/src/membergroup.h
index 833350e..63b047b 100644
--- a/src/membergroup.h
+++ b/src/membergroup.h
@@ -65,6 +65,7 @@ class MemberGroup /* : public Definition */
int numDecMembers() const;
int numDocMembers() const;
void setInGroup(bool b);
+ void addListReferences(Definition *d);
private:
MemberList *memberList; // list of all members in the group
diff --git a/src/memberlist.cpp b/src/memberlist.cpp
index bc9195b..77906f9 100644
--- a/src/memberlist.cpp
+++ b/src/memberlist.cpp
@@ -553,4 +553,25 @@ void MemberList::addMemberGroup(MemberGroup *mg)
memberGroupList->append(mg);
}
+void MemberList::addListReferences(Definition *def)
+{
+ MemberListIterator mli(*this);
+ MemberDef *md;
+ for ( ; (md=mli.current()) ; ++mli)
+ {
+ if (md->getGroupDef()==0 || def->definitionType()==Definition::TypeGroup)
+ {
+ md->addListReference(def);
+ }
+ }
+ if (memberGroupList)
+ {
+ MemberGroupListIterator mgli(*memberGroupList);
+ MemberGroup *mg;
+ for (;(mg=mgli.current());++mgli)
+ {
+ mg->addListReferences(def);
+ }
+ }
+}
diff --git a/src/memberlist.h b/src/memberlist.h
index 9b8410f..3dec524 100644
--- a/src/memberlist.h
+++ b/src/memberlist.h
@@ -54,6 +54,7 @@ class MemberList : public QList<MemberDef>
Definition *container,const char *title);
void addMemberGroup(MemberGroup *mg);
void setInGroup(bool group) { m_inGroup=group; }
+ void addListReferences(Definition *def);
private:
int m_varCnt,m_funcCnt,m_enumCnt,m_enumValCnt,m_typeCnt;
diff --git a/src/membername.h b/src/membername.h
index b99b1da..3eabfe8 100644
--- a/src/membername.h
+++ b/src/membername.h
@@ -40,25 +40,6 @@ class MemberNameIterator : public QListIterator<MemberDef>
MemberNameIterator( const MemberName &list);
};
-#if 0
-class MemberNameList : public QList<MemberName>
-{
- public:
- MemberNameList();
- ~MemberNameList();
-
- int compareItems(GCI item1,GCI item2);
-};
-
-class MemberNameListIterator : public QListIterator<MemberName>
-{
- public:
- MemberNameListIterator( const MemberNameList &list );
-};
-
-typedef QDict<MemberName> MemberNameDict;
-#endif
-
class MemberNameSDict : public SDict<MemberName>
{
public:
@@ -100,34 +81,6 @@ class MemberNameInfoIterator : public QListIterator<MemberInfo>
: QListIterator<MemberInfo>(mnii) {}
};
-#if 0
-class MemberNameInfoList : public QList<MemberNameInfo>
-{
- public:
- ~MemberNameInfoList() {}
- int compareItems(GCI item1,GCI item2)
- { return stricmp(
- ((MemberNameInfo *)item1)->memberName(),
- ((MemberNameInfo *)item2)->memberName()
- );
- }
-};
-
-class MemberNameInfoDict : public QDict<MemberNameInfo>
-{
- public:
- MemberNameInfoDict(int size) : QDict<MemberNameInfo>(size) {}
- ~MemberNameInfoDict() {}
-};
-
-class MemberNameInfoListIterator : public QListIterator<MemberNameInfo>
-{
- public:
- MemberNameInfoListIterator(const MemberNameInfoList &mil) :
- QListIterator<MemberNameInfo>(mil) {}
-};
-#endif
-
class MemberNameInfoSDict : public SDict<MemberNameInfo>
{
diff --git a/src/namespacedef.cpp b/src/namespacedef.cpp
index 72223f5..9e2692d 100644
--- a/src/namespacedef.cpp
+++ b/src/namespacedef.cpp
@@ -374,4 +374,23 @@ void NamespaceDef::addInnerCompound(Definition *d)
m_innerCompounds->append(d->localName(),d);
}
+void NamespaceDef::addListReferences()
+{
+ addRefItem(todoId(),testId(),bugId(),
+ theTranslator->trNamespace(TRUE,TRUE),
+ getOutputFileBase(),name()
+ );
+ MemberGroupListIterator mgli(*memberGroupList);
+ MemberGroup *mg;
+ for (;(mg=mgli.current());++mgli)
+ {
+ mg->addListReferences(this);
+ }
+ docDefineMembers.addListReferences(this);
+ docProtoMembers.addListReferences(this);
+ docTypedefMembers.addListReferences(this);
+ docEnumMembers.addListReferences(this);
+ docFuncMembers.addListReferences(this);
+ docVarMembers.addListReferences(this);
+}
diff --git a/src/namespacedef.h b/src/namespacedef.h
index ab0393b..ef82d9c 100644
--- a/src/namespacedef.h
+++ b/src/namespacedef.h
@@ -73,6 +73,7 @@ class NamespaceDef : public Definition
virtual Definition *findInnerCompound(const char *name);
void addInnerCompound(Definition *d);
+ void addListReferences();
//protected:
// void addMemberListToGroup(MemberList *,bool (MemberDef::*)() const);
diff --git a/src/page.h b/src/page.h
index a34875b..f082700 100644
--- a/src/page.h
+++ b/src/page.h
@@ -108,13 +108,3 @@ class PageSDict : public SDict<PageInfo>
}
};
-// typedef is to get around Solaris compile problem
-typedef SDict<PageInfo>::Iterator _SDictPageInfoIterator;
-
-class PageSDictIterator : public _SDictPageInfoIterator
-{
- public:
- PageSDictIterator(const PageSDict &d) : _SDictPageInfoIterator(d) {}
- ~PageSDictIterator() {}
-};
-
diff --git a/src/pre.l b/src/pre.l
index 97a5606..84501e1 100644
--- a/src/pre.l
+++ b/src/pre.l
@@ -1040,6 +1040,14 @@ BN [ \t\r\n]
outputArray(yytext,yyleng);
BEGIN(CopyLine);
}
+<Start>^{B}*[_A-Z][_A-Z0-9]*"("[^\)\n]*")"/{BN}{1,10}*[:{] { // constructors?
+ int i;
+ for (i=yyleng-1;i>=0;i--)
+ {
+ unput(yytext[i]);
+ }
+ BEGIN(CopyLine);
+ }
<Start>^{B}*[_A-Z][_A-Z0-9]*"("[^\)\n]*")"{B}*\n { // function like macro
static bool skipFuncMacros = Config_getBool("SKIP_FUNCTION_MACROS");
QCString name(yytext);
diff --git a/src/rtfgen.cpp b/src/rtfgen.cpp
index 338d889..1d992a4 100644
--- a/src/rtfgen.cpp
+++ b/src/rtfgen.cpp
@@ -969,16 +969,16 @@ void RTFGenerator::startIndexSection(IndexSections is)
case isModuleDocumentation:
{
//Module Documentation
- GroupDef *gd=Doxygen::groupList.first();
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
+ GroupDef *gd;
bool found=FALSE;
- while (gd && !found)
+ for (gli.toFirst();(gd=gli.current()) && !found;++gli)
{
if (!gd->isReference())
{
beginRTFChapter();
found=TRUE;
}
- gd=Doxygen::groupList.next();
}
}
break;
@@ -1185,9 +1185,10 @@ void RTFGenerator::endIndexSection(IndexSections is)
break;
case isModuleDocumentation:
{
- GroupDef *gd=Doxygen::groupList.first();
+ GroupSDict::Iterator gli(Doxygen::groupSDict);
+ GroupDef *gd;
t << "{\\tc \\v " << theTranslator->trModuleDocumentation() << "}"<< endl;
- while (gd)
+ for (gli.toFirst();(gd=gli.current());++gli)
{
if (!gd->isReference())
{
@@ -1196,7 +1197,6 @@ void RTFGenerator::endIndexSection(IndexSections is)
t << gd->getOutputFileBase();
t << ".rtf\" \\\\*MERGEFORMAT}{\\fldrslt includedstuff}}\n";
}
- gd=Doxygen::groupList.next();
}
}
break;
@@ -1301,7 +1301,7 @@ void RTFGenerator::endIndexSection(IndexSections is)
{
//t << "}\n";
t << "{\\tc \\v " << theTranslator->trExampleDocumentation() << "}"<< endl;
- PageSDictIterator pdi(*Doxygen::exampleSDict);
+ PageSDict::Iterator pdi(*Doxygen::exampleSDict);
PageInfo *pi=pdi.toFirst();
if (pi)
{
@@ -1323,7 +1323,7 @@ void RTFGenerator::endIndexSection(IndexSections is)
case isPageDocumentation:
{
t << "{\\tc \\v " << theTranslator->trPageDocumentation() << "}"<< endl;
- PageSDictIterator pdi(*Doxygen::pageSDict);
+ PageSDict::Iterator pdi(*Doxygen::pageSDict);
PageInfo *pi=pdi.toFirst();
bool first=TRUE;
for (pdi.toFirst();(pi=pdi.current());++pdi)
@@ -1960,9 +1960,10 @@ void RTFGenerator::endMemberDescription()
void RTFGenerator::startDescList(SectionTypes)
{
DBG_RTF(t << "{\\comment (startDescList)}" << endl)
- t << "{";
- newParagraph();
+ t << "{"; // ends at endDescList
+ t << "{"; // ends at endDescTitle
startBold();
+ newParagraph();
}
void RTFGenerator::endDescTitle()
@@ -1978,25 +1979,23 @@ void RTFGenerator::endDescTitle()
void RTFGenerator::writeDescItem()
{
DBG_RTF(t << "{\\comment (writeDescItem) }" << endl)
- // incrementIndentLevel();
- //t << Rtf_Style_Reset << Rtf_CList_DepthStyle();
}
void RTFGenerator::endDescList()
{
DBG_RTF(t << "{\\comment (endDescList)}" << endl)
newParagraph();
- //t << "}";
decrementIndentLevel();
m_omitParagraph = TRUE;
- //t << Rtf_Style_Reset << styleStack.top() << endl;
- t << Rtf_Style_Reset << endl;
+ t << "}";
}
void RTFGenerator::startParamList(ParamListTypes)
{
DBG_RTF(t << "{\\comment (startParamList)}" << endl)
- t << "{";
+ t << "{"; // ends at endParamList
+ t << "{"; // ends at endDescTitle
+ startBold();
newParagraph();
}
@@ -2004,10 +2003,9 @@ void RTFGenerator::endParamList()
{
DBG_RTF(t << "{\\comment (endParamList)}" << endl)
newParagraph();
- t << "}";
decrementIndentLevel();
m_omitParagraph = TRUE;
- //t << Rtf_Style_Reset << styleStack.top() << endl;
+ t << "}";
}
@@ -2295,7 +2293,7 @@ void RTFGenerator::endDotFile(bool)
void RTFGenerator::startDescTable()
{
DBG_RTF(t << "{\\comment (startDescTable) }" << endl)
- t << "{" << endl;
+ //t << "{" << endl;
//incrementIndentLevel();
//t << Rtf_Style_Reset << Rtf_CList_DepthStyle();
}
@@ -2304,7 +2302,7 @@ void RTFGenerator::endDescTable()
{
//decrementIndentLevel();
DBG_RTF(t << "{\\comment (endDescTable)}" << endl)
- t << "}" << endl;
+ //t << "}" << endl;
//t << Rtf_Style_Reset << styleStack.top();
}
@@ -2327,12 +2325,14 @@ void RTFGenerator::endDescTableTitle()
void RTFGenerator::startDescTableData()
{
DBG_RTF(t << "{\\comment (startDescTableData) }" << endl)
+ m_omitParagraph=FALSE;
}
void RTFGenerator::endDescTableData()
{
DBG_RTF(t << "{\\comment (endDescTableData) }" << endl)
newParagraph();
+ m_omitParagraph=TRUE;
}
// a style for list formatted as a "bulleted list"
@@ -2661,6 +2661,50 @@ void RTFGenerator::endInclDepGraph(DotInclDepGraph &g)
t << "}" << endl;
}
+/** Tests the integrity of the result by counting brackets.
+ *
+ */
+void testRTFOutput(const char *name)
+{
+ int bcount=0;
+ int line=1;
+ int c;
+ QFile f(name);
+ if (f.open(IO_ReadOnly))
+ {
+ while ((c=f.getch())!=-1)
+ {
+ if (c=='\\') // escape char
+ {
+ c=f.getch();
+ if (c==-1) break;
+ }
+ else if (c=='{') // open bracket
+ {
+ bcount++;
+ }
+ else if (c=='}') // close bracket
+ {
+ bcount--;
+ if (bcount<0)
+ {
+ goto err;
+ break;
+ }
+ }
+ else if (c=='\n') // newline
+ {
+ line++;
+ }
+ }
+ }
+ if (bcount==0) return; // file is OK.
+err:
+ err("Error: RTF integrity test failed at line %d of %s due to a bracket mismatch.\n",line,name);
+ err(" Please try to create a small code example that produces this error \n"
+ " and send that to dimitri@stack.nl.\n");
+}
+
/**
* This is an API to a VERY brittle RTF preprocessor that combines nested
* RTF files. This version replaces the infile with the new file
@@ -2708,6 +2752,8 @@ bool RTFGenerator::preProcessFileInplace(const char *path,const char *name)
thisDir.remove(mainRTFName);
thisDir.rename(combinedName,mainRTFName);
+ testRTFOutput(mainRTFName);
+
QDir::setCurrent(oldDir);
return TRUE;
}
diff --git a/src/translator_en.h b/src/translator_en.h
index 9e841e2..13062fe 100644
--- a/src/translator_en.h
+++ b/src/translator_en.h
@@ -1051,6 +1051,8 @@ class TranslatorEnglish : public Translator
"class Undocumented { };\n\n"
"/*! Class that is inherited using public inheritance */\n"
"class PublicBase : public Truncated { };\n\n"
+ "/*! A template class */\n"
+ "template<class T> class Templ { };\n\n"
"/*! Class that is inherited using protected inheritance */\n"
"class ProtectedBase { };\n\n"
"/*! Class that is inherited using private inheritance */\n"
@@ -1062,13 +1064,14 @@ class TranslatorEnglish : public Translator
" protected ProtectedBase,\n"
" private PrivateBase,\n"
" public Undocumented\n"
+ " public Templ<int>\n"
"{\n"
" private:\n"
" Used *m_usedClass;\n"
"};\n"
"\\endcode\n"
"If the \\c MAX_DOT_GRAPH_HEIGHT tag in the configuration file "
- "is set to 200 this will result in the following graph:"
+ "is set to 240 this will result in the following graph:"
"<p><center><img src=\"graph_legend.gif\"></center>\n"
"<p>\n"
"The boxes in the above graph have the following meaning:\n"
@@ -1077,9 +1080,9 @@ class TranslatorEnglish : public Translator
"graph is generated.\n"
"<li>%A box with a black border denotes a documented struct or class.\n"
"<li>%A box with a grey border denotes an undocumented struct or class.\n"
- "<li>%A box with a red border denotes a documented struct or class for\n"
+ "<li>%A box with a red border denotes a documented struct or class for"
"which not all inheritance/containment relations are shown. %A graph is "
- "truncated if it does not fit within the specified boundaries."
+ "truncated if it does not fit within the specified boundaries.\n"
"</ul>\n"
"The arrows have the following meaning:\n"
"<ul>\n"
@@ -1089,7 +1092,10 @@ class TranslatorEnglish : public Translator
"<li>%A dark red arrow is used for private inheritance.\n"
"<li>%A purple dashed arrow is used if a class is contained or used "
"by another class. The arrow is labeled with the variable(s) "
- "through which the pointed class or struct is accessible. \n"
+ "through which the pointed class or struct is accessible.\n"
+ "<li>%A yellow dashed arrow denotes a relation between a template instance and "
+ "the template class it was instantiated from. The arrow is labeled with "
+ "the template parameters of the instance.\n"
"</ul>\n";
}
/*! text for the link to the legend page */
diff --git a/src/util.cpp b/src/util.cpp
index 81c7916..f1fa9c6 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -40,7 +40,7 @@
#include "example.h"
#include "version.h"
#include "groupdef.h"
-//#include "xml.h"
+#include "reflist.h"
#include "page.h"
#ifndef _WIN32
@@ -2557,7 +2557,7 @@ bool generateRef(OutputDocInterface &od,const char *scName,
}
return TRUE;
}
- else if (inSeeBlock && !nameStr.isEmpty() && (gd=Doxygen::groupDict[nameStr]))
+ else if (inSeeBlock && !nameStr.isEmpty() && (gd=Doxygen::groupSDict[nameStr]))
{ // group link
od.startTextLink(gd->getOutputFileBase(),0);
if (rt) // explict link text
@@ -2636,7 +2636,7 @@ bool generateLink(OutputDocInterface &od,const char *clName,
}
return TRUE;
}
- else if ((gd=Doxygen::groupDict[linkRef])) // link to a group
+ else if ((gd=Doxygen::groupSDict[linkRef])) // link to a group
{
od.startTextLink(gd->getOutputFileBase(),0);
if (lt)
@@ -3431,3 +3431,178 @@ found:
return p;
}
+//----------------------------------------------------------------------------
+
+void addRelatedPage(const char *name,const QCString &ptitle,
+ const QCString &doc,QList<QCString> *anchors,
+ const char *fileName,int startLine,
+ int todoId,int testId,int bugId,GroupDef *gd=0,
+ TagInfo *tagInfo=0
+ )
+{
+ PageInfo *pi=0;
+ if ((pi=Doxygen::pageSDict->find(name)) && !tagInfo)
+ {
+ // append documentation block to the page.
+ pi->doc+="\n\n"+doc;
+ }
+ else // new page
+ {
+ QCString baseName=name;
+ if (baseName.right(4)==".tex")
+ baseName=baseName.left(baseName.length()-4);
+ else if (baseName.right(5)==".html")
+ baseName=baseName.left(baseName.length()-5);
+
+ QCString title=ptitle.stripWhiteSpace();
+ pi=new PageInfo(fileName,startLine,baseName,doc,title);
+ pi->todoId=todoId;
+ pi->testId=testId;
+ pi->bugId=bugId;
+ if (tagInfo)
+ {
+ pi->reference = tagInfo->tagName;
+ }
+
+ QCString pageName;
+ if (Config_getBool("CASE_SENSE_NAMES"))
+ pageName=pi->name.copy();
+ else
+ pageName=pi->name.lower();
+ //setFileNameForSections(anchors,pageName,pi);
+ pi->fileName = pageName;
+ pi->addSections(anchors);
+
+ Doxygen::pageSDict->append(baseName,pi);
+
+ if (gd) gd->addPage(pi);
+
+ if (!pi->title.isEmpty())
+ {
+ //outputList->writeTitle(pi->name,pi->title);
+
+ // a page name is a label as well!
+ SectionInfo *si=new SectionInfo(
+ pi->name,pi->title,SectionInfo::Section,pi->reference);
+ if (gd)
+ {
+ si->fileName=gd->getOutputFileBase();
+ }
+ else if (pi->inGroup)
+ {
+ si->fileName=pi->inGroup->getOutputFileBase().copy();
+ }
+ else
+ {
+ si->fileName=pageName;
+ }
+ //printf("si->label=`%s' si->definition=%s si->fileName=`%s'\n",
+ // si->label.data(),si->definition?si->definition->name().data():"<none>",
+ // si->fileName.data());
+ //printf(" SectionInfo: sec=%p sec->fileName=%s\n",si,si->fileName.data());
+ //printf("Adding section info %s\n",pi->name.data());
+ Doxygen::sectionDict.insert(pageName,si);
+ }
+ }
+}
+
+//----------------------------------------------------------------------------
+
+void addRefItem(int todoId,int testId,int bugId,const char *prefix,
+ const char *name,const char *title,const char *args=0)
+{
+
+ //printf("addRefItem(%s) todoId=%d testId=%d bugId=%d\n",name,todoId,testId,bugId);
+
+ ////////////////////////////////////////////////////////////
+ // add item to the todo list
+ ////////////////////////////////////////////////////////////
+
+ if (todoId>0 && Config_getBool("GENERATE_TODOLIST"))
+ {
+ RefItem *item = todoList.getRefItem(todoId);
+ ASSERT(item!=0);
+ if (item->written) return;
+
+ QCString doc;
+ doc += "<dl><dt>\\anchor ";
+ doc += item->listAnchor;
+ doc += "\n";
+ doc += prefix;
+ doc += " \\_internalref ";
+ doc += name;
+ doc += " \"";
+ doc += title;
+ doc += "\"";
+ if (args) doc += args;
+ doc += "</dt>\n<dd>";
+ doc += item->text;
+ doc += "</dd></dl>\n";
+ //printf("Todo page: %s\n",doc.data());
+ addRelatedPage("todo",theTranslator->trTodoList(),doc,0,"generated",1,0,0,0);
+
+ item->written=TRUE;
+ }
+
+ ////////////////////////////////////////////////////////////
+ // add item to the test list
+ ////////////////////////////////////////////////////////////
+
+ if (testId>0 && Config_getBool("GENERATE_TESTLIST"))
+ {
+ RefItem *item = testList.getRefItem(testId);
+ ASSERT(item!=0);
+ if (item->written) return;
+
+ QCString doc;
+ doc += "<dl><dt>\\anchor ";
+ doc += item->listAnchor;
+ doc += "\n";
+ doc += prefix;
+ doc += " \\_internalref ";
+ doc += name;
+ doc += " \"";
+ doc += title;
+ doc += "\"";
+ if (args) doc += args;
+ doc += "</dt>\n<dd>";
+ doc += item->text;
+ doc += "</dd></dl>\n";
+ //printf("Test page: %s\n",doc.data());
+ addRelatedPage("test",theTranslator->trTestList(),doc,0,"generated",1,0,0,0);
+
+ item->written=TRUE;
+ }
+
+ ////////////////////////////////////////////////////////////
+ // add item to the bug list
+ ////////////////////////////////////////////////////////////
+
+ if (bugId>0 && Config_getBool("GENERATE_BUGLIST"))
+ {
+ RefItem *item = bugList.getRefItem(bugId);
+ ASSERT(item!=0);
+ if (item->written) return;
+
+ QCString doc;
+ doc += "<dl><dt>\\anchor ";
+ doc += item->listAnchor;
+ doc += "\n";
+ doc += prefix;
+ doc += " \\_internalref ";
+ doc += name;
+ doc += " \"";
+ doc += title;
+ doc += "\"";
+ if (args) doc += args;
+ doc += "</dt>\n<dd>";
+ doc += item->text;
+ doc += "</dd></dl>\n";
+ //printf("Bug page: %s\n",doc.data());
+ addRelatedPage("bug",theTranslator->trBugList(),doc,0,"generated",1,0,0,0);
+
+ item->written=TRUE;
+ }
+}
+
+
diff --git a/src/util.h b/src/util.h
index b9a4bf1..6a9f058 100644
--- a/src/util.h
+++ b/src/util.h
@@ -42,6 +42,7 @@ class ClassList;
class MemberGroupList;
class MemberGroupDict;
class Definition;
+class TagInfo;
//--------------------------------------------------------------------
@@ -165,6 +166,14 @@ QCString resolveTypeDef(Definition *d,const QCString &name);
QCString mergeScopes(const QCString &leftScope,const QCString &rightScope);
int getScopeFragment(const QCString &s,int p,int *l);
int filterCRLF(char *buf,int len);
+void addRefItem(int todoId,int testId,int bugId,const char *prefix,
+ const char *name,const char *title,const char *args=0);
+void addRelatedPage(const char *name,const QCString &ptitle,
+ const QCString &doc,QList<QCString> *anchors,
+ const char *fileName,int startLine,
+ int todoId,int testId,int bugId,GroupDef *gd=0,
+ TagInfo *tagInfo=0
+ );
#endif