Commit 81adebde authored by dimitri's avatar dimitri

Release-1.3.9.1-20041228

parent 0e5fe151
DOXYGEN Version 1.3.9.1-20041224 DOXYGEN Version 1.3.9.1-20041228
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 (24 December 2004) Dimitri van Heesch (28 December 2004)
DOXYGEN Version 1.3.9.1_20041224 DOXYGEN Version 1.3.9.1_20041228
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) (24 December 2004) Dimitri van Heesch (dimitri@stack.nl) (28 December 2004)
1.3.9.1-20041224 1.3.9.1-20041228
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
\section config_format Format \section config_format Format
A configuration file is a free-form ASCII text file with a structure A configuration file is a free-form ASCII text file with a structure
that is similar to that of a Makefile, default name \c Doxyfile. It is that is similar to that of a Makefile, with the default name \c Doxyfile. It is
parsed by \c doxygen. The file may contain tabs and newlines for parsed by \c doxygen. The file may contain tabs and newlines for
formatting purposes. The statements in the file are case-sensitive. formatting purposes. The statements in the file are case-sensitive.
Comments may be placed anywhere within the file (except within quotes). Comments may be placed anywhere within the file (except within quotes).
...@@ -35,7 +35,7 @@ new values to the list. Values are sequences of non-blanks. If the value should ...@@ -35,7 +35,7 @@ new values to the list. Values are sequences of non-blanks. If the value should
contain one or more blanks it must be surrounded by quotes ("..."). contain one or more blanks it must be surrounded by quotes ("...").
Multiple lines can be concatenated by inserting a backslash (\\) Multiple lines can be concatenated by inserting a backslash (\\)
as the last character of a line. Environment variables can be expanded as the last character of a line. Environment variables can be expanded
using the pattern \c \$(ENV_VARIABLE_NAME). using the pattern <code>\$(ENV_VARIABLE_NAME)</code>.
You can also include part of a configuration file from another configuration You can also include part of a configuration file from another configuration
file using a <code>\@INCLUDE</code> tag as follows: file using a <code>\@INCLUDE</code> tag as follows:
...@@ -77,7 +77,9 @@ followed by the descriptions of the tags grouped by category. ...@@ -77,7 +77,9 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_disable_index DISABLE_INDEX \refitem cfg_disable_index DISABLE_INDEX
\refitem cfg_distribute_group_doc DISTRIBUTE_GROUP_DOC \refitem cfg_distribute_group_doc DISTRIBUTE_GROUP_DOC
\refitem cfg_dot_image_format DOT_IMAGE_FORMAT \refitem cfg_dot_image_format DOT_IMAGE_FORMAT
\refitem cfg_dot_multi_targets DOT_MULTI_TARGETS
\refitem cfg_dot_path DOT_PATH \refitem cfg_dot_path DOT_PATH
\refitem cfg_dot_transparent DOT_TRANSPARENT
\refitem cfg_dotfile_dirs DOTFILE_DIRS \refitem cfg_dotfile_dirs DOTFILE_DIRS
\refitem cfg_enable_preprocessing ENABLE_PREPROCESSING \refitem cfg_enable_preprocessing ENABLE_PREPROCESSING
\refitem cfg_enum_values_per_line ENUM_VALUES_PER_LINE \refitem cfg_enum_values_per_line ENUM_VALUES_PER_LINE
...@@ -98,6 +100,7 @@ followed by the descriptions of the tags grouped by category. ...@@ -98,6 +100,7 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_extract_private EXTRACT_PRIVATE \refitem cfg_extract_private EXTRACT_PRIVATE
\refitem cfg_extract_static EXTRACT_STATIC \refitem cfg_extract_static EXTRACT_STATIC
\refitem cfg_file_patterns FILE_PATTERNS \refitem cfg_file_patterns FILE_PATTERNS
\refitem cfg_file_version_filter FILE_VERSION_FILTER
\refitem cfg_filter_patterns FILTER_PATTERNS \refitem cfg_filter_patterns FILTER_PATTERNS
\refitem cfg_filter_source_files FILTER_SOURCE_FILES \refitem cfg_filter_source_files FILTER_SOURCE_FILES
\refitem cfg_full_path_names FULL_PATH_NAMES \refitem cfg_full_path_names FULL_PATH_NAMES
...@@ -726,6 +729,39 @@ documentation. ...@@ -726,6 +729,39 @@ documentation.
*.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm
</code> </code>
\anchor cfg_file_version_filter
<dt>\c FILE_VERSION_FILTER <dd>
\addindex FILE_VERSION_FILTER
The \c FILE_VERSION_FILTER tag can be used to specify a program or script that
doxygen should invoke to get the current version for each file (typically from the
version control system). Doxygen will invoke the program by executing (via
popen()) the command <code>command input-file</code>, where \c command is
the value of the \c FILE_VERSION_FILTER tag, and \c input-file is the name
of an input file provided by doxygen.
Whatever the progam writes to standard output is used as the file version.
Example of using a shell script as a filter for Unix:
\verbatim
FILE_VERSION_FILTER = "/bin/sh versionfilter.sh"
\endverbatim
Example shell script for CVS:
\verbatim
#!/bin/sh
cvs status $1 | sed -n 's/^[ \]*Working revision:[ \t]*\([0-9][0-9\.]*\).*/\1/p'
\endverbatim
Example shell script for Subversion:
\verbatim
#!/bin/sh
svn stat -v $1 | sed -n 's/^[ A-Z?\*|!]\{1,15\}/r/;s/ \{1,15\}/\/r/;s/ .*//p'
\endverbatim
Example filter for ClearCase:
\verbatim
FILE_VERSION_INFO = "cleartool desc -fmt \%Vn"
\endverbatim
\anchor cfg_recursive \anchor cfg_recursive
<dt>\c RECURSIVE <dd> <dt>\c RECURSIVE <dd>
\addindex RECURSIVE \addindex RECURSIVE
...@@ -1655,6 +1691,22 @@ not depth-constraint. ...@@ -1655,6 +1691,22 @@ not depth-constraint.
the specified constraint. Beware that most browsers cannot cope with very the specified constraint. Beware that most browsers cannot cope with very
large images. large images.
\anchor cfg_dot_transparent
<dt>\c DOT_TRANSPARENT <dd>
\addindex DOT_TRANSPARENT
Set the \c DOT_TRANSPARENT tag to \c YES to generate images with a transparent
background. This is disabled by default, which results in a white background.
Warning: Depending on the platform used, enabling this option may lead to badly
anti-aliased labels on the edges of a graph (i.e. they become hard to read).
\anchor cfg_dot_multi_targets
<dt>\c DOT_MULTI_TARGETS <dd>
\addindex DOT_MULTI_TARGET
Set the \c DOT_MULTI_TARGETS tag to \c YES allow dot to generate multiple output
files in one run (i.e. multiple -o and -T options on the command line). This
makes dot run faster, but since only newer versions of dot (>1.8.10)
support this, this feature is disabled by default.
\anchor cfg_generate_legend \anchor cfg_generate_legend
<dt>\c GENERATE_LEGEND <dd> <dt>\c GENERATE_LEGEND <dd>
\addindex GENERATE_LEGEND \addindex GENERATE_LEGEND
......
...@@ -104,9 +104,9 @@ Compilation is now done by performing the following steps: ...@@ -104,9 +104,9 @@ Compilation is now done by performing the following steps:
See the <code>PLATFORMS</code> file for a list of possible platform See the <code>PLATFORMS</code> file for a list of possible platform
options. options.
If you have Qt-2.1.x installed and want to build the GUI front-end, you If you have Qt-3.2.x or higher installed and want to build the GUI
should run the configure script with the <code>--with-doxywizard</code> front-end, you should run the configure script with
option: the <code>--with-doxywizard</code> option:
\verbatim \verbatim
configure --with-doxywizard configure --with-doxywizard
...@@ -297,32 +297,10 @@ ce_parse.cpp: ...@@ -297,32 +297,10 @@ ce_parse.cpp:
<b>Sun compiler problems</b> <b>Sun compiler problems</b>
I tried compiling doxygen only with Sun's C++ WorkShop Compiler It appears that doxygen doesn't work properly if it is compiled
version 5.0 (I used <code>./configure --platform solaris-cc</code>) with Sun's C++ WorkShop Compiler. I cannot verify this myself as I do
not have access to a Solaris machine with this compiler. With GNU compiler
Qt-2.x.y is required for this compiler (Qt-1.44 has problems with the bool it does work.
type).
Compiling the \c doxygen binary went ok, but while linking <code>doxytag</code> I got a
lot of link errors, like these:
\verbatim
QList<PageInfo>::__vtbl /home/dimitri/doxygen/
objects/SunWS_cache/CC_obj_6/6c3eO4IogMT2vrlGCQUQ.o
[Hint: try checking whether the first non-inlined, non-pure
virtual function of class QList<PageInfo> is defined]
\endverbatim
These are generated because the compiler is confused about the object sharing
between \c doxygen and \c doxytag. To compile \c doxytag
anyway do:
\verbatim
rm -rf objects
mkdir objects
cd src
gmake -f Makefile.doxytag
\endverbatim
when configuring with <code>--static</code> I got: when configuring with <code>--static</code> I got:
...@@ -467,7 +445,7 @@ Here is what is required: ...@@ -467,7 +445,7 @@ Here is what is required:
still a requirement however. A commercial license to build still a requirement however. A commercial license to build
doxywizard with the latest Qt library was kindly donated to me doxywizard with the latest Qt library was kindly donated to me
by the nice people at <a href="http://www.trolltech.com">TrollTech</a>. by the nice people at <a href="http://www.trolltech.com">TrollTech</a>.
See doxygen download page for a link. See doxygen download page for a link.
<li>If you used WinZip to extract the tar archive it will (apparently) not <li>If you used WinZip to extract the tar archive it will (apparently) not
create empty folders, so you have to add the folders create empty folders, so you have to add the folders
......
...@@ -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.3.9.1-20041129), 30 languages Currently (version 1.3.9.1-20041221), 30 languages
are supported (sorted alphabetically): are supported (sorted alphabetically):
Afrikaans, Brazilian Portuguese, Catalan, Chinese, Chinese Afrikaans, Brazilian Portuguese, Catalan, Chinese, Chinese
Traditional, Croatian, Czech, Danish, Dutch, English, Finnish, French, Traditional, Croatian, Czech, Danish, Dutch, English, Finnish, French,
...@@ -160,9 +160,9 @@ when the translator was updated. ...@@ -160,9 +160,9 @@ when the translator was updated.
</tr> </tr>
<tr bgcolor="#ffffff"> <tr bgcolor="#ffffff">
<td>Korean</td> <td>Korean</td>
<td>Richard Kim</td> <td>SooYoung Jung<br>Richard Kim</td>
<td>ryk at dspwiz dot com</td> <td>jung5000 at gmail dot com<br>ryk at dspwiz dot com</td>
<td>1.3.8</td> <td>up-to-date</td>
</tr> </tr>
<tr bgcolor="#ffffff"> <tr bgcolor="#ffffff">
<td>KoreanEn</td> <td>KoreanEn</td>
...@@ -299,7 +299,8 @@ when the translator was updated. ...@@ -299,7 +299,8 @@ when the translator was updated.
\hline \hline
JapaneseEn & see the Japanese language & {\tt\tiny ~} & English based \\ JapaneseEn & see the Japanese language & {\tt\tiny ~} & English based \\
\hline \hline
Korean & Richard Kim & {\tt\tiny ryk@dspwiz.com} & 1.3.8 \\ Korean & SooYoung Jung & {\tt\tiny jung5000@gmail.com} & up-to-date \\
~ & Richard Kim & {\tt\tiny ryk@dspwiz.com} & ~ \\
\hline \hline
KoreanEn & see the Korean language & {\tt\tiny ~} & English based \\ KoreanEn & see the Korean language & {\tt\tiny ~} & English based \\
\hline \hline
......
(1.3.9.1-20041129) (1.3.9.1-20041221)
Doxygen supports the following 30 languages (sorted alphabetically): Doxygen supports the following 30 languages (sorted alphabetically):
...@@ -8,7 +8,7 @@ German, Greek, Hungarian, Italian, Japanese (+En), Korean (+En), ...@@ -8,7 +8,7 @@ German, Greek, Hungarian, Italian, Japanese (+En), Korean (+En),
Lithuanian, Norwegian, Polish, Portuguese, Romanian, Russian, Serbian, Lithuanian, Norwegian, Polish, Portuguese, Romanian, Russian, Serbian,
Slovak, Slovene, Spanish, Swedish, and Ukrainian. Slovak, Slovene, Spanish, Swedish, and Ukrainian.
Of them, 14 translators are up-to-date, 16 translators are based on Of them, 15 translators are up-to-date, 15 translators are based on
some adapter class, and 2 are English based. some adapter class, and 2 are English based.
---------------------------------------------------------------------- ----------------------------------------------------------------------
...@@ -27,6 +27,7 @@ still may be some details listed even for them: ...@@ -27,6 +27,7 @@ still may be some details listed even for them:
TranslatorGerman TranslatorGerman
TranslatorHungarian TranslatorHungarian
TranslatorItalian TranslatorItalian
TranslatorKorean -- Change the base class to Translator.
TranslatorPolish TranslatorPolish
TranslatorRussian TranslatorRussian
TranslatorSerbian TranslatorSerbian
...@@ -44,7 +45,6 @@ must be implemented to become up-to-date: ...@@ -44,7 +45,6 @@ must be implemented to become up-to-date:
TranslatorAfrikaans 1.3.9 6 methods to implement TranslatorAfrikaans 1.3.9 6 methods to implement
TranslatorSpanish 1.3.8 7 methods to implement TranslatorSpanish 1.3.8 7 methods to implement
TranslatorLithuanian 1.3.8 7 methods to implement TranslatorLithuanian 1.3.8 7 methods to implement
TranslatorKorean 1.3.8 7 methods to implement
TranslatorChinesetraditional 1.3.8 7 methods to implement TranslatorChinesetraditional 1.3.8 7 methods to implement
TranslatorPortuguese 1.3.3 11 methods to implement TranslatorPortuguese 1.3.3 11 methods to implement
TranslatorSlovak 1.2.18 20 methods to implement TranslatorSlovak 1.2.18 20 methods to implement
...@@ -340,20 +340,10 @@ TranslatorJapaneseEn (TranslatorEnglish) 196 methods to implement ...@@ -340,20 +340,10 @@ TranslatorJapaneseEn (TranslatorEnglish) 196 methods to implement
virtual QCString idLanguageCharset() virtual QCString idLanguageCharset()
TranslatorKorean (TranslatorAdapter_1_3_8) 7 methods to implement TranslatorKorean (TranslatorAdapter_1_3_9)
---------------- ----------------
Implements 194 of the required methods. Implements 201 of the required methods.
Missing methods (should be implemented):
virtual QCString trDirIndex()
virtual QCString trDirDocumentation()
virtual QCString trDirectories()
virtual QCString trDirDescription()
virtual QCString trSourceFile(QCString & filename)
virtual QCString trDirReference(const char * dirName)
virtual QCString trDir(bool first_capital, bool singular)
TranslatorKoreanEn (TranslatorEnglish) 196 methods to implement TranslatorKoreanEn (TranslatorEnglish) 196 methods to implement
......
Summary: A documentation system for C/C++. Summary: A documentation system for C/C++.
Name: doxygen Name: doxygen
Version: 1.3.9.1_20041224 Version: 1.3.9.1_20041228
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
......
...@@ -936,6 +936,84 @@ void ClassDef::writeDetailedDescription(OutputList &ol, const QCString &pageType ...@@ -936,6 +936,84 @@ void ClassDef::writeDetailedDescription(OutputList &ol, const QCString &pageType
} }
} }
void ClassDef::showUsedFiles(OutputList &ol)
{
if (Config_getBool("SHOW_USED_FILES"))
{
ol.writeRuler();
ol.parseText(theTranslator->trGeneratedFromFiles(
m_isObjC && m_compType==Interface ? Class : m_compType,
m_files.count()==1));
bool first=TRUE;
const char *file = m_files.first();
while (file)
{
bool ambig;
FileDef *fd=findFileDef(Doxygen::inputNameDict,file,ambig);
if (fd)
{
if (first)
{
first=FALSE;
ol.startItemList();
}
ol.writeListItem();
QCString path=fd->getPath().copy();
if (Config_getBool("FULL_PATH_NAMES"))
{
ol.docify(stripFromPath(path));
}
QCString fname = fd->name();
if (!fd->getVersion().isEmpty()) // append version if available
{
fname += " (" + fd->getVersion() + ")";
}
// for HTML
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Html);
if (fd->generateSourceFile())
{
ol.writeObjectLink(0,fd->getSourceFileBase(),0,fname);
}
else if (fd->isLinkable())
{
ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(),0,
fname);
}
else
{
ol.docify(fname);
}
ol.popGeneratorState();
// for other output formats
ol.pushGeneratorState();
ol.disable(OutputGenerator::Html);
if (fd->isLinkable())
{
ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(),0,
fname);
}
else
{
ol.docify(fname);
}
ol.popGeneratorState();
}
file=m_files.next();
}
if (!first) ol.endItemList();
}
}
// write all documentation for this class // write all documentation for this class
void ClassDef::writeDocumentation(OutputList &ol) void ClassDef::writeDocumentation(OutputList &ol)
{ {
...@@ -1389,73 +1467,7 @@ void ClassDef::writeDocumentation(OutputList &ol) ...@@ -1389,73 +1467,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol.pushGeneratorState(); ol.pushGeneratorState();
ol.disable(OutputGenerator::Man); ol.disable(OutputGenerator::Man);
if (Config_getBool("SHOW_USED_FILES")) showUsedFiles(ol);
{
ol.writeRuler();
ol.parseText(theTranslator->trGeneratedFromFiles(
m_isObjC && m_compType==Interface ? Class : m_compType,
m_files.count()==1));
bool first=TRUE;
const char *file = m_files.first();
while (file)
{
bool ambig;
FileDef *fd=findFileDef(Doxygen::inputNameDict,file,ambig);
if (fd)
{
if (first)
{
first=FALSE;
ol.startItemList();
}
ol.writeListItem();
QCString path=fd->getPath().copy();
if (Config_getBool("FULL_PATH_NAMES"))
{
ol.docify(stripFromPath(path));
}
// for HTML
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Html);
if (fd->generateSourceFile())
{
ol.writeObjectLink(0,fd->getSourceFileBase(),0,fd->name());
}
else if (fd->isLinkable())
{
ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(),0,
fd->name());
}
else
{
ol.docify(fd->name());
}
ol.popGeneratorState();
// for other output formats
ol.pushGeneratorState();
ol.disable(OutputGenerator::Html);
if (fd->isLinkable())
{
ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(),0,
fd->name());
}
else
{
ol.docify(fd->name());
}
ol.popGeneratorState();
}
file=m_files.next();
}
if (!first) ol.endItemList();
}
// write Author section (Man only) // write Author section (Man only)
ol.enable(OutputGenerator::Man); ol.enable(OutputGenerator::Man);
......
...@@ -333,6 +333,7 @@ class ClassDef : public Definition ...@@ -333,6 +333,7 @@ class ClassDef : public Definition
void addUsedInterfaceClasses(MemberDef *md,const char *typeStr); void addUsedInterfaceClasses(MemberDef *md,const char *typeStr);
bool hasExamples(); bool hasExamples();
bool hasNonReferenceSuperClass(); bool hasNonReferenceSuperClass();
void showUsedFiles(OutputList &ol);
/*! \} Interal API */ /*! \} Interal API */
......
...@@ -99,7 +99,7 @@ CommandMap cmdMap[] = ...@@ -99,7 +99,7 @@ CommandMap cmdMap[] =
{ "$", CMD_DOLLAR }, { "$", CMD_DOLLAR },
{ "#", CMD_HASH }, { "#", CMD_HASH },
{ "%", CMD_PERCENT }, { "%", CMD_PERCENT },
{ "~", CMD_LANGSWITCH }, //{ "~", CMD_LANGSWITCH },
{ "_internalref", CMD_INTERNALREF }, { "_internalref", CMD_INTERNALREF },
{ "dot", CMD_DOT }, { "dot", CMD_DOT },
{ "enddot", CMD_ENDDOT }, { "enddot", CMD_ENDDOT },
......
...@@ -66,7 +66,7 @@ enum CommandType ...@@ -66,7 +66,7 @@ enum CommandType
CMD_INTERNAL = 32, CMD_INTERNAL = 32,
CMD_INTERNALREF = 33, CMD_INTERNALREF = 33,
CMD_INVARIANT = 34 | SIMPLESECT_BIT , CMD_INVARIANT = 34 | SIMPLESECT_BIT ,
CMD_LANGSWITCH = 35, //CMD_LANGSWITCH = 35,
CMD_LATEXONLY = 36, CMD_LATEXONLY = 36,
CMD_LESS = 37, CMD_LESS = 37,
CMD_LI = 38, CMD_LI = 38,
......
...@@ -245,6 +245,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'")) ...@@ -245,6 +245,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
%x Verbatim %x Verbatim
%x ReadLine %x ReadLine
%x CondLine %x CondLine
%x SkipLang
%% %%
...@@ -290,18 +291,18 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'")) ...@@ -290,18 +291,18 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
BEGIN(CComment); BEGIN(CComment);
} }
<Scan>"\\verbatim" { /* start of a verbatim block */ <Scan>[\\@]"verbatim" { /* start of a verbatim block */
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
BEGIN(Verbatim); BEGIN(Verbatim);
} }
<Scan>. { /* any other character */ <Scan>. { /* any other character */
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
} }
<Verbatim>"\\endverbatim" { /* end of verbatim block */ <Verbatim>[\\@]"endverbatim" { /* end of verbatim block */
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
BEGIN(Scan); BEGIN(Scan);
} }
<Verbatim>[^\\\n]* { /* any character not a backslash or new line */ <Verbatim>[^@\\\n]* { /* any character not a backslash or new line */
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
} }
<Verbatim>\n { /* new line in verbatim block */ <Verbatim>\n { /* new line in verbatim block */
...@@ -310,6 +311,25 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'")) ...@@ -310,6 +311,25 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
<Verbatim>. { /* any other character */ <Verbatim>. { /* any other character */
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
} }
<SkipLang>[\\@]"~"[a-zA-Z]* { /* end of verbatim block */
QCString langId = &yytext[2];
if (langId.isEmpty() ||
stricmp(Config_getEnum("OUTPUT_LANGUAGE"),langId)==0)
{ // enable language specific section
BEGIN(CComment);
}
}
<SkipLang>[^*@\\\n]* { /* any character not a *, @, backslash or new line */
}
<SkipLang>\n { /* new line in verbatim block */
copyToOutput(yytext,yyleng);
}
<SkipLang>"*/" { /* end of comment block */
copyToOutput(yytext,yyleng);
BEGIN(Scan);
}
<SkipLang>. { /* any other character */
}
<SkipString>\\. { /* escaped character in string */ <SkipString>\\. { /* escaped character in string */
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
} }
...@@ -323,7 +343,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'")) ...@@ -323,7 +343,7 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
<SkipString>\n { /* new line inside string (illegal for some compilers) */ <SkipString>\n { /* new line inside string (illegal for some compilers) */
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
} }
<CComment>[^\\@*\n]* { /* anything that is not a '*' */ <CComment>[^\\@*\n]* { /* anything that is not a '*' or command */
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
} }
<CComment>"*"+[^*/\\@\n]* { /* stars without slashes */ <CComment>"*"+[^*/\\@\n]* { /* stars without slashes */
...@@ -388,9 +408,17 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'")) ...@@ -388,9 +408,17 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
BEGIN(g_readLineCtx); BEGIN(g_readLineCtx);
} }
<CComment,ReadLine>("\\\\"|"@@")[a-z_A-Z][a-z_A-Z0-9]*[ \t]* { // escaped command <CComment,ReadLine>("\\\\"|"@@")[~a-z_A-Z][a-z_A-Z0-9]*[ \t]* { // escaped command
copyToOutput(yytext,yyleng); copyToOutput(yytext,yyleng);
} }
<CComment>[@\\]"~"[a-zA-Z]* { // language switch
QCString langId = &yytext[2];
if (!langId.isEmpty() &&
stricmp(Config_getEnum("OUTPUT_LANGUAGE"),langId)!=0)
{
BEGIN(SkipLang);
}
}
<CComment,ReadLine>[\\@]"cond"[ \t]+ { // conditional section <CComment,ReadLine>[\\@]"cond"[ \t]+ { // conditional section
g_condCtx = YY_START; g_condCtx = YY_START;
BEGIN(CondLine); BEGIN(CondLine);
......
...@@ -1139,113 +1139,6 @@ void Config::check() ...@@ -1139,113 +1139,6 @@ void Config::check()
examplePatternList.append("*"); examplePatternList.append("*");
} }
// add default pattern if needed
//QStrList &imagePatternList = Config_getList("IMAGE_PATTERNS");
//if (imagePatternList.isEmpty())
//{
// imagePatternList.append("*");
//}
// more checks needed if and only if the search engine is enabled.
// if (Config_getBool("SEARCHENGINE"))
// {
// // check cgi name
// QCString &cgiName = Config_getString("CGI_NAME");
// if (cgiName.isEmpty())
// {
// config_err("Error: tag CGI_NAME: no cgi script name after the CGI_NAME tag.\n");
// exit(1);
// }
// // check cgi URL
// QCString &cgiURL = Config_getString("CGI_URL");
// if (cgiURL.isEmpty())
// {
// config_err("Error: tag CGI_URL: no URL to cgi directory specified.\n");
// exit(1);
// }
// else if (cgiURL.left(7)!="http://" &&
// cgiURL.left(8)!="https://" &&
// cgiURL.left(4)!="cgi:"
// )
// {
// config_err("Error: tag CGI_URL: URL to cgi directory is invalid (must "
// "start with http:// or https://).\n");
// exit(1);
// }
// // check documentation URL
// QCString &docURL = Config_getString("DOC_URL");
// if (docURL.isEmpty())
// {
// docURL = Config_getString("OUTPUT_DIRECTORY").copy().prepend("file://").append("html");
// }
// else if (docURL.left(7)!="http://" &&
// docURL.left(8)!="https://" &&
// docURL.left(7)!="file://"
// )
// {
// config_err("Error: tag DOC_URL: URL to documentation is invalid or "
// "not absolute.\n");
// exit(1);
// }
// // check absolute documentation path
// QCString &docAbsPath = Config_getString("DOC_ABSPATH");
// if (docAbsPath.isEmpty())
// {
// docAbsPath = Config_getString("OUTPUT_DIRECTORY")+"/html";
// }
// else if (docAbsPath[0]!='/' && docAbsPath[1]!=':')
// {
// config_err("Error: tag DOC_ABSPATH: path is not absolute!\n");
// exit(1);
// }
// // check path to doxysearch
// QCString &binAbsPath = Config_getString("BIN_ABSPATH");
// if (binAbsPath.isEmpty())
// {
// config_err("Error: tag BIN_ABSPATH: no absolute path to doxysearch "
// "specified.\n");
// exit(1);
// }
// else if (binAbsPath[0]!='/' && binAbsPath[1]!=':')
// {
// config_err("Error: tag BIN_ABSPATH: path is not absolute!\n");
// exit(1);
// }
//
// }
// // check perl path
// bool found=FALSE;
// QCString &perlPath = Config_getString("PERL_PATH");
// if (perlPath.isEmpty())
// {
// QFileInfo fi;
// fi.setFile("/usr/bin/perl");
// if (fi.exists())
// {
// perlPath="/usr/bin/perl";
// found=TRUE;
// }
// else
// {
// fi.setFile("/usr/local/bin/perl");
// if (fi.exists())
// {
// perlPath="/usr/local/bin/perl";
// found=TRUE;
// }
// }
// }
// if (!found)
// {
// QFileInfo fi(perlPath);
// if (!fi.exists())
// {
// config_warn("Warning: tag PERL_PATH: perl interpreter not found at default or"
// "user specified (%s) location\n",
// perlPath.data());
// }
// }
#undef PUTENV #undef PUTENV
#undef SEP #undef SEP
#if defined(_WIN32) && !defined(__GNUC__) && (__BORLANDC__ < 0x0550) #if defined(_WIN32) && !defined(__GNUC__) && (__BORLANDC__ < 0x0550)
...@@ -1352,9 +1245,9 @@ void Config::create() ...@@ -1352,9 +1245,9 @@ void Config::create()
"If the CREATE_SUBDIRS tag is set to YES, then doxygen will create \n" "If the CREATE_SUBDIRS tag is set to YES, then doxygen will create \n"
"4096 sub-directories (in 2 levels) under the output directory of each output \n" "4096 sub-directories (in 2 levels) under the output directory of each output \n"
"format and will distribute the generated files over these directories. \n" "format and will distribute the generated files over these directories. \n"
"Enabling this option can be useful when feeding doxygen a huge amount of source \n" "Enabling this option can be useful when feeding doxygen a huge amount of \n"
"files, where putting all generated files in the same directory would otherwise \n" "source files, where putting all generated files in the same directory would \n"
"cause performance problems for the file system. \n", "otherwise cause performance problems for the file system. \n",
FALSE FALSE
); );
ce = addEnum( ce = addEnum(
...@@ -1490,11 +1383,12 @@ void Config::create() ...@@ -1490,11 +1383,12 @@ void Config::create()
"This tag implements a quasi-intelligent brief description abbreviator \n" "This tag implements a quasi-intelligent brief description abbreviator \n"
"that is used to form the text in various listings. Each string \n" "that is used to form the text in various listings. Each string \n"
"in this list, if found as the leading text of the brief description, will be \n" "in this list, if found as the leading text of the brief description, will be \n"
"stripped from the text and the result after processing the whole list, is used \n" "stripped from the text and the result after processing the whole list, is \n"
"as the annotated text. Otherwise, the brief description is used as-is. If left \n" "used as the annotated text. Otherwise, the brief description is used as-is. \n"
"blank, the following values are used (\"$name\" is automatically replaced with the \n" "If left blank, the following values are used (\"$name\" is automatically \n"
"name of the entity): \"The $name class\" \"The $name widget\" \"The $name file\" \n" "replaced with the name of the entity): \"The $name class\" \"The $name widget\" \n"
"\"is\" \"provides\" \"specifies\" \"contains\" \"represents\" \"a\" \"an\" \"the\"\n" "\"The $name file\" \"is\" \"provides\" \"specifies\" \"contains\" \n"
"\"represents\" \"a\" \"an\" \"the\"\n"
); );
cb = addBool( cb = addBool(
"ALWAYS_DETAILED_SEC", "ALWAYS_DETAILED_SEC",
...@@ -1505,10 +1399,10 @@ void Config::create() ...@@ -1505,10 +1399,10 @@ void Config::create()
); );
cb = addBool( cb = addBool(
"INLINE_INHERITED_MEMB", "INLINE_INHERITED_MEMB",
"If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all inherited \n" "If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all \n"
"members of a class in the documentation of that class as if those members were \n" "inherited members of a class in the documentation of that class as if those \n"
"ordinary class members. Constructors, destructors and assignment operators of \n" "members were ordinary class members. Constructors, destructors and assignment \n"
"the base classes will not be shown. \n", "operators of the base classes will not be shown. \n",
FALSE FALSE
); );
cb = addBool( cb = addBool(
...@@ -1602,8 +1496,8 @@ void Config::create() ...@@ -1602,8 +1496,8 @@ void Config::create()
); );
cb = addBool( cb = addBool(
"OPTIMIZE_OUTPUT_FOR_C", "OPTIMIZE_OUTPUT_FOR_C",
"Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources \n" "Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C \n"
"only. Doxygen will then generate output that is more tailored for C. \n" "sources only. Doxygen will then generate output that is more tailored for C. \n"
"For instance, some of the names that are used will be different. The list \n" "For instance, some of the names that are used will be different. The list \n"
"of all members will be omitted, etc. \n", "of all members will be omitted, etc. \n",
FALSE FALSE
...@@ -1823,6 +1717,15 @@ void Config::create() ...@@ -1823,6 +1717,15 @@ void Config::create()
"in the documentation.\n", "in the documentation.\n",
TRUE TRUE
); );
cs = addString( "FILE_VERSION_FILTER",
"The FILE_VERSION_FILTER tag can be used to specify a program or script that \n"
"doxygen should invoke to get the current version for each file (typically from the \n"
"version control system). Doxygen will invoke the program by executing (via \n"
"popen()) the command <command> <input-file>, where <command> is the value of \n"
"the FILE_VERSION_FILTER tag, and <input-file> is the name of an input file \n"
"provided by doxygen. Whatever the progam writes to standard output \n"
"is used as the file version. See the manual for examples. \n"
);
//----------------------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------------------
addInfo( "Messages","configuration options related to warning and progress messages"); addInfo( "Messages","configuration options related to warning and progress messages");
...@@ -1869,7 +1772,9 @@ void Config::create() ...@@ -1869,7 +1772,9 @@ void Config::create()
"The WARN_FORMAT tag determines the format of the warning messages that \n" "The WARN_FORMAT tag determines the format of the warning messages that \n"
"doxygen can produce. The string should contain the $file, $line, and $text \n" "doxygen can produce. The string should contain the $file, $line, and $text \n"
"tags, which will be replaced by the file and line number from which the \n" "tags, which will be replaced by the file and line number from which the \n"
"warning originated and the warning text. \n" "warning originated and the warning text. Optionally the format may contain \n"
"$version, which will be replaced by the version of the file (if it could \n"
"be obtained via FILE_VERSION_FILTER)\n"
); );
cs->setDefaultValue("$file:$line: $text"); cs->setDefaultValue("$file:$line: $text");
cs = addString( cs = addString(
...@@ -1895,8 +1800,8 @@ void Config::create() ...@@ -1895,8 +1800,8 @@ void Config::create()
"FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp \n" "FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp \n"
"and *.h) to filter out the source-files in the directories. If left \n" "and *.h) to filter out the source-files in the directories. If left \n"
"blank the following patterns are tested: \n" "blank the following patterns are tested: \n"
"*.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx *.hpp \n" "*.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx \n"
"*.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm\n" "*.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm\n"
); );
cb = addBool( cb = addBool(
"RECURSIVE", "RECURSIVE",
...@@ -1913,8 +1818,9 @@ void Config::create() ...@@ -1913,8 +1818,9 @@ void Config::create()
); );
cb = addBool( cb = addBool(
"EXCLUDE_SYMLINKS", "EXCLUDE_SYMLINKS",
"The EXCLUDE_SYMLINKS tag can be used select whether or not files or directories \n" "The EXCLUDE_SYMLINKS tag can be used select whether or not files or \n"
"that are symbolic links (a Unix filesystem feature) are excluded from the input. \n", "directories that are symbolic links (a Unix filesystem feature) are excluded \n"
"from the input. \n",
FALSE FALSE
); );
cl->setWidgetType(ConfigList::FileAndDir); cl->setWidgetType(ConfigList::FileAndDir);
...@@ -2556,8 +2462,8 @@ void Config::create() ...@@ -2556,8 +2462,8 @@ void Config::create()
"If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then \n" "If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then \n"
"doxygen's preprocessor will remove all function-like macros that are alone \n" "doxygen's preprocessor will remove all function-like macros that are alone \n"
"on a line, have an all uppercase name, and do not end with a semicolon. Such \n" "on a line, have an all uppercase name, and do not end with a semicolon. Such \n"
"function macros are typically used for boiler-plate code, and will confuse the \n" "function macros are typically used for boiler-plate code, and will confuse \n"
"parser if not removed. \n", "the parser if not removed. \n",
TRUE TRUE
); );
cb->addDependency("ENABLE_PREPROCESSING"); cb->addDependency("ENABLE_PREPROCESSING");
...@@ -2616,10 +2522,11 @@ void Config::create() ...@@ -2616,10 +2522,11 @@ void Config::create()
cb = addBool( cb = addBool(
"CLASS_DIAGRAMS", "CLASS_DIAGRAMS",
"If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will \n" "If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will \n"
"generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base or \n" "generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base \n"
"super classes. Setting the tag to NO turns the diagrams off. Note that this \n" "or super classes. Setting the tag to NO turns the diagrams off. Note that \n"
"option is superseded by the HAVE_DOT option below. This is only a fallback. It is \n" "this option is superseded by the HAVE_DOT option below. This is only a \n"
"recommended to install and use dot, since it yields more powerful graphs. \n", "fallback. It is recommended to install and use dot, since it yields more \n"
"powerful graphs. \n",
TRUE TRUE
); );
cb = addBool( cb = addBool(
...@@ -2770,15 +2677,35 @@ void Config::create() ...@@ -2770,15 +2677,35 @@ void Config::create()
"MAX_DOT_GRAPH_DEPTH", "MAX_DOT_GRAPH_DEPTH",
"The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the \n" "The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the \n"
"graphs generated by dot. A depth value of 3 means that only nodes reachable \n" "graphs generated by dot. A depth value of 3 means that only nodes reachable \n"
"from the root by following a path via at most 3 edges will be shown. Nodes that \n" "from the root by following a path via at most 3 edges will be shown. Nodes \n"
"lay further from the root node will be omitted. Note that setting this option to \n" "that lay further from the root node will be omitted. Note that setting this \n"
"1 or 2 may greatly reduce the computation time needed for large code bases. Also \n" "option to 1 or 2 may greatly reduce the computation time needed for large \n"
"note that a graph may be further truncated if the graph's image dimensions are \n" "code bases. Also note that a graph may be further truncated if the graph's \n"
"not sufficient to fit the graph (see MAX_DOT_GRAPH_WIDTH and MAX_DOT_GRAPH_HEIGHT). \n" "image dimensions are not sufficient to fit the graph (see MAX_DOT_GRAPH_WIDTH \n"
"If 0 is used for the depth value (the default), the graph is not depth-constrained. \n", "and MAX_DOT_GRAPH_HEIGHT). If 0 is used for the depth value (the default), \n"
"the graph is not depth-constrained. \n",
0,1000,0 0,1000,0
); );
ci->addDependency("HAVE_DOT"); ci->addDependency("HAVE_DOT");
cb = addBool(
"DOT_TRANSPARENT",
"Set the DOT_TRANSPARENT tag to YES to generate images with a transparent \n"
"background. This is disabled by default, which results in a white background. \n"
"Warning: Depending on the platform used, enabling this option may lead to \n"
"badly anti-aliased labels on the edges of a graph (i.e. they become hard to \n"
"read). \n",
FALSE
);
cb->addDependency("HAVE_DOT");
cb = addBool(
"DOT_MULTI_TARGETS",
"Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output \n"
"files in one run (i.e. multiple -o and -T options on the command line). This \n"
"makes dot run faster, but since only newer versions of dot (>1.8.10) \n"
"support this, this feature is disabled by default. \n",
FALSE
);
cb->addDependency("HAVE_DOT");
cb = addBool( cb = addBool(
"GENERATE_LEGEND", "GENERATE_LEGEND",
"If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will \n" "If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will \n"
......
...@@ -498,6 +498,10 @@ DirDef *DirDef::mergeDirectoryInTree(const QCString &path) ...@@ -498,6 +498,10 @@ DirDef *DirDef::mergeDirectoryInTree(const QCString &path)
void DirDef::writeDepGraph(QTextStream &t) void DirDef::writeDepGraph(QTextStream &t)
{ {
t << "digraph G {\n"; t << "digraph G {\n";
if (Config_getBool("DOT_TRANSPARENT"))
{
t << " bgcolor=transparent;\n";
}
t << " compound=true\n"; t << " compound=true\n";
t << " node [ fontsize=10, fontname=\"Helvetica\"];\n"; t << " node [ fontsize=10, fontname=\"Helvetica\"];\n";
t << " edge [ labelfontsize=9, labelfontname=\"Helvetica\"];\n"; t << " edge [ labelfontsize=9, labelfontname=\"Helvetica\"];\n";
...@@ -583,7 +587,11 @@ void DirDef::writeDepGraph(QTextStream &t) ...@@ -583,7 +587,11 @@ void DirDef::writeDepGraph(QTextStream &t)
<< usedDir->shortName() << "\""; << usedDir->shortName() << "\"";
if (usedDir->isCluster()) if (usedDir->isCluster())
{ {
t << " color=\"red\" fillcolor=\"white\" style=\"filled\""; if (!Config_getBool("DOT_TRANSPARENT"))
{
t << " fillcolor=\"white\" style=\"filled\"";
}
t << " color=\"red\"";
} }
t << " URL=\"" << usedDir->getOutputFileBase() t << " URL=\"" << usedDir->getOutputFileBase()
<< Doxygen::htmlFileExtension << "\"];\n"; << Doxygen::htmlFileExtension << "\"];\n";
...@@ -831,13 +839,20 @@ void writeDirDependencyGraph(const char *dirName) ...@@ -831,13 +839,20 @@ void writeDirDependencyGraph(const char *dirName)
dir->writeDepGraph(t); dir->writeDepGraph(t);
} }
f.close(); f.close();
QCString dotArgs(4096);
QCString outFile = QCString(dirName)+"/"+dir->getOutputFileBase()+"_dep.gif"; QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT");
dotArgs.sprintf("%s -Tgif -o %s",path.data(),outFile.data()); QCString outFile = QCString(dirName)+"/"+
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0) dir->getOutputFileBase()+"_dep."+imgExt;
{ DotRunner dotRun(path);
err("Problems running dot. Check your installation!\n"); dotRun.addJob(imgExt,outFile);
} dotRun.run();
//QCString dotArgs(4096);
//dotArgs.sprintf("%s -Tgif -o %s",path.data(),outFile.data());
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
//}
} }
out << "</body></html>"; out << "</body></html>";
} }
......
...@@ -505,16 +505,16 @@ static bool insideOL(DocNode *n) ...@@ -505,16 +505,16 @@ static bool insideOL(DocNode *n)
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
/*! Returns TRUE iff node n is a child of a language node */ ///*! Returns TRUE iff node n is a child of a language node */
static bool insideLang(DocNode *n) //static bool insideLang(DocNode *n)
{ //{
while (n) // while (n)
{ // {
if (n->kind()==DocNode::Kind_Language) return TRUE; // if (n->kind()==DocNode::Kind_Language) return TRUE;
n=n->parent(); // n=n->parent();
} // }
return FALSE; // return FALSE;
} //}
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
...@@ -673,6 +673,10 @@ static int handleStyleArgument(DocNode *parent,QList<DocNode> &children, ...@@ -673,6 +673,10 @@ static int handleStyleArgument(DocNode *parent,QList<DocNode> &children,
g_token->name.data(),cmdName.data()); g_token->name.data(),cmdName.data());
break; break;
case TK_HTMLTAG: case TK_HTMLTAG:
if (insideLI(parent) && HtmlTagMapper::map(g_token->name) && g_token->endTag)
{ // ignore </li> as the end of a style command
continue;
}
return tok; return tok;
break; break;
default: default:
...@@ -844,7 +848,7 @@ static void handleLinkedWord(DocNode *parent,QList<DocNode> &children) ...@@ -844,7 +848,7 @@ static void handleLinkedWord(DocNode *parent,QList<DocNode> &children)
if (!g_insideHtmlLink && if (!g_insideHtmlLink &&
resolveRef(g_context,g_token->name,g_inSeeBlock,&compound,&member)) resolveRef(g_context,g_token->name,g_inSeeBlock,&compound,&member))
{ {
//printf("resolveRef %s = %p (linkable?=%d)\n",g_token->name.data(),member,member->isLinkable()); //printf("resolveRef %s = %p (linkable?=%d)\n",g_token->name.data(),member,member ? member->isLinkable() : FALSE);
if (member) // member link if (member) // member link
{ {
children.append(new children.append(new
...@@ -861,6 +865,10 @@ static void handleLinkedWord(DocNode *parent,QList<DocNode> &children) ...@@ -861,6 +865,10 @@ static void handleLinkedWord(DocNode *parent,QList<DocNode> &children)
{ {
name=g_token->name; name=g_token->name;
} }
else if (compound->definitionType()==Definition::TypeGroup)
{
name=((GroupDef*)compound)->groupTitle();
}
children.append(new children.append(new
DocLinkedWord(parent,name, DocLinkedWord(parent,name,
compound->getReference(), compound->getReference(),
...@@ -1662,30 +1670,30 @@ DocFormula::DocFormula(DocNode *parent,int id) : ...@@ -1662,30 +1670,30 @@ DocFormula::DocFormula(DocNode *parent,int id) :
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
int DocLanguage::parse() //int DocLanguage::parse()
{ //{
int retval; // int retval;
DBG(("DocLanguage::parse() start\n")); // DBG(("DocLanguage::parse() start\n"));
g_nodeStack.push(this); // g_nodeStack.push(this);
//
// parse one or more paragraphs // // parse one or more paragraphs
bool isFirst=TRUE; // bool isFirst=TRUE;
DocPara *par=0; // DocPara *par=0;
do // do
{ // {
par = new DocPara(this); // par = new DocPara(this);
if (isFirst) { par->markFirst(); isFirst=FALSE; } // if (isFirst) { par->markFirst(); isFirst=FALSE; }
m_children.append(par); // m_children.append(par);
retval=par->parse(); // retval=par->parse();
} // }
while (retval==TK_NEWPARA); // while (retval==TK_NEWPARA);
if (par) par->markLast(); // if (par) par->markLast();
//
DBG(("DocLanguage::parse() end\n")); // DBG(("DocLanguage::parse() end\n"));
DocNode *n = g_nodeStack.pop(); // DocNode *n = g_nodeStack.pop();
ASSERT(n==this); // ASSERT(n==this);
return retval; // return retval;
} //}
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
...@@ -3627,50 +3635,49 @@ endref: ...@@ -3627,50 +3635,49 @@ endref:
doctokenizerYYsetStatePara(); doctokenizerYYsetStatePara();
} }
//int DocPara::handleLanguageSwitch()
int DocPara::handleLanguageSwitch() //{
{ // int retval=RetVal_OK;
int retval=RetVal_OK; //
// if (!insideLang(this)) // start a language section at this level
if (!insideLang(this)) // start a language section at this level // {
{ // do
do // {
{ // int tok = doctokenizerYYlex();
int tok = doctokenizerYYlex(); // if (tok==TK_WHITESPACE)
if (tok==TK_WHITESPACE) // {
{ // // end of language specific sections
// end of language specific sections // retval=RetVal_OK;
retval=RetVal_OK; // goto endlang;
goto endlang; // }
} // else if (tok==TK_NEWPARA)
else if (tok==TK_NEWPARA) // {
{ // // end of language specific sections
// end of language specific sections // retval = tok;
retval = tok; // goto endlang;
goto endlang; // }
} // else if (tok==TK_WORD || tok==TK_LNKWORD)
else if (tok==TK_WORD || tok==TK_LNKWORD) // {
{ // DocLanguage *dl = new DocLanguage(this,g_token->name);
DocLanguage *dl = new DocLanguage(this,g_token->name); // m_children.append(dl);
m_children.append(dl); // retval = dl->parse();
retval = dl->parse(); // }
} // else
else // {
{ // warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: Unexpected token %s as parameter of \\~",
warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: Unexpected token %s as parameter of \\~", // tokToString(tok));
tokToString(tok)); // goto endlang;
goto endlang; // }
} // }
} // while (retval==RetVal_SwitchLang);
while (retval==RetVal_SwitchLang); // }
} // else // return from this section
else // return from this section // {
{ // retval = RetVal_SwitchLang;
retval = RetVal_SwitchLang; // }
} //endlang:
endlang: // return retval;
return retval; //}
}
void DocPara::handleInclude(const QString &cmdName,DocInclude::Type t) void DocPara::handleInclude(const QString &cmdName,DocInclude::Type t)
{ {
...@@ -4091,9 +4098,9 @@ int DocPara::handleCommand(const QString &cmdName) ...@@ -4091,9 +4098,9 @@ int DocPara::handleCommand(const QString &cmdName)
m_children.append(form); m_children.append(form);
} }
break; break;
case CMD_LANGSWITCH: //case CMD_LANGSWITCH:
retval = handleLanguageSwitch(); // retval = handleLanguageSwitch();
break; // break;
case CMD_INTERNALREF: case CMD_INTERNALREF:
warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: unexpected command %s",g_token->name.data()); warn_doc_error(g_fileName,doctokenizerYYlineno,"Warning: unexpected command %s",g_token->name.data());
break; break;
......
...@@ -124,7 +124,7 @@ class DocNode ...@@ -124,7 +124,7 @@ class DocNode
Kind_Formula = 38, Kind_Formula = 38,
Kind_SecRefItem = 39, Kind_SecRefItem = 39,
Kind_SecRefList = 40, Kind_SecRefList = 40,
Kind_Language = 41, //Kind_Language = 41,
Kind_LinkedWord = 42, Kind_LinkedWord = 42,
Kind_ParamSect = 43, Kind_ParamSect = 43,
Kind_ParamList = 44, Kind_ParamList = 44,
...@@ -695,21 +695,21 @@ class DocInternalRef : public CompAccept<DocInternalRef>, public DocNode ...@@ -695,21 +695,21 @@ class DocInternalRef : public CompAccept<DocInternalRef>, public DocNode
}; };
/*! @brief Node representing a Language specific section */ /*! @brief Node representing a Language specific section */
class DocLanguage : public CompAccept<DocLanguage>, public DocNode //class DocLanguage : public CompAccept<DocLanguage>, public DocNode
{ //{
public: // public:
DocLanguage(DocNode *parent,const QString &id) : // DocLanguage(DocNode *parent,const QString &id) :
m_parent(parent), m_id(id) {} // m_parent(parent), m_id(id) {}
QString id() const { return m_id; } // QString id() const { return m_id; }
Kind kind() const { return Kind_Language; } // Kind kind() const { return Kind_Language; }
DocNode *parent() const { return m_parent; } // DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v) { CompAccept<DocLanguage>::accept(this,v); } // void accept(DocVisitor *v) { CompAccept<DocLanguage>::accept(this,v); }
int parse(); // int parse();
//
private: // private:
DocNode * m_parent; // DocNode * m_parent;
QString m_id; // QString m_id;
}; //};
/*! @brief Node representing a Hypertext reference */ /*! @brief Node representing a Hypertext reference */
class DocHRef : public CompAccept<DocHRef>, public DocNode class DocHRef : public CompAccept<DocHRef>, public DocNode
...@@ -973,7 +973,7 @@ class DocPara : public CompAccept<DocPara>, public DocNode ...@@ -973,7 +973,7 @@ class DocPara : public CompAccept<DocPara>, public DocNode
void handleRef(const QString &cmdName); void handleRef(const QString &cmdName);
void handleSection(const QString &cmdName); void handleSection(const QString &cmdName);
int handleHtmlHeader(const HtmlAttribList &tagHtmlAttribs,int level); int handleHtmlHeader(const HtmlAttribList &tagHtmlAttribs,int level);
int handleLanguageSwitch(); //int handleLanguageSwitch();
private: private:
DocNode *m_parent; DocNode *m_parent;
......
...@@ -69,7 +69,7 @@ class DocRef; ...@@ -69,7 +69,7 @@ class DocRef;
class DocFormula; class DocFormula;
class DocSecRefItem; class DocSecRefItem;
class DocSecRefList; class DocSecRefList;
class DocLanguage; //class DocLanguage;
class DocLinkedWord; class DocLinkedWord;
class DocParamSect; class DocParamSect;
class DocParamList; class DocParamList;
...@@ -163,8 +163,8 @@ class DocVisitor ...@@ -163,8 +163,8 @@ class DocVisitor
virtual void visitPost(DocSecRefItem *) = 0; virtual void visitPost(DocSecRefItem *) = 0;
virtual void visitPre(DocSecRefList *) = 0; virtual void visitPre(DocSecRefList *) = 0;
virtual void visitPost(DocSecRefList *) = 0; virtual void visitPost(DocSecRefList *) = 0;
virtual void visitPre(DocLanguage *) = 0; //virtual void visitPre(DocLanguage *) = 0;
virtual void visitPost(DocLanguage *) = 0; //virtual void visitPost(DocLanguage *) = 0;
virtual void visitPre(DocParamSect *) = 0; virtual void visitPre(DocParamSect *) = 0;
virtual void visitPost(DocParamSect *) = 0; virtual void visitPost(DocParamSect *) = 0;
virtual void visitPre(DocParamList *) = 0; virtual void visitPre(DocParamList *) = 0;
......
...@@ -35,9 +35,6 @@ ...@@ -35,9 +35,6 @@
#include <qtextstream.h> #include <qtextstream.h>
#include <md5.h> #include <md5.h>
// Enable this for transparent images
// It doesn't seems to work very well with edge labels so I disabled it.
//#define DOT_TRANSPARENT
//-------------------------------------------------------------------- //--------------------------------------------------------------------
...@@ -74,9 +71,10 @@ static void writeGraphHeader(QTextStream &t) ...@@ -74,9 +71,10 @@ static void writeGraphHeader(QTextStream &t)
{ {
t << "digraph G" << endl; t << "digraph G" << endl;
t << "{" << endl; t << "{" << endl;
#if defined(DOT_TRANSPARENT) if (Config_getBool("DOT_TRANSPARENT"))
t << " bgcolor=\"transparent\"" << endl; {
#endif t << " bgcolor=\"transparent\";" << endl;
}
t << " edge [fontname=\"Helvetica\",fontsize=10," t << " edge [fontname=\"Helvetica\",fontsize=10,"
"labelfontname=\"Helvetica\",labelfontsize=10];\n"; "labelfontname=\"Helvetica\",labelfontsize=10];\n";
t << " node [fontname=\"Helvetica\",fontsize=10,shape=record];\n"; t << " node [fontname=\"Helvetica\",fontsize=10,shape=record];\n";
...@@ -393,6 +391,53 @@ class DotNodeList : public QList<DotNode> ...@@ -393,6 +391,53 @@ class DotNodeList : public QList<DotNode>
//-------------------------------------------------------------------- //--------------------------------------------------------------------
DotRunner::DotRunner(const char *file) : m_file(file)
{
m_jobs.setAutoDelete(TRUE);
}
void DotRunner::addJob(const char *format,const char *output)
{
QCString args = QCString("-T")+format+" -o \""+output+"\"";
m_jobs.append(new QCString(args));
}
bool DotRunner::run()
{
QListIterator<QCString> li(m_jobs);
QCString *s;
if (Config_getBool("DOT_MULTI_TARGETS"))
{
QCString dotArgs="\""+m_file+"\"";
for (li.toFirst();(s=li.current());++li)
{
dotArgs+=' ';
dotArgs+=*s;
}
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{
goto error;
}
}
else
{
for (li.toFirst();(s=li.current());++li)
{
QCString dotArgs="\""+m_file+"\" "+*s;
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{
goto error;
}
}
}
return TRUE;
error:
err("Problems running dot. Check your installation!\n");
return FALSE;
}
//--------------------------------------------------------------------
/*! helper function that deletes all nodes in a connected graph, given /*! helper function that deletes all nodes in a connected graph, given
* one of the graph's nodes * one of the graph's nodes
...@@ -621,11 +666,14 @@ void DotNode::writeBox(QTextStream &t, ...@@ -621,11 +666,14 @@ void DotNode::writeBox(QTextStream &t,
} }
else else
{ {
#if defined(DOT_TRANSPARENT) if (!Config_getBool("DOT_TRANSPARENT"))
t << ",color=\"" << labCol << "\", fillcolor=\"white\", style=\"filled\""; {
#else t << ",color=\"" << labCol << "\", fillcolor=\"white\", style=\"filled\"";
t << ",color=\"" << labCol << "\""; }
#endif else
{
t << ",color=\"" << labCol << "\"";
}
if (!m_url.isEmpty()) if (!m_url.isEmpty())
{ {
int anchorPos = m_url.findRev('#'); int anchorPos = m_url.findRev('#');
...@@ -1067,17 +1115,23 @@ void DotGfxHierarchyTable::writeGraph(QTextStream &out,const char *path) ...@@ -1067,17 +1115,23 @@ void DotGfxHierarchyTable::writeGraph(QTextStream &out,const char *path)
f.close(); f.close();
resetReNumbering(); resetReNumbering();
QCString dotArgs(maxCmdLine); DotRunner dotRun(dotName);
dotArgs.sprintf("\"%s\" -T%s -o \"%s\" -Timap -o \"%s\"", dotRun.addJob(imgExt,imgName);
dotName.data(), imgExt.data(), imgName.data(), mapName.data()); dotRun.addJob("imap",mapName);
//printf("Running: dot %s -T%s -o %s -Timap -o %s\n", if (!dotRun.run())
// dotName.data(),imgExt.data(),imgName.data(),mapName.data());
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{ {
err("Problems running dot. Check your installation!\n");
out << "</table>" << endl; out << "</table>" << endl;
return; return;
} }
//QCString dotArgs(maxCmdLine);
//dotArgs.sprintf("\"%s\" -T%s -o \"%s\" -Timap -o \"%s\"",
// dotName.data(), imgExt.data(), imgName.data(), mapName.data());
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
// return;
//}
checkDotResult(imgName); checkDotResult(imgName);
if (Config_getBool("DOT_CLEANUP")) thisDir.remove(dotName); if (Config_getBool("DOT_CLEANUP")) thisDir.remove(dotName);
} }
...@@ -1625,14 +1679,22 @@ static bool findMaximalDotGraph(DotNode *root, ...@@ -1625,14 +1679,22 @@ static bool findMaximalDotGraph(DotNode *root,
writeDotGraph(root,gt,format,baseName,lrRank,renderParents, writeDotGraph(root,gt,format,baseName,lrRank,renderParents,
curDistance,backArrows,reNumber); curDistance,backArrows,reNumber);
QCString dotArgs(maxCmdLine);
// create annotated dot file // create annotated dot file
dotArgs.sprintf("-Tdot \"%s.dot\" -o \"%s_tmp.dot\"",baseName.data(),baseName.data()); DotRunner dotRun(baseName+".dot");
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0) dotRun.addJob("dot",baseName+"_tmp.dot");
if (!dotRun.run())
{ {
err("Problems running dot. Check your installation!\n");
return FALSE; return FALSE;
} }
//QCString dotArgs(maxCmdLine);
//// create annotated dot file
//dotArgs.sprintf("-Tdot \"%s.dot\" -o \"%s_tmp.dot\"",baseName.data(),baseName.data());
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
// {
// err("Problems running dot. Check your installation!\n");
// return FALSE;
//}
// extract bounding box from the result // extract bounding box from the result
readBoundingBoxDot(baseName+"_tmp.dot",&width,&height); readBoundingBoxDot(baseName+"_tmp.dot",&width,&height);
...@@ -1768,32 +1830,50 @@ QCString DotClassGraph::writeGraph(QTextStream &out, ...@@ -1768,32 +1830,50 @@ QCString DotClassGraph::writeGraph(QTextStream &out,
{ {
QCString dotArgs(maxCmdLine); QCString dotArgs(maxCmdLine);
QCString imgName = baseName+"."+imgExt; QCString imgName = baseName+"."+imgExt;
dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"",
baseName.data(),imgExt.data(),imgName.data()); DotRunner dotRun(baseName+".dot");
if (generateImageMap) dotRun.addJob(imgExt,imgName);
{ if (generateImageMap) dotRun.addJob("imap",baseName+".map");
// run dot also to create an image map if (!dotRun.run())
dotArgs+=QCString(maxCmdLine).sprintf(" -Timap -o \"%s.map\"",
baseName.data());
}
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{ {
err("Error: Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"",
// baseName.data(),imgExt.data(),imgName.data());
//if (generateImageMap)
//{
// // run dot also to create an image map
// dotArgs+=QCString(maxCmdLine).sprintf(" -Timap -o \"%s.map\"",
// baseName.data());
//}
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Error: Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
checkDotResult(imgName); checkDotResult(imgName);
} }
else if (format==EPS) // run dot to create a .eps image else if (format==EPS) // run dot to create a .eps image
{ {
QCString dotArgs(maxCmdLine); DotRunner dotRun(baseName+".dot");
dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"",baseName.data(),baseName.data()); dotRun.addJob("ps",baseName+".eps");
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0) if (!dotRun.run())
{ {
err("Error: Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//QCString dotArgs(maxCmdLine);
//dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"",baseName.data(),baseName.data());
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Error: Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
if (Config_getBool("USE_PDFLATEX")) if (Config_getBool("USE_PDFLATEX"))
{ {
QCString epstopdfArgs(maxCmdLine); QCString epstopdfArgs(maxCmdLine);
...@@ -2025,41 +2105,56 @@ QCString DotInclDepGraph::writeGraph(QTextStream &out, ...@@ -2025,41 +2105,56 @@ QCString DotInclDepGraph::writeGraph(QTextStream &out,
format, // format format, // format
TRUE, // lrRank TRUE, // lrRank
FALSE, // renderParents FALSE, // renderParents
FALSE // backArrows m_inverse // backArrows
); );
if (format==BITMAP) if (format==BITMAP)
{ {
// run dot to create a bitmap image // run dot to create a bitmap image
QCString dotArgs(maxCmdLine); QCString dotArgs(maxCmdLine);
QCString imgName=baseName+"."+imgExt; QCString imgName=baseName+"."+imgExt;
dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"", DotRunner dotRun(baseName+".dot");
baseName.data(),imgExt.data(),imgName.data()); dotRun.addJob(imgExt,imgName);
if (generateImageMap) if (generateImageMap) dotRun.addJob("imap",baseName+".map");
if (!dotRun.run())
{ {
// run dot also to create an image map
dotArgs+=QCString(maxCmdLine).sprintf(" -Timap -o \"%s.map\"",
baseName.data());
}
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"",
// baseName.data(),imgExt.data(),imgName.data());
//if (generateImageMap)
//{
// // run dot also to create an image map
// dotArgs+=QCString(maxCmdLine).sprintf(" -Timap -o \"%s.map\"",
// baseName.data());
//}
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
checkDotResult(imgName); checkDotResult(imgName);
} }
else if (format==EPS) else if (format==EPS)
{ {
// run dot to create a .eps image // run dot to create a .eps image
QCString dotArgs(maxCmdLine); DotRunner dotRun(baseName+".dot");
dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"", dotRun.addJob("ps",baseName+".eps");
baseName.data(),baseName.data()); if (!dotRun.run())
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{ {
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//QCString dotArgs(maxCmdLine);
//dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"",
// baseName.data(),baseName.data());
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
if (Config_getBool("USE_PDFLATEX")) if (Config_getBool("USE_PDFLATEX"))
{ {
QCString epstopdfArgs(maxCmdLine); QCString epstopdfArgs(maxCmdLine);
...@@ -2218,34 +2313,49 @@ QCString DotCallGraph::writeGraph(QTextStream &out, GraphOutputFormat format, ...@@ -2218,34 +2313,49 @@ QCString DotCallGraph::writeGraph(QTextStream &out, GraphOutputFormat format,
// run dot to create a bitmap image // run dot to create a bitmap image
QCString dotArgs(maxCmdLine); QCString dotArgs(maxCmdLine);
QCString imgName=baseName+"."+imgExt; QCString imgName=baseName+"."+imgExt;
dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"", DotRunner dotRun(baseName+".dot");
baseName.data(),imgExt.data(),imgName.data()); dotRun.addJob(imgExt,imgName);
if (generateImageMap) if (generateImageMap) dotRun.addJob("imap",baseName+".map");
{ if (!dotRun.run())
// run dot also to create an image map
dotArgs+=QCString(maxCmdLine).sprintf(" -Timap -o \"%s.map\"",
baseName.data());
}
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{ {
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"",
// baseName.data(),imgExt.data(),imgName.data());
//if (generateImageMap)
//{
// // run dot also to create an image map
// dotArgs+=QCString(maxCmdLine).sprintf(" -Timap -o \"%s.map\"",
// baseName.data());
//}
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
checkDotResult(imgName); checkDotResult(imgName);
} }
else if (format==EPS) else if (format==EPS)
{ {
// run dot to create a .eps image // run dot to create a .eps image
QCString dotArgs(maxCmdLine); DotRunner dotRun(baseName+".dot");
dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"", dotRun.addJob("ps",baseName+".eps");
baseName.data(),baseName.data()); if (!dotRun.run())
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{ {
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//QCString dotArgs(maxCmdLine);
//dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"",
// baseName.data(),baseName.data());
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
if (Config_getBool("USE_PDFLATEX")) if (Config_getBool("USE_PDFLATEX"))
{ {
QCString epstopdfArgs(maxCmdLine); QCString epstopdfArgs(maxCmdLine);
...@@ -2410,34 +2520,49 @@ QCString DotDirDeps::writeGraph(QTextStream &out, ...@@ -2410,34 +2520,49 @@ QCString DotDirDeps::writeGraph(QTextStream &out,
// run dot to create a bitmap image // run dot to create a bitmap image
QCString dotArgs(maxCmdLine); QCString dotArgs(maxCmdLine);
QCString imgName=baseName+"."+imgExt; QCString imgName=baseName+"."+imgExt;
dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"", DotRunner dotRun(baseName+".dot");
baseName.data(),imgExt.data(),imgName.data()); dotRun.addJob(imgExt,imgName);
if (generateImageMap) if (generateImageMap) dotRun.addJob("imap",baseName+".map");
{ if (!dotRun.run())
// run dot also to create an image map
dotArgs+=QCString(maxCmdLine).sprintf(" -Timap -o \"%s.map\"",
baseName.data());
}
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{ {
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"",
// baseName.data(),imgExt.data(),imgName.data());
//if (generateImageMap)
//{
// // run dot also to create an image map
// dotArgs+=QCString(maxCmdLine).sprintf(" -Timap -o \"%s.map\"",
// baseName.data());
//}
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
checkDotResult(imgName); checkDotResult(imgName);
} }
else if (format==EPS) else if (format==EPS)
{ {
// run dot to create a .eps image // run dot to create a .eps image
QCString dotArgs(maxCmdLine); DotRunner dotRun(baseName+".dot");
dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"", dotRun.addJob("ps",baseName+".eps");
baseName.data(),baseName.data()); if (!dotRun.run())
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{ {
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//QCString dotArgs(maxCmdLine);
//dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"",
// baseName.data(),baseName.data());
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
if (Config_getBool("USE_PDFLATEX")) if (Config_getBool("USE_PDFLATEX"))
{ {
QCString epstopdfArgs(maxCmdLine); QCString epstopdfArgs(maxCmdLine);
...@@ -2553,16 +2678,24 @@ void generateGraphLegend(const char *path) ...@@ -2553,16 +2678,24 @@ void generateGraphLegend(const char *path)
QDir::setCurrent(d.absPath()); QDir::setCurrent(d.absPath());
// run dot to generate the a bitmap image from the graph // run dot to generate the a bitmap image from the graph
QCString dotArgs(maxCmdLine);
QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT"); QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT");
QCString imgName = "graph_legend."+imgExt; QCString imgName = "graph_legend."+imgExt;
dotArgs.sprintf("-T%s graph_legend.dot -o %s",imgExt.data(),imgName.data());
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0) DotRunner dotRun("graph_legend.dot");
dotRun.addJob(imgExt,imgName);
if (!dotRun.run())
{ {
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return; return;
} }
//QCString dotArgs(maxCmdLine);
//dotArgs.sprintf("-T%s graph_legend.dot -o %s",imgExt.data(),imgName.data());
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return;
//}
checkDotResult(imgName); checkDotResult(imgName);
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
} }
...@@ -2595,26 +2728,37 @@ void writeDotGraphFromFile(const char *inFile,const char *outDir, ...@@ -2595,26 +2728,37 @@ void writeDotGraphFromFile(const char *inFile,const char *outDir,
// outf.writeBlock(a.data(),s); // outf.writeBlock(a.data(),s);
//} //}
QCString dotArgs(maxCmdLine);
QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT"); QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT");
QCString imgName = (QCString)outFile+"."+imgExt; QCString imgName = (QCString)outFile+"."+imgExt;
if (format==BITMAP)
{ DotRunner dotRun(inFile);
dotArgs.sprintf("-T%s \"%s\" -o \"%s\"", if (format==BITMAP)
imgExt.data(), dotRun.addJob(imgExt,imgName);
inFile,
imgName.data());
}
else // format==EPS else // format==EPS
dotRun.addJob("ps",QCString(outFile)+".eps");
if (!dotRun.run())
{ {
dotArgs.sprintf("-Tps \"%s\" -o \"%s.eps\"",inFile,outFile); QDir::setCurrent(oldDir);
} return;
QCString dotExe = Config_getString("DOT_PATH")+"dot";
//printf("Running: %s %s\n",dotExe.data(),dotArgs.data());
if (iSystem(dotExe,dotArgs)!=0)
{
err("Problems running dot. Check your installation!\n");
} }
//QCString dotArgs(maxCmdLine);
//if (format==BITMAP)
//{
// dotArgs.sprintf("-T%s \"%s\" -o \"%s\"",
// imgExt.data(),
// inFile,
// imgName.data());
//}
//else // format==EPS
//{
// dotArgs.sprintf("-Tps \"%s\" -o \"%s.eps\"",inFile,outFile);
//}
//QCString dotExe = Config_getString("DOT_PATH")+"dot";
////printf("Running: %s %s\n",dotExe.data(),dotArgs.data());
//if (iSystem(dotExe,dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
//}
// Added by Nils Strom // Added by Nils Strom
if ( (format==EPS) && (Config_getBool("USE_PDFLATEX")) ) if ( (format==EPS) && (Config_getBool("USE_PDFLATEX")) )
{ {
...@@ -2651,17 +2795,24 @@ QString getDotImageMapFromFile(const QString& inFile, const QString& outDir, ...@@ -2651,17 +2795,24 @@ QString getDotImageMapFromFile(const QString& inFile, const QString& outDir,
QDir::setCurrent(outDir); QDir::setCurrent(outDir);
//printf("Going to dir %s\n",QDir::currentDirPath().data()); //printf("Going to dir %s\n",QDir::currentDirPath().data());
QCString dotArgs(maxCmdLine); DotRunner dotRun(inFile);
dotArgs.sprintf("-Timap \"%s\" -o \"%s\"", inFile.data(), outFile.data()); dotRun.addJob("imap",outFile);
if (!dotRun.run())
QCString dotExe = Config_getString("DOT_PATH") + "dot";
//printf("Running: %s %s\n",dotExe.data(),dotArgs.data());
if (iSystem(dotExe,dotArgs)!=0)
{ {
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return ""; return "";
} }
//QCString dotArgs(maxCmdLine);
//dotArgs.sprintf("-Timap \"%s\" -o \"%s\"", inFile.data(), outFile.data());
//QCString dotExe = Config_getString("DOT_PATH") + "dot";
////printf("Running: %s %s\n",dotExe.data(),dotArgs.data());
//if (iSystem(dotExe,dotArgs)!=0)
//{
// err("Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return "";
//}
QString result; QString result;
QTextOStream tmpout(&result); QTextOStream tmpout(&result);
convertMapFile(tmpout, outFile, relPath ,TRUE); convertMapFile(tmpout, outFile, relPath ,TRUE);
...@@ -2928,22 +3079,31 @@ QCString DotGroupCollaboration::writeGraph( QTextStream &t, GraphOutputFormat fo ...@@ -2928,22 +3079,31 @@ QCString DotGroupCollaboration::writeGraph( QTextStream &t, GraphOutputFormat fo
{ {
QCString dotArgs(maxCmdLine); QCString dotArgs(maxCmdLine);
QCString imgName = baseName+"."+imgExt; QCString imgName = baseName+"."+imgExt;
dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"",
baseName.data(), imgExt.data(), imgName.data());
QCString mapName=baseName+".map"; QCString mapName=baseName+".map";
if (writeImageMap) DotRunner dotRun(baseName);
dotRun.addJob(imgExt,imgName);
if (writeImageMap) dotRun.addJob("imap",mapName);
if (!dotRun.run())
{ {
// run dot also to create an image map
dotArgs+=" -Timap -o \""+mapName+"\"";
}
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Error: Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//dotArgs.sprintf("\"%s.dot\" -T%s -o \"%s\"",
// baseName.data(), imgExt.data(), imgName.data());
//
//if (writeImageMap)
//{
// // run dot also to create an image map
// dotArgs+=" -Timap -o \""+mapName+"\"";
//}
//
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Error: Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
if (writeImageMap) if (writeImageMap)
{ {
...@@ -2959,15 +3119,22 @@ QCString DotGroupCollaboration::writeGraph( QTextStream &t, GraphOutputFormat fo ...@@ -2959,15 +3119,22 @@ QCString DotGroupCollaboration::writeGraph( QTextStream &t, GraphOutputFormat fo
} }
else if (format==EPS) else if (format==EPS)
{ {
QCString dotArgs(maxCmdLine); DotRunner dotRun(baseName+".dot");
dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"", dotRun.addJob("ps",baseName+".eps");
baseName.data(),baseName.data()); if (!dotRun.run())
if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
{ {
err("Error: Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir); QDir::setCurrent(oldDir);
return baseName; return baseName;
} }
//QCString dotArgs(maxCmdLine);
//dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"",
// baseName.data(),baseName.data());
//if (iSystem(Config_getString("DOT_PATH")+"dot",dotArgs)!=0)
//{
// err("Error: Problems running dot. Check your installation!\n");
// QDir::setCurrent(oldDir);
// return baseName;
//}
if (Config_getBool("USE_PDFLATEX")) if (Config_getBool("USE_PDFLATEX"))
{ {
QCString epstopdfArgs(maxCmdLine); QCString epstopdfArgs(maxCmdLine);
...@@ -3074,9 +3241,10 @@ void DotGroupCollaboration::writeGraphHeader(QTextStream &t) ...@@ -3074,9 +3241,10 @@ void DotGroupCollaboration::writeGraphHeader(QTextStream &t)
{ {
t << "digraph structs" << endl; t << "digraph structs" << endl;
t << "{" << endl; t << "{" << endl;
#if defined(DOT_TRANSPARENT) if (Config_getBool("DOT_TRANSPARENT"))
t << " bgcolor=\"transparent\"" << endl; {
#endif t << " bgcolor=\"transparent\";" << endl;
}
t << " edge [fontname=\"Helvetica\",fontsize=8," t << " edge [fontname=\"Helvetica\",fontsize=8,"
"labelfontname=\"Helvetica\",labelfontsize=8];\n"; "labelfontname=\"Helvetica\",labelfontsize=8];\n";
t << " node [fontname=\"Helvetica\",fontsize=10,shape=record];\n"; t << " node [fontname=\"Helvetica\",fontsize=10,shape=record];\n";
......
...@@ -286,6 +286,28 @@ class DotGroupCollaboration ...@@ -286,6 +286,28 @@ class DotGroupCollaboration
QList<Edge> m_edges; QList<Edge> m_edges;
}; };
/** @brief Helper class to run dot from doxygen.
*/
class DotRunner
{
public:
/** Creates a runner for a dot \a file. */
DotRunner(const char *file);
/** Adds an additional job to the run.
* Performing multiple jobs one file can be faster.
*/
void addJob(const char *format,const char *output);
/** Runs dot for all jobs added. */
bool run();
private:
QList<QCString> m_jobs;
QCString m_file;
};
void generateGraphLegend(const char *path); void generateGraphLegend(const char *path);
void writeDotGraphFromFile(const char *inFile,const char *outDir, void writeDotGraphFromFile(const char *inFile,const char *outDir,
const char *outFile,GraphOutputFormat format); const char *outFile,GraphOutputFormat format);
......
...@@ -1408,12 +1408,11 @@ static MemberDef *addVariableToClass( ...@@ -1408,12 +1408,11 @@ static MemberDef *addVariableToClass(
Entry *root, Entry *root,
ClassDef *cd, ClassDef *cd,
MemberDef::MemberType mtype, MemberDef::MemberType mtype,
/*const QCString &scope,*/
const QCString &name, const QCString &name,
bool fromAnnScope, bool fromAnnScope,
/*int indentDepth,*/
MemberDef *fromAnnMemb, MemberDef *fromAnnMemb,
Protection prot) Protection prot,
bool related)
{ {
QCString qualScope = cd->qualifiedNameWithTemplateParameters(); QCString qualScope = cd->qualifiedNameWithTemplateParameters();
QCString scopeSeparator="::"; QCString scopeSeparator="::";
...@@ -1437,7 +1436,7 @@ static MemberDef *addVariableToClass( ...@@ -1437,7 +1436,7 @@ static MemberDef *addVariableToClass(
QCString def; QCString def;
if (!root->type.isEmpty()) if (!root->type.isEmpty())
{ {
if (mtype==MemberDef::Friend || Config_getBool("HIDE_SCOPE_NAMES")) if (related || mtype==MemberDef::Friend || Config_getBool("HIDE_SCOPE_NAMES"))
{ {
def=root->type+" "+name+root->args; def=root->type+" "+name+root->args;
} }
...@@ -1481,7 +1480,7 @@ static MemberDef *addVariableToClass( ...@@ -1481,7 +1480,7 @@ static MemberDef *addVariableToClass(
MemberDef *md=new MemberDef( MemberDef *md=new MemberDef(
root->fileName,root->startLine, root->fileName,root->startLine,
root->type,name,root->args,0, root->type,name,root->args,0,
prot,Normal,root->stat,FALSE, prot,Normal,root->stat,related,
mtype,0,0); mtype,0,0);
if (root->tagInfo) if (root->tagInfo)
{ {
...@@ -1636,24 +1635,6 @@ static MemberDef *addVariableToFile( ...@@ -1636,24 +1635,6 @@ static MemberDef *addVariableToFile(
md->setRefItems(root->sli); md->setRefItems(root->sli);
return md; return md;
} }
// TODO: rethink why we would need this!
//if (nd==0 && md->isExplicit()!=root->explicitExternal)
//{
// // merge ingroup specifiers
// if (md->getGroupDef()==0 && root->groups->first())
// {
// //GroupDef *gd=Doxygen::groupSDict[root->groups->first()->groupname.data()];
// //md->setGroupDef(gd, root->groups->first()->pri, root->fileName, root->startLine, !root->doc.isEmpty());
// addMemberToGroups(root,md);
// }
// else if (md->getGroupDef()!=0 && root->groups->count()==0)
// {
// // enabling has the result that an ungrouped, undocumented external variable is put
// // in a group if the definition is documented and grouped!
// //root->groups->append(new Grouping(md->getGroupDef()->name(), md->getGroupPri()));
// }
//}
} }
} }
// new global variable, enum value or typedef // new global variable, enum value or typedef
...@@ -1667,8 +1648,6 @@ static MemberDef *addVariableToFile( ...@@ -1667,8 +1648,6 @@ static MemberDef *addVariableToFile(
md->setAnchor(root->tagInfo->anchor); md->setAnchor(root->tagInfo->anchor);
md->setReference(root->tagInfo->tagName); md->setReference(root->tagInfo->tagName);
} }
//md->setDefFile(root->fileName);
//md->setDefLine(root->startLine);
md->setDocumentation(root->doc,root->docFile,root->docLine); md->setDocumentation(root->doc,root->docFile,root->docLine);
md->setBriefDescription(root->brief,root->briefFile,root->briefLine); md->setBriefDescription(root->brief,root->briefFile,root->briefLine);
md->setInbodyDocumentation(root->inbodyDocs,root->inbodyFile,root->inbodyLine); md->setInbodyDocumentation(root->inbodyDocs,root->inbodyFile,root->inbodyLine);
...@@ -1937,8 +1916,15 @@ static void buildVarList(Entry *root) ...@@ -1937,8 +1916,15 @@ static void buildVarList(Entry *root)
cd=getClass(scope); cd=getClass(scope);
if (cd) if (cd)
{ {
addVariableToClass(root,cd,MemberDef::Friend,/*scope,*/ addVariableToClass(root, // entry
root->name,FALSE,/*0,*/0,Public); cd, // class to add member to
MemberDef::Friend, // type of member
root->name, // name of the member
FALSE, // from Anonymous scope
0, // anonymous member
Public, // protection
FALSE // related to a class
);
} }
} }
goto nextMember; goto nextMember;
...@@ -1968,6 +1954,17 @@ static void buildVarList(Entry *root) ...@@ -1968,6 +1954,17 @@ static void buildVarList(Entry *root)
classScope=stripTemplateSpecifiersFromScope(classScope,FALSE); classScope=stripTemplateSpecifiersFromScope(classScope,FALSE);
QCString annScopePrefix=scope.left(scope.length()-classScope.length()); QCString annScopePrefix=scope.left(scope.length()-classScope.length());
scope=classScope; scope=classScope;
bool isRelated=FALSE;
if (!root->relates.isEmpty()) // related variable
{
isRelated=TRUE;
if (getClass(root->relates)==0 && !scope.isEmpty())
scope=mergeScopes(scope,root->relates);
else
scope=root->relates.copy();
}
if (!scope.isEmpty() && !name.isEmpty() && (cd=getClass(scope))) if (!scope.isEmpty() && !name.isEmpty() && (cd=getClass(scope)))
{ {
// TODO: clean up this mess! // TODO: clean up this mess!
...@@ -1991,9 +1988,15 @@ static void buildVarList(Entry *root) ...@@ -1991,9 +1988,15 @@ static void buildVarList(Entry *root)
{ {
if (!pScope.isEmpty() && (pcd=getClass(pScope))) if (!pScope.isEmpty() && (pcd=getClass(pScope)))
{ {
//Protection p = (Protection)QMAX((int)root->protection,(int)cd->protection()); md=addVariableToClass(root, // entry
md=addVariableToClass(root,pcd,mtype,name, pcd, // class to add member to
TRUE,0,root->protection); mtype, // member type
name, // member name
TRUE, // from anonymous scope
0, // from anonymous member
root->protection,
isRelated
);
added=TRUE; added=TRUE;
} }
else // annonymous scope inside namespace or file => put variable in the global scope else // annonymous scope inside namespace or file => put variable in the global scope
...@@ -2008,8 +2011,14 @@ static void buildVarList(Entry *root) ...@@ -2008,8 +2011,14 @@ static void buildVarList(Entry *root)
// scope.right(scope.length()-si).data(), // scope.right(scope.length()-si).data(),
// indentDepth, // indentDepth,
// anonyScopes); // anonyScopes);
addVariableToClass(root,cd,mtype,name, addVariableToClass(root, // entry
FALSE,md,root->protection); cd, // class to add member to
mtype, // member type
name, // name of the member
FALSE, // from anonymous scope
md, // from anonymous member
root->protection,
isRelated);
} }
else if (!name.isEmpty()) // global variable else if (!name.isEmpty()) // global variable
{ {
...@@ -5452,17 +5461,18 @@ static void findEnums(Entry *root) ...@@ -5452,17 +5461,18 @@ static void findEnums(Entry *root)
ClassDef *cd=0; ClassDef *cd=0;
FileDef *fd=0; FileDef *fd=0;
NamespaceDef *nd=0; NamespaceDef *nd=0;
//MemberNameDict *mnd=0;
//MemberNameList *mnl=0;
MemberNameSDict *mnsd=0; MemberNameSDict *mnsd=0;
bool isGlobal; bool isGlobal;
//printf("Found enum with name `%s'\n",root->name.data()); bool isRelated=FALSE;
//printf("Found enum with name `%s' relates=%s\n",root->name.data(),root->relates.data());
int i; int i;
QCString name; QCString name;
QCString scope;
if ((i=root->name.findRev("::"))!=-1) // scope is specified if ((i=root->name.findRev("::"))!=-1) // scope is specified
{ {
QCString scope=root->name.left(i); // extract scope scope=root->name.left(i); // extract scope
name=root->name.right(root->name.length()-i-2); // extract name name=root->name.right(root->name.length()-i-2); // extract name
if ((cd=getClass(scope))==0) nd=getResolvedNamespace(scope); if ((cd=getClass(scope))==0) nd=getResolvedNamespace(scope);
} }
...@@ -5472,24 +5482,31 @@ static void findEnums(Entry *root) ...@@ -5472,24 +5482,31 @@ static void findEnums(Entry *root)
&& !root->parent->name.isEmpty() && !root->parent->name.isEmpty()
) // found enum docs inside a compound ) // found enum docs inside a compound
{ {
QCString scope=root->parent->name; scope=root->parent->name;
if ((cd=getClass(scope))==0) nd=getResolvedNamespace(scope); if ((cd=getClass(scope))==0) nd=getResolvedNamespace(scope);
} }
name=root->name.copy(); name=root->name.copy();
} }
if (!root->relates.isEmpty())
{ // related member, prefix user specified scope
isRelated=TRUE;
if (getClass(root->relates)==0 && !scope.isEmpty())
scope=mergeScopes(scope,root->relates);
else
scope=root->relates.copy();
if ((cd=getClass(scope))==0) nd=getResolvedNamespace(scope);
}
if (cd && !name.isEmpty()) // found a enum inside a compound if (cd && !name.isEmpty()) // found a enum inside a compound
{ {
//printf("Enum `%s'::`%s'\n",cd->name(),name.data()); //printf("Enum `%s'::`%s'\n",cd->name(),name.data());
fd=0; fd=0;
//mnd=&Doxygen::memberNameDict;
//mnl=&Doxygen::memberNameList;
mnsd=&Doxygen::memberNameSDict; mnsd=&Doxygen::memberNameSDict;
isGlobal=FALSE; isGlobal=FALSE;
} }
else if (nd && !nd->name().isEmpty() && nd->name().at(0)!='@') // found enum inside namespace else if (nd && !nd->name().isEmpty() && nd->name().at(0)!='@') // found enum inside namespace
{ {
//mnd=&Doxygen::functionNameDict;
//mnl=&Doxygen::functionNameList;
mnsd=&Doxygen::functionNameSDict; mnsd=&Doxygen::functionNameSDict;
isGlobal=TRUE; isGlobal=TRUE;
} }
...@@ -5497,26 +5514,24 @@ static void findEnums(Entry *root) ...@@ -5497,26 +5514,24 @@ static void findEnums(Entry *root)
{ {
bool ambig; bool ambig;
fd=findFileDef(Doxygen::inputNameDict,root->fileName,ambig); fd=findFileDef(Doxygen::inputNameDict,root->fileName,ambig);
//mnd=&Doxygen::functionNameDict;
//mnl=&Doxygen::functionNameList;
mnsd=&Doxygen::functionNameSDict; mnsd=&Doxygen::functionNameSDict;
isGlobal=TRUE; isGlobal=TRUE;
} }
if (!name.isEmpty()) if (!name.isEmpty())
{ {
// new enum type // new enum type
md = new MemberDef( md = new MemberDef(
root->fileName,root->startLine, root->fileName,root->startLine,
0,name,0,0,root->protection,Normal,FALSE,FALSE, 0,name,0,0,
MemberDef::Enumeration,0,0); root->protection,Normal,FALSE,isRelated,MemberDef::Enumeration,
0,0);
if (root->tagInfo) if (root->tagInfo)
{ {
md->setAnchor(root->tagInfo->anchor); md->setAnchor(root->tagInfo->anchor);
md->setReference(root->tagInfo->tagName); md->setReference(root->tagInfo->tagName);
} }
if (!isGlobal) md->setMemberClass(cd); else md->setFileDef(fd); if (!isGlobal) md->setMemberClass(cd); else md->setFileDef(fd);
//md->setDefFile(root->fileName);
//md->setDefLine(root->startLine);
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));
...@@ -5525,14 +5540,10 @@ static void findEnums(Entry *root) ...@@ -5525,14 +5540,10 @@ static void findEnums(Entry *root)
md->addSectionsToDefinition(root->anchors); md->addSectionsToDefinition(root->anchors);
md->setMemberGroupId(root->mGrpId); md->setMemberGroupId(root->mGrpId);
md->enableCallGraph(root->callGraph); md->enableCallGraph(root->callGraph);
//if (root->mGrpId!=-1)
//{
// md->setMemberGroup(memberGroupDict[root->mGrpId]);
//}
md->setRefItems(root->sli); md->setRefItems(root->sli);
if (nd && !nd->name().isEmpty() && nd->name().at(0)!='@') if (nd && !nd->name().isEmpty() && nd->name().at(0)!='@')
{ {
if (Config_getBool("HIDE_SCOPE_NAMES")) if (isRelated || Config_getBool("HIDE_SCOPE_NAMES"))
{ {
md->setDefinition(name); md->setDefinition(name);
} }
...@@ -5564,7 +5575,7 @@ static void findEnums(Entry *root) ...@@ -5564,7 +5575,7 @@ static void findEnums(Entry *root)
} }
else if (cd) else if (cd)
{ {
if (Config_getBool("HIDE_SCOPE_NAMES")) if (isRelated || Config_getBool("HIDE_SCOPE_NAMES"))
{ {
md->setDefinition(name); md->setDefinition(name);
} }
...@@ -5591,8 +5602,6 @@ static void findEnums(Entry *root) ...@@ -5591,8 +5602,6 @@ static void findEnums(Entry *root)
{ {
mn = new MemberName(name); mn = new MemberName(name);
mn->append(md); mn->append(md);
//mnd->insert(name,mn);
//mnl->append(mn);
mnsd->append(name,mn); mnsd->append(name,mn);
//printf("add %s to new memberName. Now %d members\n", //printf("add %s to new memberName. Now %d members\n",
// name.data(),mn->count()); // name.data(),mn->count());
...@@ -5603,8 +5612,10 @@ static void findEnums(Entry *root) ...@@ -5603,8 +5612,10 @@ static void findEnums(Entry *root)
Entry *e; Entry *e;
for (;(e=eli.current());++eli) for (;(e=eli.current());++eli)
{ {
//printf("e->name=%s isRelated=%d\n",e->name.data(),isRelated);
MemberName *fmn=0; MemberName *fmn=0;
if (!e->name.isEmpty() && (fmn=(*mnsd)[e->name])) MemberNameSDict *emnsd = isRelated ? &Doxygen::functionNameSDict : mnsd;
if (!e->name.isEmpty() && (fmn=(*emnsd)[e->name]))
// get list of members with the same name as the field // get list of members with the same name as the field
{ {
MemberNameIterator fmni(*fmn); MemberNameIterator fmni(*fmn);
...@@ -5613,6 +5624,7 @@ static void findEnums(Entry *root) ...@@ -5613,6 +5624,7 @@ static void findEnums(Entry *root)
{ {
if (fmd->isEnumValue()) if (fmd->isEnumValue())
{ {
//printf("found enum value with same name\n");
if (nd && !nd->name().isEmpty() && nd->name().at(0)!='@') if (nd && !nd->name().isEmpty() && nd->name().at(0)!='@')
{ {
NamespaceDef *fnd=fmd->getNamespaceDef(); NamespaceDef *fnd=fmd->getNamespaceDef();
...@@ -5631,6 +5643,16 @@ static void findEnums(Entry *root) ...@@ -5631,6 +5643,16 @@ static void findEnums(Entry *root)
fmd->setEnumScope(md); fmd->setEnumScope(md);
} }
} }
else if (isRelated && cd) // reparent enum value to
// match the enum's scope
{
md->insertEnumField(fmd); // add field def to list
fmd->setEnumScope(md); // cross ref with enum name
fmd->setEnumClassScope(cd); // cross ref with enum name
fmd->setOuterScope(cd);
fmd->makeRelated();
cd->insertMember(fmd);
}
else else
{ {
ClassDef *fcd=fmd->getClassDef(); ClassDef *fcd=fmd->getClassDef();
...@@ -8199,7 +8221,7 @@ void parseInput() ...@@ -8199,7 +8221,7 @@ void parseInput()
compoundKeywordDict.insert("exception",(void *)8); compoundKeywordDict.insert("exception",(void *)8);
bool alwaysRecursive = Config_getBool("RECURSIVE"); bool alwaysRecursive = Config_getBool("RECURSIVE");
/************************************************************************** /**************************************************************************
* Read and preprocess input * * Read and preprocess input *
**************************************************************************/ **************************************************************************/
......
...@@ -34,6 +34,11 @@ ...@@ -34,6 +34,11 @@
#include "searchindex.h" #include "searchindex.h"
//#include "xml.h" //#include "xml.h"
#if defined(_MSC_VER) || defined(__BORLANDC__)
#define popen _popen
#define pclose _pclose
#endif
class DevNullCodeDocInterface : public BaseCodeDocInterface class DevNullCodeDocInterface : public BaseCodeDocInterface
{ {
public: public:
...@@ -91,6 +96,7 @@ FileDef::FileDef(const char *p,const char *nm, ...@@ -91,6 +96,7 @@ FileDef::FileDef(const char *p,const char *nm,
} }
memberGroupSDict = new MemberGroupSDict; memberGroupSDict = new MemberGroupSDict;
memberGroupSDict->setAutoDelete(TRUE); memberGroupSDict->setAutoDelete(TRUE);
acquireFileVersion();
} }
/*! destroy the file definition */ /*! destroy the file definition */
...@@ -212,6 +218,12 @@ void FileDef::writeDocumentation(OutputList &ol) ...@@ -212,6 +218,12 @@ void FileDef::writeDocumentation(OutputList &ol)
//printf("WriteDocumentation diskname=%s\n",diskname.data()); //printf("WriteDocumentation diskname=%s\n",diskname.data());
QCString versionTitle;
if (!fileVersion.isEmpty())
{
versionTitle=("("+fileVersion+")");
}
QCString title = docname+versionTitle;
QCString pageTitle=theTranslator->trFileReference(docname); QCString pageTitle=theTranslator->trFileReference(docname);
startFile(ol,getOutputFileBase(),name(),pageTitle); startFile(ol,getOutputFileBase(),name(),pageTitle);
...@@ -228,14 +240,22 @@ void FileDef::writeDocumentation(OutputList &ol) ...@@ -228,14 +240,22 @@ void FileDef::writeDocumentation(OutputList &ol)
ol.parseText(pageTitle); // other output formats ol.parseText(pageTitle); // other output formats
ol.popGeneratorState(); ol.popGeneratorState();
addGroupListToTitle(ol,this); addGroupListToTitle(ol,this);
endTitle(ol,getOutputFileBase(),docname); endTitle(ol,getOutputFileBase(),title);
} }
else else
{ {
startTitle(ol,getOutputFileBase()); startTitle(ol,getOutputFileBase());
ol.parseText(pageTitle); ol.parseText(pageTitle);
addGroupListToTitle(ol,this); addGroupListToTitle(ol,this);
endTitle(ol,getOutputFileBase(),docname); endTitle(ol,getOutputFileBase(),title);
}
if (!fileVersion.isEmpty())
{
ol.disableAllBut(OutputGenerator::Html);
ol.startProjectNumber();
ol.docify(versionTitle);
ol.endProjectNumber();
ol.enableAll();
} }
if (Config_getBool("SEARCHENGINE")) if (Config_getBool("SEARCHENGINE"))
...@@ -519,7 +539,12 @@ void FileDef::writeDocumentation(OutputList &ol) ...@@ -519,7 +539,12 @@ void FileDef::writeDocumentation(OutputList &ol)
/*! Write a source listing of this file to the output */ /*! Write a source listing of this file to the output */
void FileDef::writeSource(OutputList &ol) void FileDef::writeSource(OutputList &ol)
{ {
QCString pageTitle = theTranslator->trSourceFile(docname); QCString title = docname;
if (!fileVersion.isEmpty())
{
title+=(" ("+fileVersion+")");
}
QCString pageTitle = theTranslator->trSourceFile(title);
ol.disableAllBut(OutputGenerator::Html); ol.disableAllBut(OutputGenerator::Html);
startFile(ol,getSourceFileBase(),0,pageTitle); startFile(ol,getSourceFileBase(),0,pageTitle);
...@@ -528,12 +553,12 @@ void FileDef::writeSource(OutputList &ol) ...@@ -528,12 +553,12 @@ void FileDef::writeSource(OutputList &ol)
getDirDef()->writeNavigationPath(ol); getDirDef()->writeNavigationPath(ol);
startTitle(ol,getOutputFileBase()); startTitle(ol,getOutputFileBase());
ol.parseText(name()); ol.parseText(name());
endTitle(ol,getOutputFileBase(),docname); endTitle(ol,getOutputFileBase(),title);
} }
else else
{ {
startTitle(ol,0); startTitle(ol,0);
ol.parseText(docname); ol.parseText(title);
endTitle(ol,0,0); endTitle(ol,0,0);
} }
...@@ -1116,3 +1141,33 @@ bool FileDef::isDocumentationFile() const ...@@ -1116,3 +1141,33 @@ bool FileDef::isDocumentationFile() const
name().right(4)==".txt" || name().right(4)==".txt" ||
name().right(4)==".dox"; name().right(4)==".dox";
} }
void FileDef::acquireFileVersion()
{
QCString vercmd = Config_getString("FILE_VERSION_FILTER");
if (!vercmd.isEmpty())
{
msg("Version of %s : ",filepath.data());
FILE *f=popen(vercmd+" "+filepath,"r");
if (!f)
{
err("Error: could not execute %s\n",vercmd.data());
return;
}
const int bufSize=1024;
char buf[bufSize];
int numRead = fread(buf,1,bufSize,f);
pclose(f);
if (numRead > 0)
{
fileVersion = QCString(buf,numRead).stripWhiteSpace();
msg("%s\n",fileVersion.data());
}
else
{
msg("no version available\n");
}
}
}
...@@ -109,6 +109,9 @@ class FileDef : public Definition ...@@ -109,6 +109,9 @@ class FileDef : public Definition
/*! Returns the absolute path of this file. */ /*! Returns the absolute path of this file. */
QCString getPath() const { return path; } QCString getPath() const { return path; }
/*! Returns version of this file. */
QCString getVersion() const { return fileVersion; }
bool isLinkableInProject() const bool isLinkableInProject() const
{ {
...@@ -187,6 +190,13 @@ class FileDef : public Definition ...@@ -187,6 +190,13 @@ class FileDef : public Definition
bool visited; bool visited;
protected:
/**
* Retrieves the file version from version control system.
*/
void acquireFileVersion();
private: private:
QDict<IncludeInfo> *includeDict; QDict<IncludeInfo> *includeDict;
...@@ -195,16 +205,15 @@ class FileDef : public Definition ...@@ -195,16 +205,15 @@ class FileDef : public Definition
QList<IncludeInfo> *includedByList; QList<IncludeInfo> *includedByList;
NamespaceSDict *usingDirList; NamespaceSDict *usingDirList;
SDict<Definition> *usingDeclList; SDict<Definition> *usingDeclList;
//DefineList *defineList;
QCString path; QCString path;
QCString filepath; QCString filepath;
QCString diskname; QCString diskname;
QCString filename; QCString filename;
QCString docname; QCString docname;
//QCString incName;
QIntDict<Definition> *srcDefDict; QIntDict<Definition> *srcDefDict;
QIntDict<MemberDef> *srcMemberDict; QIntDict<MemberDef> *srcMemberDict;
bool isSource; bool isSource;
QCString fileVersion;
PackageDef *package; PackageDef *package;
DirDef *dir; DirDef *dir;
......
...@@ -835,24 +835,24 @@ void HtmlDocVisitor::visitPost(DocSecRefList *) ...@@ -835,24 +835,24 @@ void HtmlDocVisitor::visitPost(DocSecRefList *)
m_t << "</multicol>" << endl; m_t << "</multicol>" << endl;
} }
void HtmlDocVisitor::visitPre(DocLanguage *l) //void HtmlDocVisitor::visitPre(DocLanguage *l)
{ //{
QString langId = Config_getEnum("OUTPUT_LANGUAGE"); // QString langId = Config_getEnum("OUTPUT_LANGUAGE");
if (l->id().lower()!=langId.lower()) // if (l->id().lower()!=langId.lower())
{ // {
pushEnabled(); // pushEnabled();
m_hide = TRUE; // m_hide = TRUE;
} // }
} //}
//
void HtmlDocVisitor::visitPost(DocLanguage *l) //void HtmlDocVisitor::visitPost(DocLanguage *l)
{ //{
QString langId = Config_getEnum("OUTPUT_LANGUAGE"); // QString langId = Config_getEnum("OUTPUT_LANGUAGE");
if (l->id().lower()!=langId.lower()) // if (l->id().lower()!=langId.lower())
{ // {
popEnabled(); // popEnabled();
} // }
} //}
void HtmlDocVisitor::visitPre(DocParamSect *s) void HtmlDocVisitor::visitPre(DocParamSect *s)
{ {
......
...@@ -111,8 +111,8 @@ class HtmlDocVisitor : public DocVisitor ...@@ -111,8 +111,8 @@ class HtmlDocVisitor : public DocVisitor
void visitPost(DocSecRefItem *); void visitPost(DocSecRefItem *);
void visitPre(DocSecRefList *); void visitPre(DocSecRefList *);
void visitPost(DocSecRefList *); void visitPost(DocSecRefList *);
void visitPre(DocLanguage *); //void visitPre(DocLanguage *);
void visitPost(DocLanguage *); //void visitPost(DocLanguage *);
void visitPre(DocParamSect *); void visitPre(DocParamSect *);
void visitPost(DocParamSect *); void visitPost(DocParamSect *);
void visitPre(DocParamList *); void visitPre(DocParamList *);
......
...@@ -46,7 +46,7 @@ static const char *defaultStyleSheet = ...@@ -46,7 +46,7 @@ static const char *defaultStyleSheet =
"BODY,H1,H2,H3,H4,H5,H6,P,CENTER,TD,TH,UL,DL,DIV {\n" "BODY,H1,H2,H3,H4,H5,H6,P,CENTER,TD,TH,UL,DL,DIV {\n"
" font-family: Geneva, Arial, Helvetica, sans-serif;\n" " font-family: Geneva, Arial, Helvetica, sans-serif;\n"
"}\n" "}\n"
"BODY {\n" "BODY,TD {\n"
" font-size: 90%;\n" " font-size: 90%;\n"
"}\n" "}\n"
"H1 {\n" "H1 {\n"
...@@ -136,6 +136,11 @@ static const char *defaultStyleSheet = ...@@ -136,6 +136,11 @@ static const char *defaultStyleSheet =
//"}\n" //"}\n"
"DIV.ah { background-color: black; font-weight: bold; color: #ffffff; margin-bottom: 3px; margin-top: 3px }\n" "DIV.ah { background-color: black; font-weight: bold; color: #ffffff; margin-bottom: 3px; margin-top: 3px }\n"
"TD.md { background-color: #F4F4FB; font-weight: bold; }\n" "TD.md { background-color: #F4F4FB; font-weight: bold; }\n"
"TD.mdPrefix {\n"
" background-color: #F4F4FB;\n"
" color: #606060;\n"
" font-size: 80%;\n"
"}\n"
"TD.mdname1 { background-color: #F4F4FB; font-weight: bold; color: #602020; }\n" "TD.mdname1 { background-color: #F4F4FB; font-weight: bold; color: #602020; }\n"
"TD.mdname { background-color: #F4F4FB; font-weight: bold; color: #602020; width: 600px; }\n" "TD.mdname { background-color: #F4F4FB; font-weight: bold; color: #602020; width: 600px; }\n"
"DIV.groupHeader {\n" "DIV.groupHeader {\n"
...@@ -1118,7 +1123,7 @@ void HtmlGenerator::startMemberDocPrefixItem() ...@@ -1118,7 +1123,7 @@ void HtmlGenerator::startMemberDocPrefixItem()
{ {
DBG_HTML(t << "<!-- startMemberDocPrefixItem -->" << endl;) DBG_HTML(t << "<!-- startMemberDocPrefixItem -->" << endl;)
t << " <tr>" << endl; t << " <tr>" << endl;
t << " <td class=\"md\" colspan=\"4\">" << endl; t << " <td class=\"mdPrefix\" colspan=\"4\">" << endl;
} }
void HtmlGenerator::endMemberDocPrefixItem() void HtmlGenerator::endMemberDocPrefixItem()
......
...@@ -841,24 +841,24 @@ void LatexDocVisitor::visitPost(DocSecRefList *) ...@@ -841,24 +841,24 @@ void LatexDocVisitor::visitPost(DocSecRefList *)
m_t << "\\normalsize" << endl; m_t << "\\normalsize" << endl;
} }
void LatexDocVisitor::visitPre(DocLanguage *l) //void LatexDocVisitor::visitPre(DocLanguage *l)
{ //{
QString langId = Config_getEnum("OUTPUT_LANGUAGE"); // QString langId = Config_getEnum("OUTPUT_LANGUAGE");
if (l->id().lower()!=langId.lower()) // if (l->id().lower()!=langId.lower())
{ // {
pushEnabled(); // pushEnabled();
m_hide = TRUE; // m_hide = TRUE;
} // }
} //}
//
void LatexDocVisitor::visitPost(DocLanguage *l) //void LatexDocVisitor::visitPost(DocLanguage *l)
{ //{
QString langId = Config_getEnum("OUTPUT_LANGUAGE"); // QString langId = Config_getEnum("OUTPUT_LANGUAGE");
if (l->id().lower()!=langId.lower()) // if (l->id().lower()!=langId.lower())
{ // {
popEnabled(); // popEnabled();
} // }
} //}
void LatexDocVisitor::visitPre(DocParamSect *s) void LatexDocVisitor::visitPre(DocParamSect *s)
{ {
......
...@@ -111,8 +111,8 @@ class LatexDocVisitor : public DocVisitor ...@@ -111,8 +111,8 @@ class LatexDocVisitor : public DocVisitor
void visitPost(DocSecRefItem *); void visitPost(DocSecRefItem *);
void visitPre(DocSecRefList *); void visitPre(DocSecRefList *);
void visitPost(DocSecRefList *); void visitPost(DocSecRefList *);
void visitPre(DocLanguage *); //void visitPre(DocLanguage *);
void visitPost(DocLanguage *); //void visitPost(DocLanguage *);
void visitPre(DocParamSect *); void visitPre(DocParamSect *);
void visitPost(DocParamSect *); void visitPost(DocParamSect *);
void visitPre(DocParamList *); void visitPre(DocParamList *);
......
...@@ -748,24 +748,24 @@ void ManDocVisitor::visitPost(DocSecRefList *) ...@@ -748,24 +748,24 @@ void ManDocVisitor::visitPost(DocSecRefList *)
m_t << ".PP" << endl; m_t << ".PP" << endl;
} }
void ManDocVisitor::visitPre(DocLanguage *l) //void ManDocVisitor::visitPre(DocLanguage *l)
{ //{
QString langId = Config_getEnum("OUTPUT_LANGUAGE"); // QString langId = Config_getEnum("OUTPUT_LANGUAGE");
if (l->id().lower()!=langId.lower()) // if (l->id().lower()!=langId.lower())
{ // {
pushEnabled(); // pushEnabled();
m_hide = TRUE; // m_hide = TRUE;
} // }
} //}
//
void ManDocVisitor::visitPost(DocLanguage *l) //void ManDocVisitor::visitPost(DocLanguage *l)
{ //{
QString langId = Config_getEnum("OUTPUT_LANGUAGE"); // QString langId = Config_getEnum("OUTPUT_LANGUAGE");
if (l->id().lower()!=langId.lower()) // if (l->id().lower()!=langId.lower())
{ // {
popEnabled(); // popEnabled();
} // }
} //}
void ManDocVisitor::visitPre(DocParamSect *s) void ManDocVisitor::visitPre(DocParamSect *s)
{ {
......
...@@ -111,8 +111,8 @@ class ManDocVisitor : public DocVisitor ...@@ -111,8 +111,8 @@ class ManDocVisitor : public DocVisitor
void visitPost(DocSecRefItem *); void visitPost(DocSecRefItem *);
void visitPre(DocSecRefList *); void visitPre(DocSecRefList *);
void visitPost(DocSecRefList *); void visitPost(DocSecRefList *);
void visitPre(DocLanguage *); //void visitPre(DocLanguage *);
void visitPost(DocLanguage *); //void visitPost(DocLanguage *);
void visitPre(DocParamSect *); void visitPre(DocParamSect *);
void visitPost(DocParamSect *); void visitPost(DocParamSect *);
void visitPre(DocParamList *); void visitPre(DocParamList *);
......
...@@ -605,12 +605,12 @@ bool MemberDef::isLinkableInProject() const ...@@ -605,12 +605,12 @@ bool MemberDef::isLinkableInProject() const
//printf("in a class but class not linkable!\n"); //printf("in a class but class not linkable!\n");
return FALSE; // in class but class not linkable return FALSE; // in class but class not linkable
} }
if (!group && nspace && !nspace->isLinkableInProject()) if (!group && nspace && !related && !nspace->isLinkableInProject())
{ {
//printf("in a namespace but namespace not linkable!\n"); //printf("in a namespace but namespace not linkable!\n");
return FALSE; // in namespace but namespace not linkable return FALSE; // in namespace but namespace not linkable
} }
if (!group && !nspace && fileDef && !fileDef->isLinkableInProject()) if (!group && !nspace && !related && fileDef && !fileDef->isLinkableInProject())
{ {
//printf("in a file but file not linkable!\n"); //printf("in a file but file not linkable!\n");
return FALSE; // in file (and not in namespace) but file not linkable return FALSE; // in file (and not in namespace) but file not linkable
...@@ -679,7 +679,7 @@ ClassDef *MemberDef::getClassDefOfAnonymousType() ...@@ -679,7 +679,7 @@ ClassDef *MemberDef::getClassDefOfAnonymousType()
} }
QCString ltype(type); QCString ltype(type);
// strip `static' keyword from ltype // strip `static' keyword from ltype
if (ltype.left(7)=="static ") ltype=ltype.right(ltype.length()-7); //if (ltype.left(7)=="static ") ltype=ltype.right(ltype.length()-7);
// strip `friend' keyword from ltype // strip `friend' keyword from ltype
if (ltype.left(7)=="friend ") ltype=ltype.right(ltype.length()-7); if (ltype.left(7)=="friend ") ltype=ltype.right(ltype.length()-7);
static QRegExp r("@[0-9]+"); static QRegExp r("@[0-9]+");
...@@ -927,7 +927,7 @@ void MemberDef::writeDeclaration(OutputList &ol, ...@@ -927,7 +927,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
QCString ltype(type); QCString ltype(type);
if (mtype==Typedef) ltype.prepend("typedef "); if (mtype==Typedef) ltype.prepend("typedef ");
// strip `static' keyword from ltype // strip `static' keyword from ltype
if (ltype.left(7)=="static ") ltype=ltype.right(ltype.length()-7); //if (ltype.left(7)=="static ") ltype=ltype.right(ltype.length()-7);
// strip `friend' keyword from ltype // strip `friend' keyword from ltype
if (ltype.left(7)=="friend ") ltype=ltype.right(ltype.length()-7); if (ltype.left(7)=="friend ") ltype=ltype.right(ltype.length()-7);
static QRegExp r("@[0-9]+"); static QRegExp r("@[0-9]+");
......
...@@ -213,11 +213,8 @@ class MemberDef : public Definition ...@@ -213,11 +213,8 @@ class MemberDef : public Definition
// enumeration specific members // enumeration specific members
void insertEnumField(MemberDef *md); void insertEnumField(MemberDef *md);
void setEnumScope(MemberDef *md); void setEnumScope(MemberDef *md);
void setEnumClassScope(ClassDef *cd) { classDef = cd; }
MemberDef *getEnumScope() const { return enumScope; } MemberDef *getEnumScope() const { return enumScope; }
//void setEnumUsed() { eUsed=TRUE; }
//bool enumUsed() const { return eUsed; }
//void setEnumDecl(OutputList &ed);
//OutputList *enumDecl() const { return enumDeclList; }
MemberList *enumFieldList() const { return enumFields; } MemberList *enumFieldList() const { return enumFields; }
void setDocumentedEnumValues(bool value) { docEnumValues=value; } void setDocumentedEnumValues(bool value) { docEnumValues=value; }
bool hasDocumentedEnumValues() const { return docEnumValues; } bool hasDocumentedEnumValues() const { return docEnumValues; }
......
...@@ -228,7 +228,6 @@ void MemberList::writePlainDeclarations(OutputList &ol, ...@@ -228,7 +228,6 @@ void MemberList::writePlainDeclarations(OutputList &ol,
ol.startMemberItem(0); ol.startMemberItem(0);
ol.writeString("enum "); ol.writeString("enum ");
ol.insertMemberAlign(); ol.insertMemberAlign();
//ol+=typeDecl; // append the enum values.
md->writeEnumDeclaration(ol,cd,nd,fd,gd); md->writeEnumDeclaration(ol,cd,nd,fd,gd);
ol.endMemberItem(); ol.endMemberItem();
if (!md->briefDescription().isEmpty() && Config_getBool("BRIEF_MEMBER_DESC")) if (!md->briefDescription().isEmpty() && Config_getBool("BRIEF_MEMBER_DESC"))
......
...@@ -24,66 +24,68 @@ ...@@ -24,66 +24,68 @@
#include "doxygen.h" #include "doxygen.h"
static QCString outputFormat; static QCString outputFormat;
static int warnFormatOrder; // 1 = $file,$line,$text //static int warnFormatOrder; // 1 = $file,$line,$text
// 2 = $text,$line,$file // // 2 = $text,$line,$file
// 3 = $line,$text,$file // // 3 = $line,$text,$file
// 4 = $file,$text,$line // // 4 = $file,$text,$line
// 5 = $text,$file,$line // // 5 = $text,$file,$line
// 6 = $line,$file,$text // // 6 = $line,$file,$text
static FILE *warnFile = stderr; static FILE *warnFile = stderr;
void initWarningFormat() void initWarningFormat()
{ {
int filePos = Config_getString("WARN_FORMAT").find("$file"); // int filePos = Config_getString("WARN_FORMAT").find("$file");
int linePos = Config_getString("WARN_FORMAT").find("$line"); // int linePos = Config_getString("WARN_FORMAT").find("$line");
int textPos = Config_getString("WARN_FORMAT").find("$text"); // int textPos = Config_getString("WARN_FORMAT").find("$text");
//
// sort items on position (there are 6 cases) // // sort items on position (there are 6 cases)
warnFormatOrder = 1; // warnFormatOrder = 1;
if (filePos>linePos && filePos>textPos) // if (filePos>linePos && filePos>textPos)
{ // {
if (linePos>textPos) // $text,$line,$file // if (linePos>textPos) // $text,$line,$file
{ // {
warnFormatOrder = 2; // warnFormatOrder = 2;
} // }
else // $line,$text,$file // else // $line,$text,$file
{ // {
warnFormatOrder = 3; // warnFormatOrder = 3;
} // }
} // }
else if (filePos<linePos && filePos<textPos) // else if (filePos<linePos && filePos<textPos)
{ // {
if (linePos>textPos) // $file,$text,$line // if (linePos>textPos) // $file,$text,$line
{ // {
warnFormatOrder = 4; // warnFormatOrder = 4;
} // }
} // }
else if (filePos<linePos && filePos>textPos) // $text,$file,$line // else if (filePos<linePos && filePos>textPos) // $text,$file,$line
{ // {
warnFormatOrder = 5; // warnFormatOrder = 5;
} // }
else // $line,$file,$text // else // $line,$file,$text
{ // {
warnFormatOrder = 6; // warnFormatOrder = 6;
} // }
outputFormat = // outputFormat =
substitute( // substitute(
substitute( // substitute(
substitute( // substitute(
Config_getString("WARN_FORMAT"), // Config_getString("WARN_FORMAT"),
"$file","%s" // "$file","%s"
), // ),
"$text","%s" // "$text","%s"
), // ),
"$line","%d" // "$line","%d"
)+'\n'; // )+'\n';
// replace(QRegExp("\\$file"),"%s"). // replace(QRegExp("\\$file"),"%s").
// replace(QRegExp("\\$text"),"%s"). // replace(QRegExp("\\$text"),"%s").
// replace(QRegExp("\\$line"),"%d")+ // replace(QRegExp("\\$line"),"%d")+
// '\n'; // '\n';
outputFormat = Config_getString("WARN_FORMAT");
if (!Config_getString("WARN_LOGFILE").isEmpty()) if (!Config_getString("WARN_LOGFILE").isEmpty())
{ {
warnFile = fopen(Config_getString("WARN_LOGFILE"),"w"); warnFile = fopen(Config_getString("WARN_LOGFILE"),"w");
...@@ -115,18 +117,48 @@ static void do_warn(const char *tag, const char *file, int line, const char *fmt ...@@ -115,18 +117,48 @@ static void do_warn(const char *tag, const char *file, int line, const char *fmt
if (!Config_getBool(tag)) return; // warning type disabled if (!Config_getBool(tag)) return; // warning type disabled
char text[40960]; char text[40960];
vsprintf(text, fmt, args); vsprintf(text, fmt, args);
if (file==0) file="<unknown>"; QCString fileSubst = file==0 ? "<unknown>" : file;
switch(warnFormatOrder) QCString lineSubst; lineSubst.setNum(line);
QCString textSubst = text;
QCString versionSubst;
if (file) // get version from file name
{ {
case 1: fprintf(warnFile,outputFormat,file,line,text); break; bool ambig;
case 2: fprintf(warnFile,outputFormat,text,line,file); break; FileDef *fd=findFileDef(Doxygen::inputNameDict,file,ambig);
case 3: fprintf(warnFile,outputFormat,line,text,file); break; if (fd)
case 4: fprintf(warnFile,outputFormat,file,text,line); break; {
case 5: fprintf(warnFile,outputFormat,text,file,line); break; versionSubst = fd->getVersion();
case 6: fprintf(warnFile,outputFormat,line,file,text); break; }
default:
printf("Error: warning format has not been initialized!\n");
} }
// substitute markers by actual values
QCString msgText =
substitute(
substitute(
substitute(
substitute(
outputFormat,
"$file",fileSubst
),
"$text",textSubst
),
"$line",lineSubst
),
"$version",versionSubst
)+'\n';
// print resulting message
fprintf(warnFile,msgText);
// switch(warnFormatOrder)
// {
// case 1: fprintf(warnFile,outputFormat,file,line,text); break;
// case 2: fprintf(warnFile,outputFormat,text,line,file); break;
// case 3: fprintf(warnFile,outputFormat,line,text,file); break;
// case 4: fprintf(warnFile,outputFormat,file,text,line); break;
// case 5: fprintf(warnFile,outputFormat,text,file,line); break;
// case 6: fprintf(warnFile,outputFormat,line,file,text); break;
// default:
// printf("Error: warning format has not been initialized!\n");
// }
} }
void warn(const char *file,int line,const char *fmt, ...) void warn(const char *file,int line,const char *fmt, ...)
......
...@@ -367,8 +367,8 @@ public: ...@@ -367,8 +367,8 @@ public:
void visitPost(DocSecRefItem *); void visitPost(DocSecRefItem *);
void visitPre(DocSecRefList *); void visitPre(DocSecRefList *);
void visitPost(DocSecRefList *); void visitPost(DocSecRefList *);
void visitPre(DocLanguage *); //void visitPre(DocLanguage *);
void visitPost(DocLanguage *); //void visitPost(DocLanguage *);
void visitPre(DocParamSect *); void visitPre(DocParamSect *);
void visitPost(DocParamSect *); void visitPost(DocParamSect *);
void visitPre(DocParamList *); void visitPre(DocParamList *);
...@@ -1126,16 +1126,16 @@ void PerlModDocVisitor::visitPost(DocSecRefList *) ...@@ -1126,16 +1126,16 @@ void PerlModDocVisitor::visitPost(DocSecRefList *)
#endif #endif
} }
void PerlModDocVisitor::visitPre(DocLanguage *l) //void PerlModDocVisitor::visitPre(DocLanguage *l)
{ //{
openItem("language"); // openItem("language");
m_output.addFieldQuotedString("id", l->id()); // m_output.addFieldQuotedString("id", l->id());
} //}
//
void PerlModDocVisitor::visitPost(DocLanguage *) //void PerlModDocVisitor::visitPost(DocLanguage *)
{ //{
closeItem(); // closeItem();
} //}
void PerlModDocVisitor::visitPre(DocParamSect *s) void PerlModDocVisitor::visitPre(DocParamSect *s)
{ {
......
...@@ -534,16 +534,16 @@ class PrintDocVisitor : public DocVisitor ...@@ -534,16 +534,16 @@ class PrintDocVisitor : public DocVisitor
indent_post(); indent_post();
printf("</secreflist>\n"); printf("</secreflist>\n");
} }
void visitPre(DocLanguage *l) //void visitPre(DocLanguage *l)
{ //{
indent_pre(); // indent_pre();
printf("<language id=%s>\n",l->id().data()); // printf("<language id=%s>\n",l->id().data());
} //}
void visitPost(DocLanguage *) //void visitPost(DocLanguage *)
{ //{
indent_post(); // indent_post();
printf("</language>\n"); // printf("</language>\n");
} //}
void visitPre(DocParamList *pl) void visitPre(DocParamList *pl)
{ {
indent_pre(); indent_pre();
......
...@@ -1088,26 +1088,26 @@ void RTFDocVisitor::visitPost(DocSecRefList *) ...@@ -1088,26 +1088,26 @@ void RTFDocVisitor::visitPost(DocSecRefList *)
m_lastIsPara=TRUE; m_lastIsPara=TRUE;
} }
void RTFDocVisitor::visitPre(DocLanguage *l) //void RTFDocVisitor::visitPre(DocLanguage *l)
{ //{
DBG_RTF("{\\comment RTFDocVisitor::visitPre(DocLanguage)}\n"); // DBG_RTF("{\\comment RTFDocVisitor::visitPre(DocLanguage)}\n");
QString langId = Config_getEnum("OUTPUT_LANGUAGE"); // QString langId = Config_getEnum("OUTPUT_LANGUAGE");
if (l->id().lower()!=langId.lower()) // if (l->id().lower()!=langId.lower())
{ // {
pushEnabled(); // pushEnabled();
m_hide = TRUE; // m_hide = TRUE;
} // }
} //}
//
void RTFDocVisitor::visitPost(DocLanguage *l) //void RTFDocVisitor::visitPost(DocLanguage *l)
{ //{
DBG_RTF("{\\comment RTFDocVisitor::visitPost(DocLanguage)}\n"); // DBG_RTF("{\\comment RTFDocVisitor::visitPost(DocLanguage)}\n");
QString langId = Config_getEnum("OUTPUT_LANGUAGE"); // QString langId = Config_getEnum("OUTPUT_LANGUAGE");
if (l->id().lower()!=langId.lower()) // if (l->id().lower()!=langId.lower())
{ // {
popEnabled(); // popEnabled();
} // }
} //}
void RTFDocVisitor::visitPre(DocParamSect *s) void RTFDocVisitor::visitPre(DocParamSect *s)
{ {
......
...@@ -111,8 +111,8 @@ class RTFDocVisitor : public DocVisitor ...@@ -111,8 +111,8 @@ class RTFDocVisitor : public DocVisitor
void visitPost(DocSecRefItem *); void visitPost(DocSecRefItem *);
void visitPre(DocSecRefList *); void visitPre(DocSecRefList *);
void visitPost(DocSecRefList *); void visitPost(DocSecRefList *);
void visitPre(DocLanguage *); //void visitPre(DocLanguage *);
void visitPost(DocLanguage *); //void visitPost(DocLanguage *);
void visitPre(DocParamSect *); void visitPre(DocParamSect *);
void visitPost(DocParamSect *); void visitPost(DocParamSect *);
void visitPre(DocParamList *); void visitPre(DocParamList *);
......
...@@ -84,6 +84,7 @@ static int lastPreLineCtrlContext; ...@@ -84,6 +84,7 @@ static int lastPreLineCtrlContext;
static int lastSkipVerbStringContext; static int lastSkipVerbStringContext;
static int lastCommentInArgContext; static int lastCommentInArgContext;
static int lastFileDocContext; static int lastFileDocContext;
static int lastSectionContext;
static int nextDefContext; static int nextDefContext;
static int overloadContext; static int overloadContext;
static Protection protection; static Protection protection;
...@@ -672,6 +673,7 @@ DL [dD][lL] ...@@ -672,6 +673,7 @@ DL [dD][lL]
TITLE [tT][iI][tT][lL][eE] TITLE [tT][iI][tT][lL][eE]
CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'")) CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^' \\\n]{1,4}"'"))
PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
IDLATTR ("["[^\]]*"]"){BN}*
%option noyywrap %option noyywrap
...@@ -828,6 +830,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -828,6 +830,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
%x ObjCProtocolList %x ObjCProtocolList
%x QtPropType %x QtPropType
%x QtPropName %x QtPropName
%x QtPropAttr
%x QtPropRead %x QtPropRead
%x QtPropWrite %x QtPropWrite
...@@ -1189,7 +1192,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -1189,7 +1192,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
<PackageName>";" { <PackageName>";" {
BEGIN(FindMembers); BEGIN(FindMembers);
} }
<FindMembers>{B}*"static"{BN}+ { //current->type += " static "; <FindMembers>{B}*"static"{BN}+ { current->type += " static ";
current->stat = TRUE; current->stat = TRUE;
lineCount(); lineCount();
} }
...@@ -1410,8 +1413,8 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -1410,8 +1413,8 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
if (yytext[yyleng-1]=='{') unput('{'); if (yytext[yyleng-1]=='{') unput('{');
BEGIN( CompoundName ) ; BEGIN( CompoundName ) ;
} }
<FindMembers>{B}*(("typedef"{BN}+)?)"enum{" | <FindMembers>{B}*(("typedef"{BN}+)?){IDLATTR}?"enum{" |
<FindMembers>{B}*(("typedef"{BN}+)?)"enum"{BN}+ { <FindMembers>{B}*(("typedef"{BN}+)?){IDLATTR}?"enum"{BN}+ { // for IDL: typedef [something] enum
isTypedef=((QCString)yytext).find("typedef")!=-1; isTypedef=((QCString)yytext).find("typedef")!=-1;
current->section = Entry::ENUM_SEC ; current->section = Entry::ENUM_SEC ;
addType( current ) ; addType( current ) ;
...@@ -1649,28 +1652,41 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -1649,28 +1652,41 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
current->mtype = mtype = Property; current->mtype = mtype = Property;
BEGIN(QtPropType); BEGIN(QtPropType);
} }
<QtPropType>"(" { // start of property arguments
}
<QtPropAttr>")" { // end of property arguments
unput(';');
BEGIN(FindMembers);
}
<QtPropType>{ID} { <QtPropType>{ID} {
current->type=yytext; current->type=yytext;
BEGIN(QtPropName); BEGIN(QtPropName);
} }
<QtPropName>{ID} { <QtPropName>{ID} {
current->name=yytext; current->name=yytext;
BEGIN(QtPropRead); BEGIN(QtPropAttr);
} }
<QtPropRead>"READ" { <QtPropAttr>"READ" {
current->memSpec |= Entry::Readable; current->memSpec |= Entry::Readable;
BEGIN(QtPropRead);
}
<QtPropAttr>"WRITE" {
current->memSpec |= Entry::Writable;
BEGIN(QtPropWrite);
}
<QtPropAttr>"RESET"{B}+{ID} { // reset method => not supported yet
}
<QtPropAttr>"SCRIPTABLE"{B}+{ID} { // scriptable property => not supported yet
}
<QtPropAttr>"DESIGNABLE"{B}+{ID} { // designable property => not supported yet
} }
<QtPropRead>{ID} { <QtPropRead>{ID} {
current->read = yytext; current->read = yytext;
BEGIN(QtPropWrite); BEGIN(QtPropAttr);
}
<QtPropWrite>"WRITE" {
current->memSpec |= Entry::Writable;
} }
<QtPropWrite>{ID} { <QtPropWrite>{ID} {
current->write = yytext; current->write = yytext;
unput(';'); BEGIN(QtPropAttr);
BEGIN(FindMembers);
} }
<FindMembers>"friend"{BN}+("class"|"union"|"struct"){BN}+ { <FindMembers>"friend"{BN}+("class"|"union"|"struct"){BN}+ {
current->name=yytext; current->name=yytext;
...@@ -4745,21 +4761,25 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -4745,21 +4761,25 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
<ClassDoc,PageDoc,Doc,JavaDoc>{CMD}"section"{B}+ { <ClassDoc,PageDoc,Doc,JavaDoc>{CMD}"section"{B}+ {
//sectionType=SectionInfo::Section; //sectionType=SectionInfo::Section;
current->doc+=yytext; current->doc+=yytext;
lastSectionContext=YY_START;
BEGIN(SectionLabel); BEGIN(SectionLabel);
} }
<ClassDoc,PageDoc,Doc,JavaDoc>{CMD}"subsection"{B}+ { <ClassDoc,PageDoc,Doc,JavaDoc>{CMD}"subsection"{B}+ {
//sectionType=SectionInfo::Subsection; //sectionType=SectionInfo::Subsection;
current->doc+=yytext; current->doc+=yytext;
lastSectionContext=YY_START;
BEGIN(SectionLabel); BEGIN(SectionLabel);
} }
<ClassDoc,PageDoc,Doc,JavaDoc>{CMD}"subsubsection"{B}+ { <ClassDoc,PageDoc,Doc,JavaDoc>{CMD}"subsubsection"{B}+ {
//sectionType=SectionInfo::Subsubsection; //sectionType=SectionInfo::Subsubsection;
current->doc+=yytext; current->doc+=yytext;
lastSectionContext=YY_START;
BEGIN(SectionLabel); BEGIN(SectionLabel);
} }
<ClassDoc,PageDoc,Doc,JavaDoc>{CMD}"paragraph"{B}+ { <ClassDoc,PageDoc,Doc,JavaDoc>{CMD}"paragraph"{B}+ {
//sectionType=SectionInfo::Paragraph; //sectionType=SectionInfo::Paragraph;
current->doc+=yytext; current->doc+=yytext;
lastSectionContext=YY_START;
BEGIN(SectionLabel); BEGIN(SectionLabel);
} }
<GroupHeader>. { memberGroupHeader+=*yytext; } <GroupHeader>. { memberGroupHeader+=*yytext; }
...@@ -5011,7 +5031,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -5011,7 +5031,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
current->anchors->append(si); current->anchors->append(si);
Doxygen::sectionDict.insert(yytext,si); Doxygen::sectionDict.insert(yytext,si);
current->doc+=yytext; current->doc+=yytext;
BEGIN(PageDoc); BEGIN(lastSectionContext);
} }
<SectionTitle>[^\n*]* { <SectionTitle>[^\n*]* {
sectionTitle+=yytext; sectionTitle+=yytext;
...@@ -5356,7 +5376,8 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -5356,7 +5376,8 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
); );
} }
<DocBaseClass>\n { yyLineNr++; BEGIN( ClassDoc ); } <DocBaseClass>\n { yyLineNr++; BEGIN( ClassDoc ); }
<ClassDocBrief>{BS}({BL}|"\\n\\n") { <ClassDocBrief>{BS}({BL}|"\\n\\n") |
<ClassDocBrief>("\\_linebr \\_linebr") {
//if (!current->doc.isEmpty()) current->doc+=" <p>"; //if (!current->doc.isEmpty()) current->doc+=" <p>";
if (lastBriefContext==TodoParam || if (lastBriefContext==TodoParam ||
lastBriefContext==TestParam || lastBriefContext==TestParam ||
...@@ -5444,6 +5465,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -5444,6 +5465,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
<ClassDocBrief>{BS}{CMD}("brief"|"short"){BN}+ { <ClassDocBrief>{BS}{CMD}("brief"|"short"){BN}+ {
//lastBriefContext=YY_START; //lastBriefContext=YY_START;
} }
<ClassDocBrief>{ID} { current->brief += yytext; }
<ClassDocBrief>. { current->brief += *yytext; } <ClassDocBrief>. { current->brief += *yytext; }
<ClassDocDefine>{ID}/"(" { <ClassDocDefine>{ID}/"(" {
current->name = yytext; current->name = yytext;
...@@ -5577,6 +5599,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -5577,6 +5599,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
yyLineNr++; yyLineNr++;
BEGIN(AfterDoc); BEGIN(AfterDoc);
} }
<AfterDocLine>{ID} { current->brief+=yytext; }
<AfterDocLine>. { current->brief+=yytext; } <AfterDocLine>. { current->brief+=yytext; }
<AfterDocBrief>{BS}({BL}|"\\n\\n") { <AfterDocBrief>{BS}({BL}|"\\n\\n") {
current->brief=current->brief.stripWhiteSpace(); current->brief=current->brief.stripWhiteSpace();
...@@ -5707,7 +5730,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;] ...@@ -5707,7 +5730,7 @@ PHPKW ("require"|"require_once"|"include"|"include_once"|"echo")[^a-zA-Z0-9_;]
} }
<Doc,JavaDoc,LineDoc,ClassDocBrief,AfterDocBrief,AfterDocLine,CopyArgCommentLine,ClassDoc,PageDoc,AfterDoc,CopyArgComment,DocInternal,DocInternalLine>"\\_linebr " { <Doc,JavaDoc,LineDoc,ClassDocBrief,AfterDocBrief,AfterDocLine,CopyArgCommentLine,ClassDoc,PageDoc,AfterDoc,CopyArgComment,DocInternal,DocInternalLine>"\\_linebr " {
// used to compensate for misalignments due to \n's inside ALIASES // used to compensate for misalignments due to \n's inside ALIASES
current->doc += '\n'; current->doc += '\n';
} }
<Doc,JavaDoc,ClassDoc,PageDoc,ReadFormulaShort,ReadFormulaLong,AfterDoc>^{B}*(("//"{B}*)?)"*"+[ \t]*"-"("#")?{B}+ { <Doc,JavaDoc,ClassDoc,PageDoc,ReadFormulaShort,ReadFormulaLong,AfterDoc>^{B}*(("//"{B}*)?)"*"+[ \t]*"-"("#")?{B}+ {
current->doc += yytext; current->doc += yytext;
......
...@@ -711,17 +711,17 @@ void XmlDocVisitor::visitPost(DocSecRefList *) ...@@ -711,17 +711,17 @@ void XmlDocVisitor::visitPost(DocSecRefList *)
m_t << "</toclist>" << endl; m_t << "</toclist>" << endl;
} }
void XmlDocVisitor::visitPre(DocLanguage *l) //void XmlDocVisitor::visitPre(DocLanguage *l)
{ //{
if (m_hide) return; // if (m_hide) return;
m_t << "<language langid=\"" << l->id() << "\">"; // m_t << "<language langid=\"" << l->id() << "\">";
} //}
//
void XmlDocVisitor::visitPost(DocLanguage *) //void XmlDocVisitor::visitPost(DocLanguage *)
{ //{
if (m_hide) return; // if (m_hide) return;
m_t << "</language>" << endl; // m_t << "</language>" << endl;
} //}
void XmlDocVisitor::visitPre(DocParamSect *s) void XmlDocVisitor::visitPre(DocParamSect *s)
{ {
......
...@@ -111,8 +111,8 @@ class XmlDocVisitor : public DocVisitor ...@@ -111,8 +111,8 @@ class XmlDocVisitor : public DocVisitor
void visitPost(DocSecRefItem *); void visitPost(DocSecRefItem *);
void visitPre(DocSecRefList *); void visitPre(DocSecRefList *);
void visitPost(DocSecRefList *); void visitPost(DocSecRefList *);
void visitPre(DocLanguage *); //void visitPre(DocLanguage *);
void visitPost(DocLanguage *); //void visitPost(DocLanguage *);
void visitPre(DocParamSect *); void visitPre(DocParamSect *);
void visitPost(DocParamSect *); void visitPost(DocParamSect *);
void visitPre(DocParamList *); void visitPre(DocParamList *);
......
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