Commit e1fea278 authored by dimitri's avatar dimitri

Release-1.2.13-20020203

parent 8efa01a9
DOXYGEN Version 1.2.13-20020121 DOXYGEN Version 1.2.13-20020203
Please read the installation section of the manual for instructions. Please read the installation section of the manual for instructions.
-------- --------
Dimitri van Heesch (21 January 2002) Dimitri van Heesch (03 February 2002)
DOXYGEN Version 1.2.13_20020121 DOXYGEN Version 1.2.13_20020203
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) (21 January 2002) Dimitri van Heesch (dimitri@stack.nl) (03 February 2002)
1.2.13-20020121 1.2.13-20020203
...@@ -1113,7 +1113,7 @@ ALIASES = "english=\if english" \ ...@@ -1113,7 +1113,7 @@ ALIASES = "english=\if english" \
\sa \sa
Section \ref cmdpage "\\page" for an example of the Section \ref cmdpage "\\page" for an example of the
\ref cmdsubsection "\\cmdsubsection" command. \ref cmdsubsection "\\subsection" command.
<hr> <hr>
......
...@@ -166,7 +166,7 @@ Thanks go to: ...@@ -166,7 +166,7 @@ Thanks go to:
for rendering the logos. for rendering the logos.
<li>Harm van der Heijden for adding HTML help support. <li>Harm van der Heijden for adding HTML help support.
<li>Wouter Slegers for registering the www.doxygen.org domain. <li>Wouter Slegers for registering the www.doxygen.org domain.
<li>Parker Waerchter for adding the RTF output generator. <li>Parker Waechter for adding the RTF output generator.
<li>Joerg Baumann, for adding conditional documentation blocks, <li>Joerg Baumann, for adding conditional documentation blocks,
PDF links, and the configuration generator. PDF links, and the configuration generator.
<li>Matthias Andree for providing a .spec script for building rpms from the <li>Matthias Andree for providing a .spec script for building rpms from the
......
...@@ -66,7 +66,7 @@ tools should be installed. ...@@ -66,7 +66,7 @@ tools should be installed.
\latexonly(see {\tt http://www.research.att.com/sw/tools/graphviz/})\endlatexonly. \latexonly(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.
\note 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 dot will produce a warning that it cannot find doxfont!
<li>The ghostscript interpreter. <li>The ghostscript interpreter.
...@@ -210,6 +210,18 @@ instead of the <code>export</code> command above. ...@@ -210,6 +210,18 @@ instead of the <code>export</code> command above.
Now install doxygen as described above. Now install doxygen as described above.
<b>Bison problems</b>
Versions 1.31 and 1.32 of bison contain a "bug" that results in a
compiler error like this:
ce_parse.cpp:348: member `class CPPValue yyalloc::yyvs' with
constructor not allowed in union
There is no real solution to this problem, but it is discussed on the
bison mailing list. I recomment to use version 1.29 until the problems
with bison are resolved.
<b>Latex problems</b> <b>Latex problems</b>
The file <code>a4wide.sty</code> is not available for all distributions. If The file <code>a4wide.sty</code> is not available for all distributions. If
......
...@@ -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.2.13.1), 25 languages Currently (version 1.2.13-20020121), 25 languages
are supported (sorted alphabetically): are supported (sorted alphabetically):
Brazilian Portuguese, Chinese, Croatian, Czech, Danish, Brazilian Portuguese, Chinese, Croatian, Czech, Danish,
Dutch, English, Finnish, French, German, Dutch, English, Finnish, French, German,
...@@ -60,7 +60,7 @@ when the translator was updated. ...@@ -60,7 +60,7 @@ when the translator was updated.
<TD>Chinese</TD> <TD>Chinese</TD>
<TD>Wei Liu<br>Wang Weihan</TD> <TD>Wei Liu<br>Wang Weihan</TD>
<TD>liuwei@NOSPAM.asiainfo.com<br>wangweihan@NOSPAM.capinfo.com.cn</TD> <TD>liuwei@NOSPAM.asiainfo.com<br>wangweihan@NOSPAM.capinfo.com.cn</TD>
<TD>up-to-date</TD> <TD>1.2.13</TD>
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
<TD>Croatian</TD> <TD>Croatian</TD>
...@@ -72,7 +72,7 @@ when the translator was updated. ...@@ -72,7 +72,7 @@ when the translator was updated.
<TD>Czech</TD> <TD>Czech</TD>
<TD>Petr P&#x0159;ikryl</TD> <TD>Petr P&#x0159;ikryl</TD>
<TD>prikrylp@NOSPAM.skil.cz</TD> <TD>prikrylp@NOSPAM.skil.cz</TD>
<TD>up-to-date</TD> <TD>1.2.13</TD>
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
<TD>Danish</TD> <TD>Danish</TD>
...@@ -108,7 +108,7 @@ when the translator was updated. ...@@ -108,7 +108,7 @@ when the translator was updated.
<TD>German</TD> <TD>German</TD>
<TD>Jens Seidel<br>Jens Breitenstein</TD> <TD>Jens Seidel<br>Jens Breitenstein</TD>
<TD>jensseidel@NOSPAM.users.sf.net<br>Jens.Breitenstein@NOSPAM.tlc.de</TD> <TD>jensseidel@NOSPAM.users.sf.net<br>Jens.Breitenstein@NOSPAM.tlc.de</TD>
<TD>up-to-date</TD> <TD>1.2.13</TD>
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
<TD>Greek</TD> <TD>Greek</TD>
...@@ -132,13 +132,13 @@ when the translator was updated. ...@@ -132,13 +132,13 @@ when the translator was updated.
<TD>Japanese</TD> <TD>Japanese</TD>
<TD>Ryunosuke Sato<br>Kenji Nagamatsu</TD> <TD>Ryunosuke Sato<br>Kenji Nagamatsu</TD>
<TD>puyo@NOSPAM.mint.freemail.ne.jp<br>naga@NOSPAM.joyful.club.ne.jp</TD> <TD>puyo@NOSPAM.mint.freemail.ne.jp<br>naga@NOSPAM.joyful.club.ne.jp</TD>
<TD>up-to-date</TD> <TD>1.2.13</TD>
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
<TD>Korean</TD> <TD>Korean</TD>
<TD>Richard Kim</TD> <TD>Richard Kim</TD>
<TD>ryk@NOSPAM.dspwiz.com</TD> <TD>ryk@NOSPAM.dspwiz.com</TD>
<TD>up-to-date</TD> <TD>1.2.13</TD>
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
<TD>Norwegian</TD> <TD>Norwegian</TD>
...@@ -156,7 +156,7 @@ when the translator was updated. ...@@ -156,7 +156,7 @@ when the translator was updated.
<TD>Portuguese</TD> <TD>Portuguese</TD>
<TD>Rui Godinho Lopes</TD> <TD>Rui Godinho Lopes</TD>
<TD>ruiglopes@NOSPAM.yahoo.com</TD> <TD>ruiglopes@NOSPAM.yahoo.com</TD>
<TD>up-to-date</TD> <TD>1.2.13</TD>
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
<TD>Romanian</TD> <TD>Romanian</TD>
...@@ -174,13 +174,13 @@ when the translator was updated. ...@@ -174,13 +174,13 @@ when the translator was updated.
<TD>Slovak</TD> <TD>Slovak</TD>
<TD>Stanislav Kudl&aacute;&#x010d;</TD> <TD>Stanislav Kudl&aacute;&#x010d;</TD>
<TD>skudlac@NOSPAM.pobox.sk</TD> <TD>skudlac@NOSPAM.pobox.sk</TD>
<TD>up-to-date</TD> <TD>1.2.13</TD>
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
<TD>Slovene</TD> <TD>Slovene</TD>
<TD>Matjaz Ostroversnik</TD> <TD>Matjaz Ostroversnik</TD>
<TD>matjaz.ostroversnik@NOSPAM.zrs-tk.si</TD> <TD>matjaz.ostroversnik@NOSPAM.zrs-tk.si</TD>
<TD>up-to-date</TD> <TD>1.2.13</TD>
</TR> </TR>
<TR BGCOLOR="#ffffff"> <TR BGCOLOR="#ffffff">
<TD>Spanish</TD> <TD>Spanish</TD>
...@@ -213,12 +213,12 @@ when the translator was updated. ...@@ -213,12 +213,12 @@ when the translator was updated.
\hline \hline
Brazilian & Fabio "FJTC" Jun Takada Chino & {\tt chino@icmc.sc.usp.br} & up-to-date \\ Brazilian & Fabio "FJTC" Jun Takada Chino & {\tt chino@icmc.sc.usp.br} & up-to-date \\
\hline \hline
Chinese & Wei Liu & {\tt liuwei@asiainfo.com} & up-to-date \\ Chinese & Wei Liu & {\tt liuwei@asiainfo.com} & 1.2.13 \\
& Wang Weihan & {\tt wangweihan@capinfo.com.cn} & \\ & Wang Weihan & {\tt wangweihan@capinfo.com.cn} & \\
\hline \hline
Croatian & Boris Bralo & {\tt boris.bralo@zg.tel.hr} & up-to-date \\ Croatian & Boris Bralo & {\tt boris.bralo@zg.tel.hr} & up-to-date \\
\hline \hline
Czech & Petr P\v{r}ikryl & {\tt prikrylp@skil.cz} & up-to-date \\ Czech & Petr P\v{r}ikryl & {\tt prikrylp@skil.cz} & 1.2.13 \\
\hline \hline
Danish & Erik S\o{}e S\o{}rensen & {\tt erik@mail.nu} & 1.2.7 \\ Danish & Erik S\o{}e S\o{}rensen & {\tt erik@mail.nu} & 1.2.7 \\
\hline \hline
...@@ -230,7 +230,7 @@ when the translator was updated. ...@@ -230,7 +230,7 @@ when the translator was updated.
\hline \hline
French & Xavier Outhier & {\tt xouthier@yahoo.fr} & up-to-date \\ French & Xavier Outhier & {\tt xouthier@yahoo.fr} & up-to-date \\
\hline \hline
German & Jens Seidel & {\tt jensseidel@users.sf.net} & up-to-date \\ German & Jens Seidel & {\tt jensseidel@users.sf.net} & 1.2.13 \\
& Jens Breitenstein & {\tt Jens.Breitenstein@tlc.de} & \\ & Jens Breitenstein & {\tt Jens.Breitenstein@tlc.de} & \\
\hline \hline
Greek & Harry Kalogirou & {\tt harkal@rainbow.cs.unipi.gr} & 1.2.11 \\ Greek & Harry Kalogirou & {\tt harkal@rainbow.cs.unipi.gr} & 1.2.11 \\
...@@ -240,24 +240,24 @@ when the translator was updated. ...@@ -240,24 +240,24 @@ 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} & up-to-date \\ Japanese & Ryunosuke Sato & {\tt puyo@mint.freemail.ne.jp} & 1.2.13 \\
& 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} & up-to-date \\ Korean & Richard Kim & {\tt ryk@dspwiz.com} & 1.2.13 \\
\hline \hline
Norwegian & Lars Erik Jordet & {\tt larsej@stud.ifd.hibu.no} & 1.2.2 \\ Norwegian & Lars Erik Jordet & {\tt larsej@stud.ifd.hibu.no} & 1.2.2 \\
\hline \hline
Polish & Grzegorz Kowal & {\tt g\_kowal@poczta.onet.pl} & 1.2.1 \\ Polish & Grzegorz Kowal & {\tt g\_kowal@poczta.onet.pl} & 1.2.1 \\
\hline \hline
Portuguese & Rui Godinho Lopes & {\tt ruiglopes@yahoo.com} & up-to-date \\ Portuguese & Rui Godinho Lopes & {\tt ruiglopes@yahoo.com} & 1.2.13 \\
\hline \hline
Romanian & Alexandru Iosup & {\tt aiosup@yahoo.com} & 1.2.1 \\ Romanian & Alexandru Iosup & {\tt aiosup@yahoo.com} & 1.2.1 \\
\hline \hline
Russian & Alexandr Chelpanov & {\tt cav@cryptopro.ru} & up-to-date \\ Russian & Alexandr Chelpanov & {\tt cav@cryptopro.ru} & up-to-date \\
\hline \hline
Slovak & Stanislav Kudl\'{a}\v{c} & {\tt skudlac@pobox.sk} & up-to-date \\ Slovak & Stanislav Kudl\'{a}\v{c} & {\tt skudlac@pobox.sk} & 1.2.13 \\
\hline \hline
Slovene & Matjaz Ostroversnik & {\tt matjaz.ostroversnik@zrs-tk.si} & up-to-date \\ Slovene & Matjaz Ostroversnik & {\tt matjaz.ostroversnik@zrs-tk.si} & 1.2.13 \\
\hline \hline
Spanish & Francisco Oltra Thennet & {\tt foltra@puc.cl} & 1.2.7 \\ Spanish & Francisco Oltra Thennet & {\tt foltra@puc.cl} & 1.2.7 \\
\hline \hline
......
...@@ -110,6 +110,14 @@ ...@@ -110,6 +110,14 @@
# The older translator adapters are derived from newer ones. # The older translator adapters are derived from newer ones.
# The mistaken comment said the opposite. # The mistaken comment said the opposite.
# #
# 2002/01/23
# - The nasty bug corrected. GetAdapterClassesInfo() did not
# strip trailing blanks from the method prototype; consequently,
# the required methods implemented by a translator adapter was
# not recognized as the required one (i.e. not listed).
# - Some defined() operators used on hash elements were replaced
# by exists() operators where appropriate.
#
################################################################ ################################################################
use 5.005; use 5.005;
...@@ -421,10 +429,15 @@ sub GetAdapterClassesInfo ##{{{ ...@@ -421,10 +429,15 @@ sub GetAdapterClassesInfo ##{{{
# #
$cont =~ s{\n\s*\n}{\n}sg; $cont =~ s{\n\s*\n}{\n}sg;
# Trim the spaces.
#
$cont =~ s{^\s+}{}mg;
$cont =~ s{\s+$}{}mg;
# Split the string into the lines again. # Split the string into the lines again.
# #
@content = split(/\n/, $cont); @content = split(/\n/, $cont);
# Now the list contains only two kinds of lines. The first # Now the list contains only two kinds of lines. The first
# kind of lines starts with the <class> tag and contains the # kind of lines starts with the <class> tag and contains the
# identifier of the class. The following lines list the # identifier of the class. The following lines list the
...@@ -474,8 +487,8 @@ sub GetAdapterClassesInfo ##{{{ ...@@ -474,8 +487,8 @@ sub GetAdapterClassesInfo ##{{{
# string of methods. # string of methods.
# #
my $stripped_prototype = StripArgIdentifiers($line); my $stripped_prototype = StripArgIdentifiers($line);
if (defined $$reqref{$stripped_prototype}) if (exists($$reqref{$stripped_prototype}))
{ {
++$cnt; ++$cnt;
$methods .= " $line\n"; $methods .= " $line\n";
...@@ -498,11 +511,11 @@ sub GetAdapterClassesInfo ##{{{ ...@@ -498,11 +511,11 @@ sub GetAdapterClassesInfo ##{{{
# Return the result list. # Return the result list.
# #
# push @result, $cont; # ???
return @result; return @result;
} }
##}}} ##}}}
################################################################ ################################################################
# GenerateLanguageDoc takes document templates and code sources # GenerateLanguageDoc takes document templates and code sources
# generates the content as expected in the $flangdoc file (the # generates the content as expected in the $flangdoc file (the
...@@ -656,7 +669,7 @@ xxxTABLE_FOOTxxx ...@@ -656,7 +669,7 @@ xxxTABLE_FOOTxxx
# was not defined in sources, add the question mark to the # was not defined in sources, add the question mark to the
# language identifier. # language identifier.
# #
if (defined $language{$lang}) { if (exists($language{$lang})) {
$language{$lang} = $$rcb{"Translator$lang"} . '<msep/>' $language{$lang} = $$rcb{"Translator$lang"} . '<msep/>'
. join("<sep/>", @info); . join("<sep/>", @info);
} }
...@@ -1053,8 +1066,8 @@ print STDERR "\n\n"; ...@@ -1053,8 +1066,8 @@ print STDERR "\n\n";
# Otherwise, remember it as old method which is # Otherwise, remember it as old method which is
# implemented, but not required. # implemented, but not required.
# #
if (defined $required{$prototype}) { if (exists($required{$prototype})) {
$required{$prototype} = 0; $required{$prototype} = 0; # satisfaction
} }
else { else {
push(@old_methods, $implemented); push(@old_methods, $implemented);
......
Summary: A documentation system for C/C++. Summary: A documentation system for C/C++.
Name: doxygen Name: doxygen
Version: 1.2.13_20020121 Version: 1.2.13_20020203
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
......
...@@ -1580,7 +1580,6 @@ bool ClassDef::isLinkableInProject() const ...@@ -1580,7 +1580,6 @@ bool ClassDef::isLinkableInProject() const
else else
{ {
return !name().isEmpty() && /* no name */ return !name().isEmpty() && /* no name */
//m_isTemplBaseClass==-1 && /* template base class */
!m_artificial && !m_artificial &&
name().find('@')==-1 && /* anonymous compound */ name().find('@')==-1 && /* anonymous compound */
(m_prot!=Private || Config_getBool("EXTRACT_PRIVATE")) && /* private */ (m_prot!=Private || Config_getBool("EXTRACT_PRIVATE")) && /* private */
...@@ -1635,7 +1634,7 @@ bool ClassDef::hasDocumentation() const ...@@ -1635,7 +1634,7 @@ bool ClassDef::hasDocumentation() const
// returns TRUE iff class definition `bcd' represents an (in)direct base // returns TRUE iff class definition `bcd' represents an (in)direct base
// class of class definition `cd'. // class of class definition `cd'.
bool ClassDef::isBaseClass(ClassDef *bcd) bool ClassDef::isBaseClass(ClassDef *bcd, bool followInstances)
{ {
bool found=FALSE; bool found=FALSE;
//printf("isBaseClass(cd=%s) looking for %s\n",cd->name().data(),bcd->name().data()); //printf("isBaseClass(cd=%s) looking for %s\n",cd->name().data(),bcd->name().data());
...@@ -1643,12 +1642,12 @@ bool ClassDef::isBaseClass(ClassDef *bcd) ...@@ -1643,12 +1642,12 @@ bool ClassDef::isBaseClass(ClassDef *bcd)
for ( ; bcli.current() && !found ; ++bcli) for ( ; bcli.current() && !found ; ++bcli)
{ {
ClassDef *ccd=bcli.current()->classDef; ClassDef *ccd=bcli.current()->classDef;
if (ccd->templateMaster()) ccd=ccd->templateMaster(); if (!followInstances && ccd->templateMaster()) ccd=ccd->templateMaster();
//printf("isBaseClass() baseclass %s\n",ccd->name().data()); //printf("isBaseClass() baseclass %s\n",ccd->name().data());
if (ccd==bcd) if (ccd==bcd)
found=TRUE; found=TRUE;
else else
found=ccd->isBaseClass(bcd); found=ccd->isBaseClass(bcd,followInstances);
} }
return found; return found;
} }
...@@ -1719,7 +1718,7 @@ void ClassDef::mergeMembers() ...@@ -1719,7 +1718,7 @@ void ClassDef::mergeMembers()
{ {
ClassDef *dstCd = dstMd->getClassDef(); ClassDef *dstCd = dstMd->getClassDef();
//printf(" Is %s a base class of %s?\n",srcCd->name().data(),dstCd->name().data()); //printf(" Is %s a base class of %s?\n",srcCd->name().data(),dstCd->name().data());
if (srcCd==dstCd || dstCd->isBaseClass(srcCd)) if (srcCd==dstCd || dstCd->isBaseClass(srcCd,TRUE))
// member is in the same or a base class // member is in the same or a base class
{ {
found=matchArguments(srcMd->argumentList(), found=matchArguments(srcMd->argumentList(),
...@@ -1731,7 +1730,7 @@ void ClassDef::mergeMembers() ...@@ -1731,7 +1730,7 @@ void ClassDef::mergeMembers()
hidden = hidden || !found; hidden = hidden || !found;
} }
else // member is in a non base class => multiple inheritance else // member is in a non base class => multiple inheritance
// using the same base class. // using the same base class.
{ {
//printf("$$ Existing member %s %s add scope %s\n", //printf("$$ Existing member %s %s add scope %s\n",
// dstMi->ambiguityResolutionScope.data(), // dstMi->ambiguityResolutionScope.data(),
...@@ -1748,7 +1747,8 @@ void ClassDef::mergeMembers() ...@@ -1748,7 +1747,8 @@ void ClassDef::mergeMembers()
{ {
// do not add if base class is virtual or // do not add if base class is virtual or
// if scope paths are equal // if scope paths are equal
if ((srcMi->virt==Virtual && dstMi->virt==Virtual) || //printf("same member found srcMi->virt=%d dstMi->virt=%d\n",srcMi->virt,dstMi->virt);
if ((srcMi->virt!=Normal && dstMi->virt!=Normal) ||
bClass->name()+"::"+srcMi->scopePath == dstMi->scopePath bClass->name()+"::"+srcMi->scopePath == dstMi->scopePath
) )
{ {
......
...@@ -151,7 +151,7 @@ class ClassDef : public Definition ...@@ -151,7 +151,7 @@ class ClassDef : public Definition
* class. This function will recusively traverse all branches of the * class. This function will recusively traverse all branches of the
* inheritance tree. * inheritance tree.
*/ */
bool isBaseClass(ClassDef *bcd); bool isBaseClass(ClassDef *bcd,bool followInstances);
/*! Returns a sorted dictionary with all template instances found for /*! Returns a sorted dictionary with all template instances found for
* this template class. Returns 0 if not a template or no instances. * this template class. Returns 0 if not a template or no instances.
...@@ -279,8 +279,6 @@ class ClassDef : public Definition ...@@ -279,8 +279,6 @@ class ClassDef : public Definition
void addListReferences(); void addListReferences();
/*! Creates a new compound definition. /*! Creates a new compound definition.
* \param outerScope class, file or namespace in which this class is
* defined.
* \param fileName full path and file name in which this compound was * \param fileName full path and file name in which this compound was
* found. * found.
* \param startLine line number where the definition of this compound * \param startLine line number where the definition of this compound
......
...@@ -1092,17 +1092,13 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned" ...@@ -1092,17 +1092,13 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
g_code->codify(yytext); g_code->codify(yytext);
// TODO: remove
g_inClass=FALSE; g_inClass=FALSE;
if (--g_curlyCount<=0)
{
//g_classScope.resize(0);
//g_codeParmList.clear();
}
if (--g_bodyCurlyCount<=0) if (--g_bodyCurlyCount<=0)
{ {
g_insideBody=FALSE; g_insideBody=FALSE;
g_currentMemberDef=0;
g_currentDefinition=0;
} }
} }
<ClassName,ClassVar>";" { <ClassName,ClassVar>";" {
......
...@@ -102,8 +102,17 @@ void Definition::writeDocAnchorsToTagFile() ...@@ -102,8 +102,17 @@ void Definition::writeDocAnchorsToTagFile()
} }
} }
void Definition::setDocumentation(const char *d,const char *docFile,int docLine,bool stripWhiteSpace=TRUE)
{
if (stripWhiteSpace)
m_doc=((QCString)d).stripWhiteSpace();
else
m_doc=d;
m_docFile = docFile;
m_docLine = docLine;
}
void Definition::setBriefDescription(const char *b) void Definition::setBriefDescription(const char *b,const char *briefFile,int briefLine)
{ {
m_brief=QCString(b).stripWhiteSpace(); m_brief=QCString(b).stripWhiteSpace();
int bl=m_brief.length(); int bl=m_brief.length();
...@@ -115,6 +124,8 @@ void Definition::setBriefDescription(const char *b) ...@@ -115,6 +124,8 @@ void Definition::setBriefDescription(const char *b)
default: m_brief+='.'; break; default: m_brief+='.'; break;
} }
} }
m_briefFile = briefFile;
m_briefLine = briefLine;
} }
/*! Reads a fragment of code from file \a fileName starting at /*! Reads a fragment of code from file \a fileName starting at
......
...@@ -64,17 +64,15 @@ class Definition ...@@ -64,17 +64,15 @@ class Definition
/*! Sets a new \a name for the definition */ /*! Sets a new \a name for the definition */
void setName(const char *name) { m_name=name; } void setName(const char *name) { m_name=name; }
/*! Sets the documentation of this definition to \a d. */ /*! Sets the documentation of this definition to \a d. */
void setDocumentation(const char *d,bool stripWhiteSpace=TRUE) void setDocumentation(const char *d,const char *docFile,int docLine,bool stripWhiteSpace=TRUE);
{ int docLine() const { return m_docLine; }
if (stripWhiteSpace) QCString docFile() const { return m_docFile; }
m_doc=((QCString)d).stripWhiteSpace();
else
m_doc=d;
}
/*! Sets the brief description of this definition to \a b. /*! Sets the brief description of this definition to \a b.
* A dot is added to the sentence if not available. * A dot is added to the sentence if not available.
*/ */
void setBriefDescription(const char *b); void setBriefDescription(const char *b,const char *briefFile,int briefLine);
int briefLine() const { return m_briefLine; }
QCString briefFile() const { return m_briefFile; }
/*! Returns TRUE iff the definition is documented */ /*! Returns TRUE iff the definition is documented */
virtual bool hasDocumentation() const; virtual bool hasDocumentation() const;
virtual bool isLinkableInProject() const = 0; virtual bool isLinkableInProject() const = 0;
...@@ -155,6 +153,10 @@ class Definition ...@@ -155,6 +153,10 @@ class Definition
int m_testId; // id for test list item int m_testId; // id for test list item
int m_todoId; // id for todo list item int m_todoId; // id for todo list item
int m_bugId; // id for bug list item int m_bugId; // id for bug list item
int m_docLine;
QCString m_docFile;
int m_briefLine;
QCString m_briefFile;
}; };
......
...@@ -21,10 +21,11 @@ ...@@ -21,10 +21,11 @@
#include "qtbc.h" #include "qtbc.h"
class OutputDocInterface; class OutputDocInterface;
class MemberDef;
extern void parseDoc(OutputDocInterface &ol, extern void parseDoc(OutputDocInterface &ol,
const char *fileName,int startLine, const char *fileName,int startLine,
const char *clName, const char *memName, const char *clName, MemberDef *md,
const QCString &docString); const QCString &docString);
extern void parseExample(OutputDocInterface &ol,const QCString &docString, extern void parseExample(OutputDocInterface &ol,const QCString &docString,
const char *fileName); const char *fileName);
......
...@@ -22,7 +22,6 @@ ...@@ -22,7 +22,6 @@
*/ */
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
//#include <iostream.h>
#include <assert.h> #include <assert.h>
#include <ctype.h> #include <ctype.h>
...@@ -51,10 +50,13 @@ ...@@ -51,10 +50,13 @@
* *
* scanner's state variables * scanner's state variables
*/ */
static MemberDef * memberDef;
static bool hasParamCommand;
static QDict<void> paramsFound;
static OutputDocInterface * outDoc; static OutputDocInterface * outDoc;
static bool insideArgumentList; static bool insideArgumentList;
static QCString className; static QCString className;
static QCString memberName;
static QCString linkRef; static QCString linkRef;
static QCString linkText; static QCString linkText;
static QCString codeBlock; static QCString codeBlock;
...@@ -109,7 +111,6 @@ static void initParser() ...@@ -109,7 +111,6 @@ static void initParser()
{ {
insideArgumentList=FALSE; insideArgumentList=FALSE;
className.resize(0); className.resize(0);
memberName.resize(0);
linkRef.resize(0); linkRef.resize(0);
linkText.resize(0); linkText.resize(0);
codeBlock.resize(0); codeBlock.resize(0);
...@@ -875,6 +876,44 @@ static void writeDotFile(const char *fileName, const char *captionText) ...@@ -875,6 +876,44 @@ static void writeDotFile(const char *fileName, const char *captionText)
} }
} }
/* ----------------------------------------------------------------- */
static void checkArgName(const QCString &name)
{
hasParamCommand=TRUE;
if (memberDef==0) return; // not a member
ArgumentList *al=memberDef->isDocsForDefinition() ?
memberDef->argumentList() :
memberDef->declArgumentList();
if (al==0) return; // no argument list
if (!Config_getBool("WARN_IF_UNDOCUMENTED")) return;
static QRegExp re("[a-zA-Z0-9_]+");
int p=0,i=0,l;
while ((i=re.match(name,p,&l))!=-1)
{
QCString aName=name.mid(i,l);
ArgumentListIterator ali(*al);
Argument *a;
for (ali.toFirst();(a=ali.current());++ali)
{
if (name==a->name)
{
paramsFound.insert(name,(void *)(0x8));
return;
}
}
QCString scope=memberDef->getScopeString();
if (!scope.isEmpty()) scope+="::"; else scope="";
warn(memberDef->docFile(),memberDef->docLine(),
"Warning: argument `%s' of command @param "
"is not found in the argument list of %s%s%s",
name.data(),scope.data(),memberDef->name().data(),
argListToString(al).data()
);
p=i+l;
}
}
/* ----------------------------------------------------------------- */ /* ----------------------------------------------------------------- */
#undef YY_INPUT #undef YY_INPUT
...@@ -911,7 +950,7 @@ SCOPEMASK {ID}?(("::"|"#")?(~)?{ID})+ ...@@ -911,7 +950,7 @@ SCOPEMASK {ID}?(("::"|"#")?(~)?{ID})+
URLCHAR [a-z_A-Z0-9\~\:\?\@\&\%\#\.\-\+\/\=] URLCHAR [a-z_A-Z0-9\~\:\?\@\&\%\#\.\-\+\/\=]
URLMASK ([a-z_A-Z][^\>\"\n]*{URLCHAR})|({URLCHAR}+) URLMASK ([a-z_A-Z][^\>\"\n]*{URLCHAR})|({URLCHAR}+)
NONTERM [\{\}\[\]\`\~\@\|\-\+\#\$\/\\\!\%\^\&\*()a-z_A-Z<>0-9\x80-\xff] NONTERM [\{\}\[\]\`\~\@\|\-\+\#\$\/\\\!\%\^\&\*()a-z_A-Z<>0-9\x80-\xff]
WORD ({NONTERM}+([^\n\t ]*{NONTERM}+)?)|("\""[^\n\"]"\"") WORD ({NONTERM}+([^\n\t ]*{NONTERM}+)?)|("\""[^\n\"]*"\"")
ATTR ({B}+[^>\n]*)? ATTR ({B}+[^>\n]*)?
A [aA] A [aA]
BOLD [bB] BOLD [bB]
...@@ -1631,8 +1670,10 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG}) ...@@ -1631,8 +1670,10 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
} }
<DocScan>"\\capt".* <DocScan>"\\capt".*
<DocParam>({DOCPARAM}{BN}*","{BN}*)*{DOCPARAM}{BSEP}* { <DocParam>({DOCPARAM}{BN}*","{BN}*)*{DOCPARAM}{BSEP}* {
QCString argName = substitute(yytext,"\"","").stripWhiteSpace();
if (inParamBlock) checkArgName(argName);
outDoc->startDescTableTitle(); outDoc->startDescTableTitle();
scanDoc(substitute(yytext,"\"","").stripWhiteSpace()); scanDoc(argName);
outDoc->endDescTableTitle(); outDoc->endDescTableTitle();
outDoc->startDescTableData(); outDoc->startDescTableData();
BEGIN(DocScan); BEGIN(DocScan);
...@@ -2633,18 +2674,58 @@ void parseDocument(OutputDocInterface &od,const QCString &docString) ...@@ -2633,18 +2674,58 @@ void parseDocument(OutputDocInterface &od,const QCString &docString)
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------
void parseDoc(OutputDocInterface &od,const char *fileName,int startLine, void parseDoc(OutputDocInterface &od,const char *fileName,int startLine,
const char *clName,const char *memName,const QCString &docString) const char *clName,MemberDef *md,const QCString &docString)
{ {
//printf("parseDoc(file=`%s',line=%d)\n",fileName,startLine); //printf("parseDoc(file=`%s',line=%d)\n",fileName,startLine);
initParser(); initParser();
initParseCodeContext(); initParseCodeContext();
exampleDoc=FALSE; // do not cross reference with member docs exampleDoc=FALSE; // do not cross reference with member docs
className=clName; className=clName;
memberName=memName; memberDef = md;
hasParamCommand = FALSE;
paramsFound.setAutoDelete(FALSE);
paramsFound.clear();
strcpy(yyFileName,fileName); strcpy(yyFileName,fileName);
yyLineNr = startLine; yyLineNr = startLine;
parseDocument(od,docString); parseDocument(od,docString);
if (md && hasParamCommand && Config_getBool("WARN_IF_UNDOCUMENTED"))
{
ArgumentList *al=memberDef->isDocsForDefinition() ?
memberDef->argumentList() :
memberDef->declArgumentList();
if (al)
{
ArgumentListIterator ali(*al);
Argument *a;
bool found=FALSE;
for (ali.toFirst();(a=ali.current());++ali)
{
if (!a->name.isEmpty() && paramsFound.find(a->name)==0)
{
found = TRUE;
break;
}
}
if (found)
{
QCString scope=memberDef->getScopeString();
if (!scope.isEmpty()) scope+="::"; else scope="";
warn(memberDef->docFile(),memberDef->docLine(),
"Warning: The following parameters of "
"%s%s%s are not documented:",
scope.data(),memberDef->name().data(),
argListToString(al).data());
for (ali.toFirst();(a=ali.current());++ali)
{
if (!a->name.isEmpty() && paramsFound.find(a->name)==0)
{
warn_cont( " parameter %s\n",a->name.data());
}
}
}
}
}
} }
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------
......
...@@ -227,10 +227,11 @@ static void buildGroupList(Entry *root) ...@@ -227,10 +227,11 @@ static void buildGroupList(Entry *root)
"group %s: ignoring title \"%s\" that does not match old title \"%s\"\n", "group %s: ignoring title \"%s\" that does not match old title \"%s\"\n",
root->name.data(), root->type.data(), gd->groupTitle() ); root->name.data(), root->type.data(), gd->groupTitle() );
if ( gd->briefDescription().isEmpty() ) if ( gd->briefDescription().isEmpty() )
gd->setBriefDescription(root->brief); gd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
if ( !root->doc.stripWhiteSpace().isEmpty() ) if ( !root->doc.stripWhiteSpace().isEmpty() )
gd->setDocumentation( gd->documentation().isEmpty() ? root->doc : gd->setDocumentation( gd->documentation().isEmpty() ? root->doc :
gd->documentation() + "\n\n" + root->doc ); gd->documentation() + "\n\n" + root->doc,
root->docFile, root->docLine );
gd->addSectionsToDefinition(root->anchors); gd->addSectionsToDefinition(root->anchors);
gd->setRefItems(root->todoId,root->testId,root->bugId); gd->setRefItems(root->todoId,root->testId,root->bugId);
addGroupToGroups(root,gd); addGroupToGroups(root,gd);
...@@ -243,8 +244,8 @@ static void buildGroupList(Entry *root) ...@@ -243,8 +244,8 @@ static void buildGroupList(Entry *root)
{ {
gd->setReference(root->tagInfo->tagName); gd->setReference(root->tagInfo->tagName);
} }
gd->setBriefDescription(root->brief); gd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
gd->setDocumentation(root->doc); gd->setDocumentation(root->doc,root->docFile,root->docLine);
gd->addSectionsToDefinition(root->anchors); gd->addSectionsToDefinition(root->anchors);
Doxygen::groupSDict.append(root->name,gd); Doxygen::groupSDict.append(root->name,gd);
gd->setRefItems(root->todoId,root->testId,root->bugId); gd->setRefItems(root->todoId,root->testId,root->bugId);
...@@ -305,8 +306,8 @@ static void buildFileList(Entry *root) ...@@ -305,8 +306,8 @@ static void buildFileList(Entry *root)
// using FALSE in setDocumentation is small hack to make sure a file // using FALSE in setDocumentation is small hack to make sure a file
// is documented even if a \file command is used without further // is documented even if a \file command is used without further
// documentation // documentation
fd->setDocumentation(root->doc,FALSE); fd->setDocumentation(root->doc,root->docFile,root->docLine,FALSE);
fd->setBriefDescription(root->brief); fd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
fd->addSectionsToDefinition(root->anchors); fd->addSectionsToDefinition(root->anchors);
fd->setRefItems(root->todoId,root->testId,root->bugId); fd->setRefItems(root->todoId,root->testId,root->bugId);
QListIterator<Grouping> gli(*root->groups); QListIterator<Grouping> gli(*root->groups);
...@@ -595,7 +596,7 @@ static void buildClassList(Entry *root) ...@@ -595,7 +596,7 @@ static void buildClassList(Entry *root)
} }
else if (!root->doc.isEmpty()) else if (!root->doc.isEmpty())
{ {
cd->setDocumentation(root->doc); cd->setDocumentation(root->doc,root->docFile,root->docLine);
} }
if (!root->brief.isEmpty() && !cd->briefDescription().isEmpty()) if (!root->brief.isEmpty() && !cd->briefDescription().isEmpty())
{ {
...@@ -608,7 +609,7 @@ static void buildClassList(Entry *root) ...@@ -608,7 +609,7 @@ static void buildClassList(Entry *root)
} }
else if (!root->brief.isEmpty()) else if (!root->brief.isEmpty())
{ {
cd->setBriefDescription(root->brief); cd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
} }
if (root->bodyLine!=-1 && cd->getStartBodyLine()==-1) if (root->bodyLine!=-1 && cd->getStartBodyLine()==-1)
{ {
...@@ -682,8 +683,8 @@ static void buildClassList(Entry *root) ...@@ -682,8 +683,8 @@ static void buildClassList(Entry *root)
} }
ClassDef *cd=new ClassDef(root->fileName,root->startLine,fullName,sec, ClassDef *cd=new ClassDef(root->fileName,root->startLine,fullName,sec,
tagName,refFileName); tagName,refFileName);
cd->setDocumentation(root->doc); // copy docs to definition cd->setDocumentation(root->doc,root->docFile,root->docLine); // copy docs to definition
cd->setBriefDescription(root->brief); cd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
//printf("new ClassDef %s tempArgList=%p specScope=%s\n",fullName.data(),root->tArgList,root->scopeSpec.data()); //printf("new ClassDef %s tempArgList=%p specScope=%s\n",fullName.data(),root->tArgList,root->scopeSpec.data());
...@@ -738,7 +739,7 @@ static void buildClassList(Entry *root) ...@@ -738,7 +739,7 @@ static void buildClassList(Entry *root)
} }
// the empty string test is needed for extract all case // the empty string test is needed for extract all case
cd->setBriefDescription(root->brief); cd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
cd->insertUsedFile(root->fileName); cd->insertUsedFile(root->fileName);
// add class to the list // add class to the list
...@@ -794,7 +795,7 @@ static void buildNamespaceList(Entry *root) ...@@ -794,7 +795,7 @@ static void buildNamespaceList(Entry *root)
{ {
if (nd->documentation().isEmpty() && !root->doc.isEmpty()) if (nd->documentation().isEmpty() && !root->doc.isEmpty())
{ {
nd->setDocumentation(root->doc); nd->setDocumentation(root->doc,root->docFile,root->docLine);
nd->setName(fullName); // change name to match docs nd->setName(fullName); // change name to match docs
nd->addSectionsToDefinition(root->anchors); nd->addSectionsToDefinition(root->anchors);
} }
...@@ -808,7 +809,7 @@ static void buildNamespaceList(Entry *root) ...@@ -808,7 +809,7 @@ static void buildNamespaceList(Entry *root)
} }
if (nd->briefDescription().isEmpty() && !root->brief.isEmpty()) if (nd->briefDescription().isEmpty() && !root->brief.isEmpty())
{ {
nd->setBriefDescription(root->brief); nd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
nd->setName(fullName); // change name to match docs nd->setName(fullName); // change name to match docs
} }
else if (!nd->briefDescription().isEmpty() && !root->brief.isEmpty()) else if (!nd->briefDescription().isEmpty() && !root->brief.isEmpty())
...@@ -837,8 +838,8 @@ static void buildNamespaceList(Entry *root) ...@@ -837,8 +838,8 @@ static void buildNamespaceList(Entry *root)
tagName=root->tagInfo->tagName; tagName=root->tagInfo->tagName;
} }
NamespaceDef *nd=new NamespaceDef(root->fileName,root->startLine,fullName,tagName); NamespaceDef *nd=new NamespaceDef(root->fileName,root->startLine,fullName,tagName);
nd->setDocumentation(root->doc); // copy docs to definition nd->setDocumentation(root->doc,root->docFile,root->docLine); // copy docs to definition
nd->setBriefDescription(root->brief); nd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
nd->addSectionsToDefinition(root->anchors); nd->addSectionsToDefinition(root->anchors);
//printf("Adding namespace to group\n"); //printf("Adding namespace to group\n");
...@@ -852,7 +853,7 @@ static void buildNamespaceList(Entry *root) ...@@ -852,7 +853,7 @@ static void buildNamespaceList(Entry *root)
if (fd) fd->insertNamespace(nd); if (fd) fd->insertNamespace(nd);
// the empty string test is needed for extract all case // the empty string test is needed for extract all case
nd->setBriefDescription(root->brief); nd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
nd->insertUsedFile(root->fileName); nd->insertUsedFile(root->fileName);
nd->setBodySegment(root->bodyLine,root->endBodyLine); nd->setBodySegment(root->bodyLine,root->endBodyLine);
nd->setBodyDef(fd); nd->setBodyDef(fd);
...@@ -955,8 +956,8 @@ static void findUsingDirectives(Entry *root) ...@@ -955,8 +956,8 @@ static void findUsingDirectives(Entry *root)
{ {
NamespaceDef *nd=new NamespaceDef( NamespaceDef *nd=new NamespaceDef(
root->fileName,root->startLine,root->name); root->fileName,root->startLine,root->name);
nd->setDocumentation(root->doc); // copy docs to definition nd->setDocumentation(root->doc,root->docFile,root->docLine); // copy docs to definition
nd->setBriefDescription(root->brief); nd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
nd->addSectionsToDefinition(root->anchors); nd->addSectionsToDefinition(root->anchors);
QListIterator<Grouping> gli(*root->groups); QListIterator<Grouping> gli(*root->groups);
...@@ -979,7 +980,7 @@ static void findUsingDirectives(Entry *root) ...@@ -979,7 +980,7 @@ static void findUsingDirectives(Entry *root)
} }
// the empty string test is needed for extract all case // the empty string test is needed for extract all case
nd->setBriefDescription(root->brief); nd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
nd->insertUsedFile(root->fileName); nd->insertUsedFile(root->fileName);
// add class to the list // add class to the list
Doxygen::namespaceSDict.inSort(root->name,nd); Doxygen::namespaceSDict.inSort(root->name,nd);
...@@ -1166,8 +1167,8 @@ static MemberDef *addVariableToClass( ...@@ -1166,8 +1167,8 @@ static MemberDef *addVariableToClass(
md->setMemberClass(cd); md->setMemberClass(cd);
//md->setDefFile(root->fileName); //md->setDefFile(root->fileName);
//md->setDefLine(root->startLine); //md->setDefLine(root->startLine);
md->setDocumentation(root->doc); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setBriefDescription(root->brief); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
md->setDefinition(def); md->setDefinition(def);
md->setBitfields(root->bitfields); md->setBitfields(root->bitfields);
md->addSectionsToDefinition(root->anchors); md->addSectionsToDefinition(root->anchors);
...@@ -1329,8 +1330,8 @@ static MemberDef *addVariableToFile( ...@@ -1329,8 +1330,8 @@ static MemberDef *addVariableToFile(
} }
//md->setDefFile(root->fileName); //md->setDefFile(root->fileName);
//md->setDefLine(root->startLine); //md->setDefLine(root->startLine);
md->setDocumentation(root->doc); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setBriefDescription(root->brief); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
md->addSectionsToDefinition(root->anchors); md->addSectionsToDefinition(root->anchors);
md->setFromAnonymousScope(fromAnnScope); md->setFromAnonymousScope(fromAnnScope);
md->setFromAnonymousMember(fromAnnMemb); md->setFromAnonymousMember(fromAnnMemb);
...@@ -1626,6 +1627,7 @@ void addNewMemberToClass(Entry *root,ClassDef *cd, ...@@ -1626,6 +1627,7 @@ void addNewMemberToClass(Entry *root,ClassDef *cd,
name=name.left(i); name=name.left(i);
} }
// adding class member
MemberDef *md=new MemberDef( MemberDef *md=new MemberDef(
root->fileName,root->startLine, root->fileName,root->startLine,
root->type,name,root->args,root->exception, root->type,name,root->args,root->exception,
...@@ -1637,8 +1639,9 @@ void addNewMemberToClass(Entry *root,ClassDef *cd, ...@@ -1637,8 +1639,9 @@ void addNewMemberToClass(Entry *root,ClassDef *cd,
md->setReference(root->tagInfo->tagName); md->setReference(root->tagInfo->tagName);
} }
md->setMemberClass(cd); md->setMemberClass(cd);
md->setDocumentation(root->doc); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setBriefDescription(root->brief); md->setDocsForDefinition(!root->proto);
md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
md->setBodySegment(root->bodyLine,root->endBodyLine); md->setBodySegment(root->bodyLine,root->endBodyLine);
md->setMemberSpecifiers(root->memSpec); md->setMemberSpecifiers(root->memSpec);
md->setMemberGroupId(root->mGrpId); md->setMemberGroupId(root->mGrpId);
...@@ -1746,7 +1749,7 @@ static void buildFunctionList(Entry *root) ...@@ -1746,7 +1749,7 @@ static void buildFunctionList(Entry *root)
{ {
Debug::print(Debug::Functions,0, Debug::print(Debug::Functions,0,
"FUNCTION_SEC:\n" "FUNCTION_SEC:\n"
" `%s' `%s'::`%s' `%s' relates=`%s' file=`%s' line=`%d' bodyLine=`%d' #tArgLists=%d mGrpId=%d memSpec=%d\n", " `%s' `%s'::`%s' `%s' relates=`%s' file=`%s' line=`%d' bodyLine=`%d' #tArgLists=%d mGrpId=%d memSpec=%d proto=%d\n",
root->type.data(), root->type.data(),
root->parent->name.data(), root->parent->name.data(),
root->name.data(), root->name.data(),
...@@ -1759,7 +1762,8 @@ static void buildFunctionList(Entry *root) ...@@ -1759,7 +1762,8 @@ static void buildFunctionList(Entry *root)
//root->tArgList ? (int)root->tArgList->count() : -1, //root->tArgList ? (int)root->tArgList->count() : -1,
//root->mtArgList ? (int)root->mtArgList->count() : -1, //root->mtArgList ? (int)root->mtArgList->count() : -1,
root->mGrpId, root->mGrpId,
root->memSpec root->memSpec,
root->proto
); );
bool isFriend=root->type.find("friend ")!=-1; bool isFriend=root->type.find("friend ")!=-1;
...@@ -1856,15 +1860,26 @@ static void buildFunctionList(Entry *root) ...@@ -1856,15 +1860,26 @@ static void buildFunctionList(Entry *root)
// found,fd->absFilePath().data(),root->fileName.data()); // found,fd->absFilePath().data(),root->fileName.data());
// merge argument lists // merge argument lists
mergeArguments(root->argList,md->argumentList()); //mergeArguments(root->argList,md->argumentList());
// merge documentation // merge documentation
if (!md->documentation() && !root->doc.isEmpty()) if (md->documentation().isEmpty() && !root->doc.isEmpty())
{ {
md->setDocumentation(root->doc); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setDocsForDefinition(!root->proto);
ArgumentList *argList = new ArgumentList;
stringToArgumentList(root->args,argList);
if (root->proto)
{
md->setDeclArgumentList(argList);
}
else
{
md->setArgumentList(argList);
}
} }
if (!md->briefDescription() && !root->brief.isEmpty()) if (md->briefDescription().isEmpty() && !root->brief.isEmpty())
{ {
md->setBriefDescription(root->brief); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
} }
// merge body definitions // merge body definitions
if (md->getStartBodyLine()==-1 && root->bodyLine!=-1) if (md->getStartBodyLine()==-1 && root->bodyLine!=-1)
...@@ -1908,9 +1923,10 @@ static void buildFunctionList(Entry *root) ...@@ -1908,9 +1923,10 @@ static void buildFunctionList(Entry *root)
} }
//md->setDefFile(root->fileName); //md->setDefFile(root->fileName);
//md->setDefLine(root->startLine); //md->setDefLine(root->startLine);
md->setDocumentation(root->doc); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setBriefDescription(root->brief); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
md->setPrototype(root->proto); md->setPrototype(root->proto);
md->setDocsForDefinition(!root->proto);
//md->setBody(root->body); //md->setBody(root->body);
md->setBodySegment(root->bodyLine,root->endBodyLine); md->setBodySegment(root->bodyLine,root->endBodyLine);
bool ambig; bool ambig;
...@@ -2063,13 +2079,21 @@ static void findFriends() ...@@ -2063,13 +2079,21 @@ static void findFriends()
{ {
mergeArguments(mmd->argumentList(),fmd->argumentList()); mergeArguments(mmd->argumentList(),fmd->argumentList());
if (!fmd->documentation().isEmpty()) if (!fmd->documentation().isEmpty())
mmd->setDocumentation(fmd->documentation()); {
mmd->setDocumentation(fmd->documentation(),fmd->docFile(),fmd->docLine());
}
else if (!mmd->documentation().isEmpty()) else if (!mmd->documentation().isEmpty())
fmd->setDocumentation(mmd->documentation()); {
fmd->setDocumentation(mmd->documentation(),mmd->docFile(),mmd->docLine());
}
if (mmd->briefDescription().isEmpty() && !fmd->briefDescription().isEmpty()) if (mmd->briefDescription().isEmpty() && !fmd->briefDescription().isEmpty())
mmd->setBriefDescription(fmd->briefDescription()); {
mmd->setBriefDescription(fmd->briefDescription(),fmd->briefFile(),fmd->briefLine());
}
else if (!mmd->briefDescription().isEmpty() && !fmd->briefDescription().isEmpty()) else if (!mmd->briefDescription().isEmpty() && !fmd->briefDescription().isEmpty())
fmd->setBriefDescription(mmd->briefDescription()); {
fmd->setBriefDescription(mmd->briefDescription(),mmd->briefFile(),mmd->briefLine());
}
if (mmd->getStartBodyLine()==-1 && fmd->getStartBodyLine()!=-1) if (mmd->getStartBodyLine()==-1 && fmd->getStartBodyLine()!=-1)
{ {
mmd->setBodySegment(fmd->getStartBodyLine(),fmd->getEndBodyLine()); mmd->setBodySegment(fmd->getStartBodyLine(),fmd->getEndBodyLine());
...@@ -2128,29 +2152,41 @@ static void transferFunctionDocumentation() ...@@ -2128,29 +2152,41 @@ static void transferFunctionDocumentation()
// check if not in different but documented files // check if not in different but documented files
if (Config_getBool("EXTRACT_ALL") || if (Config_getBool("EXTRACT_ALL") ||
fdef==fdec || fdef==fdec ||
(fdef!=0 && (!fdef->hasDocumentation() || !mdec->hasDocumentation())) (fdef!=0 && (!fdef->hasDocumentation() || !fdec->hasDocumentation()))
) )
{ {
//printf("Found member %s: def in %s and dec in %s\n", //printf("Found member %s: definition in %s (doc=%d) and declation in %s (doc=%d)\n",
// mn->memberName(),mdef->getFileDef()->name().data(), // mn->memberName(),
// mdec->getFileDef()->name().data()); // mdef->getFileDef()->name().data(),!mdef->documentation().isEmpty(),
// mdec->getFileDef()->name().data(),!mdec->documentation().isEmpty()
// );
/* copy documentation between function definition and declaration */ /* copy documentation between function definition and declaration */
if (mdec->briefDescription()) if (!mdec->briefDescription().isEmpty())
{ {
mdef->setBriefDescription(mdec->briefDescription()); mdef->setBriefDescription(mdec->briefDescription(),mdec->briefFile(),mdec->briefLine());
} }
else if (mdef->briefDescription()) else if (!mdef->briefDescription().isEmpty())
{ {
mdec->setBriefDescription(mdef->briefDescription()); mdec->setBriefDescription(mdef->briefDescription(),mdef->briefFile(),mdef->briefLine());
} }
if (mdef->documentation()) if (!mdef->documentation().isEmpty())
{ {
mdec->setDocumentation(mdef->documentation()); //printf("transfering docs mdef->mdec (%s->%s)\n",mdef->argsString(),mdec->argsString());
mdec->setDocumentation(mdef->documentation(),mdef->docFile(),mdef->docLine());
mdec->setDocsForDefinition(mdef->isDocsForDefinition());
ArgumentList *mdefAl = new ArgumentList;
stringToArgumentList(mdef->argsString(),mdefAl);
mdec->setArgumentList(mdefAl);
} }
else if (mdec->documentation()) else if (!mdec->documentation().isEmpty())
{ {
mdef->setDocumentation(mdec->documentation()); //printf("transfering docs mdec->mdef (%s->%s)\n",mdec->argsString(),mdef->argsString());
mdef->setDocumentation(mdec->documentation(),mdec->docFile(),mdec->docLine());
mdef->setDocsForDefinition(mdec->isDocsForDefinition());
ArgumentList *mdecAl = new ArgumentList;
stringToArgumentList(mdec->argsString(),mdecAl);
mdef->setDeclArgumentList(mdecAl);
} }
if (mdec->getStartBodyLine()!=-1 && mdef->getStartBodyLine()==-1) if (mdec->getStartBodyLine()!=-1 && mdef->getStartBodyLine()==-1)
{ {
...@@ -2651,9 +2687,9 @@ static bool findClassRelation( ...@@ -2651,9 +2687,9 @@ static bool findClassRelation(
found=baseClass!=0 && baseClass!=cd; found=baseClass!=0 && baseClass!=cd;
} }
FileDef *fd=cd->getFileDef();
if (!found) if (!found)
{ {
FileDef *fd=cd->getFileDef();
if (fd) if (fd)
{ {
// look for the using statement in this file in which the // look for the using statement in this file in which the
...@@ -2801,6 +2837,7 @@ static bool findClassRelation( ...@@ -2801,6 +2837,7 @@ static bool findClassRelation(
baseClass->insertSubClass(cd,bi->prot,bi->virt,templSpec); baseClass->insertSubClass(cd,bi->prot,bi->virt,templSpec);
// the undocumented base was found in this file // the undocumented base was found in this file
baseClass->insertUsedFile(root->fileName); baseClass->insertUsedFile(root->fileName);
baseClass->setOuterScope(fd);
return TRUE; return TRUE;
} }
else else
...@@ -3171,7 +3208,8 @@ static void addMemberDocs(Entry *root, ...@@ -3171,7 +3208,8 @@ static void addMemberDocs(Entry *root,
doc+="<p>"; doc+="<p>";
doc+=root->doc; doc+=root->doc;
} }
md->setDocumentation(doc); md->setDocumentation(doc,root->docFile,root->docLine);
md->setDocsForDefinition(!root->proto);
} }
else else
{ {
...@@ -3188,7 +3226,8 @@ static void addMemberDocs(Entry *root, ...@@ -3188,7 +3226,8 @@ static void addMemberDocs(Entry *root,
) )
{ {
//printf("overwrite!\n"); //printf("overwrite!\n");
md->setDocumentation(root->doc); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setDocsForDefinition(!root->proto);
} }
//printf("Adding brief md->brief=`%s' root->brief=`%s'!\n", //printf("Adding brief md->brief=`%s' root->brief=`%s'!\n",
...@@ -3203,7 +3242,7 @@ static void addMemberDocs(Entry *root, ...@@ -3203,7 +3242,7 @@ static void addMemberDocs(Entry *root,
) )
{ {
//printf("overwrite!\n"); //printf("overwrite!\n");
md->setBriefDescription(root->brief); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
} }
} }
...@@ -4014,7 +4053,8 @@ static void findMember(Entry *root, ...@@ -4014,7 +4053,8 @@ static void findMember(Entry *root,
QCString doc=getOverloadDocs(); QCString doc=getOverloadDocs();
doc+="<p>"; doc+="<p>";
doc+=root->doc; doc+=root->doc;
md->setDocumentation(doc); md->setDocumentation(doc,root->docFile,root->docLine);
md->setDocsForDefinition(!root->proto);
md->setPrototype(root->proto); md->setPrototype(root->proto);
md->addSectionsToDefinition(root->anchors); md->addSectionsToDefinition(root->anchors);
md->setBodySegment(root->bodyLine,root->endBodyLine); md->setBodySegment(root->bodyLine,root->endBodyLine);
...@@ -4148,9 +4188,10 @@ static void findMember(Entry *root, ...@@ -4148,9 +4188,10 @@ static void findMember(Entry *root,
md->setMemberClass(cd); md->setMemberClass(cd);
md->setMemberSpecifiers(root->memSpec); md->setMemberSpecifiers(root->memSpec);
md->setDefinition(funcDecl); md->setDefinition(funcDecl);
md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setDocsForDefinition(!root->proto);
md->setPrototype(root->proto); md->setPrototype(root->proto);
md->setDocumentation(root->doc); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
md->setBriefDescription(root->brief);
md->addSectionsToDefinition(root->anchors); md->addSectionsToDefinition(root->anchors);
md->setMemberGroupId(root->mGrpId); md->setMemberGroupId(root->mGrpId);
//md->setMemberDefTemplateArguments(root->mtArgList); //md->setMemberDefTemplateArguments(root->mtArgList);
...@@ -4441,8 +4482,9 @@ static void findEnums(Entry *root) ...@@ -4441,8 +4482,9 @@ static void findEnums(Entry *root)
cd->insertMember(md); cd->insertMember(md);
cd->insertUsedFile(root->fileName); cd->insertUsedFile(root->fileName);
} }
md->setDocumentation(root->doc); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setBriefDescription(root->brief); md->setDocsForDefinition(!root->proto);
md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
//printf("Adding member=%s\n",md->name().data()); //printf("Adding member=%s\n",md->name().data());
MemberName *mn; MemberName *mn;
...@@ -4574,14 +4616,15 @@ static void findEnumDocumentation(Entry *root) ...@@ -4574,14 +4616,15 @@ static void findEnumDocumentation(Entry *root)
// documentation outside a compound overrides the documentation inside it // documentation outside a compound overrides the documentation inside it
if (!md->documentation() || root->parent->name.isEmpty()) if (!md->documentation() || root->parent->name.isEmpty())
{ {
md->setDocumentation(root->doc); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setDocsForDefinition(!root->proto);
} }
// brief descriptions inside a compound override the documentation // brief descriptions inside a compound override the documentation
// outside it // outside it
if (!md->briefDescription() || !root->parent->name.isEmpty()) if (!md->briefDescription() || !root->parent->name.isEmpty())
{ {
md->setBriefDescription(root->brief); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
} }
if (root->mGrpId!=-1 && md->getMemberGroupId()==-1) if (root->mGrpId!=-1 && md->getMemberGroupId()==-1)
...@@ -4605,8 +4648,9 @@ static void findEnumDocumentation(Entry *root) ...@@ -4605,8 +4648,9 @@ static void findEnumDocumentation(Entry *root)
MemberName *mn=Doxygen::functionNameSDict[name]; MemberName *mn=Doxygen::functionNameSDict[name];
if (mn && (md=mn->getFirst())) if (mn && (md=mn->getFirst()))
{ {
md->setDocumentation(root->doc); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setBriefDescription(root->brief); md->setDocsForDefinition(!root->proto);
md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
md->addSectionsToDefinition(root->anchors); md->addSectionsToDefinition(root->anchors);
md->setMemberGroupId(root->mGrpId); md->setMemberGroupId(root->mGrpId);
found=TRUE; found=TRUE;
...@@ -4694,11 +4738,11 @@ static void computeMemberRelations() ...@@ -4694,11 +4738,11 @@ static void computeMemberRelations()
{ {
ClassDef *bmcd = bmd->getClassDef(); ClassDef *bmcd = bmd->getClassDef();
ClassDef *mcd = md->getClassDef(); ClassDef *mcd = md->getClassDef();
//printf("Check relation between `%s'::`%s' and `%s'::`%s'\n", //printf("Check relation between `%s'::`%s' (%p) and `%s'::`%s' (%p)\n",
// mcd->name().data(),md->name().data(), // mcd->name().data(),md->name().data(),md,
// bmcd->name().data(),bmd->name().data() // bmcd->name().data(),bmd->name().data(),bmd
// ); // );
if (md!=bmd && bmcd && mcd && bmcd!=mcd && mcd->isBaseClass(bmcd)) if (md!=bmd && bmcd && mcd && bmcd!=mcd && mcd->isBaseClass(bmcd,TRUE))
{ {
//printf(" Base argList=`%s'\n Super argList=`%s'\n", //printf(" Base argList=`%s'\n Super argList=`%s'\n",
// argListToString(bmd->argumentList()).data(), // argListToString(bmd->argumentList()).data(),
...@@ -4921,6 +4965,32 @@ static void addSourceReferences() ...@@ -4921,6 +4965,32 @@ static void addSourceReferences()
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------
// generate the documentation of all classes // generate the documentation of all classes
static void generateClassList(ClassSDict &classSDict)
{
ClassSDict::Iterator cli(classSDict);
for ( ; cli.current() ; ++cli )
{
ClassDef *cd=cli.current();
if (cd->getOuterScope()==0 || // <-- should not happen, but can if we read an old tag file
cd->getOuterScope()==Doxygen::globalScope // only look at global classes
)
{
// skip external references, anonymous compounds and
// template instances
if ( cd->isLinkableInProject() && cd->templateMaster()==0)
{
msg("Generating docs for compound %s...\n",cd->name().data());
cd->writeDocumentation(*outputList);
cd->writeMemberList(*outputList);
}
// even for undocumented classes, the inner classes can be documented.
cd->writeDocumentationForInnerClasses(*outputList);
}
}
}
static void generateClassDocs() static void generateClassDocs()
{ {
// write the installdox script if necessary // write the installdox script if necessary
...@@ -4953,28 +5023,8 @@ static void generateClassDocs() ...@@ -4953,28 +5023,8 @@ static void generateClassDocs()
msg("Generating example index...\n"); msg("Generating example index...\n");
} }
ClassSDict::Iterator cli(Doxygen::classSDict); generateClassList(Doxygen::classSDict);
for ( ; cli.current() ; ++cli ) generateClassList(Doxygen::hiddenClasses);
{
ClassDef *cd=cli.current();
if (cd->getOuterScope()==0 || // <-- should not happen, but can if we read an old tag file
cd->getOuterScope()==Doxygen::globalScope // only look at global classes
)
{
// skip external references, anonymous compounds and
// template instances
if ( cd->isLinkableInProject() && cd->templateMaster()==0)
{
msg("Generating docs for compound %s...\n",cd->name().data());
cd->writeDocumentation(*outputList);
cd->writeMemberList(*outputList);
}
// even for undocumented classes, the inner classes can be documented.
cd->writeDocumentationForInnerClasses(*outputList);
}
}
} }
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------
...@@ -4998,12 +5048,14 @@ static void inheritDocumentation() ...@@ -4998,12 +5048,14 @@ static void inheritDocumentation()
bmd->briefDescription().isEmpty() bmd->briefDescription().isEmpty()
) )
{ // search up the inheritance tree for a documentation member { // search up the inheritance tree for a documentation member
//printf("bmd=%s class=%s\n",bmd->name().data(),bmd->getClassDef()->name().data());
bmd = bmd->reimplements(); bmd = bmd->reimplements();
} }
if (bmd) // copy the documentation from the reimplemented member if (bmd) // copy the documentation from the reimplemented member
{ {
md->setDocumentation(bmd->documentation()); md->setDocumentation(bmd->documentation(),bmd->docFile(),bmd->docLine());
md->setBriefDescription(bmd->briefDescription()); md->setDocsForDefinition(bmd->isDocsForDefinition());
md->setBriefDescription(bmd->briefDescription(),bmd->briefFile(),bmd->briefLine());
} }
} }
} }
...@@ -5144,9 +5196,12 @@ static void findDefineDocumentation(Entry *root) ...@@ -5144,9 +5196,12 @@ static void findDefineDocumentation(Entry *root)
if (md->memberType()==MemberDef::Define) if (md->memberType()==MemberDef::Define)
{ {
if (md->documentation().isEmpty()) if (md->documentation().isEmpty())
md->setDocumentation(root->doc); {
md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setDocsForDefinition(!root->proto);
}
if (md->briefDescription().isEmpty()) if (md->briefDescription().isEmpty())
md->setBriefDescription(root->brief); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
md->setBodySegment(root->bodyLine,root->endBodyLine); md->setBodySegment(root->bodyLine,root->endBodyLine);
bool ambig; bool ambig;
md->setBodyDef(findFileDef(Doxygen::inputNameDict,root->fileName,ambig)); md->setBodyDef(findFileDef(Doxygen::inputNameDict,root->fileName,ambig));
...@@ -5178,9 +5233,12 @@ static void findDefineDocumentation(Entry *root) ...@@ -5178,9 +5233,12 @@ static void findDefineDocumentation(Entry *root)
// doc and define in the same file assume they belong together. // doc and define in the same file assume they belong together.
{ {
if (md->documentation().isEmpty()) if (md->documentation().isEmpty())
md->setDocumentation(root->doc); {
md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setDocsForDefinition(!root->proto);
}
if (md->briefDescription().isEmpty()) if (md->briefDescription().isEmpty())
md->setBriefDescription(root->brief); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
md->setBodySegment(root->bodyLine,root->endBodyLine); md->setBodySegment(root->bodyLine,root->endBodyLine);
bool ambig; bool ambig;
md->setBodyDef(findFileDef(Doxygen::inputNameDict,root->fileName,ambig)); md->setBodyDef(findFileDef(Doxygen::inputNameDict,root->fileName,ambig));
...@@ -5299,18 +5357,18 @@ static void buildPackageList(Entry *root) ...@@ -5299,18 +5357,18 @@ static void buildPackageList(Entry *root)
} }
pd = new PackageDef(root->fileName,root->startLine,root->name,tagName); pd = new PackageDef(root->fileName,root->startLine,root->name,tagName);
Doxygen::packageDict.inSort(root->name,pd); Doxygen::packageDict.inSort(root->name,pd);
pd->setDocumentation(root->doc); pd->setDocumentation(root->doc,root->docFile,root->docLine);
pd->setBriefDescription(root->brief); pd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
} }
else else
{ {
if (!pd->documentation() && !root->doc.isEmpty()) if (!pd->documentation() && !root->doc.isEmpty())
{ {
pd->setDocumentation(root->doc); pd->setDocumentation(root->doc,root->docFile,root->docLine);
} }
if (!pd->briefDescription() && !root->brief.isEmpty()) if (!pd->briefDescription() && !root->brief.isEmpty())
{ {
pd->setBriefDescription(root->brief); pd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
} }
} }
bool ambig; bool ambig;
...@@ -6018,13 +6076,15 @@ static int readDir(QFileInfo *fi, ...@@ -6018,13 +6076,15 @@ static int readDir(QFileInfo *fi,
StringList *resultList, StringList *resultList,
StringDict *resultDict, StringDict *resultDict,
bool errorIfNotExist, bool errorIfNotExist,
bool recursive bool recursive,
QDict<void> *killDict
) )
{ {
QDir dir((const char *)fi->absFilePath()); QDir dir((const char *)fi->absFilePath());
dir.setFilter( QDir::Files | QDir::Dirs ); dir.setFilter( QDir::Files | QDir::Dirs );
int totalSize=0; int totalSize=0;
//printf("readDir `%s'\n",fi->absFilePath().data()); //printf("readDir `%s'\n",fi->absFilePath().data());
//printf("killDict=%p count=%d\n",killDict,killDict->count());
const QFileInfoList *list = dir.entryInfoList(); const QFileInfoList *list = dir.entryInfoList();
QFileInfoListIterator it( *list ); QFileInfoListIterator it( *list );
...@@ -6034,6 +6094,7 @@ static int readDir(QFileInfo *fi, ...@@ -6034,6 +6094,7 @@ static int readDir(QFileInfo *fi,
{ {
if (exclDict==0 || exclDict->find(cfi->absFilePath())==0) if (exclDict==0 || exclDict->find(cfi->absFilePath())==0)
{ // file should not be excluded { // file should not be excluded
//printf("killDict->find(%s)\n",cfi->absFilePath().data());
if ((!cfi->exists() || !cfi->isReadable()) && errorIfNotExist) if ((!cfi->exists() || !cfi->isReadable()) && errorIfNotExist)
{ {
err("Error: source %s is not a readable file or directory... skipping.\n",cfi->absFilePath().data()); err("Error: source %s is not a readable file or directory... skipping.\n",cfi->absFilePath().data());
...@@ -6041,7 +6102,9 @@ static int readDir(QFileInfo *fi, ...@@ -6041,7 +6102,9 @@ static int readDir(QFileInfo *fi,
else if (cfi->isFile() && else if (cfi->isFile() &&
(!Config_getBool("EXCLUDE_SYMLINKS") || !cfi->isSymLink()) && (!Config_getBool("EXCLUDE_SYMLINKS") || !cfi->isSymLink()) &&
(patList==0 || patternMatch(cfi,patList)) && (patList==0 || patternMatch(cfi,patList)) &&
!patternMatch(cfi,exclPatList)) !patternMatch(cfi,exclPatList) &&
(killDict==0 || killDict->find(cfi->absFilePath())==0)
)
{ {
totalSize+=cfi->size()+cfi->absFilePath().length()+4; totalSize+=cfi->size()+cfi->absFilePath().length()+4;
QCString name=convertToQCString(cfi->fileName()); QCString name=convertToQCString(cfi->fileName());
...@@ -6069,6 +6132,7 @@ static int readDir(QFileInfo *fi, ...@@ -6069,6 +6132,7 @@ static int readDir(QFileInfo *fi,
} }
if (resultList) resultList->append(rs); if (resultList) resultList->append(rs);
if (resultDict) resultDict->insert(cfi->absFilePath(),rs); if (resultDict) resultDict->insert(cfi->absFilePath(),rs);
if (killDict) killDict->insert(cfi->absFilePath(),(void *)0x8);
} }
else if (recursive && else if (recursive &&
(!Config_getBool("EXCLUDE_SYMLINKS") || !cfi->isSymLink()) && (!Config_getBool("EXCLUDE_SYMLINKS") || !cfi->isSymLink()) &&
...@@ -6078,7 +6142,7 @@ static int readDir(QFileInfo *fi, ...@@ -6078,7 +6142,7 @@ static int readDir(QFileInfo *fi,
cfi->setFile(cfi->absFilePath()); cfi->setFile(cfi->absFilePath());
totalSize+=readDir(cfi,fnList,fnDict,exclDict, totalSize+=readDir(cfi,fnList,fnDict,exclDict,
patList,exclPatList,resultList,resultDict,errorIfNotExist, patList,exclPatList,resultList,resultDict,errorIfNotExist,
recursive); recursive,killDict);
} }
} }
++it; ++it;
...@@ -6135,9 +6199,11 @@ static int readFileOrDirectory(const char *s, ...@@ -6135,9 +6199,11 @@ static int readFileOrDirectory(const char *s,
StringList *resultList, StringList *resultList,
StringDict *resultDict, StringDict *resultDict,
bool recursive, bool recursive,
bool errorIfNotExist=TRUE bool errorIfNotExist=TRUE,
QDict<void> *killDict = 0
) )
{ {
//printf("killDict=%p count=%d\n",killDict,killDict->count());
// strip trailing slashes // strip trailing slashes
QCString fs = s; QCString fs = s;
char lc = fs.at(fs.length()-1); char lc = fs.at(fs.length()-1);
...@@ -6157,39 +6223,44 @@ static int readFileOrDirectory(const char *s, ...@@ -6157,39 +6223,44 @@ static int readFileOrDirectory(const char *s,
{ {
if (fi.isFile()) if (fi.isFile())
{ {
totalSize+=fi.size()+fi.absFilePath().length()+4; //readFile(&fi,fiList,input); //printf("killDict->find(%s)\n",fi.absFilePath().data());
//fiList->inSort(new FileInfo(fi)); if (killDict==0 || killDict->find(fi.absFilePath())==0)
QCString name=convertToQCString(fi.fileName());
//printf("New file %s\n",name.data());
if (fnDict)
{ {
FileDef *fd=new FileDef(fi.dirPath(TRUE)+"/",name); totalSize+=fi.size()+fi.absFilePath().length()+4; //readFile(&fi,fiList,input);
FileName *fn=0; //fiList->inSort(new FileInfo(fi));
if (!name.isEmpty() && (fn=(*fnDict)[name])) QCString name=convertToQCString(fi.fileName());
//printf("New file %s\n",name.data());
if (fnDict)
{ {
fn->append(fd); FileDef *fd=new FileDef(fi.dirPath(TRUE)+"/",name);
FileName *fn=0;
if (!name.isEmpty() && (fn=(*fnDict)[name]))
{
fn->append(fd);
}
else
{
fn = new FileName(fi.absFilePath(),name);
fn->append(fd);
if (fnList) fnList->inSort(fn);
fnDict->insert(name,fn);
}
} }
else QCString *rs=0;
if (resultList || resultDict)
{ {
fn = new FileName(fi.absFilePath(),name); rs=new QCString(fi.absFilePath());
fn->append(fd);
if (fnList) fnList->inSort(fn);
fnDict->insert(name,fn);
} }
if (resultList) resultList->append(rs);
if (resultDict) resultDict->insert(fi.absFilePath(),rs);
if (killDict) killDict->insert(fi.absFilePath(),(void *)0x8);
} }
QCString *rs=0;
if (resultList || resultDict)
{
rs=new QCString(fi.absFilePath());
}
if (resultList) resultList->append(rs);
if (resultDict) resultDict->insert(fi.absFilePath(),rs);
} }
else if (fi.isDir()) // readable dir else if (fi.isDir()) // readable dir
{ {
totalSize+=readDir(&fi,fnList,fnDict,exclDict,patList, totalSize+=readDir(&fi,fnList,fnDict,exclDict,patList,
exclPatList,resultList,resultDict,errorIfNotExist, exclPatList,resultList,resultDict,errorIfNotExist,
recursive); recursive,killDict);
} }
} }
} }
...@@ -6305,7 +6376,10 @@ void readConfiguration(int argc, char **argv) ...@@ -6305,7 +6376,10 @@ void readConfiguration(int argc, char **argv)
case 'g': case 'g':
genConfig=TRUE; genConfig=TRUE;
configName=getArg(argc,argv,optind); configName=getArg(argc,argv,optind);
if (!configName) configName="Doxyfile"; if (strcmp(argv[optind+1],"-")==0)
{ configName="-"; optind++; }
if (!configName)
{ configName="Doxyfile"; }
break; break;
case 'd': case 'd':
debugLabel=getArg(argc,argv,optind); debugLabel=getArg(argc,argv,optind);
...@@ -6400,7 +6474,7 @@ void readConfiguration(int argc, char **argv) ...@@ -6400,7 +6474,7 @@ void readConfiguration(int argc, char **argv)
{ {
HtmlGenerator::writeStyleSheetFile(f); HtmlGenerator::writeStyleSheetFile(f);
} }
exit(1); exit(0);
} }
else if (stricmp(formatName,"latex")==0) else if (stricmp(formatName,"latex")==0)
{ {
...@@ -6435,7 +6509,7 @@ void readConfiguration(int argc, char **argv) ...@@ -6435,7 +6509,7 @@ void readConfiguration(int argc, char **argv)
{ {
LatexGenerator::writeStyleSheetFile(f); LatexGenerator::writeStyleSheetFile(f);
} }
exit(1); exit(0);
} }
else else
{ {
...@@ -6451,7 +6525,7 @@ void readConfiguration(int argc, char **argv) ...@@ -6451,7 +6525,7 @@ void readConfiguration(int argc, char **argv)
else if (strcmp(&argv[optind][2],"version")==0) else if (strcmp(&argv[optind][2],"version")==0)
{ {
msg("%s\n",versionString); msg("%s\n",versionString);
exit(1); exit(0);
} }
break; break;
case 'h': case 'h':
...@@ -6472,7 +6546,7 @@ void readConfiguration(int argc, char **argv) ...@@ -6472,7 +6546,7 @@ void readConfiguration(int argc, char **argv)
if (genConfig) if (genConfig)
{ {
generateConfigFile(configName,shortList); generateConfigFile(configName,shortList);
exit(1); exit(0);
} }
QFileInfo configFileInfo1("Doxyfile"),configFileInfo2("doxyfile"); QFileInfo configFileInfo1("Doxyfile"),configFileInfo2("doxyfile");
...@@ -6515,7 +6589,7 @@ void readConfiguration(int argc, char **argv) ...@@ -6515,7 +6589,7 @@ void readConfiguration(int argc, char **argv)
if (updateConfig) if (updateConfig)
{ {
generateConfigFile(configName,shortList,TRUE); generateConfigFile(configName,shortList,TRUE);
exit(1); exit(0);
} }
Config::instance()->substituteEnvironmentVars(); Config::instance()->substituteEnvironmentVars();
...@@ -6544,8 +6618,8 @@ void parseInput() ...@@ -6544,8 +6618,8 @@ void parseInput()
Doxygen::classSDict.setAutoDelete(TRUE); Doxygen::classSDict.setAutoDelete(TRUE);
Doxygen::inputNameDict = new FileNameDict(1009); Doxygen::inputNameDict = new FileNameDict(10007);
Doxygen::includeNameDict = new FileNameDict(1009); Doxygen::includeNameDict = new FileNameDict(10007);
Doxygen::exampleNameDict = new FileNameDict(1009); Doxygen::exampleNameDict = new FileNameDict(1009);
Doxygen::imageNameDict = new FileNameDict(257); Doxygen::imageNameDict = new FileNameDict(257);
Doxygen::dotFileNameDict = new FileNameDict(257); Doxygen::dotFileNameDict = new FileNameDict(257);
...@@ -6652,6 +6726,7 @@ void parseInput() ...@@ -6652,6 +6726,7 @@ void parseInput()
} }
msg("Reading input files...\n"); msg("Reading input files...\n");
QDict<void> *killDict = new QDict<void>(10007);
int inputSize=0; int inputSize=0;
QStrList &inputList=Config_getList("INPUT"); QStrList &inputList=Config_getList("INPUT");
s=inputList.first(); s=inputList.first();
...@@ -6667,9 +6742,12 @@ void parseInput() ...@@ -6667,9 +6742,12 @@ void parseInput()
&Config_getList("FILE_PATTERNS"), &Config_getList("FILE_PATTERNS"),
&Config_getList("EXCLUDE_PATTERNS"), &Config_getList("EXCLUDE_PATTERNS"),
&inputFiles,0, &inputFiles,0,
alwaysRecursive); alwaysRecursive,
TRUE,
killDict);
s=inputList.next(); s=inputList.next();
} }
delete killDict;
// add predefined macro name to a dictionary // add predefined macro name to a dictionary
QStrList &expandAsDefinedList =Config_getList("EXPAND_AS_DEFINED"); QStrList &expandAsDefinedList =Config_getList("EXPAND_AS_DEFINED");
......
...@@ -65,8 +65,12 @@ Entry::Entry(const Entry &e) ...@@ -65,8 +65,12 @@ Entry::Entry(const Entry &e)
includeFile = e.includeFile.copy(); includeFile = e.includeFile.copy();
includeName = e.includeFile.copy(); includeName = e.includeFile.copy();
doc = e.doc.copy(); doc = e.doc.copy();
docLine = e.docLine;
docFile = e.docFile.copy();
relates = e.relates.copy(); relates = e.relates.copy();
brief = e.brief.copy(); brief = e.brief.copy();
briefLine = e.briefLine;
briefFile = e.briefFile.copy();
inside = e.inside.copy(); inside = e.inside.copy();
fileName = e.fileName.copy(); fileName = e.fileName.copy();
startLine = e.startLine; startLine = e.startLine;
...@@ -90,9 +94,7 @@ Entry::Entry(const Entry &e) ...@@ -90,9 +94,7 @@ Entry::Entry(const Entry &e)
anchors->setAutoDelete(TRUE); anchors->setAutoDelete(TRUE);
argList = new ArgumentList; argList = new ArgumentList;
argList->setAutoDelete(TRUE); argList->setAutoDelete(TRUE);
//printf("Entry::Entry(copy) tArgList=0\n");
tArgLists = 0; tArgLists = 0;
//mtArgList = 0;
groupDocType = e.groupDocType; groupDocType = e.groupDocType;
// deep copy of the child entry list // deep copy of the child entry list
...@@ -206,8 +208,12 @@ void Entry::reset() ...@@ -206,8 +208,12 @@ void Entry::reset()
includeFile.resize(0); includeFile.resize(0);
includeName.resize(0); includeName.resize(0);
doc.resize(0); doc.resize(0);
docFile.resize(0);
docLine=-1;
relates.resize(0); relates.resize(0);
brief.resize(0); brief.resize(0);
briefFile.resize(0);
briefLine=-1;
inside.resize(0); inside.resize(0);
fileName.resize(0); fileName.resize(0);
//scopeSpec.resize(0); //scopeSpec.resize(0);
...@@ -251,12 +257,13 @@ int Entry::getSize() ...@@ -251,12 +257,13 @@ int Entry::getSize()
size+=bitfields.length()+1; size+=bitfields.length()+1;
size+=exception.length()+1; size+=exception.length()+1;
size+=program.length()+1; size+=program.length()+1;
//size+=body.length()+1;
size+=includeFile.length()+1; size+=includeFile.length()+1;
size+=includeName.length()+1; size+=includeName.length()+1;
size+=doc.length()+1; size+=doc.length()+1;
size+=docFile.length()+1;
size+=relates.length()+1; size+=relates.length()+1;
size+=brief.length()+1; size+=brief.length()+1;
size+=briefFile.length()+1;
size+=inside.length()+1; size+=inside.length()+1;
size+=fileName.length()+1; size+=fileName.length()+1;
size+=initializer.length()+1; size+=initializer.length()+1;
......
...@@ -254,15 +254,17 @@ class Entry ...@@ -254,15 +254,17 @@ class Entry
QCString bitfields; //!< member's bit fields QCString bitfields; //!< member's bit fields
ArgumentList *argList; //!< member arguments as a list ArgumentList *argList; //!< member arguments as a list
QList<ArgumentList> *tArgLists; //!< template argument declarations QList<ArgumentList> *tArgLists; //!< template argument declarations
//QCString scopeSpec; //!< template specialization of the scope
//QCString memberSpec; //!< template specialization of the member
QCString program; //!< the program text QCString program; //!< the program text
QCString initializer; //!< initial value (for variables) QCString initializer; //!< initial value (for variables)
QCString includeFile; //!< include file (2 arg of \class, must be unique) QCString includeFile; //!< include file (2 arg of \class, must be unique)
QCString includeName; //!< include name (3 arg of \class) QCString includeName; //!< include name (3 arg of \class)
QCString doc; //!< documentation block (partly parsed) QCString doc; //!< documentation block (partly parsed)
QCString relates; //!< related class (doc block) int docLine; //!< line number at which the documentation was found
QCString docFile; //!< file in which the documentation was found
QCString brief; //!< brief description (doc block) QCString brief; //!< brief description (doc block)
int briefLine; //!< line number at which the brief desc. was found
QCString briefFile; //!< file in which the brief desc. was found
QCString relates; //!< related class (doc block)
QCString inside; //!< name of the class in which documents are found QCString inside; //!< name of the class in which documents are found
QCString exception; //!< throw specification QCString exception; //!< throw specification
int bodyLine; //!< line number of the definition in the source int bodyLine; //!< line number of the definition in the source
......
...@@ -443,8 +443,10 @@ int FTVHelp::decContentsDepth() ...@@ -443,8 +443,10 @@ int FTVHelp::decContentsDepth()
/*! Add a list item to the contents file. /*! Add a list item to the contents file.
* \param isDir TRUE if the item is a directory, FALSE if it is a text * \param isDir TRUE if the item is a directory, FALSE if it is a text
* \param name the name of the item.
* \param ref the URL of to the item. * \param ref the URL of to the item.
* \param file the file containing the definition of the item
* \param anchor the anchor within the file.
* \param name the name of the item.
*/ */
void FTVHelp::addContentsItem(bool isDir, void FTVHelp::addContentsItem(bool isDir,
const char *ref, const char *ref,
......
...@@ -134,14 +134,16 @@ void HtmlGenerator::writeStyleSheetFile(QFile &file) ...@@ -134,14 +134,16 @@ void HtmlGenerator::writeStyleSheetFile(QFile &file)
t << defaultStyleSheet; t << defaultStyleSheet;
} }
static void writeDefaultHeaderFile(QTextStream &t,const char *title, static void writeDefaultHeaderFile(QTextStream &t, const char *title,
bool external) bool external)
{ {
t << "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\">\n" t << "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\">\n"
"<html><head>" /*"<meta name=\"robots\" content=\"noindex\">\n"*/ "<html><head>" /*"<meta name=\"robots\" content=\"noindex\">\n"*/
"<meta http-equiv=\"Content-Type\" content=\"text/html;charset=" "<meta http-equiv=\"Content-Type\" content=\"text/html;charset="
<< theTranslator->idLanguageCharset() << "\">\n" << theTranslator->idLanguageCharset() << "\">\n"
"<title>" << title << "</title>\n"; "<title>";
t << convertToHtml(title);
t << "</title>\n";
t << "<link "; t << "<link ";
if (external) if (external)
t << "doxygen=\"_doc:" << Config_getString("DOC_URL") t << "doxygen=\"_doc:" << Config_getString("DOC_URL")
...@@ -212,7 +214,7 @@ void HtmlGenerator::startFile(const char *name,const char *, ...@@ -212,7 +214,7 @@ void HtmlGenerator::startFile(const char *name,const char *,
} }
else else
{ {
t << substituteKeywords(g_header,lastTitle); t << substituteKeywords(g_header,convertToHtml(lastTitle));
} }
t << "<!-- " << theTranslator->trGeneratedBy() << " Doxygen " t << "<!-- " << theTranslator->trGeneratedBy() << " Doxygen "
<< versionString << " -->" << endl; << versionString << " -->" << endl;
...@@ -255,7 +257,7 @@ void HtmlGenerator::writeFooter(int part,bool external) ...@@ -255,7 +257,7 @@ void HtmlGenerator::writeFooter(int part,bool external)
if (g_footer.isEmpty()) if (g_footer.isEmpty())
t << "<hr><address><small>"; t << "<hr><address><small>";
else else
t << substituteKeywords(g_footer,lastTitle); t << substituteKeywords(g_footer,convertToHtml(lastTitle));
break; break;
case 1: case 1:
if (g_footer.isEmpty()) if (g_footer.isEmpty())
......
...@@ -82,7 +82,7 @@ class HtmlGenerator : public OutputGenerator ...@@ -82,7 +82,7 @@ class HtmlGenerator : public OutputGenerator
void codify(const char *text); void codify(const char *text);
void writeObjectLink(const char *ref,const char *file, void writeObjectLink(const char *ref,const char *file,
const char *anchor,const char *name); const char *anchor,const char *name);
void writeCodeLink(const char *ref,const char *f, void writeCodeLink(const char *ref,const char *file,
const char *anchor,const char *name); const char *anchor,const char *name);
void startTextLink(const char *file,const char *anchor); void startTextLink(const char *file,const char *anchor);
void endTextLink(); void endTextLink();
......
...@@ -396,8 +396,10 @@ int HtmlHelp::decContentsDepth() ...@@ -396,8 +396,10 @@ int HtmlHelp::decContentsDepth()
} }
/*! Add an list item to the contents file. /*! Add an list item to the contents file.
* \param isDir boolean indicating if this is a dir or file entry
* \param name the name of the item. * \param name the name of the item.
* \param ref the URL of to the item. * \param ref the URL of to the item.
* \param anchor the anchor of the item.
*/ */
void HtmlHelp::addContentsItem(bool isDir, void HtmlHelp::addContentsItem(bool isDir,
const char *name,const char *ref, const char *name,const char *ref,
...@@ -433,8 +435,10 @@ void HtmlHelp::addContentsItem(bool isDir, ...@@ -433,8 +435,10 @@ void HtmlHelp::addContentsItem(bool isDir,
} }
/*! Add an list item to the index file. /*! Add an list item to the index file.
* \param name the name of the item. * \param level1 the main index of the item.
* \param level2 the sub index of the item.
* \param ref the URL of to the item. * \param ref the URL of to the item.
* \param anchor the anchor of the item.
* \sa HtmlHelpIndex * \sa HtmlHelpIndex
*/ */
void HtmlHelp::addIndexItem(const char *level1, const char *level2, void HtmlHelp::addIndexItem(const char *level1, const char *level2,
......
...@@ -586,7 +586,8 @@ static void writeClassTreeForList(OutputList &ol,ClassSDict *cl,bool &started) ...@@ -586,7 +586,8 @@ static void writeClassTreeForList(OutputList &ol,ClassSDict *cl,bool &started)
bool hasChildren = !cd->visited && cd->subClasses()->count()>0; bool hasChildren = !cd->visited && cd->subClasses()->count()>0;
if (cd->isLinkable()) if (cd->isLinkable())
{ {
//printf("Writing class %s\n",cd->displayName().data()); //printf("Writing class %s isLinkable()=%d isLinkableInProject()=%d cd->templateMaster()=%p\n",
// cd->displayName().data(),cd->isLinkable(),cd->isLinkableInProject(),cd->templateMaster());
ol.writeIndexItem(cd->getReference(),cd->getOutputFileBase(),cd->displayName()); ol.writeIndexItem(cd->getReference(),cd->getOutputFileBase(),cd->displayName());
if (cd->isReference()) if (cd->isReference())
{ {
......
...@@ -78,14 +78,14 @@ class LatexGenerator : public OutputGenerator ...@@ -78,14 +78,14 @@ class LatexGenerator : public OutputGenerator
void docify(const char *text); void docify(const char *text);
void codify(const char *text); void codify(const char *text);
void writeObjectLink(const char *ref,const char *file, void writeObjectLink(const char *ref,const char *file,
const char *anchor,const char *text); const char *anchor,const char *name);
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 *name);
void startTextLink(const char *,const char *); void startTextLink(const char *,const char *);
void endTextLink(); void endTextLink();
void startHtmlLink(const char *); void startHtmlLink(const char *url);
void endHtmlLink(); void endHtmlLink();
void writeMailLink(const char *); void writeMailLink(const char *url);
void startTypewriter() { t << "{\\tt "; } void startTypewriter() { t << "{\\tt "; }
void endTypewriter() { t << "}"; } void endTypewriter() { t << "}"; }
void startGroupHeader(); void startGroupHeader();
......
...@@ -77,7 +77,7 @@ class ManGenerator : public OutputGenerator ...@@ -77,7 +77,7 @@ class ManGenerator : public OutputGenerator
void codify(const char *text); void codify(const char *text);
void writeObjectLink(const char *ref,const char *file, void writeObjectLink(const char *ref,const char *file,
const char *anchor,const char *name); const char *anchor,const char *name);
void writeCodeLink(const char *ref,const char *f, void writeCodeLink(const char *ref,const char *file,
const char *anchor,const char *name); const char *anchor,const char *name);
void startTextLink(const char *,const char *) {} void startTextLink(const char *,const char *) {}
void endTextLink() {} void endTextLink() {}
......
...@@ -72,9 +72,10 @@ static QCString addTemplateNames(const QCString &s,const QCString &n,const QCStr ...@@ -72,9 +72,10 @@ static QCString addTemplateNames(const QCString &s,const QCString &n,const QCStr
static void writeDefArgumentList(OutputList &ol,ClassDef *cd, static void writeDefArgumentList(OutputList &ol,ClassDef *cd,
const QCString &scopeName,MemberDef *md) const QCString &scopeName,MemberDef *md)
{ {
ArgumentList *argList=md->argumentList(); ArgumentList *defArgList=md->isDocsForDefinition() ?
//printf("writeDefArgumentList `%s' %p\n",md->name().data(),argList); md->argumentList() : md->declArgumentList();
if (argList==0) return; // member has no function like argument list //printf("writeDefArgumentList `%s' isDocsForDefinition()=%d\n",md->name().data(),md->isDocsForDefinition());
if (defArgList==0) return; // member has no function like argument list
if (!md->isDefine()) ol.docify(" "); if (!md->isDefine()) ol.docify(" ");
ol.pushGeneratorState(); ol.pushGeneratorState();
...@@ -88,7 +89,7 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd, ...@@ -88,7 +89,7 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd,
ol.popGeneratorState(); ol.popGeneratorState();
//printf("===> name=%s isDefine=%d\n",md->name().data(),md->isDefine()); //printf("===> name=%s isDefine=%d\n",md->name().data(),md->isDefine());
Argument *a=argList->first(); Argument *a=defArgList->first();
QCString cName; QCString cName;
//if (md->scopeDefTemplateArguments()) //if (md->scopeDefTemplateArguments())
//{ //{
...@@ -143,7 +144,7 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd, ...@@ -143,7 +144,7 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd,
if (!md->isDefine()) if (!md->isDefine())
{ {
ol.endParameterType(); ol.endParameterType();
ol.startParameterName(argList->count()<2); ol.startParameterName(defArgList->count()<2);
} }
if (!a->name.isEmpty()) // argument has a name if (!a->name.isEmpty()) // argument has a name
{ {
...@@ -173,7 +174,7 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd, ...@@ -173,7 +174,7 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd,
ol.docify(" = "); ol.docify(" = ");
linkifyText(TextGeneratorOLImpl(ol),scopeName,md->name(),n); linkifyText(TextGeneratorOLImpl(ol),scopeName,md->name(),n);
} }
a=argList->next(); a=defArgList->next();
if (a) if (a)
{ {
ol.docify(", "); // there are more arguments ol.docify(", "); // there are more arguments
...@@ -193,8 +194,8 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd, ...@@ -193,8 +194,8 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd,
ol.disableAllBut(OutputGenerator::Html); ol.disableAllBut(OutputGenerator::Html);
if (!md->isDefine()) if (!md->isDefine())
{ {
if (first) ol.startParameterName(argList->count()<2); if (first) ol.startParameterName(defArgList->count()<2);
ol.endParameterName(TRUE,argList->count()<2); ol.endParameterName(TRUE,defArgList->count()<2);
} }
else else
{ {
...@@ -203,11 +204,11 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd, ...@@ -203,11 +204,11 @@ static void writeDefArgumentList(OutputList &ol,ClassDef *cd,
ol.endParameterName(TRUE,TRUE); ol.endParameterName(TRUE,TRUE);
} }
ol.popGeneratorState(); ol.popGeneratorState();
if (argList->constSpecifier) if (defArgList->constSpecifier)
{ {
ol.docify(" const"); ol.docify(" const");
} }
if (argList->volatileSpecifier) if (defArgList->volatileSpecifier)
{ {
ol.docify(" volatile"); ol.docify(" volatile");
} }
...@@ -290,6 +291,7 @@ MemberDef::MemberDef(const char *df,int dl, ...@@ -290,6 +291,7 @@ MemberDef::MemberDef(const char *df,int dl,
args=a; args=a;
args=removeRedundantWhiteSpace(args); args=removeRedundantWhiteSpace(args);
if (type.isEmpty()) decl=name()+args; else decl=type+" "+name()+args; if (type.isEmpty()) decl=name()+args; else decl=type+" "+name()+args;
//declLine=0; //declLine=0;
memberGroup=0; memberGroup=0;
virt=v; virt=v;
...@@ -329,27 +331,38 @@ MemberDef::MemberDef(const char *df,int dl, ...@@ -329,27 +331,38 @@ MemberDef::MemberDef(const char *df,int dl,
{ {
tArgList=0; tArgList=0;
} }
// copy function arguments (if any) // copy function definition arguments (if any)
if (al) if (al)
{ {
argList = new ArgumentList; defArgList = new ArgumentList;
argList->setAutoDelete(TRUE); defArgList->setAutoDelete(TRUE);
ArgumentListIterator ali(*al); ArgumentListIterator ali(*al);
Argument *a; Argument *a;
for (;(a=ali.current());++ali) for (;(a=ali.current());++ali)
{ {
argList->append(new Argument(*a)); defArgList->append(new Argument(*a));
} }
argList->constSpecifier = al->constSpecifier; defArgList->constSpecifier = al->constSpecifier;
argList->volatileSpecifier = al->volatileSpecifier; defArgList->volatileSpecifier = al->volatileSpecifier;
argList->pureSpecifier = al->pureSpecifier; defArgList->pureSpecifier = al->pureSpecifier;
}
else
{
defArgList=0;
}
// convert function declaration arguments (if any)
if (!args.isEmpty())
{
declArgList = new ArgumentList;
stringToArgumentList(args,declArgList);
} }
else else
{ {
argList=0; declArgList = 0;
} }
m_templateMaster=0; m_templateMaster=0;
classSectionSDict=0; classSectionSDict=0;
docsForDefinition=TRUE;
} }
/*! Destroys the member definition. */ /*! Destroys the member definition. */
...@@ -358,18 +371,19 @@ MemberDef::~MemberDef() ...@@ -358,18 +371,19 @@ MemberDef::~MemberDef()
delete redefinedBy; delete redefinedBy;
delete exampleSDict; delete exampleSDict;
delete enumFields; delete enumFields;
delete argList; delete defArgList;
delete tArgList; delete tArgList;
delete m_defTmpArgLists; delete m_defTmpArgLists;
delete classSectionSDict; delete classSectionSDict;
delete declArgList;
} }
void MemberDef::setReimplements(MemberDef *md) void MemberDef::setReimplements(MemberDef *md)
{ {
if (m_templateMaster) //if (m_templateMaster)
{ //{
m_templateMaster->setReimplements(md); // m_templateMaster->setReimplements(md);
} //}
redefines=md; redefines=md;
} }
...@@ -380,7 +394,17 @@ void MemberDef::insertReimplementedBy(MemberDef *md) ...@@ -380,7 +394,17 @@ void MemberDef::insertReimplementedBy(MemberDef *md)
m_templateMaster->insertReimplementedBy(md); m_templateMaster->insertReimplementedBy(md);
} }
if (redefinedBy==0) redefinedBy = new MemberList; if (redefinedBy==0) redefinedBy = new MemberList;
redefinedBy->inSort(md); if (redefinedBy->find(md)==-1) redefinedBy->inSort(md);
}
MemberDef *MemberDef::reimplements() const
{
return redefines;
}
MemberList *MemberDef::reimplementedBy() const
{
return redefinedBy;
} }
void MemberDef::insertEnumField(MemberDef *md) void MemberDef::insertEnumField(MemberDef *md)
...@@ -831,7 +855,7 @@ void MemberDef::writeDeclaration(OutputList &ol, ...@@ -831,7 +855,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
!annMemb) !annMemb)
{ {
ol.startMemberDescription(); ol.startMemberDescription();
parseDoc(ol,m_defFileName,m_defLine,cname,name(),briefDescription()); parseDoc(ol,m_defFileName,m_defLine,cname,this,briefDescription());
if (detailsVisible) if (detailsVisible)
{ {
ol.pushGeneratorState(); ol.pushGeneratorState();
...@@ -878,7 +902,7 @@ bool MemberDef::isDetailedSectionLinkable() const ...@@ -878,7 +902,7 @@ bool MemberDef::isDetailedSectionLinkable() const
//(initLines>0 && initLines<maxInitLines) || //(initLines>0 && initLines<maxInitLines) ||
hasMultiLineInitializer() || hasMultiLineInitializer() ||
// has one or more documented arguments // has one or more documented arguments
(argList!=0 && argList->hasDocumentation()); (defArgList!=0 && defArgList->hasDocumentation());
// this is not a global static or global statics should be extracted // this is not a global static or global statics should be extracted
bool staticFilter = getClassDef()!=0 || !isStatic() || Config_getBool("EXTRACT_STATIC"); bool staticFilter = getClassDef()!=0 || !isStatic() || Config_getBool("EXTRACT_STATIC");
...@@ -1136,7 +1160,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, ...@@ -1136,7 +1160,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
ol.docify("]"); ol.docify("]");
ol.endTypewriter(); ol.endTypewriter();
} }
if (!isDefine() && argList) ol.endParameterList(); if (!isDefine() && defArgList) ol.endParameterList();
ol.endMemberDoc(); ol.endMemberDoc();
ol.endDoxyAnchor(cfname,anchor()); ol.endDoxyAnchor(cfname,anchor());
ol.startIndent(); ol.startIndent();
...@@ -1171,7 +1195,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, ...@@ -1171,7 +1195,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
QCString detailed = m_templateMaster ? QCString detailed = m_templateMaster ?
m_templateMaster->documentation() : documentation(); m_templateMaster->documentation() : documentation();
ArgumentList *docArgList = m_templateMaster ? ArgumentList *docArgList = m_templateMaster ?
m_templateMaster->argList : argList; m_templateMaster->defArgList : defArgList;
/* write brief description */ /* write brief description */
if (!brief.isEmpty() && if (!brief.isEmpty() &&
...@@ -1180,23 +1204,23 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, ...@@ -1180,23 +1204,23 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
) /* || !annMemb */ ) /* || !annMemb */
) )
{ {
parseDoc(ol,m_defFileName,m_defLine,scopeName,name(),brief); parseDoc(ol,m_defFileName,m_defLine,scopeName,this,brief);
ol.newParagraph(); ol.newParagraph();
} }
/* write detailed description */ /* write detailed description */
if (!detailed.isEmpty()) if (!detailed.isEmpty())
{ {
parseDoc(ol,m_defFileName,m_defLine,scopeName,name(),detailed+"\n"); parseDoc(ol,m_defFileName,m_defLine,scopeName,this,detailed+"\n");
ol.pushGeneratorState(); ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::RTF); ol.disableAllBut(OutputGenerator::RTF);
ol.newParagraph(); ol.newParagraph();
ol.popGeneratorState(); ol.popGeneratorState();
} }
//printf("***** argList=%p name=%s docs=%s hasDocs=%d\n", //printf("***** defArgList=%p name=%s docs=%s hasDocs=%d\n",
// argList, // defArgList,
// argList?argList->hasDocumentation():-1); // defArgList?defArgList->hasDocumentation():-1);
if (docArgList && docArgList->hasDocumentation()) if (docArgList && docArgList->hasDocumentation())
{ {
//printf("***** argumentList is documented\n"); //printf("***** argumentList is documented\n");
...@@ -1215,7 +1239,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, ...@@ -1215,7 +1239,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
ol.docify(a->name); ol.docify(a->name);
ol.endDescTableTitle(); ol.endDescTableTitle();
ol.startDescTableData(); ol.startDescTableData();
parseDoc(ol,m_defFileName,m_defLine,scopeName,name(),a->docs+"\n"); parseDoc(ol,m_defFileName,m_defLine,scopeName,this,a->docs+"\n");
ol.endDescTableData(); ol.endDescTableData();
} }
} }
...@@ -1270,7 +1294,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, ...@@ -1270,7 +1294,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
if (!fmd->briefDescription().isEmpty()) if (!fmd->briefDescription().isEmpty())
{ {
parseDoc(ol,m_defFileName,m_defLine,scopeName,fmd->name(),fmd->briefDescription()); parseDoc(ol,m_defFileName,m_defLine,scopeName,fmd,fmd->briefDescription());
//ol.newParagraph(); //ol.newParagraph();
} }
if (!fmd->briefDescription().isEmpty() && if (!fmd->briefDescription().isEmpty() &&
...@@ -1280,7 +1304,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol, ...@@ -1280,7 +1304,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
} }
if (!fmd->documentation().isEmpty()) if (!fmd->documentation().isEmpty())
{ {
parseDoc(ol,m_defFileName,m_defLine,scopeName,fmd->name(),fmd->documentation()+"\n"); parseDoc(ol,m_defFileName,m_defLine,scopeName,fmd,fmd->documentation()+"\n");
} }
ol.endDescTableData(); ol.endDescTableData();
} }
...@@ -1531,7 +1555,7 @@ bool MemberDef::hasDocumentation() const ...@@ -1531,7 +1555,7 @@ bool MemberDef::hasDocumentation() const
{ {
return Definition::hasDocumentation() || return Definition::hasDocumentation() ||
(mtype==Enumeration && docEnumValues) || // has enum values (mtype==Enumeration && docEnumValues) || // has enum values
(argList!=0 && argList->hasDocumentation()); // has doc arguments (defArgList!=0 && defArgList->hasDocumentation()); // has doc arguments
} }
void MemberDef::setMemberGroup(MemberGroup *grp) void MemberDef::setMemberGroup(MemberGroup *grp)
...@@ -1605,10 +1629,10 @@ MemberDef *MemberDef::createTemplateInstanceMember( ...@@ -1605,10 +1629,10 @@ MemberDef *MemberDef::createTemplateInstanceMember(
{ {
//printf(" Member %s %s %s\n",typeString(),name().data(),argsString()); //printf(" Member %s %s %s\n",typeString(),name().data(),argsString());
ArgumentList *actualArgList = 0; ArgumentList *actualArgList = 0;
if (argList) if (defArgList)
{ {
actualArgList = new ArgumentList; actualArgList = new ArgumentList;
ArgumentListIterator ali(*argList); ArgumentListIterator ali(*defArgList);
Argument *arg; Argument *arg;
for (;(arg=ali.current());++ali) for (;(arg=ali.current());++ali)
{ {
...@@ -1616,9 +1640,9 @@ MemberDef *MemberDef::createTemplateInstanceMember( ...@@ -1616,9 +1640,9 @@ MemberDef *MemberDef::createTemplateInstanceMember(
actArg->type = substituteTemplateArgumentsInString(actArg->type,formalArgs,actualArgs); actArg->type = substituteTemplateArgumentsInString(actArg->type,formalArgs,actualArgs);
actualArgList->append(actArg); actualArgList->append(actArg);
} }
actualArgList->constSpecifier = argList->constSpecifier; actualArgList->constSpecifier = defArgList->constSpecifier;
actualArgList->volatileSpecifier = argList->volatileSpecifier; actualArgList->volatileSpecifier = defArgList->volatileSpecifier;
actualArgList->pureSpecifier = argList->pureSpecifier; actualArgList->pureSpecifier = defArgList->pureSpecifier;
} }
MemberDef *imd = new MemberDef( MemberDef *imd = new MemberDef(
...@@ -1629,7 +1653,7 @@ MemberDef *MemberDef::createTemplateInstanceMember( ...@@ -1629,7 +1653,7 @@ MemberDef *MemberDef::createTemplateInstanceMember(
exception, prot, exception, prot,
virt, stat, related, mtype, 0, 0 virt, stat, related, mtype, 0, 0
); );
imd->argList = actualArgList; imd->defArgList = actualArgList;
imd->def = substituteTemplateArgumentsInString(def,formalArgs,actualArgs); imd->def = substituteTemplateArgumentsInString(def,formalArgs,actualArgs);
imd->setBodyDef(getBodyDef()); imd->setBodyDef(getBodyDef());
imd->setBodySegment(getStartBodyLine(),getEndBodyLine()); imd->setBodySegment(getStartBodyLine(),getEndBodyLine());
......
...@@ -164,8 +164,8 @@ class MemberDef : public Definition ...@@ -164,8 +164,8 @@ class MemberDef : public Definition
// relation to other members // relation to other members
void setReimplements(MemberDef *md); void setReimplements(MemberDef *md);
void insertReimplementedBy(MemberDef *md); void insertReimplementedBy(MemberDef *md);
MemberDef *reimplements() const { return redefines; } MemberDef *reimplements() const;
MemberList *reimplementedBy() const { return redefinedBy; } MemberList *reimplementedBy() const;
// enumeration specific members // enumeration specific members
void insertEnumField(MemberDef *md); void insertEnumField(MemberDef *md);
...@@ -180,6 +180,7 @@ class MemberDef : public Definition ...@@ -180,6 +180,7 @@ class MemberDef : public Definition
bool hasDocumentedEnumValues() const { return docEnumValues; } bool hasDocumentedEnumValues() const { return docEnumValues; }
void setAnonymousEnumType(MemberDef *md) { annEnumType = md; } void setAnonymousEnumType(MemberDef *md) { annEnumType = md; }
MemberDef *getAnonymousEnumType() const { return annEnumType; } MemberDef *getAnonymousEnumType() const { return annEnumType; }
bool isDocsForDefinition() const { return docsForDefinition; }
// example related members // example related members
bool addExample(const char *anchor,const char *name,const char *file); bool addExample(const char *anchor,const char *name,const char *file);
...@@ -191,10 +192,17 @@ class MemberDef : public Definition ...@@ -191,10 +192,17 @@ class MemberDef : public Definition
bool isPrototype() const { return proto; } bool isPrototype() const { return proto; }
// argument related members // argument related members
ArgumentList *argumentList() const { return argList; } ArgumentList *argumentList() const { return defArgList; }
ArgumentList *declArgumentList() const { return declArgList; }
void setArgumentList(ArgumentList *al) void setArgumentList(ArgumentList *al)
{ if (argList) delete argList; {
argList = al; if (defArgList) delete defArgList;
defArgList = al;
}
void setDeclArgumentList(ArgumentList *al)
{
if (declArgList) delete declArgList;
declArgList = al;
} }
ArgumentList *templateArguments() const { return tArgList; } ArgumentList *templateArguments() const { return tArgList; }
void setDefinitionTemplateParameterLists(QList<ArgumentList> *lists); void setDefinitionTemplateParameterLists(QList<ArgumentList> *lists);
...@@ -234,6 +242,7 @@ class MemberDef : public Definition ...@@ -234,6 +242,7 @@ class MemberDef : public Definition
return bodyMemb ? bodyMemb->anchor() : anchor(); return bodyMemb ? bodyMemb->anchor() : anchor();
} }
void setBodyMember(MemberDef *md) { bodyMemb = md; } void setBodyMember(MemberDef *md) { bodyMemb = md; }
void setDocsForDefinition(bool b) { docsForDefinition = b; }
bool visited; bool visited;
...@@ -281,10 +290,9 @@ class MemberDef : public Definition ...@@ -281,10 +290,9 @@ class MemberDef : public Definition
int userInitLines; // result of explicit \hideinitializer or \showinitializer int userInitLines; // result of explicit \hideinitializer or \showinitializer
MemberList *section; // declation list containing this member MemberList *section; // declation list containing this member
MemberDef *annMemb; MemberDef *annMemb;
ArgumentList *argList; // argument list of this member ArgumentList *defArgList; // argument list of this member definition
ArgumentList *declArgList; // argument list of this member declaration
ArgumentList *tArgList; // template argument list of function template ArgumentList *tArgList; // template argument list of function template
//ArgumentList *scopeTAL; // template argument list of class template
//ArgumentList *membTAL; // template argument list of class template
QList<ArgumentList> *m_defTmpArgLists; QList<ArgumentList> *m_defTmpArgLists;
int grpId; // group id int grpId; // group id
MemberGroup *memberGroup; // group's member definition MemberGroup *memberGroup; // group's member definition
...@@ -302,6 +310,9 @@ class MemberDef : public Definition ...@@ -302,6 +310,9 @@ class MemberDef : public Definition
bool groupHasDocs; // true if the entry that caused the grouping was documented bool groupHasDocs; // true if the entry that caused the grouping was documented
MemberDef *m_templateMaster; MemberDef *m_templateMaster;
SIntDict<MemberList> *classSectionSDict; SIntDict<MemberList> *classSectionSDict;
bool docsForDefinition; // TRUE => documentation block is put before
// definition.
// FALSE => block is put before declaration.
// disable copying of member defs // disable copying of member defs
......
...@@ -142,8 +142,8 @@ void MemberGroup::distributeMemberGroupDocumentation() ...@@ -142,8 +142,8 @@ void MemberGroup::distributeMemberGroupDocumentation()
if (omd->documentation().isEmpty() && omd->briefDescription().isEmpty()) if (omd->documentation().isEmpty() && omd->briefDescription().isEmpty())
{ {
//printf("Copying documentation to member %s\n",omd->name().data()); //printf("Copying documentation to member %s\n",omd->name().data());
omd->setBriefDescription(md->briefDescription()); omd->setBriefDescription(md->briefDescription(),md->briefFile(),md->briefLine());
omd->setDocumentation(md->documentation()); omd->setDocumentation(md->documentation(),md->docFile(),md->docLine());
} }
omd=memberList->next(); omd=memberList->next();
} }
......
...@@ -343,7 +343,7 @@ void MemberList::writePlainDeclarations(OutputList &ol, ...@@ -343,7 +343,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,
ol.startMemberDescription(); ol.startMemberDescription();
parseDoc(ol, parseDoc(ol,
md->getDefFileName(),md->getDefLine(), md->getDefFileName(),md->getDefLine(),
cd?cd->name().data():0,md->name().data(), cd?cd->name().data():0,md,
md->briefDescription() md->briefDescription()
); );
if (md->isDetailedSectionLinkable()) if (md->isDetailedSectionLinkable())
......
...@@ -95,10 +95,10 @@ class BaseOutputDocInterface ...@@ -95,10 +95,10 @@ class BaseOutputDocInterface
* \param file The file in which the object is located. * \param file The file in which the object is located.
* \param anchor The anchor uniquely identifying the object within * \param anchor The anchor uniquely identifying the object within
* the file. * the file.
* \param text The text to display as a placeholder for the link. * \param name The text to display as a placeholder for the link.
*/ */
virtual void writeObjectLink(const char *ref,const char *file, virtual void writeObjectLink(const char *ref,const char *file,
const char *anchor, const char *text) = 0; const char *anchor, const char *name) = 0;
/*! Writes a link to an object in a code fragment. /*! Writes a link to an object in a code fragment.
* \param ref If this is non-zero, the object is to be found in * \param ref If this is non-zero, the object is to be found in
...@@ -106,10 +106,10 @@ class BaseOutputDocInterface ...@@ -106,10 +106,10 @@ class BaseOutputDocInterface
* \param file The file in which the object is located. * \param file The file in which the object is located.
* \param anchor The anchor uniquely identifying the object within * \param anchor The anchor uniquely identifying the object within
* the file. * the file.
* \param text The text to display as a placeholder for the link. * \param name The text to display as a placeholder for the link.
*/ */
virtual void writeCodeLink(const char *ref,const char *file, virtual void writeCodeLink(const char *ref,const char *file,
const char *anchor,const char *text) = 0; const char *anchor,const char *name) = 0;
/*! Starts a (link to an) URL found in the documentation. /*! Starts a (link to an) URL found in the documentation.
* \param url The URL to link to. * \param url The URL to link to.
......
...@@ -134,11 +134,11 @@ class OutputList : public OutputDocInterface ...@@ -134,11 +134,11 @@ class OutputList : public OutputDocInterface
void codify(const char *s) void codify(const char *s)
{ forall(&OutputGenerator::codify,s); } { forall(&OutputGenerator::codify,s); }
void writeObjectLink(const char *ref,const char *file, void writeObjectLink(const char *ref,const char *file,
const char *anchor, const char *text) const char *anchor, const char *name)
{ forall(&OutputGenerator::writeObjectLink,ref,file,anchor,text); } { forall(&OutputGenerator::writeObjectLink,ref,file,anchor,name); }
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 *name)
{ forall(&OutputGenerator::writeCodeLink,ref,file,anchor,text); } { forall(&OutputGenerator::writeCodeLink,ref,file,anchor,name); }
void startTextLink(const char *file,const char *anchor) void startTextLink(const char *file,const char *anchor)
{ forall(&OutputGenerator::startTextLink,file,anchor); } { forall(&OutputGenerator::startTextLink,file,anchor); }
void endTextLink() void endTextLink()
......
...@@ -1122,10 +1122,15 @@ BN [ \t\r\n] ...@@ -1122,10 +1122,15 @@ BN [ \t\r\n]
} }
<CopyLine>{ID}/{BN}*"(" { <CopyLine>{ID}/{BN}*"(" {
Define *def=0; Define *def=0;
//printf("Search for define %s\n",yytext); //def=g_fileDefineDict->find(yytext);
//printf("Search for define %s found=%d g_includeStack.isEmpty()=%d "
// "g_curlyCount=%d g_macroExpansion=%d g_expandOnlyPredef=%d "
// "isPreDefined=%d\n",yytext,def ? 1 : 0,
// g_includeStack.isEmpty(),g_curlyCount,g_macroExpansion,g_expandOnlyPredef,
// def ? def->isPredefined : -1
// );
if ((g_includeStack.isEmpty() || g_curlyCount>0) && if ((g_includeStack.isEmpty() || g_curlyCount>0) &&
g_macroExpansion && g_macroExpansion &&
/* (expandDefine=fileDefineCache->findDefine(g_yyFileName,yytext)) */
(def=g_fileDefineDict->find(yytext)) && (def=g_fileDefineDict->find(yytext)) &&
(!g_expandOnlyPredef || def->isPredefined) (!g_expandOnlyPredef || def->isPredefined)
) )
......
...@@ -41,7 +41,6 @@ RefList::~RefList() ...@@ -41,7 +41,6 @@ RefList::~RefList()
} }
/*! Adds a new item to the list. /*! Adds a new item to the list.
* \param text The item text.
* \returns A unique id for this item. * \returns A unique id for this item.
*/ */
int RefList::addRefItem() int RefList::addRefItem()
......
...@@ -79,12 +79,12 @@ class RTFGenerator : public OutputGenerator ...@@ -79,12 +79,12 @@ class RTFGenerator : public OutputGenerator
void docify(const char *text); void docify(const char *text);
void codify(const char *text); void codify(const char *text);
void writeObjectLink(const char *ref,const char *file, void writeObjectLink(const char *ref,const char *file,
const char *anchor,const char *text); const char *anchor,const char *name);
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 *name);
void startTextLink(const char *f,const char *anchor); void startTextLink(const char *f,const char *anchor);
void endTextLink(); void endTextLink();
void startHtmlLink(const char *); void startHtmlLink(const char *url);
void endHtmlLink(); void endHtmlLink();
void writeMailLink(const char *url); void writeMailLink(const char *url);
void startTypewriter() { t << "{\\f2 "; } void startTypewriter() { t << "{\\f2 "; }
......
...@@ -477,6 +477,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -477,6 +477,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
%x Function %x Function
%x FuncRound %x FuncRound
%x ExcpRound %x ExcpRound
%x ExcpList
%x FuncQual %x FuncQual
%x Operator %x Operator
%x Array %x Array
...@@ -1246,16 +1247,24 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -1246,16 +1247,24 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
if (yytext[yyleng-3]=='/') if (yytext[yyleng-3]=='/')
{ {
current->brief.resize(0); current->brief.resize(0);
current->briefLine = yyLineNr;
current->briefFile = yyFileName;
BEGIN(AfterDocLine); BEGIN(AfterDocLine);
} }
else if (yytext[yyleng-2]=='*' && Config_getBool("JAVADOC_AUTOBRIEF")) else if (yytext[yyleng-2]=='*' && Config_getBool("JAVADOC_AUTOBRIEF"))
{ {
current->brief.resize(0); current->brief.resize(0);
current->briefLine = yyLineNr;
current->briefFile = yyLineNr;
current->docLine = yyLineNr;
current->docFile = yyFileName;
BEGIN(AfterDocBrief); BEGIN(AfterDocBrief);
} }
else else
{ {
current->doc.resize(0); current->doc.resize(0);
current->docLine = yyLineNr;
current->docFile = yyFileName;
BEGIN(AfterDoc); BEGIN(AfterDoc);
} }
} }
...@@ -1266,16 +1275,24 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -1266,16 +1275,24 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
if (yytext[yyleng-3]=='/') if (yytext[yyleng-3]=='/')
{ {
current->brief.resize(0); current->brief.resize(0);
current->briefLine = yyLineNr;
current->briefFile = yyLineNr;
BEGIN(AfterDocLine); BEGIN(AfterDocLine);
} }
else if (yytext[yyleng-2]=='*' && Config_getBool("JAVADOC_AUTOBRIEF")) else if (yytext[yyleng-2]=='*' && Config_getBool("JAVADOC_AUTOBRIEF"))
{ {
current->brief.resize(0); current->brief.resize(0);
current->briefLine = yyLineNr;
current->briefFile = yyLineNr;
current->docLine = yyLineNr;
current->docFile = yyFileName;
BEGIN(AfterDocBrief); BEGIN(AfterDocBrief);
} }
else else
{ {
current->doc.resize(0); current->doc.resize(0);
current->docLine = yyLineNr;
current->docFile = yyFileName;
BEGIN(AfterDoc); BEGIN(AfterDoc);
} }
} }
...@@ -1292,16 +1309,22 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -1292,16 +1309,22 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
if (yytext[yyleng-3]=='/') if (yytext[yyleng-3]=='/')
{ {
current->brief.resize(0); current->brief.resize(0);
current->briefLine = yyLineNr;
current->briefFile = yyFileName;
BEGIN(AfterDocLine); BEGIN(AfterDocLine);
} }
else if (yytext[yyleng-2]=='*' && Config_getBool("JAVADOC_AUTOBRIEF")) else if (yytext[yyleng-2]=='*' && Config_getBool("JAVADOC_AUTOBRIEF"))
{ {
current->brief.resize(0); current->brief.resize(0);
current->briefLine = yyLineNr;
current->briefFile = yyFileName;
BEGIN(AfterDocBrief); BEGIN(AfterDocBrief);
} }
else else
{ {
current->doc.resize(0); current->doc.resize(0);
current->docLine = yyLineNr;
current->docFile = yyFileName;
BEGIN(AfterDoc); BEGIN(AfterDoc);
} }
} }
...@@ -1319,12 +1342,16 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -1319,12 +1342,16 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
if (yytext[1]=='/') // C++ style comment if (yytext[1]=='/') // C++ style comment
{ {
current->brief.resize(0); current->brief.resize(0);
current->briefLine = yyLineNr;
current->briefFile = yyFileName;
lastDocContext = YY_START; lastDocContext = YY_START;
BEGIN( LineDoc ); BEGIN( LineDoc );
} }
else // C style comment else // C style comment
{ {
current->doc.resize(0); current->doc.resize(0);
current->docLine = yyLineNr;
current->docFile = yyFileName;
lastDocContext = YY_START; lastDocContext = YY_START;
removeSlashes=FALSE; removeSlashes=FALSE;
BEGIN( Doc ); BEGIN( Doc );
...@@ -2195,7 +2222,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2195,7 +2222,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
<FuncQual>{BN}*"try"{BN}+ { /* try-function-block */ <FuncQual>{BN}*"try"{BN}+ { /* try-function-block */
insideTryBlock=TRUE; insideTryBlock=TRUE;
} }
<FuncQual>{BN}*"throw"{BN}*"(" { <FuncQual>{BN}*"throw"{BN}*"(" { // C++ style throw clause
current->exception = " throw (" ; current->exception = " throw (" ;
roundCount=0; roundCount=0;
lineCount() ; lineCount() ;
...@@ -2207,6 +2234,11 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2207,6 +2234,11 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
roundCount=0; roundCount=0;
BEGIN( ExcpRound ) ; BEGIN( ExcpRound ) ;
} }
<FuncQual>{BN}*"throws"{BN}+ { // Java style throw clause
current->exception = " throws " ;
lineCount() ;
BEGIN( ExcpList );
}
<ExcpRound>"(" { current->exception += *yytext ; <ExcpRound>"(" { current->exception += *yytext ;
++roundCount ; ++roundCount ;
} }
...@@ -2217,7 +2249,16 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2217,7 +2249,16 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
BEGIN( FuncQual ) ; BEGIN( FuncQual ) ;
} }
<ExcpRound>. { <ExcpRound>. {
current->exception += yytext; current->exception += *yytext;
}
<ExcpList>"{" {
unput('{'); BEGIN( FuncQual );
}
<ExcpList>"\n" {
current->exception += ' ';
}
<ExcpList>. {
current->exception += *yytext;
} }
<Function>"(" { current->type += current->name ; <Function>"(" { current->type += current->name ;
current->name = current->args ; current->name = current->args ;
...@@ -2235,29 +2276,17 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2235,29 +2276,17 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
current->name=current->name.simplifyWhiteSpace(); current->name=current->name.simplifyWhiteSpace();
current->type=current->type.simplifyWhiteSpace(); current->type=current->type.simplifyWhiteSpace();
current->args=current->args.simplifyWhiteSpace(); current->args=current->args.simplifyWhiteSpace();
//QCString &cn=current->name;
//QCString &rn=current_root->name;
//int i;
//if ((i=cn.findRev("::"))!=-1) // name contains scope
//{
// if (cn.left(i)==rn.right(i)) // scope name is redundant
// {
// cn=cn.right(cn.length()-i-2); // strip scope
// //printf("new name=`%s'\n",cn.data());
// }
//}
current->fileName = yyFileName; current->fileName = yyFileName;
current->startLine = yyLineNr; current->startLine = yyLineNr;
if (*yytext!=';' || (current_root->section&Entry::COMPOUND_MASK) ) if (*yytext!=';' || (current_root->section&Entry::COMPOUND_MASK) )
{ {
int tempArg=current->name.find('<'); int tempArg=current->name.find('<');
QCString tempName; QCString tempName;
if (tempArg==-1) static QRegExp re("operator[^a-z_A-Z0-9]");
tempName=current->name; if (tempArg==-1) tempName=current->name; else tempName=current->name.left(tempArg);
else if ((current->type.isEmpty() && tempName.find(re)==-1) ||
tempName=current->name.left(tempArg); current->type.left(8)=="typedef "
if (current->type.isEmpty() && tempName.find("operator")==-1 && )
(tempName.find('*')!=-1 || tempName.find('&')!=-1))
{ {
//printf("Scanner.l: found in class variable: `%s' `%s' `%s'\n", //printf("Scanner.l: found in class variable: `%s' `%s' `%s'\n",
// current->type.data(),current->name.data(),current->args.data()); // current->type.data(),current->name.data(),current->args.data());
...@@ -2268,12 +2297,13 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2268,12 +2297,13 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
//printf("Scanner.l: found in class function: `%s' `%s' `%s'\n", //printf("Scanner.l: found in class function: `%s' `%s' `%s'\n",
// current->type.data(),current->name.data(),current->args.data()); // current->type.data(),current->name.data(),current->args.data());
current->section = Entry::FUNCTION_SEC ; current->section = Entry::FUNCTION_SEC ;
current->proto = *yytext==';';
} }
} }
else // a global function prototype or function variable else // a global function prototype or function variable
{ {
static QRegExp re("([^)]*)");
//printf("Scanner.l: prototype? type=`%s' name=`%s' args=`%s'\n",current->type.data(),current->name.data(),current->args.data()); //printf("Scanner.l: prototype? type=`%s' name=`%s' args=`%s'\n",current->type.data(),current->name.data(),current->args.data());
QRegExp re("([^)]*)");
if (!current->type.isEmpty() && if (!current->type.isEmpty() &&
(current->type.find(re,0)!=-1 || current->type.left(8)=="typedef ")) (current->type.find(re,0)!=-1 || current->type.left(8)=="typedef "))
{ {
...@@ -2305,11 +2335,6 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2305,11 +2335,6 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
curlyCount=0; curlyCount=0;
BEGIN( SkipCurly ) ; BEGIN( SkipCurly ) ;
} }
//else if( *yytext == ':' )
//{
// //addToBody(yytext);
// BEGIN( SkipInits ) ;
//}
else else
{ {
if (previous->section!=Entry::VARIABLE_SEC) if (previous->section!=Entry::VARIABLE_SEC)
...@@ -2359,11 +2384,25 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2359,11 +2384,25 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
lastAfterDocContext = SkipCurlyEndDoc; lastAfterDocContext = SkipCurlyEndDoc;
afterDocTerminator = '}'; afterDocTerminator = '}';
if (yytext[yyleng-3]=='/') if (yytext[yyleng-3]=='/')
{
current->briefLine = yyLineNr;
current->briefFile = yyFileName;
BEGIN(AfterDocLine); BEGIN(AfterDocLine);
}
else if (yytext[yyleng-2]=='*' && Config_getBool("JAVADOC_AUTOBRIEF")) else if (yytext[yyleng-2]=='*' && Config_getBool("JAVADOC_AUTOBRIEF"))
{
current->briefLine = yyLineNr;
current->briefFile = yyFileName;
current->docLine = yyLineNr;
current->docFile = yyFileName;
BEGIN(AfterDocBrief); BEGIN(AfterDocBrief);
}
else else
{
current->docLine = yyLineNr;
current->docFile = yyFileName;
BEGIN(AfterDoc); BEGIN(AfterDoc);
}
} }
} }
<SkipCurlyEndDoc>"}" { <SkipCurlyEndDoc>"}" {
...@@ -2667,9 +2706,15 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2667,9 +2706,15 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
removeSlashes=(yytext[1]=='/'); removeSlashes=(yytext[1]=='/');
tmpDocType=-1; tmpDocType=-1;
if (YY_START==ReadBody) if (YY_START==ReadBody)
{
current->doc+="\n\n"; current->doc+="\n\n";
}
else else
{
current->doc.resize(0); current->doc.resize(0);
}
current->docLine = yyLineNr;
current->docFile = yyFileName;
lastDocContext = YY_START; lastDocContext = YY_START;
if (current_root->section & Entry::SCOPE_MASK) if (current_root->section & Entry::SCOPE_MASK)
{ {
...@@ -2696,9 +2741,15 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2696,9 +2741,15 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
{ {
tmpDocType=-1; tmpDocType=-1;
if (YY_START==ReadBody) if (YY_START==ReadBody)
{
current->doc+="\n\n"; current->doc+="\n\n";
}
else else
{
current->doc.resize(0); current->doc.resize(0);
}
current->docLine = yyLineNr;
current->docFile = yyFileName;
BEGIN( Doc ); BEGIN( Doc );
} }
else // Use the javadoc style else // Use the javadoc style
...@@ -2708,6 +2759,8 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2708,6 +2759,8 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
tmpDocType=-1; tmpDocType=-1;
current->doc+="\n\n"; current->doc+="\n\n";
lastDocContext = ReadBody; lastDocContext = ReadBody;
current->docLine = yyLineNr;
current->docFile = yyFileName;
BEGIN( Doc ); BEGIN( Doc );
} }
else else
...@@ -2715,6 +2768,10 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2715,6 +2768,10 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
tmpDocType=Doc; tmpDocType=Doc;
current->doc.resize(0); current->doc.resize(0);
current->brief.resize(0); current->brief.resize(0);
current->docLine = yyLineNr;
current->docFile = yyFileName;
current->briefLine = yyLineNr;
current->briefFile = yyFileName;
BEGIN( JavaDoc ); BEGIN( JavaDoc );
} }
} }
......
...@@ -13,15 +13,12 @@ ...@@ -13,15 +13,12 @@
* Brazilian Portuguese version by * Brazilian Portuguese version by
* Fabio "FJTC" Jun Takada Chino <chino@icmc.sc.usp.br> * Fabio "FJTC" Jun Takada Chino <chino@icmc.sc.usp.br>
* http://www.icmc.sc.usp.br/~chino * http://www.icmc.sc.usp.br/~chino
* Version: 1.2.11 (2001/11/23) * Version: 1.2.13 (2002/01/24)
*
* News:
* - Everything was revised.
*/ */
#ifndef TRANSLATOR_BR_H #ifndef TRANSLATOR_BR_H
#define TRANSLATOR_BR_H #define TRANSLATOR_BR_H
class TranslatorBrazilian: public TranslatorAdapter_1_2_13 class TranslatorBrazilian: public Translator
{ {
public: public:
...@@ -1313,5 +1310,26 @@ class TranslatorBrazilian: public TranslatorAdapter_1_2_13 ...@@ -1313,5 +1310,26 @@ class TranslatorBrazilian: public TranslatorAdapter_1_2_13
{ {
return "Referências"; return "Referências";
} }
//////////////////////////////////////////////////////////////////////////
// new since 1.2.13
//////////////////////////////////////////////////////////////////////////
/*! used in member documentation blocks to produce a list of
* members that are implemented by this one.
*/
virtual QCString trImplementedFromList(int numEntries)
{
return "Implementa "+trWriteList(numEntries)+".";
}
/*! used in member documentation blocks to produce a list of
* all members that implementation this member.
*/
virtual QCString trImplementedInList(int numEntries)
{
return "Implementado em "+trWriteList(numEntries)+".";
}
}; };
#endif #endif
...@@ -131,6 +131,9 @@ ...@@ -131,6 +131,9 @@
// 2001/11/06 // 2001/11/06
// - trReferences() implemented. // - trReferences() implemented.
// //
// 2002/01/23
// - trImplementedFromList() and trImplementedInList() implemented
// (new since 1.2.13)
// //
// Todo // Todo
// ---- // ----
...@@ -1479,6 +1482,26 @@ class TranslatorCzech : public TranslatorAdapter_1_2_13 ...@@ -1479,6 +1482,26 @@ class TranslatorCzech : public TranslatorAdapter_1_2_13
return decode("Odkazuje se na"); return decode("Odkazuje se na");
} }
//////////////////////////////////////////////////////////////////////////
// new since 1.2.13
//////////////////////////////////////////////////////////////////////////
/*! used in member documentation blocks to produce a list of
* members that are implemented by this one.
*/
virtual QCString trImplementedFromList(int numEntries)
{
return "Implementuje "+trWriteList(numEntries)+".";
}
/*! used in member documentation blocks to produce a list of
* all members that implement this member.
*/
virtual QCString trImplementedInList(int numEntries)
{
return "Implementováno v "+trWriteList(numEntries)+".";
}
}; };
#endif // TRANSLATOR_CZ_H #endif // TRANSLATOR_CZ_H
...@@ -1385,7 +1385,7 @@ class TranslatorEnglish : public Translator ...@@ -1385,7 +1385,7 @@ class TranslatorEnglish : public Translator
} }
/*! used in member documentation blocks to produce a list of /*! used in member documentation blocks to produce a list of
* all members that implementation this member. * all members that implement this abstract member.
*/ */
virtual QCString trImplementedInList(int numEntries) virtual QCString trImplementedInList(int numEntries)
{ {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* *
* *
* *
* Copyright (C) 1997-2002 by Dimitri van Heesch. * Copyright (C) 1997-2001 by Dimitri van Heesch.
* *
* Permission to use, copy, modify, and distribute this software and its * Permission to use, copy, modify, and distribute this software and its
* documentation under the terms of the GNU General Public License is hereby * documentation under the terms of the GNU General Public License is hereby
...@@ -33,11 +33,13 @@ ...@@ -33,11 +33,13 @@
* | QCString trIncludeFile() * | QCString trIncludeFile()
* | QCString trVerbatimText(const char *f) * | QCString trVerbatimText(const char *f)
* -------------+------------------------------------------------------------ * -------------+------------------------------------------------------------
* 2002-01-23 | Update for new since 1.2.13
* -------------+------------------------------------------------------------
*/ */
#ifndef TRANSLATOR_FR_H #ifndef TRANSLATOR_FR_H
#define TRANSLATOR_FR_H #define TRANSLATOR_FR_H
class TranslatorFrench : public TranslatorAdapter_1_2_13 class TranslatorFrench : public Translator
{ {
public: public:
QCString idLanguage() QCString idLanguage()
...@@ -1232,5 +1234,25 @@ class TranslatorFrench : public TranslatorAdapter_1_2_13 ...@@ -1232,5 +1234,25 @@ class TranslatorFrench : public TranslatorAdapter_1_2_13
{ {
return "Références"; return "Références";
} }
//////////////////////////////////////////////////////////////////////////
// new since 1.2.13
//////////////////////////////////////////////////////////////////////////
/*! used in member documentation blocks to produce a list of
* members that are implemented by this one.
*/
virtual QCString trImplementedFromList(int numEntries)
{
return "Implémente "+trWriteList(numEntries)+".";
}
/*! used in member documentation blocks to produce a list of
* all members that implementation this member.
*/
virtual QCString trImplementedInList(int numEntries)
{
return "Implémenté dans "+trWriteList(numEntries)+".";
}
}; };
#endif #endif
...@@ -44,11 +44,13 @@ ...@@ -44,11 +44,13 @@
// - Added strings for 1.2.11 // - Added strings for 1.2.11
// - better output for C documentation (trCompoundMembersDescription(), trClassDocumentation()) // - better output for C documentation (trCompoundMembersDescription(), trClassDocumentation())
// //
// 2001/11/13
// - Added strings for 1.2.13
#ifndef TRANSLATOR_HR_H #ifndef TRANSLATOR_HR_H
#define TRANSLATOR_HR_H #define TRANSLATOR_HR_H
class TranslatorCroatian : public TranslatorAdapter_1_2_13 class TranslatorCroatian : public Translator
{ {
private: private:
/*! to avoid macro redefinition from translator_cz.h */ /*! to avoid macro redefinition from translator_cz.h */
...@@ -1019,6 +1021,25 @@ class TranslatorCroatian : public TranslatorAdapter_1_2_13 ...@@ -1019,6 +1021,25 @@ class TranslatorCroatian : public TranslatorAdapter_1_2_13
{ {
return "Reference"; return "Reference";
} }
//////////////////////////////////////////////////////////////////////////
// new since 1.2.13
//////////////////////////////////////////////////////////////////////////
/*! used in member documentation blocks to produce a list of
* members that are implemented by this one.
*/
virtual QCString trImplementedFromList(int numEntries)
{
return "Implementira "+trWriteList(numEntries)+".";
}
/*! used in member documentation blocks to produce a list of
* all members that implementation this member.
*/
virtual QCString trImplementedInList(int numEntries)
{
return "Implementirano u "+trWriteList(numEntries)+".";
}
}; };
#endif #endif
...@@ -19,28 +19,29 @@ ...@@ -19,28 +19,29 @@
* *
* Revision history * Revision history
* *
* Initial Italian Translation by Ahmed Aldo Faisal * 2002/01: translated new items used since version 1.2.13
* Revised and completed by Alessandro Falappa (since June 1999) * updated e-mail address
* Updates: * 2001/11: corrected the translation fixing the issues reported by the translator.pl script
* 2001/11: corrected the translation fixing the issues reported by the translator.pl script * translated new items used since version 1.2.11
* translated new items used since version 1.2.11 * 2001/08: corrected the translation fixing the issues reported by the translator.pl script
* 2001/08: corrected the translation fixing the issues reported by the translator.pl script * translated new items used since version 1.2.7
* translated new items used since version 1.2.7 * 2001/05: adopted new translation mechanism (trough adapters),
* 2001/05: adopted new translation mechanism (trough adapters), * translated new items used since version 1.2.5 and 1.2.6,
* translated new items used since version 1.2.5 and 1.2.6, * revised those function returning strings in OPTIMIZE_OTPUT_FOR_C case,
* revised those function returning strings in OPTIMIZE_OTPUT_FOR_C case, * corrections regarding the plurals of some english terms mantained in the translation,
* corrections regarding the plurals of some english terms mantained in the translation, * changed some terms to better suit the sense
* changed some terms to better suit the sense * 2001/02: translated new items used since version 1.2.4
* 2001/02: translated new items used since version 1.2.4 * 2000/11: modified slightly the translation in trLegendDocs() function,
* 2000/11: modified slightly the translation in trLegendDocs() function, * translated new items used since version 1.2.1 and 1.2.2
* translated new items used since version 1.2.1 and 1.2.2 * 2000/08: translated new items used since version 1.1.3, 1.1.4, 1.1.5 and 1.2.0
* 2000/08: translated new items used since version 1.1.3, 1.1.4, 1.1.5 and 1.2.0 * 2000/03: translated new items used since version 1.0 and 1.1.0
* 2000/03: translated new items used since version 1.0 and 1.1.0 * 1999/19: entirely rewritten the translation to correct small variations due
* 1999/19: entirely rewritten the translation to correct small variations due * to feature additions and to conform to the layout of the latest
* to feature additions and to conform to the layout of the latest * commented translator.h for the english language
* commented translator.h for the english language * 1999/09: corrected some small typos in the "new since 0.49-990425" section
* 1999/09: corrected some small typos in the "new since 0.49-990425" section * added the "new since 0.49-990728" section
* added the "new since 0.49-990728" section * 1999/06: revised and completed by Alessandro Falappa (actual mantainer)
* 1999/??: initial italian translation by Ahmed Aldo Faisal
*/ */
/****************************************************************************** /******************************************************************************
...@@ -55,13 +56,13 @@ ...@@ -55,13 +56,13 @@
* tecnica (ad es "lista dei file" e non "lista dei files") * tecnica (ad es "lista dei file" e non "lista dei files")
* *
* Se avete suggerimenti sulla traduzione di alcuni termini o volete segnalare * Se avete suggerimenti sulla traduzione di alcuni termini o volete segnalare
* eventuali sviste potete scrivermi all'indirizzo: afalappa@interfree.it * eventuali sviste potete scrivermi all'indirizzo: alessandro@falappa.net
*/ */
#ifndef TRANSLATOR_IT_H #ifndef TRANSLATOR_IT_H
#define TRANSLATOR_IT_H #define TRANSLATOR_IT_H
class TranslatorItalian : public TranslatorAdapter_1_2_13 class TranslatorItalian : public Translator
{ {
public: public:
...@@ -1321,6 +1322,26 @@ class TranslatorItalian : public TranslatorAdapter_1_2_13 ...@@ -1321,6 +1322,26 @@ class TranslatorItalian : public TranslatorAdapter_1_2_13
{ {
return "Riferimenti"; return "Riferimenti";
} }
//////////////////////////////////////////////////////////////////////////
// new since 1.2.13
//////////////////////////////////////////////////////////////////////////
/*! used in member documentation blocks to produce a list of
* members that are implemented by this one.
*/
virtual QCString trImplementedFromList(int numEntries)
{
return "Implementa "+trWriteList(numEntries)+".";
}
/*! used in member documentation blocks to produce a list of
* all members that implementation this member.
*/
virtual QCString trImplementedInList(int numEntries)
{
return "Implementato in "+trWriteList(numEntries)+".";
}
}; };
#endif #endif
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
#ifndef TRANSLATOR_RU_H #ifndef TRANSLATOR_RU_H
#define TRANSLATOR_RU_H #define TRANSLATOR_RU_H
class TranslatorRussian : public TranslatorAdapter_1_2_13 class TranslatorRussian : public Translator
{ {
private: private:
/*! The Decode() inline assumes the source written in the /*! The Decode() inline assumes the source written in the
...@@ -746,7 +746,12 @@ class TranslatorRussian : public TranslatorAdapter_1_2_13 ...@@ -746,7 +746,12 @@ class TranslatorRussian : public TranslatorAdapter_1_2_13
*/ */
virtual QCString trReimplementedFromList(int numEntries) virtual QCString trReimplementedFromList(int numEntries)
{ {
return decode(" ")+trWriteList(numEntries)+"."; QCString result=" ";
if(numEntries>1)
result+=" ";
else
result+=" ";
return decode(result+" ")+trWriteList(numEntries)+".";
} }
/*! used in member documentation blocks to produce a list of /*! used in member documentation blocks to produce a list of
...@@ -1369,6 +1374,26 @@ class TranslatorRussian : public TranslatorAdapter_1_2_13 ...@@ -1369,6 +1374,26 @@ class TranslatorRussian : public TranslatorAdapter_1_2_13
return " "; return " ";
} }
//////////////////////////////////////////////////////////////////////////
// new since 1.2.13
//////////////////////////////////////////////////////////////////////////
/*! used in member documentation blocks to produce a list of
* members that are implemented by this one.
*/
virtual QCString trImplementedFromList(int numEntries)
{
return " "+trWriteList(numEntries)+".";
}
/*! used in member documentation blocks to produce a list of
* all members that implementation this member.
*/
virtual QCString trImplementedInList(int numEntries)
{
return " "+trWriteList(numEntries)+".";
}
}; };
#endif #endif
...@@ -570,7 +570,7 @@ QCString removeRedundantWhiteSpace(const QCString &s) ...@@ -570,7 +570,7 @@ QCString removeRedundantWhiteSpace(const QCString &s)
result+="< "; // insert extra space for layouting (nested) templates result+="< "; // insert extra space for layouting (nested) templates
} }
else if (i>0 && c=='>' && // current char is a > else if (i>0 && c=='>' && // current char is a >
(isId(s.at(i-1)) || isspace(s.at(i-1))) && // prev char is an id char or space (isId(s.at(i-1)) || isspace(s.at(i-1)) || s.at(i-1)=='*' || s.at(i-1)=='&') && // prev char is an id char or space
(i<8 || !findOperator(s,i)) // string in front is not "operator" (i<8 || !findOperator(s,i)) // string in front is not "operator"
) )
{ {
...@@ -1546,6 +1546,7 @@ static bool matchArgument(const Argument *srcA,const Argument *dstA, ...@@ -1546,6 +1546,7 @@ static bool matchArgument(const Argument *srcA,const Argument *dstA,
return TRUE; return TRUE;
} }
#if 0
static void mergeArgument(Argument *srcA,Argument *dstA, static void mergeArgument(Argument *srcA,Argument *dstA,
const QCString &className, const QCString &className,
const QCString &namespaceName, const QCString &namespaceName,
...@@ -1779,6 +1780,7 @@ done: ...@@ -1779,6 +1780,7 @@ done:
// dstA->type.data(),dstA->name.data()); // dstA->type.data(),dstA->name.data());
return; return;
} }
#endif
/*! /*!
...@@ -1885,8 +1887,8 @@ bool matchArguments(ArgumentList *srcAl,ArgumentList *dstAl, ...@@ -1885,8 +1887,8 @@ bool matchArguments(ArgumentList *srcAl,ArgumentList *dstAl,
++srcAli,++dstAli ++srcAli,++dstAli
) )
{ {
mergeArgument(srcA,dstA,className,namespaceName, //mergeArgument(srcA,dstA,className,namespaceName,
usingNamespaces,usingClasses); // usingNamespaces,usingClasses);
} }
MATCH MATCH
return TRUE; // all arguments match return TRUE; // all arguments match
...@@ -2213,7 +2215,12 @@ bool getDefs(const QCString &scName,const QCString &memberName, ...@@ -2213,7 +2215,12 @@ bool getDefs(const QCString &scName,const QCString &memberName,
} }
} }
} }
if (found) return TRUE; if (found)
{
gd=md->getGroupDef();
if (gd && gd->isLinkable()) nd=0; else gd=0;
return TRUE;
}
} }
else // no scope => global function else // no scope => global function
{ {
......
...@@ -930,7 +930,7 @@ static void writeXMLDocBlock(QTextStream &t, ...@@ -930,7 +930,7 @@ static void writeXMLDocBlock(QTextStream &t,
const QCString &fileName, const QCString &fileName,
int lineNr, int lineNr,
const QCString &scope, const QCString &scope,
const QCString &name, MemberDef *md,
const QCString &text) const QCString &text)
{ {
QCString stext = text.stripWhiteSpace(); QCString stext = text.stripWhiteSpace();
...@@ -938,10 +938,10 @@ static void writeXMLDocBlock(QTextStream &t, ...@@ -938,10 +938,10 @@ static void writeXMLDocBlock(QTextStream &t,
XMLGenerator *xmlGen = new XMLGenerator; XMLGenerator *xmlGen = new XMLGenerator;
//xmlGen->startParMode(); //xmlGen->startParMode();
parseDoc(*xmlGen, parseDoc(*xmlGen,
fileName, // input definition file fileName, // input definition file
lineNr, // input definition line lineNr, // input definition line
scope, // scope (which should not be linked to) scope, // scope (which should not be linked to)
name, // member (which should not be linked to) md, // member (which should not be linked to)
stext+"\n" // actual text stext+"\n" // actual text
); );
xmlGen->endParMode(); xmlGen->endParMode();
...@@ -1112,10 +1112,9 @@ static void generateXMLForMember(MemberDef *md,QTextStream &ti,QTextStream &t,De ...@@ -1112,10 +1112,9 @@ static void generateXMLForMember(MemberDef *md,QTextStream &ti,QTextStream &t,De
if (isFunc) //function if (isFunc) //function
{ {
ArgumentList *declAl = new ArgumentList; ArgumentList *declAl = md->declArgumentList();
ArgumentList *defAl = md->argumentList(); ArgumentList *defAl = md->argumentList();
stringToArgumentList(md->argsString(),declAl); if (declAl && declAl->count()>0)
if (declAl->count()>0)
{ {
ArgumentListIterator declAli(*declAl); ArgumentListIterator declAli(*declAl);
ArgumentListIterator defAli(*defAl); ArgumentListIterator defAli(*defAl);
...@@ -1164,7 +1163,6 @@ static void generateXMLForMember(MemberDef *md,QTextStream &ti,QTextStream &t,De ...@@ -1164,7 +1163,6 @@ static void generateXMLForMember(MemberDef *md,QTextStream &ti,QTextStream &t,De
if (defArg) ++defAli; if (defArg) ++defAli;
} }
} }
delete declAl;
} }
else if (md->memberType()==MemberDef::Define && else if (md->memberType()==MemberDef::Define &&
md->argsString()!=0) // define md->argsString()!=0) // define
...@@ -1213,10 +1211,10 @@ static void generateXMLForMember(MemberDef *md,QTextStream &ti,QTextStream &t,De ...@@ -1213,10 +1211,10 @@ static void generateXMLForMember(MemberDef *md,QTextStream &ti,QTextStream &t,De
} }
} }
t << " <briefdescription>" << endl; t << " <briefdescription>" << endl;
writeXMLDocBlock(t,md->getDefFileName(),md->getDefLine(),scopeName,md->name(),md->briefDescription()); writeXMLDocBlock(t,md->getDefFileName(),md->getDefLine(),scopeName,md,md->briefDescription());
t << " </briefdescription>" << endl; t << " </briefdescription>" << endl;
t << " <detaileddescription>" << endl; t << " <detaileddescription>" << endl;
writeXMLDocBlock(t,md->getDefFileName(),md->getDefLine(),scopeName,md->name(),md->documentation()); writeXMLDocBlock(t,md->getDefFileName(),md->getDefLine(),scopeName,md,md->documentation());
t << " </detaileddescription>" << endl; t << " </detaileddescription>" << endl;
if (md->getDefLine()!=-1) if (md->getDefLine()!=-1)
{ {
......
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