Commit fb864720 authored by dimitri's avatar dimitri

Release-1.3-rc2

parent a641157e
DOXYGEN Version 1.3-rc1-20021207 DOXYGEN Version 1.3-rc2
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 (07 December 2002) Dimitri van Heesch (16 December 2002)
DOXYGEN Version 1.3_rc1_20021207 DOXYGEN Version 1.3_rc2
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) (07 December 2002) Dimitri van Heesch (dimitri@stack.nl) (16 December 2002)
1.3-rc1-20021207 1.3-rc2
...@@ -1057,6 +1057,7 @@ HighlightHandler::HighlightHandler(IBaseHandler *parent) ...@@ -1057,6 +1057,7 @@ HighlightHandler::HighlightHandler(IBaseHandler *parent)
m_children.setAutoDelete(TRUE); m_children.setAutoDelete(TRUE);
addEndHandler("highlight",this,&HighlightHandler::endHighlight); addEndHandler("highlight",this,&HighlightHandler::endHighlight);
addStartHandler("ref",this,&HighlightHandler::startRef); addStartHandler("ref",this,&HighlightHandler::startRef);
addStartHandler("sp",this,&HighlightHandler::startSpace);
m_hl = IDocHighlight::Invalid; m_hl = IDocHighlight::Invalid;
} }
...@@ -1070,12 +1071,13 @@ void HighlightHandler::startHighlight(const QXmlAttributes& attrib) ...@@ -1070,12 +1071,13 @@ void HighlightHandler::startHighlight(const QXmlAttributes& attrib)
m_hl = s_highlightMapper->stringToKind(m_hlString); m_hl = s_highlightMapper->stringToKind(m_hlString);
m_curString=""; m_curString="";
m_parent->setDelegate(this); m_parent->setDelegate(this);
debug(2,"start highlight\n");
} }
void HighlightHandler::endHighlight() void HighlightHandler::endHighlight()
{ {
addTextNode(); addTextNode();
debug(2,"highlight class=`%s'\n",m_hlString.data()); debug(2,"end highlight class=`%s'\n",m_hlString.data());
m_parent->setDelegate(0); m_parent->setDelegate(0);
} }
...@@ -1087,8 +1089,15 @@ void HighlightHandler::startRef(const QXmlAttributes& attrib) ...@@ -1087,8 +1089,15 @@ void HighlightHandler::startRef(const QXmlAttributes& attrib)
rh->startRef(attrib); rh->startRef(attrib);
} }
void HighlightHandler::startSpace(const QXmlAttributes&)
{
m_curString=" ";
addTextNode();
}
void HighlightHandler::addTextNode() void HighlightHandler::addTextNode()
{ {
printf("m_curString=`%s'\n",m_curString.data());
if (!m_curString.isEmpty()) if (!m_curString.isEmpty())
{ {
m_children.append(new TextNode(m_curString,IDocMarkup::Normal,0)); m_children.append(new TextNode(m_curString,IDocMarkup::Normal,0));
......
...@@ -765,6 +765,7 @@ class HighlightHandler : public DocHighlightImpl, public BaseHandler<HighlightHa ...@@ -765,6 +765,7 @@ class HighlightHandler : public DocHighlightImpl, public BaseHandler<HighlightHa
void startHighlight(const QXmlAttributes& attrib); void startHighlight(const QXmlAttributes& attrib);
void endHighlight(); void endHighlight();
virtual void startRef(const QXmlAttributes&); virtual void startRef(const QXmlAttributes&);
virtual void startSpace(const QXmlAttributes&);
// IDocHighlight // IDocHighlight
virtual Kind kind() const { return DocImpl::Highlight; } virtual Kind kind() const { return DocImpl::Highlight; }
......
...@@ -52,24 +52,26 @@ To take full advantage of doxygen's features the following additional ...@@ -52,24 +52,26 @@ To take full advantage of doxygen's features the following additional
tools should be installed. tools should be installed.
<ul> <ul>
<li>Troll Tech's GUI toolkit version 2.x.y <li>Troll Tech's GUI toolkit
<A HREF="http://www.trolltech.com/products/qt.html">Qt</A> <A HREF="http://www.trolltech.com/products/qt.html">Qt</A>
\latexonly(see {\tt http://www.trolltech.com/products/qt.html})\endlatexonly. \latexonly(see {\tt http://www.trolltech.com/products/qt.html})\endlatexonly
\addindex Qt \addindex Qt
This is needed to build the GUI front-end. version 2 or higher.
This is needed to build the GUI front-end doxywizard.
<li>A \f$\mbox{\LaTeX}\f$ distribution: for instance <li>A \f$\mbox{\LaTeX}\f$ distribution: for instance
<a href="http://www.tug.org/">teTeX 1.0</a> <a href="http://www.tug.org/interest.html#free">teTeX 1.0</a>
\latexonly \\par (see {\tt http://www.tug.org/})\endlatexonly. \latexonly \\par (see {\tt http://www.tug.org/interest.html\#free})\endlatexonly.
This is needed for generating LaTeX, Postscript, and PDF output. This is needed for generating LaTeX, Postscript, and PDF output.
<li><a href="http://www.research.att.com/sw/tools/graphviz/"> <li><a href="http://www.research.att.com/sw/tools/graphviz/">
the Graph visualization toolkit version 1.5</a> the Graph visualization toolkit version 1.5 or higher</a>
\latexonly \\par (see {\tt http://www.research.att.com/sw/tools/graphviz/})\endlatexonly. \latexonly \\par (see {\tt http://www.research.att.com/sw/tools/graphviz/})\endlatexonly.
Needed for the include dependency graphs, Needed for the include dependency graphs,
the graphical inheritance graphs, and the collaboration graphs. the graphical inheritance graphs, and the collaboration graphs.
If you compile graphviz yourself, make sure you do include If you compile graphviz yourself, make sure you do include
freetype support (which requires the freetype library and header files), freetype support (which requires the freetype library and header files),
otherwise dot will produce a warning that it cannot find doxfont! otherwise the graphs will not render proper text labels.
<li>The ghostscript interpreter. <li>The ghostscript interpreter. To be found at
<a href="http://www.ghostscript.com/">www.ghostscript.com</a>.
</ul> </ul>
Compilation is now done by performing the following steps: Compilation is now done by performing the following steps:
......
...@@ -143,8 +143,8 @@ when the translator was updated. ...@@ -143,8 +143,8 @@ when the translator was updated.
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
<TD>Japanese</TD> <TD>Japanese</TD>
<TD>Ryunosuke Sato<br>Kenji Nagamatsu</TD> <TD>Ryunosuke Satoh<br>Kenji Nagamatsu</TD>
<TD>puyo@NOSPAM.mint.freemail.ne.jp<br>naga@NOSPAM.joyful.club.ne.jp</TD> <TD>sun594@NOSPAM.hotmail.com<br>naga@NOSPAM.joyful.club.ne.jp</TD>
<TD>1.2.18</TD> <TD>1.2.18</TD>
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
...@@ -262,7 +262,7 @@ when the translator was updated. ...@@ -262,7 +262,7 @@ when the translator was updated.
Italian & Alessandro Falappa & {\tt alessandro@falappa.net} & up-to-date \\ Italian & Alessandro Falappa & {\tt alessandro@falappa.net} & up-to-date \\
& Ahmed Aldo Faisal & {\tt aaf23@cam.ac.uk} & \\ & Ahmed Aldo Faisal & {\tt aaf23@cam.ac.uk} & \\
\hline \hline
Japanese & Ryunosuke Sato & {\tt puyo@mint.freemail.ne.jp} & 1.2.18 \\ Japanese & Ryunosuke Satoh & {\tt sun594@hotmail.com} & 1.2.18 \\
& Kenji Nagamatsu & {\tt naga@joyful.club.ne.jp} & \\ & Kenji Nagamatsu & {\tt naga@joyful.club.ne.jp} & \\
\hline \hline
Korean & Richard Kim & {\tt ryk@dspwiz.com} & 1.2.13 \\ Korean & Richard Kim & {\tt ryk@dspwiz.com} & 1.2.13 \\
......
...@@ -25,9 +25,6 @@ ...@@ -25,9 +25,6 @@
properly. If you find such a piece, please send it to me, so I can properly. If you find such a piece, please send it to me, so I can
improve doxygen's parsing capabilities. Try to make the piece of code improve doxygen's parsing capabilities. Try to make the piece of code
you send as small as possible, to help me narrow down the search. you send as small as possible, to help me narrow down the search.
<li>Using declarations for member are not yet supported.
They are simply ignored. Using declarations for class and using
directives are supported however.
<li>Doxygen does not work properly if there are multiple classes, structs <li>Doxygen does not work properly if there are multiple classes, structs
or unions with the same name in your code. It should not crash however, or unions with the same name in your code. It should not crash however,
rather it should ignore all of the classes with the same name except one. rather it should ignore all of the classes with the same name except one.
...@@ -78,37 +75,47 @@ If you are trying Doxygen let me know what you think of it (do you ...@@ -78,37 +75,47 @@ If you are trying Doxygen let me know what you think of it (do you
miss certain features?). Even if you decide not to use it, please let me miss certain features?). Even if you decide not to use it, please let me
know why. know why.
\anchor bug_reports
<h2>How to report a bug</h2> <h2>How to report a bug</h2>
I would appreciate an e-mail if you have found If you find a bug please send an e-mail to: dimitri@stack.nl.
a bug, or if you have ideas (or even better some code or a patch) If you are unsure whether or not something is a bug, please ask help
how to fix existing bugs and limitations. For patches please use on the <a href="http://sourceforge.net/mail/?group_id=5971">users mailing list</a>
"diff -u" or include the files you modified. If you send more than first (subscription is required).
one file please tar or zip everything, so I only have to save and download
one file.
Always try to include the following information in your bug report: If you send only a (vague) description of a bug, you are usually not very
- The version of doxygen you are using (for instance 1.2.4). helpful and it will cost me much more time to figure out what you mean.
In the worst-case your bug report may even be completely ignored by me, so
always try to include the following information in your bug report:
- The version of doxygen you are using (for instance 1.2.4, use
<code>doxygen --version</code> if you are not sure).
- The name and version number of your operating system (for instance - The name and version number of your operating system (for instance
SuSE Linux 6.4) SuSE Linux 6.4)
- It is usually a good idea to send along the configuation file as well, - It is usually a good idea to send along the configuation file as well,
but please use doxygen with the <code>-s</code> flag while generating it but please use doxygen with the <code>-s</code> flag while generating it
to keep it small. to keep it small (use <code>doxygen -s -u [configName]</code> to strip
- The easiest way for me to solve bugs is if you can send me a small example the comments from an existing config file).
demonstrating the problem you have. Please make sure the example is valid - The easiest (and often the only) way for me to fix bugs is if you can
send me a small example demonstrating the problem you have, so I can
reproduce it on my machine. Please make sure the example is valid
source code (could potentially compile) and that the problem is really source code (could potentially compile) and that the problem is really
captured by the example (I often get examples that do not trigger the captured by the example (I often get examples that do not trigger the
actual bug!). actual bug!). If you intend to send more than one file please zip or tar
the files together into a single attachment for easier processing.
If you send only a (vague) description of a bug, you are usually not very If you have ideas (or even better some code or a patch)
helpful and it will cost me much more time to figure out what you mean. how to fix existing bugs and limitations please discuss them on
In the worst-case your bug report may even be completely ignored by me! the <a href="http://sourceforge.net/mail/?group_id=5971">developers mailing list</a>.
Patches can also send directly to dimitri@stack.nl.
My e-mail address: dimitri@stack.nl For patches please use
"diff -uN" or include the files you modified. If you send more than
one file please tar or zip everything, so I only have to save and download
one file.
Note that you can also post bug report to the developers mailing list Note that you can also post bug reports via the bug tracker at
or use the bug tracker at sourceforge (though I do not really like the sourceforge, but I do not really like this because of its web
latter because of its web interface). interface, which I find rather clumpsy to use.
*/ */
Summary: A documentation system for C/C++. Summary: A documentation system for C/C++.
Name: doxygen Name: doxygen
Version: 1.3_rc1_20021207 Version: 1.3_rc2
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
......
...@@ -122,7 +122,28 @@ void Definition::setDocumentation(const char *d,const char *docFile,int docLine, ...@@ -122,7 +122,28 @@ void Definition::setDocumentation(const char *d,const char *docFile,int docLine,
if (d==0) return; if (d==0) return;
//printf("Definition::setDocumentation(%s,%s,%d)\n",d,docFile,docLine); //printf("Definition::setDocumentation(%s,%s,%d)\n",d,docFile,docLine);
if (stripWhiteSpace) if (stripWhiteSpace)
m_doc=((QCString)d).stripWhiteSpace(); {
// strip leading empty lines in front of the text, but not the
// leading spaces in front of the first line, so list items are
// parsed with the correct indent
const char *p=d;
char c;
int s=0,so=0;
while ((c=*p) && (c==' ' || c=='\r' || c=='\n'))
{
if (c=='\n') so=s;
p++;
s++;
}
m_doc=d+so;
// zero any trailing whitespace
int e=m_doc.length()-1;
while (e>=0 && (c=m_doc.at(e)) && (c==' ' || c=='\r' || c=='\n'))
{
m_doc.at(e)='\0';
e--;
}
}
else else
m_doc=d; m_doc=d;
m_docFile = docFile; m_docFile = docFile;
......
...@@ -518,6 +518,7 @@ static bool defaultHandleToken(DocNode *parent,int tok, ...@@ -518,6 +518,7 @@ static bool defaultHandleToken(DocNode *parent,int tok,
static int handleStyleArgument(DocNode *parent,QList<DocNode> &children, static int handleStyleArgument(DocNode *parent,QList<DocNode> &children,
const QString &cmdName) const QString &cmdName)
{ {
DBG(("handleStyleArgument(%s)\n",cmdName.data()));
QString tokenName = g_token->name; QString tokenName = g_token->name;
int tok=doctokenizerYYlex(); int tok=doctokenizerYYlex();
if (tok!=TK_WHITESPACE) if (tok!=TK_WHITESPACE)
...@@ -527,7 +528,10 @@ static int handleStyleArgument(DocNode *parent,QList<DocNode> &children, ...@@ -527,7 +528,10 @@ static int handleStyleArgument(DocNode *parent,QList<DocNode> &children,
return tok; return tok;
} }
while ((tok=doctokenizerYYlex()) && while ((tok=doctokenizerYYlex()) &&
tok!=TK_WHITESPACE && tok!=TK_NEWPARA && tok!=TK_LISTITEM && tok!=TK_ENDLIST tok!=TK_WHITESPACE &&
tok!=TK_NEWPARA &&
tok!=TK_LISTITEM &&
tok!=TK_ENDLIST
) )
{ {
if (!defaultHandleToken(parent,tok,children)) if (!defaultHandleToken(parent,tok,children))
...@@ -547,9 +551,12 @@ static int handleStyleArgument(DocNode *parent,QList<DocNode> &children, ...@@ -547,9 +551,12 @@ static int handleStyleArgument(DocNode *parent,QList<DocNode> &children,
tokToString(tok)); tokToString(tok));
break; break;
} }
break;
} }
} }
return tok==TK_NEWPARA ? TK_NEWPARA : RetVal_OK; DBG(("handleStyleArgument(%s) end tok=%x\n",cmdName.data(),tok));
return (tok==TK_NEWPARA || tok==TK_LISTITEM || tok==TK_ENDLIST
) ? tok : RetVal_OK;
} }
static void handleStyleEnter(DocNode *parent,QList<DocNode> &children, static void handleStyleEnter(DocNode *parent,QList<DocNode> &children,
...@@ -699,45 +706,45 @@ static bool defaultHandleToken(DocNode *parent,int tok, QList<DocNode> &children ...@@ -699,45 +706,45 @@ static bool defaultHandleToken(DocNode *parent,int tok, QList<DocNode> &children
case CMD_EMPHASIS: case CMD_EMPHASIS:
{ {
children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Italic,TRUE)); children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Italic,TRUE));
int retval=handleStyleArgument(parent,children,tokenName); tok=handleStyleArgument(parent,children,tokenName);
children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Italic,FALSE)); children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Italic,FALSE));
children.append(new DocWhiteSpace(parent," ")); children.append(new DocWhiteSpace(parent," "));
if (retval==TK_NEWPARA) goto handlepara; if (tok==TK_NEWPARA) goto handlepara;
} }
break; break;
case CMD_BOLD: case CMD_BOLD:
{ {
children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Bold,TRUE)); children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Bold,TRUE));
int retval=handleStyleArgument(parent,children,tokenName); tok=handleStyleArgument(parent,children,tokenName);
children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Bold,FALSE)); children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Bold,FALSE));
children.append(new DocWhiteSpace(parent," ")); children.append(new DocWhiteSpace(parent," "));
if (retval==TK_NEWPARA) goto handlepara; if (tok==TK_NEWPARA) goto handlepara;
} }
break; break;
case CMD_CODE: case CMD_CODE:
{ {
children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Code,TRUE)); children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Code,TRUE));
int retval=handleStyleArgument(parent,children,tokenName); tok=handleStyleArgument(parent,children,tokenName);
children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Code,FALSE)); children.append(new DocStyleChange(parent,g_nodeStack.count(),DocStyleChange::Code,FALSE));
children.append(new DocWhiteSpace(parent," ")); children.append(new DocWhiteSpace(parent," "));
if (retval==TK_NEWPARA) goto handlepara; if (tok==TK_NEWPARA) goto handlepara;
} }
break; break;
case CMD_HTMLONLY: case CMD_HTMLONLY:
{ {
doctokenizerYYsetStateHtmlOnly(); doctokenizerYYsetStateHtmlOnly();
int retval = doctokenizerYYlex(); tok = doctokenizerYYlex();
children.append(new DocVerbatim(parent,g_context,g_token->verb,DocVerbatim::HtmlOnly,g_isExample,g_fileName)); children.append(new DocVerbatim(parent,g_context,g_token->verb,DocVerbatim::HtmlOnly,g_isExample,g_fileName));
if (retval==0) warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: htmlonly section ended without end marker"); if (tok==0) warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: htmlonly section ended without end marker");
doctokenizerYYsetStatePara(); doctokenizerYYsetStatePara();
} }
break; break;
case CMD_LATEXONLY: case CMD_LATEXONLY:
{ {
doctokenizerYYsetStateLatexOnly(); doctokenizerYYsetStateLatexOnly();
int retval = doctokenizerYYlex(); tok = doctokenizerYYlex();
children.append(new DocVerbatim(parent,g_context,g_token->verb,DocVerbatim::LatexOnly,g_isExample,g_fileName)); children.append(new DocVerbatim(parent,g_context,g_token->verb,DocVerbatim::LatexOnly,g_isExample,g_fileName));
if (retval==0) warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: latexonly section ended without end marker",doctokenizerYYlineno); if (tok==0) warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: latexonly section ended without end marker",doctokenizerYYlineno);
doctokenizerYYsetStatePara(); doctokenizerYYsetStatePara();
} }
break; break;
...@@ -749,7 +756,7 @@ static bool defaultHandleToken(DocNode *parent,int tok, QList<DocNode> &children ...@@ -749,7 +756,7 @@ static bool defaultHandleToken(DocNode *parent,int tok, QList<DocNode> &children
break; break;
case CMD_ANCHOR: case CMD_ANCHOR:
{ {
int tok=doctokenizerYYlex(); tok=doctokenizerYYlex();
if (tok!=TK_WHITESPACE) if (tok!=TK_WHITESPACE)
{ {
warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: expected whitespace after %s command", warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: expected whitespace after %s command",
...@@ -775,7 +782,7 @@ static bool defaultHandleToken(DocNode *parent,int tok, QList<DocNode> &children ...@@ -775,7 +782,7 @@ static bool defaultHandleToken(DocNode *parent,int tok, QList<DocNode> &children
break; break;
case CMD_INTERNALREF: case CMD_INTERNALREF:
{ {
int tok=doctokenizerYYlex(); tok=doctokenizerYYlex();
if (tok!=TK_WHITESPACE) if (tok!=TK_WHITESPACE)
{ {
warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: expected whitespace after %s command", warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: expected whitespace after %s command",
...@@ -1005,6 +1012,8 @@ static int internalValidatingParseDoc(DocNode *parent,QList<DocNode> &children, ...@@ -1005,6 +1012,8 @@ static int internalValidatingParseDoc(DocNode *parent,QList<DocNode> &children,
{ {
int retval = RetVal_OK; int retval = RetVal_OK;
if (doc.isEmpty()) return retval;
doctokenizerYYinit(doc,g_fileName); doctokenizerYYinit(doc,g_fileName);
// first parse any number of paragraphs // first parse any number of paragraphs
...@@ -2531,32 +2540,6 @@ enddesclist: ...@@ -2531,32 +2540,6 @@ enddesclist:
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
#if 0
int DocHtmlPre::parse()
{
int rv;
g_nodeStack.push(this);
bool isFirst=FALSE;
DocPara *par=0;
do
{
par = new DocPara(this);
if (isFirst) { par->markFirst(); isFirst=FALSE; }
m_children.append(par);
rv=par->parse();
}
while (rv==TK_NEWPARA);
if (par) par->markLast();
DocNode *n=g_nodeStack.pop();
ASSERT(n==this);
return rv==RetVal_EndPre ? RetVal_OK : rv;
}
#endif
//---------------------------------------------------------------------------
int DocHtmlListItem::parse() int DocHtmlListItem::parse()
{ {
DBG(("DocHtmlListItem::parse() start\n")); DBG(("DocHtmlListItem::parse() start\n"));
...@@ -2822,7 +2805,7 @@ int DocSimpleSect::parseRcs() ...@@ -2822,7 +2805,7 @@ int DocSimpleSect::parseRcs()
internalValidatingParseDoc(this,m_children,g_token->text); internalValidatingParseDoc(this,m_children,g_token->text);
docParserPopContext(); docParserPopContext();
DBG(("DocSimpleSect::parseRcs() end retval=%d\n",retval)); DBG(("DocSimpleSect::parseRcs()\n"));
DocNode *n=g_nodeStack.pop(); DocNode *n=g_nodeStack.pop();
ASSERT(n==this); ASSERT(n==this);
return RetVal_OK; return RetVal_OK;
...@@ -3246,6 +3229,7 @@ void DocPara::handleSection(const QString &cmdName) ...@@ -3246,6 +3229,7 @@ void DocPara::handleSection(const QString &cmdName)
int DocPara::handleCommand(const QString &cmdName) int DocPara::handleCommand(const QString &cmdName)
{ {
DBG(("handleCommand(%s)\n",cmdName.data()));
int retval = RetVal_OK; int retval = RetVal_OK;
switch (CmdMapper::map(cmdName)) switch (CmdMapper::map(cmdName))
{ {
...@@ -3579,6 +3563,7 @@ int DocPara::handleCommand(const QString &cmdName) ...@@ -3579,6 +3563,7 @@ int DocPara::handleCommand(const QString &cmdName)
retval==RetVal_Section || retval==RetVal_EndList || retval==RetVal_Section || retval==RetVal_EndList ||
retval==RetVal_Internal || retval==RetVal_SwitchLang retval==RetVal_Internal || retval==RetVal_SwitchLang
); );
DBG(("handleCommand(%s) end retval=%x\n",cmdName.data(),retval));
return retval; return retval;
} }
...@@ -4103,6 +4088,7 @@ reparsetoken: ...@@ -4103,6 +4088,7 @@ reparsetoken:
// handle the command // handle the command
retval=handleCommand(g_token->name.copy()); retval=handleCommand(g_token->name.copy());
DBG(("handleCommand returns %x\n",retval));
// check the return value // check the return value
if (retval==RetVal_SimpleSec) if (retval==RetVal_SimpleSec)
...@@ -4120,6 +4106,11 @@ reparsetoken: ...@@ -4120,6 +4106,11 @@ reparsetoken:
// the command ended normally, keep scanner for new tokens. // the command ended normally, keep scanner for new tokens.
retval = 0; retval = 0;
} }
else if (retval==TK_LISTITEM || retval==TK_ENDLIST)
{
tok = retval;
goto reparsetoken;
}
else // end of file, end of paragraph, start or end of section else // end of file, end of paragraph, start or end of section
// or some auto list marker // or some auto list marker
{ {
......
...@@ -86,52 +86,57 @@ class DocNode ...@@ -86,52 +86,57 @@ class DocNode
Kind_XRefItem = 15, Kind_XRefItem = 15,
Kind_HtmlList = 16, Kind_HtmlList = 16,
Kind_HtmlListItem = 17, Kind_HtmlListItem = 17,
//Kind_HtmlPre = 18, Kind_HtmlDescList = 18,
Kind_HtmlDescList = 19, Kind_HtmlDescData = 19,
Kind_HtmlDescData = 20, Kind_HtmlDescTitle = 20,
Kind_HtmlDescTitle = 21, Kind_HtmlTable = 21,
Kind_HtmlTable = 22, Kind_HtmlRow = 22,
Kind_HtmlRow = 23, Kind_HtmlCell = 23,
Kind_HtmlCell = 24, Kind_HtmlCaption = 24,
Kind_HtmlCaption = 25, Kind_LineBreak = 25,
Kind_LineBreak = 26, Kind_HorRuler = 26,
Kind_HorRuler = 27, Kind_Anchor = 27,
Kind_Anchor = 28, Kind_IndexEntry = 28,
Kind_IndexEntry = 29, Kind_Internal = 29,
Kind_Internal = 30, Kind_HRef = 30,
Kind_HRef = 31, Kind_Include = 31,
Kind_Include = 32, Kind_IncOperator = 32,
Kind_IncOperator = 33, Kind_HtmlHeader = 33,
Kind_HtmlHeader = 34, Kind_Image = 34,
Kind_Image = 35, Kind_DotFile = 35,
Kind_DotFile = 36, Kind_Link = 36,
Kind_Link = 37, Kind_Ref = 37,
Kind_Ref = 38, Kind_Formula = 38,
Kind_Formula = 39, Kind_SecRefItem = 39,
Kind_SecRefItem = 40, Kind_SecRefList = 40,
Kind_SecRefList = 41, Kind_Language = 41,
Kind_Language = 42, Kind_LinkedWord = 42,
Kind_LinkedWord = 43, Kind_ParamSect = 43,
Kind_ParamSect = 44, Kind_ParamList = 44,
Kind_ParamList = 45, Kind_InternalRef = 45,
Kind_InternalRef = 46, Kind_Copy = 46,
Kind_Copy = 47, Kind_Text = 47
Kind_Text = 48
}; };
/*! Creates a new node */ /*! Creates a new node */
DocNode() : m_insidePre(FALSE) {} DocNode() : m_insidePre(FALSE) {}
/*! Destroys a node. */ /*! Destroys a node. */
virtual ~DocNode() {} virtual ~DocNode() {}
/*! Returns the kind of node. Provides runtime type information */ /*! Returns the kind of node. Provides runtime type information */
virtual Kind kind() const = 0; virtual Kind kind() const = 0;
/*! Returns the parent of this node or 0 for the root node. */ /*! Returns the parent of this node or 0 for the root node. */
virtual DocNode *parent() const = 0; virtual DocNode *parent() const = 0;
/*! Acceptor function for node visitors. Part of the visitor pattern. /*! Acceptor function for node visitors. Part of the visitor pattern.
* @param v Abstract visitor. * @param v Abstract visitor.
*/ */
virtual void accept(DocVisitor *v) = 0; virtual void accept(DocVisitor *v) = 0;
/*! 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; }
/*! 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:
...@@ -156,7 +161,6 @@ template<class T> class CompAccept ...@@ -156,7 +161,6 @@ template<class T> class CompAccept
protected: protected:
QList<DocNode> m_children; QList<DocNode> m_children;
QList<DocNode> &getChildren() const { return m_children; }
}; };
...@@ -1048,25 +1052,6 @@ class DocHtmlDescData : public CompAccept<DocHtmlDescData>, public DocNode ...@@ -1048,25 +1052,6 @@ class DocHtmlDescData : public CompAccept<DocHtmlDescData>, public DocNode
HtmlAttribList m_attribs; HtmlAttribList m_attribs;
}; };
#if 0
/*! @brief Node representing a preformatted HTML section */
class DocHtmlPre : public CompAccept<DocHtmlPre>, public DocNode
{
public:
DocHtmlPre(DocNode *parent,const HtmlAttribList &attribs)
: m_parent(parent), m_attribs(attribs) {}
int parse();
Kind kind() const { return Kind_HtmlPre; }
const HtmlAttribList &attribs() const { return m_attribs; }
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocHtmlPre>::accept(this,v); }
private:
DocNode * m_parent;
HtmlAttribList m_attribs;
};
#endif
/*! @brief Node representing a HTML table cell */ /*! @brief Node representing a HTML table cell */
class DocHtmlCell : public CompAccept<DocHtmlCell>, public DocNode class DocHtmlCell : public CompAccept<DocHtmlCell>, public DocNode
{ {
......
...@@ -378,7 +378,7 @@ LABELID [a-z_A-Z][a-z_A-Z0-9\-]* ...@@ -378,7 +378,7 @@ LABELID [a-z_A-Z][a-z_A-Z0-9\-]*
g_token->isEMailAddr=FALSE; g_token->isEMailAddr=FALSE;
return TK_URL; return TK_URL;
} }
<St_Para>[a-z_A-Z0-9.-]+"@"[a-z_A-Z0-9-]+"."[a-z_A-Z0-9.-]+ { // Mail address <St_Para>[a-z_A-Z0-9.-]+"@"[a-z_A-Z0-9-]+("."[a-z_A-Z0-9\-])+[a-z_A-Z0-9\-]+ { // Mail address
g_token->name=yytext; g_token->name=yytext;
g_token->isEMailAddr=TRUE; g_token->isEMailAddr=TRUE;
return TK_URL; return TK_URL;
......
...@@ -1064,9 +1064,9 @@ static void findUsingDeclarations(Entry *root) ...@@ -1064,9 +1064,9 @@ static void findUsingDeclarations(Entry *root)
!(root->parent->section&Entry::COMPOUND_MASK) // not a class/struct member !(root->parent->section&Entry::COMPOUND_MASK) // not a class/struct member
) )
{ {
printf("Found using declaration %s at line %d of %s inside section %x\n", //printf("Found using declaration %s at line %d of %s inside section %x\n",
root->name.data(),root->startLine,root->fileName.data(), // root->name.data(),root->startLine,root->fileName.data(),
root->parent->section); // root->parent->section);
bool ambig; bool ambig;
if (!root->name.isEmpty()) if (!root->name.isEmpty())
{ {
......
...@@ -485,12 +485,12 @@ void FileDef::writeSource(OutputList &ol) ...@@ -485,12 +485,12 @@ void FileDef::writeSource(OutputList &ol)
void FileDef::addMembersToMemberGroup() void FileDef::addMembersToMemberGroup()
{ {
::addMembersToMemberGroup(&decDefineMembers,memberGroupSDict); ::addMembersToMemberGroup(&decDefineMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decProtoMembers,memberGroupSDict); ::addMembersToMemberGroup(&decProtoMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decTypedefMembers,memberGroupSDict); ::addMembersToMemberGroup(&decTypedefMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decEnumMembers,memberGroupSDict); ::addMembersToMemberGroup(&decEnumMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decFuncMembers,memberGroupSDict); ::addMembersToMemberGroup(&decFuncMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decVarMembers,memberGroupSDict); ::addMembersToMemberGroup(&decVarMembers,memberGroupSDict,this);
} }
/*! Adds member definition \a md to the list of all members of this file */ /*! Adds member definition \a md to the list of all members of this file */
......
...@@ -160,13 +160,13 @@ void GroupDef::addExample(const PageInfo *def) ...@@ -160,13 +160,13 @@ void GroupDef::addExample(const PageInfo *def)
void GroupDef::addMembersToMemberGroup() void GroupDef::addMembersToMemberGroup()
{ {
::addMembersToMemberGroup(&decDefineMembers,memberGroupSDict); ::addMembersToMemberGroup(&decDefineMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decProtoMembers,memberGroupSDict); ::addMembersToMemberGroup(&decProtoMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decTypedefMembers,memberGroupSDict); ::addMembersToMemberGroup(&decTypedefMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decEnumMembers,memberGroupSDict); ::addMembersToMemberGroup(&decEnumMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decEnumValMembers,memberGroupSDict); ::addMembersToMemberGroup(&decEnumValMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decFuncMembers,memberGroupSDict); ::addMembersToMemberGroup(&decFuncMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decVarMembers,memberGroupSDict); ::addMembersToMemberGroup(&decVarMembers,memberGroupSDict,this);
//printf("GroupDef::addMembersToMemberGroup() memberGroupList=%d\n",memberGroupList->count()); //printf("GroupDef::addMembersToMemberGroup() memberGroupList=%d\n",memberGroupList->count());
MemberGroupSDict::Iterator mgli(*memberGroupSDict); MemberGroupSDict::Iterator mgli(*memberGroupSDict);
......
...@@ -62,7 +62,7 @@ static const char *defaultStyleSheet = ...@@ -62,7 +62,7 @@ static const char *defaultStyleSheet =
"TD.mdname { background-color: #f2f2ff; font-weight: bold; color: #602020; width: 600px; }\n" "TD.mdname { background-color: #f2f2ff; font-weight: bold; color: #602020; width: 600px; }\n"
"DIV.groupHeader { margin-left: 16px; margin-top: 12px; margin-bottom: 6px; font-weight: bold }\n" "DIV.groupHeader { margin-left: 16px; margin-top: 12px; margin-bottom: 6px; font-weight: bold }\n"
"DIV.groupText { margin-left: 16px; font-style: italic; font-size: smaller }\n" "DIV.groupText { margin-left: 16px; font-style: italic; font-size: smaller }\n"
"BODY { background: white }\n" "BODY { background: white; color: black }\n"
"TD.indexkey { \n" "TD.indexkey { \n"
" background-color: #eeeeff; \n" " background-color: #eeeeff; \n"
" font-weight: bold; \n" " font-weight: bold; \n"
......
...@@ -58,7 +58,7 @@ MemberGroup::~MemberGroup() ...@@ -58,7 +58,7 @@ MemberGroup::~MemberGroup()
delete memberList; delete memberList;
} }
void MemberGroup::insertMember(Definition *d,MemberDef *md) void MemberGroup::insertMember(MemberDef *md)
{ {
//printf("MemberGroup::insertMember memberList=%p count=%d" //printf("MemberGroup::insertMember memberList=%p count=%d"
// " member section list: %p\n", // " member section list: %p\n",
...@@ -67,13 +67,13 @@ void MemberGroup::insertMember(Definition *d,MemberDef *md) ...@@ -67,13 +67,13 @@ void MemberGroup::insertMember(Definition *d,MemberDef *md)
// md->getSectionList()); // md->getSectionList());
MemberDef *firstMd = memberList->first(); MemberDef *firstMd = memberList->first();
if (inSameSection && memberList->count()>0 && if (inSameSection && memberList->count()>0 &&
firstMd->getSectionList(d)!=md->getSectionList(d)) firstMd->getSectionList(m_parent)!=md->getSectionList(m_parent))
{ {
inSameSection=FALSE; inSameSection=FALSE;
} }
else if (inDeclSection==0) else if (inDeclSection==0)
{ {
inDeclSection = md->getSectionList(d); inDeclSection = md->getSectionList(m_parent);
} }
memberList->append(md); memberList->append(md);
......
...@@ -41,7 +41,7 @@ class MemberGroup ...@@ -41,7 +41,7 @@ class MemberGroup
~MemberGroup(); ~MemberGroup();
QCString header() const { return grpHeader; } QCString header() const { return grpHeader; }
int groupId() const { return grpId; } int groupId() const { return grpId; }
void insertMember(Definition *d,MemberDef *md); void insertMember(MemberDef *md);
void setAnchors(ClassDef *); void setAnchors(ClassDef *);
void writePlainDeclarations(OutputList &ol, void writePlainDeclarations(OutputList &ol,
ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd); ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd);
......
...@@ -129,12 +129,12 @@ void NamespaceDef::insertNamespace(NamespaceDef *nd) ...@@ -129,12 +129,12 @@ void NamespaceDef::insertNamespace(NamespaceDef *nd)
void NamespaceDef::addMembersToMemberGroup() void NamespaceDef::addMembersToMemberGroup()
{ {
::addMembersToMemberGroup(&decDefineMembers,memberGroupSDict); ::addMembersToMemberGroup(&decDefineMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decProtoMembers,memberGroupSDict); ::addMembersToMemberGroup(&decProtoMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decTypedefMembers,memberGroupSDict); ::addMembersToMemberGroup(&decTypedefMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decEnumMembers,memberGroupSDict); ::addMembersToMemberGroup(&decEnumMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decFuncMembers,memberGroupSDict); ::addMembersToMemberGroup(&decFuncMembers,memberGroupSDict,this);
::addMembersToMemberGroup(&decVarMembers,memberGroupSDict); ::addMembersToMemberGroup(&decVarMembers,memberGroupSDict,this);
} }
void NamespaceDef::insertMember(MemberDef *md) void NamespaceDef::insertMember(MemberDef *md)
......
...@@ -2475,6 +2475,16 @@ bool resolveRef(/* in */ const char *scName, ...@@ -2475,6 +2475,16 @@ bool resolveRef(/* in */ const char *scName,
*resContext=gd; *resContext=gd;
return TRUE; return TRUE;
} }
else if (tsName.find('.')!=-1) // maybe a link to a file
{
bool ambig;
fd=findFileDef(Doxygen::inputNameDict,tsName,ambig);
if (fd && !ambig)
{
*resContext=fd;
return TRUE;
}
}
return FALSE; return FALSE;
} }
...@@ -3135,6 +3145,7 @@ void addMembersToMemberGroup(MemberList *ml, ...@@ -3135,6 +3145,7 @@ void addMembersToMemberGroup(MemberList *ml,
MemberGroupSDict *memberGroupSDict, MemberGroupSDict *memberGroupSDict,
Definition *context) Definition *context)
{ {
ASSERT(context!=0);
//printf("addMemberToMemberGroup()\n"); //printf("addMemberToMemberGroup()\n");
MemberListIterator mli(*ml); MemberListIterator mli(*ml);
MemberDef *md; MemberDef *md;
...@@ -3169,7 +3180,7 @@ void addMembersToMemberGroup(MemberList *ml, ...@@ -3169,7 +3180,7 @@ void addMembersToMemberGroup(MemberList *ml,
); );
memberGroupSDict->append(groupId,mg); memberGroupSDict->append(groupId,mg);
} }
mg->insertMember(context,fmd); // insert in member group mg->insertMember(fmd); // insert in member group
fmd->setMemberGroup(mg); fmd->setMemberGroup(mg);
} }
} }
...@@ -3198,7 +3209,7 @@ void addMembersToMemberGroup(MemberList *ml, ...@@ -3198,7 +3209,7 @@ void addMembersToMemberGroup(MemberList *ml,
memberGroupSDict->append(groupId,mg); memberGroupSDict->append(groupId,mg);
} }
md = ml->take(index); // remove from member list md = ml->take(index); // remove from member list
mg->insertMember(context,md); // insert in member group mg->insertMember(md); // insert in member group
md->setMemberGroup(mg); md->setMemberGroup(mg);
continue; continue;
} }
......
...@@ -171,7 +171,7 @@ QCString convertToXML(const char *s); ...@@ -171,7 +171,7 @@ QCString convertToXML(const char *s);
const char * getOverloadDocs(); const char * getOverloadDocs();
void addMembersToMemberGroup(MemberList *ml, void addMembersToMemberGroup(MemberList *ml,
MemberGroupSDict *memberGroupSDict, MemberGroupSDict *memberGroupSDict,
Definition *context=0); Definition *context);
bool extractClassNameFromType(const QCString &type,int &pos, bool extractClassNameFromType(const QCString &type,int &pos,
QCString &name,QCString &templSpec); QCString &name,QCString &templSpec);
QCString substituteTemplateArgumentsInString( QCString substituteTemplateArgumentsInString(
......
...@@ -53,6 +53,16 @@ inline void writeXMLString(QTextStream &t,const char *s) ...@@ -53,6 +53,16 @@ inline void writeXMLString(QTextStream &t,const char *s)
t << convertToXML(s); t << convertToXML(s);
} }
inline void writeXMLCodeString(QTextStream &t,const char *s)
{
char c;
while ((c=*s++))
{
if (c==' ') t << "<sp/>"; else t << c;
}
}
static void writeXMLHeader(QTextStream &t) static void writeXMLHeader(QTextStream &t)
{ {
QCString dtdName = Config_getString("XML_DTD"); QCString dtdName = Config_getString("XML_DTD");
...@@ -178,7 +188,7 @@ class XMLCodeGenerator : public BaseCodeDocInterface ...@@ -178,7 +188,7 @@ class XMLCodeGenerator : public BaseCodeDocInterface
m_t << "<highlight class=\"normal\">"; m_t << "<highlight class=\"normal\">";
m_normalHLNeedStartTag=FALSE; m_normalHLNeedStartTag=FALSE;
} }
writeXMLString(m_t,text); writeXMLCodeString(m_t,text);
} }
void writeCodeLink(const char *ref,const char *file, void writeCodeLink(const char *ref,const char *file,
const char *anchor,const char *text) const char *anchor,const char *text)
......
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