Commit e2eb1d33 authored by Dimitri van Heesch's avatar Dimitri van Heesch

Release-1.6.2-20100216

parent f22ba481
DOXYGEN Version 1.6.2-20100208 DOXYGEN Version 1.6.2-20100216
Please read the installation section of the manual Please read the installation section of the manual
(http://www.doxygen.org/install.html) for instructions. (http://www.doxygen.org/install.html) for instructions.
-------- --------
Dimitri van Heesch (08 February 2010) Dimitri van Heesch (16 February 2010)
DOXYGEN Version 1.6.2_20100208 DOXYGEN Version 1.6.2_20100216
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) (08 February 2010) Dimitri van Heesch (dimitri@stack.nl) (16 February 2010)
#ifndef CONFIG_H
#define CONFIG_H
#include <QHash>
#include <QString>
class Input;
class QTextStream;
class QTextCodec;
bool parseConfig(
const QString &fileName,
const QHash<QString,Input *> &options
);
void writeStringValue(QTextStream &t,QTextCodec *codec,const QString &s);
#endif
This diff is collapsed.
...@@ -20,7 +20,7 @@ doxygen_version_minor=6 ...@@ -20,7 +20,7 @@ doxygen_version_minor=6
doxygen_version_revision=2 doxygen_version_revision=2
#NOTE: Setting version_mmn to "NO" will omit mmn info from the package. #NOTE: Setting version_mmn to "NO" will omit mmn info from the package.
doxygen_version_mmn=20100208 doxygen_version_mmn=20100216
bin_dirs=`echo $PATH | sed -e "s/:/ /g"` bin_dirs=`echo $PATH | sed -e "s/:/ /g"`
......
...@@ -23,7 +23,7 @@ text fragments, generated by doxygen, can be produced in languages other ...@@ -23,7 +23,7 @@ text fragments, generated by doxygen, can be produced in languages other
than English (the default). The output language is chosen through the than English (the default). The output language is chosen through the
configuration file (with default name and known as Doxyfile). configuration file (with default name and known as Doxyfile).
Currently (version 1.6.1), 38 languages Currently (version 1.6.2), 38 languages
are supported (sorted alphabetically): are supported (sorted alphabetically):
Afrikaans, Arabic, Brazilian Portuguese, Catalan, Chinese, Chinese Afrikaans, Arabic, Brazilian Portuguese, Catalan, Chinese, Chinese
Traditional, Croatian, Czech, Danish, Dutch, English, Esperanto, Traditional, Croatian, Czech, Danish, Dutch, English, Esperanto,
......
...@@ -173,7 +173,7 @@ class Transl: ...@@ -173,7 +173,7 @@ class Transl:
self.missingMethods = None # list of prototypes to be implemented self.missingMethods = None # list of prototypes to be implemented
self.implementedMethods = None # list of implemented required methods self.implementedMethods = None # list of implemented required methods
self.adaptMinClass = None # The newest adapter class that can be used self.adaptMinClass = None # The newest adapter class that can be used
self.isDecodedTranslator = None # Flag related to internal usage of UTF-8
def __tokenGenerator(self): def __tokenGenerator(self):
"""Generator that reads the file and yields tokens as 4-tuples. """Generator that reads the file and yields tokens as 4-tuples.
...@@ -1094,6 +1094,13 @@ class Transl: ...@@ -1094,6 +1094,13 @@ class Transl:
else: else:
self.missingMethods.append(p) self.missingMethods.append(p)
# Set the least important note first if the translator is decoded.
# If yes, then it means that the implementation should be switched
# to UTF-8 later (suggestion).
self.isDecodedTranslator = self.classId in self.manager.decodedTranslators
if self.isDecodedTranslator:
self.note = 'Reimplementation using UTF-8 suggested.'
# Check whether adapter must be used or suggest the newest one. # Check whether adapter must be used or suggest the newest one.
# Change the status and set the note accordingly. # Change the status and set the note accordingly.
if self.baseClassId != 'Translator': if self.baseClassId != 'Translator':
...@@ -1277,10 +1284,44 @@ class TrManager: ...@@ -1277,10 +1284,44 @@ class TrManager:
self.numLang = None # excluding coupled En-based self.numLang = None # excluding coupled En-based
self.doxVersion = None # Doxygen version self.doxVersion = None # Doxygen version
# Capture the knowledge about translators that are not implemented
# to use UTF-8 internally.
self.decodedTranslators = self.getDecodedTranslators()
# Build objects where each one is responsible for one translator. # Build objects where each one is responsible for one translator.
self.__build() self.__build()
def getDecodedTranslators(self):
"""Parses language.cpp to find what translators do not use UTF-8 yet"""
decodedTranslators = []
# Regular expression to detect the lines like
# theTranslator=new TranslatorDecoder(new TranslatorSwedish);
rex = re.compile(r'^\s*theTranslator\s*=\s*new\s+.*$')
# Regular expression to get the (optional) TranslatorDecoder and TranslatorXXX
rex2 = re.compile(r'\bTranslator\w+')
# Parse the lines in the specific source code.
f = open(os.path.join(self.src_path, 'language.cpp'), 'rU')
for line in f:
if rex.match(line):
lst = rex2.findall(line)
if lst[0] == 'TranslatorDecoder':
decodedTranslators.append(lst[1])
f.close()
# Display warning when all translator implementations were converted
# to UTF-8.
if len(decodedTranslators) == 0:
print 'This script should be updated. All translators do use UTF-8'
print 'internally. The TranslatorDecoder adapter should be removed'
print 'from the code and its usage should not be checked any more.'
return decodedTranslators
def __build(self): def __build(self):
"""Find the translator files and build the objects for translators.""" """Find the translator files and build the objects for translators."""
......
(1.6.1) (1.6.2)
Doxygen supports the following 38 languages (sorted alphabetically): Doxygen supports the following 38 languages (sorted alphabetically):
...@@ -19,13 +19,13 @@ alphabetically). This means that they derive from the Translator class ...@@ -19,13 +19,13 @@ alphabetically). This means that they derive from the Translator class
and they implement all 221 of the required methods. Anyway, there and they implement all 221 of the required methods. Anyway, there
still may be some details listed even for them: still may be some details listed even for them:
TranslatorBrazilian TranslatorBrazilian -- Reimplementation using UTF-8 suggested.
TranslatorCzech TranslatorCzech
TranslatorDutch TranslatorDutch
TranslatorEnglish TranslatorEnglish
TranslatorFrench -- The MAX_DOT_GRAPH_HEIGHT found in trLegendDocs() TranslatorFrench -- Reimplementation using UTF-8 suggested.
TranslatorKorean TranslatorKorean -- Reimplementation using UTF-8 suggested.
TranslatorPolish -- Remove the obsolete methods (never used). TranslatorPolish -- Reimplementation using UTF-8 suggested.
---------------------------------------------------------------------- ----------------------------------------------------------------------
The following translator classes need some maintenance (the most The following translator classes need some maintenance (the most
...@@ -36,34 +36,80 @@ must be implemented to become up-to-date: ...@@ -36,34 +36,80 @@ must be implemented to become up-to-date:
TranslatorVietnamese 1.6.0 5 methods to implement (2 %) TranslatorVietnamese 1.6.0 5 methods to implement (2 %)
TranslatorTurkish 1.6.0 5 methods to implement (2 %) TranslatorTurkish 1.6.0 5 methods to implement (2 %)
TranslatorSwedish 1.6.0 5 methods to implement (2 %) TranslatorSwedish 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorSpanish 1.6.0 5 methods to implement (2 %) TranslatorSpanish 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorSerbian 1.6.0 5 methods to implement (2 %) TranslatorSerbian 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorSerbianCyrilic 1.6.0 5 methods to implement (2 %) TranslatorSerbianCyrilic 1.6.0 5 methods to implement (2 %)
TranslatorRussian 1.6.0 5 methods to implement (2 %) TranslatorRussian 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorRomanian 1.6.0 5 methods to implement (2 %) TranslatorRomanian 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorPersian 1.6.0 5 methods to implement (2 %) TranslatorPersian 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorMacedonian 1.6.0 5 methods to implement (2 %) TranslatorMacedonian 1.6.0 5 methods to implement (2 %)
TranslatorJapanese 1.6.0 5 methods to implement (2 %) TranslatorJapanese 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorItalian 1.6.0 5 methods to implement (2 %) TranslatorItalian 1.6.0 5 methods to implement (2 %)
TranslatorGerman 1.6.0 5 methods to implement (2 %) TranslatorGerman 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorFinnish 1.6.0 5 methods to implement (2 %) TranslatorFinnish 1.6.0 5 methods to implement (2 %)
TranslatorEsperanto 1.6.0 5 methods to implement (2 %) TranslatorEsperanto 1.6.0 5 methods to implement (2 %)
TranslatorCroatian 1.6.0 5 methods to implement (2 %) TranslatorCroatian 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorChinese 1.6.0 5 methods to implement (2 %) TranslatorChinese 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorChinesetraditional 1.6.0 5 methods to implement (2 %) TranslatorChinesetraditional 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorCatalan 1.6.0 5 methods to implement (2 %) TranslatorCatalan 1.6.0 5 methods to implement (2 %)
TranslatorAfrikaans 1.6.0 5 methods to implement (2 %) TranslatorAfrikaans 1.6.0 5 methods to implement (2 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorGreek 1.5.4 27 methods to implement (12 %) TranslatorGreek 1.5.4 27 methods to implement (12 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorDanish 1.5.4 27 methods to implement (12 %) TranslatorDanish 1.5.4 27 methods to implement (12 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorSlovene 1.4.6 29 methods to implement (13 %) TranslatorSlovene 1.4.6 29 methods to implement (13 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorNorwegian 1.4.6 28 methods to implement (12 %) TranslatorNorwegian 1.4.6 28 methods to implement (12 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorLithuanian 1.4.6 29 methods to implement (13 %) TranslatorLithuanian 1.4.6 29 methods to implement (13 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorIndonesian 1.4.6 28 methods to implement (12 %) TranslatorIndonesian 1.4.6 28 methods to implement (12 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorHungarian 1.4.6 29 methods to implement (13 %) TranslatorHungarian 1.4.6 29 methods to implement (13 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorArabic 1.4.6 28 methods to implement (12 %) TranslatorArabic 1.4.6 28 methods to implement (12 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorUkrainian 1.4.1 29 methods to implement (13 %) TranslatorUkrainian 1.4.1 29 methods to implement (13 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorPortuguese 1.3.3 40 methods to implement (18 %) TranslatorPortuguese 1.3.3 40 methods to implement (18 %)
Note: Reimplementation using UTF-8 suggested.
TranslatorSlovak 1.2.18 49 methods to implement (22 %) TranslatorSlovak 1.2.18 49 methods to implement (22 %)
Note: Reimplementation using UTF-8 suggested.
---------------------------------------------------------------------- ----------------------------------------------------------------------
The following translator classes derive directly from the The following translator classes derive directly from the
...@@ -71,8 +117,8 @@ TranslatorEnglish. The class identifier has the suffix 'En' that says ...@@ -71,8 +117,8 @@ TranslatorEnglish. The class identifier has the suffix 'En' that says
that this is intentional. Usually, there is also a non-English based that this is intentional. Usually, there is also a non-English based
version of the translator for the language: version of the translator for the language:
TranslatorJapaneseEn implements 5 methods TranslatorJapaneseEn implements 5 methods -- Reimplementation using UTF-8 suggested.
TranslatorKoreanEn implements 5 methods TranslatorKoreanEn implements 5 methods -- Reimplementation using UTF-8 suggested.
====================================================================== ======================================================================
WARNING: The following translator methods are declared in the WARNING: The following translator methods are declared in the
...@@ -154,6 +200,12 @@ TranslatorArabic (TranslatorAdapter_1_4_6) 28 methods to implement (12 %) ...@@ -154,6 +200,12 @@ TranslatorArabic (TranslatorAdapter_1_4_6) 28 methods to implement (12 %)
virtual QCString trNoDescriptionAvailable() virtual QCString trNoDescriptionAvailable()
TranslatorBrazilian (Translator)
-------------------
Implements 221 of the required methods (100 %).
TranslatorCatalan (TranslatorAdapter_1_6_0) 5 methods to implement (2 %) TranslatorCatalan (TranslatorAdapter_1_6_0) 5 methods to implement (2 %)
----------------- -----------------
...@@ -483,6 +535,12 @@ TranslatorJapaneseEn (TranslatorEnglish) 216 methods to implement (97 %) ...@@ -483,6 +535,12 @@ TranslatorJapaneseEn (TranslatorEnglish) 216 methods to implement (97 %)
virtual QCString latexLanguageSupportCommand() virtual QCString latexLanguageSupportCommand()
TranslatorKorean (Translator)
----------------
Implements 221 of the required methods (100 %).
TranslatorKoreanEn (TranslatorEnglish) 216 methods to implement (97 %) TranslatorKoreanEn (TranslatorEnglish) 216 methods to implement (97 %)
------------------ ------------------
......
...@@ -773,7 +773,7 @@ stylesheet in the HTML output directory as well, or it will be erased! ...@@ -773,7 +773,7 @@ stylesheet in the HTML output directory as well, or it will be erased!
If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML
page will contain the date and time when the page was generated. Setting page will contain the date and time when the page was generated. Setting
this to NO can help when comparing the output of multiple runs. this to NO can help when comparing the output of multiple runs.
' defval='0' depends='GENERATE_HTML'/> ' defval='1' depends='GENERATE_HTML'/>
<option type='bool' id='HTML_ALIGN_MEMBERS' docs=' <option type='bool' id='HTML_ALIGN_MEMBERS' docs='
If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes,
files or namespaces will be aligned in HTML using tables. If set to files or namespaces will be aligned in HTML using tables. If set to
......
...@@ -1105,7 +1105,7 @@ void addConfigOptions(Config *cfg) ...@@ -1105,7 +1105,7 @@ void addConfigOptions(Config *cfg)
"If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML\n" "If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML\n"
"page will contain the date and time when the page was generated. Setting\n" "page will contain the date and time when the page was generated. Setting\n"
"this to NO can help when comparing the output of multiple runs.", "this to NO can help when comparing the output of multiple runs.",
FALSE TRUE
); );
cb->addDependency("GENERATE_HTML"); cb->addDependency("GENERATE_HTML");
//---- //----
......
...@@ -20,8 +20,11 @@ ...@@ -20,8 +20,11 @@
Define::Define() Define::Define()
{ {
undef=FALSE;
fileDef=0; fileDef=0;
lineNr=1;
nargs=-1;
undef=FALSE;
varArgs=FALSE;
isPredefined=FALSE; isPredefined=FALSE;
nonRecursive=FALSE; nonRecursive=FALSE;
} }
...@@ -33,6 +36,9 @@ Define::Define(const Define &d) ...@@ -33,6 +36,9 @@ Define::Define(const Define &d)
lineNr=d.lineNr; lineNr=d.lineNr;
nargs=d.nargs; nargs=d.nargs;
undef=d.undef; undef=d.undef;
varArgs=d.varArgs;
isPredefined=d.isPredefined;
nonRecursive=d.nonRecursive;
fileDef=0; fileDef=0;
} }
......
...@@ -1146,6 +1146,7 @@ void Definition::makePartOfGroup(GroupDef *gd) ...@@ -1146,6 +1146,7 @@ void Definition::makePartOfGroup(GroupDef *gd)
void Definition::setRefItems(const QList<ListItemInfo> *sli) void Definition::setRefItems(const QList<ListItemInfo> *sli)
{ {
//printf("%s::setRefItems()\n",name().data());
if (sli) if (sli)
{ {
makeResident(); makeResident();
...@@ -1166,6 +1167,7 @@ void Definition::setRefItems(const QList<ListItemInfo> *sli) ...@@ -1166,6 +1167,7 @@ void Definition::setRefItems(const QList<ListItemInfo> *sli)
void Definition::mergeRefItems(Definition *d) void Definition::mergeRefItems(Definition *d)
{ {
//printf("%s::mergeRefItems()\n",name().data());
LockingPtr< QList<ListItemInfo> > xrefList = d->xrefListItems(); LockingPtr< QList<ListItemInfo> > xrefList = d->xrefListItems();
if (xrefList!=0) if (xrefList!=0)
{ {
......
...@@ -999,7 +999,7 @@ void ClassDiagram::writeFigure(QTextStream &output,const char *path, ...@@ -999,7 +999,7 @@ void ClassDiagram::writeFigure(QTextStream &output,const char *path,
} }
//output << "}\n"; //output << "}\n";
output << ":\\begin{figure}[H]\n" output << "\\begin{figure}[H]\n"
"\\begin{center}\n" "\\begin{center}\n"
"\\leavevmode\n"; "\\leavevmode\n";
output << "\\includegraphics[height=" << realHeight << "cm]{" output << "\\includegraphics[height=" << realHeight << "cm]{"
......
...@@ -6617,6 +6617,7 @@ static void addEnumValuesToEnums(EntryNav *rootNav) ...@@ -6617,6 +6617,7 @@ static void addEnumValuesToEnums(EntryNav *rootNav)
fmd->setMaxInitLines(root->initLines); fmd->setMaxInitLines(root->initLines);
fmd->setMemberGroupId(root->mGrpId); fmd->setMemberGroupId(root->mGrpId);
fmd->setExplicitExternal(root->explicitExternal); fmd->setExplicitExternal(root->explicitExternal);
fmd->setRefItems(root->sli);
if (fmd) if (fmd)
{ {
md->insertEnumField(fmd); md->insertEnumField(fmd);
...@@ -7737,6 +7738,16 @@ static void findDirDocumentation(EntryNav *rootNav) ...@@ -7737,6 +7738,16 @@ static void findDirDocumentation(EntryNav *rootNav)
QCString normalizedName = root->name; QCString normalizedName = root->name;
normalizedName = substitute(normalizedName,"\\","/"); normalizedName = substitute(normalizedName,"\\","/");
//printf("root->docFile=%s normalizedName=%s\n",
// root->docFile.data(),normalizedName.data());
if (root->docFile==normalizedName) // current dir?
{
int lastSlashPos=normalizedName.findRev('/');
if (lastSlashPos!=-1) // strip file name
{
normalizedName=normalizedName.left(lastSlashPos);
}
}
if (normalizedName.at(normalizedName.length()-1)!='/') if (normalizedName.at(normalizedName.length()-1)!='/')
{ {
normalizedName+='/'; normalizedName+='/';
...@@ -7774,7 +7785,7 @@ static void findDirDocumentation(EntryNav *rootNav) ...@@ -7774,7 +7785,7 @@ static void findDirDocumentation(EntryNav *rootNav)
else else
{ {
warn(root->fileName,root->startLine,"Warning: No matching " warn(root->fileName,root->startLine,"Warning: No matching "
"directory found for command \\dir %s\n",root->name.data()); "directory found for command \\dir %s\n",normalizedName.data());
} }
rootNav->releaseEntry(); rootNav->releaseEntry();
} }
......
...@@ -369,37 +369,46 @@ hr.footer { ...@@ -369,37 +369,46 @@ hr.footer {
} }
.memname { .memname {
white-space: nowrap; white-space: nowrap;
font-weight: bold; font-weight: bold;
} margin-left: 6px;
.memproto, .memdoc {
border: 1px solid #84b0c7;
} }
.memproto { .memproto {
padding: 0; border-top: 1px solid #84b0c7;
background-color: #d5e1e8; border-left: 1px solid #84b0c7;
font-weight: bold; border-right: 1px solid #84b0c7;
-webkit-border-top-left-radius: 8px; padding: 0;
-webkit-border-top-right-radius: 8px; background-color: #d5e1e8;
-webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); font-weight: bold;
-moz-border-radius-topleft: 8px; /* firefox specific markup */
-moz-border-radius-topright: 8px; background-image: -moz-linear-gradient(rgba(228, 233, 245, 1.0) 0%, rgba(193, 205, 232, 1.0) 100%);
-moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px;
-moz-border-radius-topright: 8px;
-moz-border-radius-topleft: 8px;
/* webkit specific markup */
background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, from(rgba(228, 233, 245, 1.0)), to(rgba(193, 205, 232, 1.0)));
-webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);
-webkit-border-top-right-radius: 8px;
-webkit-border-top-left-radius: 8px;
} }
.memdoc { .memdoc {
padding: 2px 5px; border-bottom: 1px solid #84b0c7;
background-color: #eef3f5; border-left: 1px solid #84b0c7;
border-top-width: 0; border-right: 1px solid #84b0c7;
-webkit-border-bottom-left-radius: 8px; padding: 2px 5px;
-webkit-border-bottom-right-radius: 8px; background-color: #eef3f5;
-webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); border-top-width: 0;
-moz-border-radius-bottomleft: 8px; /* firefox specific markup */
-moz-border-radius-bottomright: 8px; -moz-border-radius-bottomleft: 8px;
-moz-border-radius-bottomright: 8px;
-moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px;
/* webkit specific markup */
-webkit-border-bottom-left-radius: 8px;
-webkit-border-bottom-right-radius: 8px;
-webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);
} }
.paramkey { .paramkey {
......
...@@ -369,37 +369,46 @@ ...@@ -369,37 +369,46 @@
"}\n" "}\n"
"\n" "\n"
".memname {\n" ".memname {\n"
" white-space: nowrap;\n" " white-space: nowrap;\n"
" font-weight: bold;\n" " font-weight: bold;\n"
"}\n" " margin-left: 6px;\n"
"\n"
".memproto, .memdoc {\n"
" border: 1px solid #84b0c7; \n"
"}\n" "}\n"
"\n" "\n"
".memproto {\n" ".memproto {\n"
" padding: 0;\n" " border-top: 1px solid #84b0c7; \n"
" background-color: #d5e1e8;\n" " border-left: 1px solid #84b0c7; \n"
" font-weight: bold;\n" " border-right: 1px solid #84b0c7; \n"
" -webkit-border-top-left-radius: 8px;\n" " padding: 0;\n"
" -webkit-border-top-right-radius: 8px;\n" " background-color: #d5e1e8;\n"
" -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);\n" " font-weight: bold;\n"
" -moz-border-radius-topleft: 8px;\n" " /* firefox specific markup */\n"
" -moz-border-radius-topright: 8px;\n" " background-image: -moz-linear-gradient(rgba(228, 233, 245, 1.0) 0%, rgba(193, 205, 232, 1.0) 100%);\n"
" -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px;\n" " -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px;\n"
" -moz-border-radius-topright: 8px;\n"
" -moz-border-radius-topleft: 8px;\n"
" /* webkit specific markup */\n"
" background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, from(rgba(228, 233, 245, 1.0)), to(rgba(193, 205, 232, 1.0)));\n"
" -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);\n"
" -webkit-border-top-right-radius: 8px;\n"
" -webkit-border-top-left-radius: 8px;\n"
"\n" "\n"
"}\n" "}\n"
"\n" "\n"
".memdoc {\n" ".memdoc {\n"
" padding: 2px 5px;\n" " border-bottom: 1px solid #84b0c7; \n"
" background-color: #eef3f5;\n" " border-left: 1px solid #84b0c7; \n"
" border-top-width: 0;\n" " border-right: 1px solid #84b0c7; \n"
" -webkit-border-bottom-left-radius: 8px;\n" " padding: 2px 5px;\n"
" -webkit-border-bottom-right-radius: 8px;\n" " background-color: #eef3f5;\n"
" -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);\n" " border-top-width: 0;\n"
" -moz-border-radius-bottomleft: 8px;\n" " /* firefox specific markup */\n"
" -moz-border-radius-bottomright: 8px;\n" " -moz-border-radius-bottomleft: 8px;\n"
" -moz-border-radius-bottomright: 8px;\n"
" -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px;\n" " -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px;\n"
" /* webkit specific markup */\n"
" -webkit-border-bottom-left-radius: 8px;\n"
" -webkit-border-bottom-right-radius: 8px;\n"
" -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);\n"
"}\n" "}\n"
"\n" "\n"
".paramkey {\n" ".paramkey {\n"
......
...@@ -93,6 +93,7 @@ FileDef::FileDef(const char *p,const char *nm, ...@@ -93,6 +93,7 @@ FileDef::FileDef(const char *p,const char *nm,
docname.prepend(stripFromPath(path.copy())); docname.prepend(stripFromPath(path.copy()));
} }
m_isJava = name().right(5)==".java"; m_isJava = name().right(5)==".java";
m_isCSharp = name().right(5)==".cs";
memberGroupSDict = 0; memberGroupSDict = 0;
acquireFileVersion(); acquireFileVersion();
m_subGrouping=Config_getBool("SUBGROUPING"); m_subGrouping=Config_getBool("SUBGROUPING");
...@@ -1550,3 +1551,23 @@ bool FileDef::isLinkableInProject() const ...@@ -1550,3 +1551,23 @@ bool FileDef::isLinkableInProject() const
return hasDocumentation() && !isReference() && showFiles; return hasDocumentation() && !isReference() && showFiles;
} }
bool FileDef::includes(FileDef *incFile,QDict<FileDef> *includedFiles) const
{
if (incFile==this) return TRUE;
//printf("%s::includes(%s)\n",name().data(),incFile->name().data());
includedFiles->insert(absFilePath(),this);
if (includeList)
{
QListIterator<IncludeInfo> ili(*includeList);
IncludeInfo *ii;
for (;(ii=ili.current());++ili)
{
if (ii->fileDef &&
includedFiles->find(ii->fileDef->absFilePath())==0 &&
ii->fileDef->includes(incFile,includedFiles)) return TRUE;
}
}
return FALSE;
}
...@@ -125,6 +125,7 @@ class FileDef : public Definition ...@@ -125,6 +125,7 @@ class FileDef : public Definition
bool isIncluded(const QCString &name) const; bool isIncluded(const QCString &name) const;
bool isJava() const { return m_isJava; } bool isJava() const { return m_isJava; }
bool isCSharp() const { return m_isCSharp; }
void writeDocumentation(OutputList &ol); void writeDocumentation(OutputList &ol);
void writeMemberPages(OutputList &ol); void writeMemberPages(OutputList &ol);
...@@ -164,6 +165,7 @@ class FileDef : public Definition ...@@ -164,6 +165,7 @@ class FileDef : public Definition
void addListReferences(); void addListReferences();
bool isDocumentationFile() const; bool isDocumentationFile() const;
bool includes(FileDef *incFile,QDict<FileDef> *includedFiles) const;
MemberList *getMemberList(MemberList::ListType lt) const; MemberList *getMemberList(MemberList::ListType lt) const;
const QList<MemberList> &getMemberLists() const { return m_memberLists; } const QList<MemberList> &getMemberLists() const { return m_memberLists; }
...@@ -216,6 +218,7 @@ class FileDef : public Definition ...@@ -216,6 +218,7 @@ class FileDef : public Definition
QIntDict<MemberDef> *srcMemberDict; QIntDict<MemberDef> *srcMemberDict;
bool isSource; bool isSource;
bool m_isJava; bool m_isJava;
bool m_isCSharp;
QCString fileVersion; QCString fileVersion;
PackageDef *package; PackageDef *package;
DirDef *dir; DirDef *dir;
......
...@@ -1658,6 +1658,7 @@ void LatexGenerator::startClassDiagram() ...@@ -1658,6 +1658,7 @@ void LatexGenerator::startClassDiagram()
{ {
//if (Config_getBool("COMPACT_LATEX")) t << "\\subsubsection"; else t << "\\subsection"; //if (Config_getBool("COMPACT_LATEX")) t << "\\subsubsection"; else t << "\\subsection";
//t << "{"; //t << "{";
newParagraph();
} }
void LatexGenerator::endClassDiagram(const ClassDiagram &d, void LatexGenerator::endClassDiagram(const ClassDiagram &d,
...@@ -1812,6 +1813,7 @@ void LatexGenerator::endMemberGroup(bool hasHeader) ...@@ -1812,6 +1813,7 @@ void LatexGenerator::endMemberGroup(bool hasHeader)
void LatexGenerator::startDotGraph() void LatexGenerator::startDotGraph()
{ {
newParagraph();
} }
void LatexGenerator::endDotGraph(const DotClassGraph &g) void LatexGenerator::endDotGraph(const DotClassGraph &g)
......
...@@ -100,6 +100,7 @@ void ManGenerator::init() ...@@ -100,6 +100,7 @@ void ManGenerator::init()
static QCString buildFileName(const char *name) static QCString buildFileName(const char *name)
{ {
QCString fileName; QCString fileName;
if (name==0) return "noname";
const char *p=name; const char *p=name;
char c; char c;
...@@ -407,7 +408,7 @@ void ManGenerator::startDoxyAnchor(const char *,const char *manName, ...@@ -407,7 +408,7 @@ void ManGenerator::startDoxyAnchor(const char *,const char *manName,
// the name of the link file is derived from the name of the anchor: // the name of the link file is derived from the name of the anchor:
// - truncate after an (optional) :: // - truncate after an (optional) ::
QCString baseName = name; QCString baseName = name;
int i=baseName.findRev(':'); int i=baseName.findRev("::");
if (i!=-1) baseName=baseName.right(baseName.length()-i-1); if (i!=-1) baseName=baseName.right(baseName.length()-i-1);
// - remove dangerous characters and append suffix, then add dir prefix // - remove dangerous characters and append suffix, then add dir prefix
......
...@@ -2700,7 +2700,7 @@ void MemberDef::addListReference(Definition *) ...@@ -2700,7 +2700,7 @@ void MemberDef::addListReference(Definition *)
if (xrefItems!=0) if (xrefItems!=0)
{ {
addRefItem(xrefItems.pointer(), addRefItem(xrefItems.pointer(),
qualifiedName(), qualifiedName()+argsString(), // argsString is needed for overloaded functions (see bug 609624)
memLabel, memLabel,
getOutputFileBase()+"#"+anchor(),memName,memArgs); getOutputFileBase()+"#"+anchor(),memName,memArgs);
} }
......
...@@ -511,10 +511,12 @@ void MemberList::addListReferences(Definition *def) ...@@ -511,10 +511,12 @@ void MemberList::addListReferences(Definition *def)
LockingPtr<MemberList> enumFields = md->enumFieldList(); LockingPtr<MemberList> enumFields = md->enumFieldList();
if (md->memberType()==MemberDef::Enumeration && enumFields!=0) if (md->memberType()==MemberDef::Enumeration && enumFields!=0)
{ {
//printf(" Adding enum values!\n");
MemberListIterator vmli(*enumFields); MemberListIterator vmli(*enumFields);
MemberDef *vmd; MemberDef *vmd;
for ( ; (vmd=vmli.current()) ; ++vmli) for ( ; (vmd=vmli.current()) ; ++vmli)
{ {
//printf(" adding %s\n",vmd->name().data());
vmd->addListReference(def); vmd->addListReference(def);
} }
} }
......
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
struct FileState struct FileState
{ {
FileState(int size) : fileBuf(size), oldFileBuf(0), oldFileBufPos(0) {} FileState(int size) : fileBuf(size), oldFileBuf(0), oldFileBufPos(0),fileDef(0) {}
int lineNr; int lineNr;
//FILE *filePtr; //FILE *filePtr;
BufStr fileBuf; BufStr fileBuf;
...@@ -63,6 +63,7 @@ struct FileState ...@@ -63,6 +63,7 @@ struct FileState
//bool isPlainFile; //bool isPlainFile;
YY_BUFFER_STATE bufState; YY_BUFFER_STATE bufState;
QCString fileName; QCString fileName;
FileDef *fileDef;
}; };
/* ----------------------------------------------------------------- /* -----------------------------------------------------------------
...@@ -121,6 +122,7 @@ DefineDict* getFileDefineDict() ...@@ -121,6 +122,7 @@ DefineDict* getFileDefineDict()
return g_fileDefineDict; return g_fileDefineDict;
} }
#if 0
static void setFileName(const char *name) static void setFileName(const char *name)
{ {
bool ambig; bool ambig;
...@@ -130,6 +132,16 @@ static void setFileName(const char *name) ...@@ -130,6 +132,16 @@ static void setFileName(const char *name)
if (g_yyFileDef && g_yyFileDef->isReference()) g_yyFileDef=0; if (g_yyFileDef && g_yyFileDef->isReference()) g_yyFileDef=0;
g_insideCS = g_yyFileName.right(3)==".cs"; g_insideCS = g_yyFileName.right(3)==".cs";
} }
#endif
static void setFileName(FileState *fs)
{
g_yyFileName=fs->fileName;
g_yyFileDef=fs->fileDef;
//printf("^^ setFileName: %s->%p\n",g_yyFileName.data(),g_yyFileDef);
if (g_yyFileDef && g_yyFileDef->isReference()) g_yyFileDef=0;
g_insideCS = g_yyFileName.right(3)==".cs";
}
static void incrLevel() static void incrLevel()
{ {
...@@ -173,18 +185,42 @@ static void setCaseDone(bool value) ...@@ -173,18 +185,42 @@ static void setCaseDone(bool value)
g_levelGuard[g_level-1]=value; g_levelGuard[g_level-1]=value;
} }
static bool macroIsAccessible(Define *def)
{
//printf("macroIsAccessible(%s) input=%s def=%s\n",
// def->name.data(),g_inputFileDef?g_inputFileDef->name().data():"<none>",
// def->fileDef ? def->fileDef->name().data() : "<none>");
if (def && def->isPredefined) // predefined macro -> globally accessible
{
//printf("%s: predefined macro %s\n",g_inputFileDef->name().data(),def->name.data());
return TRUE;
}
if (g_inputFileDef && def && def->fileDef) // check if g_inputFileDef actually includes def->fileDef
{
QDict<FileDef> includedFiles(257);
bool b = g_inputFileDef->includes(def->fileDef,&includedFiles);
//printf("%s: Checking for accessibility of define '%s' (defined in %s): result=%d\n",
// g_inputFileDef->name().data(),def->name.data(),def->fileDef->name().data(),b);
return b;
}
return FALSE;
}
static Define *isDefined(const char *name) static Define *isDefined(const char *name)
{ {
Define *def=0;
if (name) if (name)
{ {
Define *def; def=g_fileDefineDict->find(name);
//if ((def=fileDefineCache->findDefine(g_yyFileName,name)) && !def->undef) //if ((def=fileDefineCache->findDefine(g_yyFileName,name)) && !def->undef)
// return def; // return def;
if ((def=g_fileDefineDict->find(name)) && !def->undef) return def; if (def && def->undef) def=0;
if (def && !macroIsAccessible(def)) def=0;
} }
return 0; return def;
} }
static QDict<void> g_allIncludes(10009); static QDict<void> g_allIncludes(10009);
static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyIncluded) static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyIncluded)
...@@ -245,6 +281,8 @@ static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyInclude ...@@ -245,6 +281,8 @@ static FileState *checkAndOpenFile(const QCString &fileName,bool &alreadyInclude
{ {
fs->oldFileBuf = g_inputBuf; fs->oldFileBuf = g_inputBuf;
fs->oldFileBufPos = g_inputBufPos; fs->oldFileBufPos = g_inputBufPos;
fs->fileDef = g_yyFileDef;
fs->fileName = g_yyFileName;
} }
} }
return fs; return fs;
...@@ -262,7 +300,7 @@ static FileState *findFile(const char *fileName,bool localInclude,bool &alreadyI ...@@ -262,7 +300,7 @@ static FileState *findFile(const char *fileName,bool localInclude,bool &alreadyI
FileState *fs = checkAndOpenFile(absName,alreadyIncluded); FileState *fs = checkAndOpenFile(absName,alreadyIncluded);
if (fs) if (fs)
{ {
setFileName(absName); setFileName(fs);
g_yyLineNr=1; g_yyLineNr=1;
return fs; return fs;
} }
...@@ -283,7 +321,7 @@ static FileState *findFile(const char *fileName,bool localInclude,bool &alreadyI ...@@ -283,7 +321,7 @@ static FileState *findFile(const char *fileName,bool localInclude,bool &alreadyI
FileState *fs = checkAndOpenFile(absName,alreadyIncluded); FileState *fs = checkAndOpenFile(absName,alreadyIncluded);
if (fs) if (fs)
{ {
setFileName(absName); setFileName(fs);
g_yyLineNr=1; g_yyLineNr=1;
return fs; return fs;
} }
...@@ -1062,12 +1100,15 @@ QCString expandMacro(const QCString &name) ...@@ -1062,12 +1100,15 @@ QCString expandMacro(const QCString &name)
Define *newDefine() Define *newDefine()
{ {
Define *def=new Define; Define *def=new Define;
def->name = g_defName; def->name = g_defName;
def->definition = g_defText.stripWhiteSpace(); def->definition = g_defText.stripWhiteSpace();
def->nargs = g_defArgs; def->nargs = g_defArgs;
def->fileName = g_yyFileName; def->fileName = g_yyFileName;
def->lineNr = g_yyLineNr; def->fileDef = g_yyFileDef;
def->varArgs = g_defVarArgs; def->lineNr = g_yyLineNr;
def->varArgs = g_defVarArgs;
//printf("newDefine: %s->%s\n",def->name.data(),
// def->fileDef ? def->fileDef->name().data() : "<none>");
//printf("newDefine: `%s'->`%s'\n",def->name.data(),def->definition.data()); //printf("newDefine: `%s'->`%s'\n",def->name.data(),def->definition.data());
if (!def->name.isEmpty() && Doxygen::expandAsDefinedDict[def->name]) if (!def->name.isEmpty() && Doxygen::expandAsDefinedDict[def->name])
{ {
...@@ -1124,7 +1165,10 @@ void addDefine() ...@@ -1124,7 +1165,10 @@ void addDefine()
Doxygen::functionNameSDict->append(g_defName,mn); Doxygen::functionNameSDict->append(g_defName,mn);
} }
mn->append(md); mn->append(md);
if (g_yyFileDef) g_yyFileDef->insertMember(md); if (g_yyFileDef)
{
g_yyFileDef->insertMember(md);
}
//Define *d; //Define *d;
//if ((d=defineDict[g_defName])==0) defineDict.insert(g_defName,newDefine()); //if ((d=defineDict[g_defName])==0) defineDict.insert(g_defName,newDefine());
...@@ -1190,9 +1234,10 @@ static void readIncludeFile(const QCString &inc) ...@@ -1190,9 +1234,10 @@ static void readIncludeFile(const QCString &inc)
g_yyFileDef->addIncludedByDependency(oldFileDef,oldFileDef->docName(),localInclude,g_isImported); g_yyFileDef->addIncludedByDependency(oldFileDef,oldFileDef->docName(),localInclude,g_isImported);
} }
} }
fs->bufState=YY_CURRENT_BUFFER; fs->bufState = YY_CURRENT_BUFFER;
fs->lineNr=oldLineNr; fs->lineNr = oldLineNr;
fs->fileName=oldFileName; fs->fileName = oldFileName;
fs->fileDef = oldFileDef;
// push the state on the stack // push the state on the stack
g_includeStack.push(fs); g_includeStack.push(fs);
// set the scanner to the include file // set the scanner to the include file
...@@ -1398,6 +1443,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -1398,6 +1443,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
(g_includeStack.isEmpty() || g_curlyCount>0) && (g_includeStack.isEmpty() || g_curlyCount>0) &&
g_macroExpansion && g_macroExpansion &&
(def=g_fileDefineDict->find(name)) && (def=g_fileDefineDict->find(name)) &&
macroIsAccessible(def) &&
(!g_expandOnlyPredef || def->isPredefined) (!g_expandOnlyPredef || def->isPredefined)
) )
) )
...@@ -1470,10 +1516,11 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -1470,10 +1516,11 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
if ((g_includeStack.isEmpty() || g_curlyCount>0) && if ((g_includeStack.isEmpty() || g_curlyCount>0) &&
g_macroExpansion && g_macroExpansion &&
(def=g_fileDefineDict->find(yytext)) && (def=g_fileDefineDict->find(yytext)) &&
macroIsAccessible(def) &&
(!g_expandOnlyPredef || def->isPredefined) (!g_expandOnlyPredef || def->isPredefined)
) )
{ {
//printf("Found it!\n"); //printf("Found it! #args=%d\n",def->nargs);
g_roundCount=0; g_roundCount=0;
g_defArgsStr=yytext; g_defArgsStr=yytext;
if (def->nargs==-1) // no function macro if (def->nargs==-1) // no function macro
...@@ -1499,6 +1546,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -1499,6 +1546,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
g_macroExpansion && g_macroExpansion &&
(def=g_fileDefineDict->find(yytext)) && (def=g_fileDefineDict->find(yytext)) &&
def->nargs==-1 && def->nargs==-1 &&
macroIsAccessible(def) &&
(!g_expandOnlyPredef || def->isPredefined) (!g_expandOnlyPredef || def->isPredefined)
) )
{ {
...@@ -2181,7 +2229,8 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2181,7 +2229,8 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
//printf("new define!\n"); //printf("new define!\n");
g_fileDefineDict->insert(g_defName,newDefine()); g_fileDefineDict->insert(g_defName,newDefine());
} }
else if (def)// name already exists else if (def && macroIsAccessible(def))
// name already exists
{ {
//printf("existing define!\n"); //printf("existing define!\n");
//printf("define found\n"); //printf("define found\n");
...@@ -2271,11 +2320,11 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) ...@@ -2271,11 +2320,11 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'"))
YY_BUFFER_STATE oldBuf = YY_CURRENT_BUFFER; YY_BUFFER_STATE oldBuf = YY_CURRENT_BUFFER;
yy_switch_to_buffer( fs->bufState ); yy_switch_to_buffer( fs->bufState );
yy_delete_buffer( oldBuf ); yy_delete_buffer( oldBuf );
g_yyLineNr=fs->lineNr; g_yyLineNr = fs->lineNr;
//preYYin = fs->oldYYin; //preYYin = fs->oldYYin;
g_inputBuf = fs->oldFileBuf; g_inputBuf = fs->oldFileBuf;
g_inputBufPos = fs->oldFileBufPos; g_inputBufPos = fs->oldFileBufPos;
setFileName(fs->fileName.copy()); setFileName(fs);
//fprintf(stderr,"######## FileName %s\n",g_yyFileName.data()); //fprintf(stderr,"######## FileName %s\n",g_yyFileName.data());
// Deal with file changes due to // Deal with file changes due to
...@@ -2454,6 +2503,7 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output) ...@@ -2454,6 +2503,7 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output)
i_obrace<i_cbrace i_obrace<i_cbrace
) // predefined function macro definition ) // predefined function macro definition
{ {
//printf("predefined function macro '%s'\n",defStr);
QRegExp reId("[a-z_A-Z][a-z_A-Z0-9]*"); // regexp matching an id QRegExp reId("[a-z_A-Z][a-z_A-Z0-9]*"); // regexp matching an id
QDict<int> argDict(17); QDict<int> argDict(17);
argDict.setAutoDelete(TRUE); argDict.setAutoDelete(TRUE);
...@@ -2493,11 +2543,13 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output) ...@@ -2493,11 +2543,13 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output)
if (!dname.isEmpty()) if (!dname.isEmpty())
{ {
Define *def = new Define; Define *def = new Define;
def->name = dname; def->name = dname;
def->definition = definition; def->definition = definition;
def->nargs = count; def->nargs = count;
def->isPredefined = TRUE; def->isPredefined = TRUE;
def->nonRecursive = nonRecursive; def->nonRecursive = nonRecursive;
def->fileDef = g_yyFileDef;
def->fileName = fileName;
g_fileDefineDict->insert(def->name,def); g_fileDefineDict->insert(def->name,def);
} }
...@@ -2509,6 +2561,7 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output) ...@@ -2509,6 +2561,7 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output)
!ds.isEmpty() && (int)ds.length()>i_equals !ds.isEmpty() && (int)ds.length()>i_equals
) // predefined non-function macro definition ) // predefined non-function macro definition
{ {
//printf("predefined normal macro '%s'\n",defStr);
Define *def = new Define; Define *def = new Define;
if (i_equals==-1) // simple define without argument if (i_equals==-1) // simple define without argument
{ {
...@@ -2526,6 +2579,8 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output) ...@@ -2526,6 +2579,8 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output)
def->nargs = -1; def->nargs = -1;
def->isPredefined = TRUE; def->isPredefined = TRUE;
def->nonRecursive = nonRecursive; def->nonRecursive = nonRecursive;
def->fileDef = g_yyFileDef;
def->fileName = fileName;
g_fileDefineDict->insert(def->name,def); g_fileDefineDict->insert(def->name,def);
} }
else else
...@@ -2566,8 +2621,14 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output) ...@@ -2566,8 +2621,14 @@ void preprocessFile(const char *fileName,BufStr &input,BufStr &output)
g_yyLineNr = 1; g_yyLineNr = 1;
g_level = 0; g_level = 0;
g_ifcount = 0; g_ifcount = 0;
setFileName(fileName); QFileInfo fi(fileName);
bool ambig;
g_yyFileName = convertToQCString(fi.absFilePath());
g_yyFileDef = findFileDef(Doxygen::inputNameDict,g_yyFileName,ambig);
if (g_yyFileDef && g_yyFileDef->isReference()) g_yyFileDef=0;
g_insideCS = g_yyFileName.right(3)==".cs";
g_inputFileDef = g_yyFileDef; g_inputFileDef = g_yyFileDef;
BEGIN( Start ); BEGIN( Start );
g_expectGuard = TRUE; g_expectGuard = TRUE;
......
...@@ -4031,7 +4031,7 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) ...@@ -4031,7 +4031,7 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
// was: current->args.simplifyWhiteSpace(); // was: current->args.simplifyWhiteSpace();
current->fileName = yyFileName; current->fileName = yyFileName;
current->startLine = yyLineNr; current->startLine = yyLineNr;
static QRegExp re("([^)]*\\[*&][^)]*)"); // (...*...) static QRegExp re("([^)]*[*&][^)]*)"); // (...*...)
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('<');
...@@ -4041,6 +4041,10 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) ...@@ -4041,6 +4041,10 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
(current->type.find(re,0)!=-1 || current->type.left(8)=="typedef ")) (current->type.find(re,0)!=-1 || current->type.left(8)=="typedef "))
{ {
//printf("Scanner.l: found in class variable: `%s' `%s' `%s'\n", current->type.data(),current->name.data(),current->args.data()); //printf("Scanner.l: found in class variable: `%s' `%s' `%s'\n", current->type.data(),current->name.data(),current->args.data());
if (isTypedef && current->type.left(8)!="typedef ")
{
current->type.prepend("typedef ");
}
current->section = Entry::VARIABLE_SEC ; current->section = Entry::VARIABLE_SEC ;
} }
else else
...@@ -4056,6 +4060,10 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) ...@@ -4056,6 +4060,10 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
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 "))
{ {
if (isTypedef && current->type.left(8)!="typedef ")
{
current->type.prepend("typedef ");
}
//printf("Scanner.l: found function variable!\n"); //printf("Scanner.l: found function variable!\n");
current->section = Entry::VARIABLE_SEC; current->section = Entry::VARIABLE_SEC;
} }
......
...@@ -5829,7 +5829,7 @@ void addRefItem(const QList<ListItemInfo> *sli, ...@@ -5829,7 +5829,7 @@ void addRefItem(const QList<ListItemInfo> *sli,
const char *key, const char *key,
const char *prefix, const char *name,const char *title,const char *args) const char *prefix, const char *name,const char *title,const char *args)
{ {
//printf("addRefItem(sli=%p,prefix=%s,name=%s,title=%s,args=%s)\n",sli,prefix,name,title,args); //printf("addRefItem(sli=%p,key=%s,prefix=%s,name=%s,title=%s,args=%s)\n",sli,key,prefix,name,title,args);
if (sli) if (sli)
{ {
QListIterator<ListItemInfo> slii(*sli); QListIterator<ListItemInfo> slii(*sli);
......
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