Commit 5ce25000 authored by Dimitri van Heesch's avatar Dimitri van Heesch

Release-1.2.1

parent c4ef4619
DOXYGEN Version 1.2.0-20000806
DOXYGEN Version 1.2.1
Please read the installation section of the manual for instructions.
--------
Dimitri van Heesch (06 August 2000)
Dimitri van Heesch (13 August 2000)
DOXYGEN Version 1.2.0-20000806
DOXYGEN Version 1.2.1
Please read INSTALL for compilation instructions.
......@@ -7,4 +7,4 @@ The latest version of doxygen can be obtained at
Enjoy,
Dimitri van Heesch (06 August 2000)
Dimitri van Heesch (13 August 2000)
1.2.0-20000806
1.2.1
......@@ -239,7 +239,7 @@ static void readIncludeFile(const char *incName)
else
{
ConfigFileState *fs=includeStack.pop();
pclose(fs->filePtr);
fclose(fs->filePtr);
YY_BUFFER_STATE oldBuf = YY_CURRENT_BUFFER;
yy_switch_to_buffer( fs->oldState );
yy_delete_buffer( oldBuf );
......
......@@ -791,14 +791,6 @@ void init()
ConfigString::addFixedValue("outputLanguage","Croatian");
ConfigString::addFixedValue("outputLanguage","Polish");
ConfigString::addFixedValue("outputLanguage","Portuguese");
ConfigBool::add( "noIndexFlag",
"DISABLE_INDEX",
"FALSE",
"generate condensed index flag",
"The DISABLE_INDEX tag can be used to turn on/off the condensed index at \n"
"top of each HTML page. The value NO (the default) enables the index and \n"
"the value YES disables it. \n"
);
ConfigBool::add( "extractAllFlag",
"EXTRACT_ALL",
"FALSE",
......@@ -1244,6 +1236,15 @@ void init()
"of the generated HTML documentation. \n"
);
addDependency("htmlHelpFlag","generateHtml");
ConfigBool::add( "noIndexFlag",
"DISABLE_INDEX",
"FALSE",
"generate condensed index flag",
"The DISABLE_INDEX tag can be used to turn on/off the condensed index at \n"
"top of each HTML page. The value NO (the default) enables the index and \n"
"the value YES disables it. \n"
);
addDependency("noIndexFlag","generateHtml");
//-----------------------------------------------------------------------------------------------
ConfigInfo::add( "LaTeX","configuration options related to the LaTeX output");
//-----------------------------------------------------------------------------------------------
......
......@@ -30,7 +30,7 @@ ENABLED_SECTIONS = logo_on
ENABLE_PREPROCESSING = NO
CASE_SENSE_NAMES = NO
IMAGE_PATH = .
INPUT = index.doc install.doc starting.doc docblocks.doc \
INPUT = index.doc install.doc starting.doc docblocks.doc lists.doc \
grouping.doc formulas.doc diagrams.doc preprocessing.doc \
external.doc faq.doc trouble.doc history.doc features.doc \
doxygen_usage.doc doxytag_usage.doc doxysearch_usage.doc \
......
......@@ -179,7 +179,7 @@ Doxygen. Unrecognized commands are treated as normal text.
\par Example:
\verbinclude define.h
\htmlonly
Click <a href="$(DOXYGEN_DOCDIR)/examples/define/html/define.h.html">here</a>
Click <a href="$(DOXYGEN_DOCDIR)/examples/define/html/define_h.html">here</a>
for the corresponding HTML documentation that is generated by Doxygen.
\endhtmlonly
......@@ -270,7 +270,7 @@ Doxygen. Unrecognized commands are treated as normal text.
\par Example:
\verbinclude file.h
\htmlonly
Click <a href="$(DOXYGEN_DOCDIR)/examples/file/html/file.h.html">here</a>
Click <a href="$(DOXYGEN_DOCDIR)/examples/file/html/file_h.html">here</a>
for the corresponding HTML documentation that is generated by Doxygen.
\endhtmlonly
......
......@@ -204,7 +204,7 @@ Here is an example of a the use of these comment blocks:
inside these comment blocks.
\htmlonly
Go to the <a href="grouping.html">next</a> section or return to the
Go to the <a href="lists.html">next</a> section or return to the
<a href="index.html">index</a>.
\endhtmlonly
......
......@@ -20,6 +20,7 @@
\usepackage{doxygen}
\usepackage{multicol}
\usepackage{times}
\usepackage{alltt}
\usepackage[pagebackref=true,
colorlinks=true,
linkcolor=blue
......@@ -46,6 +47,7 @@ Written by Dimitri van Heesch\\[2ex]
\input{install}
\input{starting}
\input{docblocks}
\input{lists}
\input{grouping}
\input{formulas}
\input{diagrams}
......
......@@ -89,6 +89,7 @@ The first part forms a user manual:
documentation quickly.
<li>Section \ref docblocks demonstrates the various ways that code can
be documented.
<li>Section \ref lists show various ways to create lists.
<li>Section \ref grouping shows how to group things together.
<li>Section \ref formulas shows how to insert formulas in the documentation.
<li>Section \ref diagrams describes the diagrams and graphs that doxygen can generate.
......
/*! \page lists Lists
Doxygen has a number of ways to create lists of items.
<b>Using dashes</b>
By putting a number of column-aligned minus signs at the start of a
line, a bullet list will automatically be generated.
Numbered lists can also be generated by using a minus followed by a hash.
Nesting of lists is allowed.<p>
Here is an example:
\verbatim
/*!
* A list of events:
* - mouse events
* -# mouse move event
* -# mouse click event\n
* More info about the click event.
* -# mouse double click event
* - keyboard events
* -# key down event
* -# key up event
*
* More text here.
*/
\endverbatim
The result will be:
A list of events:
- mouse events
-# mouse move event
-# mouse click event\n
More info about the click event.
-# mouse double click event
- keyboard events
-# key down event
-# key up event
More text here.
If you use tabs within lists, please make sure that \ref cfg_tab_size "TAB_SIZE" in the
configuration file is set to the correct tab size.
<b>Using HTML commands</b>
If you like you can also use HTML commands inside the documentation
blocks. Using these commands has the advantage that it is more natural
for list items that consists of multiple paragraphs.
Here is the above example with HTML commands:
\verbatim
/*!
* A list of events:
* <ul>
* <li> mouse events
* <ol>
* <li>mouse move event
* <li>mouse click event\n
* More info about the click event.
* <li>mouse double click event
* </ol>
* <li> keyboard events
* <ol>
* <li>key down event
* <li>key up event
* </ol>
* </ul>
* More text here.
*/
\endverbatim
\note The the indent here is not important.
<b>Using \\arg or \@li</b>
For compatibility with the Troll Tech's internal documentation tool and
with KDoc, doxygen has two commands that can be used to create simple
not nested lists.
See \ref cmdarg "\arg" and \ref cmdli "\li" for more info.
\htmlonly
Go to the <a href="grouping.html">next</a> section or return to the
<a href="index.html">index</a>.
\endhtmlonly
*/
......@@ -197,43 +197,6 @@ During parsing the following steps take place:
See section \ref htmlcmds for an overview of all supported HTML tags.
</ul>
By putting a number of column-aligned minus signs at the start of a
line, a bullet list will automatically be generated.
Numbered lists can also be generated by using a minus followed by a hash.
Nesting of lists is allowed.<p>
Here is an example:
\verbatim
/*!
* A list of events:
* - mouse events
* -# mouse move event
* -# mouse click event\n
* More info about the click event.
* -# mouse double click event
* - keyboard events
* -# key down event
* -# key up event
*
* More text here.
*/
\endverbatim
The result will be:
A list of events:
- mouse events
-# mouse move event
-# mouse click event\n
More info about the click event.
-# mouse double click event
- keyboard events
-# key down event
-# key up event
More text here.
If you use tabs within lists, please make sure that \ref cfg_tab_size "TAB_SIZE" in the
configuration file is set to the correct tab size.
\htmlonly
Go to the <a href="docblocks.html">next</a> section or return to the
<a href="index.html">index</a>.
......@@ -241,4 +204,3 @@ Go to the <a href="docblocks.html">next</a> section or return to the
*/
Name: doxygen
Version: 1.2.0-20000806
Version: 1.2.1
Summary: documentation system for C, C++ and IDL
Release: 1
Source0: doxygen-%{version}.src.tar.gz
......
......@@ -1635,6 +1635,7 @@ void ClassDef::determineImplUsageRelation()
}
QCString templSpec;
if (te>ts) templSpec = type.mid(ts,te-ts);
// TODO: also check using Nx::Cx cases here!
ClassDef *cd=getResolvedClass(name()+"::"+type.mid(i,l));
if (cd==0) cd=getResolvedClass(type.mid(i,l)); // TODO: also try inbetween scopes!
//printf("Search for class %s result=%p\n",type.mid(i,l).data(),cd);
......
......@@ -298,6 +298,7 @@ static void addVariable()
g_codeVarList.append(new CodeVarDef(g_cvd));
}
}
//printf("g_codeVarList.count()=%d\n",g_codeVarList.count());
}
}
......@@ -328,6 +329,7 @@ static void addParameter()
g_codeParmList.append(new CodeVarDef(g_cvd));
}
}
//printf("g_codeParmList.count()=%d\n",g_codeParmList.count());
}
}
......@@ -747,7 +749,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
<SkipCPP>. {
g_code->codify(yytext);
}
<SkipCPP>\\\n {
<SkipCPP>\\[\r]?\n {
codifyLines(yytext);
}
<SkipCPP>\n/.*\n {
......@@ -817,6 +819,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
CodeClassDef *cd=new CodeClassDef(g_ccd);
g_codeClassList.append(cd);
g_codeClassDict.insert(cd->name,cd);
//printf("g_codeClassList.count()=%d\n",g_codeClassList.count());
}
BEGIN( Body );
}
......@@ -960,7 +963,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
g_lastStringContext=YY_START;
BEGIN( SkipString );
}
<SkipString>[^\"\\\n]* {
<SkipString>[^\"\\\r\n]* {
g_code->codify(yytext);
}
<SkipString>"//"|"/*" {
......@@ -1448,8 +1451,8 @@ void parseCode(OutputList &ol,const char *className,const QCString &s,
bool exBlock, const char *exName,FileDef *fd,
int startLine,int endLine,bool inlineFragment)
{
g_code = new OutputList(&ol);
if (s.isEmpty()) return;
g_code = new OutputList(&ol);
g_inputString = s;
g_inputPosition = 0;
g_currentFontClass = 0;
......
/* This file was generated by configgen on Sat Aug 5 20:49:38 2000
/* This file was generated by configgen on Sat Aug 12 16:16:35 2000
* from config_templ.h
*
* DO NOT EDIT!
......@@ -41,7 +41,6 @@ struct Config
static QCString projectNumber; // the number of the project
static QCString outputDir; // the global output directory
static QCString outputLanguage; // the output language
static bool noIndexFlag; // generate condensed index flag
static bool extractAllFlag; // generate docs for all classes flag
static bool extractPrivateFlag; // generate docs for private members flag
static bool extractStaticFlag; // generate docs for static members flag
......@@ -92,6 +91,7 @@ struct Config
static QCString htmlStyleSheet; // user defined cascading style sheet
static bool htmlAlignMemberFlag; // align members in HTML using tables.
static bool htmlHelpFlag; // should html help files be generated?
static bool noIndexFlag; // generate condensed index flag
static bool generateLatex; // generate Latex output
static QCString latexOutputDir; // the directory to put the Latex files
static bool compactLatexFlag; // generate compact LaTeX documentation.
......
/* This file was generated by configgen on Sun Aug 6 16:28:57 2000
/* This file was generated by configgen on Sun Aug 13 14:05:26 2000
* from config_templ.l
*
* DO NOT EDIT!
......@@ -78,7 +78,6 @@ QCString Config::projectName;
QCString Config::projectNumber;
QCString Config::outputDir;
QCString Config::outputLanguage = "English";
bool Config::noIndexFlag = FALSE;
bool Config::extractAllFlag = FALSE;
bool Config::extractPrivateFlag = FALSE;
bool Config::extractStaticFlag = FALSE;
......@@ -129,6 +128,7 @@ QCString Config::footerFile;
QCString Config::htmlStyleSheet;
bool Config::htmlAlignMemberFlag = TRUE;
bool Config::htmlHelpFlag = FALSE;
bool Config::noIndexFlag = FALSE;
bool Config::generateLatex = TRUE;
QCString Config::latexOutputDir = "latex";
bool Config::compactLatexFlag = FALSE;
......@@ -332,7 +332,6 @@ static void readIncludeFile(const char *incName)
<Start>"PROJECT_NUMBER"[ \t]*"=" { BEGIN(GetString); s=&Config::projectNumber; s->resize(0); }
<Start>"OUTPUT_DIRECTORY"[ \t]*"=" { BEGIN(GetString); s=&Config::outputDir; s->resize(0); }
<Start>"OUTPUT_LANGUAGE"[ \t]*"=" { BEGIN(GetString); s=&Config::outputLanguage; s->resize(0); }
<Start>"DISABLE_INDEX"[ \t]*"=" { BEGIN(GetBool); b=&Config::noIndexFlag; }
<Start>"EXTRACT_ALL"[ \t]*"=" { BEGIN(GetBool); b=&Config::extractAllFlag; }
<Start>"EXTRACT_PRIVATE"[ \t]*"=" { BEGIN(GetBool); b=&Config::extractPrivateFlag; }
<Start>"EXTRACT_STATIC"[ \t]*"=" { BEGIN(GetBool); b=&Config::extractStaticFlag; }
......@@ -393,6 +392,7 @@ static void readIncludeFile(const char *incName)
<Start>"HTML_STYLESHEET"[ \t]*"=" { BEGIN(GetString); s=&Config::htmlStyleSheet; s->resize(0); }
<Start>"HTML_ALIGN_MEMBERS"[ \t]*"=" { BEGIN(GetBool); b=&Config::htmlAlignMemberFlag; }
<Start>"GENERATE_HTMLHELP"[ \t]*"=" { BEGIN(GetBool); b=&Config::htmlHelpFlag; }
<Start>"DISABLE_INDEX"[ \t]*"=" { BEGIN(GetBool); b=&Config::noIndexFlag; }
<Start>"GENERATE_LATEX"[ \t]*"=" { BEGIN(GetBool); b=&Config::generateLatex; }
<Start>"LATEX_OUTPUT"[ \t]*"=" { BEGIN(GetString); s=&Config::latexOutputDir; s->resize(0); }
<Start>"COMPACT_LATEX"[ \t]*"=" { BEGIN(GetBool); b=&Config::compactLatexFlag; }
......@@ -465,7 +465,7 @@ static void readIncludeFile(const char *incName)
else
{
ConfigFileState *fs=includeStack.pop();
pclose(fs->filePtr);
fclose(fs->filePtr);
YY_BUFFER_STATE oldBuf = YY_CURRENT_BUFFER;
yy_switch_to_buffer( fs->oldState );
yy_delete_buffer( oldBuf );
......@@ -554,7 +554,6 @@ void dumpConfig()
printf("projectNumber=`%s'\n",Config::projectNumber.data());
printf("outputDir=`%s'\n",Config::outputDir.data());
printf("outputLanguage=`%s'\n",Config::outputLanguage.data());
printf("noIndexFlag=`%d'\n",Config::noIndexFlag);
printf("extractAllFlag=`%d'\n",Config::extractAllFlag);
printf("extractPrivateFlag=`%d'\n",Config::extractPrivateFlag);
printf("extractStaticFlag=`%d'\n",Config::extractStaticFlag);
......@@ -679,6 +678,7 @@ void dumpConfig()
printf("htmlStyleSheet=`%s'\n",Config::htmlStyleSheet.data());
printf("htmlAlignMemberFlag=`%d'\n",Config::htmlAlignMemberFlag);
printf("htmlHelpFlag=`%d'\n",Config::htmlHelpFlag);
printf("noIndexFlag=`%d'\n",Config::noIndexFlag);
printf("# configuration options related to the LaTeX output\n");
printf("generateLatex=`%d'\n",Config::generateLatex);
printf("latexOutputDir=`%s'\n",Config::latexOutputDir.data());
......@@ -790,7 +790,6 @@ void Config::init()
Config::projectNumber.resize(0);
Config::outputDir.resize(0);
Config::outputLanguage = "English";
Config::noIndexFlag = FALSE;
Config::extractAllFlag = FALSE;
Config::extractPrivateFlag = FALSE;
Config::extractStaticFlag = FALSE;
......@@ -841,6 +840,7 @@ void Config::init()
Config::htmlStyleSheet.resize(0);
Config::htmlAlignMemberFlag = TRUE;
Config::htmlHelpFlag = FALSE;
Config::noIndexFlag = FALSE;
Config::generateLatex = TRUE;
Config::latexOutputDir = "latex";
Config::compactLatexFlag = FALSE;
......@@ -1006,17 +1006,6 @@ void writeTemplateConfig(QFile *f,bool sl)
writeStringValue(t,Config::outputLanguage);
t << "\n";
if (!sl)
{
t << "\n";
t << "# The DISABLE_INDEX tag can be used to turn on/off the condensed index at \n";
t << "# top of each HTML page. The value NO (the default) enables the index and \n";
t << "# the value YES disables it. \n";
t << "\n";
}
t << "DISABLE_INDEX = ";
writeBoolValue(t,Config::noIndexFlag);
t << "\n";
if (!sl)
{
t << "\n";
t << "# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in \n";
......@@ -1608,6 +1597,17 @@ void writeTemplateConfig(QFile *f,bool sl)
writeBoolValue(t,Config::htmlHelpFlag);
t << "\n";
if (!sl)
{
t << "\n";
t << "# The DISABLE_INDEX tag can be used to turn on/off the condensed index at \n";
t << "# top of each HTML page. The value NO (the default) enables the index and \n";
t << "# the value YES disables it. \n";
t << "\n";
}
t << "DISABLE_INDEX = ";
writeBoolValue(t,Config::noIndexFlag);
t << "\n";
if (!sl)
{
t << "\n";
}
......
......@@ -101,7 +101,11 @@ class Definition
void writeSourceRefs(OutputList &ol,const char *scopeName);
void addSourceReference(MemberDef *d);
void setRefItems(int todoId,int testId) { m_todoId=todoId; m_testId=testId; }
void setRefItems(int todoId,int testId)
{
if (todoId!=0) m_todoId=todoId;
if (testId!=0) m_testId=testId;
}
int todoId() const { return m_todoId; }
int testId() const { return m_testId; }
......
......@@ -881,7 +881,7 @@ DOCPARAM ([a-z_A-Z0-9:\<\>\=\.\-]+)|("\"".*"\"")
outDoc->writeString(c);
}
<DocScan>"\\postheader"/{BN}
<DocScan>"\\functionindex"/{BN} { writeMemberList(*outDoc); }
<DocScan>"\\functionindex"/{BN} { writeMemberList(*outDoc,FALSE); }
<DocScan>"\\classhierarchy"/{BN} { writeClassHierarchy(*outDoc); }
<DocScan>"\\annotatedclasslist"/{BN} { writeAnnotatedClassList(*outDoc); }
<DocScan>"\\headerfilelist"/{BN} { /*TODO: fix this writeHeaderFileList(*outDoc); */ }
......@@ -1636,7 +1636,7 @@ DOCPARAM ([a-z_A-Z0-9:\<\>\=\.\-]+)|("\"".*"\"")
BEGIN( DocCodeBlock );
}
<DocScan>{CMD}"endcode"/[^a-z_A-Z0-9] {
warn(yyFileName,yyLineNr,"Warning: \\endcode without <PRE> or \\code "
warn(yyFileName,yyLineNr,"Warning: \\endcode without \\code "
"in the documentation.");
}
......@@ -1675,12 +1675,6 @@ DOCPARAM ([a-z_A-Z0-9:\<\>\=\.\-]+)|("\"".*"\"")
outDoc->endCodeFragment();
BEGIN( DocScan );
}
<DocCodeBlock>"</"{PRE}{ATTR}">" {
parseCode(*outDoc,className,codeBlock,exampleDoc,exampleName);
//printf("Code block\n-------------\n%s\n--------------\n",codeBlock.data());
outDoc->endCodeFragment();
BEGIN( DocScan );
}
<DocScan>{CMD}("e"|"em"|"a"){BN}+ { BEGIN( DocEmphasis ); }
<DocScan>{CMD}"b"{BN}+ { BEGIN( DocBold ); }
<DocScan>{CMD}("c"|"p"){BN}+ { BEGIN( DocCode ); }
......@@ -1781,17 +1775,8 @@ DOCPARAM ([a-z_A-Z0-9:\<\>\=\.\-]+)|("\"".*"\"")
/*restoreOutputListState();*/
outDoc->popGeneratorState();
}
<DocScan>"<"{PRE}{ATTR}">" {
outDoc->startCodeFragment();
codeBlock.resize(0);
BEGIN( DocCodeBlock );
}
<DocScan>"</"{PRE}{ATTR}">" {
warn(yyFileName,yyLineNr,
"Warning: </PRE> without <PRE> or \\code"
"in the documentation."
);
}
<DocScan>"<"{PRE}{ATTR}">" { outDoc->startPreFragment(); }
<DocScan>"</"{PRE}{ATTR}">" { outDoc->endPreFragment(); }
<DocScan>"<"{SUB}{ATTR}">" { outDoc->startSubscript(); }
<DocScan>"</"{SUB}{ATTR}">" { outDoc->endSubscript(); }
<DocScan>"<"{SUP}{ATTR}">" { outDoc->startSuperscript(); }
......@@ -2112,6 +2097,7 @@ void parseDocument(OutputList &ol,const QCString &docString)
includeFileOffset=0;
includeFileLength=0;
currentListIndent.clear();
listIndentStack.clear();
if (!docString) return;
linkRef = "";
linkText = "";
......
......@@ -55,6 +55,7 @@
#include "rtfgen.h"
#include "xml.h"
#include "reflist.h"
#include "page.h"
#if defined(_MSC_VER) || defined(__BORLANDC__)
#define popen _popen
......@@ -64,8 +65,8 @@
// lists
ClassList classList; // all documented classes
NamespaceList namespaceList; // all namespaces
PageList exampleList; // all example files
PageList pageList; // all related documentation pages
//PageList *exampleList = new PageList; // all example files
//PageList *pageList = new PageList; // all related documentation pages
MemberNameList memberNameList; // class member + related functions
MemberNameList functionNameList; // all unrelated functions
FileNameList inputNameList; // all input files
......@@ -74,13 +75,13 @@ GroupList groupList; // all groups
FormulaList formulaList; // all formulas
// dictionaries
PageDict pageDict(1009); // all doc pages
PageDict exampleDict(1009); // all examples
PageSDict *pageSDict = new PageSDict(1009); // all doc pages
PageSDict *exampleSDict = new PageSDict(1009); // all examples
ClassDict classDict(1009); // all documented classes
NamespaceDict namespaceDict(257); // all documented namespaces
MemberNameDict memberNameDict(10007); // all class member names
MemberNameDict functionNameDict(10007); // all functions
StringDict substituteDict(1009); // class name substitutes
//StringDict substituteDict(1009); // class name substitutes
SectionDict sectionDict(257); // all page sections
StringDict excludeNameDict(1009); // sections
FileNameDict *inputNameDict; // sections
......@@ -106,21 +107,19 @@ void clearAll()
{
classList.clear();
namespaceList.clear();
exampleList.clear();
pageList.clear();
pageSDict->clear();
exampleSDict->clear();
memberNameList.clear();
functionNameList.clear();
inputNameList.clear();
inputFiles.clear();
groupList.clear();
formulaList.clear();
pageDict.clear();
exampleDict.clear();
classDict.clear();
namespaceDict.clear();
memberNameDict.clear();
functionNameDict.clear();
substituteDict.clear();
//substituteDict.clear();
sectionDict.clear();
inputNameDict->clear();
excludeNameDict.clear();
......@@ -180,7 +179,7 @@ static void addRelatedPage(const char *name,const QCString &ptitle,
)
{
PageInfo *pi=0;
if ((pi=pageDict[name]))
if ((pi=pageSDict->find(name)))
{
//warn("Warning: Page %s was already documented. Ignoring documentation "
// "at line %d of %s\n",root->name.data(),root->startLine,
......@@ -208,8 +207,8 @@ static void addRelatedPage(const char *name,const QCString &ptitle,
pageName=pi->name.lower();
setFileNameForSections(anchors,pageName);
pageList.append(pi);
pageDict.insert(baseName,pi);
pageSDict->append(baseName,pi);
if (!pi->title.isEmpty())
{
//outputList->writeTitle(pi->name,pi->title);
......@@ -2065,7 +2064,7 @@ static bool findBaseClassRelation(Entry *root,ClassDef *cd,
// look in the outer scope for a match
{
Debug::print(
Debug::Classes,0," baseClass %s of %s found (%s and %s)\n",
Debug::Classes,0," class relation %s inherited by %s found (%s and %s)\n",
baseClassName.data(),
root->name.data(),
(bi->prot==Private)?"private":((bi->prot==Protected)?"protected":"public"),
......@@ -2126,9 +2125,27 @@ static bool findBaseClassRelation(Entry *root,ClassDef *cd,
root->name!=fName;
}
}
if (fd && !found) // and in the global namespace
{
ClassList *cl = fd->getUsedClasses();
if (cl)
{
ClassListIterator cli(*cl);
ClassDef *ucd;
for (cli.toFirst(); (ucd=cli.current()) && !found; ++cli)
{
if (rightScopeMatch(ucd->name(),bi->name))
{
baseClass = ucd;
found = TRUE;
}
}
}
}
}
if (!found && nd) // class is inside a namespace
{
//printf(" class %s inside namespace %s\n",cd->name().data(),nd->name().data());
NamespaceList *nl = nd->getUsedNamespaces();
QCString fName = nd->name()+"::"+baseClassName;
found = (baseClass=getResolvedClass(fName))!=0 && root->name!=fName;
......@@ -2143,6 +2160,41 @@ static bool findBaseClassRelation(Entry *root,ClassDef *cd,
root->name!=fName;
}
}
if (!found) // also check imported classes within this namespace
{
ClassList *cl = nd->getUsedClasses();
if (cl)
{
ClassListIterator cli(*cl);
ClassDef *ucd;
for (cli.toFirst(); (ucd=cli.current()) && !found; ++cli)
{
if (rightScopeMatch(ucd->name(),bi->name))
{
baseClass = ucd;
found = TRUE;
}
}
}
}
// TODO: check any inbetween namespaces as well!
if (fd && !found) // and in the global namespace
{
ClassList *cl = fd->getUsedClasses();
if (cl)
{
ClassListIterator cli(*cl);
ClassDef *ucd;
for (cli.toFirst(); (ucd=cli.current()) && !found; ++cli)
{
if (rightScopeMatch(ucd->name(),bi->name))
{
baseClass = ucd;
found = TRUE;
}
}
}
}
}
}
if (found)
......@@ -2334,11 +2386,11 @@ static void addTodoTestReferences()
addRefItem(gd->todoId(),gd->testId(),"group",gd->getOutputFileBase(),gd->name());
gd=groupList.next();
}
PageInfo *pi=pageList.first();
while (pi)
PageSDictIterator pdi(*pageSDict);
PageInfo *pi=0;
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
addRefItem(pi->todoId,pi->testId,"page",pi->name,pi->title);
pi=pageList.next();
}
MemberNameListIterator mnli(memberNameList);
MemberName *mn=0;
......@@ -4190,7 +4242,7 @@ static void generateClassDocs()
msg("Generating member index...\n");
writeMemberIndex(*outputList);
if (exampleList.count()>0)
if (exampleSDict->count()>0)
{
msg("Generating example index...\n");
}
......@@ -4544,8 +4596,9 @@ static void resolveUserReferences()
static void generatePageDocs()
{
PageInfo *pi=pageList.first();
while (pi)
PageSDictIterator pdi(*pageSDict);
PageInfo *pi=0;
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
msg("Generating docs for page %s...\n",pi->name.data());
outputList->disable(OutputGenerator::Man);
......@@ -4567,7 +4620,6 @@ static void generatePageDocs()
outputList->endTextBlock();
endFile(*outputList);
outputList->enable(OutputGenerator::Man);
pi=pageList.next();
}
}
......@@ -4580,7 +4632,7 @@ static void buildExampleList(Entry *root)
{
if (!root->name.isEmpty())
{
if (exampleDict[root->name])
if (exampleSDict->find(root->name))
{
warn(root->fileName,root->startLine,
"Warning: Example %s was already documented. Ignoring "
......@@ -4595,8 +4647,7 @@ static void buildExampleList(Entry *root)
setFileNameForSections(root->anchors,
convertFileName(pi->name)+"-example"
);
exampleList.inSort(pi);
exampleDict.insert(root->name,pi);
exampleSDict->inSort(root->name,pi);
}
}
}
......@@ -4621,8 +4672,9 @@ static void buildExampleList(Entry *root)
static void generateExampleDocs()
{
outputList->disable(OutputGenerator::Man);
PageInfo *pi=exampleList.first();
while (pi)
PageSDictIterator pdi(*exampleSDict);
PageInfo *pi=0;
for (pdi.toFirst();(pi=pdi.current());++pdi)
{
msg("Generating docs for example %s...\n",pi->name.data());
QCString n=convertFileName(pi->name)+"-example";
......@@ -4632,7 +4684,6 @@ static void generateExampleDocs()
endTitle(*outputList,n,0);
parseExample(*outputList,pi->doc+"\n\\include "+pi->name,pi->name);
endFile(*outputList);
pi=exampleList.next();
}
outputList->enable(OutputGenerator::Man);
}
......
......@@ -33,34 +33,6 @@
#include "section.h"
#include "membergroup.h"
struct PageInfo
{
PageInfo(const char *f, int l,const char *n,const char *d,const char *t) :
defFileName(f), defLine(l), name(n), doc(d), title(t),
todoId(0), testId(0) {}
// where the page definition was found
QCString defFileName;
int defLine;
// contents of the page
QCString name;
QCString doc;
QCString title;
// ids
int todoId;
int testId;
};
class PageList : public QList<PageInfo>
{
int compareItems(GCI i1,GCI i2)
{
return stricmp(((PageInfo *)i1)->name,((PageInfo *)i2)->name);
}
};
class BufStr : public QCString
{
public:
......@@ -87,35 +59,37 @@ class BufStr : public QCString
const int spareRoom; // 10Kb extra room to avoid frequent resizing
};
class PageSList;
class PageSDict;
class PageInfo;
extern PageSDict *exampleSDict;
extern PageSDict *pageSDict;
extern PageInfo *mainPage;
extern FileNameDict *includeNameDict;
extern FileNameDict *exampleNameDict;
extern FileNameDict *inputNameDict;
extern FileNameDict *imageNameDict;
typedef QList<QCString> StringList;
typedef QDict<FileDef> FileDict;
typedef QDict<QCString> StringDict;
typedef QDict<PageInfo> PageDict;
typedef QDict<GroupDef> GroupDict;
extern const char * getOverloadDocs();
extern ClassList classList;
extern ClassDict classDict;
extern QStrList tagfileList;
extern PageList exampleList;
extern PageDict exampleDict;
extern PageList pageList;
extern PageDict pageDict;
extern MemberNameList memberNameList;
extern MemberNameList functionNameList;
extern MemberNameDict memberNameDict;
extern MemberNameDict functionNameDict;
extern StringDict substituteDict;
//extern StringDict substituteDict;
extern FileList fileList;
extern FileDict fileDict;
extern ClassDef unrelatedClass;
extern QTextStream tagFile;
extern SectionDict sectionDict;
extern FileNameList inputNameList;
extern FileNameDict *includeNameDict;
extern FileNameDict *exampleNameDict;
extern FileNameDict *inputNameDict;
extern FileNameDict *imageNameDict;
extern StringDict typedefDict;
extern GroupList groupList;
extern GroupDict groupDict;
......@@ -124,7 +98,6 @@ extern NamespaceDict namespaceDict;
extern FormulaList formulaList;
extern FormulaDict formulaDict;
extern FormulaDict formulaNameDict;
extern PageInfo *mainPage;
extern StringDict tagDestinationDict;
extern QIntDict<QCString> memberHeaderDict; // dictionary of the member groups heading
extern QIntDict<QCString> memberDocDict; // dictionary of the member groups heading
......@@ -143,4 +116,6 @@ extern int documentedNamespaceMembers;
extern int documentedIncludeFiles;
extern QCString spaces;
extern const char * getOverloadDocs();
#endif
......@@ -26,7 +26,7 @@ HEADERS = doxygen.h scanner.h doc.h classdef.h classlist.h memberdef.h \
translator_nl.h translator_se.h translator_cz.h translator_fr.h \
translator_it.h formula.h debug.h membergroup.h htmlhelp.h \
translator_ru.h translator_pl.h dot.h rtfgen.h xml.h xml_dtd.h \
reflist.h
reflist.h page.h sortdict.h
SOURCES = doxygen.cpp scanner.cpp doc.cpp classdef.cpp classlist.cpp \
memberdef.cpp membername.cpp index.cpp memberlist.cpp \
entry.cpp logos.cpp instdox.cpp message.cpp code.cpp \
......
......@@ -575,7 +575,7 @@ void HtmlGenerator::endClassDiagram(ClassDiagram &d,
t << ":\n<p><center><img src=\""
<< fileName << ".gif\" usemap=\"#" << name << "_map\""
<< " border=\"0\"></center>" << endl
<< "<map name=\"" << name << "_map\"><p>" << endl;
<< "<map name=\"" << name << "_map\">" << endl;
d.writeImageMap(t,dir,fileName);
}
......
......@@ -124,6 +124,8 @@ class HtmlGenerator : public OutputGenerator
// to prevent an extra
// blank line
// (with netscape)
void startPreFragment() { t << "<pre>"; }
void endPreFragment() { t << "</pre>"; }
void startCodeLine() { col=0; }
void endCodeLine() { codify("\n"); }
void writeBoldString(const char *text)
......
This diff is collapsed.
......@@ -52,7 +52,7 @@ void writeSourceIndex(OutputList &ol);
void writeAnnotatedIndex(OutputList &ol);
void writeAnnotatedClassList(OutputList &ol);
void writeMemberIndex(OutputList &ol);
void writeMemberList(OutputList &ol);
void writeMemberList(OutputList &ol,bool useSections);
void writeHeaderIndex(OutputList &ol);
void writeHeaderFileList(OutputList &ol);
void writeExampleIndex(OutputList &ol);
......
......@@ -28,6 +28,7 @@
#include "language.h"
#include "version.h"
#include "dot.h"
#include "page.h"
static QCString filterTitle(const char *s)
{
......@@ -204,6 +205,7 @@ static void writeDefaultHeaderPart1(QTextStream &t)
"\\usepackage{fancyhdr}\n"
"\\usepackage{graphicx}\n"
"\\usepackage{float}\n"
"\\usepackage{alltt}\n"
"\\usepackage{doxygen}\n";
if (Config::pdfHyperFlag)
{
......@@ -703,24 +705,24 @@ void LatexGenerator::endIndexSection(IndexSections is)
case isExampleDocumentation:
{
t << "}\n";
PageInfo *pi=exampleList.first();
PageSDictIterator pdi(*exampleSDict);
PageInfo *pi=pdi.toFirst();
if (pi)
{
t << "\\input{" << convertFileName(pi->name) << "-example}\n";
pi=exampleList.next();
}
while (pi)
for (++pdi;(pi=pdi.current());++pdi)
{
if (Config::compactLatexFlag) t << "\\input" ; else t << "\\include";
t << "{" << convertFileName(pi->name) << "-example}\n";
pi=exampleList.next();
}
}
break;
case isPageDocumentation:
{
t << "}\n";
PageInfo *pi=pageList.first();
PageSDictIterator pdi(*pageSDict);
PageInfo *pi=pdi.toFirst();
if (pi)
{
QCString pageName;
......@@ -729,9 +731,8 @@ void LatexGenerator::endIndexSection(IndexSections is)
else
pageName=pi->name.lower();
t << "\\input{" << pageName << "}\n";
pi=pageList.next();
}
while (pi)
for (++pdi;(pi=pdi.current());++pdi)
{
if (Config::compactLatexFlag) t << "\\input" ; else t << "\\include";
QCString pageName;
......@@ -740,7 +741,6 @@ void LatexGenerator::endIndexSection(IndexSections is)
else
pageName=pi->name.lower();
t << "{" << pageName << "}\n";
pi=pageList.next();
}
}
break;
......@@ -1071,14 +1071,14 @@ void LatexGenerator::addToIndex(const char *s1,const char *s2)
void LatexGenerator::writeSection(const char *lab,const char *title,bool sub)
{
t << "\\";
if (sub) t << "subsection{"; else t << "section{";
docify(title);
t << "}\\label{" << lab << "}" << endl;
if (Config::pdfHyperFlag)
{
t << "\\hypertarget{" << lab << "}{}";
}
t << "\\";
if (sub) t << "subsection{"; else t << "section{";
docify(title);
t << "}\\label{" << lab << "}" << endl;
}
void LatexGenerator::writeSectionRef(const char *,const char *lab,
......
......@@ -110,6 +110,8 @@ class LatexGenerator : public OutputGenerator
void writeAnchor(const char *fileName,const char *name);
void startCodeFragment() { t << "\\small\\begin{verbatim}"; }
void endCodeFragment() { t << "\\end{verbatim}\\normalsize " << endl; }
void startPreFragment() { t << "\\small\\begin{alltt}"; }
void endPreFragment() { t << "\\end{alltt}\\normalsize " << endl; }
void startCodeLine() { col=0; }
void endCodeLine() { t << endl; }
void writeBoldString(const char *text)
......
......@@ -106,6 +106,8 @@ class ManGenerator : public OutputGenerator
void writeAnchor(const char *,const char *) {}
void startCodeFragment();
void endCodeFragment();
void startPreFragment() { startCodeFragment(); }
void endPreFragment() { endCodeFragment(); }
void startCodeLine() {}
void endCodeLine() { t << endl; col=0; }
void writeBoldString(const char *text)
......
......@@ -234,7 +234,7 @@ MemberDef::MemberDef(const char *df,int dl,
const char *t,const char *na,const char *a,const char *e,
Protection p,Specifier v,bool s,bool r,MemberType mt,
const ArgumentList *tal,const ArgumentList *al
) : Definition(df,dl,substituteClassNames(na))
) : Definition(df,dl,na)
{
//printf("++++++ MemberDef(%s file=%s,line=%d) ++++++ \n",na,df,dl);
classDef=0;
......@@ -255,8 +255,8 @@ MemberDef::MemberDef(const char *df,int dl,
scopeTAL=0;
membTAL=0;
initLines=0;
type=substituteClassNames(t);
args=substituteClassNames(a);
type=t;
args=a;
if (type.isEmpty()) decl=name()+args; else decl=type+" "+name()+args;
declLine=0;
memberGroup=0;
......@@ -1025,6 +1025,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
ol.startBold();
parseText(ol,theTranslator->trInitialValue());
ol.endBold();
initParseCodeContext();
ol.startCodeFragment();
parseCode(ol,scopeName,init,FALSE,0);
ol.endCodeFragment();
......@@ -1400,7 +1401,7 @@ void MemberDef::generateXML(QTextStream &t,Definition *def)
scopeName=getNamespaceDef()->name();
t << " <";
enum { define_t,variable_t,typedef_t,enum_t,function_t } xmlType;
enum { define_t,variable_t,typedef_t,enum_t,function_t } xmlType = function_t;
switch (mtype)
{
case Define: t << "definedef"; xmlType=define_t; break;
......
......@@ -113,6 +113,8 @@ class OutputGenerator
virtual void writeAnchor(const char *fileName,const char *name) = 0;
virtual void startCodeFragment() = 0;
virtual void endCodeFragment() = 0;
virtual void startPreFragment() = 0;
virtual void endPreFragment() = 0;
virtual void startCodeLine() = 0;
virtual void endCodeLine() = 0;
virtual void writeBoldString(const char *text) = 0;
......
......@@ -260,7 +260,7 @@ FORALL1(int a1,a1)
FORALL1(DotClassGraph &a1,a1)
FORALL1(DotInclDepGraph &a1,a1)
FORALL1(DotGfxHierarchyTable &a1,a1)
#if defined(HAS_BOOL_TYPE)
#if defined(HAS_BOOL_TYPE) || defined(Q_HAS_BOOL_TYPE)
FORALL1(bool a1,a1)
FORALL2(bool a1,int a2,a1,a2)
FORALL2(bool a1,bool a2,a1,a2)
......
......@@ -186,6 +186,10 @@ class OutputList
{ forall(&OutputGenerator::startCodeFragment); }
void endCodeFragment()
{ forall(&OutputGenerator::endCodeFragment); }
void startPreFragment()
{ forall(&OutputGenerator::startPreFragment); }
void endPreFragment()
{ forall(&OutputGenerator::endPreFragment); }
void startCodeLine()
{ forall(&OutputGenerator::startCodeLine); }
void endCodeLine()
......@@ -395,7 +399,7 @@ class OutputList
FORALLPROTO1(DotClassGraph &);
FORALLPROTO1(DotInclDepGraph &);
FORALLPROTO1(DotGfxHierarchyTable &);
#if defined(HAS_BOOL_TYPE)
#if defined(HAS_BOOL_TYPE) || defined(Q_HAS_BOOL_TYPE)
FORALLPROTO1(bool);
FORALLPROTO2(bool,int);
FORALLPROTO2(bool,bool);
......
/******************************************************************************
*
*
*
* Copyright (C) 1997-2000 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
* for any purpose. It is provided "as is" without express or implied warranty.
* See the GNU General Public License for more details.
*
* Documents produced by Doxygen are derivative works derived from the
* input used in their production; they are not affected by this license.
*
*/
#include "sortdict.h"
class PageInfo
{
public:
PageInfo(const char *f, int l,const char *n,const char *d,const char *t) :
defFileName(f), defLine(l), name(n),
doc(d), title(t), todoId(0), testId(0) {}
// where the page definition was found
QCString defFileName;
int defLine;
// contents of the page
QCString name;
QCString doc;
QCString title;
// ids
int todoId;
int testId;
};
class PageSDict : public SDict<PageInfo>
{
public:
PageSDict(int size) : SDict<PageInfo>(size) {}
~PageSDict() {}
int compareItems(GCI i1,GCI i2)
{
return stricmp(((PageInfo *)i1)->name,((PageInfo *)i2)->name);
}
};
class PageSDictIterator : public SDict<PageInfo>::Iterator
{
public:
PageSDictIterator(const PageSDict &d) : SDict<PageInfo>::Iterator(d) {}
~PageSDictIterator() {}
};
......@@ -502,7 +502,7 @@ static bool replaceFunctionMacro(const QCString &expr,QCString *rest,int pos,int
}
else
{
resExpr+=substArg;
resExpr+=" "+substArg+" ";
}
}
}
......@@ -592,7 +592,7 @@ static void expandExpression(QCString &expr,QCString *rest,int pos)
{
// substitute the definition of the macro
//printf("macro `%s'->`%s'\n",macroName.data(),def->definition.data());
expMacro=def->definition.stripWhiteSpace();
expMacro=" "+def->definition.stripWhiteSpace()+" ";
replaced=TRUE;
len=l;
//printf("simple macro expansion=`%s'->`%s'\n",macroName.data(),expMacro.data());
......
......@@ -32,6 +32,7 @@
#include "language.h"
#include "dot.h"
#include "version.h"
#include "page.h"
//#define DBG_RTF(x) x;
#define DBG_RTF(x)
......@@ -935,31 +936,31 @@ void RTFGenerator::endIndexSection(IndexSections is)
case isExampleDocumentation:
{
//t << "}\n";
PageInfo *pi=exampleList.first();
t << "{\\tc \\v " << theTranslator->trExampleDocumentation() << "}"<< endl;
PageSDictIterator pdi(*exampleSDict);
PageInfo *pi=pdi.toFirst();
if (pi)
{
t << "\\par " << Rtf_Style["Reset"] << endl;
t << "{\\field\\fldedit{\\*\\fldinst INCLUDETEXT \"";
t << convertFileName(pi->name);
t << "-example.rtf\" \\\\*MERGEFORMAT}{\\fldrslt includedstuff}}\n";
pi=exampleList.next();
}
while (pi)
for (++pdi;(pi=pdi.current());++pdi)
{
t << "\\par " << Rtf_Style["Reset"] << endl;
beginRTFSection();
t << "{\\field\\fldedit{\\*\\fldinst INCLUDETEXT \"";
t << convertFileName(pi->name);
t << "-example.rtf\" \\\\*MERGEFORMAT}{\\fldrslt includedstuff}}\n";
pi=exampleList.next();
}
}
break;
case isPageDocumentation:
{
t << "{\\tc \\v " << theTranslator->trPageDocumentation() << "}"<< endl;
PageInfo *pi=pageList.first();
PageSDictIterator pdi(*pageSDict);
PageInfo *pi=pdi.toFirst();
if (pi)
{
QCString pageName;
......@@ -971,9 +972,8 @@ void RTFGenerator::endIndexSection(IndexSections is)
t << "{\\field\\fldedit{\\*\\fldinst INCLUDETEXT \"";
t << pageName;
t << ".rtf\" \\\\*MERGEFORMAT}{\\fldrslt includedstuff}}\n";
pi=pageList.next();
}
while (pi)
for (++pdi;(pi=pdi.current());++pdi)
{
QCString pageName;
if (Config::caseSensitiveNames)
......@@ -985,7 +985,6 @@ void RTFGenerator::endIndexSection(IndexSections is)
t << "{\\field\\fldedit{\\*\\fldinst INCLUDETEXT \"";
t << pageName;
t << ".rtf\" \\\\*MERGEFORMAT}{\\fldrslt includedstuff}}\n";
pi=pageList.next();
}
}
break;
......
......@@ -105,6 +105,8 @@ class RTFGenerator : public OutputGenerator
void writeAnchor(const char *fileName,const char *name);
void startCodeFragment();
void endCodeFragment();
void startPreFragment() { startCodeFragment(); }
void endPreFragment() { endCodeFragment(); }
void startCodeLine() { col=0; }
void endCodeLine() { lineBreak(); }
void writeBoldString(const char *text)
......
/******************************************************************************
*
*
*
*
* Copyright (C) 1997-2000 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
* for any purpose. It is provided "as is" without express or implied warranty.
* See the GNU General Public License for more details.
*
* Documents produced by Doxygen are derivative works derived from the
* input used in their production; they are not affected by this license.
*
*/
#ifndef _SORTDICT_H
#define _SORTDICT_H
#include "qtbc.h"
#include <qlist.h>
#include <qdict.h>
/*! Ordered dictionary of elements of type T.
* Internally uses a QList<T> and a QDict<T>.
*/
template<class T>
class SDict
{
private:
/*! internal wrapper class that redirects compareItems() to the
* dictionary
*/
class SList : public QList<T>
{
public:
SList(SDict<T> *owner) : m_owner(owner) {}
~SList() {}
int compareItems(GCI item1,GCI item2)
{
return m_owner->compareItems(item1,item2);
}
private:
SDict<T> *m_owner;
};
SList *m_list;
QDict<T> *m_dict;
public:
/*! Create an ordered dictionary.
* \param size The size of the dictionary. Should be a prime number for
* best distribution of elements.
*/
SDict(int size)
{
m_list = new SList(this);
m_dict = new QDict<T>(size);
}
/*! Destroys the dictionary */
virtual ~SDict()
{
delete m_list;
delete m_dict;
}
/*! Appends a compound to the dictionary. The element is owned by the
* dictionary.
* \param key The unique key to use to quicky find the item later on.
* \param d The compound to add.
* \sa find()
*/
void append(const char *key,const T *d)
{
m_list->append(d);
m_dict->insert(key,d);
}
/*! Inserts a compound into the dictionary in a sorted way.
* \param key The unique key to use to quicky find the item later on.
* \param d The compound to add.
* \sa find()
*/
void inSort(const char *key,const T *d)
{
m_list->inSort(d);
m_dict->insert(key,d);
}
/*! Indicates whether or not the dictionary owns its elements */
void setAutoDelete(bool val)
{
m_list->setAutoDelete(val);
}
/*! Looks up a compound given its key.
* \param key The key to identify this element.
* \return The requested compound or zero if it cannot be found.
* \sa append()
*/
T *find(const char *key)
{
return m_dict->find(key);
}
/*! Function that is used to compare two items when sorting.
* Overload this to properly sort items.
* \sa inSort()
*/
virtual int compareItems(GCI item1,GCI item2)
{
return item1!=item2;
}
/*! Clears the dictionary. Will delete items if setAutoDelete() was
* set to \c TRUE.
* \sa setAutoDelete
*/
void clear()
{
m_list->clear();
m_dict->clear();
}
/*! Returns the number of items stored in the dictionary
*/
int count()
{
return m_list->count();
}
class Iterator; // first forward declare
friend class Iterator; // then make it a friend
/*! Simple iterator for SDict. It iterates in the order in which the
* elements are stored.
*/
class Iterator
{
public:
/*! Create an iterator given the dictionary. */
Iterator(const SDict<T> &dict)
{
m_li = new QListIterator<T>(*dict.m_list);
}
/*! Destroys the dictionary */
virtual ~Iterator()
{
delete m_li;
}
/*! Set the iterator to the first element in the list.
* \return The first compound, or zero if the list was empty.
*/
T *toFirst() const
{
return m_li->toFirst();
}
/*! Returns the current compound */
T *current() const
{
return m_li->current();
}
/*! Moves the iterator to the next element.
* \return the new "current" element, or zero if the iterator was
* already pointing at the last element.
*/
T *operator++()
{
return m_li->operator++();
}
private:
QListIterator<T> *m_li;
};
};
#endif
......@@ -151,7 +151,7 @@ class TranslatorDutch : public Translator
QCString trModuleDocumentation()
{ return "Module Documentatie"; }
QCString trClassDocumentation()
{ return "Klasse Documentatie"; }
{ return "Klassen Documentatie"; }
QCString trFileDocumentation()
{ return "File Documentatie"; }
QCString trExampleDocumentation()
......
......@@ -37,6 +37,7 @@
#include "version.h"
#include "groupdef.h"
#include "xml.h"
#include "page.h"
#ifndef _WIN32
#include <unistd.h>
......@@ -797,14 +798,14 @@ void writeQuickLinks(OutputList &ol,bool compact,bool ext)
parseText(ol,theTranslator->trFileMembers());
ol.endQuickIndexItem();
}
if (pageList.count()>0)
if (pageSDict->count()>0)
{
if (!compact) ol.writeListItem();
ol.startQuickIndexItem(extLink,"pages.html");
parseText(ol,theTranslator->trRelatedPages());
ol.endQuickIndexItem();
}
if (exampleList.count()>0)
if (exampleSDict->count()>0)
{
if (!compact) ol.writeListItem();
ol.startQuickIndexItem(extLink,"examples.html");
......@@ -2109,13 +2110,13 @@ bool generateLink(OutputList &ol,const char *clName,
ol.docify(lt);
return FALSE;
}
else if ((pi=pageDict[linkRef])) // link to a page
else if ((pi=pageSDict->find(linkRef))) // link to a page
{
ol.writeObjectLink(0,pi->name,0,lt);
writePageRef(ol,pi->name,0);
return TRUE;
}
else if ((pi=exampleDict[linkRef])) // link to an example
else if ((pi=exampleSDict->find(linkRef))) // link to an example
{
ol.writeObjectLink(0,convertFileName(pi->name)+"-example",0,lt);
writePageRef(ol,convertFileName(pi->name)+"-example",0);
......@@ -2162,6 +2163,7 @@ void generateFileRef(OutputList &ol,const char *name,const char *text)
//----------------------------------------------------------------------
#if 0
QCString substituteClassNames(const QCString &s)
{
int i=0,l,p;
......@@ -2185,6 +2187,7 @@ QCString substituteClassNames(const QCString &s)
result+=s.mid(i,s.length()-i);
return result;
}
#endif
//----------------------------------------------------------------------
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment