Commit 3cd2917e authored by dimitri's avatar dimitri

Release-1.3

parent 535ddc3b
DOXYGEN Version 1.3-rc3-20030330 DOXYGEN Version 1.3
Please read the installation section of the manual Please read the installation section of the manual
(http://www.doxygen.org/install.html) for instructions. (http://www.doxygen.org/install.html) for instructions.
-------- --------
Dimitri van Heesch (30 March 2003) Dimitri van Heesch (10 April 2003)
DOXYGEN Version 1.3_rc3_20030330 DOXYGEN Version 1.3
Please read INSTALL for compilation instructions. Please read INSTALL for compilation instructions.
...@@ -17,4 +17,4 @@ to subscribe to the lists or to visit the archives. ...@@ -17,4 +17,4 @@ to subscribe to the lists or to visit the archives.
Enjoy, Enjoy,
Dimitri van Heesch (dimitri@stack.nl) (30 March 2003) Dimitri van Heesch (dimitri@stack.nl) (10 April 2003)
1.3-rc3-20030330 1.3
...@@ -39,7 +39,7 @@ It can help you in three ways: ...@@ -39,7 +39,7 @@ It can help you in three ways:
The documentation is extracted directly from the sources, which The documentation is extracted directly from the sources, which
makes it much easier to keep the documentation consistent with the makes it much easier to keep the documentation consistent with the
source code. source code.
<li> You can configure doxygen to extract the code structure <li> You can \ref extract_all "configure" doxygen to extract the code structure
from undocumented source files. This is very useful to quickly from undocumented source files. This is very useful to quickly
find your way in large source distributions. find your way in large source distributions.
You can also visualize the relations between the various elements You can also visualize the relations between the various elements
......
...@@ -25,7 +25,7 @@ Doxygen has built-in support for multiple languages. This means ...@@ -25,7 +25,7 @@ Doxygen has built-in support for multiple languages. This means
that the text fragments that doxygen generates can be produced in that the text fragments that doxygen generates can be produced in
languages other than English (the default) at configuration time. languages other than English (the default) at configuration time.
Currently (version 1.3-rc3-20030327), 28 languages Currently (version 1.2.14-20020317), 28 languages
are supported (sorted alphabetically): are supported (sorted alphabetically):
Brazilian Portuguese, Catalan, Chinese, Chinese Traditional, Croatian, Brazilian Portuguese, Catalan, Chinese, Chinese Traditional, Croatian,
Czech, Danish, Dutch, English, Finnish, Czech, Danish, Dutch, English, Finnish,
......
...@@ -102,6 +102,7 @@ written in Java. Files ending with <code>.cs</code> are treated as C# files. ...@@ -102,6 +102,7 @@ written in Java. Files ending with <code>.cs</code> are treated as C# files.
Finally, files with the extensions <code>.php</code>, <code>.php4</code>, Finally, files with the extensions <code>.php</code>, <code>.php4</code>,
<code>.inc</code> or <code>.phtml</code> are treated as PHP sources. <code>.inc</code> or <code>.phtml</code> are treated as PHP sources.
\anchor extract_all
If you start using doxygen for an existing project (thus without any If you start using doxygen for an existing project (thus without any
documentation that doxygen is aware of), you can still get an idea of documentation that doxygen is aware of), you can still get an idea of
what the documented result would be. To do so, you must set what the documented result would be. To do so, you must set
......
Summary: A documentation system for C/C++. Summary: A documentation system for C/C++.
Name: doxygen Name: doxygen
Version: 1.3_rc3_20030330 Version: 1.3
Release: 1 Release: 1
Epoch: 1 Epoch: 1
Source0: ftp://ftp.stack.nl/pub/users/dimitri/%{name}-%{version}.src.tar.gz Source0: ftp://ftp.stack.nl/pub/users/dimitri/%{name}-%{version}.src.tar.gz
......
...@@ -672,6 +672,7 @@ static void generateClassOrGlobalLink(BaseCodeDocInterface &ol,char *clName, ...@@ -672,6 +672,7 @@ static void generateClassOrGlobalLink(BaseCodeDocInterface &ol,char *clName,
} }
else else
{ {
//printf("typeOnly=%d\n",typeOnly);
if (cd==0 && !typeOnly) // not a class, see if it is a global enum/variable/typedef. if (cd==0 && !typeOnly) // not a class, see if it is a global enum/variable/typedef.
{ {
MemberDef *md = setCallContextForVar(clName); MemberDef *md = setCallContextForVar(clName);
...@@ -1556,7 +1557,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned" ...@@ -1556,7 +1557,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
<MemberCall2,FuncCall>[a-z_A-Z][:a-z_A-Z0-9]*({B}*"<"[^\n\<\>]*">")? { <MemberCall2,FuncCall>[a-z_A-Z][:a-z_A-Z0-9]*({B}*"<"[^\n\<\>]*">")? {
addParmType(); addParmType();
g_parmName=yytext; g_parmName=yytext;
generateClassOrGlobalLink(*g_code,yytext,TRUE); generateClassOrGlobalLink(*g_code,yytext,!g_insideBody);
} }
<MemberCall2,FuncCall>, { <MemberCall2,FuncCall>, {
g_code->codify(yytext); g_code->codify(yytext);
...@@ -1798,6 +1799,11 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned" ...@@ -1798,6 +1799,11 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
codifyLines(yytext); codifyLines(yytext);
endFontClass(); endFontClass();
} }
if (YY_START==SkipCxxComment)
{
endFontClass();
BEGIN( g_lastCContext ) ;
}
} }
<*>\n{B}*"//@"[{}].*\n { // remove one-line group marker <*>\n{B}*"//@"[{}].*\n { // remove one-line group marker
if (Config_getBool("STRIP_CODE_COMMENTS")) if (Config_getBool("STRIP_CODE_COMMENTS"))
...@@ -1815,6 +1821,11 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned" ...@@ -1815,6 +1821,11 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
codifyLines(yytext); codifyLines(yytext);
endFontClass(); endFontClass();
} }
if (YY_START==SkipCxxComment)
{
endFontClass();
BEGIN( g_lastCContext ) ;
}
} }
<*>\n{B}*"/*@"[{}] { // remove one-line group marker <*>\n{B}*"/*@"[{}] { // remove one-line group marker
if (Config_getBool("STRIP_CODE_COMMENTS")) if (Config_getBool("STRIP_CODE_COMMENTS"))
......
...@@ -2371,8 +2371,21 @@ void Config::create() ...@@ -2371,8 +2371,21 @@ void Config::create()
//----------------------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------------------
cl = addList( cl = addList(
"TAGFILES", "TAGFILES",
"The TAGFILES tag can be used to specify one or more tagfiles. \n" "The TAGFILES option can be used to specify one or more tagfiles. \n"
); "Optionally an initial location of the external documentation \n"
"can be added for each tagfile. The format of a tag file without \n"
"this location is as follows: \n"
" TAGFILES = file1 file2 ... \n"
"Adding location for the tag files is done as follows: \n"
" TAGFILES = file1=loc1 \"file2 = loc2\" ... \n"
"where \"loc1\" and \"loc2\" can be relative or absolute paths or \n"
"URLs. If a location is present for each tag, the installdox tool \n"
"does not have to be run to correct the links.\n"
"Note that each tag file must have a unique name\n"
"(where the name does NOT include the path)\n"
"If a tag file is not located in the directory in which doxygen \n"
"is run, you must also specify the path to the tagfile here. \n"
);
cl->setWidgetType(ConfigList::File); cl->setWidgetType(ConfigList::File);
cs = addString( cs = addString(
"GENERATE_TAGFILE", "GENERATE_TAGFILE",
......
...@@ -1175,6 +1175,7 @@ DocAnchor::DocAnchor(DocNode *parent,const QString &id,bool newAnchor) ...@@ -1175,6 +1175,7 @@ DocAnchor::DocAnchor(DocNode *parent,const QString &id,bool newAnchor)
void DocInclude::parse() void DocInclude::parse()
{ {
DBG(("DocInclude::parse(file=%s,text=%s)\n",m_file.data(),m_text.data()));
switch(m_type) switch(m_type)
{ {
case Include: case Include:
...@@ -1184,6 +1185,7 @@ void DocInclude::parse() ...@@ -1184,6 +1185,7 @@ void DocInclude::parse()
g_includeFileText = m_text; g_includeFileText = m_text;
g_includeFileOffset = 0; g_includeFileOffset = 0;
g_includeFileLength = m_text.length(); g_includeFileLength = m_text.length();
//printf("g_includeFile=<<%s>>\n",g_includeFileText.data());
break; break;
case VerbInclude: case VerbInclude:
// fall through // fall through
...@@ -1200,7 +1202,7 @@ void DocIncOperator::parse() ...@@ -1200,7 +1202,7 @@ void DocIncOperator::parse()
const char *p = g_includeFileText; const char *p = g_includeFileText;
uint l = g_includeFileLength; uint l = g_includeFileLength;
uint o = g_includeFileOffset; uint o = g_includeFileOffset;
//printf("DocIncOperator::parse() text=%s off=%d len=%d\n",p,o,l); DBG(("DocIncOperator::parse() text=%s off=%d len=%d\n",p,o,l));
uint so = o,bo; uint so = o,bo;
bool nonEmpty = FALSE; bool nonEmpty = FALSE;
switch(type()) switch(type())
...@@ -1223,6 +1225,7 @@ void DocIncOperator::parse() ...@@ -1223,6 +1225,7 @@ void DocIncOperator::parse()
if (g_includeFileText.mid(so,o-so).find(m_pattern)!=-1) if (g_includeFileText.mid(so,o-so).find(m_pattern)!=-1)
{ {
m_text = g_includeFileText.mid(so,o-so); m_text = g_includeFileText.mid(so,o-so);
DBG(("DocIncOperator::parse() Line: %s\n",m_text.data()));
} }
g_includeFileOffset = QMIN(l,o+1); // set pointer to start of new line g_includeFileOffset = QMIN(l,o+1); // set pointer to start of new line
break; break;
...@@ -1247,6 +1250,7 @@ void DocIncOperator::parse() ...@@ -1247,6 +1250,7 @@ void DocIncOperator::parse()
if (g_includeFileText.mid(so,o-so).find(m_pattern)!=-1) if (g_includeFileText.mid(so,o-so).find(m_pattern)!=-1)
{ {
m_text = g_includeFileText.mid(so,o-so); m_text = g_includeFileText.mid(so,o-so);
DBG(("DocIncOperator::parse() SkipLine: %s\n",m_text.data()));
break; break;
} }
o++; // skip new line o++; // skip new line
...@@ -1301,6 +1305,7 @@ void DocIncOperator::parse() ...@@ -1301,6 +1305,7 @@ void DocIncOperator::parse()
if (g_includeFileText.mid(so,o-so).find(m_pattern)!=-1) if (g_includeFileText.mid(so,o-so).find(m_pattern)!=-1)
{ {
m_text = g_includeFileText.mid(bo,o-bo); m_text = g_includeFileText.mid(bo,o-bo);
DBG(("DocIncOperator::parse() Until: %s\n",m_text.data()));
break; break;
} }
o++; // skip new line o++; // skip new line
...@@ -3129,6 +3134,7 @@ int DocPara::handleXRefItem(DocXRefItem::Type t) ...@@ -3129,6 +3134,7 @@ int DocPara::handleXRefItem(DocXRefItem::Type t)
void DocPara::handleIncludeOperator(const QString &cmdName,DocIncOperator::Type t) void DocPara::handleIncludeOperator(const QString &cmdName,DocIncOperator::Type t)
{ {
DBG(("handleIncludeOperator(%s)\n",cmdName.data()));
int tok=doctokenizerYYlex(); int tok=doctokenizerYYlex();
if (tok!=TK_WHITESPACE) if (tok!=TK_WHITESPACE)
{ {
...@@ -3349,6 +3355,7 @@ endlang: ...@@ -3349,6 +3355,7 @@ endlang:
void DocPara::handleInclude(const QString &cmdName,DocInclude::Type t) void DocPara::handleInclude(const QString &cmdName,DocInclude::Type t)
{ {
DBG(("handleInclude(%s)\n",cmdName.data()));
int tok=doctokenizerYYlex(); int tok=doctokenizerYYlex();
if (tok!=TK_WHITESPACE) if (tok!=TK_WHITESPACE)
{ {
......
...@@ -47,6 +47,8 @@ class SectionDict; ...@@ -47,6 +47,8 @@ class SectionDict;
* Can be 0. * Can be 0.
* @param input String representation of the documentation block. * @param input String representation of the documentation block.
* @param isExample TRUE if the documentation belongs to an example. * @param isExample TRUE if the documentation belongs to an example.
* @param sections Sections (and anchors) found in the documentation are
* collected here (if not 0).
* @returns Root node of the abstract syntax tree. Ownership of the * @returns Root node of the abstract syntax tree. Ownership of the
* pointer is handed over to the caller. * pointer is handed over to the caller.
*/ */
...@@ -139,9 +141,11 @@ class DocNode ...@@ -139,9 +141,11 @@ class DocNode
/*! Returns TRUE iff this node is inside a preformatted section */ /*! Returns TRUE iff this node is inside a preformatted section */
bool isPreformatted() const { return m_insidePre; } bool isPreformatted() const { return m_insidePre; }
protected:
/*! Sets whether or not this item is inside a preformatted section */ /*! Sets whether or not this item is inside a preformatted section */
void setInsidePreformatted(bool p) { m_insidePre = p; } void setInsidePreformatted(bool p) { m_insidePre = p; }
private: private:
bool m_insidePre; bool m_insidePre;
}; };
...@@ -193,12 +197,12 @@ class DocLinkedWord : public DocNode ...@@ -193,12 +197,12 @@ class DocLinkedWord : public DocNode
const QString &anchor) : const QString &anchor) :
m_parent(parent), m_word(word), m_ref(ref), m_parent(parent), m_word(word), m_ref(ref),
m_file(file), m_anchor(anchor) {} m_file(file), m_anchor(anchor) {}
QString word() const { return m_word; } QString word() const { return m_word; }
Kind kind() const { return Kind_Word; } Kind kind() const { return Kind_Word; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
QString file() const { return m_file; } QString file() const { return m_file; }
QString ref() const { return m_ref; } QString ref() const { return m_ref; }
QString anchor() const { return m_anchor; } QString anchor() const { return m_anchor; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
private: private:
...@@ -215,11 +219,11 @@ class DocURL : public DocNode ...@@ -215,11 +219,11 @@ class DocURL : public DocNode
public: public:
DocURL(DocNode *parent,const QString &url,bool isEmail) : DocURL(DocNode *parent,const QString &url,bool isEmail) :
m_parent(parent), m_url(url), m_isEmail(isEmail) {} m_parent(parent), m_url(url), m_isEmail(isEmail) {}
QString url() const { return m_url; } QString url() const { return m_url; }
Kind kind() const { return Kind_URL; } Kind kind() const { return Kind_URL; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
bool isEmail() const { return m_isEmail; } bool isEmail() const { return m_isEmail; }
private: private:
DocNode *m_parent; DocNode *m_parent;
...@@ -233,8 +237,8 @@ class DocLineBreak : public DocNode ...@@ -233,8 +237,8 @@ class DocLineBreak : public DocNode
public: public:
DocLineBreak(DocNode *parent) : DocLineBreak(DocNode *parent) :
m_parent(parent) {} m_parent(parent) {}
Kind kind() const { return Kind_LineBreak; } Kind kind() const { return Kind_LineBreak; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
private: private:
...@@ -247,8 +251,8 @@ class DocHorRuler : public DocNode ...@@ -247,8 +251,8 @@ class DocHorRuler : public DocNode
public: public:
DocHorRuler(DocNode *parent) : DocHorRuler(DocNode *parent) :
m_parent(parent) {} m_parent(parent) {}
Kind kind() const { return Kind_HorRuler; } Kind kind() const { return Kind_HorRuler; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
private: private:
...@@ -260,10 +264,10 @@ class DocAnchor : public DocNode ...@@ -260,10 +264,10 @@ class DocAnchor : public DocNode
{ {
public: public:
DocAnchor(DocNode *parent,const QString &id,bool newAnchor); DocAnchor(DocNode *parent,const QString &id,bool newAnchor);
Kind kind() const { return Kind_Anchor; } Kind kind() const { return Kind_Anchor; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
QString anchor() const { return m_anchor; } QString anchor() const { return m_anchor; }
QString file() const { return m_file; } QString file() const { return m_file; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
private: private:
...@@ -284,13 +288,13 @@ class DocStyleChange : public DocNode ...@@ -284,13 +288,13 @@ class DocStyleChange : public DocNode
const HtmlAttribList *attribs=0) : const HtmlAttribList *attribs=0) :
m_parent(parent), m_position(position), m_style(s), m_enable(enable) m_parent(parent), m_position(position), m_style(s), m_enable(enable)
{ if (attribs) m_attribs=*attribs; } { if (attribs) m_attribs=*attribs; }
Kind kind() const { return Kind_StyleChange; } Kind kind() const { return Kind_StyleChange; }
Style style() const { return m_style; } Style style() const { return m_style; }
const char *styleString() const; const char *styleString() const;
bool enable() const { return m_enable; } bool enable() const { return m_enable; }
uint position() const { return m_position; } uint position() const { return m_position; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
const HtmlAttribList &attribs() const { return m_attribs; } const HtmlAttribList &attribs() const { return m_attribs; }
private: private:
...@@ -311,10 +315,10 @@ class DocSymbol : public DocNode ...@@ -311,10 +315,10 @@ class DocSymbol : public DocNode
}; };
DocSymbol(DocNode *parent,SymType s,char letter='\0') : DocSymbol(DocNode *parent,SymType s,char letter='\0') :
m_parent(parent), m_symbol(s), m_letter(letter) {} m_parent(parent), m_symbol(s), m_letter(letter) {}
SymType symbol() const { return m_symbol; } SymType symbol() const { return m_symbol; }
char letter() const { return m_letter; } char letter() const { return m_letter; }
Kind kind() const { return Kind_Symbol; } Kind kind() const { return Kind_Symbol; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
static SymType decodeSymbol(const QString &symName,char *letter); static SymType decodeSymbol(const QString &symName,char *letter);
...@@ -330,9 +334,9 @@ class DocWhiteSpace : public DocNode ...@@ -330,9 +334,9 @@ class DocWhiteSpace : public DocNode
public: public:
DocWhiteSpace(DocNode *parent,const QString &chars) : DocWhiteSpace(DocNode *parent,const QString &chars) :
m_parent(parent), m_chars(chars) {} m_parent(parent), m_chars(chars) {}
Kind kind() const { return Kind_WhiteSpace; } Kind kind() const { return Kind_WhiteSpace; }
QString chars() const { return m_chars; } QString chars() const { return m_chars; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
private: private:
DocNode *m_parent; DocNode *m_parent;
...@@ -349,13 +353,13 @@ class DocVerbatim : public DocNode ...@@ -349,13 +353,13 @@ class DocVerbatim : public DocNode
const QString &exampleFile) : const QString &exampleFile) :
m_parent(parent), m_context(context), m_text(text), m_type(t), m_parent(parent), m_context(context), m_text(text), m_type(t),
m_isExample(isExample), m_exampleFile(exampleFile) {} m_isExample(isExample), m_exampleFile(exampleFile) {}
Kind kind() const { return Kind_Verbatim; } Kind kind() const { return Kind_Verbatim; }
Type type() const { return m_type; } Type type() const { return m_type; }
QString text() const { return m_text; } QString text() const { return m_text; }
QString context() const { return m_context; } QString context() const { return m_context; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
bool isExample() const { return m_isExample; } bool isExample() const { return m_isExample; }
QString exampleFile() const { return m_exampleFile; } QString exampleFile() const { return m_exampleFile; }
private: private:
...@@ -440,11 +444,11 @@ class DocFormula : public DocNode ...@@ -440,11 +444,11 @@ class DocFormula : public DocNode
{ {
public: public:
DocFormula(DocNode *parent,int id); DocFormula(DocNode *parent,int id);
Kind kind() const { return Kind_Formula; } Kind kind() const { return Kind_Formula; }
QString name() const { return m_name; } QString name() const { return m_name; }
QString text() const { return m_text; } QString text() const { return m_text; }
int id() const { return m_id; } int id() const { return m_id; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
private: private:
...@@ -461,9 +465,9 @@ class DocIndexEntry : public DocNode ...@@ -461,9 +465,9 @@ class DocIndexEntry : public DocNode
DocIndexEntry(DocNode *parent) : m_parent(parent) { } DocIndexEntry(DocNode *parent) : m_parent(parent) { }
Kind kind() const { return Kind_IndexEntry; } Kind kind() const { return Kind_IndexEntry; }
int parse(); int parse();
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { v->visit(this); } void accept(DocVisitor *v) { v->visit(this); }
QString entry() { return m_entry; } QString entry() { return m_entry; }
private: private:
DocNode *m_parent; DocNode *m_parent;
...@@ -478,11 +482,11 @@ class DocCopy : public CompAccept<DocCopy>, public DocNode ...@@ -478,11 +482,11 @@ class DocCopy : public CompAccept<DocCopy>, public DocNode
public: public:
DocCopy(DocNode *parent,const QString &link) DocCopy(DocNode *parent,const QString &link)
: m_parent(parent), m_link(link) { } : m_parent(parent), m_link(link) { }
Kind kind() const { return Kind_IndexEntry; } Kind kind() const { return Kind_IndexEntry; }
QString link() const { return m_link; } QString link() const { return m_link; }
void parse(); DocNode *parent() const { return m_parent; }
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocCopy>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocCopy>::accept(this,v); }
void parse();
private: private:
DocNode *m_parent; DocNode *m_parent;
...@@ -495,12 +499,12 @@ class DocAutoList : public CompAccept<DocAutoList>, public DocNode ...@@ -495,12 +499,12 @@ class DocAutoList : public CompAccept<DocAutoList>, public DocNode
public: public:
DocAutoList(DocNode *parent,int indent,bool isEnumList) : DocAutoList(DocNode *parent,int indent,bool isEnumList) :
m_parent(parent), m_indent(indent), m_isEnumList(isEnumList) {} m_parent(parent), m_indent(indent), m_isEnumList(isEnumList) {}
Kind kind() const { return Kind_AutoList; } Kind kind() const { return Kind_AutoList; }
int parse(); bool isEnumList() const { return m_isEnumList; }
bool isEnumList() const { return m_isEnumList; } int indent() const { return m_indent; }
int indent() const { return m_indent; } DocNode *parent() const { return m_parent; }
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocAutoList>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocAutoList>::accept(this,v); }
int parse();
private: private:
DocNode *m_parent; DocNode *m_parent;
...@@ -516,8 +520,8 @@ class DocTitle : public CompAccept<DocTitle>, public DocNode ...@@ -516,8 +520,8 @@ class DocTitle : public CompAccept<DocTitle>, public DocNode
DocTitle(DocNode *parent) : m_parent(parent) {} DocTitle(DocNode *parent) : m_parent(parent) {}
void parse(); void parse();
void parseFromString(const QString &title); void parseFromString(const QString &title);
Kind kind() const { return Kind_Title; } Kind kind() const { return Kind_Title; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocTitle>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocTitle>::accept(this,v); }
private: private:
...@@ -531,14 +535,14 @@ class DocXRefItem : public CompAccept<DocXRefItem>, public DocNode ...@@ -531,14 +535,14 @@ class DocXRefItem : public CompAccept<DocXRefItem>, public DocNode
enum Type { Bug, Test, Todo, Deprecated }; enum Type { Bug, Test, Todo, Deprecated };
DocXRefItem(DocNode *parent,int id,Type t) : DocXRefItem(DocNode *parent,int id,Type t) :
m_parent(parent), m_id(id), m_type(t) {} m_parent(parent), m_id(id), m_type(t) {}
Kind kind() const { return Kind_XRefItem; } Kind kind() const { return Kind_XRefItem; }
Type type() const { return m_type; } Type type() const { return m_type; }
QString file() const { return m_file; } QString file() const { return m_file; }
QString anchor() const { return m_anchor; } QString anchor() const { return m_anchor; }
QString title() const { return m_title; } QString title() const { return m_title; }
void parse(); DocNode *parent() const { return m_parent; }
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocXRefItem>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocXRefItem>::accept(this,v); }
void parse();
private: private:
DocNode *m_parent; DocNode *m_parent;
...@@ -558,11 +562,11 @@ class DocImage : public CompAccept<DocImage>, public DocNode ...@@ -558,11 +562,11 @@ class DocImage : public CompAccept<DocImage>, public DocNode
m_parent(parent), m_name(name), m_type(t) {} m_parent(parent), m_name(name), m_type(t) {}
Kind kind() const { return Kind_Image; } Kind kind() const { return Kind_Image; }
Type type() const { return m_type; } Type type() const { return m_type; }
QString name() const { return m_name; } QString name() const { return m_name; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
bool hasCaption() const { return !m_children.isEmpty(); } bool hasCaption() const { return !m_children.isEmpty(); }
QString width() const { return m_width; } QString width() const { return m_width; }
QString height() const { return m_height; } QString height() const { return m_height; }
void accept(DocVisitor *v) { CompAccept<DocImage>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocImage>::accept(this,v); }
void parse(); void parse();
...@@ -582,11 +586,11 @@ class DocDotFile : public CompAccept<DocDotFile>, public DocNode ...@@ -582,11 +586,11 @@ class DocDotFile : public CompAccept<DocDotFile>, public DocNode
m_parent(parent), m_name(name) { } m_parent(parent), m_name(name) { }
void parse(); void parse();
Kind kind() const { return Kind_DotFile; } Kind kind() const { return Kind_DotFile; }
QString name() const { return m_name; } QString name() const { return m_name; }
QString file() const { return m_file; } QString file() const { return m_file; }
bool hasCaption() const { return !m_children.isEmpty(); } bool hasCaption() const { return !m_children.isEmpty(); }
QString width() const { return m_width; } QString width() const { return m_width; }
QString height() const { return m_height; } QString height() const { return m_height; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocDotFile>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocDotFile>::accept(this,v); }
...@@ -604,11 +608,11 @@ class DocLink : public CompAccept<DocLink>, public DocNode ...@@ -604,11 +608,11 @@ class DocLink : public CompAccept<DocLink>, public DocNode
public: public:
DocLink(DocNode *parent,const QString &target); DocLink(DocNode *parent,const QString &target);
QString parse(bool); QString parse(bool);
Kind kind() const { return Kind_Link; } Kind kind() const { return Kind_Link; }
QString file() const { return m_file; } QString file() const { return m_file; }
QString ref() const { return m_ref; } QString ref() const { return m_ref; }
QString anchor() const { return m_anchor; } QString anchor() const { return m_anchor; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocLink>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocLink>::accept(this,v); }
private: private:
...@@ -626,10 +630,10 @@ class DocRef : public CompAccept<DocRef>, public DocNode ...@@ -626,10 +630,10 @@ class DocRef : public CompAccept<DocRef>, public DocNode
DocRef(DocNode *parent,const QString &target); DocRef(DocNode *parent,const QString &target);
void parse(); void parse();
Kind kind() const { return Kind_Ref; } Kind kind() const { return Kind_Ref; }
QString file() const { return m_file; } QString file() const { return m_file; }
QString ref() const { return m_ref; } QString ref() const { return m_ref; }
QString anchor() const { return m_anchor; } QString anchor() const { return m_anchor; }
QString targetTitle() const { return m_text; } QString targetTitle() const { return m_text; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
bool hasLinkText() const { return !m_children.isEmpty(); } bool hasLinkText() const { return !m_children.isEmpty(); }
bool refToAnchor() const { return m_refToAnchor; } bool refToAnchor() const { return m_refToAnchor; }
...@@ -653,8 +657,8 @@ class DocInternalRef : public CompAccept<DocInternalRef>, public DocNode ...@@ -653,8 +657,8 @@ class DocInternalRef : public CompAccept<DocInternalRef>, public DocNode
DocInternalRef(DocNode *parent,const QString &target); DocInternalRef(DocNode *parent,const QString &target);
void parse(); void parse();
Kind kind() const { return Kind_Ref; } Kind kind() const { return Kind_Ref; }
QString file() const { return m_file; } QString file() const { return m_file; }
QString anchor() const { return m_anchor; } QString anchor() const { return m_anchor; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocInternalRef>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocInternalRef>::accept(this,v); }
...@@ -670,11 +674,11 @@ class DocLanguage : public CompAccept<DocLanguage>, public DocNode ...@@ -670,11 +674,11 @@ class DocLanguage : public CompAccept<DocLanguage>, public DocNode
public: public:
DocLanguage(DocNode *parent,const QString &id) : DocLanguage(DocNode *parent,const QString &id) :
m_parent(parent), m_id(id) {} m_parent(parent), m_id(id) {}
QString id() const { return m_id; } QString id() const { return m_id; }
int parse(); Kind kind() const { return Kind_Language; }
Kind kind() const { return Kind_Language; } DocNode *parent() const { return m_parent; }
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocLanguage>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocLanguage>::accept(this,v); }
int parse();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -688,9 +692,9 @@ class DocHRef : public CompAccept<DocHRef>, public DocNode ...@@ -688,9 +692,9 @@ class DocHRef : public CompAccept<DocHRef>, public DocNode
DocHRef(DocNode *parent,const QString &url) : DocHRef(DocNode *parent,const QString &url) :
m_parent(parent), m_url(url) {} m_parent(parent), m_url(url) {}
int parse(); int parse();
QString url() const { return m_url; } QString url() const { return m_url; }
Kind kind() const { return Kind_HRef; } Kind kind() const { return Kind_HRef; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocHRef>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocHRef>::accept(this,v); }
private: private:
...@@ -704,12 +708,12 @@ class DocHtmlHeader : public CompAccept<DocHtmlHeader>, public DocNode ...@@ -704,12 +708,12 @@ class DocHtmlHeader : public CompAccept<DocHtmlHeader>, public DocNode
public: public:
DocHtmlHeader(DocNode *parent,const HtmlAttribList &attribs,int level) : DocHtmlHeader(DocNode *parent,const HtmlAttribList &attribs,int level) :
m_parent(parent), m_level(level), m_attribs(attribs) {} m_parent(parent), m_level(level), m_attribs(attribs) {}
int parse(); int level() const { return m_level; }
int level() const { return m_level; } Kind kind() const { return Kind_HtmlHeader; }
Kind kind() const { return Kind_HtmlHeader; }
const HtmlAttribList &attribs() const { return m_attribs; } const HtmlAttribList &attribs() const { return m_attribs; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocHtmlHeader>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocHtmlHeader>::accept(this,v); }
int parse();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -723,11 +727,11 @@ class DocHtmlDescTitle : public CompAccept<DocHtmlDescTitle>, public DocNode ...@@ -723,11 +727,11 @@ class DocHtmlDescTitle : public CompAccept<DocHtmlDescTitle>, public DocNode
public: public:
DocHtmlDescTitle(DocNode *parent,const HtmlAttribList &attribs) : DocHtmlDescTitle(DocNode *parent,const HtmlAttribList &attribs) :
m_parent(parent), m_attribs(attribs) {} m_parent(parent), m_attribs(attribs) {}
int parse(); Kind kind() const { return Kind_HtmlDescTitle; }
Kind kind() const { return Kind_HtmlDescTitle; } DocNode *parent() const { return m_parent; }
DocNode *parent() const { return m_parent; }
const HtmlAttribList &attribs() const { return m_attribs; } const HtmlAttribList &attribs() const { return m_attribs; }
void accept(DocVisitor *v) { CompAccept<DocHtmlDescTitle>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocHtmlDescTitle>::accept(this,v); }
int parse();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -740,11 +744,11 @@ class DocHtmlDescList : public CompAccept<DocHtmlDescList>, public DocNode ...@@ -740,11 +744,11 @@ class DocHtmlDescList : public CompAccept<DocHtmlDescList>, public DocNode
public: public:
DocHtmlDescList(DocNode *parent,const HtmlAttribList &attribs) DocHtmlDescList(DocNode *parent,const HtmlAttribList &attribs)
: m_parent(parent), m_attribs(attribs) {} : m_parent(parent), m_attribs(attribs) {}
int parse(); Kind kind() const { return Kind_HtmlDescList; }
Kind kind() const { return Kind_HtmlDescList; } DocNode *parent() const { return m_parent; }
DocNode *parent() const { return m_parent; }
const HtmlAttribList &attribs() const { return m_attribs; } const HtmlAttribList &attribs() const { return m_attribs; }
void accept(DocVisitor *v) { CompAccept<DocHtmlDescList>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocHtmlDescList>::accept(this,v); }
int parse();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -759,10 +763,10 @@ class DocSection : public CompAccept<DocSection>, public DocNode ...@@ -759,10 +763,10 @@ class DocSection : public CompAccept<DocSection>, public DocNode
m_parent(parent), m_level(level), m_id(id) {} m_parent(parent), m_level(level), m_id(id) {}
Kind kind() const { return Kind_Section; } Kind kind() const { return Kind_Section; }
int level() const { return m_level; } int level() const { return m_level; }
QString title() const { return m_title; } QString title() const { return m_title; }
QString anchor() const { return m_anchor; } QString anchor() const { return m_anchor; }
QString id() const { return m_id; } QString id() const { return m_id; }
QString file() const { return m_file; } QString file() const { return m_file; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocSection>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocSection>::accept(this,v); }
int parse(); int parse();
...@@ -783,9 +787,9 @@ class DocSecRefItem : public CompAccept<DocSecRefItem>, public DocNode ...@@ -783,9 +787,9 @@ class DocSecRefItem : public CompAccept<DocSecRefItem>, public DocNode
DocSecRefItem(DocNode *parent,const QString &target) : DocSecRefItem(DocNode *parent,const QString &target) :
m_parent(parent), m_target(target) {} m_parent(parent), m_target(target) {}
Kind kind() const { return Kind_SecRefItem; } Kind kind() const { return Kind_SecRefItem; }
QString target() const { return m_target; } QString target() const { return m_target; }
QString file() const { return m_file; } QString file() const { return m_file; }
QString anchor() const { return m_anchor; } QString anchor() const { return m_anchor; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocSecRefItem>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocSecRefItem>::accept(this,v); }
void parse(); void parse();
...@@ -803,8 +807,8 @@ class DocSecRefList : public CompAccept<DocSecRefList>, public DocNode ...@@ -803,8 +807,8 @@ class DocSecRefList : public CompAccept<DocSecRefList>, public DocNode
public: public:
DocSecRefList(DocNode *parent) : m_parent(parent) {} DocSecRefList(DocNode *parent) : m_parent(parent) {}
void parse(); void parse();
Kind kind() const { return Kind_SecRefList; } Kind kind() const { return Kind_SecRefList; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocSecRefList>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocSecRefList>::accept(this,v); }
private: private:
...@@ -817,8 +821,8 @@ class DocInternal : public CompAccept<DocInternal>, public DocNode ...@@ -817,8 +821,8 @@ class DocInternal : public CompAccept<DocInternal>, public DocNode
public: public:
DocInternal(DocNode *parent) : m_parent(parent) {} DocInternal(DocNode *parent) : m_parent(parent) {}
int parse(); int parse();
Kind kind() const { return Kind_Internal; } Kind kind() const { return Kind_Internal; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocInternal>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocInternal>::accept(this,v); }
private: private:
...@@ -830,10 +834,10 @@ class DocSimpleList : public CompAccept<DocSimpleList>, public DocNode ...@@ -830,10 +834,10 @@ class DocSimpleList : public CompAccept<DocSimpleList>, public DocNode
{ {
public: public:
DocSimpleList(DocNode *parent) : m_parent(parent) {} DocSimpleList(DocNode *parent) : m_parent(parent) {}
Kind kind() const { return Kind_SimpleList; } Kind kind() const { return Kind_SimpleList; }
int parse(); DocNode *parent() const { return m_parent; }
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocSimpleList>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocSimpleList>::accept(this,v); }
int parse();
private: private:
DocNode *m_parent; DocNode *m_parent;
...@@ -846,12 +850,12 @@ class DocHtmlList : public CompAccept<DocHtmlList>, public DocNode ...@@ -846,12 +850,12 @@ class DocHtmlList : public CompAccept<DocHtmlList>, public DocNode
enum Type { Unordered, Ordered }; enum Type { Unordered, Ordered };
DocHtmlList(DocNode *parent,const HtmlAttribList &attribs,Type t) : DocHtmlList(DocNode *parent,const HtmlAttribList &attribs,Type t) :
m_parent(parent), m_type(t), m_attribs(attribs) {} m_parent(parent), m_type(t), m_attribs(attribs) {}
Kind kind() const { return Kind_HtmlList; } Kind kind() const { return Kind_HtmlList; }
Type type() const { return m_type; } Type type() const { return m_type; }
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocHtmlList>::accept(this,v); }
const HtmlAttribList &attribs() const { return m_attribs; } const HtmlAttribList &attribs() const { return m_attribs; }
int parse(); int parse();
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocHtmlList>::accept(this,v); }
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -870,12 +874,12 @@ class DocSimpleSect : public CompAccept<DocSimpleSect>, public DocNode ...@@ -870,12 +874,12 @@ class DocSimpleSect : public CompAccept<DocSimpleSect>, public DocNode
}; };
DocSimpleSect(DocNode *parent,Type t); DocSimpleSect(DocNode *parent,Type t);
virtual ~DocSimpleSect(); virtual ~DocSimpleSect();
int parse(bool userTitle); Kind kind() const { return Kind_SimpleSect; }
int parseRcs(); Type type() const { return m_type; }
Kind kind() const { return Kind_SimpleSect; }
Type type() const { return m_type; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v); void accept(DocVisitor *v);
int parse(bool userTitle);
int parseRcs();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -893,9 +897,9 @@ class DocParamSect : public CompAccept<DocParamSect>, public DocNode ...@@ -893,9 +897,9 @@ class DocParamSect : public CompAccept<DocParamSect>, public DocNode
}; };
DocParamSect(DocNode *parent,Type t) : m_parent(parent), m_type(t) {} DocParamSect(DocNode *parent,Type t) : m_parent(parent), m_type(t) {}
int parse(const QString &cmdName); int parse(const QString &cmdName);
Kind kind() const { return Kind_ParamSect; } Kind kind() const { return Kind_ParamSect; }
Type type() const { return m_type; } Type type() const { return m_type; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocParamSect>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocParamSect>::accept(this,v); }
private: private:
...@@ -910,14 +914,14 @@ class DocPara : public CompAccept<DocPara>, public DocNode ...@@ -910,14 +914,14 @@ class DocPara : public CompAccept<DocPara>, public DocNode
DocPara(DocNode *parent) : m_parent(parent), DocPara(DocNode *parent) : m_parent(parent),
m_isFirst(FALSE), m_isLast(FALSE) {} m_isFirst(FALSE), m_isLast(FALSE) {}
int parse(); int parse();
Kind kind() const { return Kind_Para; } Kind kind() const { return Kind_Para; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
bool isEmpty() const { return m_children.isEmpty(); } bool isEmpty() const { return m_children.isEmpty(); }
void accept(DocVisitor *v) { CompAccept<DocPara>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocPara>::accept(this,v); }
void markFirst(bool v=TRUE) { m_isFirst=v; } void markFirst(bool v=TRUE) { m_isFirst=v; }
void markLast(bool v=TRUE) { m_isLast=v; } void markLast(bool v=TRUE) { m_isLast=v; }
bool isFirst() const { return m_isFirst; } bool isFirst() const { return m_isFirst; }
bool isLast() const { return m_isLast; } bool isLast() const { return m_isLast; }
int handleCommand(const QString &cmdName); int handleCommand(const QString &cmdName);
int handleHtmlStartTag(const QString &tagName,const HtmlAttribList &tagHtmlAttribs); int handleHtmlStartTag(const QString &tagName,const HtmlAttribList &tagHtmlAttribs);
...@@ -948,23 +952,22 @@ class DocParamList : public DocNode ...@@ -948,23 +952,22 @@ class DocParamList : public DocNode
DocParamList(DocNode *parent,DocParamSect::Type t) DocParamList(DocNode *parent,DocParamSect::Type t)
: m_parent(parent) , m_type(t), m_isFirst(TRUE), m_isLast(TRUE) : m_parent(parent) , m_type(t), m_isFirst(TRUE), m_isLast(TRUE)
{ m_paragraph=new DocPara(this); } { m_paragraph=new DocPara(this); }
virtual ~DocParamList() virtual ~DocParamList() { delete m_paragraph; }
{ delete m_paragraph; } Kind kind() const { return Kind_ParamList; }
int parse(const QString &cmdName); DocNode *parent() const { return m_parent; }
Kind kind() const { return Kind_ParamList; } const QStrList &parameters() { return m_params; }
DocNode *parent() const { return m_parent; }
const QStrList &parameters() { return m_params; }
DocParamSect::Type type() const { return m_type; } DocParamSect::Type type() const { return m_type; }
void markFirst(bool b=TRUE) { m_isFirst=b; } void markFirst(bool b=TRUE) { m_isFirst=b; }
void markLast(bool b=TRUE) { m_isLast=b; } void markLast(bool b=TRUE) { m_isLast=b; }
bool isFirst() const { return m_isFirst; } bool isFirst() const { return m_isFirst; }
bool isLast() const { return m_isLast; } bool isLast() const { return m_isLast; }
void accept(DocVisitor *v) void accept(DocVisitor *v)
{ {
v->visitPre(this); v->visitPre(this);
m_paragraph->accept(v); m_paragraph->accept(v);
v->visitPost(this); v->visitPost(this);
} }
int parse(const QString &cmdName);
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -982,16 +985,17 @@ class DocAutoListItem : public DocNode ...@@ -982,16 +985,17 @@ class DocAutoListItem : public DocNode
DocAutoListItem(DocNode *parent,int num) : m_parent(parent), m_itemNum(num) DocAutoListItem(DocNode *parent,int num) : m_parent(parent), m_itemNum(num)
{ m_paragraph=new DocPara(this); } { m_paragraph=new DocPara(this); }
virtual ~DocAutoListItem() { delete m_paragraph; } virtual ~DocAutoListItem() { delete m_paragraph; }
int parse(); Kind kind() const { return Kind_AutoListItem; }
Kind kind() const { return Kind_AutoListItem; } DocNode *parent() const { return m_parent; }
DocNode *parent() const { return m_parent; } int itemNumber() const { return m_itemNum; }
int itemNumber() const { return m_itemNum; }
void accept(DocVisitor *v) void accept(DocVisitor *v)
{ {
v->visitPre(this); v->visitPre(this);
m_paragraph->accept(v); m_paragraph->accept(v);
v->visitPost(this); v->visitPost(this);
} }
int parse();
private: private:
DocNode *m_parent; DocNode *m_parent;
DocPara *m_paragraph; DocPara *m_paragraph;
...@@ -1006,8 +1010,8 @@ class DocSimpleListItem : public DocNode ...@@ -1006,8 +1010,8 @@ class DocSimpleListItem : public DocNode
{ m_paragraph=new DocPara(this); } { m_paragraph=new DocPara(this); }
int parse(); int parse();
virtual ~DocSimpleListItem() { delete m_paragraph; } virtual ~DocSimpleListItem() { delete m_paragraph; }
Kind kind() const { return Kind_SimpleListItem; } Kind kind() const { return Kind_SimpleListItem; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) void accept(DocVisitor *v)
{ {
v->visitPre(this); v->visitPre(this);
...@@ -1026,12 +1030,12 @@ class DocHtmlListItem : public CompAccept<DocHtmlListItem>, public DocNode ...@@ -1026,12 +1030,12 @@ class DocHtmlListItem : public CompAccept<DocHtmlListItem>, public DocNode
public: public:
DocHtmlListItem(DocNode *parent,const HtmlAttribList &attribs,int num) : DocHtmlListItem(DocNode *parent,const HtmlAttribList &attribs,int num) :
m_parent(parent), m_attribs(attribs), m_itemNum(num) {} m_parent(parent), m_attribs(attribs), m_itemNum(num) {}
int parse(); Kind kind() const { return Kind_HtmlListItem; }
Kind kind() const { return Kind_HtmlListItem; } int itemNumber() const { return m_itemNum; }
int itemNumber() const { return m_itemNum; }
const HtmlAttribList &attribs() const { return m_attribs; } const HtmlAttribList &attribs() const { return m_attribs; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocHtmlListItem>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocHtmlListItem>::accept(this,v); }
int parse();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -1045,11 +1049,11 @@ class DocHtmlDescData : public CompAccept<DocHtmlDescData>, public DocNode ...@@ -1045,11 +1049,11 @@ class DocHtmlDescData : public CompAccept<DocHtmlDescData>, public DocNode
public: public:
DocHtmlDescData(DocNode *parent) : DocHtmlDescData(DocNode *parent) :
m_parent(parent) {} m_parent(parent) {}
int parse(); Kind kind() const { return Kind_HtmlDescData; }
Kind kind() const { return Kind_HtmlDescData; }
const HtmlAttribList &attribs() const { return m_attribs; } const HtmlAttribList &attribs() const { return m_attribs; }
DocNode *parent() const { return m_parent; } DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocHtmlDescData>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocHtmlDescData>::accept(this,v); }
int parse();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -1063,16 +1067,16 @@ class DocHtmlCell : public CompAccept<DocHtmlCell>, public DocNode ...@@ -1063,16 +1067,16 @@ class DocHtmlCell : public CompAccept<DocHtmlCell>, public DocNode
DocHtmlCell(DocNode *parent,const HtmlAttribList &attribs,bool isHeading) : DocHtmlCell(DocNode *parent,const HtmlAttribList &attribs,bool isHeading) :
m_parent(parent), m_isHeading(isHeading), m_parent(parent), m_isHeading(isHeading),
m_isFirst(FALSE), m_isLast(FALSE), m_attribs(attribs) {} m_isFirst(FALSE), m_isLast(FALSE), m_attribs(attribs) {}
int parse(); bool isHeading() const { return m_isHeading; }
bool isHeading() const { return m_isHeading; } bool isFirst() const { return m_isFirst; }
bool isFirst() const { return m_isFirst; } bool isLast() const { return m_isLast; }
bool isLast() const { return m_isLast; } Kind kind() const { return Kind_HtmlCell; }
Kind kind() const { return Kind_HtmlCell; } DocNode *parent() const { return m_parent; }
const HtmlAttribList &attribs() const { return m_attribs; } void accept(DocVisitor *v) { CompAccept<DocHtmlCell>::accept(this,v); }
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocHtmlCell>::accept(this,v); }
void markFirst(bool v=TRUE) { m_isFirst=v; } void markFirst(bool v=TRUE) { m_isFirst=v; }
void markLast(bool v=TRUE) { m_isLast=v; } void markLast(bool v=TRUE) { m_isLast=v; }
const HtmlAttribList &attribs() const { return m_attribs; }
int parse();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -1088,11 +1092,11 @@ class DocHtmlCaption : public CompAccept<DocHtmlCaption>, public DocNode ...@@ -1088,11 +1092,11 @@ class DocHtmlCaption : public CompAccept<DocHtmlCaption>, public DocNode
public: public:
DocHtmlCaption(DocNode *parent,const HtmlAttribList &attribs) : DocHtmlCaption(DocNode *parent,const HtmlAttribList &attribs) :
m_parent(parent), m_attribs(attribs) {} m_parent(parent), m_attribs(attribs) {}
int parse(); Kind kind() const { return Kind_HtmlCaption; }
Kind kind() const { return Kind_HtmlCaption; } DocNode *parent() const { return m_parent; }
const HtmlAttribList &attribs() const { return m_attribs; }
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocHtmlCaption>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocHtmlCaption>::accept(this,v); }
const HtmlAttribList &attribs() const { return m_attribs; }
int parse();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -1105,12 +1109,12 @@ class DocHtmlRow : public CompAccept<DocHtmlRow>, public DocNode ...@@ -1105,12 +1109,12 @@ class DocHtmlRow : public CompAccept<DocHtmlRow>, public DocNode
public: public:
DocHtmlRow(DocNode *parent,const HtmlAttribList &attribs) DocHtmlRow(DocNode *parent,const HtmlAttribList &attribs)
: m_parent(parent), m_attribs(attribs) {} : m_parent(parent), m_attribs(attribs) {}
int parse(); Kind kind() const { return Kind_HtmlRow; }
Kind kind() const { return Kind_HtmlRow; } DocNode *parent() const { return m_parent; }
const HtmlAttribList &attribs() const { return m_attribs; } uint numCells() const { return m_children.count(); }
DocNode *parent() const { return m_parent; }
uint numCells() const { return m_children.count(); }
void accept(DocVisitor *v) { CompAccept<DocHtmlRow>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocHtmlRow>::accept(this,v); }
const HtmlAttribList &attribs() const { return m_attribs; }
int parse();
private: private:
DocNode * m_parent; DocNode * m_parent;
...@@ -1164,10 +1168,10 @@ class DocText : public CompAccept<DocText>, public DocNode ...@@ -1164,10 +1168,10 @@ class DocText : public CompAccept<DocText>, public DocNode
{ {
public: public:
DocText() {} DocText() {}
void parse(); Kind kind() const { return Kind_Text; }
Kind kind() const { return Kind_Text; }
DocNode *parent() const { return 0; } DocNode *parent() const { return 0; }
void accept(DocVisitor *v) { CompAccept<DocText>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocText>::accept(this,v); }
void parse();
}; };
/*! @brief Root node of documentation tree */ /*! @brief Root node of documentation tree */
...@@ -1175,10 +1179,10 @@ class DocRoot : public CompAccept<DocRoot>, public DocNode ...@@ -1175,10 +1179,10 @@ class DocRoot : public CompAccept<DocRoot>, public DocNode
{ {
public: public:
DocRoot() {} DocRoot() {}
void parse(); Kind kind() const { return Kind_Root; }
Kind kind() const { return Kind_Root; }
DocNode *parent() const { return 0; } DocNode *parent() const { return 0; }
void accept(DocVisitor *v) { CompAccept<DocRoot>::accept(this,v); } void accept(DocVisitor *v) { CompAccept<DocRoot>::accept(this,v); }
void parse();
}; };
......
...@@ -964,25 +964,6 @@ DotGfxHierarchyTable::~DotGfxHierarchyTable() ...@@ -964,25 +964,6 @@ DotGfxHierarchyTable::~DotGfxHierarchyTable()
{ {
//printf("DotGfxHierarchyTable::~DotGfxHierarchyTable\n"); //printf("DotGfxHierarchyTable::~DotGfxHierarchyTable\n");
#if 0 // TODO: delete this
SDict<DotNode> skipNodes(1009);
skipNodes.setAutoDelete(TRUE);
DotNode *n = m_rootNodes->first();
while (n)
{
//printf("adding %s %p\n",n->label().data(),n);
skipNodes.append((char*)n,n);
n=m_rootNodes->next();
}
n = m_rootNodes->first();
while (n)
{
//printf("Deleting root node %s\n",n->label().data());
deleteNodes(n,&skipNodes);
n=m_rootNodes->next();
}
#endif
//QDictIterator<DotNode> di(*m_usedNodes); //QDictIterator<DotNode> di(*m_usedNodes);
//DotNode *n; //DotNode *n;
//for (;(n=di.current());++di) //for (;(n=di.current());++di)
......
...@@ -152,7 +152,7 @@ class DotClassGraph ...@@ -152,7 +152,7 @@ class DotClassGraph
class DotInclDepGraph class DotInclDepGraph
{ {
public: public:
DotInclDepGraph(FileDef *fd,int maxRecusionDepth,bool inverse=FALSE); DotInclDepGraph(FileDef *fd,int maxRecusionDepth,bool inverse);
~DotInclDepGraph(); ~DotInclDepGraph();
QCString writeGraph(QTextStream &t, GraphOutputFormat f,const char *path, QCString writeGraph(QTextStream &t, GraphOutputFormat f,const char *path,
bool writeImageMap=TRUE); bool writeImageMap=TRUE);
......
...@@ -799,20 +799,20 @@ static void addClassToContext(Entry *root) ...@@ -799,20 +799,20 @@ static void addClassToContext(Entry *root)
Doxygen::classSDict.append(fullName,cd); Doxygen::classSDict.append(fullName,cd);
// also add class to the correct structural context // also add class to the correct structural context
Definition *d = findScopeFromQualifiedName(Doxygen::globalScope,fullName); //Definition *d = findScopeFromQualifiedName(Doxygen::globalScope,fullName);
if (d==0) //if (d==0)
{ //{
//warn(root->fileName,root->startLine, // warn(root->fileName,root->startLine,
// "Warning: Internal inconsistency: scope for class %s not " // "Warning: Internal inconsistency: scope for class %s not "
// "found!\n",fullName.data() // "found!\n",fullName.data()
// ); // );
} //}
else //else
{ //{
//printf("****** adding %s to scope %s\n",cd->name().data(),d->name().data()); // //printf("****** adding %s to scope %s\n",cd->name().data(),d->name().data());
d->addInnerCompound(cd); // d->addInnerCompound(cd);
cd->setOuterScope(d); // cd->setOuterScope(d);
} //}
} }
} }
...@@ -850,6 +850,46 @@ static void buildClassDocList(Entry *root) ...@@ -850,6 +850,46 @@ static void buildClassDocList(Entry *root)
buildClassDocList(e); buildClassDocList(e);
} }
} }
static void resolveClassNestingRelations()
{
int nestingLevel=0;
bool done=FALSE;
while (!done)
{
// iterate over all classes searching for a class with right nesting
// level (starting with 0 and going up until no more classes are found)
done=TRUE;
ClassSDict::Iterator cli(Doxygen::classSDict);
ClassDef *cd=0;
for (cli.toFirst();(cd=cli.current());++cli)
{
if (cd->name().contains("::")==nestingLevel)
{
//printf("Level=%d processing=%s\n",nestingLevel,cd->name().data());
done=FALSE;
// also add class to the correct structural context
Definition *d = findScopeFromQualifiedName(Doxygen::globalScope,cd->name());
if (d==0)
{
warn(cd->getDefFileName(),cd->getDefLine(),
"Warning: Internal inconsistency: scope for class %s not "
"found!\n",cd->name().data()
);
}
else
{
//printf("****** adding %s to scope %s\n",cd->name().data(),d->name().data());
d->addInnerCompound(cd);
cd->setOuterScope(d);
}
}
}
nestingLevel++;
}
}
//---------------------------------------------------------------------- //----------------------------------------------------------------------
// build a list of all namespaces mentioned in the documentation // build a list of all namespaces mentioned in the documentation
// and all namespaces that have a documentation block before their definition. // and all namespaces that have a documentation block before their definition.
...@@ -1710,7 +1750,7 @@ done: ...@@ -1710,7 +1750,7 @@ done:
// Searches the Entry tree for Variable documentation sections. // Searches the Entry tree for Variable documentation sections.
// If found they are stored in their class or in the global list. // If found they are stored in their class or in the global list.
void buildVarList(Entry *root) static void buildVarList(Entry *root)
{ {
if (!root->name.isEmpty() && if (!root->name.isEmpty() &&
(root->type.isEmpty() || compoundKeywordDict.find(root->type)==0) && (root->type.isEmpty() || compoundKeywordDict.find(root->type)==0) &&
...@@ -1914,7 +1954,7 @@ nextMember: ...@@ -1914,7 +1954,7 @@ nextMember:
// Searches the Entry tree for Function sections. // Searches the Entry tree for Function sections.
// If found they are stored in their class or in the global list. // If found they are stored in their class or in the global list.
void addMethodToClass(Entry *root,ClassDef *cd, static void addMethodToClass(Entry *root,ClassDef *cd,
const QCString &rname,/*const QCString &scope,*/bool isFriend) const QCString &rname,/*const QCString &scope,*/bool isFriend)
{ {
int l,i; int l,i;
...@@ -2790,7 +2830,7 @@ static QDict<int> *getTemplateArgumentsInName(ArgumentList *templateArguments,co ...@@ -2790,7 +2830,7 @@ static QDict<int> *getTemplateArgumentsInName(ArgumentList *templateArguments,co
* This function differs from getResolvedClass in that it also takes * This function differs from getResolvedClass in that it also takes
* using declarations and definition into account. * using declarations and definition into account.
*/ */
ClassDef *findClassWithinClassContext(ClassDef *cd,const QCString &name) static ClassDef *findClassWithinClassContext(ClassDef *cd,const QCString &name)
{ {
ClassDef *result=0; ClassDef *result=0;
...@@ -7861,6 +7901,7 @@ void parseInput() ...@@ -7861,6 +7901,7 @@ void parseInput()
msg("Building class list...\n"); msg("Building class list...\n");
buildClassList(root); buildClassList(root);
buildClassDocList(root); buildClassDocList(root);
resolveClassNestingRelations();
findUsingDeclarations(root); findUsingDeclarations(root);
msg("Building example list...\n"); msg("Building example list...\n");
......
...@@ -310,7 +310,7 @@ void FileDef::writeDocumentation(OutputList &ol) ...@@ -310,7 +310,7 @@ void FileDef::writeDocumentation(OutputList &ol)
if (Config_getBool("HAVE_DOT") && Config_getBool("INCLUDE_GRAPH")) if (Config_getBool("HAVE_DOT") && Config_getBool("INCLUDE_GRAPH"))
{ {
//printf("Graph for file %s\n",name().data()); //printf("Graph for file %s\n",name().data());
DotInclDepGraph incDepGraph(this,FALSE); DotInclDepGraph incDepGraph(this,Config_getInt("MAX_DOT_GRAPH_DEPTH"),FALSE);
if (!incDepGraph.isTrivial()) if (!incDepGraph.isTrivial())
{ {
ol.disable(OutputGenerator::Man); ol.disable(OutputGenerator::Man);
...@@ -326,7 +326,7 @@ void FileDef::writeDocumentation(OutputList &ol) ...@@ -326,7 +326,7 @@ void FileDef::writeDocumentation(OutputList &ol)
if (Config_getBool("HAVE_DOT") && Config_getBool("INCLUDED_BY_GRAPH")) if (Config_getBool("HAVE_DOT") && Config_getBool("INCLUDED_BY_GRAPH"))
{ {
//printf("Graph for file %s\n",name().data()); //printf("Graph for file %s\n",name().data());
DotInclDepGraph incDepGraph(this,TRUE); DotInclDepGraph incDepGraph(this,Config_getInt("MAX_DOT_GRAPH_DEPTH"),TRUE);
if (!incDepGraph.isTrivial()) if (!incDepGraph.isTrivial())
{ {
ol.disable(OutputGenerator::Man); ol.disable(OutputGenerator::Man);
......
...@@ -244,7 +244,10 @@ void HtmlDocVisitor::visit(DocIncOperator *op) ...@@ -244,7 +244,10 @@ void HtmlDocVisitor::visit(DocIncOperator *op)
} }
if (op->type()!=DocIncOperator::Skip) if (op->type()!=DocIncOperator::Skip)
{ {
popEnabled();
if (!m_hide) parseCode(m_ci,op->context(),op->text().latin1(),op->isExample(),op->exampleFile()); if (!m_hide) parseCode(m_ci,op->context(),op->text().latin1(),op->isExample(),op->exampleFile());
pushEnabled();
m_hide=TRUE;
} }
if (op->isLast()) if (op->isLast())
{ {
......
...@@ -737,6 +737,7 @@ void MemberDef::writeDeclaration(OutputList &ol, ...@@ -737,6 +737,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
ol.pushGeneratorState(); ol.pushGeneratorState();
ol.disable(OutputGenerator::Man); ol.disable(OutputGenerator::Man);
ol.disable(OutputGenerator::Latex);
ol.docify("\n"); ol.docify("\n");
ol.popGeneratorState(); ol.popGeneratorState();
} }
......
...@@ -1176,27 +1176,27 @@ class TranslatorPolish : public Translator ...@@ -1176,27 +1176,27 @@ class TranslatorPolish : public Translator
/*! Title of the package index page */ /*! Title of the package index page */
virtual QCString trPackageList() virtual QCString trPackageList()
{ {
return "Lista Pakietów"; return decode("Lista Pakietów");
} }
/*! The description of the package index page */ /*! The description of the package index page */
virtual QCString trPackageListDescription() virtual QCString trPackageListDescription()
{ {
return "Oto lista pakietów wraz z krótkim opisem (o ile jest dostêpny):"; return decode("Oto lista pakietów wraz z krótkim opisem (o ile jest dostêpny):");
} }
/*! The link name in the Quick links header for each page */ /*! The link name in the Quick links header for each page */
virtual QCString trPackages() virtual QCString trPackages()
{ {
return "Pakiety"; return decode("Pakiety");
} }
/*! Used as a chapter title for Latex & RTF output */ /*! Used as a chapter title for Latex & RTF output */
virtual QCString trPackageDocumentation() virtual QCString trPackageDocumentation()
{ {
return "Dokumentacja Pakietu"; return decode("Dokumentacja Pakietu");
} }
/*! Text shown before a multi-line define */ /*! Text shown before a multi-line define */
virtual QCString trDefineValue() virtual QCString trDefineValue()
{ {
return "Warto¶æ:"; return decode("Warto¶æ:");
} }
////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////
...@@ -1206,12 +1206,12 @@ class TranslatorPolish : public Translator ...@@ -1206,12 +1206,12 @@ class TranslatorPolish : public Translator
/*! Used as a marker that is put before a \\bug item */ /*! Used as a marker that is put before a \\bug item */
virtual QCString trBug() virtual QCString trBug()
{ {
return "B³±d"; return decode("B³±d");
} }
/*! Used as the header of the bug list */ /*! Used as the header of the bug list */
virtual QCString trBugList() virtual QCString trBugList()
{ {
return "Lista b³êdów"; return decode("Lista b³êdów");
} }
////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////
...@@ -1233,7 +1233,7 @@ class TranslatorPolish : public Translator ...@@ -1233,7 +1233,7 @@ class TranslatorPolish : public Translator
/*! Used as header RTF general index */ /*! Used as header RTF general index */
virtual QCString trRTFGeneralIndex() virtual QCString trRTFGeneralIndex()
{ {
return "Indeks"; return decode("Indeks");
} }
/*! This is used for translation of the word that will possibly /*! This is used for translation of the word that will possibly
...@@ -1267,7 +1267,7 @@ class TranslatorPolish : public Translator ...@@ -1267,7 +1267,7 @@ class TranslatorPolish : public Translator
QCString result((first_capital ? "Przestrze" : "przestrze")); QCString result((first_capital ? "Przestrze" : "przestrze"));
result+=(singular ? "ñ" : "nie"); result+=(singular ? "ñ" : "nie");
result+=" nazw"; result+=" nazw";
return result; return decode(result);
} }
/*! This is used for translation of the word that will possibly /*! This is used for translation of the word that will possibly
...@@ -1287,7 +1287,7 @@ class TranslatorPolish : public Translator ...@@ -1287,7 +1287,7 @@ class TranslatorPolish : public Translator
*/ */
virtual QCString trPage(bool first_capital, bool singular) virtual QCString trPage(bool first_capital, bool singular)
{ {
QCString result((first_capital ? "Ston" : "stron")); QCString result((first_capital ? "Stron" : "stron"));
result+=(singular ? "a" : "y"); result+=(singular ? "a" : "y");
return result; return result;
} }
...@@ -1300,7 +1300,7 @@ class TranslatorPolish : public Translator ...@@ -1300,7 +1300,7 @@ class TranslatorPolish : public Translator
{ {
QCString result((first_capital ? "Sk³adow" : "sk³adow")); QCString result((first_capital ? "Sk³adow" : "sk³adow"));
result+=(singular ? "a" : "e"); result+=(singular ? "a" : "e");
return result; return decode(result);
} }
/*! This is used for translation of the word that will possibly /*! This is used for translation of the word that will possibly
...@@ -1346,7 +1346,7 @@ class TranslatorPolish : public Translator ...@@ -1346,7 +1346,7 @@ class TranslatorPolish : public Translator
*/ */
virtual QCString trReferences() virtual QCString trReferences()
{ {
return "Odwo³uje siê do"; return decode("Odwo³uje siê do");
} }
...@@ -1374,7 +1374,7 @@ class TranslatorPolish : public Translator ...@@ -1374,7 +1374,7 @@ class TranslatorPolish : public Translator
*/ */
virtual QCString trRTFTableOfContents() virtual QCString trRTFTableOfContents()
{ {
return "Spis tre¶ci"; return decode("Spis tre¶ci");
} }
////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////
...@@ -1386,7 +1386,7 @@ class TranslatorPolish : public Translator ...@@ -1386,7 +1386,7 @@ class TranslatorPolish : public Translator
*/ */
virtual QCString trDeprecatedList() virtual QCString trDeprecatedList()
{ {
return "Lista elementów do wycofania"; return decode("Lista elementów do wycofania");
} }
////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////
...@@ -1403,7 +1403,7 @@ class TranslatorPolish : public Translator ...@@ -1403,7 +1403,7 @@ class TranslatorPolish : public Translator
/*! Header used for the documentation section of a class' events. */ /*! Header used for the documentation section of a class' events. */
virtual QCString trEventDocumentation() virtual QCString trEventDocumentation()
{ {
return "Dokumentacja zdarzeñ"; return decode("Dokumentacja zdarzeñ");
} }
......
...@@ -1932,7 +1932,14 @@ void mergeArguments(ArgumentList *srcAl,ArgumentList *dstAl) ...@@ -1932,7 +1932,14 @@ void mergeArguments(ArgumentList *srcAl,ArgumentList *dstAl)
} }
else if (!srcA->name.isEmpty() && !dstA->name.isEmpty()) else if (!srcA->name.isEmpty() && !dstA->name.isEmpty())
{ {
srcA->name = dstA->name.copy(); if (srcA->docs.isEmpty() && !dstA->docs.isEmpty())
{
srcA->name = dstA->name.copy();
}
else if (!srcA->docs.isEmpty() && dstA->docs.isEmpty())
{
dstA->name = srcA->name.copy();
}
} }
} }
else else
......
...@@ -18,12 +18,15 @@ ...@@ -18,12 +18,15 @@
#ifndef UTIL_H #ifndef UTIL_H
#define UTIL_H #define UTIL_H
/*! \file util.h
* \brief A bunch of utility functions.
*/
#include "qtbc.h" #include "qtbc.h"
#include <qlist.h> #include <qlist.h>
#include <qtextstream.h> #include <qtextstream.h>
#include <ctype.h> #include <ctype.h>
class ClassDef; class ClassDef;
class FileDef; class FileDef;
class MemberList; class MemberList;
...@@ -73,13 +76,12 @@ class TextGeneratorOLImpl : public TextGeneratorIntf ...@@ -73,13 +76,12 @@ class TextGeneratorOLImpl : public TextGeneratorIntf
//-------------------------------------------------------------------- //--------------------------------------------------------------------
extern void linkifyText(const TextGeneratorIntf &ol,const char *clName,const char *name, void linkifyText(const TextGeneratorIntf &ol,const char *clName,const char *name,
const char *text,bool autoBreak=FALSE,bool external=TRUE); const char *text,bool autoBreak=FALSE,bool external=TRUE);
void setAnchors(ClassDef *cd,char id,MemberList *ml,int groupId=-1);
extern void setAnchors(ClassDef *cd,char id,MemberList *ml,int groupId=-1); QCString fileToString(const char *name,bool filter=FALSE);
extern QCString fileToString(const char *name,bool filter=FALSE); QCString dateToString(bool);
extern QCString dateToString(bool); bool getDefs(const QCString &scopeName,
extern bool getDefs(const QCString &scopeName,
const QCString &memberName, const QCString &memberName,
const char *, const char *,
MemberDef *&md, MemberDef *&md,
...@@ -93,14 +95,14 @@ extern bool getDefs(const QCString &scopeName, ...@@ -93,14 +95,14 @@ extern bool getDefs(const QCString &scopeName,
); );
extern bool resolveRef(/* in */ const char *scName, bool resolveRef(/* in */ const char *scName,
/* in */ const char *name, /* in */ const char *name,
/* in */ bool inSeeBlock, /* in */ bool inSeeBlock,
/* out */ Definition **resContext, /* out */ Definition **resContext,
/* out */ MemberDef **resMember /* out */ MemberDef **resMember
); );
extern bool resolveLink(/* in */ const char *scName, bool resolveLink(/* in */ const char *scName,
/* in */ const char *lr, /* in */ const char *lr,
/* in */ bool inSeeBlock, /* in */ bool inSeeBlock,
/* out */ Definition **resContext, /* out */ Definition **resContext,
...@@ -108,47 +110,39 @@ extern bool resolveLink(/* in */ const char *scName, ...@@ -108,47 +110,39 @@ extern bool resolveLink(/* in */ const char *scName,
/* out */ QCString &resAnchor /* out */ QCString &resAnchor
); );
extern bool generateRef(OutputDocInterface &od,const char *, bool generateRef(OutputDocInterface &od,const char *,
const char *,bool inSeeBlock,const char * =0); const char *,bool inSeeBlock,const char * =0);
extern bool generateLink(OutputDocInterface &od,const char *, bool generateLink(OutputDocInterface &od,const char *,
const char *,bool inSeeBlock,const char *); const char *,bool inSeeBlock,const char *);
extern void generateFileRef(OutputDocInterface &od,const char *, void generateFileRef(OutputDocInterface &od,const char *,
const char *linkTxt=0); const char *linkTxt=0);
void writePageRef(OutputDocInterface &od,const char *cn,const char *mn); void writePageRef(OutputDocInterface &od,const char *cn,const char *mn);
extern bool matchArguments(ArgumentList *,ArgumentList *, bool matchArguments(ArgumentList *,ArgumentList *,
const char *cl=0,const char *ns=0,bool checkCV=TRUE, const char *cl=0,const char *ns=0,bool checkCV=TRUE,
NamespaceList *usingNamespaces=0, NamespaceList *usingNamespaces=0,
ClassList *usingClasses=0); ClassList *usingClasses=0);
extern void mergeArguments(ArgumentList *,ArgumentList *); void mergeArguments(ArgumentList *,ArgumentList *);
extern QCString substituteClassNames(const QCString &s); QCString substituteClassNames(const QCString &s);
extern QCString substitute(const char *s,const char *src,const char *dst); QCString substitute(const char *s,const char *src,const char *dst);
extern QCString resolveDefines(const char *n); QCString resolveDefines(const char *n);
extern ClassDef *getClass(const char *key); ClassDef *getClass(const char *key);
extern ClassDef *getResolvedClass(Definition *scope, ClassDef *getResolvedClass(Definition *scope,
const char *key, const char *key,
bool *pIsTypeDef=0, bool *pIsTypeDef=0,
QCString *pTemplSpec=0); QCString *pTemplSpec=0);
extern NamespaceDef *getResolvedNamespace(const char *key); NamespaceDef *getResolvedNamespace(const char *key);
extern FileDef *findFileDef(const FileNameDict *fnDict,const char *n, FileDef *findFileDef(const FileNameDict *fnDict,const char *n,
bool &ambig); bool &ambig);
extern QCString showFileDefMatches(const FileNameDict *fnDict,const char *n); QCString showFileDefMatches(const FileNameDict *fnDict,const char *n);
extern int guessSection(const char *name); int guessSection(const char *name);
extern bool isId(char c); bool isId(char c);
extern QCString removeRedundantWhiteSpace(const QCString &s); QCString removeRedundantWhiteSpace(const QCString &s);
//extern void startTitle(OutputList &ol,const char *fileName);
//extern void endTitle(OutputList &ol,const char *fileName,const char *name);
//void startFile(OutputList &ol,const char *name,
// const char *title,bool external=FALSE);
//void endFile(OutputList &ol,bool external=FALSE);
//void writeQuickLinks(OutputList &ol,bool compact,bool external=FALSE);
QCString argListToString(ArgumentList *al); QCString argListToString(ArgumentList *al);
QCString tempArgListToString(ArgumentList *al); QCString tempArgListToString(ArgumentList *al);
QCString generateMarker(int id); QCString generateMarker(int id);
void writeExample(OutputList &ol,ExampleSDict *el); void writeExample(OutputList &ol,ExampleSDict *el);
//void setFileNameForSections(QList<QCString> *anchorList,const char *fileName,
// PageInfo *pi=0);
QCString stripAnonymousNamespaceScope(const QCString &s); QCString stripAnonymousNamespaceScope(const QCString &s);
QCString stripFromPath(const QCString &path); QCString stripFromPath(const QCString &path);
bool rightScopeMatch(const QCString &scope, const QCString &name); bool rightScopeMatch(const QCString &scope, const QCString &name);
......
...@@ -979,7 +979,7 @@ static void generateXMLForClass(ClassDef *cd,QTextStream &ti) ...@@ -979,7 +979,7 @@ static void generateXMLForClass(ClassDef *cd,QTextStream &ti)
writeXMLDocBlock(t,cd->docFile(),cd->docLine(),cd->name(),0,cd->documentation()); writeXMLDocBlock(t,cd->docFile(),cd->docLine(),cd->name(),0,cd->documentation());
t << " </detaileddescription>" << endl; t << " </detaileddescription>" << endl;
DotClassGraph inheritanceGraph(cd,DotClassGraph::Inheritance, DotClassGraph inheritanceGraph(cd,DotClassGraph::Inheritance,
Config_getBool("MAX_DOT_GRAPH_DEPTH")); Config_getInt("MAX_DOT_GRAPH_DEPTH"));
if (!inheritanceGraph.isTrivial()) if (!inheritanceGraph.isTrivial())
{ {
t << " <inheritancegraph>" << endl; t << " <inheritancegraph>" << endl;
...@@ -987,7 +987,7 @@ static void generateXMLForClass(ClassDef *cd,QTextStream &ti) ...@@ -987,7 +987,7 @@ static void generateXMLForClass(ClassDef *cd,QTextStream &ti)
t << " </inheritancegraph>" << endl; t << " </inheritancegraph>" << endl;
} }
DotClassGraph collaborationGraph(cd,DotClassGraph::Implementation, DotClassGraph collaborationGraph(cd,DotClassGraph::Implementation,
Config_getBool("MAX_DOT_GRAPH_DEPTH")); Config_getInt("MAX_DOT_GRAPH_DEPTH"));
if (!collaborationGraph.isTrivial()) if (!collaborationGraph.isTrivial())
{ {
t << " <collaborationgraph>" << endl; t << " <collaborationgraph>" << endl;
...@@ -1162,7 +1162,7 @@ static void generateXMLForFile(FileDef *fd,QTextStream &ti) ...@@ -1162,7 +1162,7 @@ static void generateXMLForFile(FileDef *fd,QTextStream &ti)
t << "</includedby>" << endl; t << "</includedby>" << endl;
} }
DotInclDepGraph incDepGraph(fd,FALSE); DotInclDepGraph incDepGraph(fd,Config_getInt("MAX_DOT_GRAPH_DEPTH"),FALSE);
if (!incDepGraph.isTrivial()) if (!incDepGraph.isTrivial())
{ {
t << " <incdepgraph>" << endl; t << " <incdepgraph>" << endl;
...@@ -1170,7 +1170,7 @@ static void generateXMLForFile(FileDef *fd,QTextStream &ti) ...@@ -1170,7 +1170,7 @@ static void generateXMLForFile(FileDef *fd,QTextStream &ti)
t << " </incdepgraph>" << endl; t << " </incdepgraph>" << endl;
} }
DotInclDepGraph invIncDepGraph(fd,TRUE); DotInclDepGraph invIncDepGraph(fd,Config_getInt("MAX_DOT_GRAPH_DEPTH"),TRUE);
if (!invIncDepGraph.isTrivial()) if (!invIncDepGraph.isTrivial())
{ {
t << " <invincdepgraph>" << endl; t << " <invincdepgraph>" << endl;
......
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