summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--INSTALL4
-rw-r--r--Makefile.in16
-rw-r--r--Makefile.win_make.in5
-rw-r--r--Makefile.win_nmake.in5
-rw-r--r--README4
-rw-r--r--VERSION2
-rw-r--r--addon/configgen/Makefile.in42
-rw-r--r--addon/configgen/README13
-rw-r--r--addon/configgen/config_templ.h42
-rw-r--r--addon/configgen/config_templ.l1004
-rw-r--r--addon/configgen/configgen.cpp1887
-rw-r--r--addon/configgen/configgen.pro.in20
-rw-r--r--addon/doxywizard/Makefile.in32
-rw-r--r--addon/doxywizard/doxywizard.cpp540
-rw-r--r--addon/doxywizard/doxywizard.h111
-rw-r--r--addon/doxywizard/doxywizard.pro.in7
-rw-r--r--addon/doxywizard/input.h14
-rw-r--r--addon/doxywizard/inputbool.cpp8
-rw-r--r--addon/doxywizard/inputbool.h10
-rw-r--r--addon/doxywizard/inputint.cpp2
-rw-r--r--addon/doxywizard/inputint.h7
-rw-r--r--addon/doxywizard/inputstring.cpp2
-rw-r--r--addon/doxywizard/inputstring.h8
-rw-r--r--addon/doxywizard/inputstrlist.cpp2
-rw-r--r--addon/doxywizard/inputstrlist.h7
-rw-r--r--addon/doxywizard/pagewidget.cpp2
-rw-r--r--addon/doxywizard/pagewidget.h2
-rw-r--r--addon/doxywizard/pixmaps.cpp2
-rw-r--r--addon/doxywizard/pixmaps.h2
-rw-r--r--addon/doxywizard/qtbc.h (renamed from addon/configgen/qtbc.h)6
-rw-r--r--addon/xmlgen/xml.cpp34
-rw-r--r--addon/xmlgen/xmlgen.pro.in12
-rw-r--r--addon/xmlread/qtbc.h2
-rwxr-xr-xconfigure17
-rw-r--r--doc/commands.doc17
-rw-r--r--doc/htmlcmds.doc7
-rw-r--r--packages/rpm/doxygen.spec2
-rw-r--r--qtools/Makefile.in2
-rw-r--r--qtools/qarray.h2
-rw-r--r--qtools/qasciidict.h2
-rw-r--r--qtools/qbuffer.cpp2
-rw-r--r--qtools/qbuffer.h2
-rw-r--r--qtools/qcollection.cpp2
-rw-r--r--qtools/qcollection.h2
-rw-r--r--qtools/qcstring.cpp2
-rw-r--r--qtools/qcstring.h2
-rw-r--r--qtools/qdatastream.cpp2
-rw-r--r--qtools/qdatastream.h2
-rw-r--r--qtools/qdatetime.cpp2
-rw-r--r--qtools/qdatetime.h2
-rw-r--r--qtools/qdict.h2
-rw-r--r--qtools/qdir.cpp2
-rw-r--r--qtools/qdir.h2
-rw-r--r--qtools/qdir_unix.cpp2
-rw-r--r--qtools/qdir_win32.cpp2
-rw-r--r--qtools/qfeatures.h2
-rw-r--r--qtools/qfile.cpp2
-rw-r--r--qtools/qfile.h2
-rw-r--r--qtools/qfile_unix.cpp2
-rw-r--r--qtools/qfile_win32.cpp2
-rw-r--r--qtools/qfiledefs_p.h2
-rw-r--r--qtools/qfileinfo.cpp2
-rw-r--r--qtools/qfileinfo.h2
-rw-r--r--qtools/qfileinfo_unix.cpp2
-rw-r--r--qtools/qfileinfo_win32.cpp2
-rw-r--r--qtools/qgarray.cpp2
-rw-r--r--qtools/qgarray.h2
-rw-r--r--qtools/qgdict.cpp2
-rw-r--r--qtools/qgdict.h2
-rw-r--r--qtools/qgeneric.h2
-rw-r--r--qtools/qglist.cpp2
-rw-r--r--qtools/qglist.h2
-rw-r--r--qtools/qglobal.cpp2
-rw-r--r--qtools/qglobal.h2
-rw-r--r--qtools/qgvector.cpp2
-rw-r--r--qtools/qgvector.h2
-rw-r--r--qtools/qintdict.h2
-rw-r--r--qtools/qiodevice.cpp2
-rw-r--r--qtools/qiodevice.h2
-rw-r--r--qtools/qlist.h2
-rw-r--r--qtools/qmap.cpp2
-rw-r--r--qtools/qmap.h2
-rw-r--r--qtools/qptrdict.h2
-rw-r--r--qtools/qqueue.h2
-rw-r--r--qtools/qregexp.cpp2
-rw-r--r--qtools/qregexp.h2
-rw-r--r--qtools/qshared.h2
-rw-r--r--qtools/qsortedlist.h2
-rw-r--r--qtools/qstack.h2
-rw-r--r--qtools/qstring.cpp2
-rw-r--r--qtools/qstring.h2
-rw-r--r--qtools/qstringlist.cpp2
-rw-r--r--qtools/qstringlist.h2
-rw-r--r--qtools/qstrlist.h2
-rw-r--r--qtools/qstrvec.h2
-rw-r--r--qtools/qtextcodec.cpp2
-rw-r--r--qtools/qtextcodec.h2
-rw-r--r--qtools/qtextstream.cpp2
-rw-r--r--qtools/qtextstream.h2
-rw-r--r--qtools/qtl.h2
-rw-r--r--qtools/qvaluelist.h2
-rw-r--r--qtools/qvaluestack.h2
-rw-r--r--qtools/qvector.h2
-rw-r--r--qtools/qxml.cpp2
-rw-r--r--qtools/qxml.h2
-rw-r--r--src/Makefile.in8
-rw-r--r--src/classdef.cpp96
-rw-r--r--src/classlist.cpp12
-rw-r--r--src/code.l22
-rw-r--r--src/config.h571
-rw-r--r--src/config.l3611
-rw-r--r--src/define.cpp2
-rw-r--r--src/definition.cpp14
-rw-r--r--src/diagram.cpp4
-rw-r--r--src/doc.l55
-rw-r--r--src/dot.cpp44
-rw-r--r--src/doxygen.cpp522
-rw-r--r--src/doxygen.pro.in12
-rw-r--r--src/filedef.cpp52
-rw-r--r--src/filedef.h2
-rw-r--r--src/filename.cpp2
-rw-r--r--src/filename.h2
-rw-r--r--src/formula.cpp6
-rw-r--r--src/ftvhelp.cpp24
-rw-r--r--src/groupdef.cpp44
-rw-r--r--src/htmlgen.cpp89
-rw-r--r--src/htmlgen.h2
-rw-r--r--src/htmlhelp.cpp18
-rw-r--r--src/index.cpp196
-rw-r--r--src/instdox.cpp8
-rw-r--r--src/language.cpp5
-rw-r--r--src/latexgen.cpp187
-rw-r--r--src/latexgen.h2
-rw-r--r--src/libdoxycfg.pro.in26
-rw-r--r--src/libdoxycfg.t49
-rw-r--r--src/libdoxygen.pro.in2
-rw-r--r--src/libdoxygen.t3
-rw-r--r--src/mangen.cpp24
-rw-r--r--src/mangen.h2
-rw-r--r--src/memberdef.cpp70
-rw-r--r--src/memberlist.cpp48
-rw-r--r--src/message.cpp22
-rw-r--r--src/namespacedef.cpp30
-rw-r--r--src/outputgen.h2
-rw-r--r--src/outputlist.h4
-rw-r--r--src/packagedef.cpp8
-rw-r--r--src/page.h2
-rw-r--r--src/pre.l136
-rw-r--r--src/rtfgen.cpp57
-rw-r--r--src/rtfgen.h2
-rw-r--r--src/scanner.l85
-rw-r--r--src/translator.h57
-rw-r--r--src/translator_br.h889
-rw-r--r--src/translator_ru.h18
-rw-r--r--src/util.cpp42
-rw-r--r--src/util.h4
156 files changed, 4683 insertions, 6546 deletions
diff --git a/INSTALL b/INSTALL
index 71c4fd1..9161a9d 100644
--- a/INSTALL
+++ b/INSTALL
@@ -1,6 +1,6 @@
-DOXYGEN Version 1.2.6-20010319
+DOXYGEN Version 1.2.6-20010401
Please read the installation section of the manual for instructions.
--------
-Dimitri van Heesch (19 March 2001)
+Dimitri van Heesch (01 April 2001)
diff --git a/Makefile.in b/Makefile.in
index 2b38472..68479d9 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1,6 +1,6 @@
DOCDIR = $(INSTALL)/share/doc/packages/doxygen
-#all: src/version.cpp configgen doxywizard
+#all: src/version.cpp doxywizard
# cd qtools ; $(MAKE)
# cd src ; $(MAKE)
@@ -9,7 +9,6 @@ clean: FORCE
cd doc ; $(MAKE) clean
cd qtools ; $(MAKE) clean
cd src ; $(MAKE) clean
- cd addon/configgen ; $(MAKE) clean
cd addon/doxywizard ; $(MAKE) clean
cd addon/xmlread ; $(MAKE) clean
cd addon/xmlgen ; $(MAKE) clean
@@ -18,7 +17,6 @@ clean: FORCE
distclean: clean
cd src ; $(MAKE) distclean
- cd addon/configgen ; $(MAKE) distclean
cd addon/doxywizard ; $(MAKE) distclean
cd addon/xmlread ; $(MAKE) distclean
cd addon/xmlgen ; $(MAKE) distclean
@@ -26,19 +24,19 @@ distclean: clean
-rm -f bin/doxy*
-rm -f html
-rm -f objects/*.o
- -rm -f src/Makefile.doxygen src/Makefile.libdoxygen src/Makefile.doxytag
+ -rm -f src/Makefile.doxygen src/Makefile.libdoxygen
+ -rm -f src/Makefile.doxytag src/Makefile.libdoxycfg
-rm -f src/Makefile.doxysearch qtools/Makefile.qtools
-rm -f Makefile qtools/Makefile src/Makefile examples/Makefile doc/Makefile
-rm -f .makeconfig .tmakeconfig
- -rm -f src/doxygen.pro src/libdoxygen.pro src/doxytag.pro src/doxysearch.pro qtools/qtools.pro
+ -rm -f src/doxygen.pro src/libdoxygen.pro src/doxytag.pro src/doxysearch.pro qtools/qtools.pro src/libdoxycfg.pro
-rm -f src/version.cpp
- -rm -r addon/configgen/Makefile addon/doxywizard/Makefile
- -rm -f addon/configgen/Makefile.configgen
+ -rm -r addon/doxywizard/Makefile
-rm -f addon/doxywizard/Makefile.doxywizard
- -rm -f addon/configgen/configgen.pro addon/doxywizard/doxywizard.pro
- -rm -f addon/configgen/obj/*.o
+ -rm -f addon/doxywizard/doxywizard.pro
-rm -f addon/doxywizard/obj/*.o
-rm -f addon/doxywizard/moc/moc_*
+ -rm -f addon/doxywizard/config.cpp
-rm -f addon/xmlread/xmlread.pro
-rm -f addon/xmlread/Makefile addon/xmlread/Makefile.xmlread
-rm -f addon/xmlread/*.o
diff --git a/Makefile.win_make.in b/Makefile.win_make.in
index 40f2c45..d0a7eb2 100644
--- a/Makefile.win_make.in
+++ b/Makefile.win_make.in
@@ -13,9 +13,10 @@ distclean: clean
-del src\Makefile.libdoxygen \
src\Makefile.doxygen \
src\Makefile.doxytag \
- src\Makefile.doxysearch
+ src\Makefile.doxysearch \
+ src\Makefile.libdoxycfg
-del Makefile src\Makefile examples\Makefile doc\Makefile
- -del src\libdoxygen.pro src\doxygen.pro src\doxytag.pro src\doxysearch.pro
+ -del src\libdoxygen.pro src\doxygen.pro src\doxytag.pro src\doxysearch.pro src\libdoxycfg.pro
-del src\version.cpp
docs:
diff --git a/Makefile.win_nmake.in b/Makefile.win_nmake.in
index 4d9f65a..41961a0 100644
--- a/Makefile.win_nmake.in
+++ b/Makefile.win_nmake.in
@@ -23,9 +23,10 @@ distclean: clean
-del src\Makefile.libdoxygen \
src\Makefile.doxygen \
src\Makefile.doxytag \
- src\Makefile.doxysearch
+ src\Makefile.doxysearch \
+ src\Makefile.libdoxycfg
-del Makefile src\Makefile examples\Makefile doc\Makefile
- -del src\libdoxygen.pro src\doxygen.pro src\doxytag.pro src\doxysearch.pro
+ -del src\libdoxygen.pro src\doxygen.pro src\doxytag.pro src\doxysearch.pro src\libdoxycfg.pro
-del src\version.cpp
docs: FORCE
diff --git a/README b/README
index 70ca1aa..989c13c 100644
--- a/README
+++ b/README
@@ -1,4 +1,4 @@
-DOXYGEN Version 1.2.6-20010319
+DOXYGEN Version 1.2.6-20010401
Please read INSTALL for compilation instructions.
@@ -7,4 +7,4 @@ The latest version of doxygen can be obtained at
Enjoy,
-Dimitri van Heesch (19 March 2001)
+Dimitri van Heesch (01 April 2001)
diff --git a/VERSION b/VERSION
index 077c54b..b84b84c 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-1.2.6-20010319
+1.2.6-20010401
diff --git a/addon/configgen/Makefile.in b/addon/configgen/Makefile.in
deleted file mode 100644
index f5ad09a..0000000
--- a/addon/configgen/Makefile.in
+++ /dev/null
@@ -1,42 +0,0 @@
-#
-#
-#
-# Copyright (C) 1997-2001 by Dimitri van Heesch.
-#
-# Permission to use, copy, modify, and distribute this software and its
-# documentation under the terms of the GNU General Public License is hereby
-# granted. No representations are made about the suitability of this software
-# for any purpose. It is provided "as is" without express or implied warranty.
-# See the GNU General Public License for more details.
-#
-
-CFGGEN_DIR = bin
-
-all: Makefile.configgen config.h config.l
- $(MAKE) -f Makefile.configgen $@
-
-Makefile.configgen: configgen.pro
- $(ENV) $(PERL) $(TMAKE) configgen.pro >Makefile.configgen
-
-config.h: $(CFGGEN_DIR)/configgen config_templ.h
- $(CFGGEN_DIR)/configgen config_templ.h >config.h
-
-config.l: $(CFGGEN_DIR)/configgen config_templ.l
- $(CFGGEN_DIR)/configgen config_templ.l >config.l
-
-$(CFGGEN_DIR)/configgen: Makefile.configgen configgen.cpp
- $(MAKE) -f Makefile.configgen
-
-tmake:
- $(ENV) $(PERL) $(TMAKE) configgen.pro >Makefile.configgen
-
-install:
- $(CP) config.l config.h ../../src
-
-clean: Makefile.configgen
- $(MAKE) -f Makefile.configgen clean
-
-distclean: clean
- $(RM) config.cpp config.h config.l Makefile.configgen
-
-FORCE:
diff --git a/addon/configgen/README b/addon/configgen/README
deleted file mode 100644
index 717ca2e..0000000
--- a/addon/configgen/README
+++ /dev/null
@@ -1,13 +0,0 @@
-The configgen tool is used to:
-- generate the parser for the configuration file based on
- the templates config_templ.h and config_templ.l
-- generate the GUI frontend "doxywizard" for creating a configuration
- file based on the templates doxywizard_templ.h and doxywizard_templ.cpp
-
-If you want to add a new configuration option to doxygen,
-then you should add a new entry the init() function in configgen.cpp
-
-After that you can do a "make install" in this directory to update
-the config.l and config.h in doxygen's source directory.
-
--Dimitri
diff --git a/addon/configgen/config_templ.h b/addon/configgen/config_templ.h
deleted file mode 100644
index eca1a95..0000000
--- a/addon/configgen/config_templ.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/******************************************************************************
- *
- *
- *
- * Copyright (C) 1997-2001 by Dimitri van Heesch.
- *
- * Permission to use, copy, modify, and distribute this software and its
- * documentation under the terms of the GNU General Public License is hereby
- * granted. No representations are made about the suitability of this software
- * for any purpose. It is provided "as is" without express or implied warranty.
- * See the GNU General Public License for more details.
- *
- */
-
-#ifndef CONFIG_H
-#define CONFIG_H
-
-#ifndef DOXYWIZARD
-#include "qtbc.h"
-#endif
-#include <qstrlist.h>
-#include <qfile.h>
-
-extern void parseConfig(const QCString &config,const char *fn);
-extern void writeTemplateConfig(QFile *f,bool shortList);
-extern void checkConfig();
-extern void configStrToVal();
-extern void substituteEnvironmentVars();
-
-/*! \brief Namespace for configuration variables
- *
- * This struct acts as a namespace that holds the global static variables
- * read from a user-supplied configuration file.
- */
-struct Config
-{
- static void init();
-
-#CONFIG Header
-};
-
-#endif
diff --git a/addon/configgen/config_templ.l b/addon/configgen/config_templ.l
deleted file mode 100644
index c4310f3..0000000
--- a/addon/configgen/config_templ.l
+++ /dev/null
@@ -1,1004 +0,0 @@
-/******************************************************************************
- *
- *
- *
- * Copyright (C) 1997-2001 by Dimitri van Heesch.
- *
- * Permission to use, copy, modify, and distribute this software and its
- * documentation under the terms of the GNU General Public License is hereby
- * granted. No representations are made about the suitability of this software
- * for any purpose. It is provided "as is" without express or implied warranty.
- * See the GNU General Public License for more details.
- *
- */
-
-%{
-
-/*
- * includes
- */
-#include <stdio.h>
-#include <stdlib.h>
-#include <iostream.h>
-#include <assert.h>
-#include <ctype.h>
-
-#include <qfileinfo.h>
-#include <qdir.h>
-#include <qtextstream.h>
-#include <qregexp.h>
-#include <qstack.h>
-
-#include "config.h"
-#include "version.h"
-
-#ifdef DOXYWIZARD
-#include <stdarg.h>
-void err(const char *fmt, ...)
-{
- va_list args;
- va_start(args, fmt);
- vfprintf(stderr, fmt, args);
- va_end(args);
-}
-void warn_cont(const char *fmt, ...)
-{
- va_list args;
- va_start(args, fmt);
- vfprintf(stderr, fmt, args);
- va_end(args);
-}
-void initWarningFormat()
-{
-}
-#else
-#include "doxygen.h"
-#include "message.h"
-#include "pre.h"
-#include "version.h"
-#include "language.h"
-#endif
-
-#define MAX_INCLUDE_DEPTH 10
-#define YY_NEVER_INTERACTIVE 1
-#define YY_NO_UNPUT
-
-/* -----------------------------------------------------------------
- *
- * exported variables
- */
-
-#CONFIG Config
-
-/* -----------------------------------------------------------------
- *
- * static variables
- */
-
-struct ConfigFileState
-{
- int lineNr;
- FILE *filePtr;
- YY_BUFFER_STATE oldState;
- YY_BUFFER_STATE newState;
- QCString fileName;
-};
-
-static const char *inputString;
-static int inputPosition;
-static int yyLineNr;
-static QCString yyFileName;
-static QCString tmpString;
-static QCString *s=0;
-static bool *b=0;
-static QStrList *l=0;
-static int lastState;
-static QCString elemStr;
-static QCString includeName;
-static QStrList includePathList;
-static QStack<ConfigFileState> includeStack;
-static int includeDepth;
-
-#CONFIG Static
-
-/* -----------------------------------------------------------------
- */
-#undef YY_INPUT
-#define YY_INPUT(buf,result,max_size) result=yyread(buf,max_size);
-
-static int yyread(char *buf,int max_size)
-{
- // no file included
- if (includeStack.isEmpty())
- {
- int c=0;
- while( c < max_size && inputString[inputPosition] )
- {
- *buf = inputString[inputPosition++] ;
- c++; buf++;
- }
- return c;
- }
- else
- {
- //assert(includeStack.current()->newState==YY_CURRENT_BUFFER);
- return fread(buf,1,max_size,includeStack.current()->filePtr);
- }
-}
-
-
-static FILE *tryPath(const char *path,const char *fileName)
-{
- QCString absName=(QCString)path+"/"+fileName;
- QFileInfo fi(absName);
- if (fi.exists() && fi.isFile())
- {
- FILE *f=fopen(absName,"r");
- if (!f) err("Error: could not open file %s for reading\n",absName.data());
- return f;
- }
- return 0;
-}
-
-static void substEnvVarsInStrList(QStrList &sl);
-static void substEnvVarsInString(QCString &s);
-
-static FILE *findFile(const char *fileName)
-{
- substEnvVarsInStrList(includePathList);
- char *s=includePathList.first();
- while (s) // try each of the include paths
- {
- FILE *f = tryPath(s,fileName);
- if (f) return f;
- s=includePathList.next();
- }
- // try cwd if includePathList fails
- return tryPath(".",fileName);
-}
-
-static void readIncludeFile(const char *incName)
-{
- if (includeDepth==MAX_INCLUDE_DEPTH) {
- err("Error: maximum include depth (%d) reached, %s is not included. Aborting...\n",
- MAX_INCLUDE_DEPTH,incName);
- exit(1);
- }
-
- QCString inc = incName;
- substEnvVarsInString(inc);
- inc = inc.stripWhiteSpace();
- uint incLen = inc.length();
- if (inc.at(0)=='"' && inc.at(incLen-1)=='"') // strip quotes
- {
- inc=inc.mid(1,incLen-2);
- }
-
- FILE *f;
-
- //printf("Searching for `%s'\n",incFileName.data());
- if ((f=findFile(inc))) // see if the include file can be found
- {
- // For debugging
-#if SHOW_INCLUDES
- for (i=0;i<includeStack.count();i++) msg(" ");
- msg("@INCLUDE = %s: parsing...\n",inc.data());
-#endif
-
- // store the state of the old file
- ConfigFileState *fs=new ConfigFileState;
- fs->oldState=YY_CURRENT_BUFFER;
- fs->lineNr=yyLineNr;
- fs->fileName=yyFileName;
- fs->filePtr=f;
- // push the state on the stack
- includeStack.push(fs);
- // set the scanner to the include file
- yy_switch_to_buffer(yy_create_buffer(f, YY_BUF_SIZE));
- fs->newState=YY_CURRENT_BUFFER;
- yyFileName=inc;
- includeDepth++;
- }
- else
- {
- err("Error: @INCLUDE = %s: not found!\n",inc.data());
- exit(1);
- }
-}
-
-
-%}
-
-%option noyywrap
-
-%x Start
-%x SkipComment
-%x GetString
-%x GetBool
-%x GetStrList
-%x GetQuotedString
-%x GetEnvVar
-%x Include
-
-%%
-
-<*>\0x0d
-<Start,GetString,GetStrList,GetBool>"#" { BEGIN(SkipComment); }
-#CONFIG Rules
-
-<Start>"@INCLUDE_PATH"[ \t]*"=" { BEGIN(GetStrList); l=&includePathList; l->clear(); elemStr=""; }
- /* include a config file */
-<Start>"@INCLUDE"[ \t]*"=" { BEGIN(Include);}
-<Include>([^ \"\t\r\n]+)|("\""[^\n\"]+"\"") {
- readIncludeFile(yytext);
- BEGIN(Start);
- }
-<<EOF>> {
- //printf("End of include file\n");
- //printf("Include stack depth=%d\n",g_includeStack.count());
- if (includeStack.isEmpty())
- {
- //printf("Terminating scanner!\n");
- yyterminate();
- }
- else
- {
- ConfigFileState *fs=includeStack.pop();
- fclose(fs->filePtr);
- YY_BUFFER_STATE oldBuf = YY_CURRENT_BUFFER;
- yy_switch_to_buffer( fs->oldState );
- yy_delete_buffer( oldBuf );
- yyLineNr=fs->lineNr;
- yyFileName=fs->fileName;
- delete fs; fs=0;
- includeDepth--;
- }
- }
-
-<Start>[a-z_A-Z0-9]+ { err("Warning: ignoring unknown tag `%s' at line %d, file %s\n",yytext,yyLineNr,yyFileName.data()); }
-<GetString,GetBool>\n { yyLineNr++; BEGIN(Start); }
-<GetStrList>\n {
- yyLineNr++;
- if (!elemStr.isEmpty())
- {
- //printf("elemStr1=`%s'\n",elemStr.data());
- l->append(elemStr);
- }
- BEGIN(Start);
- }
-<GetStrList>[ \t]+ {
- if (!elemStr.isEmpty())
- {
- //printf("elemStr2=`%s'\n",elemStr.data());
- l->append(elemStr);
- }
- elemStr.resize(0);
- }
-<GetString>[^ \"\t\r\n]+ { (*s)+=yytext; }
-<GetString,GetStrList>"\"" { lastState=YY_START;
- BEGIN(GetQuotedString);
- tmpString.resize(0);
- }
-<GetQuotedString>"\""|"\n" {
- //printf("Quoted String = `%s'\n",tmpString.data());
- if (lastState==GetString)
- (*s)+=tmpString;
- else
- elemStr+=tmpString;
- if (*yytext=='\n')
- {
- err("Warning: Missing end quote (\") on line %d, file %s\n",yyLineNr,yyFileName.data());
- yyLineNr++;
- }
- BEGIN(lastState);
- }
-<GetQuotedString>"\\\"" {
- tmpString+='"';
- }
-<GetQuotedString>. { tmpString+=*yytext; }
-<GetBool>[a-zA-Z]+ {
- QCString bs=yytext;
- bs=bs.upper();
- if (bs=="YES")
- *b=TRUE;
- else if (bs=="NO")
- *b=FALSE;
- else
- {
- *b=FALSE;
- warn_cont("Warning: Invalid value `%s' for "
- "boolean tag in line %d, file %s; use YES or NO\n",
- bs.data(),yyLineNr,yyFileName.data());
- }
- }
-<GetStrList>[^ \#\"\t\r\n]+ {
- elemStr+=yytext;
- }
-<SkipComment>\n { yyLineNr++; BEGIN(Start); }
-<SkipComment>\\[ \r\t]*\n { yyLineNr++; BEGIN(Start); }
-<*>\\[ \r\t]*\n { yyLineNr++; }
-<*>.
-<*>\n { yyLineNr++ ; }
-
-%%
-
-/*@ ----------------------------------------------------------------------------
- */
-
-
-void dumpConfig()
-{
-#CONFIG Dump
-}
-
-void Config::init()
-{
-#CONFIG Init
-}
-
-static void writeBoolValue(QTextStream &t,bool v)
-{
- if (v) t << "YES"; else t << "NO";
-}
-
-static void writeIntValue(QTextStream &t,int i)
-{
- t << i;
-}
-
-static void writeStringValue(QTextStream &t,QCString &s)
-{
- const char *p=s.data();
- char c;
- bool hasBlanks=FALSE;
- if (p)
- {
- while ((c=*p++)!=0 && !hasBlanks) hasBlanks = (c==' ' || c=='\n' || c=='\t');
- if (hasBlanks)
- t << "\"" << s << "\"";
- else
- t << s;
- }
-}
-
-static void writeStringList(QTextStream &t,QStrList &l)
-{
- const char *p = l.first();
- bool first=TRUE;
- while (p)
- {
- char c;
- const char *s=p;
- bool hasBlanks=FALSE;
- while ((c=*p++)!=0 && !hasBlanks) hasBlanks = (c==' ' || c=='\n' || c=='\t');
- if (!first) t << " ";
- first=FALSE;
- if (hasBlanks) t << "\"" << s << "\""; else t << s;
- p = l.next();
- if (p) t << " \\" << endl;
- }
-}
-
-void writeTemplateConfig(QFile *f,bool sl)
-{
- QTextStream t(f);
-#ifdef DOXYWIZARD
- t << "# Doxygen configuration generated by Doxywizard version " << versionString << endl;
-#else
- t << "# Doxyfile " << versionString << endl << endl;
-#endif
- if (!sl)
- {
- t << "# This file describes the settings to be used by doxygen for a project\n";
- t << "#\n";
- t << "# All text after a hash (#) is considered a comment and will be ignored\n";
- t << "# The format is:\n";
- t << "# TAG = value [value, ...]\n";
- t << "# For lists items can also be appended using:\n";
- t << "# TAG += value [value, ...]\n";
- t << "# Values that contain spaces should be placed between quotes (\" \")\n";
- }
-#CONFIG Template
-}
-
-void configStrToVal()
-{
- if (tabSizeString.isEmpty())
- {
- Config::tabSize=8;
- }
- else
- {
- bool ok;
- int ts = tabSizeString.toInt(&ok);
- if (!ok || ts<1 || ts>16)
- {
- warn_cont("Warning: argument of TAB_SIZE is not a valid number, using tab size of 8 spaces!\n");
- ts=8;
- }
- Config::tabSize = ts;
- }
-
- if (colsInAlphaIndexString.isEmpty())
- {
- Config::colsInAlphaIndex=5;
- }
- else
- {
- bool ok;
- int cols = colsInAlphaIndexString.toInt(&ok);
- if (!ok || cols<1 || cols>20)
- {
- warn_cont("Warning: argument of COLS_IN_ALPHA_INDEX is not a valid number in the range [1..20]!\n"
- "Using the default of 5 columns!\n");
- cols = 5;
- }
- Config::colsInAlphaIndex=cols;
- }
-
- if (enumValuesPerLineString.isEmpty())
- {
- Config::enumValuesPerLine=4;
- }
- else
- {
- bool ok;
- int cols = enumValuesPerLineString.toInt(&ok);
- if (!ok || cols<1 || cols>20)
- {
- warn_cont("Warning: argument of ENUM_VALUES_PER_LINE is not a valid number in the range [1..20]!\n"
- "Using the default of 4!\n");
- cols = 4;
- }
- Config::enumValuesPerLine=cols;
- }
-
- if (treeViewWidthString.isEmpty())
- {
- Config::treeViewWidth=250;
- }
- else
- {
- bool ok;
- int width = treeViewWidthString.toInt(&ok);
- if (!ok || width<0 || width>1500)
- {
- warn_cont("Warning: argument of TREEVIEW_WIDTH is not a valid number in the range [0..1500]!\n"
- "Using the default of 250!\n");
- width = 250;
- }
- Config::treeViewWidth=width;
- }
-
- if (maxDotGraphWidthString.isEmpty())
- {
- Config::maxDotGraphWidth=1024;
- }
- else
- {
- bool ok;
- int width =maxDotGraphWidthString.toInt(&ok);
- if (!ok)
- {
- warn_cont("Warning: argument of MAX_DOT_GRAPH_WIDTH is not a valid number in the range [100..30000]!\n"
- "Using the default of 1024 pixels!\n");
- width=1024;
- }
- else if (width<100) // clip to lower bound
- {
- width=100;
- }
- else if (width>30000) // clip to upper bound
- {
- width=30000;
- }
- Config::maxDotGraphWidth=width;
- }
-
- if (maxDotGraphHeightString.isEmpty())
- {
- Config::maxDotGraphHeight=1024;
- }
- else
- {
- bool ok;
- int height =maxDotGraphHeightString.toInt(&ok);
- if (!ok)
- {
- warn_cont("Warning: argument of MAX_DOT_GRAPH_WIDTH is not a valid number in the range [100..30000]!\n"
- "Using the default of 1024 pixels!\n");
- height=1024;
- }
- else if (height<100) // clip to lower bound
- {
- height=100;
- }
- else if (height>30000) // clip to upper bound
- {
- height=30000;
- }
- Config::maxDotGraphHeight=height;
- }
-
- if (maxInitLinesString.isEmpty())
- {
- Config::maxInitLines=30;
- }
- else
- {
- bool ok;
- int maxLines =maxInitLinesString.toInt(&ok);
- if (!ok)
- {
- warn_cont("Warning: argument of MAX_DOT_GRAPH_WIDTH is not a valid number in the range [100..30000]!\n"
- "Using the default of 1024 pixels!\n");
- maxLines=30;
- }
- else if (maxLines<0) // clip to lower bound
- {
- maxLines=0;
- }
- else if (maxLines>10000) // clip to upper bound
- {
- maxLines=10000;
- }
- Config::maxInitLines=maxLines;
- }
-}
-
-static void substEnvVarsInString(QCString &s)
-{
- static QRegExp re("\\$\\([a-z_A-Z0-9]+\\)");
- if (s.isEmpty()) return;
- int p=0;
- int i,l;
- //printf("substEnvVarInString(%s) start\n",s.data());
- while ((i=re.match(s,p,&l))!=-1)
- {
- //printf("Found environment var s.mid(%d,%d)=`%s'\n",i+2,l-3,s.mid(i+2,l-3).data());
- QCString env=getenv(s.mid(i+2,l-3));
- substEnvVarsInString(env); // recursively expand variables if needed.
- s = s.left(i)+env+s.right(s.length()-i-l);
- p=i+env.length(); // next time start at the end of the expanded string
- }
- //printf("substEnvVarInString(%s) end\n",s.data());
-}
-
-static void substEnvVarsInStrList(QStrList &sl)
-{
- char *s = sl.first();
- while (s)
- {
- QCString result(s);
- bool wasQuoted = (result.find(' ')!=-1) || (result.find('\t')!=-1);
- substEnvVarsInString(result);
-
- if (!wasQuoted) /* as a result of the expansion, a single string
- may have expanded into a list, which we'll
- add to sl. If the orginal string already
- contained multiple elements no further
- splitting is done to allow quoted items with spaces! */
- {
-
-
-
- int l=result.length();
- int i,p=0;
- // skip spaces
- // search for a "word"
- for (i=0;i<l;i++)
- {
- char c;
- // skip until start of new word
- while (i<l && ((c=result.at(i))==' ' || c=='\t')) i++;
- p=i; // p marks the start index of the word
- // skip until end of a word
- while (i<l && ((c=result.at(i))!=' ' && c!='\t' && c!='"')) i++;
- if (i<l) // not at the end of the string
- {
- if (c=='"') // word within quotes
- {
- p=i+1;
- for (i++;i<l;i++)
- {
- c=result.at(i);
- if (c=='"') // end quote
- {
- // replace the string in the list and go to the next item.
- sl.insert(sl.at(),result.mid(p,i-p)); // insert new item before current item.
- sl.next(); // current item is now the old item
- p=i+1;
- break;
- }
- else if (c=='\\') // skip escaped stuff
- {
- i++;
- }
- }
- }
- else if (c==' ' || c=='\t') // separator
- {
- // replace the string in the list and go to the next item.
- sl.insert(sl.at(),result.mid(p,i-p)); // insert new item before current item.
- sl.next(); // current item is now the old item
- p=i+1;
- }
- }
- }
- if (p!=l) // add the leftover as a string
- {
- // replace the string in the list and go to the next item.
- sl.insert(sl.at(),result.right(l-p)); // insert new item before current item.
- sl.next(); // current item is now the old item
- }
-
- // remove the old unexpanded string from the list
- i=sl.at();
- sl.remove(); // current item index changes if the last element is removed.
- if (sl.at()==i) // not last item
- s = sl.current();
- else // just removed last item
- s = 0;
- }
- else // just goto the next element in the list
- {
- s=sl.next();
- }
- }
-}
-
-
-void substituteEnvironmentVars()
-{
-#CONFIG Substenv
-}
-
-void checkConfig()
-{
- //if (!projectName.isEmpty())
- //{
- // projectName[0]=toupper(projectName[0]);
- //}
-
- if (Config::warnFormat.isEmpty())
- {
- Config::warnFormat="$file:$line $text";
- }
- else
- {
- if (Config::warnFormat.find("$file")==-1)
- {
- err("Error: warning format does not contain a $file tag!\n");
- exit(1);
- }
- if (Config::warnFormat.find("$line")==-1)
- {
- err("Error: warning format does not contain a $line tag!\n");
- exit(1);
- }
- if (Config::warnFormat.find("$text")==-1)
- {
- err("Error: wanring format foes not contain a $text tag!\n");
- exit(1);
- }
- }
- initWarningFormat();
-
- // set default man page extension if non is given by the user
- if (Config::manExtension.isEmpty())
- {
- Config::manExtension=".3";
- }
-
- Config::paperType = Config::paperType.lower().stripWhiteSpace();
- if (Config::paperType.isEmpty())
- {
- Config::paperType = "a4wide";
- }
- if (Config::paperType!="a4" && Config::paperType!="a4wide" && Config::paperType!="letter" &&
- Config::paperType!="legal" && Config::paperType!="executive")
- {
- err("Error: Unknown page type specified");
- }
-
- Config::outputLanguage=Config::outputLanguage.stripWhiteSpace();
- if (Config::outputLanguage.isEmpty())
- {
- Config::outputLanguage = "English";
-#ifndef DOXYWIZARD
- setTranslator("English");
-#endif
- }
- else
- {
-#ifndef DOXYWIZARD
- if (!setTranslator(Config::outputLanguage))
- {
- err("Error: Output language %s not supported! Using English instead.\n",
- Config::outputLanguage.data());
- }
-#endif
- }
-
- // expand the relative stripFromPath values
- char *sfp = Config::stripFromPath.first();
- while (sfp)
- {
- QCString path = sfp;
- if (path.at(0)!='/' && (path.length()<=2 || path.at(1)!=':'))
- {
- QFileInfo fi(path);
- if (fi.exists() && fi.isDir())
- {
- int i = Config::stripFromPath.at();
- Config::stripFromPath.remove();
- if (Config::stripFromPath.at()==i) // did not remove last item
- Config::stripFromPath.insert(i,fi.absFilePath()+"/");
- else
- Config::stripFromPath.append(fi.absFilePath()+"/");
- }
- }
- sfp = Config::stripFromPath.next();
- }
-
-
- // Test to see if HTML header is valid
- if (!Config::headerFile.isEmpty())
- {
- QFileInfo fi(Config::headerFile);
- if (!fi.exists())
- {
- err("Error: tag HTML_HEADER: header file `%s' "
- "does not exist\n",Config::headerFile.data());
- exit(1);
- }
- }
- // Test to see if HTML footer is valid
- if (!Config::footerFile.isEmpty())
- {
- QFileInfo fi(Config::footerFile);
- if (!fi.exists())
- {
- err("Error: tag HTML_FOOTER: footer file `%s' "
- "does not exist\n",Config::footerFile.data());
- exit(1);
- }
- }
- // Test to see if LaTeX header is valid
- if (!Config::latexHeaderFile.isEmpty())
- {
- QFileInfo fi(Config::latexHeaderFile);
- if (!fi.exists())
- {
- err("Error: tag LATEX_HEADER: header file `%s' "
- "does not exist\n",Config::latexHeaderFile.data());
- exit(1);
- }
- }
- // check include path
- char *s=Config::includePath.first();
- while (s)
- {
- QFileInfo fi(s);
- if (!fi.exists()) err("Warning: tag INCLUDE_PATH: include path `%s' "
- "does not exist\n",s);
-#ifndef DOXYWIZARD
- addSearchDir(fi.absFilePath());
-#endif
- s=Config::includePath.next();
- }
-
- // check aliases
- s=Config::aliasList.first();
- while (s)
- {
- QRegExp re("[a-z_A-Z][a-z_A-Z0-9]*[ \t]*=");
- QCString alias=s;
- alias=alias.stripWhiteSpace();
- if (alias.find(re)!=0)
- {
- err("Illegal alias format `%s'. Use \"name=value\"\n",alias.data());
- }
- s=Config::aliasList.next();
- }
-
- // check dot path
- if (!Config::dotPath.isEmpty())
- {
- if (Config::dotPath.find('\\')!=-1)
- {
- if (Config::dotPath.at(Config::dotPath.length()-1)!='\\')
- {
- Config::dotPath+='\\';
- }
- }
- else if (Config::dotPath.find('/')!=-1)
- {
- if (Config::dotPath.at(Config::dotPath.length()-1)!='/')
- {
- Config::dotPath+='/';
- }
- }
-#if defined(_WIN32)
- QFileInfo dp(Config::dotPath+"dot.exe");
-#else
- QFileInfo dp(Config::dotPath+"dot");
-#endif
- if (!dp.exists() || !dp.isFile())
- {
- err("Warning: the dot tool could not be found at %s\n",Config::dotPath.data());
- Config::dotPath="";
- }
- else
- {
- Config::dotPath=dp.dirPath(TRUE)+"/";
-#if defined(_WIN32) // convert slashes
- uint i=0,l=Config::dotPath.length();
- for (i=0;i<l;i++) if (Config::dotPath.at(i)=='/') Config::dotPath.at(i)='\\';
-#endif
- }
- }
- else // make sure the string is empty but not null!
- {
- Config::dotPath="";
- }
-
- // check input
- if (Config::inputSources.count()==0)
- {
- err("Error: tag INPUT: no input files specified after the INPUT tag.\n");
- exit(1);
- }
- else
- {
- s=Config::inputSources.first();
- while (s)
- {
- QFileInfo fi(s);
- if (!fi.exists())
- {
- err("Error: tag INPUT: input source `%s' does not exist\n",s);
- exit(1);
- }
- s=Config::inputSources.next();
- }
- }
-
- // add default pattern if needed
- if (Config::filePatternList.isEmpty())
- {
- Config::filePatternList.append("*");
- }
-
- // add default pattern if needed
- if (Config::examplePatternList.isEmpty())
- {
- Config::examplePatternList.append("*");
- }
-
- // add default pattern if needed
- //if (Config::imagePatternList.isEmpty())
- //{
- // Config::imagePatternList.append("*");
- //}
-
- // more checks needed if and only if the search engine is enabled.
- if (Config::searchEngineFlag)
- {
- // check cgi name
- if (Config::cgiName.isEmpty())
- {
- err("Error: tag CGI_NAME: no cgi script name after the CGI_NAME tag.\n");
- exit(1);
- }
- // check cgi URL
- if (Config::cgiURL.isEmpty())
- {
- err("Error: tag CGI_URL: no URL to cgi directory specified.\n");
- exit(1);
- }
- else if (Config::cgiURL.left(7)!="http://" &&
- Config::cgiURL.left(8)!="https://"
- )
- {
- err("Error: tag CGI_URL: URL to cgi directory is invalid (must "
- "start with http:// or https://).\n");
- exit(1);
- }
- // check documentation URL
- if (Config::docURL.isEmpty())
- {
- Config::docURL = Config::outputDir.copy().prepend("file://").append("html");
- }
- else if (Config::docURL.left(7)!="http://" &&
- Config::docURL.left(8)!="https://" &&
- Config::docURL.left(7)!="file://"
- )
- {
- err("Error: tag DOC_URL: URL to documentation is invalid or "
- "not absolute.\n");
- exit(1);
- }
- // check absolute documentation path
- if (Config::docAbsPath.isEmpty())
- {
- Config::docAbsPath = Config::outputDir+"/html";
- }
- else if (Config::docAbsPath[0]!='/' && Config::docAbsPath[1]!=':')
- {
- err("Error: tag DOC_ABSPATH: path is not absolute!\n");
- exit(1);
- }
- // check path to doxysearch
- if (Config::binAbsPath.isEmpty())
- {
- err("Error: tag BIN_ABSPATH: no absolute path to doxysearch "
- "specified.\n");
- exit(1);
- }
- else if (Config::binAbsPath[0]!='/' && Config::binAbsPath[1]!=':')
- {
- err("Error: tag BIN_ABSPATH: path is not absolute!\n");
- exit(1);
- }
-
- // check perl path
- bool found=FALSE;
- if (Config::perlPath.isEmpty())
- {
- QFileInfo fi;
- fi.setFile("/usr/bin/perl");
- if (fi.exists())
- {
- Config::perlPath="/usr/bin/perl";
- found=TRUE;
- }
- else
- {
- fi.setFile("/usr/local/bin/perl");
- if (fi.exists())
- {
- Config::perlPath="/usr/local/bin/perl";
- found=TRUE;
- }
- }
- }
- if (!found)
- {
- QFileInfo fi(Config::perlPath);
- if (!fi.exists())
- {
- warn_cont("Warning: tag PERL_PATH: perl interpreter not found at default or"
- "user specified (%s) location\n",
- Config::perlPath.data());
- }
- }
- }
-
-#undef PUTENV
-#if defined(_WIN32) && !defined(__GNUC__)
-#define PUTENV _putenv
-#else
-#define PUTENV putenv
-#endif
- if (Config::haveDotFlag) PUTENV("DOTFONTPATH=.");
-
-}
-
-void parseConfig(const QCString &s,const char *fn)
-{
- inputString = s;
- inputPosition = 0;
- yyLineNr = 1;
- yyFileName=fn;
- includeStack.setAutoDelete(TRUE);
- includeStack.clear();
- includeDepth = 0;
- configYYrestart( configYYin );
- BEGIN( Start );
- configYYlex();
-}
-
-//extern "C" { // some bogus code to keep the compiler happy
-// int configYYwrap() { return 1 ; }
-//}
diff --git a/addon/configgen/configgen.cpp b/addon/configgen/configgen.cpp
deleted file mode 100644
index db2c42f..0000000
--- a/addon/configgen/configgen.cpp
+++ /dev/null
@@ -1,1887 +0,0 @@
-/******************************************************************************
- *
- *
- *
- * Copyright (C) 2000 by Joerg Baumann & Dimitri van Heesch.
- *
- * Permission to use, copy, modify, and distribute this software and its
- * documentation under the terms of the GNU General Public License is hereby
- * granted. No representations are made about the suitability of this software
- * for any purpose. It is provided "as is" without express or implied warranty.
- * See the GNU General Public License for more details.
- *
- * All output generated with Doxygen is not covered by this license.
- *
- */
-
-// includes
-
-#include "qtbc.h"
-#include <qtextstream.h>
-#include <qfile.h>
-#include <qlist.h>
-#include <qdict.h>
-#include <qstrlist.h>
-#include <qdatetime.h>
-
-#include <stdio.h>
-#include <stdlib.h>
-
-#define MAX_OPTION_LENGTH 23
-
-static QString spaces=" ";
-
-void init(); // defined below
-
-// Iterate over all options calling the spezified method
-#define FORALL(x) \
-{\
- ConfigOption *co=ConfigOption::optionList.first();\
- while (co)\
- {\
- co->x;\
- co=ConfigOption::optionList.next();\
- }\
-}
-
-/*! convert a normal string \a s into a string that can be embedded in C code.
- * The \a prefix string will be placed before each string line and the
- * \a postfix string will be placed after each string.
- */
-static void stringToC(QTextStream &t,QCString &s,
- const char *prefix,const char *postfix)
-{
- int i=0,l=s.length();
- bool eol=TRUE;
- for (i=0;i<l;i++)
- {
- char c;
- switch ((c=s[i]))
- {
- case '\n':
- t << postfix << endl;
- eol=TRUE;
- break;
- case '\\':
- case '"':
- if (eol) t << prefix;
- t << "\\" << (char)c;
- eol=FALSE;
- break;
- default:
- if (eol) t << prefix;
- eol=FALSE;
- t << (char)c;
- break;
- }
- }
- if (!eol) t << postfix << endl;
-}
-
-class ConfigBool;
-
-/*! baseclass for options */
-class ConfigOption
-{
- public:
- static QList<ConfigOption> optionList;
- static QDict<ConfigOption> optionDict;
- QCString getVarName() const { return varName; }
-
- virtual ~ConfigOption() {}
-
- virtual void printHeader(QTextStream &t)
- {
- t << " static " << type << " " << varName
- << "; /*!< " << shortDesc << " */" << endl;
- }
- virtual void printStatic(QTextStream &) {}
- virtual void printConfig(QTextStream &t)
- {
- t << type << " Config::" << varName;
- if (!defaultValue.isEmpty()) t << " = \"" << defaultValue << "\"";
- t << ";" << endl;
- }
- virtual void printRules(QTextStream &)
- {
- }
- virtual void printDump(QTextStream &)
- {
- }
- virtual void printCheck(QTextStream &t)
- {
- // FIXME
- if (!check.isEmpty()) t << check << endl;
- }
- virtual void printInit(QTextStream &t)
- {
- t << " Config::" << varName << " = "
- << defaultValue << ";" << endl;
- }
- virtual void printTemplate(QTextStream &t)
- {
- t << " if (!sl)" << endl;
- t << " {" << endl;
- t << " t << \"\\n\";" << endl;
- stringToC(t,longDesc," t << \"# ","\\n\";");
- t << " t << \"\\n\";" << endl;
- t << " }" << endl;
- t << " t << \"" << cfgName;
- t << spaces.left(MAX_OPTION_LENGTH-cfgName.length());
- t << "= \";" << endl;
- t << " " << writeFunc << "(t,Config::" << varName << ");" << endl;
- t << " t << \"\\n\";" << endl;
- }
- virtual void printSubstEnv(QTextStream &) {}
- virtual void printWidgets(QTextStream &,int) = 0;
- virtual void addDependency(ConfigOption *)
- {
- fprintf(stderr,"Error: dependency add for non boolean option!\n");
- }
- void setDependsOn(ConfigBool *b) { depends=b; }
-
- protected:
- ConfigOption(const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_,const char * type_,
- const char * type2_,const char * writeFunc_
- ):
- varName(var), cfgName(cfg), defaultValue(value), shortDesc(short_),
- longDesc(long_), type(type_), type2(type2_), writeFunc(writeFunc_)
- {
- if (optionDict.find(var)!=0)
- {
- fprintf(stderr,"Error: configuration variable found more than once!\n");
- }
- else
- {
- optionList.append(this);
- optionDict.insert(var,this);
- }
- depends=0;
- }
-
- void tclQuote(QTextStream &t,const char *s)
- {
- t << "{";
- for (const char *p=s;*p!=0;p++)
- {
- if (strchr("{}",*p)) t << '\\';
- t << (*p);
- }
- t << "} ";
- }
-
- QCString varName; // name as in Config::name
- QCString cfgName; // name as in cfgfile
- QCString defaultValue; // default value
- QCString shortDesc; // short description
- QCString longDesc; // long description
- QCString type,type2; //
- QCString writeFunc; //
- QCString check; //
- ConfigBool *depends;
-};
-
-QList<ConfigOption> ConfigOption::optionList;
-QDict<ConfigOption> ConfigOption::optionDict;
-
-void addDependency(const char *src,const char *dst)
-{
- ConfigOption *sopt = ConfigOption::optionDict.find(src);
- ConfigOption *dopt = ConfigOption::optionDict.find(dst);
- if (!sopt)
- {
- fprintf(stderr,"Error: option %s not defined!\n",src);
- }
- if (!dopt)
- {
- fprintf(stderr,"Error: option %s not defined!\n",dst);
- }
- dopt->addDependency(sopt);
- sopt->setDependsOn((ConfigBool *)dopt);
-}
-
-
-class ConfigInfo : public ConfigOption
-{
- public:
- ConfigInfo(const char *var,const char * short_)
- : ConfigOption(var,"","",short_,"","","","") {}
- static void add(const char *var,const char * short_);
- void printHeader(QTextStream &) {}
- void printConfig(QTextStream &) {}
- void printRules(QTextStream &) {}
- virtual void printTemplate(QTextStream &t)
- {
- t << " if (!sl)" << endl;
- t << " {" << endl;
- t << " t << \"\\n\";" << endl;
- t << " }" << endl;
- t << " t << \"#---------------------------------------------------------------------------\\n\";" << endl;
- t << " t << \"# " << shortDesc << "\\n\";" << endl;
- t << " t << \"#---------------------------------------------------------------------------\\n\";" << endl;
- }
- virtual void printInit(QTextStream &) {}
- virtual void printDump(QTextStream &t)
- {
- t << " printf(\"# " << shortDesc << "\\n\");" << endl;
- }
- virtual void printWidgets(QTextStream &t,int pass)
- {
- switch(pass)
- {
- case 0:
- t << " PageWidget *" << varName << " = new PageWidget( tab, \""
- << varName << "\" );" << endl;
- break;
- case 1:
- t << " " << varName << "->addStretch(1);" << endl;
- break;
- default:
- break;
- }
- }
- QCString getVarName() { return varName; }
-};
-
-class ConfigList : public ConfigOption
-{
- public:
- enum WidgetType { String, File, Dir, FileAndDir };
- ConfigList(ConfigInfo *parent,const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_, WidgetType w)
- : ConfigOption(var,cfg,value,short_,long_,"QStrList","List","writeStringList"),
- m_parent(parent),
- m_widgetType(w)
- {
- }
- static void add(const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_,WidgetType w=String);
- virtual void printRules(QTextStream &t)
- {
- // rule for assignment
- t << "<Start>\"" << cfgName << "\"[ \\t]*\"=\"";
- t << spaces.left(MAX_OPTION_LENGTH-cfgName.length());
- t << "{ BEGIN(GetStrList); l=&Config::" << varName;
- t << "; l->clear(); elemStr=\"\"; }" << endl;
-
- // rule for appending
- t << "<Start>\"" << cfgName << "\"[ \\t]*\"+=\"";
- t << spaces.left(MAX_OPTION_LENGTH-cfgName.length()-1);
- t << "{ BEGIN(GetStrList); l=&Config::" << varName;
- t << "; elemStr=\"\"; }" << endl;
- }
- virtual void printInit(QTextStream &t)
- {
- t << " Config::" << varName;
- if (!defaultValue.isEmpty())
- {
- t << " = \"" << defaultValue << "\"";
- }
- else
- {
- t << ".clear()";
- }
- t << ";" << endl;
- }
- virtual void printDump(QTextStream &t)
- {
- t << " {" << endl;
- t << " char *is=Config::" << varName << ".first();" << endl;
- t << " while (is)" << endl;
- t << " {" << endl;
- t << " printf(\"" << varName << "=`%s'\\n\",is);" << endl;
- t << " is=Config::" << varName << ".next();" << endl;
- t << " }" << endl;
- t << " }" << endl;
- }
- virtual void printSubstEnv(QTextStream &t)
- {
- t << " substEnvVarsInStrList( Config::" << varName << " );" << endl;
- }
- virtual void printWidgets(QTextStream &t,int pass)
- {
- switch (pass)
- {
- case 0:
- {
- t << " " << varName << " = new InputStrList( \"" << cfgName
- << "\", " << m_parent->getVarName() << ", Config::" << varName;
- if (m_widgetType!=String)
- {
- t << ",";
- switch(m_widgetType)
- {
- case File: t << "InputStrList::ListFile"; break;
- case Dir: t << "InputStrList::ListDir"; break;
- case FileAndDir: t << "InputStrList::ListFileDir"; break;
- default: break;
- }
- }
- t << " );" << endl;
- t << " QWhatsThis::add(" << varName << ", " << endl;
- stringToC(t,longDesc," \"","\"");
- t << " );" << endl;
- t << " connect(" << varName
- << ",SIGNAL(changed()),this,SIGNAL(changed()));" << endl;
- }
- break;
- case 2:
- {
- t << " InputStrList *" << varName << ";" << endl;
- }
- break;
- case 5:
- {
- t << " " << varName << "->init();" << endl;
- }
- break;
- default:
- break;
- }
- }
- private:
- ConfigInfo *m_parent;
- WidgetType m_widgetType;
-};
-
-class ConfigString : public ConfigOption
-{
- public:
- enum WidgetType { String, File, Dir };
- ConfigString(ConfigInfo *parent, const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_, WidgetType w
- )
- : ConfigOption(var,cfg,value,short_,long_,
- "QCString","String","writeStringValue"
- ),
- m_parent(parent),
- m_widgetType(w)
- {
- }
-
- static void add(const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_,WidgetType w=String);
- static void addFixedValue(const char *var, const char *value);
-
- virtual void printRules(QTextStream &t)
- {
- t << "<Start>\"" << cfgName << "\"[ \\t]*\"=\"";
- t << spaces.left(MAX_OPTION_LENGTH-cfgName.length());
- t << "{ BEGIN(GetString); s=&Config::" << varName;
- t << "; s->resize(0); }" << endl;
- }
- virtual void printInit(QTextStream &t)
- {
- t << " Config::" << varName;
- if (!defaultValue.isEmpty()) t << " = \"" << defaultValue << "\"";
- else t << ".resize(0)";
- t << ";" << endl;
- }
- virtual void printDump(QTextStream &t)
- {
- t << " printf(\"" << varName << "=`%s'\\n\",Config::" << varName << ".data());" << endl;
- }
- virtual void printSubstEnv(QTextStream &t)
- {
- t << " substEnvVarsInString( Config::" << varName << " );" << endl;
- }
- virtual void printWidgets(QTextStream &t,int pass)
- {
- switch (pass)
- {
- case 0:
- {
- t << " " << varName << " = new InputString( \"" << cfgName
- << "\", " << m_parent->getVarName() << ", Config::" << varName;
- if (m_widgetType!=String || m_values.count()>0)
- {
- t << ",";
- switch (m_widgetType)
- {
- case File:
- t << "InputString::StringFile";
- break;
- case Dir:
- t << "InputString::StringDir";
- break;
- default:
- t << "InputString::StringFixed";
- break;
- }
- }
-
- t << " );" << endl;
- t << " QWhatsThis::add(" << varName << ", " << endl;
- stringToC(t,longDesc," \"","\"");
- t << " );" << endl;
- t << " connect(" << varName
- << ",SIGNAL(changed()),this,SIGNAL(changed()));" << endl;
- if (m_values.count()>0)
- {
- char *s = m_values.first();
- while (s)
- {
- t << " " << varName << "->addValue(\"" << s << "\");" << endl;
- s = m_values.next();
- }
- }
- }
- break;
- case 2:
- {
- t << " InputString *" << varName << ";" << endl;
- }
- break;
- case 5:
- {
- t << " " << varName << "->init();" << endl;
- }
- break;
- default:
- break;
- }
- }
- void addValue(const char *val)
- {
- m_values.append(val);
- }
- private:
- ConfigInfo *m_parent;
- WidgetType m_widgetType;
- QStrList m_values;
-};
-
-class ConfigInt : public ConfigOption
-{
- public:
- ConfigInt(ConfigInfo *parent,const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_,int minVal,int maxVal)
- : ConfigOption(var,cfg,value,short_,long_,"int ","Int","writeIntValue"),
- m_parent(parent), m_minVal(minVal), m_maxVal(maxVal)
- {
- }
- static void add(const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_,int minVal,int maxVal);
- virtual void printConfig(QTextStream &t)
- {
- t << type << " Config::" << varName;
- if (!defaultValue.isEmpty()) t << " = " << defaultValue;
- t << ";" << endl;
- }
- virtual void printRules(QTextStream &t)
- {
- t << "<Start>\"" << cfgName << "\"[ \\t]*\"=\"";
- t << spaces.left(MAX_OPTION_LENGTH-cfgName.length());
- t << "{ BEGIN(GetString); s=&" << varName;
- t << "String; s->resize(0); }" << endl;
- }
- virtual void printStatic(QTextStream &t)
- {
- t << "static QCString " << varName << "String;" << endl;
- }
- virtual void printDump(QTextStream &t)
- {
- t << " printf(\"" << varName << "=`%d'\\n\",Config::" << varName << ");" << endl;
- }
- virtual void printWidgets(QTextStream &t,int pass)
- {
- switch (pass)
- {
- case 0:
- {
- t << " " << varName << " = new InputInt( \"" << cfgName
- << "\", " << m_parent->getVarName() << ", Config::"
- << varName << "," << m_minVal << "," << m_maxVal << " );" << endl;
- t << " QWhatsThis::add(" << varName << ", " << endl;
- stringToC(t,longDesc," \"","\"");
- t << " );" << endl;
- t << " connect(" << varName
- << ",SIGNAL(changed()),this,SIGNAL(changed()));" << endl;
- }
- break;
- case 2:
- {
- t << " InputInt *" << varName << ";" << endl;
- }
- break;
- case 5:
- {
- t << " " << varName << "->init();" << endl;
- }
- break;
- default:
- break;
- }
- }
- private:
- ConfigInfo *m_parent;
- int m_minVal;
- int m_maxVal;
-};
-
-class ConfigBool : public ConfigOption
-{
- public:
- ConfigBool(ConfigInfo *parent,const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_)
- : ConfigOption(var,cfg,value,short_,long_,"bool ","Bool","writeBoolValue"),
- m_parent(parent) {}
- static void add(const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_);
- virtual void printConfig(QTextStream &t)
- {
- t << type << " Config::" << varName;
- if (!defaultValue.isEmpty()) t << " = " << defaultValue;
- t << ";" << endl;
- }
- virtual void printRules(QTextStream &t)
- {
- t << "<Start>\"" << cfgName << "\"[ \\t]*\"=\"";
- t << spaces.left(MAX_OPTION_LENGTH-cfgName.length());
- t << "{ BEGIN(GetBool); b=&Config::" << varName;
- t << "; }" << endl;
- }
- virtual void printDump(QTextStream &t)
- {
- t << " printf(\"" << varName << "=`%d'\\n\",Config::" << varName << ");" << endl;
- }
- virtual void printWidgets(QTextStream &t,int pass)
- {
- switch (pass)
- {
- case 0:
- {
- t << " " << varName << " = new InputBool( \"" << cfgName
- << "\", " << m_parent->getVarName() << ", Config::" << varName << " );" << endl;
- t << " QWhatsThis::add(" << varName << ", " << endl;
- stringToC(t,longDesc," \"","\"");
- t << " );" << endl;
- t << " connect(" << varName
- << ",SIGNAL(changed()),this,SIGNAL(changed()));" << endl;
- if (dependencies.count()>0)
- {
- t << " connect(" << varName << ",SIGNAL(toggled(bool)),SLOT("
- << varName << "Toggle(bool)));" << endl;
- }
- }
- break;
- case 1:
- {
- if (dependencies.count()>0)
- {
- t << " " << varName << "Toggle(Config::" << varName << ");" << endl;
- }
- }
- break;
- case 2:
- {
- t << " InputBool *" << varName << ";" << endl;
- }
- break;
- case 3:
- {
- if (dependencies.count()>0)
- {
- t << " void " << varName << "Toggle(bool);" << endl;
- }
- }
- break;
- case 4:
- {
- if (dependencies.count()>0)
- {
- t << "void ConfigFile::" << varName << "Toggle(bool state)" << endl;
- t << "{" << endl;
- ConfigOption *o=dependencies.first();
- while (o)
- {
- t << " " << o->getVarName() << "->setEnabled(state);" << endl;
- o=dependencies.next();
- }
- t << "}" << endl << endl;
- }
- }
- break;
- case 5:
- {
- t << " " << varName << "->init();" << endl;
- }
- default:
- break;
- }
- }
- virtual void addDependency(ConfigOption *o)
- {
- dependencies.append(o);
- }
- private:
- ConfigInfo *m_parent;
- QList<ConfigOption> dependencies;
-};
-
-static ConfigInfo *g_lastConfigInfo;
-
-void ConfigList::add(const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_,WidgetType w)
-{
- ConfigOption* o=new ConfigList(g_lastConfigInfo,var,cfg,value,short_,long_,w);
- ASSERT(o!=0);
- ASSERT(g_lastConfigInfo!=0);
- //optionList.append(o);
-}
-
-void ConfigString::add(const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_,WidgetType w)
-{
- ConfigOption* o=new ConfigString(g_lastConfigInfo,var,cfg,value,short_,long_,w);
- ASSERT(o!=0);
- ASSERT(g_lastConfigInfo!=0);
- //optionList.append(o);
-}
-
-void ConfigInt::add(const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_,int minVal, int maxVal)
-{
- ConfigOption* o=new ConfigInt(g_lastConfigInfo,var,cfg,value,
- short_,long_,minVal,maxVal);
- ASSERT(o!=0);
- ASSERT(g_lastConfigInfo!=0);
- //optionList.append(o);
-}
-
-void ConfigBool::add(const char * var,const char * cfg,const char * value,
- const char * short_,const char * long_)
-{
- ConfigOption* o=new ConfigBool(g_lastConfigInfo,var,cfg,value,short_,long_);
- ASSERT(o!=0);
- ASSERT(g_lastConfigInfo!=0);
- //optionList.append(o);
-}
-
-void ConfigInfo::add(const char * var,const char * short_)
-{
- g_lastConfigInfo =new ConfigInfo(var,short_);
- ASSERT(g_lastConfigInfo!=0);
- //optionList.append(g_lastConfigInfo);
-}
-
-void ConfigString::addFixedValue(const char *var, const char *value)
-{
- ConfigString *cs = (ConfigString *)optionDict[var];
- if (cs==0)
- {
- fprintf(stderr,"ConfigString::addFixedValue: unknown variable %s\n",var);
- }
- else
- {
- cs->addValue(value);
- }
-}
-
-
-int main(int argc,char * argv[])
-{
- // check arguments
- if (argc!=2)
- {
- fprintf(stderr,"usage: %s config-template\n",argv[0]);
- exit(1);
- }
-
- init(); // create options
- QFile ctfile(argv[1]);
-
- // open template file
- if (!ctfile.open(IO_ReadOnly))
- {
- fprintf(stderr,"Error: couldn´t open file %s\n",argv[1]);
- exit(1);
- }
- const int maxLineLen=10000;
- char buf[maxLineLen];
-
- QFile f;
- f.open(IO_WriteOnly,stdout);
- QTextStream t(&f);
-
- t << "/* This file was generated by configgen on "
- << QDateTime::currentDateTime().toString()
- << "\n * from " << argv[1] << "\n *\n * DO NOT EDIT!\n */\n\n";
-
- // process template file
- while (!ctfile.atEnd())
- {
- int l = ctfile.readLine(buf,maxLineLen-1);
- if (l>1 && buf[l-2]=='\r') // remove the \r for the folks using Windows
- {
- buf[l-2]='\n';
- buf[l-1]='\r';
- }
- if (QCString("#CONFIG Config\n" )==buf) FORALL(printConfig(t))
- else if (QCString("#CONFIG Static\n" )==buf) FORALL(printStatic(t))
- else if (QCString("#CONFIG Rules\n" )==buf) FORALL(printRules(t))
- else if (QCString("#CONFIG Dump\n" )==buf) FORALL(printDump(t))
- else if (QCString("#CONFIG Init\n" )==buf) FORALL(printInit(t))
- else if (QCString("#CONFIG Template\n")==buf) FORALL(printTemplate(t))
- else if (QCString("#CONFIG Check\n" )==buf) FORALL(printCheck(t))
- else if (QCString("#CONFIG Header\n" )==buf) FORALL(printHeader(t))
- else if (QCString("#CONFIG Substenv\n")==buf) FORALL(printSubstEnv(t))
- else if (QCString("#CONFIG Widgets0\n" )==buf) FORALL(printWidgets(t,0))
- else if (QCString("#CONFIG Widgets1\n" )==buf) FORALL(printWidgets(t,1))
- else if (QCString("#CONFIG WidgetVars\n" )==buf) FORALL(printWidgets(t,2))
- else if (QCString("#CONFIG WidgetSlots\n" )==buf) FORALL(printWidgets(t,3))
- else if (QCString("#CONFIG WidgetSlotImpl\n" )==buf) FORALL(printWidgets(t,4))
- else if (QCString("#CONFIG WidgetInit\n" )==buf) FORALL(printWidgets(t,5))
- else t << buf;
- }
- ctfile.close();
- return 0;
-}
-
-void init()
-{
- // option definitions
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add("General","General configuration options");
- //-----------------------------------------------------------------------------------------------
-
- ConfigString::add("projectName",
- "PROJECT_NAME",
- "",
- "the name of the project",
- "The PROJECT_NAME tag is a single word (or a sequence of words surrounded \n"
- "by quotes) that should identify the project. "
- );
- ConfigString::add("projectNumber",
- "PROJECT_NUMBER",
- "",
- "the number of the project",
- "The PROJECT_NUMBER tag can be used to enter a project or revision number. \n"
- "This could be handy for archiving the generated documentation or \n"
- "if some version control system is used.\n"
- );
- ConfigString::add("outputDir",
- "OUTPUT_DIRECTORY",
- "",
- "the global output directory",
- "The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) \n"
- "base path where the generated documentation will be put. \n"
- "If a relative path is entered, it will be relative to the location \n"
- "where doxygen was started. If left blank the current directory will be used.\n",
- ConfigString::Dir
- );
- ConfigString::add("outputLanguage",
- "OUTPUT_LANGUAGE",
- "English",
- "the output language",
- "The OUTPUT_LANGUAGE tag is used to specify the language in which all \n"
- "documentation generated by doxygen is written. Doxygen will use this \n"
- "information to generate all constant output in the proper language. \n"
- "The default language is English, other supported languages are: \n"
- "Dutch, French, Italian, Czech, Swedish, German, Finnish, Japanese, \n"
- "Korean, Hungarian, Norwegian, Spanish, Romanian, Russian, Croatian, \n"
- "Polish, Portuguese and Slovene.\n"
- );
- ConfigString::addFixedValue("outputLanguage","Croatian");
- ConfigString::addFixedValue("outputLanguage","Czech");
- ConfigString::addFixedValue("outputLanguage","Dutch");
- ConfigString::addFixedValue("outputLanguage","English");
- ConfigString::addFixedValue("outputLanguage","French");
- ConfigString::addFixedValue("outputLanguage","Finnish");
- ConfigString::addFixedValue("outputLanguage","German");
- ConfigString::addFixedValue("outputLanguage","Hungarian");
- ConfigString::addFixedValue("outputLanguage","Italian");
- ConfigString::addFixedValue("outputLanguage","Japanese");
- ConfigString::addFixedValue("outputLanguage","Korean");
- ConfigString::addFixedValue("outputLanguage","Norwegian");
- ConfigString::addFixedValue("outputLanguage","Romanian");
- ConfigString::addFixedValue("outputLanguage","Russian");
- ConfigString::addFixedValue("outputLanguage","Polish");
- ConfigString::addFixedValue("outputLanguage","Portuguese");
- ConfigString::addFixedValue("outputLanguage","Slovene");
- ConfigString::addFixedValue("outputLanguage","Spanish");
- ConfigString::addFixedValue("outputLanguage","Swedish");
- ConfigBool::add( "extractAllFlag",
- "EXTRACT_ALL",
- "FALSE",
- "generate docs for all classes flag",
- "If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in \n"
- "documentation are documented, even if no documentation was available. \n"
- "Private class members and static file members will be hidden unless \n"
- "the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES \n"
- );
- ConfigBool::add( "extractPrivateFlag",
- "EXTRACT_PRIVATE",
- "FALSE",
- "generate docs for private members flag",
- "If the EXTRACT_PRIVATE tag is set to YES all private members of a class \n"
- "will be included in the documentation. \n"
- );
- ConfigBool::add( "extractStaticFlag",
- "EXTRACT_STATIC",
- "FALSE",
- "generate docs for static members flag",
- "If the EXTRACT_STATIC tag is set to YES all static members of a file \n"
- "will be included in the documentation. \n"
- );
- ConfigBool::add( "hideMemberFlag",
- "HIDE_UNDOC_MEMBERS",
- "FALSE",
- "hide undocumented members.",
- "If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all \n"
- "undocumented members of documented classes, files or namespaces. \n"
- "If set to NO (the default) these members will be included in the \n"
- "various overviews, but no documentation section is generated. \n"
- "This option has no effect if EXTRACT_ALL is enabled. \n"
- );
- ConfigBool::add( "hideClassFlag",
- "HIDE_UNDOC_CLASSES",
- "FALSE",
- "hide undocumented members.",
- "If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all \n"
- "undocumented classes that are normally visible in the class hierarchy. \n"
- "If set to NO (the default) these class will be included in the various \n"
- "overviews. This option has no effect if EXTRACT_ALL is enabled. \n"
- );
- ConfigBool::add( "briefMemDescFlag",
- "BRIEF_MEMBER_DESC",
- "TRUE",
- "enable `inline' brief member descr.",
- "If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will \n"
- "include brief member descriptions after the members that are listed in \n"
- "the file and class documentation (similar to JavaDoc). \n"
- "Set to NO to disable this. \n"
- );
- ConfigBool::add( "repeatBriefFlag",
- "REPEAT_BRIEF",
- "TRUE",
- "repeat brief descriptions.",
- "If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend \n"
- "the brief description of a member or function before the detailed description. \n"
- "Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the \n"
- "brief descriptions will be completely suppressed. \n"
- );
- ConfigBool::add( "alwaysDetailsFlag",
- "ALWAYS_DETAILED_SEC",
- "FALSE",
- "show details description even if there is only a brief description?",
- "If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then \n"
- "Doxygen will generate a detailed section even if there is only a brief \n"
- "description. \n"
- );
- ConfigBool::add( "fullPathNameFlag",
- "FULL_PATH_NAMES",
- "FALSE",
- "using full path name in output",
- "If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full \n"
- "path before files name in the file list and in the header files. If set \n"
- "to NO the shortest path that makes the file name unique will be used. \n"
- );
- ConfigList::add( "stripFromPath",
- "STRIP_FROM_PATH",
- "",
- "list of candidates to strip from the file path",
- "If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag \n"
- "can be used to strip a user defined part of the path. Stripping is \n"
- "only done if one of the specified strings matches the left-hand part of \n"
- "the path. It is allowed to use relative paths in the argument list.\n"
- );
- addDependency("stripFromPath","fullPathNameFlag");
- ConfigBool::add( "internalDocsFlag",
- "INTERNAL_DOCS",
- "FALSE",
- "determines what happens to internal docs.",
- "The INTERNAL_DOCS tag determines if documentation \n"
- "that is typed after a \\internal command is included. If the tag is set \n"
- "to NO (the default) then the documentation will be excluded. \n"
- "Set it to YES to include the internal documentation. \n"
- );
- ConfigBool::add( "classDiagramFlag",
- "CLASS_DIAGRAMS",
- "TRUE",
- "enable the generation of class diagrams.",
- "If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will \n"
- "generate a class diagram (in Html and LaTeX) for classes with base or \n"
- "super classes. Setting the tag to NO turns the diagrams off. \n"
- );
- ConfigBool::add( "sourceBrowseFlag",
- "SOURCE_BROWSER",
- "FALSE",
- "include source code in documentation.",
- "If the SOURCE_BROWSER tag is set to YES then a list of source files will \n"
- "be generated. Documented entities will be cross-referenced with these sources. \n"
- );
- ConfigBool::add( "inlineSourceFlag",
- "INLINE_SOURCES",
- "FALSE",
- "inline the definition bodies in the docs?",
- "Setting the INLINE_SOURCES tag to YES will include the body \n"
- "of functions and classes directly in the documentation. \n"
- );
- ConfigBool::add( "stripCommentsFlag",
- "STRIP_CODE_COMMENTS",
- "TRUE",
- "strip special comments from code fragments?",
- "Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct \n"
- "doxygen to hide any special comment blocks from generated source code \n"
- "fragments. Normal C and C++ comments will always remain visible. \n"
- );
- ConfigBool::add( "caseSensitiveNames",
- "CASE_SENSE_NAMES",
- "TRUE",
- "determines if output can be mixed case.",
- "If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate \n"
- "file names in lower case letters. If set to YES upper case letters are also \n"
- "allowed. This is useful if you have classes or files whose names only differ \n"
- "in case and if your file system supports case sensitive file names. Windows \n"
- "users are adviced to set this option to NO.\n"
- );
- ConfigBool::add( "hideScopeNames",
- "HIDE_SCOPE_NAMES",
- "FALSE",
- "hide the name of the scope.",
- "If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen \n"
- "will show members with their full class and namespace scopes in the \n"
- "documentation. If set to YES the scope will be hidden. \n"
- );
- ConfigBool::add( "verbatimHeaderFlag",
- "VERBATIM_HEADERS",
- "TRUE",
- "enable/disable generation of verb headers.",
- "If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen \n"
- "will generate a verbatim copy of the header file for each class for \n"
- "which an include is specified. Set to NO to disable this. \n"
- );
- ConfigBool::add( "showIncFileFlag",
- "SHOW_INCLUDE_FILES",
- "TRUE",
- "show include file in file documentation?",
- "If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen \n"
- "will put list of the files that are included by a file in the documentation \n"
- "of that file. \n"
- );
- ConfigBool::add( "autoBriefFlag",
- "JAVADOC_AUTOBRIEF",
- "FALSE",
- "should javadoc comments behaves as Qt comments.",
- "If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen \n"
- "will interpret the first line (until the first dot) of a JavaDoc-style \n"
- "comment as the brief description. If set to NO, the JavaDoc \n"
- "comments will behave just like the Qt-style comments (thus requiring an \n"
- "explict @brief command for a brief description. \n"
- );
- ConfigBool::add( "inheritDocsFlag",
- "INHERIT_DOCS",
- "TRUE",
- "inheritance of documentation enabled?",
- "If the INHERIT_DOCS tag is set to YES (the default) then an undocumented \n"
- "member inherits the documentation from any documented member that it \n"
- "reimplements. \n"
- );
- ConfigBool::add( "inlineInfoFlag",
- "INLINE_INFO",
- "TRUE",
- "show info about inline members?",
- "If the INLINE_INFO tag is set to YES (the default) then a tag [inline] \n"
- "is inserted in the documentation for inline members. \n"
- );
- ConfigBool::add( "sortMembersFlag",
- "SORT_MEMBER_DOCS",
- "TRUE",
- "sort members alphabetically?",
- "If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen \n"
- "will sort the (detailed) documentation of file and class members \n"
- "alphabetically by member name. If set to NO the members will appear in \n"
- "declaration order. \n"
- );
- ConfigBool::add( "distributeDocFlag",
- "DISTRIBUTE_GROUP_DOC",
- "FALSE",
- "distribute docs over member group?",
- "If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC \n"
- "tag is set to YES, then doxygen will reuse the documentation of the first \n"
- "member in the group (if any) for the other members of the group. By default \n"
- "all members of a group must be documented explicitly.\n"
- );
- ConfigInt::add( "tabSize",
- "TAB_SIZE",
- "8",
- "number of spaces in a tab",
- "The TAB_SIZE tag can be used to set the number of spaces in a tab. \n"
- "Doxygen uses this value to replace tabs by spaces in code fragments. \n",
- 1,16
- );
- ConfigList::add( "sectionFilterList",
- "ENABLED_SECTIONS",
- "",
- "list of section filters that are enabled",
- "The ENABLE_SECTIONS tag can be used to enable conditional \n"
- "documentation sections, marked by \\if sectionname ... \\endif. \n"
- );
- ConfigBool::add( "generateTodoList",
- "GENERATE_TODOLIST",
- "TRUE",
- "do we want a todo list?",
- "The GENERATE_TODOLIST tag can be used to enable (YES) or \n"
- "disable (NO) the todo list. This list is created by putting \\todo \n"
- "commands in the documentation.\n"
- );
- ConfigBool::add( "generateTestList",
- "GENERATE_TESTLIST",
- "TRUE",
- "do we want a test list?",
- "The GENERATE_TESTLIST tag can be used to enable (YES) or \n"
- "disable (NO) the test list. This list is created by putting \\test \n"
- "commands in the documentation.\n"
- );
- ConfigBool::add( "generateBugList",
- "GENERATE_BUGLIST",
- "TRUE",
- "do we want a bug list?",
- "The GENERATE_BUGLIST tag can be used to enable (YES) or \n"
- "disable (NO) the bug list. This list is created by putting \\bug \n"
- "commands in the documentation.\n"
- );
- ConfigList::add( "aliasList",
- "ALIASES",
- "",
- "list of aliases",
- "This tag can be used to specify a number of aliases that acts \n"
- "as commands in the documentation. An alias has the form \"name=value\". \n"
- "For example adding \"sideeffect=\\par Side Effects:\\n\" will allow you to \n"
- "put the command \\sideeffect (or @sideeffect) in the documentation, which \n"
- "will result in a user defined paragraph with heading \"Side Effects:\". \n"
- "You can put \\n's in the value part of an alias to insert newlines. \n"
- );
- ConfigInt::add( "maxInitLines",
- "MAX_INITIALIZER_LINES",
- "30",
- "when do we hide values of variable and defines?",
- "The MAX_INITIALIZER_LINES tag determines the maximum number of lines \n"
- "the initial value of a variable or define consist of for it to appear in \n"
- "the documentation. If the initializer consists of more lines than specified \n"
- "here it will be hidden. Use a value of 0 to hide initializers completely. \n"
- "The appearance of the initializer of individual variables and defines in the \n"
- "documentation can be controlled using \\showinitializer or \\hideinitializer \n"
- "command in the documentation regardless of this setting. \n",
- 0,10000
- );
- ConfigBool::add( "optimizeForCFlag",
- "OPTIMIZE_OUTPUT_FOR_C",
- "FALSE",
- "do we parse C code?",
- "Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources \n"
- "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"
- "of all members will be omitted, etc. \n"
- );
- ConfigBool::add( "showUsedFilesFlag",
- "SHOW_USED_FILES",
- "TRUE",
- "do we show the list of used files for classes and structs?",
- "Set the SHOW_USED_FILES tag to NO to disable the list of files generated \n"
- "at the bottom of the documentation of classes and structs. If set to YES the \n"
- "list will mention the files that were used to generate the documentation. \n"
- );
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "Messages","configuration options related to warning and progress messages");
- //-----------------------------------------------------------------------------------------------
- ConfigBool::add( "quietFlag",
- "QUIET",
- "FALSE",
- "generate progress messages flag",
- "The QUIET tag can be used to turn on/off the messages that are generated \n"
- "by doxygen. Possible values are YES and NO. If left blank NO is used. \n"
- );
- ConfigBool::add( "warningFlag",
- "WARNINGS",
- "TRUE",
- "generate warnings flag",
- "The WARNINGS tag can be used to turn on/off the warning messages that are \n"
- "generated by doxygen. Possible values are YES and NO. If left blank \n"
- "NO is used. \n"
- );
- ConfigBool::add( "warningUndocFlag",
- "WARN_IF_UNDOCUMENTED",
- "TRUE",
- "generate undocumented warnings",
- "If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings \n"
- "for undocumented members. If EXTRACT_ALL is set to YES then this flag will \n"
- "automatically be disabled. \n"
- );
- ConfigString::add("warnFormat",
- "WARN_FORMAT",
- "$file:$line: $text",
- "format of the warning messages",
- "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"
- "tags, which will be replaced by the file and line number from which the \n"
- "warning originated and the warning text. \n"
- );
- ConfigString::add("warnLogFile",
- "WARN_LOGFILE",
- "",
- "log file to write warning to",
- "The WARN_LOGFILE tag can be used to specify a file to which warning \n"
- "and error messages should be written. If left blank the output is written \n"
- "to stderr. \n"
- );
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "Input","configuration options related to the input files");
- //-----------------------------------------------------------------------------------------------
- ConfigList::add( "inputSources",
- "INPUT",
- "",
- "list of input files",
- "The INPUT tag can be used to specify the files and/or directories that contain \n"
- "documented source files. You may enter file names like \"myfile.cpp\" or \n"
- "directories like \"/usr/src/myproject\". Separate the files or directories \n"
- "with spaces. \n",
- ConfigList::FileAndDir
- );
- ConfigList::add( "filePatternList",
- "FILE_PATTERNS",
- "",
- "list of file patterns",
- "If the value of the INPUT tag contains directories, you can use the \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"
- "blank all files are included. \n"
- );
- ConfigBool::add( "recursiveFlag",
- "RECURSIVE",
- "FALSE",
- "scan directories recursively",
- "The RECURSIVE tag can be used to turn specify whether or not subdirectories \n"
- "should be searched for input files as well. Possible values are YES and NO. \n"
- "If left blank NO is used. \n"
- );
- ConfigList::add( "excludeSources",
- "EXCLUDE",
- "",
- "list of files to exclude from the input",
- "The EXCLUDE tag can be used to specify files and/or directories that should \n"
- "excluded from the INPUT source files. This way you can easily exclude a \n"
- "subdirectory from a directory tree whose root is specified with the INPUT tag. \n",
- ConfigList::FileAndDir
- );
- ConfigList::add( "excludePatternList",
- "EXCLUDE_PATTERNS",
- "",
- "list of patterns to exclude from input",
- "If the value of the INPUT tag contains directories, you can use the \n"
- "EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude \n"
- "certain files from those directories. \n"
- );
- ConfigList::add( "examplePath",
- "EXAMPLE_PATH",
- "",
- "list of example paths",
- "The EXAMPLE_PATH tag can be used to specify one or more files or \n"
- "directories that contain example code fragments that are included (see \n"
- "the \\include command). \n",
- ConfigList::Dir
- );
- ConfigList::add( "examplePatternList",
- "EXAMPLE_PATTERNS",
- "",
- "list of example patterns",
- "If the value of the EXAMPLE_PATH tag contains directories, you can use the \n"
- "EXAMPLE_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"
- "blank all files are included. \n"
- );
- ConfigList::add( "imagePath",
- "IMAGE_PATH",
- "",
- "list of image paths",
- "The IMAGE_PATH tag can be used to specify one or more files or \n"
- "directories that contain image that are included in the documentation (see \n"
- "the \\image command). \n",
- ConfigList::Dir
- );
- ConfigString::add("inputFilter",
- "INPUT_FILTER",
- "",
- "a filter command that is applied to input files",
- "The INPUT_FILTER tag can be used to specify a program that doxygen should \n"
- "invoke to filter for each input file. Doxygen will invoke the filter program \n"
- "by executing (via popen()) the command <filter> <input-file>, where <filter> \n"
- "is the value of the INPUT_FILTER tag, and <input-file> is the name of an \n"
- "input file. Doxygen will then use the output that the filter program writes \n"
- "to standard output. \n",
- ConfigString::File
- );
- ConfigBool::add( "filterForSourceFlag",
- "FILTER_SOURCE_FILES",
- "FALSE",
- "do we filter source files?",
- "If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using \n"
- "INPUT_FILTER) will be used to filter the input files when producing source \n"
- "files to browse. \n"
- );
-
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "Index","configuration options related to the alphabetical class index");
- //-----------------------------------------------------------------------------------------------
-
- ConfigBool::add( "alphaIndexFlag",
- "ALPHABETICAL_INDEX",
- "FALSE",
- "should an alphabetical index be generated?",
- "If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index \n"
- "of all compounds will be generated. Enable this if the project \n"
- "contains a lot of classes, structs, unions or interfaces. \n"
- );
- ConfigInt::add( "colsInAlphaIndex",
- "COLS_IN_ALPHA_INDEX",
- "5",
- "number of columns in the alphabetical index",
- "If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then \n"
- "the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns \n"
- "in which this list will be split (can be a number in the range [1..20]) \n",
- 1,20
- );
- ConfigList::add( "ignorePrefixList",
- "IGNORE_PREFIX",
- "",
- "list of prefixes to ignore for the alphabetical index",
- "In case all classes in a project start with a common prefix, all \n"
- "classes will be put under the same header in the alphabetical index. \n"
- "The IGNORE_PREFIX tag can be used to specify one or more prefixes that \n"
- "should be ignored while generating the index headers. \n"
- );
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "HTML","configuration options related to the HTML output");
- //-----------------------------------------------------------------------------------------------
- ConfigBool::add( "generateHtml",
- "GENERATE_HTML",
- "TRUE",
- "generate HTML output",
- "If the GENERATE_HTML tag is set to YES (the default) Doxygen will \n"
- "generate HTML output. \n"
- );
- ConfigString::add("htmlOutputDir",
- "HTML_OUTPUT",
- "html",
- "the directory to put the HTML files",
- "The HTML_OUTPUT tag is used to specify where the HTML docs will be put. \n"
- "If a relative path is entered the value of OUTPUT_DIRECTORY will be \n"
- "put in front of it. If left blank `html' will be used as the default path. \n",
- ConfigString::Dir
- );
- addDependency("htmlOutputDir","generateHtml");
- ConfigString::add("headerFile",
- "HTML_HEADER",
- "",
- "the name of the personal HTML header",
- "The HTML_HEADER tag can be used to specify a personal HTML header for \n"
- "each generated HTML page. If it is left blank doxygen will generate a \n"
- "standard header.\n",
- ConfigString::File
- );
- addDependency("headerFile","generateHtml");
- ConfigString::add("footerFile",
- "HTML_FOOTER",
- "",
- "the name of the personal HTML footer",
- "The HTML_FOOTER tag can be used to specify a personal HTML footer for \n"
- "each generated HTML page. If it is left blank doxygen will generate a \n"
- "standard footer.\n",
- ConfigString::File
- );
- addDependency("footerFile","generateHtml");
- ConfigString::add("htmlStyleSheet",
- "HTML_STYLESHEET",
- "",
- "user defined cascading style sheet",
- "The HTML_STYLESHEET tag can be used to specify a user defined cascading \n"
- "style sheet that is used by each HTML page. It can be used to \n"
- "fine-tune the look of the HTML output. If the tag is left blank doxygen \n"
- "will generate a default style sheet \n",
- ConfigString::File
- );
- addDependency("htmlStyleSheet","generateHtml");
- ConfigBool::add( "htmlAlignMemberFlag",
- "HTML_ALIGN_MEMBERS",
- "TRUE",
- "align members in HTML using tables.",
- "If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, \n"
- "files or namespaces will be aligned in HTML using tables. If set to \n"
- "NO a bullet list will be used. \n"
- );
- addDependency("htmlAlignMemberFlag","generateHtml");
- ConfigBool::add( "htmlHelpFlag",
- "GENERATE_HTMLHELP",
- "FALSE",
- "should html help files be generated?",
- "If the GENERATE_HTMLHELP tag is set to YES, additional index files \n"
- "will be generated that can be used as input for tools like the \n"
- "Microsoft HTML help workshop to generate a compressed HTML help file (.chm) \n"
- "of the generated HTML documentation. \n"
- );
- addDependency("htmlHelpFlag","generateHtml");
- ConfigBool::add( "htmlHelpChiFlag",
- "GENERATE_CHI",
- "FALSE",
- "should chi file be generated?",
- "If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag \n"
- "controls if a separate .chi index file is generated (YES) or that \n"
- "it should be included in the master .chm file (NO).\n"
- );
- addDependency("htmlHelpChiFlag","generateHtml");
- ConfigBool::add( "htmlHelpTocFlag",
- "BINARY_TOC",
- "FALSE",
- "should a binary table of contents be generated?",
- "If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag \n"
- "controls whether a binary table of contents is generated (YES) or a \n"
- "normal table of contents (NO) in the .chm file.\n"
- );
- addDependency("htmlHelpTocFlag","generateHtml");
- ConfigBool::add( "htmlHelpTocExpandFlag",
- "TOC_EXPAND",
- "FALSE",
- "should module elements be displayed in the table of contents?",
- "The TOC_EXPAND flag can be set YES to add extra items for group members \n"
- "to the contents of the Html help documentation and to the tree view. \n"
- );
- addDependency("htmlHelpTocExpandFlag","generateHtml");
- ConfigBool::add( "noIndexFlag",
- "DISABLE_INDEX",
- "FALSE",
- "generate condensed index flag",
- "The DISABLE_INDEX tag can be used to turn on/off the condensed index at \n"
- "top of each HTML page. The value NO (the default) enables the index and \n"
- "the value YES disables it. \n"
- );
- addDependency("noIndexFlag","generateHtml");
- ConfigInt::add( "enumValuesPerLine",
- "ENUM_VALUES_PER_LINE",
- "4",
- "number of enum values that are put on one line",
- "This tag can be used to set the number of enum values (range [1..20]) \n"
- "that doxygen will group on one line in the generated HTML documentation. \n",
- 1,20
- );
- addDependency("enumValuesPerLine","generateHtml");
- ConfigBool::add( "ftvHelpFlag",
- "GENERATE_TREEVIEW",
- "FALSE",
- "should a folder tree view be generated?",
- "If the GENERATE_TREEVIEW tag is set to YES, a side panel will be\n"
- "generated containing a tree-like index structure (just like the one that \n"
- "is generated for HTML Help). For this to work a browser that supports \n"
- "JavaScript and frames is required (for instance Netscape 4.0+ \n"
- "or Internet explorer 4.0+). "
- );
- addDependency("ftvHelpFlag","generateHtml");
- ConfigInt::add( "treeViewWidth",
- "TREEVIEW_WIDTH",
- "250",
- "What is the width of the treeview panel?",
- "If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be \n"
- "used to set the initial width (in pixels) of the frame in which the tree \n"
- "is shown. \n",
- 0,1500
- );
- addDependency("treeViewWidth","generateHtml");
-
-// TODO: integrate this option
-// ConfigBool::add( "htmlHelpGroupsOnly",
-// "HTMLHELP_GROUPS_ONLY",
-// "FALSE",
-// "should \\ingroup's be used to create HTML Help hierarchy?",
-// "If the HTMLHELP_GROUPS_ONLY tag is set to YES, documented objects are \n"
-// "displayed in the HTML Help tree if and only if they are \n"
-// "placed in a user-defined group using the \\ingroup markup. \n"
-// "Use \\defgroup to define a group before adding objects to a group. \n"
-// "Also affects FTV Help (see GENERATE_FTVHELP tag). \n"
-// );
-// addDependency("htmlHelpGroupsOnly","generateHtml");
-
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "LaTeX","configuration options related to the LaTeX output");
- //-----------------------------------------------------------------------------------------------
- ConfigBool::add( "generateLatex",
- "GENERATE_LATEX",
- "TRUE",
- "generate Latex output",
- "If the GENERATE_LATEX tag is set to YES (the default) Doxygen will \n"
- "generate Latex output. \n"
- );
- ConfigString::add("latexOutputDir",
- "LATEX_OUTPUT",
- "latex",
- "the directory to put the Latex files",
- "The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. \n"
- "If a relative path is entered the value of OUTPUT_DIRECTORY will be \n"
- "put in front of it. If left blank `latex' will be used as the default path. \n",
- ConfigString::Dir
- );
- addDependency("latexOutputDir","generateLatex");
- ConfigBool::add( "compactLatexFlag",
- "COMPACT_LATEX",
- "FALSE",
- "generate compact LaTeX documentation.",
- "If the COMPACT_LATEX tag is set to YES Doxygen generates more compact \n"
- "LaTeX documents. This may be useful for small projects and may help to \n"
- "save some trees in general. \n"
- );
- addDependency("compactLatexFlag","generateLatex");
- ConfigString::add("paperType",
- "PAPER_TYPE",
- "a4wide",
- "the page type to generate docs for",
- "The PAPER_TYPE tag can be used to set the paper type that is used \n"
- "by the printer. Possible values are: a4, a4wide, letter, legal and \n"
- "executive. If left blank a4wide will be used. \n"
- );
- ConfigString::addFixedValue("paperType","a4");
- ConfigString::addFixedValue("paperType","a4wide");
- ConfigString::addFixedValue("paperType","letter");
- ConfigString::addFixedValue("paperType","legal");
- ConfigString::addFixedValue("paperType","executive");
- addDependency("paperType","generateLatex");
- ConfigList::add( "extraPackageList",
- "EXTRA_PACKAGES",
- "",
- "list of extra LaTeX packages.",
- "The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX \n"
- "packages that should be included in the LaTeX output. \n"
- );
- addDependency("extraPackageList","generateLatex");
- ConfigString::add("latexHeaderFile",
- "LATEX_HEADER",
- "",
- "the name of the personal LaTeX header",
- "The LATEX_HEADER tag can be used to specify a personal LaTeX header for \n"
- "the generated latex document. The header should contain everything until \n"
- "the first chapter. If it is left blank doxygen will generate a \n"
- "standard header. Notice: only use this tag if you know what you are doing! \n",
- ConfigString::File
- );
- addDependency("latexHeaderFile","generateLatex");
- ConfigBool::add( "pdfHyperFlag",
- "PDF_HYPERLINKS",
- "FALSE",
- "generate latex prepared creating hyperlinked pdfs.",
- "If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated \n"
- "is prepared for conversion to pdf (using ps2pdf). The pdf file will \n"
- "contain links (just like the HTML output) instead of page references \n"
- "This makes the output suitable for online browsing using a pdf viewer. \n"
- );
- addDependency("pdfHyperFlag","generateLatex");
- ConfigBool::add( "usePDFLatexFlag",
- "USE_PDFLATEX",
- "FALSE",
- "use pdflatex instead of plain latex",
- "If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of \n"
- "plain latex in the generated Makefile. Set this option to YES to get a \n"
- "higher quality PDF documentation. \n"
- );
- addDependency("usePDFLatexFlag","generateLatex");
- ConfigBool::add( "latexBatchModeFlag",
- "LATEX_BATCHMODE",
- "FALSE",
- "continue after latex errors?",
- "If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\\\batchmode. \n"
- "command to the generated LaTeX files. This will instruct LaTeX to keep \n"
- "running if errors occur, instead of asking the user for help. \n"
- "This option is also used when generating formulas in HTML. \n"
- );
- addDependency("latexBatchModeFlag","generateLatex");
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "RTF","configuration options related to the RTF output");
- //-----------------------------------------------------------------------------------------------
- ConfigBool::add( "generateRTF",
- "GENERATE_RTF",
- "TRUE",
- "generate RTF flag",
- "If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output \n"
- "The RTF output is optimised for Word 97 and may not look very pretty with \n"
- "other RTF readers or editors.\n"
- );
- ConfigString::add("rtfOutputDir",
- "RTF_OUTPUT",
- "rtf",
- "the directory to put the RTF files",
- "The RTF_OUTPUT tag is used to specify where the RTF docs will be put. \n"
- "If a relative path is entered the value of OUTPUT_DIRECTORY will be \n"
- "put in front of it. If left blank `rtf' will be used as the default path. \n",
- ConfigString::Dir
- );
- addDependency("rtfOutputDir","generateRTF");
- ConfigBool::add( "compactRTFFlag",
- "COMPACT_RTF",
- "FALSE",
- "generate more compact RTF",
- "If the COMPACT_RTF tag is set to YES Doxygen generates more compact \n"
- "RTF documents. This may be useful for small projects and may help to \n"
- "save some trees in general. \n"
- );
- addDependency("compactRTFFlag","generateRTF");
- ConfigBool::add( "rtfHyperFlag",
- "RTF_HYPERLINKS",
- "FALSE",
- "generate hyper links in RTF",
- "If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated \n"
- "will contain hyperlink fields. The RTF file will \n"
- "contain links (just like the HTML output) instead of page references. \n"
- "This makes the output suitable for online browsing using a WORD or other. \n"
- "programs which support those fields. \n"
- "Note: wordpad (write) and others do not support links. \n"
- );
- addDependency("rtfHyperFlag","generateRTF");
- ConfigString::add("rtfStylesheetFile",
- "RTF_STYLESHEET_FILE",
- "",
- "file to load stylesheet definitions from",
- "Load stylesheet definitions from file. Syntax is similar to doxygen's \n"
- "config file, i.e. a series of assigments. You only have to provide \n"
- "replacements, missing definitions are set to their default value. \n",
- ConfigString::File
- );
- addDependency("rtfStylesheetFile","generateRTF");
- ConfigString::add("rtfExtensionsFile",
- "RTF_EXTENSIONS_FILE",
- "",
- "file to load rtf extensions from",
- "Set optional variables used in the generation of an rtf document. \n"
- "Syntax is similar to doxygen's config file.\n",
- ConfigString::File
- );
- addDependency("rtfExtensionsFile","generateRTF");
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "Man","configuration options related to the man page output");
- //-----------------------------------------------------------------------------------------------
- ConfigBool::add( "generateMan",
- "GENERATE_MAN",
- "TRUE",
- "generate Man pages",
- "If the GENERATE_MAN tag is set to YES (the default) Doxygen will \n"
- "generate man pages \n"
- );
- ConfigString::add("manOutputDir",
- "MAN_OUTPUT",
- "man",
- "the directory to put the man pages",
- "The MAN_OUTPUT tag is used to specify where the man pages will be put. \n"
- "If a relative path is entered the value of OUTPUT_DIRECTORY will be \n"
- "put in front of it. If left blank `man' will be used as the default path. \n",
- ConfigString::Dir
- );
- addDependency("manOutputDir","generateMan");
- ConfigString::add("manExtension",
- "MAN_EXTENSION",
- ".3",
- "extension the man page files",
- "The MAN_EXTENSION tag determines the extension that is added to \n"
- "the generated man pages (default is the subroutine's section .3) \n"
- );
- addDependency("manExtension","generateMan");
- //-----------------------------------------------------------------------------------------------
- //ConfigInfo::add( "XML","configuration options related to the XML output");
- //-----------------------------------------------------------------------------------------------
- //ConfigBool::add( "generateXML",
- // "GENERATE_XML",
- // "FALSE",
- // "generate XML output",
- // "If the GENERATE_XML tag is set to YES Doxygen will \n"
- // "generate an XML file that captures the structure of \n"
- // "the code including all documentation. Warning: This feature \n"
- // "is still experimental and very incomplete.\n"
- // );
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "Preprocessor","Configuration options related to the preprocessor ");
- //-----------------------------------------------------------------------------------------------
- ConfigBool::add( "preprocessingFlag",
- "ENABLE_PREPROCESSING",
- "TRUE",
- "enable preprocessing",
- "If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will \n"
- "evaluate all C-preprocessor directives found in the sources and include \n"
- "files. \n"
- );
- ConfigBool::add( "macroExpansionFlag",
- "MACRO_EXPANSION",
- "FALSE",
- "expand macros in the source.",
- "If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro \n"
- "names in the source code. If set to NO (the default) only conditional \n"
- "compilation will be performed. Macro expansion can be done in a controlled \n"
- "way by setting EXPAND_ONLY_PREDEF to YES. \n"
- );
- addDependency("macroExpansionFlag","preprocessingFlag");
- ConfigBool::add( "onlyPredefinedFlag",
- "EXPAND_ONLY_PREDEF",
- "FALSE",
- "expand only predefined macros",
- "If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES \n"
- "then the macro expansion is limited to the macros specified with the \n"
- "PREDEFINED and EXPAND_AS_PREDEFINED tags. \n"
- );
- addDependency("onlyPredefinedFlag","preprocessingFlag");
- ConfigBool::add( "searchIncludeFlag",
- "SEARCH_INCLUDES",
- "TRUE",
- "search for included files",
- "If the SEARCH_INCLUDES tag is set to YES (the default) the includes files \n"
- "in the INCLUDE_PATH (see below) will be search if a #include is found. \n"
- );
- addDependency("searchIncludeFlag","preprocessingFlag");
- ConfigList::add( "includePath",
- "INCLUDE_PATH",
- "",
- "list of include paths",
- "The INCLUDE_PATH tag can be used to specify one or more directories that \n"
- "contain include files that are not input files but should be processed by \n"
- "the preprocessor. \n",
- ConfigList::Dir
- );
- addDependency("includePath","preprocessingFlag");
- ConfigList::add( "includeFilePatternList",
- "INCLUDE_FILE_PATTERNS",
- "",
- "list of include file patterns",
- "You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard \n"
- "patterns (like *.h and *.hpp) to filter out the header-files in the \n"
- "directories. If left blank, the patterns specified with FILE_PATTERNS will \n"
- "be used. \n"
- );
- addDependency("includeFilePatternList","preprocessingFlag");
- ConfigList::add( "predefined",
- "PREDEFINED",
- "",
- "list of predefined macro names.",
- "The PREDEFINED tag can be used to specify one or more macro names that \n"
- "are defined before the preprocessor is started (similar to the -D option of \n"
- "gcc). The argument of the tag is a list of macros of the form: name \n"
- "or name=definition (no spaces). If the definition and the = are \n"
- "omitted =1 is assumed. \n"
- );
- addDependency("predefined","preprocessingFlag");
- ConfigList::add( "expandAsDefinedList",
- "EXPAND_AS_DEFINED",
- "",
- "list of defines to expand",
- "If the MACRO_EXPANSION and EXPAND_PREDEF_ONLY tags are set to YES then \n"
- "this tag can be used to specify a list of macro names that should be expanded. \n"
- "The macro definition that is found in the sources will be used. \n"
- "Use the PREDEFINED tag if you want to use a different macro definition. \n"
- );
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "External","Configuration::addtions related to external references ");
- //-----------------------------------------------------------------------------------------------
- ConfigList::add( "tagFileList",
- "TAGFILES",
- "",
- "list of tag files",
- "The TAGFILES tag can be used to specify one or more tagfiles. \n",
- ConfigList::File
- );
- ConfigString::add("genTagFile",
- "GENERATE_TAGFILE",
- "",
- "the tag file to generate",
- "When a file name is specified after GENERATE_TAGFILE, doxygen will create \n"
- "a tag file that is based on the input files it reads. \n",
- ConfigString::File
- );
- ConfigBool::add( "allExtFlag",
- "ALLEXTERNALS",
- "FALSE",
- "include all external classes flag",
- "If the ALLEXTERNALS tag is set to YES all external classes will be listed \n"
- "in the class index. If set to NO only the inherited external classes \n"
- "will be listed. \n"
- );
- ConfigString::add("perlPath",
- "PERL_PATH",
- "/usr/bin/perl",
- "the absolute path to perl",
- "The PERL_PATH should be the absolute path and name of the perl script \n"
- "interpreter (i.e. the result of `which perl'). \n",
- ConfigString::Dir
- );
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "Dot","Configuration options related to the dot tool ");
- //-----------------------------------------------------------------------------------------------
- ConfigBool::add( "haveDotFlag",
- "HAVE_DOT",
- "FALSE",
- "indicates wether or not dot is present",
- "If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is \n"
- "available from the path. This tool is part of Graphviz, a graph visualization \n"
- "toolkit from AT&T and Lucent Bell Labs. The other options in this section \n"
- "have no effect if this option is set to NO (the default) \n"
- );
- ConfigBool::add( "classGraphFlag",
- "CLASS_GRAPH",
- "TRUE",
- "class graph",
- "If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen \n"
- "will generate a graph for each documented class showing the direct and \n"
- "indirect inheritance relations. Setting this tag to YES will force the \n"
- "the CLASS_DIAGRAMS tag to NO.\n"
- );
- addDependency("classGraphFlag","haveDotFlag");
- ConfigBool::add( "collGraphFlag",
- "COLLABORATION_GRAPH",
- "TRUE",
- "collaboration graph",
- "If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen \n"
- "will generate a graph for each documented class showing the direct and \n"
- "indirect implementation dependencies (inheritance, containment, and \n"
- "class references variables) of the class with other documented classes. \n"
- );
- addDependency("collGraphFlag","haveDotFlag");
- ConfigBool::add( "includeGraphFlag",
- "INCLUDE_GRAPH",
- "TRUE",
- "include graph",
- "If the ENABLE_PREPROCESSING, INCLUDE_GRAPH, and HAVE_DOT tags are set to \n"
- "YES then doxygen will generate a graph for each documented file showing \n"
- "the direct and indirect include dependencies of the file with other \n"
- "documented files. \n"
- );
- addDependency("includeGraphFlag","haveDotFlag");
- ConfigBool::add( "includedByGraphFlag",
- "INCLUDED_BY_GRAPH",
- "TRUE",
- "depends on include graph",
- "If the ENABLE_PREPROCESSING, INCLUDED_BY_GRAPH, and HAVE_DOT tags are set to \n"
- "YES then doxygen will generate a graph for each documented header file showing \n"
- "the documented files that directly or indirectly include this file \n"
- );
- addDependency("includedByGraphFlag","haveDotFlag");
- ConfigBool::add( "gfxHierarchyFlag",
- "GRAPHICAL_HIERARCHY",
- "TRUE",
- "flag to enable graphical hierarchy",
- "If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen \n"
- "will graphical hierarchy of all classes instead of a textual one. \n"
- );
- addDependency("gfxHierarchyFlag","haveDotFlag");
- ConfigString::add("dotPath",
- "DOT_PATH",
- "",
- "path to the dot tool",
- "The tag DOT_PATH can be used to specify the path where the dot tool can be \n"
- "found. If left blank, it is assumed the dot tool can be found on the path. \n",
- ConfigString::Dir
- );
- addDependency("dotPath","haveDotFlag");
- ConfigInt::add( "maxDotGraphWidth",
- "MAX_DOT_GRAPH_WIDTH",
- "1024",
- "max dot graph width",
- "The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width \n"
- "(in pixels) of the graphs generated by dot. If a graph becomes larger than \n"
- "this value, doxygen will try to truncate the graph, so that it fits within \n"
- "the specified constraint. Beware that most browsers cannot cope with very \n"
- "large images. \n",
- 100,30000
- );
- addDependency("maxDotGraphWidth","haveDotFlag");
- ConfigInt::add( "maxDotGraphHeight",
- "MAX_DOT_GRAPH_HEIGHT",
- "1024",
- "max dot graph height",
- "The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height \n"
- "(in pixels) of the graphs generated by dot. If a graph becomes larger than \n"
- "this value, doxygen will try to truncate the graph, so that it fits within \n"
- "the specified constraint. Beware that most browsers cannot cope with very \n"
- "large images. \n",
- 100,30000
- );
- addDependency("maxDotGraphHeight","haveDotFlag");
- ConfigBool::add( "generateLegend",
- "GENERATE_LEGEND",
- "TRUE",
- "generate legend page",
- "If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will \n"
- "generate a legend page explaining the meaning of the various boxes and \n"
- "arrows in the dot generated graphs. \n"
- );
- addDependency("generateLegend","haveDotFlag");
- ConfigBool::add( "dotCleanUp",
- "DOT_CLEANUP",
- "TRUE",
- "remove intermedia dot files?",
- "If the DOT_CLEANUP tag is set to YES (the default) Doxygen will \n"
- "remove the intermedate dot files that are used to generate \n"
- "the various graphs. \n"
- );
- addDependency("dotCleanUp","haveDotFlag");
-
- //-----------------------------------------------------------------------------------------------
- ConfigInfo::add( "Search","Configuration::addtions related to the search engine ");
- //-----------------------------------------------------------------------------------------------
- ConfigBool::add( "searchEngineFlag",
- "SEARCHENGINE",
- "FALSE",
- "generate search engine flag",
- "The SEARCHENGINE tag specifies whether or not a search engine should be \n"
- "used. If set to NO the values of all tags below this one will be ignored. \n"
- );
- ConfigString::add("cgiName",
- "CGI_NAME",
- "search.cgi",
- "the name of the CGI binary",
- "The CGI_NAME tag should be the name of the CGI script that \n"
- "starts the search engine (doxysearch) with the correct parameters. \n"
- "A script with this name will be generated by doxygen. \n"
- );
- addDependency("cgiName","searchEngineFlag");
- ConfigString::add("cgiURL",
- "CGI_URL",
- "",
- "the absolute URL to the CGI binary",
- "The CGI_URL tag should be the absolute URL to the directory where the \n"
- "cgi binaries are located. See the documentation of your http daemon for \n"
- "details. \n"
- );
- addDependency("cgiURL","searchEngineFlag");
- ConfigString::add("docURL",
- "DOC_URL",
- "",
- "the absolute URL to the documentation",
- "The DOC_URL tag should be the absolute URL to the directory where the \n"
- "documentation is located. If left blank the absolute path to the \n"
- "documentation, with file:// prepended to it, will be used. \n"
- );
- addDependency("docURL","searchEngineFlag");
- ConfigString::add("docAbsPath",
- "DOC_ABSPATH",
- "",
- "the absolute path to the documentation",
- "The DOC_ABSPATH tag should be the absolute path to the directory where the \n"
- "documentation is located. If left blank the directory on the local machine \n"
- "will be used. \n",
- ConfigString::Dir
- );
- addDependency("docAbsPath","searchEngineFlag");
- ConfigString::add("binAbsPath",
- "BIN_ABSPATH",
- "/usr/local/bin/",
- "the absolute path to the doxysearch",
- "The BIN_ABSPATH tag must point to the directory where the doxysearch binary \n"
- "is installed. \n",
- ConfigString::Dir
- );
- addDependency("binAbsPath","searchEngineFlag");
- ConfigList::add( "extDocPathList",
- "EXT_DOC_PATHS",
- "",
- "list of external doc. directories.",
- "The EXT_DOC_PATHS tag can be used to specify one or more paths to \n"
- "documentation generated for other projects. This allows doxysearch to search \n"
- "the documentation for these projects as well. \n",
- ConfigList::Dir
- );
- addDependency("extDocPathList","searchEngineFlag");
-
- // The IMAGE_PATTERNS tag is now officially obsolete.
-}
diff --git a/addon/configgen/configgen.pro.in b/addon/configgen/configgen.pro.in
deleted file mode 100644
index 12ddf92..0000000
--- a/addon/configgen/configgen.pro.in
+++ /dev/null
@@ -1,20 +0,0 @@
-#
-#
-#
-# Copyright (C) 1997-2001 by Dimitri van Heesch.
-#
-# Permission to use, copy, modify, and distribute this software and its
-# documentation under the terms of the GNU General Public License is hereby
-# granted. No representations are made about the suitability of this software
-# for any purpose. It is provided "as is" without express or implied warranty.
-# See the GNU General Public License for more details.
-#
-# TMake project file for configgen
-
-TEMPLATE = app.t
-CONFIG = console qt warn_on $extraopts
-HEADERS =
-SOURCES = configgen.cpp
-win32:INCLUDEPATH += .
-TARGET = bin/configgen
-OBJECTS_DIR = obj
diff --git a/addon/doxywizard/Makefile.in b/addon/doxywizard/Makefile.in
index 249190a..65995b5 100644
--- a/addon/doxywizard/Makefile.in
+++ b/addon/doxywizard/Makefile.in
@@ -1,5 +1,5 @@
#
-#
+# $Id$
#
# Copyright (C) 1997-2001 by Dimitri van Heesch.
#
@@ -10,30 +10,17 @@
# See the GNU General Public License for more details.
#
-CFGGENBIN_DIR = ../configgen/bin
-CFGGENSRC_DIR = ../configgen
-
-all: $(CFGGENBIN_DIR)/configgen config.h config.l doxywizard.cpp doxywizard.h \
- Makefile.doxywizard
+all: config.l config.h Makefile.doxywizard
$(MAKE) -f Makefile.doxywizard $@
-Makefile.doxywizard: doxywizard.pro doxywizard.t
- $(ENV) $(PERL) $(TMAKE) doxywizard.pro >Makefile.doxywizard
-
-config.l: $(CFGGENBIN_DIR)/configgen $(CFGGENSRC_DIR)/config_templ.l
- $(CFGGENBIN_DIR)/configgen $(CFGGENSRC_DIR)/config_templ.l >config.l
+config.l:
+ $(CP) ../../src/config.l config.l
-config.h: $(CFGGENBIN_DIR)/configgen $(CFGGENSRC_DIR)/config_templ.h
- $(CFGGENBIN_DIR)/configgen $(CFGGENSRC_DIR)/config_templ.h >config.h
+config.h:
+ $(CP) ../../src/config.h config.h
-doxywizard.cpp: $(CFGGENBIN_DIR)/configgen doxywizard_templ.cpp
- $(CFGGENBIN_DIR)/configgen doxywizard_templ.cpp >doxywizard.cpp
-
-doxywizard.h: $(CFGGENBIN_DIR)/configgen doxywizard_templ.h
- $(CFGGENBIN_DIR)/configgen doxywizard_templ.h >doxywizard.h
-
-$(CFGGENBIN_DIR)/configgen: $(CFGGENSRC_DIR)/configgen.cpp
- $(MAKE) -C $(CFGGENSRC_DIR)
+Makefile.doxywizard: doxywizard.pro
+ $(ENV) $(PERL) $(TMAKE) doxywizard.pro >Makefile.doxywizard
tmake:
$(ENV) $(PERL) $(TMAKE) doxywizard.pro >Makefile.doxywizard
@@ -42,8 +29,7 @@ clean: Makefile.doxywizard
$(MAKE) -f Makefile.doxywizard clean
distclean: clean
- $(RM) doxywizard.cpp doxywizard.h \
- config.l config.h config.cpp Makefile.doxywizard
+ $(RM) Makefile.doxywizard config.l config.h config.cpp
install:
$(INSTTOOL) -d $(INSTALL)/bin
diff --git a/addon/doxywizard/doxywizard.cpp b/addon/doxywizard/doxywizard.cpp
new file mode 100644
index 0000000..8ceecbb
--- /dev/null
+++ b/addon/doxywizard/doxywizard.cpp
@@ -0,0 +1,540 @@
+/******************************************************************************
+ *
+ * $Id$
+ *
+ * Copyright (C) 1997-2001 by Dimitri van Heesch.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation under the terms of the GNU General Public License is hereby
+ * granted. No representations are made about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
+ * See the GNU General Public License for more details.
+ *
+ */
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <qmainwindow.h>
+#include <qpopupmenu.h>
+#include <qfileinfo.h>
+#include <qmenubar.h>
+#include <qstatusbar.h>
+#include <qfiledialog.h>
+#include <qmessagebox.h>
+#include <qapplication.h>
+#include <qwhatsthis.h>
+#include <qlayout.h>
+#include <qtabwidget.h>
+#include <qtoolbar.h>
+#include <qtoolbutton.h>
+
+#include "doxywizard.h"
+#include "pagewidget.h"
+#include "inputbool.h"
+#include "inputstring.h"
+#include "inputstrlist.h"
+#include "inputint.h"
+#include "config.h"
+#include "version.h"
+#include "pixmaps.h"
+
+QString configFileName;
+
+const int messageTimeout = 4000; //!< status bar message timeout in millisec.
+
+//-------------------------------------------------------------------------
+
+static bool loadConfig( QString loadFile )
+{
+ QFileInfo fi( loadFile );
+ if ( !fi.exists() )
+ {
+ QMessageBox::warning(0,
+ "Warning","Input file "+loadFile+
+ " does not exist! Starting new file.",
+ "ok"
+ );
+ return FALSE;
+ }
+ QFile f( loadFile );
+ if ( !f.open(IO_ReadOnly) )
+ {
+ QMessageBox::warning(0,
+ "Warning","Cannot open input "+loadFile+
+ " for reading!.",
+ "abort"
+ );
+ exit(1);
+ }
+
+ // set config values to their defaults
+ Config::instance()->init();
+
+ // read file into a string buffer
+ int fsize = fi.size();
+ QCString contents(fsize+1); // add room for \0 terminator
+ f.readBlock(contents.data(),fsize);
+ contents[fsize]='\0';
+
+ // parse the config file
+ // this will initialize the various Config data members
+ Config::instance()->parse(contents,loadFile);
+ Config::instance()->convertStrToVal();
+
+ f.close();
+ return TRUE;
+}
+
+static bool saveConfig( QString saveFile )
+{
+ QFile f( saveFile );
+ if ( !f.open(IO_WriteOnly) )
+ {
+ QMessageBox::warning(0,
+ "Warning","Cannot open file "+saveFile+
+ " for writing. Nothing saved!.",
+ "ok"
+ );
+ return FALSE; // failure
+ }
+
+ Config::instance()->writeTemplate(&f,TRUE); // write brief config file
+
+ return TRUE; // success
+}
+
+//--------------------------------------------------------------------------
+
+Wizard::Wizard(int argc,char **argv) :
+ QMainWindow( 0, (QCString)"DoxyWizard v"+versionString )
+{
+ // File popupmenu
+
+ hasChanged=FALSE;
+
+ fileTools = new QToolBar( this, "file operations" );
+ fileTools->setLabel( "File Operations" );
+
+ new QToolButton( QPixmap( file_xpm ), "New File", QString::null,
+ this, SLOT(newFile()), fileTools, "new file" );
+
+ //QToolButton * fileOpen =
+ new QToolButton( QPixmap( fileopen_xpm ), "Open File", QString::null,
+ this, SLOT(loadFile()), fileTools, "open file" );
+
+ //QToolButton * fileSave =
+ new QToolButton( QPixmap( filesave_xpm ), "Save File", QString::null,
+ this, SLOT(saveFile()), fileTools, "save file" );
+
+ //Micha: QToolButton * =
+ new QToolButton( QPixmap( rundoxygen_xpm ), "Save and Run doxygen", QString::null,
+ this, SLOT(runDoxygen()), fileTools, "save and run doxygen" );
+
+
+ QWhatsThis::whatsThisButton( fileTools );
+
+ QPopupMenu* file = new QPopupMenu;
+ file->insertItem( QIconSet(QPixmap(file_xpm)),
+ "&New", this, SLOT(newFile()), CTRL+Key_N );
+ file->insertItem( QIconSet(QPixmap(fileopen_xpm)),
+ "&Load", this, SLOT(loadFile()), CTRL+Key_O );
+ file->insertSeparator();
+ file->insertItem( QIconSet(QPixmap(filesave_xpm)),
+ "&Save", this, SLOT(saveFile()), CTRL+Key_S );
+ file->insertItem( "&Save as ...", this, SLOT(saveAsFile()) );
+ file->insertSeparator();
+ file->insertItem( "&Quit", this, SLOT(quit()), CTRL+Key_Q );
+
+ // Doxygen popupmenu
+ QPopupMenu* doxygen = new QPopupMenu;
+ int itemIndex = doxygen->insertItem( QIconSet(QPixmap(rundoxygen_xpm)),
+ "&Run", this, SLOT(runDoxygen()), CTRL+Key_R );
+ doxygen->setWhatsThis ( itemIndex, "Run doxygen with the current configuration file..." );
+
+ // Help popupmenu
+ QPopupMenu* help = new QPopupMenu;
+ help->insertItem( "&About", this, SLOT(about()), Key_F1 );
+ help->insertItem( "What's &This", this , SLOT(whatsThis()), SHIFT+Key_F1);
+
+ // menubar definition
+ menuBar()->insertItem( "&File", file );
+ menuBar()->insertItem( "&Doxygen", doxygen );
+ menuBar()->insertSeparator();
+ menuBar()->insertItem( "&Help", help );
+
+ statusBar()->message("Welcome to DoxyWizard",messageTimeout);
+
+ cw = new ConfigFile( this );
+ connect(cw,SIGNAL(changed()),this,SLOT(changed()));
+ setCentralWidget( cw );
+ cw->show();
+
+ if (argc==2)
+ {
+ loadFile(argv[1]);
+ }
+ else
+ {
+ newFile();
+ }
+ refreshCaption();
+
+ resize( 640, 480 );
+
+}
+
+void Wizard::newFile()
+{
+ if (hasChanged)
+ {
+ switch( QMessageBox::warning( this, "DoxyWizard",
+ "Start a new file and lose changes?\n",
+ "Yes", "No", 0, 0, 1 ))
+ {
+ case 0:
+ break;
+ default: // command aborted by the user
+ return;
+ }
+ }
+ Config::instance()->init();
+ configFileName="Doxyfile";
+ cw->init();
+}
+
+void Wizard::loadFile(const char *fileName)
+{
+ if (fileName==0)
+ {
+ configFileName = QFileDialog::getOpenFileName();
+ }
+ else
+ {
+ configFileName = fileName;
+ }
+
+ if ( !configFileName.isNull() )
+ {
+ //initData( configFileName );
+ loadConfig(configFileName);
+ cw->init();
+
+ statusBar()->message(configFileName, messageTimeout);
+ }
+}
+
+void Wizard::loadFile()
+{
+ if (hasChanged)
+ {
+ switch( QMessageBox::warning(
+ this, "DoxyWizard", "Load a new file and lose changes?\n",
+ "Yes", "No", 0, 0, 1 ))
+ {
+ case 0:
+ break;
+ default: // command aborted by the user
+ return;
+ }
+ }
+ loadFile(0);
+}
+
+void Wizard::saveFile()
+{
+ //printf("configFileName=`%s'\n",configFileName.data());
+ if (configFileName.isEmpty())
+ {
+ saveAsFile();
+ return;
+ }
+ else
+ {
+ saveConfig(configFileName);
+ statusBar()->message(configFileName + " saved", messageTimeout);
+ }
+ hasChanged = FALSE;
+ refreshCaption();
+}
+
+void Wizard::saveAsFile()
+{
+ configFileName = QFileDialog::getSaveFileName();
+ if (configFileName.isNull())
+ {
+ statusBar()->message("Save aborted", messageTimeout );
+ return; // operation cancelled by the user
+ }
+
+ saveConfig(configFileName);
+ statusBar()->message("Saved as "+ configFileName, messageTimeout );
+}
+
+//Micha
+// TODO: Use QProcess to show the output in a window
+void Wizard::runDoxygen()
+{
+ saveFile();
+ QString s = "doxygen " + configFileName;
+ system((const char*)s);
+ statusBar()->message("doxygen completed: "+ configFileName, messageTimeout );
+ hasChanged = FALSE;
+ refreshCaption();
+}
+
+
+void Wizard::quit()
+{
+ if (hasChanged)
+ {
+ switch( QMessageBox::warning( this, "DoxyWizard", "Quit and lose changes?\n",
+ "Yes", "No", 0, 0, 1 ))
+ {
+ case 0:
+ qApp->quit();
+ break;
+ case 1:
+ break;
+ }
+ }
+ else
+ {
+ qApp->quit();
+ }
+}
+
+void Wizard::changed()
+{
+ hasChanged = TRUE;
+ refreshCaption();
+}
+
+void Wizard::refreshCaption()
+{
+ QString s;
+ if (hasChanged) s=" *";
+ setCaption("Doxywizard - ["+configFileName+s+"]");
+}
+
+void Wizard::about()
+{
+ QMessageBox::about(this, "DoxyWizard",
+ "<qt><center>A tool to create and edit configuration files "
+ "that can be read by doxygen.</center><p>"
+ "<center>Written by Dimitri van Heesch</center><p>"
+ "<center>(c) 2000</center></qt>"
+ );
+}
+
+//----------------------------------------------------------------------
+
+
+ConfigFile::ConfigFile( QWidget *parent ) : QWidget( parent )
+{
+
+ m_dependencies = new QDict< QList<IInput> >(257);
+ m_dependencies->setAutoDelete(TRUE);
+ m_inputWidgets = new QDict< IInput >;
+ m_switches = new QDict< QObject >;
+
+ QVBoxLayout *layout = new QVBoxLayout( this );
+
+ // QTabWidget definition
+ QTabWidget *tab = new QTabWidget( this );
+ layout->addWidget( tab );
+
+ QListIterator<ConfigOption> options = Config::instance()->iterator();
+ PageWidget *page = 0;
+ ConfigOption *option = 0;
+ for (options.toFirst();(option=options.current());++options)
+ {
+ switch(option->kind())
+ {
+ case ConfigOption::O_Info:
+ if (page) page->addStretch(1);
+ page = new PageWidget( tab, option->name() );
+ QWhatsThis::add(page, option->docs().simplifyWhiteSpace() );
+ break;
+ case ConfigOption::O_String:
+ {
+ ASSERT(page!=0);
+ InputString::StringMode sm;
+ switch(((ConfigString *)option)->widgetType())
+ {
+ case ConfigString::String: sm=InputString::StringFree; break;
+ case ConfigString::File: sm=InputString::StringFile; break;
+ case ConfigString::Dir: sm=InputString::StringDir; break;
+ }
+ InputString *inputString = new InputString(
+ option->name(), // name
+ page, // widget
+ *((ConfigString *)option)->valueRef(), // variable
+ sm // type
+ );
+ QWhatsThis::add(inputString, option->docs().simplifyWhiteSpace() );
+ connect(inputString,SIGNAL(changed()),SIGNAL(changed()));
+ m_inputWidgets->insert(option->name(),inputString);
+ addDependency(m_switches,option->dependsOn(),option->name());
+ }
+ break;
+ case ConfigOption::O_Enum:
+ {
+ ASSERT(page!=0);
+ InputString *inputString = new InputString(
+ option->name(), // name
+ page, // widget
+ *((ConfigEnum *)option)->valueRef(), // variable
+ InputString::StringFixed // type
+ );
+ QStrListIterator sli=((ConfigEnum *)option)->iterator();
+ for (sli.toFirst();sli.current();++sli)
+ {
+ inputString->addValue(sli.current());
+ }
+ QWhatsThis::add(inputString, option->docs().simplifyWhiteSpace() );
+ connect(inputString,SIGNAL(changed()),SIGNAL(changed()));
+ m_inputWidgets->insert(option->name(),inputString);
+ addDependency(m_switches,option->dependsOn(),option->name());
+ }
+ break;
+ case ConfigOption::O_List:
+ {
+ ASSERT(page!=0);
+ InputStrList::ListMode lm;
+ switch(((ConfigList *)option)->widgetType())
+ {
+ case ConfigList::String: lm=InputStrList::ListString; break;
+ case ConfigList::File: lm=InputStrList::ListFile; break;
+ case ConfigList::Dir: lm=InputStrList::ListDir; break;
+ case ConfigList::FileAndDir: lm=InputStrList::ListFileDir; break;
+ }
+ InputStrList *inputStrList = new InputStrList(
+ option->name(), // name
+ page, // widget
+ *((ConfigList *)option)->valueRef(), // variable
+ lm // type
+ );
+ QWhatsThis::add(inputStrList, option->docs().simplifyWhiteSpace() );
+ connect(inputStrList,SIGNAL(changed()),SIGNAL(changed()));
+ m_inputWidgets->insert(option->name(),inputStrList);
+ addDependency(m_switches,option->dependsOn(),option->name());
+ }
+ break;
+ break;
+ case ConfigOption::O_Bool:
+ {
+ ASSERT(page!=0);
+ InputBool *inputBool = new InputBool(
+ option->name(), // name
+ page, // widget
+ *((ConfigBool *)option)->valueRef() // variable
+ );
+ QWhatsThis::add(inputBool, option->docs().simplifyWhiteSpace() );
+ connect(inputBool,SIGNAL(changed()),SIGNAL(changed()));
+ m_inputWidgets->insert(option->name(),inputBool);
+ addDependency(m_switches,option->dependsOn(),option->name());
+ }
+ break;
+ case ConfigOption::O_Int:
+ {
+ ASSERT(page!=0);
+ InputInt *inputInt = new InputInt(
+ option->name(), // name
+ page, // widget
+ *((ConfigInt *)option)->valueRef(), // variable
+ ((ConfigInt *)option)->minVal(), // min value
+ ((ConfigInt *)option)->maxVal() // max value
+ );
+ QWhatsThis::add(inputInt, option->docs().simplifyWhiteSpace() );
+ connect(inputInt,SIGNAL(changed()),SIGNAL(changed()));
+ m_inputWidgets->insert(option->name(),inputInt);
+ addDependency(m_switches,option->dependsOn(),option->name());
+ }
+ break;
+ }
+ }
+ if (page) page->addStretch(1);
+
+ QDictIterator<QObject> di(*m_switches);
+ QObject *obj = 0;
+ for (di.toFirst();(obj=di.current());++di)
+ {
+ connect(obj,SIGNAL(toggle(const char *,bool)),SLOT(toggle(const char *,bool)));
+ // UGLY HACK: assumes each item depends on a boolean without checking!
+ emit toggle(di.currentKey(),((InputBool *)obj)->getState());
+ }
+
+}
+
+ConfigFile::~ConfigFile()
+{
+ delete m_dependencies;
+ delete m_inputWidgets;
+ delete m_switches;
+}
+
+void ConfigFile::addDependency(QDict<QObject> *switches,
+ const QCString &dep,const QCString &name)
+{
+ if (!dep.isEmpty())
+ {
+ IInput *parent = m_inputWidgets->find(dep);
+ ASSERT(parent!=0);
+ IInput *child = m_inputWidgets->find(name);
+ ASSERT(child!=0);
+ if (switches->find(dep)==0)
+ {
+ switches->insert(dep,parent->qobject());
+ }
+ QList<IInput> *list = m_dependencies->find(dep);
+ if (list==0)
+ {
+ list = new QList<IInput>;
+ m_dependencies->insert(dep,list);
+ }
+ list->append(child);
+ }
+}
+
+void ConfigFile::toggle(const char *name,bool state)
+{
+ QList<IInput> *inputs = m_dependencies->find(name);
+ ASSERT(inputs!=0);
+ IInput *input = inputs->first();
+ while (input)
+ {
+ input->setEnabled(state);
+ input = inputs->next();
+ }
+}
+
+void ConfigFile::init()
+{
+ QDictIterator<IInput> di(*m_inputWidgets);
+ IInput *input = 0;
+ for (di.toFirst();(input=di.current());++di)
+ {
+ input->init();
+ }
+ QDictIterator<QObject> dio(*m_switches);
+ QObject *obj = 0;
+ for (dio.toFirst();(obj=dio.current());++dio)
+ {
+ connect(obj,SIGNAL(toggle(const char *,bool)),SLOT(toggle(const char *,bool)));
+ // UGLY HACK: assumes each item depends on a boolean without checking!
+ emit toggle(dio.currentKey(),((InputBool *)obj)->getState());
+ }
+
+}
+
+//----------------------------------------------------------------------
+
+int main(int argc,char **argv)
+{
+ QApplication::setColorSpec( QApplication::NormalColor );
+ QApplication app(argc,argv);
+ Wizard wizard(argc,argv);
+ app.setMainWidget( &wizard );
+ wizard.show();
+ return app.exec();
+}
diff --git a/addon/doxywizard/doxywizard.h b/addon/doxywizard/doxywizard.h
new file mode 100644
index 0000000..f78733e
--- /dev/null
+++ b/addon/doxywizard/doxywizard.h
@@ -0,0 +1,111 @@
+/******************************************************************************
+ *
+ * $Id$
+ *
+ * Copyright (C) 1997-2001 by Dimitri van Heesch.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation under the terms of the GNU General Public License is hereby
+ * granted. No representations are made about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
+ * See the GNU General Public License for more details.
+ *
+ */
+
+#ifndef _DOXWIZARD_H
+#define _DOXWIZARD_H
+
+#include <qmainwindow.h>
+#include <qlist.h>
+#include <qdict.h>
+
+class IInput;
+class QToolBar;
+class QWidget;
+class QObject;
+class ConfigFile;
+class InputBool;
+class InputString;
+class InputStrList;
+class InputFile;
+class InputDir;
+class InputInt;
+
+class Wizard : public QMainWindow
+{
+ Q_OBJECT
+
+ public:
+ Wizard(int argc,char **argv);
+ ~Wizard(){};
+ void loadFile(const char *s);
+
+ private slots:
+ void newFile();
+ void loadFile();
+ void saveFile();
+ void saveAsFile();
+ void quit();
+ void changed();
+ void about();
+ void runDoxygen(); // Micha
+
+ signals:
+
+ private:
+ void refreshCaption();
+ QToolBar *fileTools;
+ bool hasChanged;
+ ConfigFile *cw;
+};
+
+class ConfigWidget
+{
+ public:
+ enum Kind { Int, String, StrList, Bool };
+
+ ConfigWidget(QWidget *w,Kind k) : m_widget(w), m_kind(k) {}
+
+ Kind kind() const { return m_kind; }
+
+ InputString *getString() const
+ { return m_kind==String ? (InputString *)m_widget : 0; }
+
+ InputBool *getBool() const
+ { return m_kind==Bool ? (InputBool *)m_widget : 0; }
+
+ InputStrList *getStrList() const
+ { return m_kind==StrList ? (InputStrList *)m_widget : 0; }
+
+ InputInt *getInt() const
+ { return m_kind==Int ? (InputInt *)m_widget : 0; }
+
+ private:
+ QWidget *m_widget;
+ Kind m_kind;
+};
+
+class ConfigFile : public QWidget
+{
+ Q_OBJECT
+
+ public:
+ ConfigFile(QWidget *parent=0);
+ ~ConfigFile();
+ void init();
+ void addDependency(QDict<QObject> *switches,
+ const QCString &dep,const QCString &name);
+
+ signals:
+ void changed();
+
+ private slots:
+ void toggle(const char *,bool);
+
+ private:
+ QDict<IInput> *m_inputWidgets;
+ QDict< QList<IInput> > *m_dependencies;
+ QDict<QObject> *m_switches;
+};
+
+#endif
diff --git a/addon/doxywizard/doxywizard.pro.in b/addon/doxywizard/doxywizard.pro.in
index b7a690f..649c395 100644
--- a/addon/doxywizard/doxywizard.pro.in
+++ b/addon/doxywizard/doxywizard.pro.in
@@ -1,5 +1,5 @@
#
-#
+# $Id$
#
# Copyright (C) 1997-2001 by Dimitri van Heesch.
#
@@ -22,24 +22,24 @@ CONFIG = qt warn_on $extraopts
# header file for the project
HEADERS = doxywizard.h \
- config.h \
version.h \
pagewidget.h \
inputstring.h \
inputbool.h \
inputstrlist.h \
inputint.h \
+ config.h \
pixmaps.h
# source flle for the project
SOURCES = doxywizard.cpp \
- config.cpp \
version.cpp \
pagewidget.cpp \
inputstring.cpp \
inputbool.cpp \
inputstrlist.cpp \
inputint.cpp \
+ config.cpp \
pixmaps.cpp
# where to put the objects
@@ -50,3 +50,4 @@ MOC_DIR = moc
# extra C++ compiler options
TMAKE_CXXFLAGS += -DDOXYWIZARD
+
diff --git a/addon/doxywizard/input.h b/addon/doxywizard/input.h
new file mode 100644
index 0000000..ab9bcf5
--- /dev/null
+++ b/addon/doxywizard/input.h
@@ -0,0 +1,14 @@
+#ifndef _INPUT_H
+#define _INPUT_H
+
+class QObject;
+
+class IInput
+{
+ public:
+ virtual void init() = 0;
+ virtual void setEnabled(bool) = 0;
+ virtual QObject *qobject() = 0;
+};
+
+#endif
diff --git a/addon/doxywizard/inputbool.cpp b/addon/doxywizard/inputbool.cpp
index c63696a..4ac2f8a 100644
--- a/addon/doxywizard/inputbool.cpp
+++ b/addon/doxywizard/inputbool.cpp
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
@@ -36,7 +36,11 @@ void InputBool::init()
void InputBool::setState( bool s )
{
- if (state!=s) emit changed();
+ if (state!=s)
+ {
+ emit changed();
+ emit toggle(text(),s);
+ }
state=s;
}
diff --git a/addon/doxywizard/inputbool.h b/addon/doxywizard/inputbool.h
index 2bd8d7a..9c2511f 100644
--- a/addon/doxywizard/inputbool.h
+++ b/addon/doxywizard/inputbool.h
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
@@ -17,9 +17,11 @@
#include <qcheckbox.h>
+#include "input.h"
+
class PageWidget;
-class InputBool : public QCheckBox
+class InputBool : public QCheckBox, public IInput
{
Q_OBJECT
@@ -27,9 +29,13 @@ class InputBool : public QCheckBox
InputBool( const QString &text, PageWidget *parent, bool &flag );
~InputBool(){};
void init();
+ void setEnabled(bool b) { QCheckBox::setEnabled(b); }
+ QObject *qobject() { return this; }
+ bool getState() const { return state; }
signals:
void changed();
+ void toggle(const char *,bool);
private slots:
void setState(bool);
diff --git a/addon/doxywizard/inputint.cpp b/addon/doxywizard/inputint.cpp
index 702988c..d6173c4 100644
--- a/addon/doxywizard/inputint.cpp
+++ b/addon/doxywizard/inputint.cpp
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/addon/doxywizard/inputint.h b/addon/doxywizard/inputint.h
index 434cb39..28da9cf 100644
--- a/addon/doxywizard/inputint.h
+++ b/addon/doxywizard/inputint.h
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
@@ -18,11 +18,13 @@
#include <qwidget.h>
#include <qstring.h>
+#include "input.h"
+
class QLabel;
class QSpinBox;
class PageWidget;
-class InputInt : public QWidget
+class InputInt : public QWidget, public IInput
{
Q_OBJECT
@@ -32,6 +34,7 @@ class InputInt : public QWidget
~InputInt(){};
void setEnabled(bool);
void init();
+ QObject *qobject() { return this; }
private:
QLabel *lab;
diff --git a/addon/doxywizard/inputstring.cpp b/addon/doxywizard/inputstring.cpp
index a20ba68..e43fc93 100644
--- a/addon/doxywizard/inputstring.cpp
+++ b/addon/doxywizard/inputstring.cpp
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/addon/doxywizard/inputstring.h b/addon/doxywizard/inputstring.h
index e1b42cf..794f93e 100644
--- a/addon/doxywizard/inputstring.h
+++ b/addon/doxywizard/inputstring.h
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
@@ -19,13 +19,16 @@
#include <qstring.h>
#include <qdict.h>
+#include "qtbc.h"
+#include "input.h"
+
class QLabel;
class QLineEdit;
class QPushButton;
class QComboBox;
class PageWidget;
-class InputString : public QWidget
+class InputString : public QWidget, public IInput
{
Q_OBJECT
@@ -42,6 +45,7 @@ class InputString : public QWidget
void setEnabled(bool);
void addValue(const char *s);
void init();
+ QObject *qobject() { return this; }
private:
QLabel *lab;
diff --git a/addon/doxywizard/inputstrlist.cpp b/addon/doxywizard/inputstrlist.cpp
index 9ab9a5b..c6c34f4 100644
--- a/addon/doxywizard/inputstrlist.cpp
+++ b/addon/doxywizard/inputstrlist.cpp
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/addon/doxywizard/inputstrlist.h b/addon/doxywizard/inputstrlist.h
index 3bf6371..e60b036 100644
--- a/addon/doxywizard/inputstrlist.h
+++ b/addon/doxywizard/inputstrlist.h
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
@@ -18,6 +18,8 @@
#include <qwidget.h>
#include <qstring.h>
+#include "input.h"
+
class QLabel;
class QLineEdit;
class QPushButton;
@@ -25,7 +27,7 @@ class QListBox;
class PageWidget;
class QStrList;
-class InputStrList : public QWidget
+class InputStrList : public QWidget, public IInput
{
Q_OBJECT
@@ -41,6 +43,7 @@ class InputStrList : public QWidget
~InputStrList() {};
void setEnabled(bool);
void init();
+ QObject *qobject() { return this; }
private:
QLabel *lab;
diff --git a/addon/doxywizard/pagewidget.cpp b/addon/doxywizard/pagewidget.cpp
index 7e6920b..67d4d57 100644
--- a/addon/doxywizard/pagewidget.cpp
+++ b/addon/doxywizard/pagewidget.cpp
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/addon/doxywizard/pagewidget.h b/addon/doxywizard/pagewidget.h
index 6d238df..266fcc4 100644
--- a/addon/doxywizard/pagewidget.h
+++ b/addon/doxywizard/pagewidget.h
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/addon/doxywizard/pixmaps.cpp b/addon/doxywizard/pixmaps.cpp
index 5f2497b..6c7199b 100644
--- a/addon/doxywizard/pixmaps.cpp
+++ b/addon/doxywizard/pixmaps.cpp
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/addon/doxywizard/pixmaps.h b/addon/doxywizard/pixmaps.h
index 7ec854e..144fee3 100644
--- a/addon/doxywizard/pixmaps.h
+++ b/addon/doxywizard/pixmaps.h
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/addon/configgen/qtbc.h b/addon/doxywizard/qtbc.h
index 3bbdc7a..13b6fea 100644
--- a/addon/configgen/qtbc.h
+++ b/addon/doxywizard/qtbc.h
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
@@ -26,11 +26,13 @@
#if QT_VERSION >= 200
+#include <locale.h>
+
#define GCI QCollection::Item
#include <qcstring.h>
#include <qstring.h>
-inline QCString convertToQCString(const QString &s) { return s.local8Bit(); }
+inline QCString convertToQCString(const QString &s) { return s.latin1(); }
#else /* QT_VERSION < 200 */
diff --git a/addon/xmlgen/xml.cpp b/addon/xmlgen/xml.cpp
index ecb3fce..a624426 100644
--- a/addon/xmlgen/xml.cpp
+++ b/addon/xmlgen/xml.cpp
@@ -60,7 +60,7 @@ class TextGeneratorXMLImpl : public TextGeneratorIntf
void generateDTD()
{
- QCString fileName=Config::outputDir+"/xml/doxygen.dtd";
+ QCString fileName=Config::instance()->getString("OUTPUT_DIRECTORY")+"/xml/doxygen.dtd";
QFile f(fileName);
if (!f.open(IO_WriteOnly))
{
@@ -440,49 +440,49 @@ void generateXMLForFile(FileDef *fd,QTextStream &t)
void generateXML()
{
- if (Config::outputDir.isEmpty())
- Config::outputDir=QDir::currentDirPath();
+ if (Config::instance()->getString("OUTPUT_DIRECTORY").isEmpty())
+ Config::instance()->getString("OUTPUT_DIRECTORY")=QDir::currentDirPath();
else
{
- QDir dir(Config::outputDir);
+ QDir dir(Config::instance()->getString("OUTPUT_DIRECTORY"));
if (!dir.exists())
{
dir.setPath(QDir::currentDirPath());
- if (!dir.mkdir(Config::outputDir))
+ if (!dir.mkdir(Config::instance()->getString("OUTPUT_DIRECTORY")))
{
err("Error: tag OUTPUT_DIRECTORY: Output directory `%s' does not "
- "exist and cannot be created\n",Config::outputDir.data());
+ "exist and cannot be created\n",Config::instance()->getString("OUTPUT_DIRECTORY").data());
exit(1);
}
- else if (!Config::quietFlag)
+ else if (!Config::instance()->getBool("QUIET"))
{
err("Notice: Output directory `%s' does not exist. "
- "I have created it for you.\n", Config::outputDir.data());
+ "I have created it for you.\n", Config::instance()->getString("OUTPUT_DIRECTORY").data());
}
- dir.cd(Config::outputDir);
+ dir.cd(Config::instance()->getString("OUTPUT_DIRECTORY"));
}
- Config::outputDir=dir.absPath();
+ Config::instance()->getString("OUTPUT_DIRECTORY")=dir.absPath();
}
- QDir dir(Config::outputDir);
+ QDir dir(Config::instance()->getString("OUTPUT_DIRECTORY"));
if (!dir.exists())
{
dir.setPath(QDir::currentDirPath());
- if (!dir.mkdir(Config::outputDir))
+ if (!dir.mkdir(Config::instance()->getString("OUTPUT_DIRECTORY")))
{
- err("Cannot create directory %s\n",Config::outputDir.data());
+ err("Cannot create directory %s\n",Config::instance()->getString("OUTPUT_DIRECTORY").data());
return;
}
}
- QDir xmlDir(Config::outputDir+"/xml");
- if (!xmlDir.exists() && !xmlDir.mkdir(Config::outputDir+"/xml"))
+ QDir xmlDir(Config::instance()->getString("OUTPUT_DIRECTORY")+"/xml");
+ if (!xmlDir.exists() && !xmlDir.mkdir(Config::instance()->getString("OUTPUT_DIRECTORY")+"/xml"))
{
- err("Could not create xml directory in %s\n",Config::outputDir.data());
+ err("Could not create xml directory in %s\n",Config::instance()->getString("OUTPUT_DIRECTORY").data());
return;
}
generateDTD();
- QCString fileName=Config::outputDir+"/xml/doxygen.xml";
+ QCString fileName=Config::instance()->getString("OUTPUT_DIRECTORY")+"/xml/doxygen.xml";
QFile f(fileName);
if (!f.open(IO_WriteOnly))
{
diff --git a/addon/xmlgen/xmlgen.pro.in b/addon/xmlgen/xmlgen.pro.in
index c16db47..2f29fd3 100644
--- a/addon/xmlgen/xmlgen.pro.in
+++ b/addon/xmlgen/xmlgen.pro.in
@@ -3,18 +3,18 @@ CONFIG = console warn_on $extraopt
HEADERS = xml.h xml_dtd.h
SOURCES = main.cpp xml.cpp
DEPENDPATH = ../../src
-unix:LIBS += -L../../lib -ldoxygen -lqtools
+unix:LIBS += -L../../lib -ldoxygen -ldoxycfg -lqtools
win32:INCLUDEPATH += .
-win32-mingw:LIBS += -L../../lib -ldoxygen -lqtools
-win32-msvc:LIBS += qtools.lib doxygen.lib shell32.lib
+win32-mingw:LIBS += -L../../lib -ldoxygen -ldoxycfg -lqtools
+win32-msvc:LIBS += qtools.lib doxygen.lib doxycfg.lib shell32.lib
win32-msvc:TMAKE_LFLAGS += /LIBPATH:..\..\lib
-win32-borland:LIBS += qtools.lib doxygen.lib shell32.lib
+win32-borland:LIBS += qtools.lib doxygen.lib doxycfg.lib shell32.lib
win32-borland:TMAKE_LFLAGS += -L..\..\lib
win32:TMAKE_CXXFLAGS += -DQT_NODLL
INCLUDEPATH += ../../qtools ../../src
DESTDIR = ../../bin
TARGET = doxygen_xml
-unix:TARGETDEPS = ../../lib/libdoxygen.a
-win32:TARGETDEPS = ..\..\lib\doxygen.lib
+unix:TARGETDEPS = ../../lib/libdoxygen.a ../../lib/libdoxycfg.a
+win32:TARGETDEPS = ..\..\lib\doxygen.lib ../../lib/doxycfg.lib
OBJECTS_DIR = obj
diff --git a/addon/xmlread/qtbc.h b/addon/xmlread/qtbc.h
index 51f62dd..13b6fea 100644
--- a/addon/xmlread/qtbc.h
+++ b/addon/xmlread/qtbc.h
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/configure b/configure
index ff0a2e6..b201aba 100755
--- a/configure
+++ b/configure
@@ -26,7 +26,6 @@ f_plf_auto=NO
f_prefix=/usr
f_insttool=install
f_english=NO
-f_configgen=NO
f_wizard=NO
f_xmlgen=NO
@@ -65,9 +64,6 @@ while test -n "$1"; do
--install)
shift; f_insttool=$1
;;
- --with-configgen)
- f_configgen=YES
- ;;
--with-doxywizard)
f_wizard=YES
;;
@@ -91,7 +87,7 @@ if test "$f_help" = y; then
Usage: $0 [--help] [--shared] [--static] [--release] [--debug]
[--perl name] [--make name] [--dot name] [--platform target]
[--prefix dir] [--install name] [--english-only]
- [--with-configgen] [--with-doxywizard] [--with-xmlgen]
+ [--with-doxywizard] [--with-xmlgen]
Options:
@@ -124,10 +120,6 @@ Options:
--english-only Include support for English only.
- --with-configgen Build the configuration generator. This is only
- useful for doxygen developers that want to add
- new configuration options.
-
--with-doxywizard Build the GUI frontend for doxygen. This
requires Qt 2.x.x
@@ -380,7 +372,7 @@ TMAKE_CXXFLAGS += -DENGLISH_ONLY
EOF
fi
-f_inmakefiles="Makefile.in addon/xmlgen/Makefile.in qtools/Makefile.in src/Makefile.in examples/Makefile.in doc/Makefile.in addon/configgen/Makefile.in addon/doxywizard/Makefile.in addon/xmlread/Makefile.in"
+f_inmakefiles="Makefile.in addon/xmlgen/Makefile.in qtools/Makefile.in src/Makefile.in examples/Makefile.in doc/Makefile.in addon/doxywizard/Makefile.in addon/xmlread/Makefile.in"
for i in $f_inmakefiles ; do
SRC=$i
@@ -398,9 +390,6 @@ EOF
echo "all: src/version.cpp " >> $DST
echo " \$(MAKE) -C qtools" >> $DST
echo " \$(MAKE) -C src" >> $DST
- if test $f_configgen = YES; then
- echo " \$(MAKE) -C addon/configgen" >> $DST
- fi
if test $f_wizard = YES; then
echo " \$(MAKE) -C addon/doxywizard" >> $DST
fi
@@ -417,7 +406,7 @@ EOF
echo " Created $DST from $SRC..."
done
-f_inprofiles="qtools/qtools.pro.in src/libdoxygen.pro.in src/doxygen.pro.in src/doxytag.pro.in src/doxysearch.pro.in addon/configgen/configgen.pro.in addon/doxywizard/doxywizard.pro.in addon/xmlread/xmlread.pro.in addon/xmlgen/xmlgen.pro.in"
+f_inprofiles="qtools/qtools.pro.in src/libdoxygen.pro.in src/libdoxycfg.pro.in src/doxygen.pro.in src/doxytag.pro.in src/doxysearch.pro.in addon/doxywizard/doxywizard.pro.in addon/xmlread/xmlread.pro.in addon/xmlgen/xmlgen.pro.in"
for i in $f_inprofiles ; do
SRC=$i
diff --git a/doc/commands.doc b/doc/commands.doc
index 92491ae..c6aa049 100644
--- a/doc/commands.doc
+++ b/doc/commands.doc
@@ -77,6 +77,7 @@ documentation:
<li> \refitem cmdfile \file
<li> \refitem cmdfn \fn
<li> \refitem cmdhideinitializer \hideinitializer
+<li> \refitem cmdhtmlinclude \htmlinclude
<li> \refitem cmdhtmlonly \htmlonly
<li> \refitem cmdif \if
<li> \refitem cmdimage \image
@@ -899,7 +900,7 @@ Public/Protected/Private/... section.
\subsection cmdanchor \anchor <word>
\addindex \anchor
- This command places an invisble, named anchor into to documentation
+ This command places an invisible, named anchor into to documentation
to which you can refer with the \\ref command.
\sa section \ref cmdref "\\ref".
@@ -1118,6 +1119,20 @@ Public/Protected/Private/... section.
The command is equivalent to pasting the file in the documentation and
placing \\verbatim and \\endverbatim commands around it.
+ Files or directories that doxygen should look for can be specified using the
+ \ref cfg_example_path "EXAMPLE_PATH" tag of Doxygen's configuration file.
+
+<hr>
+\subsection cmdhtmlinclude \htmlinclude <file-name>
+
+ \addindex \htmlinclude
+ This command includes the file \<file-name\> as is in the HTML documentation.
+ The command is equivalent to pasting the file in the documentation and
+ placing \\htmlonly and \\endhtmlonly commands around it.
+
+ Files or directories that doxygen should look for can be specified using the
+ \ref cfg_example_path "EXAMPLE_PATH" tag of Doxygen's configuration file.
+
<hr>
<h2>\htmlonly <center> --- \endhtmlonly
Commands for visual enhancements
diff --git a/doc/htmlcmds.doc b/doc/htmlcmds.doc
index 8c9c28c..6cc320c 100644
--- a/doc/htmlcmds.doc
+++ b/doc/htmlcmds.doc
@@ -91,7 +91,7 @@ documentation. Note that all attributes of a HTML tag are ignored
<li>\c </VAR> Ends a \c </VAR> section.
</ul>
-The special HTML characters entities that are recognized by Doxygen:
+The special HTML character entities that are recognized by Doxygen:
<ul>
<li>\c &copy; the copyright symbol
@@ -107,6 +107,11 @@ The special HTML characters entities that are recognized by Doxygen:
<li>\c &?tilde; where ? is one of {A,N,O,a,n,o},
writes a character with a tilde accent (like &atilde;).
<li>\c &szlig; write a sharp s (i.e. &szlig;) to the output.
+<li>\c &?cedil; where ? is one of {c,C},
+ writes a c-cedille (like &ccedil;).
+<li>\c &?ring; where ? is one of {a,A},
+ writes an \c a with a ring (like &aring;).
+<li>\c &nbsp; a non breakable space.
</ul>
*/
diff --git a/packages/rpm/doxygen.spec b/packages/rpm/doxygen.spec
index 9d5cf64..2d3cb7e 100644
--- a/packages/rpm/doxygen.spec
+++ b/packages/rpm/doxygen.spec
@@ -1,5 +1,5 @@
Name: doxygen
-Version: 1.2.6-20010319
+Version: 1.2.6-20010401
Summary: documentation system for C, C++ and IDL
Release: 1
Source0: doxygen-%{version}.src.tar.gz
diff --git a/qtools/Makefile.in b/qtools/Makefile.in
index 78710fd..26a8e9c 100644
--- a/qtools/Makefile.in
+++ b/qtools/Makefile.in
@@ -1,5 +1,5 @@
#
-#
+# $Id$
#
# Copyright (C) 1997-2000 by Dimitri van Heesch.
#
diff --git a/qtools/qarray.h b/qtools/qarray.h
index 90dcbb7..5fb6bf7 100644
--- a/qtools/qarray.h
+++ b/qtools/qarray.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QArray template/macro class
**
diff --git a/qtools/qasciidict.h b/qtools/qasciidict.h
index 3f2deaf..23b85e5 100644
--- a/qtools/qasciidict.h
+++ b/qtools/qasciidict.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QAsciiDict template class
**
diff --git a/qtools/qbuffer.cpp b/qtools/qbuffer.cpp
index beed0ba..59d20a2 100644
--- a/qtools/qbuffer.cpp
+++ b/qtools/qbuffer.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QBuffer class
**
diff --git a/qtools/qbuffer.h b/qtools/qbuffer.h
index 9dcd286..d3fdae1 100644
--- a/qtools/qbuffer.h
+++ b/qtools/qbuffer.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QBuffer class
**
diff --git a/qtools/qcollection.cpp b/qtools/qcollection.cpp
index e70b64b..21bf412 100644
--- a/qtools/qcollection.cpp
+++ b/qtools/qcollection.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of base class for all collection classes
**
diff --git a/qtools/qcollection.h b/qtools/qcollection.h
index a169b7c..e672609 100644
--- a/qtools/qcollection.h
+++ b/qtools/qcollection.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of base class for all collection classes
**
diff --git a/qtools/qcstring.cpp b/qtools/qcstring.cpp
index 2d2e0c5..f128ae1 100644
--- a/qtools/qcstring.cpp
+++ b/qtools/qcstring.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of extended char array operations, and QByteArray and
** QCString classes
diff --git a/qtools/qcstring.h b/qtools/qcstring.h
index 073a969..b9cad44 100644
--- a/qtools/qcstring.h
+++ b/qtools/qcstring.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of the extended char array operations,
** and QByteArray and QCString classes
diff --git a/qtools/qdatastream.cpp b/qtools/qdatastream.cpp
index 7f63cbf..c586570 100644
--- a/qtools/qdatastream.cpp
+++ b/qtools/qdatastream.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QDataStream class
**
diff --git a/qtools/qdatastream.h b/qtools/qdatastream.h
index 3d18062..dafab36 100644
--- a/qtools/qdatastream.h
+++ b/qtools/qdatastream.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QDataStream class
**
diff --git a/qtools/qdatetime.cpp b/qtools/qdatetime.cpp
index cecb855..026387a 100644
--- a/qtools/qdatetime.cpp
+++ b/qtools/qdatetime.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of date and time classes
**
diff --git a/qtools/qdatetime.h b/qtools/qdatetime.h
index 2479dbf..820fde3 100644
--- a/qtools/qdatetime.h
+++ b/qtools/qdatetime.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of date and time classes
**
diff --git a/qtools/qdict.h b/qtools/qdict.h
index 3b70336..fdd9366 100644
--- a/qtools/qdict.h
+++ b/qtools/qdict.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QDict template class
**
diff --git a/qtools/qdir.cpp b/qtools/qdir.cpp
index ed7ed99..b0d1c0d 100644
--- a/qtools/qdir.cpp
+++ b/qtools/qdir.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QDir class
**
diff --git a/qtools/qdir.h b/qtools/qdir.h
index dd74271..8fcadf5 100644
--- a/qtools/qdir.h
+++ b/qtools/qdir.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QDir class
**
diff --git a/qtools/qdir_unix.cpp b/qtools/qdir_unix.cpp
index 46a3b69..9ace60a 100644
--- a/qtools/qdir_unix.cpp
+++ b/qtools/qdir_unix.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QDirclass
**
diff --git a/qtools/qdir_win32.cpp b/qtools/qdir_win32.cpp
index b1eee66..832c86b 100644
--- a/qtools/qdir_win32.cpp
+++ b/qtools/qdir_win32.cpp
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/qtools/qfeatures.h b/qtools/qfeatures.h
index 84fa715..9dc5107 100644
--- a/qtools/qfeatures.h
+++ b/qtools/qfeatures.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Global feature selection
**
diff --git a/qtools/qfile.cpp b/qtools/qfile.cpp
index 2222b5b..06300de 100644
--- a/qtools/qfile.cpp
+++ b/qtools/qfile.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QFile class
**
diff --git a/qtools/qfile.h b/qtools/qfile.h
index 4ef0685..e95cdf4 100644
--- a/qtools/qfile.h
+++ b/qtools/qfile.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QFile class
**
diff --git a/qtools/qfile_unix.cpp b/qtools/qfile_unix.cpp
index e074eed..a1beb31 100644
--- a/qtools/qfile_unix.cpp
+++ b/qtools/qfile_unix.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QFileInfo class
**
diff --git a/qtools/qfile_win32.cpp b/qtools/qfile_win32.cpp
index fd28d43..12a0643 100644
--- a/qtools/qfile_win32.cpp
+++ b/qtools/qfile_win32.cpp
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/qtools/qfiledefs_p.h b/qtools/qfiledefs_p.h
index 4a1a154..eeac5c5 100644
--- a/qtools/qfiledefs_p.h
+++ b/qtools/qfiledefs_p.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Common macros and system include files for QFile, QFileInfo and QDir.
**
diff --git a/qtools/qfileinfo.cpp b/qtools/qfileinfo.cpp
index 5053b76..7e30a9e 100644
--- a/qtools/qfileinfo.cpp
+++ b/qtools/qfileinfo.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QFileInfo class
**
diff --git a/qtools/qfileinfo.h b/qtools/qfileinfo.h
index 76ef8c2..8543e1c 100644
--- a/qtools/qfileinfo.h
+++ b/qtools/qfileinfo.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QFileInfo class
**
diff --git a/qtools/qfileinfo_unix.cpp b/qtools/qfileinfo_unix.cpp
index 5a8fe04..fbeb363 100644
--- a/qtools/qfileinfo_unix.cpp
+++ b/qtools/qfileinfo_unix.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QFileInfo class
**
diff --git a/qtools/qfileinfo_win32.cpp b/qtools/qfileinfo_win32.cpp
index bfcc6ac..abb9b9d 100644
--- a/qtools/qfileinfo_win32.cpp
+++ b/qtools/qfileinfo_win32.cpp
@@ -1,6 +1,6 @@
/******************************************************************************
*
- *
+ * $Id$
*
* Copyright (C) 1997-2001 by Dimitri van Heesch.
*
diff --git a/qtools/qgarray.cpp b/qtools/qgarray.cpp
index efc9de0..b20caee 100644
--- a/qtools/qgarray.cpp
+++ b/qtools/qgarray.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QGArray class
**
diff --git a/qtools/qgarray.h b/qtools/qgarray.h
index 12c463b..971d6bf 100644
--- a/qtools/qgarray.h
+++ b/qtools/qgarray.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QGArray class
**
diff --git a/qtools/qgdict.cpp b/qtools/qgdict.cpp
index c3b2f74..545628e 100644
--- a/qtools/qgdict.cpp
+++ b/qtools/qgdict.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QGDict and QGDictIterator classes
**
diff --git a/qtools/qgdict.h b/qtools/qgdict.h
index 6243364..cc9e262 100644
--- a/qtools/qgdict.h
+++ b/qtools/qgdict.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QGDict and QGDictIterator classes
**
diff --git a/qtools/qgeneric.h b/qtools/qgeneric.h
index c2892a0..312cb30 100644
--- a/qtools/qgeneric.h
+++ b/qtools/qgeneric.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Macros for pasting tokens; utilized by our generic classes
**
diff --git a/qtools/qglist.cpp b/qtools/qglist.cpp
index f464a73..0ffddf0 100644
--- a/qtools/qglist.cpp
+++ b/qtools/qglist.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QGList and QGListIterator classes
**
diff --git a/qtools/qglist.h b/qtools/qglist.h
index f400b64..6949aa3 100644
--- a/qtools/qglist.h
+++ b/qtools/qglist.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QGList and QGListIterator classes
**
diff --git a/qtools/qglobal.cpp b/qtools/qglobal.cpp
index 50f5202..95075a9 100644
--- a/qtools/qglobal.cpp
+++ b/qtools/qglobal.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Global functions
**
diff --git a/qtools/qglobal.h b/qtools/qglobal.h
index 9c2b53e..7acd0de 100644
--- a/qtools/qglobal.h
+++ b/qtools/qglobal.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Global type declarations and definitions
**
diff --git a/qtools/qgvector.cpp b/qtools/qgvector.cpp
index 88409ce..a769a55 100644
--- a/qtools/qgvector.cpp
+++ b/qtools/qgvector.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QGVector class
**
diff --git a/qtools/qgvector.h b/qtools/qgvector.h
index 6a7999d..b5fbde0 100644
--- a/qtools/qgvector.h
+++ b/qtools/qgvector.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QGVector class
**
diff --git a/qtools/qintdict.h b/qtools/qintdict.h
index ddc5fdf..52722ed 100644
--- a/qtools/qintdict.h
+++ b/qtools/qintdict.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QIntDict template class
**
diff --git a/qtools/qiodevice.cpp b/qtools/qiodevice.cpp
index 43b2787..babe387 100644
--- a/qtools/qiodevice.cpp
+++ b/qtools/qiodevice.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QIODevice class
**
diff --git a/qtools/qiodevice.h b/qtools/qiodevice.h
index 1c54217..6688bda 100644
--- a/qtools/qiodevice.h
+++ b/qtools/qiodevice.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QIODevice class
**
diff --git a/qtools/qlist.h b/qtools/qlist.h
index a4608fb..a7ad156 100644
--- a/qtools/qlist.h
+++ b/qtools/qlist.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QList template/macro class
**
diff --git a/qtools/qmap.cpp b/qtools/qmap.cpp
index 1d2510a..3f73f81 100644
--- a/qtools/qmap.cpp
+++ b/qtools/qmap.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QMap
**
diff --git a/qtools/qmap.h b/qtools/qmap.h
index f384a3d..ecd355f 100644
--- a/qtools/qmap.h
+++ b/qtools/qmap.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QMap class
**
diff --git a/qtools/qptrdict.h b/qtools/qptrdict.h
index c075e30..2ed1ef2 100644
--- a/qtools/qptrdict.h
+++ b/qtools/qptrdict.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QPtrDict template class
**
diff --git a/qtools/qqueue.h b/qtools/qqueue.h
index 94bc130..36af518 100644
--- a/qtools/qqueue.h
+++ b/qtools/qqueue.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QQueue template/macro class
**
diff --git a/qtools/qregexp.cpp b/qtools/qregexp.cpp
index 671867e..99189a6 100644
--- a/qtools/qregexp.cpp
+++ b/qtools/qregexp.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QRegExp class
**
diff --git a/qtools/qregexp.h b/qtools/qregexp.h
index 25868ce..a66453c 100644
--- a/qtools/qregexp.h
+++ b/qtools/qregexp.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QRegExp class
**
diff --git a/qtools/qshared.h b/qtools/qshared.h
index 79fab7b..338029e 100644
--- a/qtools/qshared.h
+++ b/qtools/qshared.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QShared struct
**
diff --git a/qtools/qsortedlist.h b/qtools/qsortedlist.h
index aeadd90..7b90da6 100644
--- a/qtools/qsortedlist.h
+++ b/qtools/qsortedlist.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QList template/macro class
**
diff --git a/qtools/qstack.h b/qtools/qstack.h
index c23215c..47311a5 100644
--- a/qtools/qstack.h
+++ b/qtools/qstack.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QStack template/macro class
**
diff --git a/qtools/qstring.cpp b/qtools/qstring.cpp
index e13ffc8..b9530a6 100644
--- a/qtools/qstring.cpp
+++ b/qtools/qstring.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of the QString class and related Unicode functions
**
diff --git a/qtools/qstring.h b/qtools/qstring.h
index f131446..b574b05 100644
--- a/qtools/qstring.h
+++ b/qtools/qstring.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of the QString class, and related Unicode
** functions.
diff --git a/qtools/qstringlist.cpp b/qtools/qstringlist.cpp
index ff4f33e..d923f23 100644
--- a/qtools/qstringlist.cpp
+++ b/qtools/qstringlist.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QStringList
**
diff --git a/qtools/qstringlist.h b/qtools/qstringlist.h
index 03342c5..04d11c6 100644
--- a/qtools/qstringlist.h
+++ b/qtools/qstringlist.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QStringList class
**
diff --git a/qtools/qstrlist.h b/qtools/qstrlist.h
index c6a1864..abec631 100644
--- a/qtools/qstrlist.h
+++ b/qtools/qstrlist.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QStrList, QStrIList and QStrListIterator classes
**
diff --git a/qtools/qstrvec.h b/qtools/qstrvec.h
index 15d3abb..31d7d89 100644
--- a/qtools/qstrvec.h
+++ b/qtools/qstrvec.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QStrVec and QStrIVec classes
**
diff --git a/qtools/qtextcodec.cpp b/qtools/qtextcodec.cpp
index cdecfce..b55345e 100644
--- a/qtools/qtextcodec.cpp
+++ b/qtools/qtextcodec.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QTextCodec class
**
diff --git a/qtools/qtextcodec.h b/qtools/qtextcodec.h
index 18ece20..9d5783f 100644
--- a/qtools/qtextcodec.h
+++ b/qtools/qtextcodec.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QTextCodec class
**
diff --git a/qtools/qtextstream.cpp b/qtools/qtextstream.cpp
index 6686f81..ae794df 100644
--- a/qtools/qtextstream.cpp
+++ b/qtools/qtextstream.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QTextStream class
**
diff --git a/qtools/qtextstream.h b/qtools/qtextstream.h
index c5f5ba1..357447d 100644
--- a/qtools/qtextstream.h
+++ b/qtools/qtextstream.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QTextStream class
**
diff --git a/qtools/qtl.h b/qtools/qtl.h
index bd72e7d..ed1fe40 100644
--- a/qtools/qtl.h
+++ b/qtools/qtl.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of Qt template library classes
**
diff --git a/qtools/qvaluelist.h b/qtools/qvaluelist.h
index a1014ed..246df84 100644
--- a/qtools/qvaluelist.h
+++ b/qtools/qvaluelist.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QValueList class
**
diff --git a/qtools/qvaluestack.h b/qtools/qvaluestack.h
index 9728d6c..e38edb2 100644
--- a/qtools/qvaluestack.h
+++ b/qtools/qvaluestack.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QValueStack class
**
diff --git a/qtools/qvector.h b/qtools/qvector.h
index 36f0be7..9dd970c 100644
--- a/qtools/qvector.h
+++ b/qtools/qvector.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QVector template/macro class
**
diff --git a/qtools/qxml.cpp b/qtools/qxml.cpp
index 11a9b01..f437783 100644
--- a/qtools/qxml.cpp
+++ b/qtools/qxml.cpp
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Implementation of QXmlSimpleReader and related classes.
**
diff --git a/qtools/qxml.h b/qtools/qxml.h
index ce40e5f..98d6641 100644
--- a/qtools/qxml.h
+++ b/qtools/qxml.h
@@ -1,5 +1,5 @@
/****************************************************************************
-**
+** $Id$
**
** Definition of QXmlSimpleReader and related classes.
**
diff --git a/src/Makefile.in b/src/Makefile.in
index 5d724a1..15a641e 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -14,8 +14,9 @@
# input used in their production; they are not affected by this license.
#
-all: Makefile.libdoxygen Makefile.doxygen Makefile.doxytag Makefile.doxysearch Makefile
+all: Makefile.libdoxygen Makefile.libdoxycfg Makefile.doxygen Makefile.doxytag Makefile.doxysearch Makefile
$(MAKE) -f Makefile.libdoxygen $@
+ $(MAKE) -f Makefile.libdoxycfg $@
$(MAKE) -f Makefile.doxygen $@
$(MAKE) -f Makefile.doxytag $@
$(MAKE) -f Makefile.doxysearch $@
@@ -23,6 +24,9 @@ all: Makefile.libdoxygen Makefile.doxygen Makefile.doxytag Makefile.doxysearch M
Makefile.libdoxygen: libdoxygen.pro libdoxygen.t
$(ENV) $(PERL) $(TMAKE) libdoxygen.pro >Makefile.libdoxygen
+Makefile.libdoxycfg: libdoxycfg.pro libdoxycfg.t
+ $(ENV) $(PERL) $(TMAKE) libdoxycfg.pro >Makefile.libdoxycfg
+
Makefile.doxygen: doxygen.pro
$(ENV) $(PERL) $(TMAKE) doxygen.pro >Makefile.doxygen
@@ -34,12 +38,14 @@ Makefile.doxysearch: doxysearch.pro
tmake:
$(ENV) $(PERL) $(TMAKE) libdoxygen.pro >Makefile.libdoxygen
+ $(ENV) $(PERL) $(TMAKE) libdoxycfg.pro >Makefile.libdoxycfg
$(ENV) $(PERL) $(TMAKE) doxygen.pro >Makefile.doxygen
$(ENV) $(PERL) $(TMAKE) doxytag.pro >Makefile.doxytag
$(ENV) $(PERL) $(TMAKE) doxysearch.pro >Makefile.doxysearch
clean: Makefile.libdoxygen Makefile.doxygen Makefile.doxytag Makefile.doxysearch
$(MAKE) -f Makefile.libdoxygen clean
+ $(MAKE) -f Makefile.libdoxycfg clean
$(MAKE) -f Makefile.doxygen clean
$(MAKE) -f Makefile.doxytag clean
$(MAKE) -f Makefile.doxysearch clean
diff --git a/src/classdef.cpp b/src/classdef.cpp
index b335af7..83cb3c0 100644
--- a/src/classdef.cpp
+++ b/src/classdef.cpp
@@ -119,7 +119,7 @@ ClassDef::~ClassDef()
QCString ClassDef::displayName() const
{
- if (Config::hideScopeNames)
+ if (Config::instance()->getBool("HIDE_SCOPE_NAMES"))
{
return stripScope(name());
}
@@ -209,7 +209,7 @@ void ClassDef::insertMember(MemberDef *md)
/********************************************/
/* insert member in the declaration section */
/********************************************/
- if (md->isRelated() && (Config::extractPrivateFlag || md->protection()!=Private))
+ if (md->isRelated() && (Config::instance()->getBool("EXTRACT_PRIVATE") || md->protection()!=Private))
{
related.append(md);
md->setSectionList(&related);
@@ -357,11 +357,11 @@ void ClassDef::insertMember(MemberDef *md)
/* insert member in the detailed documentation section */
/*******************************************************/
if ((md->isRelated() &&
- (Config::extractPrivateFlag || md->protection()!=Private)
+ (Config::instance()->getBool("EXTRACT_PRIVATE") || md->protection()!=Private)
) || md->isFriend()
)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
relatedMembers.inSort(md);
else
relatedMembers.append(md);
@@ -371,14 +371,14 @@ void ClassDef::insertMember(MemberDef *md)
switch (md->memberType())
{
case MemberDef::Property:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
propertyMembers.inSort(md);
else
propertyMembers.append(md);
break;
case MemberDef::Signal: // fall through
case MemberDef::DCOP:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
functionMembers.inSort(md);
else
functionMembers.append(md);
@@ -387,21 +387,21 @@ void ClassDef::insertMember(MemberDef *md)
switch (md->protection())
{
case Protected:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
functionMembers.inSort(md);
else
functionMembers.append(md);
break;
case Public:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
functionMembers.inSort(md);
else
functionMembers.append(md);
break;
case Private:
- if (Config::extractPrivateFlag)
+ if (Config::instance()->getBool("EXTRACT_PRIVATE"))
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
functionMembers.inSort(md);
else
functionMembers.append(md);
@@ -410,24 +410,24 @@ void ClassDef::insertMember(MemberDef *md)
}
break;
default: // any of the other members
- if (md->protection()!=Private || Config::extractPrivateFlag)
+ if (md->protection()!=Private || Config::instance()->getBool("EXTRACT_PRIVATE"))
{
switch (md->memberType())
{
case MemberDef::Typedef:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
typedefMembers.inSort(md);
else
typedefMembers.append(md);
break;
case MemberDef::Enumeration:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
enumMembers.inSort(md);
else
enumMembers.append(md);
break;
case MemberDef::EnumValue:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
enumValMembers.inSort(md);
else
enumValMembers.append(md);
@@ -443,14 +443,14 @@ void ClassDef::insertMember(MemberDef *md)
}
else
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
functionMembers.inSort(md);
else
functionMembers.append(md);
}
break;
case MemberDef::Variable:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
variableMembers.inSort(md);
else
variableMembers.append(md);
@@ -720,7 +720,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <compound kind=\"" << compoundTypeString();
Doxygen::tagFile << "\">" << endl;
@@ -729,7 +729,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
- if (Config::classDiagramFlag) ol.disableAllBut(OutputGenerator::Man);
+ if (Config::instance()->getBool("CLASS_DIAGRAMS")) ol.disableAllBut(OutputGenerator::Man);
// write subclasses
@@ -753,7 +753,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ClassDef *cd=bcd->classDef;
if (cd->isLinkable())
{
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <base";
if (bcd->prot==Protected)
@@ -819,7 +819,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol.newParagraph();
}
- if (Config::classDiagramFlag) ol.enableAll();
+ if (Config::instance()->getBool("CLASS_DIAGRAMS")) ol.enableAll();
count=0;
@@ -840,7 +840,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
- if (Config::haveDotFlag && Config::classGraphFlag)
+ if (Config::instance()->getBool("HAVE_DOT") && Config::instance()->getBool("CLASS_GRAPH"))
// write class diagram using dot
{
DotClassGraph inheritanceGraph(this,DotClassGraph::Inheritance);
@@ -851,7 +851,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol.startDotGraph();
parseText(ol,theTranslator->trClassDiagram(name()));
ol.endDotGraph(inheritanceGraph);
- if (Config::generateLegend)
+ if (Config::instance()->getBool("GENERATE_LEGEND"))
{
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Html);
@@ -865,7 +865,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol.popGeneratorState();
}
}
- else if (Config::classDiagramFlag && count>0)
+ else if (Config::instance()->getBool("CLASS_DIAGRAMS") && count>0)
// write class diagram using build-in generator
{
ClassDiagram diagram(this); // create a diagram of this class.
@@ -876,7 +876,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol.endClassDiagram(diagram,fileName,name());
}
- if (Config::haveDotFlag && Config::collGraphFlag)
+ if (Config::instance()->getBool("HAVE_DOT") && Config::instance()->getBool("COLLABORATION_GRAPH"))
{
DotClassGraph usageImplGraph(this,DotClassGraph::Implementation);
if (!usageImplGraph.isTrivial())
@@ -886,7 +886,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol.startDotGraph();
parseText(ol,theTranslator->trCollaborationDiagram(name()));
ol.endDotGraph(usageImplGraph);
- if (Config::generateLegend)
+ if (Config::instance()->getBool("GENERATE_LEGEND"))
{
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Html);
@@ -902,7 +902,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
// write link to list of all members (HTML only)
- if (allMemberNameInfoList->count()>0 && !Config::optimizeForCFlag)
+ if (allMemberNameInfoList->count()>0 && !Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
ol.disableAllBut(OutputGenerator::Html);
ol.startTextLink(memListFileName,0);
@@ -953,7 +953,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
proStaticMembers.writeDeclarations(ol,this,0,0,0,theTranslator->trStaticProtectedMembers(),0);
proStaticAttribs.writeDeclarations(ol,this,0,0,0,theTranslator->trStaticProtectedAttribs(),0);
- if (Config::extractPrivateFlag)
+ if (Config::instance()->getBool("EXTRACT_PRIVATE"))
{
// private non-static members
priTypes.writeDeclarations(ol,this,0,0,0,theTranslator->trPrivateTypes(),0);
@@ -973,9 +973,9 @@ void ClassDef::writeDocumentation(OutputList &ol)
// write detailed description
bool exampleFlag=hasExamples();
- if ((!briefDescription().isEmpty() && Config::repeatBriefFlag) ||
+ if ((!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF")) ||
!documentation().isEmpty() ||
- /*(Config::sourceBrowseFlag && startBodyLine!=-1 && bodyDef) ||*/
+ /*(Config::instance()->getBool("SOURCE_BROWSER") && startBodyLine!=-1 && bodyDef) ||*/
exampleFlag)
{
ol.writeRuler();
@@ -992,11 +992,11 @@ void ClassDef::writeDocumentation(OutputList &ol)
writeTemplateSpec(ol,outerTempArgList,pageType,name());
// repeat brief description
- if (!briefDescription().isEmpty() && Config::repeatBriefFlag)
+ if (!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF"))
{
ol+=briefOutput;
}
- if (!briefDescription().isEmpty() && Config::repeatBriefFlag &&
+ if (!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF") &&
!documentation().isEmpty())
{
ol.newParagraph();
@@ -1118,7 +1118,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
// write the list of used files (not for man pages)
ol.pushGeneratorState();
- if (Config::showUsedFilesFlag)
+ if (Config::instance()->getBool("SHOW_USED_FILES"))
{
ol.disable(OutputGenerator::Man);
ol.writeRuler();
@@ -1140,7 +1140,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol.writeListItem();
QCString path=fd->getPath().copy();
- if (Config::fullPathNameFlag)
+ if (Config::instance()->getBool("FULL_PATH_NAMES"))
{
ol.docify(stripFromPath(path));
}
@@ -1171,12 +1171,12 @@ void ClassDef::writeDocumentation(OutputList &ol)
ol.startGroupHeader();
parseText(ol,theTranslator->trAuthor());
ol.endGroupHeader();
- parseText(ol,theTranslator->trGeneratedAutomatically(Config::projectName));
+ parseText(ol,theTranslator->trGeneratedAutomatically(Config::instance()->getString("PROJECT_NAME")));
ol.popGeneratorState();
ol.endTextBlock();
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
writeDocAnchorsToTagFile();
Doxygen::tagFile << " </compound>" << endl;
@@ -1188,7 +1188,7 @@ void ClassDef::writeDocumentation(OutputList &ol)
// write the list of all (inherited) members for this class
void ClassDef::writeMemberList(OutputList &ol)
{
- if (allMemberNameInfoList->count()==0 || Config::optimizeForCFlag) return;
+ if (allMemberNameInfoList->count()==0 || Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C")) return;
// only for HTML
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Html);
@@ -1238,7 +1238,7 @@ void ClassDef::writeMemberList(OutputList &ol)
(
md->isFriend() ||
(/*mi->prot!=Private &&*/
- (prot!=Private || Config::extractPrivateFlag)
+ (prot!=Private || Config::instance()->getBool("EXTRACT_PRIVATE"))
)
)
)
@@ -1265,7 +1265,7 @@ void ClassDef::writeMemberList(OutputList &ol)
ol.writeString("\n");
memberWritten=TRUE;
}
- else if (!Config::hideMemberFlag) // no documentation,
+ else if (!Config::instance()->getBool("HIDE_UNDOC_MEMBERS")) // no documentation,
// generate link to the class instead.
{
ol.writeListItem();
@@ -1297,7 +1297,7 @@ void ClassDef::writeMemberList(OutputList &ol)
}
if ((prot!=Public || virt!=Normal ||
md->isFriend() || md->isRelated() || md->isExplicit() ||
- md->isMutable() || (md->isInline() && Config::inlineInfoFlag) ||
+ md->isMutable() || (md->isInline() && Config::instance()->getBool("INLINE_INFO")) ||
md->isSignal() || md->isSlot() ||
md->isStatic()
)
@@ -1310,7 +1310,7 @@ void ClassDef::writeMemberList(OutputList &ol)
else if (md->isRelated()) sl.append("related");
else
{
- if (Config::inlineInfoFlag && md->isInline())
+ if (Config::instance()->getBool("INLINE_INFO") && md->isInline())
sl.append("inline");
if (md->isExplicit()) sl.append("explicit");
if (md->isMutable()) sl.append("mutable");
@@ -1445,7 +1445,7 @@ void ClassDef::writeDeclaration(OutputList &ol,MemberDef *md,bool inGroup)
proSlots.writePlainDeclarations(ol,this,0,0,0);
proStaticMembers.writePlainDeclarations(ol,this,0,0,0);
proStaticAttribs.writePlainDeclarations(ol,this,0,0,0);
- if (Config::extractPrivateFlag)
+ if (Config::instance()->getBool("EXTRACT_PRIVATE"))
{
priTypes.writePlainDeclarations(ol,this,0,0,0);
priMembers.writePlainDeclarations(ol,this,0,0,0);
@@ -1463,20 +1463,20 @@ void ClassDef::writeDeclaration(OutputList &ol,MemberDef *md,bool inGroup)
bool ClassDef::isLinkableInProject()
{
return !name().isEmpty() && name().find('@')==-1 &&
- (prot!=Private || Config::extractPrivateFlag) &&
+ (prot!=Private || Config::instance()->getBool("EXTRACT_PRIVATE")) &&
hasDocumentation() && !isReference();
}
/*! the class is visible in a class diagram, or class hierarchy */
bool ClassDef::isVisibleInHierarchy()
{ return // show all classes or a subclass is visible
- (Config::allExtFlag || hasNonReferenceSuperClass()) &&
+ (Config::instance()->getBool("ALLEXTERNALS") || hasNonReferenceSuperClass()) &&
// and not an annonymous compound
name().find('@')==-1 &&
// and not privately inherited
- (prot!=Private || Config::extractPrivateFlag) &&
+ (prot!=Private || Config::instance()->getBool("EXTRACT_PRIVATE")) &&
// documented or show anyway or documentation is external
- (hasDocumentation() || !Config::hideClassFlag || isReference());
+ (hasDocumentation() || !Config::instance()->getBool("HIDE_UNDOC_CLASSES") || isReference());
}
//----------------------------------------------------------------------
@@ -1750,10 +1750,10 @@ void ClassDef::determineImplUsageRelation()
ClassDef *cd=0;
if (getNamespaceDef()!=0)
{
- cd=getResolvedClass(getNamespaceDef()->name()+"::"+usedClassName);
+ cd=getResolvedClass(getNamespaceDef()->name()+"::"+usedClassName,0,&templSpec);
}
- if (cd==0) cd=getResolvedClass(name()+"::"+usedClassName);
- if (cd==0) cd=getResolvedClass(usedClassName); // TODO: also try inbetween scopes!
+ if (cd==0) cd=getResolvedClass(name()+"::"+usedClassName,0,&templSpec);
+ if (cd==0) cd=getResolvedClass(usedClassName,0,&templSpec); // TODO: also try inbetween scopes!
//printf("Search for class %s result=%p\n",usedClassName.data(),cd);
if (cd) // class exists
{
diff --git a/src/classlist.cpp b/src/classlist.cpp
index bd80ca1..bba7b9d 100644
--- a/src/classlist.cpp
+++ b/src/classlist.cpp
@@ -35,9 +35,9 @@ int ClassList::compareItems(GCI item1, GCI item2)
{
ClassDef *c1=(ClassDef *)item1;
ClassDef *c2=(ClassDef *)item2;
- //int prefixLength = Config::ignorePrefix.length();
- //int i1 = c1->name().left(prefixLength)==Config::ignorePrefix ? prefixLength : 0;
- //int i2 = c2->name().left(prefixLength)==Config::ignorePrefix ? prefixLength : 0;
+ //int prefixLength = Config::instance()->get("").length();
+ //int i1 = c1->name().left(prefixLength)==Config::instance()->get("") ? prefixLength : 0;
+ //int i2 = c2->name().left(prefixLength)==Config::instance()->get("") ? prefixLength : 0;
return stricmp(c1->name().data()+getPrefixIndex(c1->name()),
c2->name().data()+getPrefixIndex(c2->name())
);
@@ -61,7 +61,7 @@ void ClassList::writeDeclaration(OutputList &ol,const ClassDef::CompoundType *fi
)
{
bool isLink = cd->isLinkable();
- if (isLink || !Config::hideClassFlag)
+ if (isLink || !Config::instance()->getBool("HIDE_UNDOC_CLASSES"))
{
if (!found)
{
@@ -78,7 +78,7 @@ void ClassList::writeDeclaration(OutputList &ol,const ClassDef::CompoundType *fi
ol.startMemberList();
found=TRUE;
}
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <class kind=\"" << cd->compoundTypeString()
<< "\">" << convertToXML(cd->name()) << "</class>" << endl;
@@ -107,7 +107,7 @@ void ClassList::writeDeclaration(OutputList &ol,const ClassDef::CompoundType *fi
{
ol.startMemberDescription();
parseDoc(ol,cd->getDefFileName(),cd->getDefLine(),cd->name(),0,cd->briefDescription());
- if ((!cd->briefDescription().isEmpty() && Config::repeatBriefFlag) ||
+ if ((!cd->briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF")) ||
!cd->documentation().isEmpty())
{
ol.pushGeneratorState();
diff --git a/src/code.l b/src/code.l
index 76ad9b2..ce88db8 100644
--- a/src/code.l
+++ b/src/code.l
@@ -1361,7 +1361,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
<RemoveSpecialCComment>\n { g_yyLineNr++; }
<RemoveSpecialCComment>.
<*>\n({B}*"//"[!/][^\n]*\n)+ { // remove special one-line comment
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
g_yyLineNr+=((QCString)yytext).contains('\n');
endCodeLine();
@@ -1378,7 +1378,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<*>\n{B}*"//@"[{}].*\n { // remove one-line group marker
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
g_yyLineNr+=2;
endCodeLine();
@@ -1395,7 +1395,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<*>\n{B}*"/*@"[{}] { // remove one-line group marker
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
g_lastSpecialCContext = YY_START;
g_yyLineNr++;
@@ -1414,7 +1414,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<*>^{B}*"//@"[{}].*\n { // remove one-line group marker
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
g_yyLineNr++;
endCodeLine();
@@ -1431,7 +1431,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<*>^{B}*"/*@"[{}] { // remove multi-line group marker
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
g_lastSpecialCContext = YY_START;
BEGIN(RemoveSpecialCComment);
@@ -1449,7 +1449,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<*>^{B}*"//"[!/][^\n]*\n { // remove special one-line comment
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
g_yyLineNr++;
endCodeLine();
@@ -1466,7 +1466,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<*>"//"[!/][^\n]*\n { // strip special one-line comment
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
char c[2]; c[0]='\n'; c[1]=0;
codifyLines(c);
@@ -1479,7 +1479,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<*>\n{B}*"/*"[!*]/[^/*] {
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
g_lastSpecialCContext = YY_START;
g_yyLineNr++;
@@ -1498,7 +1498,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<*>^{B}*"/*"[!*]/[^/*] { // special C comment block at a new line
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
g_lastSpecialCContext = YY_START;
BEGIN(RemoveSpecialCComment);
@@ -1516,7 +1516,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
}
}
<*>"/*"[!*]/[^/*] { // special C comment block half way a line
- if (Config::stripCommentsFlag)
+ if (Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
g_lastSpecialCContext = YY_START;
BEGIN(RemoveSpecialCComment);
@@ -1533,7 +1533,7 @@ TYPEKW ("bool"|"char"|"double"|"float"|"int"|"long"|"short"|"signed"|"unsigned"
BEGIN(SkipComment);
}
}
-<*>"/*"("!"?)"*/" { if (!Config::stripCommentsFlag)
+<*>"/*"("!"?)"*/" { if (!Config::instance()->getBool("STRIP_CODE_COMMENTS"))
{
startFontClass("comment");
g_code->codify(yytext);
diff --git a/src/config.h b/src/config.h
index 0bdaffa..b67b97c 100644
--- a/src/config.h
+++ b/src/config.h
@@ -1,164 +1,445 @@
-/* This file was generated by configgen on Mon Mar 19 20:34:58 2001
- * from config_templ.h
+#ifndef CONFIG_H
+#define CONFIG_H
+
+#include "qtbc.h"
+#include <qstrlist.h>
+#include <qfile.h>
+#include <qdict.h>
+#include <qlist.h>
+#include <qtextstream.h>
+
+
+/*! \brief Abstract base class for any configuration option.
*
- * DO NOT EDIT!
*/
+class ConfigOption
+{
+ public:
-/******************************************************************************
- *
- *
+ enum OptionType { O_Info, O_List, O_Enum, O_String, O_Int, O_Bool };
+ enum { MAX_OPTION_LENGTH = 23 };
+ ConfigOption(OptionType t) : m_kind(t)
+ {
+ m_spaces.fill(' ',40);
+ }
+ virtual ~ConfigOption()
+ {
+ }
+ void addDependency(const char *dep)
+ {
+ m_dependency = dep;
+ }
+ OptionType kind() const { return m_kind; }
+ virtual void writeTemplate(QTextStream &t,bool sl) = 0;
+ virtual void convertStrToVal() {}
+ virtual void substEnvVars() {}
+ virtual void init() {}
+ QCString name() const { return m_name; }
+ QCString docs() const { return m_doc; }
+ QCString dependsOn() const { return m_dependency; }
+
+ protected:
+
+ QCString convertToComment(const QCString &s)
+ {
+ QCString result;
+ if (s.isEmpty()) return result;
+ else
+ {
+ result+="# ";
+ QCString tmp=s.stripWhiteSpace();
+ char *p=tmp.data();
+ char c;
+ while ((c=*p++))
+ {
+ if (c=='\n') result+="\n# ";
+ else result+=c;
+ }
+ result+='\n';
+ }
+ return result;
+ }
+
+ void writeBoolValue(QTextStream &t,bool v)
+ {
+ if (v) t << "YES"; else t << "NO";
+ }
+
+ void writeIntValue(QTextStream &t,int i)
+ {
+ t << i;
+ }
+
+ void writeStringValue(QTextStream &t,QCString &s)
+ {
+ const char *p=s.data();
+ char c;
+ bool hasBlanks=FALSE;
+ if (p)
+ {
+ while ((c=*p++)!=0 && !hasBlanks) hasBlanks = (c==' ' || c=='\n' || c=='\t');
+ if (hasBlanks)
+ t << "\"" << s << "\"";
+ else
+ t << s;
+ }
+ }
+
+ void writeStringList(QTextStream &t,QStrList &l)
+ {
+ const char *p = l.first();
+ bool first=TRUE;
+ while (p)
+ {
+ char c;
+ const char *s=p;
+ bool hasBlanks=FALSE;
+ while ((c=*p++)!=0 && !hasBlanks) hasBlanks = (c==' ' || c=='\n' || c=='\t');
+ if (!first) t << " ";
+ first=FALSE;
+ if (hasBlanks) t << "\"" << s << "\""; else t << s;
+ p = l.next();
+ if (p) t << " \\" << endl;
+ }
+ }
+
+ QCString m_spaces;
+ QCString m_name;
+ QCString m_doc;
+ QCString m_dependency;
+ OptionType m_kind;
+};
+
+/*! \brief Section marker for grouping the configuration options
*
- * Copyright (C) 1997-2001 by Dimitri van Heesch.
+ */
+class ConfigInfo : public ConfigOption
+{
+ public:
+ ConfigInfo(const char *name,const char *doc)
+ : ConfigOption(O_Info)
+ {
+ m_name = name;
+ m_doc = doc;
+ }
+ void writeTemplate(QTextStream &t, bool sl)
+ {
+ if (!sl)
+ {
+ t << "\n";
+ }
+ t << "#---------------------------------------------------------------------------\n";
+ t << "# " << m_doc << endl;
+ t << "#---------------------------------------------------------------------------\n";
+ }
+};
+
+/*! \brief Option of the list type.
*
- * Permission to use, copy, modify, and distribute this software and its
- * documentation under the terms of the GNU General Public License is hereby
- * granted. No representations are made about the suitability of this software
- * for any purpose. It is provided "as is" without express or implied warranty.
- * See the GNU General Public License for more details.
+ */
+class ConfigList : public ConfigOption
+{
+ public:
+ enum WidgetType { String, File, Dir, FileAndDir };
+ ConfigList(const char *name,const char *doc)
+ : ConfigOption(O_List)
+ {
+ m_name = name;
+ m_doc = doc;
+ m_widgetType = String;
+ }
+ void addValue(const char *v) { m_value.append(v); }
+ void setWidgetType(WidgetType w) { m_widgetType = w; }
+ WidgetType widgetType() const { return m_widgetType; }
+ QStrList *valueRef() { return &m_value; }
+ void writeTemplate(QTextStream &t,bool sl)
+ {
+ if (!sl)
+ {
+ t << endl;
+ t << convertToComment(m_doc);
+ t << endl;
+ }
+ t << m_name << m_spaces.left(MAX_OPTION_LENGTH-m_name.length()) << "= ";
+ writeStringList(t,m_value);
+ t << "\n";
+ }
+ void substEnvVars();
+ private:
+ QStrList m_value;
+ WidgetType m_widgetType;
+};
+
+/*! \brief Option of the enum type.
*
*/
+class ConfigEnum : public ConfigOption
+{
+ public:
+ ConfigEnum(const char *name,const char *doc,const char *defVal)
+ : ConfigOption(O_Enum)
+ {
+ m_name = name;
+ m_doc = doc;
+ m_value = defVal;
+ m_defValue = defVal;
+ }
+ void addValue(const char *v) { m_valueRange.append(v); }
+ QStrListIterator iterator()
+ {
+ return QStrListIterator(m_valueRange);
+ }
+ QCString *valueRef() { return &m_value; }
+ void writeTemplate(QTextStream &t,bool sl)
+ {
+ if (!sl)
+ {
+ t << endl;
+ t << convertToComment(m_doc);
+ t << endl;
+ }
+ t << m_name << m_spaces.left(MAX_OPTION_LENGTH-m_name.length()) << "= ";
+ writeStringValue(t,m_value);
+ t << "\n";
+ }
+ void init() { m_value = m_defValue.copy(); }
-#ifndef CONFIG_H
-#define CONFIG_H
+ private:
+ QStrList m_valueRange;
+ QCString m_value;
+ QCString m_defValue;
+};
-#ifndef DOXYWIZARD
-#include "qtbc.h"
-#endif
-#include <qstrlist.h>
-#include <qfile.h>
+/*! \brief Option of the string type.
+ *
+ */
+class ConfigString : public ConfigOption
+{
+ public:
+ enum WidgetType { String, File, Dir };
+ ConfigString(const char *name,const char *doc)
+ : ConfigOption(O_String)
+ {
+ m_name = name;
+ m_doc = doc;
+ m_widgetType = String;
+ }
+ ~ConfigString()
+ {
+ }
+ void setWidgetType(WidgetType w) { m_widgetType = w; }
+ WidgetType widgetType() const { return m_widgetType; }
+ void setDefaultValue(const char *v) { m_defValue = v; }
+ QCString *valueRef() { return &m_value; }
+ void writeTemplate(QTextStream &t,bool sl)
+ {
+ if (!sl)
+ {
+ t << endl;
+ t << convertToComment(m_doc);
+ t << endl;
+ }
+ t << m_name << m_spaces.left(MAX_OPTION_LENGTH-m_name.length()) << "= ";
+ writeStringValue(t,m_value);
+ t << "\n";
+ }
+ void substEnvVars();
+ void init() { m_value = m_defValue.copy(); }
+
+ private:
+ QCString m_value;
+ QCString m_defValue;
+ WidgetType m_widgetType;
+};
-extern void parseConfig(const QCString &config,const char *fn);
-extern void writeTemplateConfig(QFile *f,bool shortList);
-extern void checkConfig();
-extern void configStrToVal();
-extern void substituteEnvironmentVars();
+/*! \brief Option of the integer type.
+ *
+ */
+class ConfigInt : public ConfigOption
+{
+ public:
+ ConfigInt(const char *name,const char *doc,int minVal,int maxVal,int defVal)
+ : ConfigOption(O_Int)
+ {
+ m_name = name;
+ m_doc = doc;
+ m_value = defVal;
+ m_defValue = defVal;
+ m_minVal = minVal;
+ m_maxVal = maxVal;
+ }
+ QCString *valueStringRef() { return &m_valueString; }
+ int *valueRef() { return &m_value; }
+ int minVal() const { return m_minVal; }
+ int maxVal() const { return m_maxVal; }
+ void convertStrToVal();
+ void writeTemplate(QTextStream &t,bool sl)
+ {
+ if (!sl)
+ {
+ t << endl;
+ t << convertToComment(m_doc);
+ t << endl;
+ }
+ t << m_name << m_spaces.left(MAX_OPTION_LENGTH-m_name.length()) << "= ";
+ writeIntValue(t,m_value);
+ t << "\n";
+ }
+ void init() { m_value = m_defValue; }
+ private:
+ int m_value;
+ int m_defValue;
+ int m_minVal;
+ int m_maxVal;
+ QCString m_valueString;
+};
+
+/*! \brief Option of the boolean type.
+ *
+ */
+class ConfigBool : public ConfigOption
+{
+ public:
+ ConfigBool(const char *name,const char *doc,bool defVal)
+ : ConfigOption(O_Bool)
+ {
+ m_name = name;
+ m_doc = doc;
+ m_value = defVal;
+ m_defValue = defVal;
+ }
+ bool *valueRef() { return &m_value; }
+ void writeTemplate(QTextStream &t,bool sl)
+ {
+ if (!sl)
+ {
+ t << endl;
+ t << convertToComment(m_doc);
+ t << endl;
+ }
+ t << m_name << m_spaces.left(MAX_OPTION_LENGTH-m_name.length()) << "= ";
+ writeBoolValue(t,m_value);
+ t << "\n";
+ }
+ void init() { m_value = m_defValue; }
+ private:
+ bool m_value;
+ bool m_defValue;
+};
-/*! \brief Namespace for configuration variables
+/*! \brief Singleton for configuration variables.
*
- * This struct acts as a namespace that holds the global static variables
+ * This object holds the global static variables
* read from a user-supplied configuration file.
+ * The static member instance() can be used to get
+ * a pointer to the one and only instance.
*/
struct Config
{
- static void init();
-
- static QCString projectName; /*!< the name of the project */
- static QCString projectNumber; /*!< the number of the project */
- static QCString outputDir; /*!< the global output directory */
- static QCString outputLanguage; /*!< the output language */
- static bool extractAllFlag; /*!< generate docs for all classes flag */
- static bool extractPrivateFlag; /*!< generate docs for private members flag */
- static bool extractStaticFlag; /*!< generate docs for static members flag */
- static bool hideMemberFlag; /*!< hide undocumented members. */
- static bool hideClassFlag; /*!< hide undocumented members. */
- static bool briefMemDescFlag; /*!< enable `inline' brief member descr. */
- static bool repeatBriefFlag; /*!< repeat brief descriptions. */
- static bool alwaysDetailsFlag; /*!< show details description even if there is only a brief description? */
- static bool fullPathNameFlag; /*!< using full path name in output */
- static QStrList stripFromPath; /*!< list of candidates to strip from the file path */
- static bool internalDocsFlag; /*!< determines what happens to internal docs. */
- static bool classDiagramFlag; /*!< enable the generation of class diagrams. */
- static bool sourceBrowseFlag; /*!< include source code in documentation. */
- static bool inlineSourceFlag; /*!< inline the definition bodies in the docs? */
- static bool stripCommentsFlag; /*!< strip special comments from code fragments? */
- static bool caseSensitiveNames; /*!< determines if output can be mixed case. */
- static bool hideScopeNames; /*!< hide the name of the scope. */
- static bool verbatimHeaderFlag; /*!< enable/disable generation of verb headers. */
- static bool showIncFileFlag; /*!< show include file in file documentation? */
- static bool autoBriefFlag; /*!< should javadoc comments behaves as Qt comments. */
- static bool inheritDocsFlag; /*!< inheritance of documentation enabled? */
- static bool inlineInfoFlag; /*!< show info about inline members? */
- static bool sortMembersFlag; /*!< sort members alphabetically? */
- static bool distributeDocFlag; /*!< distribute docs over member group? */
- static int tabSize; /*!< number of spaces in a tab */
- static QStrList sectionFilterList; /*!< list of section filters that are enabled */
- static bool generateTodoList; /*!< do we want a todo list? */
- static bool generateTestList; /*!< do we want a test list? */
- static bool generateBugList; /*!< do we want a bug list? */
- static QStrList aliasList; /*!< list of aliases */
- static int maxInitLines; /*!< when do we hide values of variable and defines? */
- static bool optimizeForCFlag; /*!< do we parse C code? */
- static bool showUsedFilesFlag; /*!< do we show the list of used files for classes and structs? */
- static bool quietFlag; /*!< generate progress messages flag */
- static bool warningFlag; /*!< generate warnings flag */
- static bool warningUndocFlag; /*!< generate undocumented warnings */
- static QCString warnFormat; /*!< format of the warning messages */
- static QCString warnLogFile; /*!< log file to write warning to */
- static QStrList inputSources; /*!< list of input files */
- static QStrList filePatternList; /*!< list of file patterns */
- static bool recursiveFlag; /*!< scan directories recursively */
- static QStrList excludeSources; /*!< list of files to exclude from the input */
- static QStrList excludePatternList; /*!< list of patterns to exclude from input */
- static QStrList examplePath; /*!< list of example paths */
- static QStrList examplePatternList; /*!< list of example patterns */
- static QStrList imagePath; /*!< list of image paths */
- static QCString inputFilter; /*!< a filter command that is applied to input files */
- static bool filterForSourceFlag; /*!< do we filter source files? */
- static bool alphaIndexFlag; /*!< should an alphabetical index be generated? */
- static int colsInAlphaIndex; /*!< number of columns in the alphabetical index */
- static QStrList ignorePrefixList; /*!< list of prefixes to ignore for the alphabetical index */
- static bool generateHtml; /*!< generate HTML output */
- static QCString htmlOutputDir; /*!< the directory to put the HTML files */
- static QCString headerFile; /*!< the name of the personal HTML header */
- static QCString footerFile; /*!< the name of the personal HTML footer */
- static QCString htmlStyleSheet; /*!< user defined cascading style sheet */
- static bool htmlAlignMemberFlag; /*!< align members in HTML using tables. */
- static bool htmlHelpFlag; /*!< should html help files be generated? */
- static bool htmlHelpChiFlag; /*!< should chi file be generated? */
- static bool htmlHelpTocFlag; /*!< should a binary table of contents be generated? */
- static bool htmlHelpTocExpandFlag; /*!< should module elements be displayed in the table of contents? */
- static bool noIndexFlag; /*!< generate condensed index flag */
- static int enumValuesPerLine; /*!< number of enum values that are put on one line */
- static bool ftvHelpFlag; /*!< should a folder tree view be generated? */
- static int treeViewWidth; /*!< What is the width of the treeview panel? */
- static bool generateLatex; /*!< generate Latex output */
- static QCString latexOutputDir; /*!< the directory to put the Latex files */
- static bool compactLatexFlag; /*!< generate compact LaTeX documentation. */
- static QCString paperType; /*!< the page type to generate docs for */
- static QStrList extraPackageList; /*!< list of extra LaTeX packages. */
- static QCString latexHeaderFile; /*!< the name of the personal LaTeX header */
- static bool pdfHyperFlag; /*!< generate latex prepared creating hyperlinked pdfs. */
- static bool usePDFLatexFlag; /*!< use pdflatex instead of plain latex */
- static bool latexBatchModeFlag; /*!< continue after latex errors? */
- static bool generateRTF; /*!< generate RTF flag */
- static QCString rtfOutputDir; /*!< the directory to put the RTF files */
- static bool compactRTFFlag; /*!< generate more compact RTF */
- static bool rtfHyperFlag; /*!< generate hyper links in RTF */
- static QCString rtfStylesheetFile; /*!< file to load stylesheet definitions from */
- static QCString rtfExtensionsFile; /*!< file to load rtf extensions from */
- static bool generateMan; /*!< generate Man pages */
- static QCString manOutputDir; /*!< the directory to put the man pages */
- static QCString manExtension; /*!< extension the man page files */
- static bool preprocessingFlag; /*!< enable preprocessing */
- static bool macroExpansionFlag; /*!< expand macros in the source. */
- static bool onlyPredefinedFlag; /*!< expand only predefined macros */
- static bool searchIncludeFlag; /*!< search for included files */
- static QStrList includePath; /*!< list of include paths */
- static QStrList includeFilePatternList; /*!< list of include file patterns */
- static QStrList predefined; /*!< list of predefined macro names. */
- static QStrList expandAsDefinedList; /*!< list of defines to expand */
- static QStrList tagFileList; /*!< list of tag files */
- static QCString genTagFile; /*!< the tag file to generate */
- static bool allExtFlag; /*!< include all external classes flag */
- static QCString perlPath; /*!< the absolute path to perl */
- static bool haveDotFlag; /*!< indicates wether or not dot is present */
- static bool classGraphFlag; /*!< class graph */
- static bool collGraphFlag; /*!< collaboration graph */
- static bool includeGraphFlag; /*!< include graph */
- static bool includedByGraphFlag; /*!< depends on include graph */
- static bool gfxHierarchyFlag; /*!< flag to enable graphical hierarchy */
- static QCString dotPath; /*!< path to the dot tool */
- static int maxDotGraphWidth; /*!< max dot graph width */
- static int maxDotGraphHeight; /*!< max dot graph height */
- static bool generateLegend; /*!< generate legend page */
- static bool dotCleanUp; /*!< remove intermedia dot files? */
- static bool searchEngineFlag; /*!< generate search engine flag */
- static QCString cgiName; /*!< the name of the CGI binary */
- static QCString cgiURL; /*!< the absolute URL to the CGI binary */
- static QCString docURL; /*!< the absolute URL to the documentation */
- static QCString docAbsPath; /*!< the absolute path to the documentation */
- static QCString binAbsPath; /*!< the absolute path to the doxysearch */
- static QStrList extDocPathList; /*!< list of external doc. directories. */
+ public:
+ static Config *instance()
+ {
+ if (m_instance==0) m_instance = new Config;
+ return m_instance;
+ }
+
+ void writeTemplate(QFile *f,bool shortIndex);
+ void convertStrToVal();
+ void substituteEnvironmentVars();
+ void check();
+ void init();
+ void parse(const QCString &config,const char *fn);
+ QListIterator<ConfigOption> iterator()
+ {
+ return QListIterator<ConfigOption>(*m_options);
+ }
+
+ ////////////////////////
+ // get functions
+ ////////////////////////
+ QCString &getString(const char *name) const;
+ QStrList &getList(const char *name) const;
+ QCString &getEnum(const char *name) const;
+ int &getInt(const char *name) const;
+ bool &getBool(const char *name) const;
+ ConfigOption *get(const char *name) const
+ {
+ return m_dict->find(name);
+ }
+
+ ////////////////////////
+ // add functions
+ ////////////////////////
+ ConfigInfo *addInfo(const char *name,const char *doc)
+ {
+ ConfigInfo *result = new ConfigInfo(name,doc);
+ m_options->append(result);
+ return result;
+ }
+ ConfigString *addString(const char *name,
+ const char *doc)
+ {
+ ConfigString *result = new ConfigString(name,doc);
+ m_options->append(result);
+ m_dict->insert(name,result);
+ return result;
+ }
+ ConfigEnum *addEnum(const char *name,
+ const char *doc,
+ const char *defVal)
+ {
+ ConfigEnum *result = new ConfigEnum(name,doc,defVal);
+ m_options->append(result);
+ m_dict->insert(name,result);
+ return result;
+ }
+ ConfigList *addList(const char *name,
+ const char *doc)
+ {
+ ConfigList *result = new ConfigList(name,doc);
+ m_options->append(result);
+ m_dict->insert(name,result);
+ return result;
+ }
+ ConfigInt *addInt(const char *name,
+ const char *doc,
+ int minVal,int maxVal,int defVal)
+ {
+ ConfigInt *result = new ConfigInt(name,doc,minVal,maxVal,defVal);
+ m_options->append(result);
+ m_dict->insert(name,result);
+ return result;
+ }
+ ConfigBool *addBool(const char *name,
+ const char *doc,
+ bool defVal)
+ {
+ ConfigBool *result = new ConfigBool(name,doc,defVal);
+ m_options->append(result);
+ m_dict->insert(name,result);
+ return result;
+ }
+ protected:
+ Config()
+ {
+ m_options = new QList<ConfigOption>;
+ m_dict = new QDict<ConfigOption>(257);
+ m_options->setAutoDelete(TRUE);
+ m_initialized = FALSE;
+ create();
+ }
+ ~Config()
+ {
+ delete m_options;
+ delete m_dict;
+ }
+ void create();
+
+ private:
+ QList<ConfigOption> *m_options;
+ QDict<ConfigOption> *m_dict;
+ static Config *m_instance;
+ bool m_initialized;
};
#endif
diff --git a/src/config.l b/src/config.l
index c31152b..0c1503a 100644
--- a/src/config.l
+++ b/src/config.l
@@ -1,9 +1,3 @@
-/* This file was generated by configgen on Mon Mar 19 20:34:59 2001
- * from config_templ.l
- *
- * DO NOT EDIT!
- */
-
/******************************************************************************
*
*
@@ -69,128 +63,102 @@ void initWarningFormat()
#define YY_NEVER_INTERACTIVE 1
#define YY_NO_UNPUT
-/* -----------------------------------------------------------------
- *
- * exported variables
- */
-
-QCString Config::projectName;
-QCString Config::projectNumber;
-QCString Config::outputDir;
-QCString Config::outputLanguage = "English";
-bool Config::extractAllFlag = FALSE;
-bool Config::extractPrivateFlag = FALSE;
-bool Config::extractStaticFlag = FALSE;
-bool Config::hideMemberFlag = FALSE;
-bool Config::hideClassFlag = FALSE;
-bool Config::briefMemDescFlag = TRUE;
-bool Config::repeatBriefFlag = TRUE;
-bool Config::alwaysDetailsFlag = FALSE;
-bool Config::fullPathNameFlag = FALSE;
-QStrList Config::stripFromPath;
-bool Config::internalDocsFlag = FALSE;
-bool Config::classDiagramFlag = TRUE;
-bool Config::sourceBrowseFlag = FALSE;
-bool Config::inlineSourceFlag = FALSE;
-bool Config::stripCommentsFlag = TRUE;
-bool Config::caseSensitiveNames = TRUE;
-bool Config::hideScopeNames = FALSE;
-bool Config::verbatimHeaderFlag = TRUE;
-bool Config::showIncFileFlag = TRUE;
-bool Config::autoBriefFlag = FALSE;
-bool Config::inheritDocsFlag = TRUE;
-bool Config::inlineInfoFlag = TRUE;
-bool Config::sortMembersFlag = TRUE;
-bool Config::distributeDocFlag = FALSE;
-int Config::tabSize = 8;
-QStrList Config::sectionFilterList;
-bool Config::generateTodoList = TRUE;
-bool Config::generateTestList = TRUE;
-bool Config::generateBugList = TRUE;
-QStrList Config::aliasList;
-int Config::maxInitLines = 30;
-bool Config::optimizeForCFlag = FALSE;
-bool Config::showUsedFilesFlag = TRUE;
-bool Config::quietFlag = FALSE;
-bool Config::warningFlag = TRUE;
-bool Config::warningUndocFlag = TRUE;
-QCString Config::warnFormat = "$file:$line: $text";
-QCString Config::warnLogFile;
-QStrList Config::inputSources;
-QStrList Config::filePatternList;
-bool Config::recursiveFlag = FALSE;
-QStrList Config::excludeSources;
-QStrList Config::excludePatternList;
-QStrList Config::examplePath;
-QStrList Config::examplePatternList;
-QStrList Config::imagePath;
-QCString Config::inputFilter;
-bool Config::filterForSourceFlag = FALSE;
-bool Config::alphaIndexFlag = FALSE;
-int Config::colsInAlphaIndex = 5;
-QStrList Config::ignorePrefixList;
-bool Config::generateHtml = TRUE;
-QCString Config::htmlOutputDir = "html";
-QCString Config::headerFile;
-QCString Config::footerFile;
-QCString Config::htmlStyleSheet;
-bool Config::htmlAlignMemberFlag = TRUE;
-bool Config::htmlHelpFlag = FALSE;
-bool Config::htmlHelpChiFlag = FALSE;
-bool Config::htmlHelpTocFlag = FALSE;
-bool Config::htmlHelpTocExpandFlag = FALSE;
-bool Config::noIndexFlag = FALSE;
-int Config::enumValuesPerLine = 4;
-bool Config::ftvHelpFlag = FALSE;
-int Config::treeViewWidth = 250;
-bool Config::generateLatex = TRUE;
-QCString Config::latexOutputDir = "latex";
-bool Config::compactLatexFlag = FALSE;
-QCString Config::paperType = "a4wide";
-QStrList Config::extraPackageList;
-QCString Config::latexHeaderFile;
-bool Config::pdfHyperFlag = FALSE;
-bool Config::usePDFLatexFlag = FALSE;
-bool Config::latexBatchModeFlag = FALSE;
-bool Config::generateRTF = TRUE;
-QCString Config::rtfOutputDir = "rtf";
-bool Config::compactRTFFlag = FALSE;
-bool Config::rtfHyperFlag = FALSE;
-QCString Config::rtfStylesheetFile;
-QCString Config::rtfExtensionsFile;
-bool Config::generateMan = TRUE;
-QCString Config::manOutputDir = "man";
-QCString Config::manExtension = ".3";
-bool Config::preprocessingFlag = TRUE;
-bool Config::macroExpansionFlag = FALSE;
-bool Config::onlyPredefinedFlag = FALSE;
-bool Config::searchIncludeFlag = TRUE;
-QStrList Config::includePath;
-QStrList Config::includeFilePatternList;
-QStrList Config::predefined;
-QStrList Config::expandAsDefinedList;
-QStrList Config::tagFileList;
-QCString Config::genTagFile;
-bool Config::allExtFlag = FALSE;
-QCString Config::perlPath = "/usr/bin/perl";
-bool Config::haveDotFlag = FALSE;
-bool Config::classGraphFlag = TRUE;
-bool Config::collGraphFlag = TRUE;
-bool Config::includeGraphFlag = TRUE;
-bool Config::includedByGraphFlag = TRUE;
-bool Config::gfxHierarchyFlag = TRUE;
-QCString Config::dotPath;
-int Config::maxDotGraphWidth = 1024;
-int Config::maxDotGraphHeight = 1024;
-bool Config::generateLegend = TRUE;
-bool Config::dotCleanUp = TRUE;
-bool Config::searchEngineFlag = FALSE;
-QCString Config::cgiName = "search.cgi";
-QCString Config::cgiURL;
-QCString Config::docURL;
-QCString Config::docAbsPath;
-QCString Config::binAbsPath = "/usr/local/bin/";
-QStrList Config::extDocPathList;
+Config *Config::m_instance = 0;
+
+void ConfigInt::convertStrToVal()
+{
+ if (!m_valueString.isEmpty())
+ {
+ bool ok;
+ int val = m_valueString.toInt(&ok);
+ if (!ok || val<m_minVal || val>m_maxVal)
+ {
+ warn_cont("Warning: argument of %s is not a valid number in the range [%d..%d]!\n"
+ "Using the default of %d!\n",m_name.data(),m_minVal,m_maxVal,m_value);
+ }
+ m_value=val;
+ }
+}
+
+QCString &Config::getString(const char *name) const
+{
+ ConfigOption *opt = m_dict->find(name);
+ if (opt==0)
+ {
+ err("ConfigOption::getString: Requested unknown option %s!\n",name);
+ exit(1);
+ }
+ else if (opt->kind()!=ConfigOption::O_String)
+ {
+ err("ConfigOption::getString: Requested option %s not of string type!\n",name);
+ exit(1);
+ }
+ return *((ConfigString *)opt)->valueRef();
+}
+
+QStrList &Config::getList(const char *name) const
+{
+ ConfigOption *opt = m_dict->find(name);
+ if (opt==0)
+ {
+ err("ConfigOption::getList: Requested unknown option %s!\n",name);
+ exit(1);
+ }
+ else if (opt->kind()!=ConfigOption::O_List)
+ {
+ err("ConfigOption::getList: Requested option %s not of list type!\n",name);
+ exit(1);
+ }
+ return *((ConfigList *)opt)->valueRef();
+}
+
+QCString &Config::getEnum(const char *name) const
+{
+ ConfigOption *opt = m_dict->find(name);
+ if (opt==0)
+ {
+ err("ConfigOption::getEnum: Requested unknown option %s!\n",name);
+ exit(1);
+ }
+ else if (opt->kind()!=ConfigOption::O_Enum)
+ {
+ err("ConfigOption::getEnum: Requested option %s not of enum type!\n",name);
+ exit(1);
+ }
+ return *((ConfigEnum *)opt)->valueRef();
+}
+
+int &Config::getInt(const char *name) const
+{
+ ConfigOption *opt = m_dict->find(name);
+ if (opt==0)
+ {
+ err("ConfigOption::getInt: Requested unknown option %s!\n",name);
+ exit(1);
+ }
+ else if (opt->kind()!=ConfigOption::O_Int)
+ {
+ err("ConfigOption::getInt: Requested option %s not of integer type!\n",name);
+ exit(1);
+ }
+ return *((ConfigInt *)opt)->valueRef();
+}
+
+bool &Config::getBool(const char *name) const
+{
+ ConfigOption *opt = m_dict->find(name);
+ if (opt==0)
+ {
+ err("ConfigOption::getInt: Requested unknown option %s!\n",name);
+ exit(1);
+ }
+ else if (opt->kind()!=ConfigOption::O_Bool)
+ {
+ err("ConfigOption::getInt: Requested option %s not of integer type!\n",name);
+ exit(1);
+ }
+ return *((ConfigBool *)opt)->valueRef();
+}
/* -----------------------------------------------------------------
*
@@ -229,6 +197,8 @@ static QCString treeViewWidthString;
static QCString maxDotGraphWidthString;
static QCString maxDotGraphHeightString;
+static Config *config;
+
/* -----------------------------------------------------------------
*/
#undef YY_INPUT
@@ -341,6 +311,7 @@ static void readIncludeFile(const char *incName)
%x Start
%x SkipComment
+%x SkipInvalid
%x GetString
%x GetBool
%x GetStrList
@@ -351,143 +322,52 @@ static void readIncludeFile(const char *incName)
%%
<*>\0x0d
-<Start,GetString,GetStrList,GetBool>"#" { BEGIN(SkipComment); }
-<Start>"PROJECT_NAME"[ \t]*"=" { BEGIN(GetString); s=&Config::projectName; s->resize(0); }
-<Start>"PROJECT_NUMBER"[ \t]*"=" { BEGIN(GetString); s=&Config::projectNumber; s->resize(0); }
-<Start>"OUTPUT_DIRECTORY"[ \t]*"=" { BEGIN(GetString); s=&Config::outputDir; s->resize(0); }
-<Start>"OUTPUT_LANGUAGE"[ \t]*"=" { BEGIN(GetString); s=&Config::outputLanguage; s->resize(0); }
-<Start>"EXTRACT_ALL"[ \t]*"=" { BEGIN(GetBool); b=&Config::extractAllFlag; }
-<Start>"EXTRACT_PRIVATE"[ \t]*"=" { BEGIN(GetBool); b=&Config::extractPrivateFlag; }
-<Start>"EXTRACT_STATIC"[ \t]*"=" { BEGIN(GetBool); b=&Config::extractStaticFlag; }
-<Start>"HIDE_UNDOC_MEMBERS"[ \t]*"=" { BEGIN(GetBool); b=&Config::hideMemberFlag; }
-<Start>"HIDE_UNDOC_CLASSES"[ \t]*"=" { BEGIN(GetBool); b=&Config::hideClassFlag; }
-<Start>"BRIEF_MEMBER_DESC"[ \t]*"=" { BEGIN(GetBool); b=&Config::briefMemDescFlag; }
-<Start>"REPEAT_BRIEF"[ \t]*"=" { BEGIN(GetBool); b=&Config::repeatBriefFlag; }
-<Start>"ALWAYS_DETAILED_SEC"[ \t]*"=" { BEGIN(GetBool); b=&Config::alwaysDetailsFlag; }
-<Start>"FULL_PATH_NAMES"[ \t]*"=" { BEGIN(GetBool); b=&Config::fullPathNameFlag; }
-<Start>"STRIP_FROM_PATH"[ \t]*"=" { BEGIN(GetStrList); l=&Config::stripFromPath; l->clear(); elemStr=""; }
-<Start>"STRIP_FROM_PATH"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::stripFromPath; elemStr=""; }
-<Start>"INTERNAL_DOCS"[ \t]*"=" { BEGIN(GetBool); b=&Config::internalDocsFlag; }
-<Start>"CLASS_DIAGRAMS"[ \t]*"=" { BEGIN(GetBool); b=&Config::classDiagramFlag; }
-<Start>"SOURCE_BROWSER"[ \t]*"=" { BEGIN(GetBool); b=&Config::sourceBrowseFlag; }
-<Start>"INLINE_SOURCES"[ \t]*"=" { BEGIN(GetBool); b=&Config::inlineSourceFlag; }
-<Start>"STRIP_CODE_COMMENTS"[ \t]*"=" { BEGIN(GetBool); b=&Config::stripCommentsFlag; }
-<Start>"CASE_SENSE_NAMES"[ \t]*"=" { BEGIN(GetBool); b=&Config::caseSensitiveNames; }
-<Start>"HIDE_SCOPE_NAMES"[ \t]*"=" { BEGIN(GetBool); b=&Config::hideScopeNames; }
-<Start>"VERBATIM_HEADERS"[ \t]*"=" { BEGIN(GetBool); b=&Config::verbatimHeaderFlag; }
-<Start>"SHOW_INCLUDE_FILES"[ \t]*"=" { BEGIN(GetBool); b=&Config::showIncFileFlag; }
-<Start>"JAVADOC_AUTOBRIEF"[ \t]*"=" { BEGIN(GetBool); b=&Config::autoBriefFlag; }
-<Start>"INHERIT_DOCS"[ \t]*"=" { BEGIN(GetBool); b=&Config::inheritDocsFlag; }
-<Start>"INLINE_INFO"[ \t]*"=" { BEGIN(GetBool); b=&Config::inlineInfoFlag; }
-<Start>"SORT_MEMBER_DOCS"[ \t]*"=" { BEGIN(GetBool); b=&Config::sortMembersFlag; }
-<Start>"DISTRIBUTE_GROUP_DOC"[ \t]*"=" { BEGIN(GetBool); b=&Config::distributeDocFlag; }
-<Start>"TAB_SIZE"[ \t]*"=" { BEGIN(GetString); s=&tabSizeString; s->resize(0); }
-<Start>"ENABLED_SECTIONS"[ \t]*"=" { BEGIN(GetStrList); l=&Config::sectionFilterList; l->clear(); elemStr=""; }
-<Start>"ENABLED_SECTIONS"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::sectionFilterList; elemStr=""; }
-<Start>"GENERATE_TODOLIST"[ \t]*"=" { BEGIN(GetBool); b=&Config::generateTodoList; }
-<Start>"GENERATE_TESTLIST"[ \t]*"=" { BEGIN(GetBool); b=&Config::generateTestList; }
-<Start>"GENERATE_BUGLIST"[ \t]*"=" { BEGIN(GetBool); b=&Config::generateBugList; }
-<Start>"ALIASES"[ \t]*"=" { BEGIN(GetStrList); l=&Config::aliasList; l->clear(); elemStr=""; }
-<Start>"ALIASES"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::aliasList; elemStr=""; }
-<Start>"MAX_INITIALIZER_LINES"[ \t]*"=" { BEGIN(GetString); s=&maxInitLinesString; s->resize(0); }
-<Start>"OPTIMIZE_OUTPUT_FOR_C"[ \t]*"=" { BEGIN(GetBool); b=&Config::optimizeForCFlag; }
-<Start>"SHOW_USED_FILES"[ \t]*"=" { BEGIN(GetBool); b=&Config::showUsedFilesFlag; }
-<Start>"QUIET"[ \t]*"=" { BEGIN(GetBool); b=&Config::quietFlag; }
-<Start>"WARNINGS"[ \t]*"=" { BEGIN(GetBool); b=&Config::warningFlag; }
-<Start>"WARN_IF_UNDOCUMENTED"[ \t]*"=" { BEGIN(GetBool); b=&Config::warningUndocFlag; }
-<Start>"WARN_FORMAT"[ \t]*"=" { BEGIN(GetString); s=&Config::warnFormat; s->resize(0); }
-<Start>"WARN_LOGFILE"[ \t]*"=" { BEGIN(GetString); s=&Config::warnLogFile; s->resize(0); }
-<Start>"INPUT"[ \t]*"=" { BEGIN(GetStrList); l=&Config::inputSources; l->clear(); elemStr=""; }
-<Start>"INPUT"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::inputSources; elemStr=""; }
-<Start>"FILE_PATTERNS"[ \t]*"=" { BEGIN(GetStrList); l=&Config::filePatternList; l->clear(); elemStr=""; }
-<Start>"FILE_PATTERNS"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::filePatternList; elemStr=""; }
-<Start>"RECURSIVE"[ \t]*"=" { BEGIN(GetBool); b=&Config::recursiveFlag; }
-<Start>"EXCLUDE"[ \t]*"=" { BEGIN(GetStrList); l=&Config::excludeSources; l->clear(); elemStr=""; }
-<Start>"EXCLUDE"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::excludeSources; elemStr=""; }
-<Start>"EXCLUDE_PATTERNS"[ \t]*"=" { BEGIN(GetStrList); l=&Config::excludePatternList; l->clear(); elemStr=""; }
-<Start>"EXCLUDE_PATTERNS"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::excludePatternList; elemStr=""; }
-<Start>"EXAMPLE_PATH"[ \t]*"=" { BEGIN(GetStrList); l=&Config::examplePath; l->clear(); elemStr=""; }
-<Start>"EXAMPLE_PATH"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::examplePath; elemStr=""; }
-<Start>"EXAMPLE_PATTERNS"[ \t]*"=" { BEGIN(GetStrList); l=&Config::examplePatternList; l->clear(); elemStr=""; }
-<Start>"EXAMPLE_PATTERNS"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::examplePatternList; elemStr=""; }
-<Start>"IMAGE_PATH"[ \t]*"=" { BEGIN(GetStrList); l=&Config::imagePath; l->clear(); elemStr=""; }
-<Start>"IMAGE_PATH"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::imagePath; elemStr=""; }
-<Start>"INPUT_FILTER"[ \t]*"=" { BEGIN(GetString); s=&Config::inputFilter; s->resize(0); }
-<Start>"FILTER_SOURCE_FILES"[ \t]*"=" { BEGIN(GetBool); b=&Config::filterForSourceFlag; }
-<Start>"ALPHABETICAL_INDEX"[ \t]*"=" { BEGIN(GetBool); b=&Config::alphaIndexFlag; }
-<Start>"COLS_IN_ALPHA_INDEX"[ \t]*"=" { BEGIN(GetString); s=&colsInAlphaIndexString; s->resize(0); }
-<Start>"IGNORE_PREFIX"[ \t]*"=" { BEGIN(GetStrList); l=&Config::ignorePrefixList; l->clear(); elemStr=""; }
-<Start>"IGNORE_PREFIX"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::ignorePrefixList; elemStr=""; }
-<Start>"GENERATE_HTML"[ \t]*"=" { BEGIN(GetBool); b=&Config::generateHtml; }
-<Start>"HTML_OUTPUT"[ \t]*"=" { BEGIN(GetString); s=&Config::htmlOutputDir; s->resize(0); }
-<Start>"HTML_HEADER"[ \t]*"=" { BEGIN(GetString); s=&Config::headerFile; s->resize(0); }
-<Start>"HTML_FOOTER"[ \t]*"=" { BEGIN(GetString); s=&Config::footerFile; s->resize(0); }
-<Start>"HTML_STYLESHEET"[ \t]*"=" { BEGIN(GetString); s=&Config::htmlStyleSheet; s->resize(0); }
-<Start>"HTML_ALIGN_MEMBERS"[ \t]*"=" { BEGIN(GetBool); b=&Config::htmlAlignMemberFlag; }
-<Start>"GENERATE_HTMLHELP"[ \t]*"=" { BEGIN(GetBool); b=&Config::htmlHelpFlag; }
-<Start>"GENERATE_CHI"[ \t]*"=" { BEGIN(GetBool); b=&Config::htmlHelpChiFlag; }
-<Start>"BINARY_TOC"[ \t]*"=" { BEGIN(GetBool); b=&Config::htmlHelpTocFlag; }
-<Start>"TOC_EXPAND"[ \t]*"=" { BEGIN(GetBool); b=&Config::htmlHelpTocExpandFlag; }
-<Start>"DISABLE_INDEX"[ \t]*"=" { BEGIN(GetBool); b=&Config::noIndexFlag; }
-<Start>"ENUM_VALUES_PER_LINE"[ \t]*"=" { BEGIN(GetString); s=&enumValuesPerLineString; s->resize(0); }
-<Start>"GENERATE_TREEVIEW"[ \t]*"=" { BEGIN(GetBool); b=&Config::ftvHelpFlag; }
-<Start>"TREEVIEW_WIDTH"[ \t]*"=" { BEGIN(GetString); s=&treeViewWidthString; s->resize(0); }
-<Start>"GENERATE_LATEX"[ \t]*"=" { BEGIN(GetBool); b=&Config::generateLatex; }
-<Start>"LATEX_OUTPUT"[ \t]*"=" { BEGIN(GetString); s=&Config::latexOutputDir; s->resize(0); }
-<Start>"COMPACT_LATEX"[ \t]*"=" { BEGIN(GetBool); b=&Config::compactLatexFlag; }
-<Start>"PAPER_TYPE"[ \t]*"=" { BEGIN(GetString); s=&Config::paperType; s->resize(0); }
-<Start>"EXTRA_PACKAGES"[ \t]*"=" { BEGIN(GetStrList); l=&Config::extraPackageList; l->clear(); elemStr=""; }
-<Start>"EXTRA_PACKAGES"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::extraPackageList; elemStr=""; }
-<Start>"LATEX_HEADER"[ \t]*"=" { BEGIN(GetString); s=&Config::latexHeaderFile; s->resize(0); }
-<Start>"PDF_HYPERLINKS"[ \t]*"=" { BEGIN(GetBool); b=&Config::pdfHyperFlag; }
-<Start>"USE_PDFLATEX"[ \t]*"=" { BEGIN(GetBool); b=&Config::usePDFLatexFlag; }
-<Start>"LATEX_BATCHMODE"[ \t]*"=" { BEGIN(GetBool); b=&Config::latexBatchModeFlag; }
-<Start>"GENERATE_RTF"[ \t]*"=" { BEGIN(GetBool); b=&Config::generateRTF; }
-<Start>"RTF_OUTPUT"[ \t]*"=" { BEGIN(GetString); s=&Config::rtfOutputDir; s->resize(0); }
-<Start>"COMPACT_RTF"[ \t]*"=" { BEGIN(GetBool); b=&Config::compactRTFFlag; }
-<Start>"RTF_HYPERLINKS"[ \t]*"=" { BEGIN(GetBool); b=&Config::rtfHyperFlag; }
-<Start>"RTF_STYLESHEET_FILE"[ \t]*"=" { BEGIN(GetString); s=&Config::rtfStylesheetFile; s->resize(0); }
-<Start>"RTF_EXTENSIONS_FILE"[ \t]*"=" { BEGIN(GetString); s=&Config::rtfExtensionsFile; s->resize(0); }
-<Start>"GENERATE_MAN"[ \t]*"=" { BEGIN(GetBool); b=&Config::generateMan; }
-<Start>"MAN_OUTPUT"[ \t]*"=" { BEGIN(GetString); s=&Config::manOutputDir; s->resize(0); }
-<Start>"MAN_EXTENSION"[ \t]*"=" { BEGIN(GetString); s=&Config::manExtension; s->resize(0); }
-<Start>"ENABLE_PREPROCESSING"[ \t]*"=" { BEGIN(GetBool); b=&Config::preprocessingFlag; }
-<Start>"MACRO_EXPANSION"[ \t]*"=" { BEGIN(GetBool); b=&Config::macroExpansionFlag; }
-<Start>"EXPAND_ONLY_PREDEF"[ \t]*"=" { BEGIN(GetBool); b=&Config::onlyPredefinedFlag; }
-<Start>"SEARCH_INCLUDES"[ \t]*"=" { BEGIN(GetBool); b=&Config::searchIncludeFlag; }
-<Start>"INCLUDE_PATH"[ \t]*"=" { BEGIN(GetStrList); l=&Config::includePath; l->clear(); elemStr=""; }
-<Start>"INCLUDE_PATH"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::includePath; elemStr=""; }
-<Start>"INCLUDE_FILE_PATTERNS"[ \t]*"=" { BEGIN(GetStrList); l=&Config::includeFilePatternList; l->clear(); elemStr=""; }
-<Start>"INCLUDE_FILE_PATTERNS"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::includeFilePatternList; elemStr=""; }
-<Start>"PREDEFINED"[ \t]*"=" { BEGIN(GetStrList); l=&Config::predefined; l->clear(); elemStr=""; }
-<Start>"PREDEFINED"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::predefined; elemStr=""; }
-<Start>"EXPAND_AS_DEFINED"[ \t]*"=" { BEGIN(GetStrList); l=&Config::expandAsDefinedList; l->clear(); elemStr=""; }
-<Start>"EXPAND_AS_DEFINED"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::expandAsDefinedList; elemStr=""; }
-<Start>"TAGFILES"[ \t]*"=" { BEGIN(GetStrList); l=&Config::tagFileList; l->clear(); elemStr=""; }
-<Start>"TAGFILES"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::tagFileList; elemStr=""; }
-<Start>"GENERATE_TAGFILE"[ \t]*"=" { BEGIN(GetString); s=&Config::genTagFile; s->resize(0); }
-<Start>"ALLEXTERNALS"[ \t]*"=" { BEGIN(GetBool); b=&Config::allExtFlag; }
-<Start>"PERL_PATH"[ \t]*"=" { BEGIN(GetString); s=&Config::perlPath; s->resize(0); }
-<Start>"HAVE_DOT"[ \t]*"=" { BEGIN(GetBool); b=&Config::haveDotFlag; }
-<Start>"CLASS_GRAPH"[ \t]*"=" { BEGIN(GetBool); b=&Config::classGraphFlag; }
-<Start>"COLLABORATION_GRAPH"[ \t]*"=" { BEGIN(GetBool); b=&Config::collGraphFlag; }
-<Start>"INCLUDE_GRAPH"[ \t]*"=" { BEGIN(GetBool); b=&Config::includeGraphFlag; }
-<Start>"INCLUDED_BY_GRAPH"[ \t]*"=" { BEGIN(GetBool); b=&Config::includedByGraphFlag; }
-<Start>"GRAPHICAL_HIERARCHY"[ \t]*"=" { BEGIN(GetBool); b=&Config::gfxHierarchyFlag; }
-<Start>"DOT_PATH"[ \t]*"=" { BEGIN(GetString); s=&Config::dotPath; s->resize(0); }
-<Start>"MAX_DOT_GRAPH_WIDTH"[ \t]*"=" { BEGIN(GetString); s=&maxDotGraphWidthString; s->resize(0); }
-<Start>"MAX_DOT_GRAPH_HEIGHT"[ \t]*"=" { BEGIN(GetString); s=&maxDotGraphHeightString; s->resize(0); }
-<Start>"GENERATE_LEGEND"[ \t]*"=" { BEGIN(GetBool); b=&Config::generateLegend; }
-<Start>"DOT_CLEANUP"[ \t]*"=" { BEGIN(GetBool); b=&Config::dotCleanUp; }
-<Start>"SEARCHENGINE"[ \t]*"=" { BEGIN(GetBool); b=&Config::searchEngineFlag; }
-<Start>"CGI_NAME"[ \t]*"=" { BEGIN(GetString); s=&Config::cgiName; s->resize(0); }
-<Start>"CGI_URL"[ \t]*"=" { BEGIN(GetString); s=&Config::cgiURL; s->resize(0); }
-<Start>"DOC_URL"[ \t]*"=" { BEGIN(GetString); s=&Config::docURL; s->resize(0); }
-<Start>"DOC_ABSPATH"[ \t]*"=" { BEGIN(GetString); s=&Config::docAbsPath; s->resize(0); }
-<Start>"BIN_ABSPATH"[ \t]*"=" { BEGIN(GetString); s=&Config::binAbsPath; s->resize(0); }
-<Start>"EXT_DOC_PATHS"[ \t]*"=" { BEGIN(GetStrList); l=&Config::extDocPathList; l->clear(); elemStr=""; }
-<Start>"EXT_DOC_PATHS"[ \t]*"+=" { BEGIN(GetStrList); l=&Config::extDocPathList; elemStr=""; }
-
+<Start,GetString,GetStrList,GetBool,SkipInvalid>"#" { BEGIN(SkipComment); }
+<Start>[a-z_A-Z][a-z_A-Z0-9]*[ \t]*"=" { QCString cmd=yytext;
+ cmd=cmd.left(cmd.length()-1).stripWhiteSpace();
+ ConfigOption *option = config->get(cmd);
+ if (option==0) // oops not known
+ {
+ err("Warning: ignoring unsupported tag `%s' at line %d, file %s\n",
+ yytext,yyLineNr,yyFileName.data());
+ BEGIN(SkipInvalid);
+ }
+ else // known tag
+ {
+ switch(option->kind())
+ {
+ case ConfigOption::O_Info:
+ // shouldn't get here!
+ BEGIN(SkipInvalid);
+ break;
+ case ConfigOption::O_List:
+ l = ((ConfigList *)option)->valueRef();
+ l->clear();
+ elemStr="";
+ BEGIN(GetStrList);
+ break;
+ case ConfigOption::O_Enum:
+ s = ((ConfigEnum *)option)->valueRef();
+ s->resize(0);
+ BEGIN(GetString);
+ break;
+ case ConfigOption::O_String:
+ s = ((ConfigString *)option)->valueRef();
+ s->resize(0);
+ BEGIN(GetString);
+ break;
+ case ConfigOption::O_Int:
+ s = ((ConfigInt *)option)->valueStringRef();
+ s->resize(0);
+ BEGIN(GetString);
+ break;
+ case ConfigOption::O_Bool:
+ b = ((ConfigBool *)option)->valueRef();
+ BEGIN(GetBool);
+ break;
+ }
+ }
+ }
<Start>"@INCLUDE_PATH"[ \t]*"=" { BEGIN(GetStrList); l=&includePathList; l->clear(); elemStr=""; }
/* include a config file */
<Start>"@INCLUDE"[ \t]*"=" { BEGIN(Include);}
@@ -518,7 +398,7 @@ static void readIncludeFile(const char *incName)
}
<Start>[a-z_A-Z0-9]+ { err("Warning: ignoring unknown tag `%s' at line %d, file %s\n",yytext,yyLineNr,yyFileName.data()); }
-<GetString,GetBool>\n { yyLineNr++; BEGIN(Start); }
+<GetString,GetBool,SkipInvalid>\n { yyLineNr++; BEGIN(Start); }
<GetStrList>\n {
yyLineNr++;
if (!elemStr.isEmpty())
@@ -537,7 +417,7 @@ static void readIncludeFile(const char *incName)
elemStr.resize(0);
}
<GetString>[^ \"\t\r\n]+ { (*s)+=yytext; }
-<GetString,GetStrList>"\"" { lastState=YY_START;
+<GetString,GetStrList,SkipInvalid>"\"" { lastState=YY_START;
BEGIN(GetQuotedString);
tmpString.resize(0);
}
@@ -561,9 +441,9 @@ static void readIncludeFile(const char *incName)
<GetBool>[a-zA-Z]+ {
QCString bs=yytext;
bs=bs.upper();
- if (bs=="YES")
+ if (bs=="YES" || bs=="1")
*b=TRUE;
- else if (bs=="NO")
+ else if (bs=="NO" || bs=="0")
*b=FALSE;
else
{
@@ -587,387 +467,7 @@ static void readIncludeFile(const char *incName)
/*@ ----------------------------------------------------------------------------
*/
-
-void dumpConfig()
-{
- printf("# General configuration options\n");
- printf("projectName=`%s'\n",Config::projectName.data());
- printf("projectNumber=`%s'\n",Config::projectNumber.data());
- printf("outputDir=`%s'\n",Config::outputDir.data());
- printf("outputLanguage=`%s'\n",Config::outputLanguage.data());
- printf("extractAllFlag=`%d'\n",Config::extractAllFlag);
- printf("extractPrivateFlag=`%d'\n",Config::extractPrivateFlag);
- printf("extractStaticFlag=`%d'\n",Config::extractStaticFlag);
- printf("hideMemberFlag=`%d'\n",Config::hideMemberFlag);
- printf("hideClassFlag=`%d'\n",Config::hideClassFlag);
- printf("briefMemDescFlag=`%d'\n",Config::briefMemDescFlag);
- printf("repeatBriefFlag=`%d'\n",Config::repeatBriefFlag);
- printf("alwaysDetailsFlag=`%d'\n",Config::alwaysDetailsFlag);
- printf("fullPathNameFlag=`%d'\n",Config::fullPathNameFlag);
- {
- char *is=Config::stripFromPath.first();
- while (is)
- {
- printf("stripFromPath=`%s'\n",is);
- is=Config::stripFromPath.next();
- }
- }
- printf("internalDocsFlag=`%d'\n",Config::internalDocsFlag);
- printf("classDiagramFlag=`%d'\n",Config::classDiagramFlag);
- printf("sourceBrowseFlag=`%d'\n",Config::sourceBrowseFlag);
- printf("inlineSourceFlag=`%d'\n",Config::inlineSourceFlag);
- printf("stripCommentsFlag=`%d'\n",Config::stripCommentsFlag);
- printf("caseSensitiveNames=`%d'\n",Config::caseSensitiveNames);
- printf("hideScopeNames=`%d'\n",Config::hideScopeNames);
- printf("verbatimHeaderFlag=`%d'\n",Config::verbatimHeaderFlag);
- printf("showIncFileFlag=`%d'\n",Config::showIncFileFlag);
- printf("autoBriefFlag=`%d'\n",Config::autoBriefFlag);
- printf("inheritDocsFlag=`%d'\n",Config::inheritDocsFlag);
- printf("inlineInfoFlag=`%d'\n",Config::inlineInfoFlag);
- printf("sortMembersFlag=`%d'\n",Config::sortMembersFlag);
- printf("distributeDocFlag=`%d'\n",Config::distributeDocFlag);
- printf("tabSize=`%d'\n",Config::tabSize);
- {
- char *is=Config::sectionFilterList.first();
- while (is)
- {
- printf("sectionFilterList=`%s'\n",is);
- is=Config::sectionFilterList.next();
- }
- }
- printf("generateTodoList=`%d'\n",Config::generateTodoList);
- printf("generateTestList=`%d'\n",Config::generateTestList);
- printf("generateBugList=`%d'\n",Config::generateBugList);
- {
- char *is=Config::aliasList.first();
- while (is)
- {
- printf("aliasList=`%s'\n",is);
- is=Config::aliasList.next();
- }
- }
- printf("maxInitLines=`%d'\n",Config::maxInitLines);
- printf("optimizeForCFlag=`%d'\n",Config::optimizeForCFlag);
- printf("showUsedFilesFlag=`%d'\n",Config::showUsedFilesFlag);
- printf("# configuration options related to warning and progress messages\n");
- printf("quietFlag=`%d'\n",Config::quietFlag);
- printf("warningFlag=`%d'\n",Config::warningFlag);
- printf("warningUndocFlag=`%d'\n",Config::warningUndocFlag);
- printf("warnFormat=`%s'\n",Config::warnFormat.data());
- printf("warnLogFile=`%s'\n",Config::warnLogFile.data());
- printf("# configuration options related to the input files\n");
- {
- char *is=Config::inputSources.first();
- while (is)
- {
- printf("inputSources=`%s'\n",is);
- is=Config::inputSources.next();
- }
- }
- {
- char *is=Config::filePatternList.first();
- while (is)
- {
- printf("filePatternList=`%s'\n",is);
- is=Config::filePatternList.next();
- }
- }
- printf("recursiveFlag=`%d'\n",Config::recursiveFlag);
- {
- char *is=Config::excludeSources.first();
- while (is)
- {
- printf("excludeSources=`%s'\n",is);
- is=Config::excludeSources.next();
- }
- }
- {
- char *is=Config::excludePatternList.first();
- while (is)
- {
- printf("excludePatternList=`%s'\n",is);
- is=Config::excludePatternList.next();
- }
- }
- {
- char *is=Config::examplePath.first();
- while (is)
- {
- printf("examplePath=`%s'\n",is);
- is=Config::examplePath.next();
- }
- }
- {
- char *is=Config::examplePatternList.first();
- while (is)
- {
- printf("examplePatternList=`%s'\n",is);
- is=Config::examplePatternList.next();
- }
- }
- {
- char *is=Config::imagePath.first();
- while (is)
- {
- printf("imagePath=`%s'\n",is);
- is=Config::imagePath.next();
- }
- }
- printf("inputFilter=`%s'\n",Config::inputFilter.data());
- printf("filterForSourceFlag=`%d'\n",Config::filterForSourceFlag);
- printf("# configuration options related to the alphabetical class index\n");
- printf("alphaIndexFlag=`%d'\n",Config::alphaIndexFlag);
- printf("colsInAlphaIndex=`%d'\n",Config::colsInAlphaIndex);
- {
- char *is=Config::ignorePrefixList.first();
- while (is)
- {
- printf("ignorePrefixList=`%s'\n",is);
- is=Config::ignorePrefixList.next();
- }
- }
- printf("# configuration options related to the HTML output\n");
- printf("generateHtml=`%d'\n",Config::generateHtml);
- printf("htmlOutputDir=`%s'\n",Config::htmlOutputDir.data());
- printf("headerFile=`%s'\n",Config::headerFile.data());
- printf("footerFile=`%s'\n",Config::footerFile.data());
- printf("htmlStyleSheet=`%s'\n",Config::htmlStyleSheet.data());
- printf("htmlAlignMemberFlag=`%d'\n",Config::htmlAlignMemberFlag);
- printf("htmlHelpFlag=`%d'\n",Config::htmlHelpFlag);
- printf("htmlHelpChiFlag=`%d'\n",Config::htmlHelpChiFlag);
- printf("htmlHelpTocFlag=`%d'\n",Config::htmlHelpTocFlag);
- printf("htmlHelpTocExpandFlag=`%d'\n",Config::htmlHelpTocExpandFlag);
- printf("noIndexFlag=`%d'\n",Config::noIndexFlag);
- printf("enumValuesPerLine=`%d'\n",Config::enumValuesPerLine);
- printf("ftvHelpFlag=`%d'\n",Config::ftvHelpFlag);
- printf("treeViewWidth=`%d'\n",Config::treeViewWidth);
- printf("# configuration options related to the LaTeX output\n");
- printf("generateLatex=`%d'\n",Config::generateLatex);
- printf("latexOutputDir=`%s'\n",Config::latexOutputDir.data());
- printf("compactLatexFlag=`%d'\n",Config::compactLatexFlag);
- printf("paperType=`%s'\n",Config::paperType.data());
- {
- char *is=Config::extraPackageList.first();
- while (is)
- {
- printf("extraPackageList=`%s'\n",is);
- is=Config::extraPackageList.next();
- }
- }
- printf("latexHeaderFile=`%s'\n",Config::latexHeaderFile.data());
- printf("pdfHyperFlag=`%d'\n",Config::pdfHyperFlag);
- printf("usePDFLatexFlag=`%d'\n",Config::usePDFLatexFlag);
- printf("latexBatchModeFlag=`%d'\n",Config::latexBatchModeFlag);
- printf("# configuration options related to the RTF output\n");
- printf("generateRTF=`%d'\n",Config::generateRTF);
- printf("rtfOutputDir=`%s'\n",Config::rtfOutputDir.data());
- printf("compactRTFFlag=`%d'\n",Config::compactRTFFlag);
- printf("rtfHyperFlag=`%d'\n",Config::rtfHyperFlag);
- printf("rtfStylesheetFile=`%s'\n",Config::rtfStylesheetFile.data());
- printf("rtfExtensionsFile=`%s'\n",Config::rtfExtensionsFile.data());
- printf("# configuration options related to the man page output\n");
- printf("generateMan=`%d'\n",Config::generateMan);
- printf("manOutputDir=`%s'\n",Config::manOutputDir.data());
- printf("manExtension=`%s'\n",Config::manExtension.data());
- printf("# Configuration options related to the preprocessor \n");
- printf("preprocessingFlag=`%d'\n",Config::preprocessingFlag);
- printf("macroExpansionFlag=`%d'\n",Config::macroExpansionFlag);
- printf("onlyPredefinedFlag=`%d'\n",Config::onlyPredefinedFlag);
- printf("searchIncludeFlag=`%d'\n",Config::searchIncludeFlag);
- {
- char *is=Config::includePath.first();
- while (is)
- {
- printf("includePath=`%s'\n",is);
- is=Config::includePath.next();
- }
- }
- {
- char *is=Config::includeFilePatternList.first();
- while (is)
- {
- printf("includeFilePatternList=`%s'\n",is);
- is=Config::includeFilePatternList.next();
- }
- }
- {
- char *is=Config::predefined.first();
- while (is)
- {
- printf("predefined=`%s'\n",is);
- is=Config::predefined.next();
- }
- }
- {
- char *is=Config::expandAsDefinedList.first();
- while (is)
- {
- printf("expandAsDefinedList=`%s'\n",is);
- is=Config::expandAsDefinedList.next();
- }
- }
- printf("# Configuration::addtions related to external references \n");
- {
- char *is=Config::tagFileList.first();
- while (is)
- {
- printf("tagFileList=`%s'\n",is);
- is=Config::tagFileList.next();
- }
- }
- printf("genTagFile=`%s'\n",Config::genTagFile.data());
- printf("allExtFlag=`%d'\n",Config::allExtFlag);
- printf("perlPath=`%s'\n",Config::perlPath.data());
- printf("# Configuration options related to the dot tool \n");
- printf("haveDotFlag=`%d'\n",Config::haveDotFlag);
- printf("classGraphFlag=`%d'\n",Config::classGraphFlag);
- printf("collGraphFlag=`%d'\n",Config::collGraphFlag);
- printf("includeGraphFlag=`%d'\n",Config::includeGraphFlag);
- printf("includedByGraphFlag=`%d'\n",Config::includedByGraphFlag);
- printf("gfxHierarchyFlag=`%d'\n",Config::gfxHierarchyFlag);
- printf("dotPath=`%s'\n",Config::dotPath.data());
- printf("maxDotGraphWidth=`%d'\n",Config::maxDotGraphWidth);
- printf("maxDotGraphHeight=`%d'\n",Config::maxDotGraphHeight);
- printf("generateLegend=`%d'\n",Config::generateLegend);
- printf("dotCleanUp=`%d'\n",Config::dotCleanUp);
- printf("# Configuration::addtions related to the search engine \n");
- printf("searchEngineFlag=`%d'\n",Config::searchEngineFlag);
- printf("cgiName=`%s'\n",Config::cgiName.data());
- printf("cgiURL=`%s'\n",Config::cgiURL.data());
- printf("docURL=`%s'\n",Config::docURL.data());
- printf("docAbsPath=`%s'\n",Config::docAbsPath.data());
- printf("binAbsPath=`%s'\n",Config::binAbsPath.data());
- {
- char *is=Config::extDocPathList.first();
- while (is)
- {
- printf("extDocPathList=`%s'\n",is);
- is=Config::extDocPathList.next();
- }
- }
-}
-
-void Config::init()
-{
- Config::projectName.resize(0);
- Config::projectNumber.resize(0);
- Config::outputDir.resize(0);
- Config::outputLanguage = "English";
- Config::extractAllFlag = FALSE;
- Config::extractPrivateFlag = FALSE;
- Config::extractStaticFlag = FALSE;
- Config::hideMemberFlag = FALSE;
- Config::hideClassFlag = FALSE;
- Config::briefMemDescFlag = TRUE;
- Config::repeatBriefFlag = TRUE;
- Config::alwaysDetailsFlag = FALSE;
- Config::fullPathNameFlag = FALSE;
- Config::stripFromPath.clear();
- Config::internalDocsFlag = FALSE;
- Config::classDiagramFlag = TRUE;
- Config::sourceBrowseFlag = FALSE;
- Config::inlineSourceFlag = FALSE;
- Config::stripCommentsFlag = TRUE;
- Config::caseSensitiveNames = TRUE;
- Config::hideScopeNames = FALSE;
- Config::verbatimHeaderFlag = TRUE;
- Config::showIncFileFlag = TRUE;
- Config::autoBriefFlag = FALSE;
- Config::inheritDocsFlag = TRUE;
- Config::inlineInfoFlag = TRUE;
- Config::sortMembersFlag = TRUE;
- Config::distributeDocFlag = FALSE;
- Config::tabSize = 8;
- Config::sectionFilterList.clear();
- Config::generateTodoList = TRUE;
- Config::generateTestList = TRUE;
- Config::generateBugList = TRUE;
- Config::aliasList.clear();
- Config::maxInitLines = 30;
- Config::optimizeForCFlag = FALSE;
- Config::showUsedFilesFlag = TRUE;
- Config::quietFlag = FALSE;
- Config::warningFlag = TRUE;
- Config::warningUndocFlag = TRUE;
- Config::warnFormat = "$file:$line: $text";
- Config::warnLogFile.resize(0);
- Config::inputSources.clear();
- Config::filePatternList.clear();
- Config::recursiveFlag = FALSE;
- Config::excludeSources.clear();
- Config::excludePatternList.clear();
- Config::examplePath.clear();
- Config::examplePatternList.clear();
- Config::imagePath.clear();
- Config::inputFilter.resize(0);
- Config::filterForSourceFlag = FALSE;
- Config::alphaIndexFlag = FALSE;
- Config::colsInAlphaIndex = 5;
- Config::ignorePrefixList.clear();
- Config::generateHtml = TRUE;
- Config::htmlOutputDir = "html";
- Config::headerFile.resize(0);
- Config::footerFile.resize(0);
- Config::htmlStyleSheet.resize(0);
- Config::htmlAlignMemberFlag = TRUE;
- Config::htmlHelpFlag = FALSE;
- Config::htmlHelpChiFlag = FALSE;
- Config::htmlHelpTocFlag = FALSE;
- Config::htmlHelpTocExpandFlag = FALSE;
- Config::noIndexFlag = FALSE;
- Config::enumValuesPerLine = 4;
- Config::ftvHelpFlag = FALSE;
- Config::treeViewWidth = 250;
- Config::generateLatex = TRUE;
- Config::latexOutputDir = "latex";
- Config::compactLatexFlag = FALSE;
- Config::paperType = "a4wide";
- Config::extraPackageList.clear();
- Config::latexHeaderFile.resize(0);
- Config::pdfHyperFlag = FALSE;
- Config::usePDFLatexFlag = FALSE;
- Config::latexBatchModeFlag = FALSE;
- Config::generateRTF = TRUE;
- Config::rtfOutputDir = "rtf";
- Config::compactRTFFlag = FALSE;
- Config::rtfHyperFlag = FALSE;
- Config::rtfStylesheetFile.resize(0);
- Config::rtfExtensionsFile.resize(0);
- Config::generateMan = TRUE;
- Config::manOutputDir = "man";
- Config::manExtension = ".3";
- Config::preprocessingFlag = TRUE;
- Config::macroExpansionFlag = FALSE;
- Config::onlyPredefinedFlag = FALSE;
- Config::searchIncludeFlag = TRUE;
- Config::includePath.clear();
- Config::includeFilePatternList.clear();
- Config::predefined.clear();
- Config::expandAsDefinedList.clear();
- Config::tagFileList.clear();
- Config::genTagFile.resize(0);
- Config::allExtFlag = FALSE;
- Config::perlPath = "/usr/bin/perl";
- Config::haveDotFlag = FALSE;
- Config::classGraphFlag = TRUE;
- Config::collGraphFlag = TRUE;
- Config::includeGraphFlag = TRUE;
- Config::includedByGraphFlag = TRUE;
- Config::gfxHierarchyFlag = TRUE;
- Config::dotPath.resize(0);
- Config::maxDotGraphWidth = 1024;
- Config::maxDotGraphHeight = 1024;
- Config::generateLegend = TRUE;
- Config::dotCleanUp = TRUE;
- Config::searchEngineFlag = FALSE;
- Config::cgiName = "search.cgi";
- Config::cgiURL.resize(0);
- Config::docURL.resize(0);
- Config::docAbsPath.resize(0);
- Config::binAbsPath = "/usr/local/bin/";
- Config::extDocPathList.clear();
-}
-
+#if 0
static void writeBoolValue(QTextStream &t,bool v)
{
if (v) t << "YES"; else t << "NO";
@@ -1010,8 +510,9 @@ static void writeStringList(QTextStream &t,QStrList &l)
if (p) t << " \\" << endl;
}
}
+#endif
-void writeTemplateConfig(QFile *f,bool sl)
+void Config::writeTemplate(QFile *f,bool sl)
{
QTextStream t(f);
#ifdef DOXYWIZARD
@@ -1030,1553 +531,21 @@ void writeTemplateConfig(QFile *f,bool sl)
t << "# TAG += value [value, ...]\n";
t << "# Values that contain spaces should be placed between quotes (\" \")\n";
}
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# General configuration options\n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# The PROJECT_NAME tag is a single word (or a sequence of words surrounded \n";
- t << "# by quotes) that should identify the project. \n";
- t << "\n";
- }
- t << "PROJECT_NAME = ";
- writeStringValue(t,Config::projectName);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The PROJECT_NUMBER tag can be used to enter a project or revision number. \n";
- t << "# This could be handy for archiving the generated documentation or \n";
- t << "# if some version control system is used.\n";
- t << "\n";
- }
- t << "PROJECT_NUMBER = ";
- writeStringValue(t,Config::projectNumber);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) \n";
- t << "# base path where the generated documentation will be put. \n";
- t << "# If a relative path is entered, it will be relative to the location \n";
- t << "# where doxygen was started. If left blank the current directory will be used.\n";
- t << "\n";
- }
- t << "OUTPUT_DIRECTORY = ";
- writeStringValue(t,Config::outputDir);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The OUTPUT_LANGUAGE tag is used to specify the language in which all \n";
- t << "# documentation generated by doxygen is written. Doxygen will use this \n";
- t << "# information to generate all constant output in the proper language. \n";
- t << "# The default language is English, other supported languages are: \n";
- t << "# Dutch, French, Italian, Czech, Swedish, German, Finnish, Japanese, \n";
- t << "# Korean, Hungarian, Norwegian, Spanish, Romanian, Russian, Croatian, \n";
- t << "# Polish, Portuguese and Slovene.\n";
- t << "\n";
- }
- t << "OUTPUT_LANGUAGE = ";
- writeStringValue(t,Config::outputLanguage);
- t << "\n";
- if (!sl)
+ ConfigOption *option = m_options->first();
+ while (option)
{
- t << "\n";
- t << "# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in \n";
- t << "# documentation are documented, even if no documentation was available. \n";
- t << "# Private class members and static file members will be hidden unless \n";
- t << "# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES \n";
- t << "\n";
+ option->writeTemplate(t,sl);
+ option = m_options->next();
}
- t << "EXTRACT_ALL = ";
- writeBoolValue(t,Config::extractAllFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the EXTRACT_PRIVATE tag is set to YES all private members of a class \n";
- t << "# will be included in the documentation. \n";
- t << "\n";
- }
- t << "EXTRACT_PRIVATE = ";
- writeBoolValue(t,Config::extractPrivateFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the EXTRACT_STATIC tag is set to YES all static members of a file \n";
- t << "# will be included in the documentation. \n";
- t << "\n";
- }
- t << "EXTRACT_STATIC = ";
- writeBoolValue(t,Config::extractStaticFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all \n";
- t << "# undocumented members of documented classes, files or namespaces. \n";
- t << "# If set to NO (the default) these members will be included in the \n";
- t << "# various overviews, but no documentation section is generated. \n";
- t << "# This option has no effect if EXTRACT_ALL is enabled. \n";
- t << "\n";
- }
- t << "HIDE_UNDOC_MEMBERS = ";
- writeBoolValue(t,Config::hideMemberFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all \n";
- t << "# undocumented classes that are normally visible in the class hierarchy. \n";
- t << "# If set to NO (the default) these class will be included in the various \n";
- t << "# overviews. This option has no effect if EXTRACT_ALL is enabled. \n";
- t << "\n";
- }
- t << "HIDE_UNDOC_CLASSES = ";
- writeBoolValue(t,Config::hideClassFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will \n";
- t << "# include brief member descriptions after the members that are listed in \n";
- t << "# the file and class documentation (similar to JavaDoc). \n";
- t << "# Set to NO to disable this. \n";
- t << "\n";
- }
- t << "BRIEF_MEMBER_DESC = ";
- writeBoolValue(t,Config::briefMemDescFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend \n";
- t << "# the brief description of a member or function before the detailed description. \n";
- t << "# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the \n";
- t << "# brief descriptions will be completely suppressed. \n";
- t << "\n";
- }
- t << "REPEAT_BRIEF = ";
- writeBoolValue(t,Config::repeatBriefFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then \n";
- t << "# Doxygen will generate a detailed section even if there is only a brief \n";
- t << "# description. \n";
- t << "\n";
- }
- t << "ALWAYS_DETAILED_SEC = ";
- writeBoolValue(t,Config::alwaysDetailsFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full \n";
- t << "# path before files name in the file list and in the header files. If set \n";
- t << "# to NO the shortest path that makes the file name unique will be used. \n";
- t << "\n";
- }
- t << "FULL_PATH_NAMES = ";
- writeBoolValue(t,Config::fullPathNameFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag \n";
- t << "# can be used to strip a user defined part of the path. Stripping is \n";
- t << "# only done if one of the specified strings matches the left-hand part of \n";
- t << "# the path. It is allowed to use relative paths in the argument list.\n";
- t << "\n";
- }
- t << "STRIP_FROM_PATH = ";
- writeStringList(t,Config::stripFromPath);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The INTERNAL_DOCS tag determines if documentation \n";
- t << "# that is typed after a \\internal command is included. If the tag is set \n";
- t << "# to NO (the default) then the documentation will be excluded. \n";
- t << "# Set it to YES to include the internal documentation. \n";
- t << "\n";
- }
- t << "INTERNAL_DOCS = ";
- writeBoolValue(t,Config::internalDocsFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will \n";
- t << "# generate a class diagram (in Html and LaTeX) for classes with base or \n";
- t << "# super classes. Setting the tag to NO turns the diagrams off. \n";
- t << "\n";
- }
- t << "CLASS_DIAGRAMS = ";
- writeBoolValue(t,Config::classDiagramFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the SOURCE_BROWSER tag is set to YES then a list of source files will \n";
- t << "# be generated. Documented entities will be cross-referenced with these sources. \n";
- t << "\n";
- }
- t << "SOURCE_BROWSER = ";
- writeBoolValue(t,Config::sourceBrowseFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# Setting the INLINE_SOURCES tag to YES will include the body \n";
- t << "# of functions and classes directly in the documentation. \n";
- t << "\n";
- }
- t << "INLINE_SOURCES = ";
- writeBoolValue(t,Config::inlineSourceFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct \n";
- t << "# doxygen to hide any special comment blocks from generated source code \n";
- t << "# fragments. Normal C and C++ comments will always remain visible. \n";
- t << "\n";
- }
- t << "STRIP_CODE_COMMENTS = ";
- writeBoolValue(t,Config::stripCommentsFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate \n";
- t << "# file names in lower case letters. If set to YES upper case letters are also \n";
- t << "# allowed. This is useful if you have classes or files whose names only differ \n";
- t << "# in case and if your file system supports case sensitive file names. Windows \n";
- t << "# users are adviced to set this option to NO.\n";
- t << "\n";
- }
- t << "CASE_SENSE_NAMES = ";
- writeBoolValue(t,Config::caseSensitiveNames);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen \n";
- t << "# will show members with their full class and namespace scopes in the \n";
- t << "# documentation. If set to YES the scope will be hidden. \n";
- t << "\n";
- }
- t << "HIDE_SCOPE_NAMES = ";
- writeBoolValue(t,Config::hideScopeNames);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen \n";
- t << "# will generate a verbatim copy of the header file for each class for \n";
- t << "# which an include is specified. Set to NO to disable this. \n";
- t << "\n";
- }
- t << "VERBATIM_HEADERS = ";
- writeBoolValue(t,Config::verbatimHeaderFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen \n";
- t << "# will put list of the files that are included by a file in the documentation \n";
- t << "# of that file. \n";
- t << "\n";
- }
- t << "SHOW_INCLUDE_FILES = ";
- writeBoolValue(t,Config::showIncFileFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen \n";
- t << "# will interpret the first line (until the first dot) of a JavaDoc-style \n";
- t << "# comment as the brief description. If set to NO, the JavaDoc \n";
- t << "# comments will behave just like the Qt-style comments (thus requiring an \n";
- t << "# explict @brief command for a brief description. \n";
- t << "\n";
- }
- t << "JAVADOC_AUTOBRIEF = ";
- writeBoolValue(t,Config::autoBriefFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented \n";
- t << "# member inherits the documentation from any documented member that it \n";
- t << "# reimplements. \n";
- t << "\n";
- }
- t << "INHERIT_DOCS = ";
- writeBoolValue(t,Config::inheritDocsFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] \n";
- t << "# is inserted in the documentation for inline members. \n";
- t << "\n";
- }
- t << "INLINE_INFO = ";
- writeBoolValue(t,Config::inlineInfoFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen \n";
- t << "# will sort the (detailed) documentation of file and class members \n";
- t << "# alphabetically by member name. If set to NO the members will appear in \n";
- t << "# declaration order. \n";
- t << "\n";
- }
- t << "SORT_MEMBER_DOCS = ";
- writeBoolValue(t,Config::sortMembersFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC \n";
- t << "# tag is set to YES, then doxygen will reuse the documentation of the first \n";
- t << "# member in the group (if any) for the other members of the group. By default \n";
- t << "# all members of a group must be documented explicitly.\n";
- t << "\n";
- }
- t << "DISTRIBUTE_GROUP_DOC = ";
- writeBoolValue(t,Config::distributeDocFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The TAB_SIZE tag can be used to set the number of spaces in a tab. \n";
- t << "# Doxygen uses this value to replace tabs by spaces in code fragments. \n";
- t << "\n";
- }
- t << "TAB_SIZE = ";
- writeIntValue(t,Config::tabSize);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The ENABLE_SECTIONS tag can be used to enable conditional \n";
- t << "# documentation sections, marked by \\if sectionname ... \\endif. \n";
- t << "\n";
- }
- t << "ENABLED_SECTIONS = ";
- writeStringList(t,Config::sectionFilterList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The GENERATE_TODOLIST tag can be used to enable (YES) or \n";
- t << "# disable (NO) the todo list. This list is created by putting \\todo \n";
- t << "# commands in the documentation.\n";
- t << "\n";
- }
- t << "GENERATE_TODOLIST = ";
- writeBoolValue(t,Config::generateTodoList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The GENERATE_TESTLIST tag can be used to enable (YES) or \n";
- t << "# disable (NO) the test list. This list is created by putting \\test \n";
- t << "# commands in the documentation.\n";
- t << "\n";
- }
- t << "GENERATE_TESTLIST = ";
- writeBoolValue(t,Config::generateTestList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The GENERATE_BUGLIST tag can be used to enable (YES) or \n";
- t << "# disable (NO) the bug list. This list is created by putting \\bug \n";
- t << "# commands in the documentation.\n";
- t << "\n";
- }
- t << "GENERATE_BUGLIST = ";
- writeBoolValue(t,Config::generateBugList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# This tag can be used to specify a number of aliases that acts \n";
- t << "# as commands in the documentation. An alias has the form \"name=value\". \n";
- t << "# For example adding \"sideeffect=\\par Side Effects:\\n\" will allow you to \n";
- t << "# put the command \\sideeffect (or @sideeffect) in the documentation, which \n";
- t << "# will result in a user defined paragraph with heading \"Side Effects:\". \n";
- t << "# You can put \\n's in the value part of an alias to insert newlines. \n";
- t << "\n";
- }
- t << "ALIASES = ";
- writeStringList(t,Config::aliasList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The MAX_INITIALIZER_LINES tag determines the maximum number of lines \n";
- t << "# the initial value of a variable or define consist of for it to appear in \n";
- t << "# the documentation. If the initializer consists of more lines than specified \n";
- t << "# here it will be hidden. Use a value of 0 to hide initializers completely. \n";
- t << "# The appearance of the initializer of individual variables and defines in the \n";
- t << "# documentation can be controlled using \\showinitializer or \\hideinitializer \n";
- t << "# command in the documentation regardless of this setting. \n";
- t << "\n";
- }
- t << "MAX_INITIALIZER_LINES = ";
- writeIntValue(t,Config::maxInitLines);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources \n";
- t << "# only. Doxygen will then generate output that is more tailored for C. \n";
- t << "# For instance some of the names that are used will be different. The list \n";
- t << "# of all members will be omitted, etc. \n";
- t << "\n";
- }
- t << "OPTIMIZE_OUTPUT_FOR_C = ";
- writeBoolValue(t,Config::optimizeForCFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# Set the SHOW_USED_FILES tag to NO to disable the list of files generated \n";
- t << "# at the bottom of the documentation of classes and structs. If set to YES the \n";
- t << "# list will mention the files that were used to generate the documentation. \n";
- t << "\n";
- }
- t << "SHOW_USED_FILES = ";
- writeBoolValue(t,Config::showUsedFilesFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# configuration options related to warning and progress messages\n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# The QUIET tag can be used to turn on/off the messages that are generated \n";
- t << "# by doxygen. Possible values are YES and NO. If left blank NO is used. \n";
- t << "\n";
- }
- t << "QUIET = ";
- writeBoolValue(t,Config::quietFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The WARNINGS tag can be used to turn on/off the warning messages that are \n";
- t << "# generated by doxygen. Possible values are YES and NO. If left blank \n";
- t << "# NO is used. \n";
- t << "\n";
- }
- t << "WARNINGS = ";
- writeBoolValue(t,Config::warningFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings \n";
- t << "# for undocumented members. If EXTRACT_ALL is set to YES then this flag will \n";
- t << "# automatically be disabled. \n";
- t << "\n";
- }
- t << "WARN_IF_UNDOCUMENTED = ";
- writeBoolValue(t,Config::warningUndocFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The WARN_FORMAT tag determines the format of the warning messages that \n";
- t << "# doxygen can produce. The string should contain the $file, $line, and $text \n";
- t << "# tags, which will be replaced by the file and line number from which the \n";
- t << "# warning originated and the warning text. \n";
- t << "\n";
- }
- t << "WARN_FORMAT = ";
- writeStringValue(t,Config::warnFormat);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The WARN_LOGFILE tag can be used to specify a file to which warning \n";
- t << "# and error messages should be written. If left blank the output is written \n";
- t << "# to stderr. \n";
- t << "\n";
- }
- t << "WARN_LOGFILE = ";
- writeStringValue(t,Config::warnLogFile);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# configuration options related to the input files\n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# The INPUT tag can be used to specify the files and/or directories that contain \n";
- t << "# documented source files. You may enter file names like \"myfile.cpp\" or \n";
- t << "# directories like \"/usr/src/myproject\". Separate the files or directories \n";
- t << "# with spaces. \n";
- t << "\n";
- }
- t << "INPUT = ";
- writeStringList(t,Config::inputSources);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the value of the INPUT tag contains directories, you can use the \n";
- t << "# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp \n";
- t << "# and *.h) to filter out the source-files in the directories. If left \n";
- t << "# blank all files are included. \n";
- t << "\n";
- }
- t << "FILE_PATTERNS = ";
- writeStringList(t,Config::filePatternList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The RECURSIVE tag can be used to turn specify whether or not subdirectories \n";
- t << "# should be searched for input files as well. Possible values are YES and NO. \n";
- t << "# If left blank NO is used. \n";
- t << "\n";
- }
- t << "RECURSIVE = ";
- writeBoolValue(t,Config::recursiveFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The EXCLUDE tag can be used to specify files and/or directories that should \n";
- t << "# excluded from the INPUT source files. This way you can easily exclude a \n";
- t << "# subdirectory from a directory tree whose root is specified with the INPUT tag. \n";
- t << "\n";
- }
- t << "EXCLUDE = ";
- writeStringList(t,Config::excludeSources);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the value of the INPUT tag contains directories, you can use the \n";
- t << "# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude \n";
- t << "# certain files from those directories. \n";
- t << "\n";
- }
- t << "EXCLUDE_PATTERNS = ";
- writeStringList(t,Config::excludePatternList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The EXAMPLE_PATH tag can be used to specify one or more files or \n";
- t << "# directories that contain example code fragments that are included (see \n";
- t << "# the \\include command). \n";
- t << "\n";
- }
- t << "EXAMPLE_PATH = ";
- writeStringList(t,Config::examplePath);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the value of the EXAMPLE_PATH tag contains directories, you can use the \n";
- t << "# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp \n";
- t << "# and *.h) to filter out the source-files in the directories. If left \n";
- t << "# blank all files are included. \n";
- t << "\n";
- }
- t << "EXAMPLE_PATTERNS = ";
- writeStringList(t,Config::examplePatternList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The IMAGE_PATH tag can be used to specify one or more files or \n";
- t << "# directories that contain image that are included in the documentation (see \n";
- t << "# the \\image command). \n";
- t << "\n";
- }
- t << "IMAGE_PATH = ";
- writeStringList(t,Config::imagePath);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The INPUT_FILTER tag can be used to specify a program that doxygen should \n";
- t << "# invoke to filter for each input file. Doxygen will invoke the filter program \n";
- t << "# by executing (via popen()) the command <filter> <input-file>, where <filter> \n";
- t << "# is the value of the INPUT_FILTER tag, and <input-file> is the name of an \n";
- t << "# input file. Doxygen will then use the output that the filter program writes \n";
- t << "# to standard output. \n";
- t << "\n";
- }
- t << "INPUT_FILTER = ";
- writeStringValue(t,Config::inputFilter);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using \n";
- t << "# INPUT_FILTER) will be used to filter the input files when producing source \n";
- t << "# files to browse. \n";
- t << "\n";
- }
- t << "FILTER_SOURCE_FILES = ";
- writeBoolValue(t,Config::filterForSourceFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# configuration options related to the alphabetical class index\n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index \n";
- t << "# of all compounds will be generated. Enable this if the project \n";
- t << "# contains a lot of classes, structs, unions or interfaces. \n";
- t << "\n";
- }
- t << "ALPHABETICAL_INDEX = ";
- writeBoolValue(t,Config::alphaIndexFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then \n";
- t << "# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns \n";
- t << "# in which this list will be split (can be a number in the range [1..20]) \n";
- t << "\n";
- }
- t << "COLS_IN_ALPHA_INDEX = ";
- writeIntValue(t,Config::colsInAlphaIndex);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# In case all classes in a project start with a common prefix, all \n";
- t << "# classes will be put under the same header in the alphabetical index. \n";
- t << "# The IGNORE_PREFIX tag can be used to specify one or more prefixes that \n";
- t << "# should be ignored while generating the index headers. \n";
- t << "\n";
- }
- t << "IGNORE_PREFIX = ";
- writeStringList(t,Config::ignorePrefixList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# configuration options related to the HTML output\n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GENERATE_HTML tag is set to YES (the default) Doxygen will \n";
- t << "# generate HTML output. \n";
- t << "\n";
- }
- t << "GENERATE_HTML = ";
- writeBoolValue(t,Config::generateHtml);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. \n";
- t << "# If a relative path is entered the value of OUTPUT_DIRECTORY will be \n";
- t << "# put in front of it. If left blank `html' will be used as the default path. \n";
- t << "\n";
- }
- t << "HTML_OUTPUT = ";
- writeStringValue(t,Config::htmlOutputDir);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The HTML_HEADER tag can be used to specify a personal HTML header for \n";
- t << "# each generated HTML page. If it is left blank doxygen will generate a \n";
- t << "# standard header.\n";
- t << "\n";
- }
- t << "HTML_HEADER = ";
- writeStringValue(t,Config::headerFile);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The HTML_FOOTER tag can be used to specify a personal HTML footer for \n";
- t << "# each generated HTML page. If it is left blank doxygen will generate a \n";
- t << "# standard footer.\n";
- t << "\n";
- }
- t << "HTML_FOOTER = ";
- writeStringValue(t,Config::footerFile);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The HTML_STYLESHEET tag can be used to specify a user defined cascading \n";
- t << "# style sheet that is used by each HTML page. It can be used to \n";
- t << "# fine-tune the look of the HTML output. If the tag is left blank doxygen \n";
- t << "# will generate a default style sheet \n";
- t << "\n";
- }
- t << "HTML_STYLESHEET = ";
- writeStringValue(t,Config::htmlStyleSheet);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, \n";
- t << "# files or namespaces will be aligned in HTML using tables. If set to \n";
- t << "# NO a bullet list will be used. \n";
- t << "\n";
- }
- t << "HTML_ALIGN_MEMBERS = ";
- writeBoolValue(t,Config::htmlAlignMemberFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GENERATE_HTMLHELP tag is set to YES, additional index files \n";
- t << "# will be generated that can be used as input for tools like the \n";
- t << "# Microsoft HTML help workshop to generate a compressed HTML help file (.chm) \n";
- t << "# of the generated HTML documentation. \n";
- t << "\n";
- }
- t << "GENERATE_HTMLHELP = ";
- writeBoolValue(t,Config::htmlHelpFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag \n";
- t << "# controls if a separate .chi index file is generated (YES) or that \n";
- t << "# it should be included in the master .chm file (NO).\n";
- t << "\n";
- }
- t << "GENERATE_CHI = ";
- writeBoolValue(t,Config::htmlHelpChiFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag \n";
- t << "# controls whether a binary table of contents is generated (YES) or a \n";
- t << "# normal table of contents (NO) in the .chm file.\n";
- t << "\n";
- }
- t << "BINARY_TOC = ";
- writeBoolValue(t,Config::htmlHelpTocFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The TOC_EXPAND flag can be set YES to add extra items for group members \n";
- t << "# to the contents of the Html help documentation and to the tree view. \n";
- t << "\n";
- }
- t << "TOC_EXPAND = ";
- writeBoolValue(t,Config::htmlHelpTocExpandFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The DISABLE_INDEX tag can be used to turn on/off the condensed index at \n";
- t << "# top of each HTML page. The value NO (the default) enables the index and \n";
- t << "# the value YES disables it. \n";
- t << "\n";
- }
- t << "DISABLE_INDEX = ";
- writeBoolValue(t,Config::noIndexFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# This tag can be used to set the number of enum values (range [1..20]) \n";
- t << "# that doxygen will group on one line in the generated HTML documentation. \n";
- t << "\n";
- }
- t << "ENUM_VALUES_PER_LINE = ";
- writeIntValue(t,Config::enumValuesPerLine);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GENERATE_TREEVIEW tag is set to YES, a side panel will be\n";
- t << "# generated containing a tree-like index structure (just like the one that \n";
- t << "# is generated for HTML Help). For this to work a browser that supports \n";
- t << "# JavaScript and frames is required (for instance Netscape 4.0+ \n";
- t << "# or Internet explorer 4.0+). \n";
- t << "\n";
- }
- t << "GENERATE_TREEVIEW = ";
- writeBoolValue(t,Config::ftvHelpFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be \n";
- t << "# used to set the initial width (in pixels) of the frame in which the tree \n";
- t << "# is shown. \n";
- t << "\n";
- }
- t << "TREEVIEW_WIDTH = ";
- writeIntValue(t,Config::treeViewWidth);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# configuration options related to the LaTeX output\n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will \n";
- t << "# generate Latex output. \n";
- t << "\n";
- }
- t << "GENERATE_LATEX = ";
- writeBoolValue(t,Config::generateLatex);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. \n";
- t << "# If a relative path is entered the value of OUTPUT_DIRECTORY will be \n";
- t << "# put in front of it. If left blank `latex' will be used as the default path. \n";
- t << "\n";
- }
- t << "LATEX_OUTPUT = ";
- writeStringValue(t,Config::latexOutputDir);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact \n";
- t << "# LaTeX documents. This may be useful for small projects and may help to \n";
- t << "# save some trees in general. \n";
- t << "\n";
- }
- t << "COMPACT_LATEX = ";
- writeBoolValue(t,Config::compactLatexFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The PAPER_TYPE tag can be used to set the paper type that is used \n";
- t << "# by the printer. Possible values are: a4, a4wide, letter, legal and \n";
- t << "# executive. If left blank a4wide will be used. \n";
- t << "\n";
- }
- t << "PAPER_TYPE = ";
- writeStringValue(t,Config::paperType);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX \n";
- t << "# packages that should be included in the LaTeX output. \n";
- t << "\n";
- }
- t << "EXTRA_PACKAGES = ";
- writeStringList(t,Config::extraPackageList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The LATEX_HEADER tag can be used to specify a personal LaTeX header for \n";
- t << "# the generated latex document. The header should contain everything until \n";
- t << "# the first chapter. If it is left blank doxygen will generate a \n";
- t << "# standard header. Notice: only use this tag if you know what you are doing! \n";
- t << "\n";
- }
- t << "LATEX_HEADER = ";
- writeStringValue(t,Config::latexHeaderFile);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated \n";
- t << "# is prepared for conversion to pdf (using ps2pdf). The pdf file will \n";
- t << "# contain links (just like the HTML output) instead of page references \n";
- t << "# This makes the output suitable for online browsing using a pdf viewer. \n";
- t << "\n";
- }
- t << "PDF_HYPERLINKS = ";
- writeBoolValue(t,Config::pdfHyperFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of \n";
- t << "# plain latex in the generated Makefile. Set this option to YES to get a \n";
- t << "# higher quality PDF documentation. \n";
- t << "\n";
- }
- t << "USE_PDFLATEX = ";
- writeBoolValue(t,Config::usePDFLatexFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\\\batchmode. \n";
- t << "# command to the generated LaTeX files. This will instruct LaTeX to keep \n";
- t << "# running if errors occur, instead of asking the user for help. \n";
- t << "# This option is also used when generating formulas in HTML. \n";
- t << "\n";
- }
- t << "LATEX_BATCHMODE = ";
- writeBoolValue(t,Config::latexBatchModeFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# configuration options related to the RTF output\n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output \n";
- t << "# The RTF output is optimised for Word 97 and may not look very pretty with \n";
- t << "# other RTF readers or editors.\n";
- t << "\n";
- }
- t << "GENERATE_RTF = ";
- writeBoolValue(t,Config::generateRTF);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. \n";
- t << "# If a relative path is entered the value of OUTPUT_DIRECTORY will be \n";
- t << "# put in front of it. If left blank `rtf' will be used as the default path. \n";
- t << "\n";
- }
- t << "RTF_OUTPUT = ";
- writeStringValue(t,Config::rtfOutputDir);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the COMPACT_RTF tag is set to YES Doxygen generates more compact \n";
- t << "# RTF documents. This may be useful for small projects and may help to \n";
- t << "# save some trees in general. \n";
- t << "\n";
- }
- t << "COMPACT_RTF = ";
- writeBoolValue(t,Config::compactRTFFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated \n";
- t << "# will contain hyperlink fields. The RTF file will \n";
- t << "# contain links (just like the HTML output) instead of page references. \n";
- t << "# This makes the output suitable for online browsing using a WORD or other. \n";
- t << "# programs which support those fields. \n";
- t << "# Note: wordpad (write) and others do not support links. \n";
- t << "\n";
- }
- t << "RTF_HYPERLINKS = ";
- writeBoolValue(t,Config::rtfHyperFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# Load stylesheet definitions from file. Syntax is similar to doxygen's \n";
- t << "# config file, i.e. a series of assigments. You only have to provide \n";
- t << "# replacements, missing definitions are set to their default value. \n";
- t << "\n";
- }
- t << "RTF_STYLESHEET_FILE = ";
- writeStringValue(t,Config::rtfStylesheetFile);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# Set optional variables used in the generation of an rtf document. \n";
- t << "# Syntax is similar to doxygen's config file.\n";
- t << "\n";
- }
- t << "RTF_EXTENSIONS_FILE = ";
- writeStringValue(t,Config::rtfExtensionsFile);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# configuration options related to the man page output\n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GENERATE_MAN tag is set to YES (the default) Doxygen will \n";
- t << "# generate man pages \n";
- t << "\n";
- }
- t << "GENERATE_MAN = ";
- writeBoolValue(t,Config::generateMan);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The MAN_OUTPUT tag is used to specify where the man pages will be put. \n";
- t << "# If a relative path is entered the value of OUTPUT_DIRECTORY will be \n";
- t << "# put in front of it. If left blank `man' will be used as the default path. \n";
- t << "\n";
- }
- t << "MAN_OUTPUT = ";
- writeStringValue(t,Config::manOutputDir);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The MAN_EXTENSION tag determines the extension that is added to \n";
- t << "# the generated man pages (default is the subroutine's section .3) \n";
- t << "\n";
- }
- t << "MAN_EXTENSION = ";
- writeStringValue(t,Config::manExtension);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# Configuration options related to the preprocessor \n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will \n";
- t << "# evaluate all C-preprocessor directives found in the sources and include \n";
- t << "# files. \n";
- t << "\n";
- }
- t << "ENABLE_PREPROCESSING = ";
- writeBoolValue(t,Config::preprocessingFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro \n";
- t << "# names in the source code. If set to NO (the default) only conditional \n";
- t << "# compilation will be performed. Macro expansion can be done in a controlled \n";
- t << "# way by setting EXPAND_ONLY_PREDEF to YES. \n";
- t << "\n";
- }
- t << "MACRO_EXPANSION = ";
- writeBoolValue(t,Config::macroExpansionFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES \n";
- t << "# then the macro expansion is limited to the macros specified with the \n";
- t << "# PREDEFINED and EXPAND_AS_PREDEFINED tags. \n";
- t << "\n";
- }
- t << "EXPAND_ONLY_PREDEF = ";
- writeBoolValue(t,Config::onlyPredefinedFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files \n";
- t << "# in the INCLUDE_PATH (see below) will be search if a #include is found. \n";
- t << "\n";
- }
- t << "SEARCH_INCLUDES = ";
- writeBoolValue(t,Config::searchIncludeFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The INCLUDE_PATH tag can be used to specify one or more directories that \n";
- t << "# contain include files that are not input files but should be processed by \n";
- t << "# the preprocessor. \n";
- t << "\n";
- }
- t << "INCLUDE_PATH = ";
- writeStringList(t,Config::includePath);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard \n";
- t << "# patterns (like *.h and *.hpp) to filter out the header-files in the \n";
- t << "# directories. If left blank, the patterns specified with FILE_PATTERNS will \n";
- t << "# be used. \n";
- t << "\n";
- }
- t << "INCLUDE_FILE_PATTERNS = ";
- writeStringList(t,Config::includeFilePatternList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The PREDEFINED tag can be used to specify one or more macro names that \n";
- t << "# are defined before the preprocessor is started (similar to the -D option of \n";
- t << "# gcc). The argument of the tag is a list of macros of the form: name \n";
- t << "# or name=definition (no spaces). If the definition and the = are \n";
- t << "# omitted =1 is assumed. \n";
- t << "\n";
- }
- t << "PREDEFINED = ";
- writeStringList(t,Config::predefined);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the MACRO_EXPANSION and EXPAND_PREDEF_ONLY tags are set to YES then \n";
- t << "# this tag can be used to specify a list of macro names that should be expanded. \n";
- t << "# The macro definition that is found in the sources will be used. \n";
- t << "# Use the PREDEFINED tag if you want to use a different macro definition. \n";
- t << "\n";
- }
- t << "EXPAND_AS_DEFINED = ";
- writeStringList(t,Config::expandAsDefinedList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# Configuration::addtions related to external references \n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# The TAGFILES tag can be used to specify one or more tagfiles. \n";
- t << "\n";
- }
- t << "TAGFILES = ";
- writeStringList(t,Config::tagFileList);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# When a file name is specified after GENERATE_TAGFILE, doxygen will create \n";
- t << "# a tag file that is based on the input files it reads. \n";
- t << "\n";
- }
- t << "GENERATE_TAGFILE = ";
- writeStringValue(t,Config::genTagFile);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the ALLEXTERNALS tag is set to YES all external classes will be listed \n";
- t << "# in the class index. If set to NO only the inherited external classes \n";
- t << "# will be listed. \n";
- t << "\n";
- }
- t << "ALLEXTERNALS = ";
- writeBoolValue(t,Config::allExtFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The PERL_PATH should be the absolute path and name of the perl script \n";
- t << "# interpreter (i.e. the result of `which perl'). \n";
- t << "\n";
- }
- t << "PERL_PATH = ";
- writeStringValue(t,Config::perlPath);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# Configuration options related to the dot tool \n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is \n";
- t << "# available from the path. This tool is part of Graphviz, a graph visualization \n";
- t << "# toolkit from AT&T and Lucent Bell Labs. The other options in this section \n";
- t << "# have no effect if this option is set to NO (the default) \n";
- t << "\n";
- }
- t << "HAVE_DOT = ";
- writeBoolValue(t,Config::haveDotFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen \n";
- t << "# will generate a graph for each documented class showing the direct and \n";
- t << "# indirect inheritance relations. Setting this tag to YES will force the \n";
- t << "# the CLASS_DIAGRAMS tag to NO.\n";
- t << "\n";
- }
- t << "CLASS_GRAPH = ";
- writeBoolValue(t,Config::classGraphFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen \n";
- t << "# will generate a graph for each documented class showing the direct and \n";
- t << "# indirect implementation dependencies (inheritance, containment, and \n";
- t << "# class references variables) of the class with other documented classes. \n";
- t << "\n";
- }
- t << "COLLABORATION_GRAPH = ";
- writeBoolValue(t,Config::collGraphFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the ENABLE_PREPROCESSING, INCLUDE_GRAPH, and HAVE_DOT tags are set to \n";
- t << "# YES then doxygen will generate a graph for each documented file showing \n";
- t << "# the direct and indirect include dependencies of the file with other \n";
- t << "# documented files. \n";
- t << "\n";
- }
- t << "INCLUDE_GRAPH = ";
- writeBoolValue(t,Config::includeGraphFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the ENABLE_PREPROCESSING, INCLUDED_BY_GRAPH, and HAVE_DOT tags are set to \n";
- t << "# YES then doxygen will generate a graph for each documented header file showing \n";
- t << "# the documented files that directly or indirectly include this file \n";
- t << "\n";
- }
- t << "INCLUDED_BY_GRAPH = ";
- writeBoolValue(t,Config::includedByGraphFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen \n";
- t << "# will graphical hierarchy of all classes instead of a textual one. \n";
- t << "\n";
- }
- t << "GRAPHICAL_HIERARCHY = ";
- writeBoolValue(t,Config::gfxHierarchyFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The tag DOT_PATH can be used to specify the path where the dot tool can be \n";
- t << "# found. If left blank, it is assumed the dot tool can be found on the path. \n";
- t << "\n";
- }
- t << "DOT_PATH = ";
- writeStringValue(t,Config::dotPath);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width \n";
- t << "# (in pixels) of the graphs generated by dot. If a graph becomes larger than \n";
- t << "# this value, doxygen will try to truncate the graph, so that it fits within \n";
- t << "# the specified constraint. Beware that most browsers cannot cope with very \n";
- t << "# large images. \n";
- t << "\n";
- }
- t << "MAX_DOT_GRAPH_WIDTH = ";
- writeIntValue(t,Config::maxDotGraphWidth);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height \n";
- t << "# (in pixels) of the graphs generated by dot. If a graph becomes larger than \n";
- t << "# this value, doxygen will try to truncate the graph, so that it fits within \n";
- t << "# the specified constraint. Beware that most browsers cannot cope with very \n";
- t << "# large images. \n";
- t << "\n";
- }
- t << "MAX_DOT_GRAPH_HEIGHT = ";
- writeIntValue(t,Config::maxDotGraphHeight);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will \n";
- t << "# generate a legend page explaining the meaning of the various boxes and \n";
- t << "# arrows in the dot generated graphs. \n";
- t << "\n";
- }
- t << "GENERATE_LEGEND = ";
- writeBoolValue(t,Config::generateLegend);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will \n";
- t << "# remove the intermedate dot files that are used to generate \n";
- t << "# the various graphs. \n";
- t << "\n";
- }
- t << "DOT_CLEANUP = ";
- writeBoolValue(t,Config::dotCleanUp);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- }
- t << "#---------------------------------------------------------------------------\n";
- t << "# Configuration::addtions related to the search engine \n";
- t << "#---------------------------------------------------------------------------\n";
- if (!sl)
- {
- t << "\n";
- t << "# The SEARCHENGINE tag specifies whether or not a search engine should be \n";
- t << "# used. If set to NO the values of all tags below this one will be ignored. \n";
- t << "\n";
- }
- t << "SEARCHENGINE = ";
- writeBoolValue(t,Config::searchEngineFlag);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The CGI_NAME tag should be the name of the CGI script that \n";
- t << "# starts the search engine (doxysearch) with the correct parameters. \n";
- t << "# A script with this name will be generated by doxygen. \n";
- t << "\n";
- }
- t << "CGI_NAME = ";
- writeStringValue(t,Config::cgiName);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The CGI_URL tag should be the absolute URL to the directory where the \n";
- t << "# cgi binaries are located. See the documentation of your http daemon for \n";
- t << "# details. \n";
- t << "\n";
- }
- t << "CGI_URL = ";
- writeStringValue(t,Config::cgiURL);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The DOC_URL tag should be the absolute URL to the directory where the \n";
- t << "# documentation is located. If left blank the absolute path to the \n";
- t << "# documentation, with file:// prepended to it, will be used. \n";
- t << "\n";
- }
- t << "DOC_URL = ";
- writeStringValue(t,Config::docURL);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The DOC_ABSPATH tag should be the absolute path to the directory where the \n";
- t << "# documentation is located. If left blank the directory on the local machine \n";
- t << "# will be used. \n";
- t << "\n";
- }
- t << "DOC_ABSPATH = ";
- writeStringValue(t,Config::docAbsPath);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The BIN_ABSPATH tag must point to the directory where the doxysearch binary \n";
- t << "# is installed. \n";
- t << "\n";
- }
- t << "BIN_ABSPATH = ";
- writeStringValue(t,Config::binAbsPath);
- t << "\n";
- if (!sl)
- {
- t << "\n";
- t << "# The EXT_DOC_PATHS tag can be used to specify one or more paths to \n";
- t << "# documentation generated for other projects. This allows doxysearch to search \n";
- t << "# the documentation for these projects as well. \n";
- t << "\n";
- }
- t << "EXT_DOC_PATHS = ";
- writeStringList(t,Config::extDocPathList);
- t << "\n";
}
-void configStrToVal()
+void Config::convertStrToVal()
{
- if (tabSizeString.isEmpty())
- {
- Config::tabSize=8;
- }
- else
- {
- bool ok;
- int ts = tabSizeString.toInt(&ok);
- if (!ok || ts<1 || ts>16)
- {
- warn_cont("Warning: argument of TAB_SIZE is not a valid number, using tab size of 8 spaces!\n");
- ts=8;
- }
- Config::tabSize = ts;
- }
-
- if (colsInAlphaIndexString.isEmpty())
- {
- Config::colsInAlphaIndex=5;
- }
- else
- {
- bool ok;
- int cols = colsInAlphaIndexString.toInt(&ok);
- if (!ok || cols<1 || cols>20)
- {
- warn_cont("Warning: argument of COLS_IN_ALPHA_INDEX is not a valid number in the range [1..20]!\n"
- "Using the default of 5 columns!\n");
- cols = 5;
- }
- Config::colsInAlphaIndex=cols;
- }
-
- if (enumValuesPerLineString.isEmpty())
- {
- Config::enumValuesPerLine=4;
- }
- else
- {
- bool ok;
- int cols = enumValuesPerLineString.toInt(&ok);
- if (!ok || cols<1 || cols>20)
- {
- warn_cont("Warning: argument of ENUM_VALUES_PER_LINE is not a valid number in the range [1..20]!\n"
- "Using the default of 4!\n");
- cols = 4;
- }
- Config::enumValuesPerLine=cols;
- }
-
- if (treeViewWidthString.isEmpty())
- {
- Config::treeViewWidth=250;
- }
- else
- {
- bool ok;
- int width = treeViewWidthString.toInt(&ok);
- if (!ok || width<0 || width>1500)
- {
- warn_cont("Warning: argument of TREEVIEW_WIDTH is not a valid number in the range [0..1500]!\n"
- "Using the default of 250!\n");
- width = 250;
- }
- Config::treeViewWidth=width;
- }
-
- if (maxDotGraphWidthString.isEmpty())
- {
- Config::maxDotGraphWidth=1024;
- }
- else
- {
- bool ok;
- int width =maxDotGraphWidthString.toInt(&ok);
- if (!ok)
- {
- warn_cont("Warning: argument of MAX_DOT_GRAPH_WIDTH is not a valid number in the range [100..30000]!\n"
- "Using the default of 1024 pixels!\n");
- width=1024;
- }
- else if (width<100) // clip to lower bound
- {
- width=100;
- }
- else if (width>30000) // clip to upper bound
- {
- width=30000;
- }
- Config::maxDotGraphWidth=width;
- }
-
- if (maxDotGraphHeightString.isEmpty())
- {
- Config::maxDotGraphHeight=1024;
- }
- else
- {
- bool ok;
- int height =maxDotGraphHeightString.toInt(&ok);
- if (!ok)
- {
- warn_cont("Warning: argument of MAX_DOT_GRAPH_WIDTH is not a valid number in the range [100..30000]!\n"
- "Using the default of 1024 pixels!\n");
- height=1024;
- }
- else if (height<100) // clip to lower bound
- {
- height=100;
- }
- else if (height>30000) // clip to upper bound
- {
- height=30000;
- }
- Config::maxDotGraphHeight=height;
- }
-
- if (maxInitLinesString.isEmpty())
+ ConfigOption *option = m_options->first();
+ while (option)
{
- Config::maxInitLines=30;
- }
- else
- {
- bool ok;
- int maxLines =maxInitLinesString.toInt(&ok);
- if (!ok)
- {
- warn_cont("Warning: argument of MAX_DOT_GRAPH_WIDTH is not a valid number in the range [100..30000]!\n"
- "Using the default of 1024 pixels!\n");
- maxLines=30;
- }
- else if (maxLines<0) // clip to lower bound
- {
- maxLines=0;
- }
- else if (maxLines>10000) // clip to upper bound
- {
- maxLines=10000;
- }
- Config::maxInitLines=maxLines;
+ option->convertStrToVal();
+ option = m_options->next();
}
}
@@ -2613,9 +582,6 @@ static void substEnvVarsInStrList(QStrList &sl)
contained multiple elements no further
splitting is done to allow quoted items with spaces! */
{
-
-
-
int l=result.length();
int i,p=0;
// skip spaces
@@ -2681,80 +647,52 @@ static void substEnvVarsInStrList(QStrList &sl)
}
}
+void ConfigString::substEnvVars()
+{
+ substEnvVarsInString(m_value);
+}
+
+void ConfigList::substEnvVars()
+{
+ substEnvVarsInStrList(m_value);
+}
+
-void substituteEnvironmentVars()
+void Config::substituteEnvironmentVars()
{
- substEnvVarsInString( Config::projectName );
- substEnvVarsInString( Config::projectNumber );
- substEnvVarsInString( Config::outputDir );
- substEnvVarsInString( Config::outputLanguage );
- substEnvVarsInStrList( Config::stripFromPath );
- substEnvVarsInStrList( Config::sectionFilterList );
- substEnvVarsInStrList( Config::aliasList );
- substEnvVarsInString( Config::warnFormat );
- substEnvVarsInString( Config::warnLogFile );
- substEnvVarsInStrList( Config::inputSources );
- substEnvVarsInStrList( Config::filePatternList );
- substEnvVarsInStrList( Config::excludeSources );
- substEnvVarsInStrList( Config::excludePatternList );
- substEnvVarsInStrList( Config::examplePath );
- substEnvVarsInStrList( Config::examplePatternList );
- substEnvVarsInStrList( Config::imagePath );
- substEnvVarsInString( Config::inputFilter );
- substEnvVarsInStrList( Config::ignorePrefixList );
- substEnvVarsInString( Config::htmlOutputDir );
- substEnvVarsInString( Config::headerFile );
- substEnvVarsInString( Config::footerFile );
- substEnvVarsInString( Config::htmlStyleSheet );
- substEnvVarsInString( Config::latexOutputDir );
- substEnvVarsInString( Config::paperType );
- substEnvVarsInStrList( Config::extraPackageList );
- substEnvVarsInString( Config::latexHeaderFile );
- substEnvVarsInString( Config::rtfOutputDir );
- substEnvVarsInString( Config::rtfStylesheetFile );
- substEnvVarsInString( Config::rtfExtensionsFile );
- substEnvVarsInString( Config::manOutputDir );
- substEnvVarsInString( Config::manExtension );
- substEnvVarsInStrList( Config::includePath );
- substEnvVarsInStrList( Config::includeFilePatternList );
- substEnvVarsInStrList( Config::predefined );
- substEnvVarsInStrList( Config::expandAsDefinedList );
- substEnvVarsInStrList( Config::tagFileList );
- substEnvVarsInString( Config::genTagFile );
- substEnvVarsInString( Config::perlPath );
- substEnvVarsInString( Config::dotPath );
- substEnvVarsInString( Config::cgiName );
- substEnvVarsInString( Config::cgiURL );
- substEnvVarsInString( Config::docURL );
- substEnvVarsInString( Config::docAbsPath );
- substEnvVarsInString( Config::binAbsPath );
- substEnvVarsInStrList( Config::extDocPathList );
+ ConfigOption *option = m_options->first();
+ while (option)
+ {
+ option->substEnvVars();
+ option = m_options->next();
+ }
}
-void checkConfig()
+void Config::check()
{
//if (!projectName.isEmpty())
//{
// projectName[0]=toupper(projectName[0]);
//}
- if (Config::warnFormat.isEmpty())
+ QCString &warnFormat = getString("WARN_FORMAT");
+ if (warnFormat.isEmpty())
{
- Config::warnFormat="$file:$line $text";
+ warnFormat="$file:$line $text";
}
else
{
- if (Config::warnFormat.find("$file")==-1)
+ if (warnFormat.find("$file")==-1)
{
err("Error: warning format does not contain a $file tag!\n");
exit(1);
}
- if (Config::warnFormat.find("$line")==-1)
+ if (warnFormat.find("$line")==-1)
{
err("Error: warning format does not contain a $line tag!\n");
exit(1);
}
- if (Config::warnFormat.find("$text")==-1)
+ if (warnFormat.find("$text")==-1)
{
err("Error: wanring format foes not contain a $text tag!\n");
exit(1);
@@ -2762,27 +700,30 @@ void checkConfig()
}
initWarningFormat();
+ QCString &manExtension = getString("MAN_EXTENSION");
// set default man page extension if non is given by the user
- if (Config::manExtension.isEmpty())
+ if (manExtension.isEmpty())
{
- Config::manExtension=".3";
+ manExtension=".3";
}
- Config::paperType = Config::paperType.lower().stripWhiteSpace();
- if (Config::paperType.isEmpty())
+ QCString &paperType = getEnum("PAPER_TYPE");
+ paperType=paperType.lower().stripWhiteSpace();
+ if (paperType.isEmpty())
{
- Config::paperType = "a4wide";
+ paperType = "a4wide";
}
- if (Config::paperType!="a4" && Config::paperType!="a4wide" && Config::paperType!="letter" &&
- Config::paperType!="legal" && Config::paperType!="executive")
+ if (paperType!="a4" && paperType!="a4wide" && paperType!="letter" &&
+ paperType!="legal" && paperType!="executive")
{
err("Error: Unknown page type specified");
}
- Config::outputLanguage=Config::outputLanguage.stripWhiteSpace();
- if (Config::outputLanguage.isEmpty())
+ QCString &outputLanguage=getEnum("OUTPUT_LANGUAGE");
+ outputLanguage=outputLanguage.stripWhiteSpace();
+ if (outputLanguage.isEmpty())
{
- Config::outputLanguage = "English";
+ outputLanguage = "English";
#ifndef DOXYWIZARD
setTranslator("English");
#endif
@@ -2790,16 +731,17 @@ void checkConfig()
else
{
#ifndef DOXYWIZARD
- if (!setTranslator(Config::outputLanguage))
+ if (!setTranslator(outputLanguage))
{
err("Error: Output language %s not supported! Using English instead.\n",
- Config::outputLanguage.data());
+ outputLanguage.data());
}
#endif
}
// expand the relative stripFromPath values
- char *sfp = Config::stripFromPath.first();
+ QStrList &stripFromPath = getList("STRIP_FROM_PATH");
+ char *sfp = stripFromPath.first();
while (sfp)
{
QCString path = sfp;
@@ -2808,53 +750,57 @@ void checkConfig()
QFileInfo fi(path);
if (fi.exists() && fi.isDir())
{
- int i = Config::stripFromPath.at();
- Config::stripFromPath.remove();
- if (Config::stripFromPath.at()==i) // did not remove last item
- Config::stripFromPath.insert(i,fi.absFilePath()+"/");
+ int i = stripFromPath.at();
+ stripFromPath.remove();
+ if (stripFromPath.at()==i) // did not remove last item
+ stripFromPath.insert(i,fi.absFilePath()+"/");
else
- Config::stripFromPath.append(fi.absFilePath()+"/");
+ stripFromPath.append(fi.absFilePath()+"/");
}
}
- sfp = Config::stripFromPath.next();
+ sfp = stripFromPath.next();
}
// Test to see if HTML header is valid
- if (!Config::headerFile.isEmpty())
+ QCString &headerFile = getString("HTML_HEADER");
+ if (!headerFile.isEmpty())
{
- QFileInfo fi(Config::headerFile);
+ QFileInfo fi(headerFile);
if (!fi.exists())
{
err("Error: tag HTML_HEADER: header file `%s' "
- "does not exist\n",Config::headerFile.data());
+ "does not exist\n",headerFile.data());
exit(1);
}
}
// Test to see if HTML footer is valid
- if (!Config::footerFile.isEmpty())
+ QCString &footerFile = getString("HTML_FOOTER");
+ if (!footerFile.isEmpty())
{
- QFileInfo fi(Config::footerFile);
+ QFileInfo fi(footerFile);
if (!fi.exists())
{
err("Error: tag HTML_FOOTER: footer file `%s' "
- "does not exist\n",Config::footerFile.data());
+ "does not exist\n",footerFile.data());
exit(1);
}
}
// Test to see if LaTeX header is valid
- if (!Config::latexHeaderFile.isEmpty())
+ QCString &latexHeaderFile = getString("LATEX_HEADER");
+ if (!latexHeaderFile.isEmpty())
{
- QFileInfo fi(Config::latexHeaderFile);
+ QFileInfo fi(latexHeaderFile);
if (!fi.exists())
{
err("Error: tag LATEX_HEADER: header file `%s' "
- "does not exist\n",Config::latexHeaderFile.data());
+ "does not exist\n",latexHeaderFile.data());
exit(1);
}
}
// check include path
- char *s=Config::includePath.first();
+ QStrList &includePath = getList("INCLUDE_PATH");
+ char *s=includePath.first();
while (s)
{
QFileInfo fi(s);
@@ -2863,11 +809,12 @@ void checkConfig()
#ifndef DOXYWIZARD
addSearchDir(fi.absFilePath());
#endif
- s=Config::includePath.next();
+ s=includePath.next();
}
// check aliases
- s=Config::aliasList.first();
+ QStrList &aliasList = getList("ALIASES");
+ s=aliasList.first();
while (s)
{
QRegExp re("[a-z_A-Z][a-z_A-Z0-9]*[ \t]*=");
@@ -2877,59 +824,61 @@ void checkConfig()
{
err("Illegal alias format `%s'. Use \"name=value\"\n",alias.data());
}
- s=Config::aliasList.next();
+ s=aliasList.next();
}
// check dot path
- if (!Config::dotPath.isEmpty())
+ QCString &dotPath = getString("DOT_PATH");
+ if (!dotPath.isEmpty())
{
- if (Config::dotPath.find('\\')!=-1)
+ if (dotPath.find('\\')!=-1)
{
- if (Config::dotPath.at(Config::dotPath.length()-1)!='\\')
+ if (dotPath.at(dotPath.length()-1)!='\\')
{
- Config::dotPath+='\\';
+ dotPath+='\\';
}
}
- else if (Config::dotPath.find('/')!=-1)
+ else if (dotPath.find('/')!=-1)
{
- if (Config::dotPath.at(Config::dotPath.length()-1)!='/')
+ if (dotPath.at(dotPath.length()-1)!='/')
{
- Config::dotPath+='/';
+ dotPath+='/';
}
}
#if defined(_WIN32)
- QFileInfo dp(Config::dotPath+"dot.exe");
+ QFileInfo dp(dotPath+"dot.exe");
#else
- QFileInfo dp(Config::dotPath+"dot");
+ QFileInfo dp(dotPath+"dot");
#endif
if (!dp.exists() || !dp.isFile())
{
- err("Warning: the dot tool could not be found at %s\n",Config::dotPath.data());
- Config::dotPath="";
+ err("Warning: the dot tool could not be found at %s\n",dotPath.data());
+ dotPath="";
}
else
{
- Config::dotPath=dp.dirPath(TRUE)+"/";
+ dotPath=dp.dirPath(TRUE)+"/";
#if defined(_WIN32) // convert slashes
- uint i=0,l=Config::dotPath.length();
- for (i=0;i<l;i++) if (Config::dotPath.at(i)=='/') Config::dotPath.at(i)='\\';
+ uint i=0,l=dotPath.length();
+ for (i=0;i<l;i++) if (dotPath.at(i)=='/') dotPath.at(i)='\\';
#endif
}
}
else // make sure the string is empty but not null!
{
- Config::dotPath="";
+ dotPath="";
}
// check input
- if (Config::inputSources.count()==0)
+ QStrList &inputSources=getList("INPUT");
+ if (inputSources.count()==0)
{
err("Error: tag INPUT: no input files specified after the INPUT tag.\n");
exit(1);
}
else
{
- s=Config::inputSources.first();
+ s=inputSources.first();
while (s)
{
QFileInfo fi(s);
@@ -2938,45 +887,50 @@ void checkConfig()
err("Error: tag INPUT: input source `%s' does not exist\n",s);
exit(1);
}
- s=Config::inputSources.next();
+ s=inputSources.next();
}
}
// add default pattern if needed
- if (Config::filePatternList.isEmpty())
+ QStrList &filePatternList = getList("FILE_PATTERNS");
+ if (filePatternList.isEmpty())
{
- Config::filePatternList.append("*");
+ filePatternList.append("*");
}
// add default pattern if needed
- if (Config::examplePatternList.isEmpty())
+ QStrList &examplePatternList = getList("EXAMPLE_PATTERNS");
+ if (examplePatternList.isEmpty())
{
- Config::examplePatternList.append("*");
+ examplePatternList.append("*");
}
// add default pattern if needed
- //if (Config::imagePatternList.isEmpty())
+ //QStrList &imagePatternList = getList("IMAGE_PATTERNS");
+ //if (imagePatternList.isEmpty())
//{
- // Config::imagePatternList.append("*");
+ // imagePatternList.append("*");
//}
// more checks needed if and only if the search engine is enabled.
- if (Config::searchEngineFlag)
+ if (getBool("SEARCHENGINE"))
{
// check cgi name
- if (Config::cgiName.isEmpty())
+ QCString &cgiName = getString("CGI_NAME");
+ if (cgiName.isEmpty())
{
err("Error: tag CGI_NAME: no cgi script name after the CGI_NAME tag.\n");
exit(1);
}
// check cgi URL
- if (Config::cgiURL.isEmpty())
+ QCString &cgiURL = getString("CGI_URL");
+ if (cgiURL.isEmpty())
{
err("Error: tag CGI_URL: no URL to cgi directory specified.\n");
exit(1);
}
- else if (Config::cgiURL.left(7)!="http://" &&
- Config::cgiURL.left(8)!="https://"
+ else if (cgiURL.left(7)!="http://" &&
+ cgiURL.left(8)!="https://"
)
{
err("Error: tag CGI_URL: URL to cgi directory is invalid (must "
@@ -2984,13 +938,14 @@ void checkConfig()
exit(1);
}
// check documentation URL
- if (Config::docURL.isEmpty())
+ QCString &docURL = getString("DOC_URL");
+ if (docURL.isEmpty())
{
- Config::docURL = Config::outputDir.copy().prepend("file://").append("html");
+ docURL = getString("OUTPUT_DIRECTORY").copy().prepend("file://").append("html");
}
- else if (Config::docURL.left(7)!="http://" &&
- Config::docURL.left(8)!="https://" &&
- Config::docURL.left(7)!="file://"
+ else if (docURL.left(7)!="http://" &&
+ docURL.left(8)!="https://" &&
+ docURL.left(7)!="file://"
)
{
err("Error: tag DOC_URL: URL to documentation is invalid or "
@@ -2998,23 +953,25 @@ void checkConfig()
exit(1);
}
// check absolute documentation path
- if (Config::docAbsPath.isEmpty())
+ QCString &docAbsPath = getString("DOC_ABSPATH");
+ if (docAbsPath.isEmpty())
{
- Config::docAbsPath = Config::outputDir+"/html";
+ docAbsPath = getString("OUTPUT_DIRECTORY")+"/html";
}
- else if (Config::docAbsPath[0]!='/' && Config::docAbsPath[1]!=':')
+ else if (docAbsPath[0]!='/' && docAbsPath[1]!=':')
{
err("Error: tag DOC_ABSPATH: path is not absolute!\n");
exit(1);
}
// check path to doxysearch
- if (Config::binAbsPath.isEmpty())
+ QCString &binAbsPath = getString("BIN_ABSPATH");
+ if (binAbsPath.isEmpty())
{
err("Error: tag BIN_ABSPATH: no absolute path to doxysearch "
"specified.\n");
exit(1);
}
- else if (Config::binAbsPath[0]!='/' && Config::binAbsPath[1]!=':')
+ else if (binAbsPath[0]!='/' && binAbsPath[1]!=':')
{
err("Error: tag BIN_ABSPATH: path is not absolute!\n");
exit(1);
@@ -3022,13 +979,14 @@ void checkConfig()
// check perl path
bool found=FALSE;
- if (Config::perlPath.isEmpty())
+ QCString &perlPath = getString("PERL_PATH");
+ if (perlPath.isEmpty())
{
QFileInfo fi;
fi.setFile("/usr/bin/perl");
if (fi.exists())
{
- Config::perlPath="/usr/bin/perl";
+ perlPath="/usr/bin/perl";
found=TRUE;
}
else
@@ -3036,19 +994,19 @@ void checkConfig()
fi.setFile("/usr/local/bin/perl");
if (fi.exists())
{
- Config::perlPath="/usr/local/bin/perl";
+ perlPath="/usr/local/bin/perl";
found=TRUE;
}
}
}
if (!found)
{
- QFileInfo fi(Config::perlPath);
+ QFileInfo fi(perlPath);
if (!fi.exists())
{
warn_cont("Warning: tag PERL_PATH: perl interpreter not found at default or"
"user specified (%s) location\n",
- Config::perlPath.data());
+ perlPath.data());
}
}
}
@@ -3059,12 +1017,1015 @@ void checkConfig()
#else
#define PUTENV putenv
#endif
- if (Config::haveDotFlag) PUTENV("DOTFONTPATH=.");
+ if (getBool("HAVE_DOT")) PUTENV("DOTFONTPATH=.");
}
-void parseConfig(const QCString &s,const char *fn)
+void Config::init()
+{
+ ConfigOption *option = m_options->first();
+ while (option)
+ {
+ option->init();
+ option = m_options->next();
+ }
+}
+
+void Config::create()
+{
+ if (m_initialized) return;
+ m_initialized = TRUE;
+
+ ConfigString *cs;
+ ConfigEnum *ce;
+ ConfigList *cl;
+ ConfigInt *ci;
+ ConfigBool *cb;
+
+ // option definitions
+ //-----------------------------------------------------------------------------------------------
+ addInfo("General","General configuration options");
+ //-----------------------------------------------------------------------------------------------
+
+
+ cs = addString(//"projectName",
+ "PROJECT_NAME",
+ "The PROJECT_NAME tag is a single word (or a sequence of words surrounded \n"
+ "by quotes) that should identify the project. "
+ );
+ cs = addString(//"projectNumber",
+ "PROJECT_NUMBER",
+ "The PROJECT_NUMBER tag can be used to enter a project or revision number. \n"
+ "This could be handy for archiving the generated documentation or \n"
+ "if some version control system is used.\n"
+ );
+ cs = addString(//"outputDir",
+ "OUTPUT_DIRECTORY",
+ "The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) \n"
+ "base path where the generated documentation will be put. \n"
+ "If a relative path is entered, it will be relative to the location \n"
+ "where doxygen was started. If left blank the current directory will be used.\n"
+ );
+ cs->setWidgetType(ConfigString::Dir);
+ ce = addEnum(//"outputLanguage",
+ "OUTPUT_LANGUAGE",
+ "The OUTPUT_LANGUAGE tag is used to specify the language in which all \n"
+ "documentation generated by doxygen is written. Doxygen will use this \n"
+ "information to generate all constant output in the proper language. \n"
+ "The default language is English, other supported languages are: \n"
+ "Dutch, French, Italian, Czech, Swedish, German, Finnish, Japanese, \n"
+ "Korean, Hungarian, Norwegian, Spanish, Romanian, Russian, Croatian, \n"
+ "Polish, Portuguese, Brazilian and Slovene.\n",
+ "English"
+ );
+ ce->addValue("Brazilian");
+ ce->addValue("Croatian");
+ ce->addValue("Czech");
+ ce->addValue("Dutch");
+ ce->addValue("English");
+ ce->addValue("French");
+ ce->addValue("Finnish");
+ ce->addValue("German");
+ ce->addValue("Hungarian");
+ ce->addValue("Italian");
+ ce->addValue("Japanese");
+ ce->addValue("Korean");
+ ce->addValue("Norwegian");
+ ce->addValue("Romanian");
+ ce->addValue("Russian");
+ ce->addValue("Polish");
+ ce->addValue("Portuguese");
+ ce->addValue("Slovene");
+ ce->addValue("Spanish");
+ ce->addValue("Swedish");
+ cb = addBool( //"extractAllFlag",
+ "EXTRACT_ALL",
+ "If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in \n"
+ "documentation are documented, even if no documentation was available. \n"
+ "Private class members and static file members will be hidden unless \n"
+ "the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES \n",
+ FALSE
+ );
+ cb = addBool( //"extractPrivateFlag",
+ "EXTRACT_PRIVATE",
+ "If the EXTRACT_PRIVATE tag is set to YES all private members of a class \n"
+ "will be included in the documentation. \n",
+ FALSE
+ );
+ cb = addBool( //"extractStaticFlag",
+ "EXTRACT_STATIC",
+ "If the EXTRACT_STATIC tag is set to YES all static members of a file \n"
+ "will be included in the documentation. \n",
+ FALSE
+ );
+ cb = addBool( //"hideMemberFlag",
+ "HIDE_UNDOC_MEMBERS",
+ "If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all \n"
+ "undocumented members of documented classes, files or namespaces. \n"
+ "If set to NO (the default) these members will be included in the \n"
+ "various overviews, but no documentation section is generated. \n"
+ "This option has no effect if EXTRACT_ALL is enabled. \n",
+ FALSE
+ );
+ cb = addBool( //"hideClassFlag",
+ "HIDE_UNDOC_CLASSES",
+ "If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all \n"
+ "undocumented classes that are normally visible in the class hierarchy. \n"
+ "If set to NO (the default) these class will be included in the various \n"
+ "overviews. This option has no effect if EXTRACT_ALL is enabled. \n",
+ FALSE
+ );
+ cb = addBool( //"briefMemDescFlag",
+ "BRIEF_MEMBER_DESC",
+ "If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will \n"
+ "include brief member descriptions after the members that are listed in \n"
+ "the file and class documentation (similar to JavaDoc). \n"
+ "Set to NO to disable this. \n",
+ TRUE
+ );
+ cb = addBool( //"repeatBriefFlag",
+ "REPEAT_BRIEF",
+ "If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend \n"
+ "the brief description of a member or function before the detailed description. \n"
+ "Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the \n"
+ "brief descriptions will be completely suppressed. \n",
+ TRUE
+ );
+ cb = addBool( //"alwaysDetailsFlag",
+ "ALWAYS_DETAILED_SEC",
+ "If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then \n"
+ "Doxygen will generate a detailed section even if there is only a brief \n"
+ "description. \n",
+ FALSE
+ );
+ cb = addBool( //"fullPathNameFlag",
+ "FULL_PATH_NAMES",
+ "If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full \n"
+ "path before files name in the file list and in the header files. If set \n"
+ "to NO the shortest path that makes the file name unique will be used. \n",
+ FALSE
+ );
+ cl = addList( //"stripFromPath",
+ "STRIP_FROM_PATH",
+ "If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag \n"
+ "can be used to strip a user defined part of the path. Stripping is \n"
+ "only done if one of the specified strings matches the left-hand part of \n"
+ "the path. It is allowed to use relative paths in the argument list.\n"
+ );
+ cl->addDependency("FULL_PATH_NAMES");
+ cb = addBool( //"internalDocsFlag",
+ "INTERNAL_DOCS",
+ "The INTERNAL_DOCS tag determines if documentation \n"
+ "that is typed after a \\internal command is included. If the tag is set \n"
+ "to NO (the default) then the documentation will be excluded. \n"
+ "Set it to YES to include the internal documentation. \n",
+ FALSE
+ );
+ cb = addBool( //"classDiagramFlag",
+ "CLASS_DIAGRAMS",
+ "If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will \n"
+ "generate a class diagram (in Html and LaTeX) for classes with base or \n"
+ "super classes. Setting the tag to NO turns the diagrams off. \n",
+ TRUE
+ );
+ cb = addBool( //"sourceBrowseFlag",
+ "SOURCE_BROWSER",
+ "If the SOURCE_BROWSER tag is set to YES then a list of source files will \n"
+ "be generated. Documented entities will be cross-referenced with these sources. \n",
+ FALSE
+ );
+ cb = addBool( //"inlineSourceFlag",
+ "INLINE_SOURCES",
+ "Setting the INLINE_SOURCES tag to YES will include the body \n"
+ "of functions and classes directly in the documentation. \n",
+ FALSE
+ );
+ cb = addBool( //"stripCommentsFlag",
+ "STRIP_CODE_COMMENTS",
+ "Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct \n"
+ "doxygen to hide any special comment blocks from generated source code \n"
+ "fragments. Normal C and C++ comments will always remain visible. \n",
+ TRUE
+ );
+ cb = addBool( //"caseSensitiveNames",
+ "CASE_SENSE_NAMES",
+ "If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate \n"
+ "file names in lower case letters. If set to YES upper case letters are also \n"
+ "allowed. This is useful if you have classes or files whose names only differ \n"
+ "in case and if your file system supports case sensitive file names. Windows \n"
+ "users are adviced to set this option to NO.\n",
+ TRUE
+ );
+ cb = addBool( //"hideScopeNames",
+ "HIDE_SCOPE_NAMES",
+ "If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen \n"
+ "will show members with their full class and namespace scopes in the \n"
+ "documentation. If set to YES the scope will be hidden. \n",
+ FALSE
+ );
+ cb = addBool( //"verbatimHeaderFlag",
+ "VERBATIM_HEADERS",
+ "If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen \n"
+ "will generate a verbatim copy of the header file for each class for \n"
+ "which an include is specified. Set to NO to disable this. \n",
+ TRUE
+ );
+ cb = addBool( //"showIncFileFlag",
+ "SHOW_INCLUDE_FILES",
+ "If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen \n"
+ "will put list of the files that are included by a file in the documentation \n"
+ "of that file. \n",
+ TRUE
+ );
+ cb = addBool( //"autoBriefFlag",
+ "JAVADOC_AUTOBRIEF",
+ "If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen \n"
+ "will interpret the first line (until the first dot) of a JavaDoc-style \n"
+ "comment as the brief description. If set to NO, the JavaDoc \n"
+ "comments will behave just like the Qt-style comments (thus requiring an \n"
+ "explict @brief command for a brief description. \n",
+ FALSE
+ );
+ cb = addBool( //"inheritDocsFlag",
+ "INHERIT_DOCS",
+ "If the INHERIT_DOCS tag is set to YES (the default) then an undocumented \n"
+ "member inherits the documentation from any documented member that it \n"
+ "reimplements. \n",
+ TRUE
+ );
+ cb = addBool( //"inlineInfoFlag",
+ "INLINE_INFO",
+ "If the INLINE_INFO tag is set to YES (the default) then a tag [inline] \n"
+ "is inserted in the documentation for inline members. \n",
+ TRUE
+ );
+ cb = addBool( //"sortMembersFlag",
+ "SORT_MEMBER_DOCS",
+ "If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen \n"
+ "will sort the (detailed) documentation of file and class members \n"
+ "alphabetically by member name. If set to NO the members will appear in \n"
+ "declaration order. \n",
+ TRUE
+ );
+ cb = addBool( //"distributeDocFlag",
+ "DISTRIBUTE_GROUP_DOC",
+ "If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC \n"
+ "tag is set to YES, then doxygen will reuse the documentation of the first \n"
+ "member in the group (if any) for the other members of the group. By default \n"
+ "all members of a group must be documented explicitly.\n",
+ FALSE
+ );
+ ci = addInt( //"tabSize",
+ "TAB_SIZE",
+ "The TAB_SIZE tag can be used to set the number of spaces in a tab. \n"
+ "Doxygen uses this value to replace tabs by spaces in code fragments. \n",
+ 1,16,8
+ );
+ cl = addList( //"sectionFilterList",
+ "ENABLED_SECTIONS",
+ "The ENABLE_SECTIONS tag can be used to enable conditional \n"
+ "documentation sections, marked by \\if sectionname ... \\endif. \n"
+ );
+ cb = addBool( //"generateTodoList",
+ "GENERATE_TODOLIST",
+ "The GENERATE_TODOLIST tag can be used to enable (YES) or \n"
+ "disable (NO) the todo list. This list is created by putting \\todo \n"
+ "commands in the documentation.\n",
+ TRUE
+ );
+ cb = addBool( //"generateTestList",
+ "GENERATE_TESTLIST",
+ "The GENERATE_TESTLIST tag can be used to enable (YES) or \n"
+ "disable (NO) the test list. This list is created by putting \\test \n"
+ "commands in the documentation.\n",
+ TRUE
+ );
+ cb = addBool( //"generateBugList",
+ "GENERATE_BUGLIST",
+ "The GENERATE_BUGLIST tag can be used to enable (YES) or \n"
+ "disable (NO) the bug list. This list is created by putting \\bug \n"
+ "commands in the documentation.\n",
+ TRUE
+ );
+ cl = addList( //"aliasList",
+ "ALIASES",
+ "This tag can be used to specify a number of aliases that acts \n"
+ "as commands in the documentation. An alias has the form \"name=value\". \n"
+ "For example adding \"sideeffect=\\par Side Effects:\\n\" will allow you to \n"
+ "put the command \\sideeffect (or @sideeffect) in the documentation, which \n"
+ "will result in a user defined paragraph with heading \"Side Effects:\". \n"
+ "You can put \\n's in the value part of an alias to insert newlines. \n"
+ );
+ ci = addInt( //"maxInitLines",
+ "MAX_INITIALIZER_LINES",
+ "The MAX_INITIALIZER_LINES tag determines the maximum number of lines \n"
+ "the initial value of a variable or define consist of for it to appear in \n"
+ "the documentation. If the initializer consists of more lines than specified \n"
+ "here it will be hidden. Use a value of 0 to hide initializers completely. \n"
+ "The appearance of the initializer of individual variables and defines in the \n"
+ "documentation can be controlled using \\showinitializer or \\hideinitializer \n"
+ "command in the documentation regardless of this setting. \n",
+ 0,10000,30
+ );
+ cb = addBool( //"optimizeForCFlag",
+ "OPTIMIZE_OUTPUT_FOR_C",
+ "Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources \n"
+ "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"
+ "of all members will be omitted, etc. \n",
+ FALSE
+ );
+ cb = addBool( //"showUsedFilesFlag",
+ "SHOW_USED_FILES",
+ "Set the SHOW_USED_FILES tag to NO to disable the list of files generated \n"
+ "at the bottom of the documentation of classes and structs. If set to YES the \n"
+ "list will mention the files that were used to generate the documentation. \n",
+ TRUE
+ );
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "Messages","configuration options related to warning and progress messages");
+ //-----------------------------------------------------------------------------------------------
+
+ cb = addBool( //"quietFlag",
+ "QUIET",
+ "The QUIET tag can be used to turn on/off the messages that are generated \n"
+ "by doxygen. Possible values are YES and NO. If left blank NO is used. \n",
+ FALSE
+ );
+ cb = addBool( //"warningFlag",
+ "WARNINGS",
+ "The WARNINGS tag can be used to turn on/off the warning messages that are \n"
+ "generated by doxygen. Possible values are YES and NO. If left blank \n"
+ "NO is used. \n",
+ TRUE
+ );
+ cb = addBool( //"warningUndocFlag",
+ "WARN_IF_UNDOCUMENTED",
+ "If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings \n"
+ "for undocumented members. If EXTRACT_ALL is set to YES then this flag will \n"
+ "automatically be disabled. \n",
+ TRUE
+ );
+ cs = addString(//"warnFormat",
+ "WARN_FORMAT",
+ "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"
+ "tags, which will be replaced by the file and line number from which the \n"
+ "warning originated and the warning text. \n"
+ );
+ cs->setDefaultValue("$file:$line: $text");
+ cs = addString(//"warnLogFile",
+ "WARN_LOGFILE",
+ "The WARN_LOGFILE tag can be used to specify a file to which warning \n"
+ "and error messages should be written. If left blank the output is written \n"
+ "to stderr. \n"
+ );
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "Input","configuration options related to the input files");
+ //-----------------------------------------------------------------------------------------------
+ cl = addList( //"inputSources",
+ "INPUT",
+ "The INPUT tag can be used to specify the files and/or directories that contain \n"
+ "documented source files. You may enter file names like \"myfile.cpp\" or \n"
+ "directories like \"/usr/src/myproject\". Separate the files or directories \n"
+ "with spaces. \n"
+ );
+ cl->setWidgetType(ConfigList::FileAndDir);
+ cl = addList( //"filePatternList",
+ "FILE_PATTERNS",
+ "If the value of the INPUT tag contains directories, you can use the \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"
+ "blank all files are included. \n"
+ );
+ cb = addBool( //"recursiveFlag",
+ "RECURSIVE",
+ "The RECURSIVE tag can be used to turn specify whether or not subdirectories \n"
+ "should be searched for input files as well. Possible values are YES and NO. \n"
+ "If left blank NO is used. \n",
+ FALSE
+ );
+ cl = addList( //"excludeSources",
+ "EXCLUDE",
+ "The EXCLUDE tag can be used to specify files and/or directories that should \n"
+ "excluded from the INPUT source files. This way you can easily exclude a \n"
+ "subdirectory from a directory tree whose root is specified with the INPUT tag. \n"
+ );
+ cl->setWidgetType(ConfigList::FileAndDir);
+ cl = addList( //"excludePatternList",
+ "EXCLUDE_PATTERNS",
+ "If the value of the INPUT tag contains directories, you can use the \n"
+ "EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude \n"
+ "certain files from those directories. \n"
+ );
+ cl = addList( //"examplePath",
+ "EXAMPLE_PATH",
+ "The EXAMPLE_PATH tag can be used to specify one or more files or \n"
+ "directories that contain example code fragments that are included (see \n"
+ "the \\include command). \n"
+ );
+ cl->setWidgetType(ConfigList::Dir);
+ cl = addList( //"examplePatternList",
+ "EXAMPLE_PATTERNS",
+ "If the value of the EXAMPLE_PATH tag contains directories, you can use the \n"
+ "EXAMPLE_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"
+ "blank all files are included. \n"
+ );
+ cl = addList( //"imagePath",
+ "IMAGE_PATH",
+ "The IMAGE_PATH tag can be used to specify one or more files or \n"
+ "directories that contain image that are included in the documentation (see \n"
+ "the \\image command). \n"
+ );
+ cl->setWidgetType(ConfigList::Dir);
+ cs = addString(//"inputFilter",
+ "INPUT_FILTER",
+ "The INPUT_FILTER tag can be used to specify a program that doxygen should \n"
+ "invoke to filter for each input file. Doxygen will invoke the filter program \n"
+ "by executing (via popen()) the command <filter> <input-file>, where <filter> \n"
+ "is the value of the INPUT_FILTER tag, and <input-file> is the name of an \n"
+ "input file. Doxygen will then use the output that the filter program writes \n"
+ "to standard output. \n"
+ );
+ cl->setWidgetType(ConfigList::File);
+ cb = addBool( //"filterForSourceFlag",
+ "FILTER_SOURCE_FILES",
+ "If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using \n"
+ "INPUT_FILTER) will be used to filter the input files when producing source \n"
+ "files to browse. \n",
+ FALSE
+ );
+
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "Index","configuration options related to the alphabetical class index");
+ //-----------------------------------------------------------------------------------------------
+
+ cb = addBool( //"alphaIndexFlag",
+ "ALPHABETICAL_INDEX",
+ "If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index \n"
+ "of all compounds will be generated. Enable this if the project \n"
+ "contains a lot of classes, structs, unions or interfaces. \n",
+ FALSE
+ );
+ ci = addInt( //"colsInAlphaIndex",
+ "COLS_IN_ALPHA_INDEX",
+ "If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then \n"
+ "the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns \n"
+ "in which this list will be split (can be a number in the range [1..20]) \n",
+ 1,20,5
+ );
+ cl = addList( //"ignorePrefixList",
+ "IGNORE_PREFIX",
+ "In case all classes in a project start with a common prefix, all \n"
+ "classes will be put under the same header in the alphabetical index. \n"
+ "The IGNORE_PREFIX tag can be used to specify one or more prefixes that \n"
+ "should be ignored while generating the index headers. \n"
+ );
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "HTML","configuration options related to the HTML output");
+ //-----------------------------------------------------------------------------------------------
+ cb = addBool( //"generateHtml",
+ "GENERATE_HTML",
+ "If the GENERATE_HTML tag is set to YES (the default) Doxygen will \n"
+ "generate HTML output. \n",
+ TRUE
+ );
+ cs = addString(//"htmlOutputDir",
+ "HTML_OUTPUT",
+ "The HTML_OUTPUT tag is used to specify where the HTML docs will be put. \n"
+ "If a relative path is entered the value of OUTPUT_DIRECTORY will be \n"
+ "put in front of it. If left blank `html' will be used as the default path. \n"
+ );
+ cs->setDefaultValue("html");
+ cs->setWidgetType(ConfigString::Dir);
+ cs->addDependency("GENERATE_HTML");
+ cs = addString(//"headerFile",
+ "HTML_HEADER",
+ "The HTML_HEADER tag can be used to specify a personal HTML header for \n"
+ "each generated HTML page. If it is left blank doxygen will generate a \n"
+ "standard header.\n"
+ );
+ cs->setWidgetType(ConfigString::File);
+ cs->addDependency("GENERATE_HTML");
+ cs = addString(//"footerFile",
+ "HTML_FOOTER",
+ "The HTML_FOOTER tag can be used to specify a personal HTML footer for \n"
+ "each generated HTML page. If it is left blank doxygen will generate a \n"
+ "standard footer.\n"
+ );
+ cs->setWidgetType(ConfigString::File);
+ cs->addDependency("GENERATE_HTML");
+ cs = addString(//"htmlStyleSheet",
+ "HTML_STYLESHEET",
+ "The HTML_STYLESHEET tag can be used to specify a user defined cascading \n"
+ "style sheet that is used by each HTML page. It can be used to \n"
+ "fine-tune the look of the HTML output. If the tag is left blank doxygen \n"
+ "will generate a default style sheet \n"
+ );
+ cs->setWidgetType(ConfigString::File);
+ cs->addDependency("GENERATE_HTML");
+ cb = addBool( //"htmlAlignMemberFlag",
+ "HTML_ALIGN_MEMBERS",
+ "If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, \n"
+ "files or namespaces will be aligned in HTML using tables. If set to \n"
+ "NO a bullet list will be used. \n",
+ TRUE
+ );
+ cb->addDependency("GENERATE_HTML");
+ cb = addBool( //"htmlHelpFlag",
+ "GENERATE_HTMLHELP",
+ "If the GENERATE_HTMLHELP tag is set to YES, additional index files \n"
+ "will be generated that can be used as input for tools like the \n"
+ "Microsoft HTML help workshop to generate a compressed HTML help file (.chm) \n"
+ "of the generated HTML documentation. \n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_HTML");
+ cb = addBool( //"htmlHelpChiFlag",
+ "GENERATE_CHI",
+ "If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag \n"
+ "controls if a separate .chi index file is generated (YES) or that \n"
+ "it should be included in the master .chm file (NO).\n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_HTML");
+ cb = addBool( //"htmlHelpTocFlag",
+ "BINARY_TOC",
+ "If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag \n"
+ "controls whether a binary table of contents is generated (YES) or a \n"
+ "normal table of contents (NO) in the .chm file.\n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_HTML");
+ cb = addBool( //"htmlHelpTocExpandFlag",
+ "TOC_EXPAND",
+ "The TOC_EXPAND flag can be set YES to add extra items for group members \n"
+ "to the contents of the Html help documentation and to the tree view. \n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_HTML");
+ cb = addBool( //"noIndexFlag",
+ "DISABLE_INDEX",
+ "The DISABLE_INDEX tag can be used to turn on/off the condensed index at \n"
+ "top of each HTML page. The value NO (the default) enables the index and \n"
+ "the value YES disables it. \n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_HTML");
+ ci = addInt( //"enumValuesPerLine",
+ "ENUM_VALUES_PER_LINE",
+ "This tag can be used to set the number of enum values (range [1..20]) \n"
+ "that doxygen will group on one line in the generated HTML documentation. \n",
+ 1,20,4
+ );
+ ci->addDependency("GENERATE_HTML");
+ cb = addBool( //"ftvHelpFlag",
+ "GENERATE_TREEVIEW",
+ "If the GENERATE_TREEVIEW tag is set to YES, a side panel will be\n"
+ "generated containing a tree-like index structure (just like the one that \n"
+ "is generated for HTML Help). For this to work a browser that supports \n"
+ "JavaScript and frames is required (for instance Netscape 4.0+ \n"
+ "or Internet explorer 4.0+). ",
+ FALSE
+ );
+ cb->addDependency("GENERATE_HTML");
+ ci = addInt( //"treeViewWidth",
+ "TREEVIEW_WIDTH",
+ "If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be \n"
+ "used to set the initial width (in pixels) of the frame in which the tree \n"
+ "is shown. \n",
+ 0,1500,250
+ );
+ ci->addDependency("GENERATE_HTML");
+
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "LaTeX","configuration options related to the LaTeX output");
+ //-----------------------------------------------------------------------------------------------
+ cb = addBool( //"generateLatex",
+ "GENERATE_LATEX",
+ "If the GENERATE_LATEX tag is set to YES (the default) Doxygen will \n"
+ "generate Latex output. \n",
+ TRUE
+ );
+ cs = addString(//"latexOutputDir",
+ "LATEX_OUTPUT",
+ "The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. \n"
+ "If a relative path is entered the value of OUTPUT_DIRECTORY will be \n"
+ "put in front of it. If left blank `latex' will be used as the default path. \n"
+ );
+ cs->setDefaultValue("latex");
+ cs->setWidgetType(ConfigString::Dir);
+ cs->addDependency("GENERATE_LATEX");
+ cb = addBool( //"compactLatexFlag",
+ "COMPACT_LATEX",
+ "If the COMPACT_LATEX tag is set to YES Doxygen generates more compact \n"
+ "LaTeX documents. This may be useful for small projects and may help to \n"
+ "save some trees in general. \n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_LATEX");
+ ce = addEnum(//"paperType",
+ "PAPER_TYPE",
+ "The PAPER_TYPE tag can be used to set the paper type that is used \n"
+ "by the printer. Possible values are: a4, a4wide, letter, legal and \n"
+ "executive. If left blank a4wide will be used. \n",
+ "a4wide"
+ );
+ ce->addValue("a4");
+ ce->addValue("a4wide");
+ ce->addValue("letter");
+ ce->addValue("legal");
+ ce->addValue("executive");
+ ce->addDependency("GENERATE_LATEX");
+ cl = addList( //"extraPackageList",
+ "EXTRA_PACKAGES",
+ "The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX \n"
+ "packages that should be included in the LaTeX output. \n"
+ );
+ cl->addDependency("GENERATE_LATEX");
+ cs = addString(//"latexHeaderFile",
+ "LATEX_HEADER",
+ "The LATEX_HEADER tag can be used to specify a personal LaTeX header for \n"
+ "the generated latex document. The header should contain everything until \n"
+ "the first chapter. If it is left blank doxygen will generate a \n"
+ "standard header. Notice: only use this tag if you know what you are doing! \n"
+ );
+ cs->setWidgetType(ConfigString::File);
+ cs->addDependency("GENERATE_LATEX");
+ cb = addBool( //"pdfHyperFlag",
+ "PDF_HYPERLINKS",
+ "If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated \n"
+ "is prepared for conversion to pdf (using ps2pdf). The pdf file will \n"
+ "contain links (just like the HTML output) instead of page references \n"
+ "This makes the output suitable for online browsing using a pdf viewer. \n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_LATEX");
+ cb = addBool( //"usePDFLatexFlag",
+ "USE_PDFLATEX",
+ "If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of \n"
+ "plain latex in the generated Makefile. Set this option to YES to get a \n"
+ "higher quality PDF documentation. \n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_LATEX");
+ cb = addBool( //"latexBatchModeFlag",
+ "LATEX_BATCHMODE",
+ "If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\\\batchmode. \n"
+ "command to the generated LaTeX files. This will instruct LaTeX to keep \n"
+ "running if errors occur, instead of asking the user for help. \n"
+ "This option is also used when generating formulas in HTML. \n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_LATEX");
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "RTF","configuration options related to the RTF output");
+ //-----------------------------------------------------------------------------------------------
+ cb = addBool( //"generateRTF",
+ "GENERATE_RTF",
+ "If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output \n"
+ "The RTF output is optimised for Word 97 and may not look very pretty with \n"
+ "other RTF readers or editors.\n",
+ TRUE
+ );
+ cs = addString(//"rtfOutputDir",
+ "RTF_OUTPUT",
+ "The RTF_OUTPUT tag is used to specify where the RTF docs will be put. \n"
+ "If a relative path is entered the value of OUTPUT_DIRECTORY will be \n"
+ "put in front of it. If left blank `rtf' will be used as the default path. \n"
+ );
+ cs->setDefaultValue("rtf");
+ cs->setWidgetType(ConfigString::Dir);
+ cs->addDependency("GENERATE_RTF");
+ cb = addBool( //"compactRTFFlag",
+ "COMPACT_RTF",
+ "If the COMPACT_RTF tag is set to YES Doxygen generates more compact \n"
+ "RTF documents. This may be useful for small projects and may help to \n"
+ "save some trees in general. \n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_RTF");
+ cb = addBool( //"rtfHyperFlag",
+ "RTF_HYPERLINKS",
+ "If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated \n"
+ "will contain hyperlink fields. The RTF file will \n"
+ "contain links (just like the HTML output) instead of page references. \n"
+ "This makes the output suitable for online browsing using a WORD or other. \n"
+ "programs which support those fields. \n"
+ "Note: wordpad (write) and others do not support links. \n",
+ FALSE
+ );
+ cb->addDependency("GENERATE_RTF");
+ cs = addString(//"rtfStylesheetFile",
+ "RTF_STYLESHEET_FILE",
+ "Load stylesheet definitions from file. Syntax is similar to doxygen's \n"
+ "config file, i.e. a series of assigments. You only have to provide \n"
+ "replacements, missing definitions are set to their default value. \n"
+ );
+ cs->setWidgetType(ConfigString::File);
+ cs->addDependency("GENERATE_RTF");
+ cs = addString(//"rtfExtentionsFile",
+ "RTF_EXTENSIONS_FILE",
+ "Set optional variables used in the generation of an rtf document. \n"
+ "Syntax is similar to doxygen's config file.\n"
+ );
+ cs->setWidgetType(ConfigString::File);
+ cs->addDependency("GENERATE_RTF");
+
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "Man","configuration options related to the man page output");
+ //-----------------------------------------------------------------------------------------------
+ cb = addBool( //"generateMan",
+ "GENERATE_MAN",
+ "If the GENERATE_MAN tag is set to YES (the default) Doxygen will \n"
+ "generate man pages \n",
+ TRUE
+ );
+ cs = addString(//"manOutputDir",
+ "MAN_OUTPUT",
+ "The MAN_OUTPUT tag is used to specify where the man pages will be put. \n"
+ "If a relative path is entered the value of OUTPUT_DIRECTORY will be \n"
+ "put in front of it. If left blank `man' will be used as the default path. \n"
+ );
+ cs->setDefaultValue("man");
+ cs->setWidgetType(ConfigString::Dir);
+ cs->addDependency("GENERATE_MAN");
+ cs = addString(//"manExtension",
+ "MAN_EXTENSION",
+ "The MAN_EXTENSION tag determines the extension that is added to \n"
+ "the generated man pages (default is the subroutine's section .3) \n"
+ );
+ cs->setDefaultValue(".3");
+ cs->addDependency("GENERATE_MAN");
+ //-----------------------------------------------------------------------------------------------
+ //addInfo( "XML","configuration options related to the XML output");
+ //-----------------------------------------------------------------------------------------------
+ //addBool( "generateXML",
+ // "GENERATE_XML",
+ // "FALSE",
+ // "generate XML output",
+ // "If the GENERATE_XML tag is set to YES Doxygen will \n"
+ // "generate an XML file that captures the structure of \n"
+ // "the code including all documentation. Warning: This feature \n"
+ // "is still experimental and very incomplete.\n"
+ // );
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "Preprocessor","Configuration options related to the preprocessor ");
+ //-----------------------------------------------------------------------------------------------
+ cb = addBool( //"preprocessingFlag",
+ "ENABLE_PREPROCESSING",
+ "If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will \n"
+ "evaluate all C-preprocessor directives found in the sources and include \n"
+ "files. \n",
+ TRUE
+ );
+ cb = addBool( //"macroExpansionFlag",
+ "MACRO_EXPANSION",
+ "If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro \n"
+ "names in the source code. If set to NO (the default) only conditional \n"
+ "compilation will be performed. Macro expansion can be done in a controlled \n"
+ "way by setting EXPAND_ONLY_PREDEF to YES. \n",
+ FALSE
+ );
+ cb->addDependency("ENABLE_PREPROCESSING");
+ cb = addBool( //"onlyPredefinedFlag",
+ "EXPAND_ONLY_PREDEF",
+ "If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES \n"
+ "then the macro expansion is limited to the macros specified with the \n"
+ "PREDEFINED and EXPAND_AS_PREDEFINED tags. \n",
+ FALSE
+ );
+ cb->addDependency("ENABLE_PREPROCESSING");
+ cb = addBool( //"searchIncludeFlag",
+ "SEARCH_INCLUDES",
+ "If the SEARCH_INCLUDES tag is set to YES (the default) the includes files \n"
+ "in the INCLUDE_PATH (see below) will be search if a #include is found. \n",
+ TRUE
+ );
+ cb->addDependency("ENABLE_PREPROCESSING");
+ cl = addList( //"includePath",
+ "INCLUDE_PATH",
+ "The INCLUDE_PATH tag can be used to specify one or more directories that \n"
+ "contain include files that are not input files but should be processed by \n"
+ "the preprocessor. \n"
+ );
+ cl->setWidgetType(ConfigList::Dir);
+ cl->addDependency("ENABLE_PREPROCESSING");
+ cl = addList( //"includeFilePatternList",
+ "INCLUDE_FILE_PATTERNS",
+ "You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard \n"
+ "patterns (like *.h and *.hpp) to filter out the header-files in the \n"
+ "directories. If left blank, the patterns specified with FILE_PATTERNS will \n"
+ "be used. \n"
+ );
+ cl->addDependency("ENABLE_PREPROCESSING");
+ cl = addList( //"predefined",
+ "PREDEFINED",
+ "The PREDEFINED tag can be used to specify one or more macro names that \n"
+ "are defined before the preprocessor is started (similar to the -D option of \n"
+ "gcc). The argument of the tag is a list of macros of the form: name \n"
+ "or name=definition (no spaces). If the definition and the = are \n"
+ "omitted =1 is assumed. \n"
+ );
+ cl->addDependency("ENABLE_PREPROCESSING");
+ cl = addList( //"expandAsDefinedList",
+ "EXPAND_AS_DEFINED",
+ "If the MACRO_EXPANSION and EXPAND_PREDEF_ONLY tags are set to YES then \n"
+ "this tag can be used to specify a list of macro names that should be expanded. \n"
+ "The macro definition that is found in the sources will be used. \n"
+ "Use the PREDEFINED tag if you want to use a different macro definition. \n"
+ );
+ cl->addDependency("ENABLE_PREPROCESSING");
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "External","Configuration::addtions related to external references ");
+ //-----------------------------------------------------------------------------------------------
+ cl = addList( //"tagFileList",
+ "TAGFILES",
+ "The TAGFILES tag can be used to specify one or more tagfiles. \n"
+ );
+ cl->setWidgetType(ConfigList::File);
+ cs = addString(//"genTagFile",
+ "GENERATE_TAGFILE",
+ "When a file name is specified after GENERATE_TAGFILE, doxygen will create \n"
+ "a tag file that is based on the input files it reads. \n"
+ );
+ cs->setWidgetType(ConfigString::File);
+ cb = addBool( //"allExtFlag",
+ "ALLEXTERNALS",
+ "If the ALLEXTERNALS tag is set to YES all external classes will be listed \n"
+ "in the class index. If set to NO only the inherited external classes \n"
+ "will be listed. \n",
+ FALSE
+ );
+ cs = addString(//"perlPath",
+ "PERL_PATH",
+ "The PERL_PATH should be the absolute path and name of the perl script \n"
+ "interpreter (i.e. the result of `which perl'). \n"
+ );
+ cs->setDefaultValue("/usr/bin/perl");
+ cs->setWidgetType(ConfigString::Dir);
+
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "Dot","Configuration options related to the dot tool ");
+ //-----------------------------------------------------------------------------------------------
+ cb = addBool( //"haveDotFlag",
+ "HAVE_DOT",
+ "If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is \n"
+ "available from the path. This tool is part of Graphviz, a graph visualization \n"
+ "toolkit from AT&T and Lucent Bell Labs. The other options in this section \n"
+ "have no effect if this option is set to NO (the default) \n",
+ FALSE
+ );
+ cb = addBool( //"classGraphFlag",
+ "CLASS_GRAPH",
+ "If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen \n"
+ "will generate a graph for each documented class showing the direct and \n"
+ "indirect inheritance relations. Setting this tag to YES will force the \n"
+ "the CLASS_DIAGRAMS tag to NO.\n",
+ TRUE
+ );
+ cb->addDependency("HAVE_DOT");
+ cb = addBool( //"collGraphFlag",
+ "COLLABORATION_GRAPH",
+ "If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen \n"
+ "will generate a graph for each documented class showing the direct and \n"
+ "indirect implementation dependencies (inheritance, containment, and \n"
+ "class references variables) of the class with other documented classes. \n",
+ TRUE
+ );
+ cb->addDependency("HAVE_DOT");
+ cb = addBool( //"includeGraphFlag",
+ "INCLUDE_GRAPH",
+ "If the ENABLE_PREPROCESSING, INCLUDE_GRAPH, and HAVE_DOT tags are set to \n"
+ "YES then doxygen will generate a graph for each documented file showing \n"
+ "the direct and indirect include dependencies of the file with other \n"
+ "documented files. \n",
+ TRUE
+ );
+ cb->addDependency("HAVE_DOT");
+ cb = addBool( //"includedByGraphFlag",
+ "INCLUDED_BY_GRAPH",
+ "If the ENABLE_PREPROCESSING, INCLUDED_BY_GRAPH, and HAVE_DOT tags are set to \n"
+ "YES then doxygen will generate a graph for each documented header file showing \n"
+ "the documented files that directly or indirectly include this file \n",
+ TRUE
+ );
+ cb->addDependency("HAVE_DOT");
+ cb = addBool( //"gfxHierarchyFlag",
+ "GRAPHICAL_HIERARCHY",
+ "If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen \n"
+ "will graphical hierarchy of all classes instead of a textual one. \n",
+ TRUE
+ );
+ cb->addDependency("HAVE_DOT");
+ cs = addString(//"dotPath",
+ "DOT_PATH",
+ "The tag DOT_PATH can be used to specify the path where the dot tool can be \n"
+ "found. If left blank, it is assumed the dot tool can be found on the path. \n"
+ );
+ cs->setWidgetType(ConfigString::Dir);
+ cs->addDependency("HAVE_DOT");
+ ci = addInt( //"maxDotGraphWidth",
+ "MAX_DOT_GRAPH_WIDTH",
+ "The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width \n"
+ "(in pixels) of the graphs generated by dot. If a graph becomes larger than \n"
+ "this value, doxygen will try to truncate the graph, so that it fits within \n"
+ "the specified constraint. Beware that most browsers cannot cope with very \n"
+ "large images. \n",
+ 100,30000, 1024
+ );
+ ci->addDependency("HAVE_DOT");
+ ci = addInt( //"maxDotGraphHeight",
+ "MAX_DOT_GRAPH_HEIGHT",
+ "The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height \n"
+ "(in pixels) of the graphs generated by dot. If a graph becomes larger than \n"
+ "this value, doxygen will try to truncate the graph, so that it fits within \n"
+ "the specified constraint. Beware that most browsers cannot cope with very \n"
+ "large images. \n",
+ 100,30000,1024
+ );
+ ci->addDependency("HAVE_DOT");
+ cb = addBool( //"generateLegend",
+ "GENERATE_LEGEND",
+ "If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will \n"
+ "generate a legend page explaining the meaning of the various boxes and \n"
+ "arrows in the dot generated graphs. \n",
+ TRUE
+ );
+ cb->addDependency("HAVE_DOT");
+ cb = addBool( //"dotCleanUp",
+ "DOT_CLEANUP",
+ "If the DOT_CLEANUP tag is set to YES (the default) Doxygen will \n"
+ "remove the intermedate dot files that are used to generate \n"
+ "the various graphs. \n",
+ TRUE
+ );
+ cb->addDependency("HAVE_DOT");
+
+ //-----------------------------------------------------------------------------------------------
+ addInfo( "Search","Configuration::addtions related to the search engine ");
+ //-----------------------------------------------------------------------------------------------
+ cb = addBool( //"searchEngineFlag",
+ "SEARCHENGINE",
+ "The SEARCHENGINE tag specifies whether or not a search engine should be \n"
+ "used. If set to NO the values of all tags below this one will be ignored. \n",
+ FALSE
+ );
+ cs = addString(//"cgiName",
+ "CGI_NAME",
+ "The CGI_NAME tag should be the name of the CGI script that \n"
+ "starts the search engine (doxysearch) with the correct parameters. \n"
+ "A script with this name will be generated by doxygen. \n"
+ );
+ cs->setDefaultValue("search.cgi");
+ cs->addDependency("SEARCHENGINE");
+ cs = addString(//"cgiURL",
+ "CGI_URL",
+ "The CGI_URL tag should be the absolute URL to the directory where the \n"
+ "cgi binaries are located. See the documentation of your http daemon for \n"
+ "details. \n"
+ );
+ cs->addDependency("SEARCHENGINE");
+ cs = addString(//"docURL",
+ "DOC_URL",
+ "The DOC_URL tag should be the absolute URL to the directory where the \n"
+ "documentation is located. If left blank the absolute path to the \n"
+ "documentation, with file:// prepended to it, will be used. \n"
+ );
+ cs->addDependency("SEARCHENGINE");
+ cs = addString(//"docAbsPath",
+ "DOC_ABSPATH",
+ "The DOC_ABSPATH tag should be the absolute path to the directory where the \n"
+ "documentation is located. If left blank the directory on the local machine \n"
+ "will be used. \n"
+ );
+ cs->setWidgetType(ConfigString::Dir);
+ cs->addDependency("SEARCHENGINE");
+ cs = addString(//"binAbsPath",
+ "BIN_ABSPATH",
+ "The BIN_ABSPATH tag must point to the directory where the doxysearch binary \n"
+ "is installed. \n"
+ );
+ cs->setDefaultValue("/usr/local/bin/");
+ cs->setWidgetType(ConfigString::Dir);
+ cs->addDependency("SEARCHENGINE");
+ cl = addList( //"extDocPathList",
+ "EXT_DOC_PATHS",
+ "The EXT_DOC_PATHS tag can be used to specify one or more paths to \n"
+ "documentation generated for other projects. This allows doxysearch to search \n"
+ "the documentation for these projects as well. \n"
+ );
+ cl->setWidgetType(ConfigList::Dir);
+ cl->addDependency("SEARCHENGINE");
+
+ // The IMAGE_PATTERNS tag is now officially obsolete.
+}
+
+
+void Config::parse(const QCString &s,const char *fn)
{
+ config = Config::instance();
inputString = s;
inputPosition = 0;
yyLineNr = 1;
diff --git a/src/define.cpp b/src/define.cpp
index 424e0be..31c4b76 100644
--- a/src/define.cpp
+++ b/src/define.cpp
@@ -42,5 +42,5 @@ Define::~Define()
bool Define::hasDocumentation()
{
- return definition && (doc || Config::extractAllFlag);
+ return definition && (doc || Config::instance()->getBool("EXTRACT_ALL"));
}
diff --git a/src/definition.cpp b/src/definition.cpp
index 7482856..b425702 100644
--- a/src/definition.cpp
+++ b/src/definition.cpp
@@ -73,7 +73,7 @@ QCString Definition::nameToFile(const char *name,bool allowDots)
case ',': result+="_x_"; break;
case ' ': break;
default:
- if (Config::caseSensitiveNames)
+ if (Config::instance()->getBool("CASE_SENSE_NAMES"))
result+=c;
else
result+=tolower(c);
@@ -111,7 +111,7 @@ void Definition::addSectionsToDefinition(QList<QCString> *anchorList)
void Definition::writeDocAnchorsToTagFile()
{
- if (!Config::genTagFile.isEmpty() && sectionDict)
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty() && sectionDict)
{
QDictIterator<SectionInfo> sdi(*sectionDict);
SectionInfo *si;
@@ -183,7 +183,7 @@ static bool readCodeFragment(const char *fileName,
}
else if (c=='\t')
{
- col+=Config::tabSize - (col%Config::tabSize);
+ col+=Config::instance()->getInt("TAB_SIZE") - (col%Config::instance()->getInt("TAB_SIZE"));
}
else
{
@@ -249,7 +249,7 @@ void Definition::writeSourceDef(OutputList &ol,const char *)
{
ol.pushGeneratorState();
//printf("Definition::writeSourceRef %d %p\n",bodyLine,bodyDef);
- if (Config::sourceBrowseFlag && startBodyLine!=-1 && bodyDef)
+ if (Config::instance()->getBool("SOURCE_BROWSER") && startBodyLine!=-1 && bodyDef)
{
//ol.disable(OutputGenerator::RTF);
ol.newParagraph();
@@ -346,7 +346,7 @@ void Definition::writeInlineCode(OutputList &ol,const char *scopeName)
ol.pushGeneratorState();
//printf("Source Fragment %s: %d-%d bodyDef=%p\n",name().data(),
// startBodyLine,endBodyLine,bodyDef);
- if (Config::inlineSourceFlag && startBodyLine!=-1 &&
+ if (Config::instance()->getBool("INLINE_SOURCES") && startBodyLine!=-1 &&
endBodyLine>=startBodyLine && bodyDef)
{
QCString codeFragment;
@@ -373,7 +373,7 @@ void Definition::writeInlineCode(OutputList &ol,const char *scopeName)
void Definition::writeSourceRefs(OutputList &ol,const char *scopeName)
{
ol.pushGeneratorState();
- if (Config::sourceBrowseFlag && sourceRefList)
+ if (Config::instance()->getBool("SOURCE_BROWSER") && sourceRefList)
{
ol.newParagraph();
parseText(ol,theTranslator->trReferencedBy());
@@ -434,7 +434,7 @@ bool Definition::hasDocumentation()
{
return !doc.isEmpty() || // has detailed docs
!brief.isEmpty() || // has brief description
- Config::extractAllFlag; // extract everything
+ Config::instance()->getBool("EXTRACT_ALL"); // extract everything
}
void Definition::addSourceReference(MemberDef *md)
diff --git a/src/diagram.cpp b/src/diagram.cpp
index 681fc89..997da07 100644
--- a/src/diagram.cpp
+++ b/src/diagram.cpp
@@ -205,7 +205,7 @@ QCString DiagramItem::label() const
{
result=classDef->name();
}
- if (Config::hideScopeNames) result=stripScope(result);
+ if (Config::instance()->getBool("HIDE_SCOPE_NAMES")) result=stripScope(result);
return result;
}
@@ -1233,7 +1233,7 @@ void ClassDiagram::writeFigure(QTextStream &output,const char *path,
super->drawConnectors(t,0,FALSE,FALSE,baseRows,superRows,0,0);
f1.close();
- if (Config::usePDFLatexFlag)
+ if (Config::instance()->getBool("USE_PDFLATEX"))
{
QCString epstopdfArgs(4096);
epstopdfArgs.sprintf("\"%s.eps\" --outfile=\"%s.pdf\"",
diff --git a/src/doc.l b/src/doc.l
index 46cc73d..49b45bb 100644
--- a/src/doc.l
+++ b/src/doc.l
@@ -350,6 +350,31 @@ static void verbIncludeFile(OutputDocInterface &od,const char *name)
}
}
+static void rawIncludeFile(OutputDocInterface &od,const char *name)
+{
+ bool ambig;
+ FileDef *fd;
+ if ((fd=findFileDef(Doxygen::exampleNameDict,name,ambig)))
+ {
+ od.writeString(fileToString(fd->absFilePath()));
+ }
+ else if (ambig)
+ {
+ QCString text;
+ text.sprintf("Include file name %s is ambigious.\n",name);
+ text+=("Possible candidates:\n");
+ text+=showFileDefMatches(Doxygen::exampleNameDict,name);
+ warn(yyFileName,yyLineNr,text);
+ }
+ else
+ {
+ warn(yyFileName,yyLineNr,
+ "Warning: include file %s is not found. "
+ "Check your EXAMPLE_PATH",name);
+ }
+}
+
+
static QCString stripQuotes(const char *s)
{
@@ -522,7 +547,7 @@ static void addListItemMarker(const char *marker,int dashPos,bool enumerated)
//printf("Parsed[%d]=%d\n",i,marker[i]);
if (marker[i]=='\t')
{
- indent+=Config::tabSize - (indent%Config::tabSize);
+ indent+=Config::instance()->getInt("TAB_SIZE") - (indent%Config::instance()->getInt("TAB_SIZE"));
}
else if (marker[i]=='\n')
{
@@ -653,13 +678,13 @@ static QCString findAndCopyImage(const char *fileName,ImageTypes type)
switch(type)
{
case IT_Html:
- outputDir = Config::htmlOutputDir;
+ outputDir = Config::instance()->getString("HTML_OUTPUT");
break;
case IT_Latex:
- outputDir = Config::latexOutputDir;
+ outputDir = Config::instance()->getString("LATEX_OUTPUT");
break;
case IT_RTF:
- outputDir = Config::rtfOutputDir;
+ outputDir = Config::instance()->getString("RTF_OUTPUT");
break;
}
QCString outputFile = outputDir+"/"+result;
@@ -866,6 +891,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
%x DocRefName
%x DocVerbatim
%x DocVerbInc
+%x DocHtmlInc
%x DocIndexWord
%x DocRefArg
%x DocRefArgStart
@@ -907,7 +933,8 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
<DocScan,Text>"&"[ANOano]"tilde;" { outDoc->writeTilde(yytext[1]); }
<DocScan,Text>"&szlig;" { outDoc->writeSharpS(); }
<DocScan,Text>"&"[cC]"cedil;" { outDoc->writeCCedil(yytext[1]); }
-<DocScan,Text>"&[aA]ring;" { outDoc->writeRing(yytext[1]); }
+<DocScan,Text>"&"[aA]"ring;" { outDoc->writeRing(yytext[1]); }
+<DocScan,Text>"&nbsp;" { outDoc->writeNonBreakableSpace(1); }
<DocScan,DocHtmlScan,DocLatexScan>"$("[a-z_A-Z]+")" {
QCString envvar=&yytext[2];
envvar=envvar.left(envvar.length()-1);
@@ -951,6 +978,14 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
verbIncludeFile(*outDoc,stripQuotes(yytext));
BEGIN( DocScan );
}
+<DocScan>{CMD}"htmlinclude"/{BN} { BEGIN( DocHtmlInc ); }
+<DocHtmlInc>{FILE} {
+ outDoc->pushGeneratorState();
+ outDoc->disableAllBut(OutputGenerator::Html);
+ rawIncludeFile(*outDoc,stripQuotes(yytext));
+ outDoc->popGeneratorState();
+ BEGIN( DocScan );
+ }
<DocScan>{CMD}"verbatim"/[^a-z_A-Z0-9] {
outDoc->startCodeFragment();
insideVerbatim=TRUE;
@@ -974,7 +1009,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
outDoc->codify(c);
}
<DocScan>{CMD}"internal"/{BN} {
- if (!Config::internalDocsFlag)
+ if (!Config::instance()->getBool("INTERNAL_DOCS"))
{
outDoc->newParagraph();
scanString(theTranslator->trForInternalUseOnly()+"\n");
@@ -1293,7 +1328,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
}
}
<DocScan>"\\todo "[0-9]+ { // this tag is generated in an earlier pass
- if (Config::generateTodoList)
+ if (Config::instance()->getBool("GENERATE_TODOLIST"))
{
QCString numStr=yytext;
numStr=numStr.right(numStr.length()-6);
@@ -1315,7 +1350,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
}
}
<DocScan>"\\test "[0-9]+ { // this tag is generated in an earlier pass
- if (Config::generateTestList)
+ if (Config::instance()->getBool("GENERATE_TESTLIST"))
{
QCString numStr=yytext;
numStr=numStr.right(numStr.length()-6);
@@ -1337,7 +1372,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
}
}
<DocScan>"\\bug "[0-9]+ { // this tag is generated in an earlier pass
- if (Config::generateBugList)
+ if (Config::instance()->getBool("GENERATE_BUGLIST"))
{
QCString numStr=yytext;
numStr=numStr.right(numStr.length()-5);
@@ -1621,7 +1656,7 @@ OPMASK ({B}*{OPNORM}({OPARG}?))|({OPCAST}{OPARG})
}
}
<DocIf>[^\n\t ]+ {
- if (Config::sectionFilterList.find(yytext)==-1)
+ if (Config::instance()->getList("ENABLED_SECTIONS").find(yytext)==-1)
{
outDoc->disableAll();
}
diff --git a/src/dot.cpp b/src/dot.cpp
index f060f88..6e445c8 100644
--- a/src/dot.cpp
+++ b/src/dot.cpp
@@ -167,9 +167,9 @@ static bool isLeaf(ClassDef *cd)
// if class is not a leaf
if (!isLeaf(bClass)) return FALSE;
// or class is not documented in this project
- if (!Config::allExtFlag && !bClass->isLinkableInProject()) return FALSE;
+ if (!Config::instance()->getBool("ALLEXTERNALS") && !bClass->isLinkableInProject()) return FALSE;
// or class is not documented and all ALLEXTERNALS = YES
- if (Config::allExtFlag && !bClass->isLinkable()) return FALSE;
+ if (Config::instance()->getBool("ALLEXTERNALS") && !bClass->isLinkable()) return FALSE;
}
}
return TRUE;
@@ -583,7 +583,7 @@ void DotGfxHierarchyTable::writeGraph(QTextStream &out,const char *path)
QCString dotArgs(4096);
dotArgs.sprintf("-Tgif \"%s\" -o \"%s\"",dotName.data(),gifName.data());
//printf("Running: dot -Tgif %s -o %s\n",dotName.data(),gifName.data());
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Problems running dot. Check your installation!\n");
out << "</table>" << endl;
@@ -591,7 +591,7 @@ void DotGfxHierarchyTable::writeGraph(QTextStream &out,const char *path)
}
dotArgs.sprintf("-Timap \"%s\" -o \"%s\"",dotName.data(),mapName.data());
//printf("Running: dot -Timap %s -o %s\n",dotName.data(),mapName.data());
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Problems running dot. Check your installation!\n");
out << "</table>" << endl;
@@ -602,7 +602,7 @@ void DotGfxHierarchyTable::writeGraph(QTextStream &out,const char *path)
out << "<map name=\"" << n->m_label << "_map\">" << endl;
convertMapFile(out,mapName);
out << "</map>" << endl;
- if (Config::dotCleanUp) thisDir.remove(dotName);
+ if (Config::instance()->getBool("DOT_CLEANUP")) thisDir.remove(dotName);
thisDir.remove(mapName);
}
out << "</table>" << endl;
@@ -819,7 +819,7 @@ void DotClassGraph::addClass(ClassDef *cd,DotNode *n,int prot,
else // new class
{
QCString displayName=className;
- if (Config::hideScopeNames) displayName=stripScope(displayName);
+ if (Config::instance()->getBool("HIDE_SCOPE_NAMES")) displayName=stripScope(displayName);
QCString tmp_url;
if (cd->isLinkable()) tmp_url=cd->getReference()+"$"+cd->getOutputFileBase();
bn = new DotNode(m_curNodeNumber++,
@@ -996,7 +996,7 @@ static void findMaximalDotGraph(DotNode *root,
int height=0;
// binary search for the maximal inheritance depth that fits in a reasonable
- // sized image (dimensions: Config::maxDotGraphWidth, Config::maxDotGraphHeight)
+ // sized image (dimensions: Config::instance()->getInt("MAX_DOT_GRAPH_WIDTH"), Config::instance()->getInt("MAX_DOT_GRAPH_HEIGHT"))
do
{
writeDotGraph(root,format,baseName,lrRank,renderParents,
@@ -1005,7 +1005,7 @@ static void findMaximalDotGraph(DotNode *root,
QCString dotArgs(4096);
// create annotated dot file
dotArgs.sprintf("-Tdot \"%s.dot\" -o \"%s_tmp.dot\"",baseName.data(),baseName.data());
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Problems running dot. Check your installation!\n");
return;
@@ -1016,9 +1016,9 @@ static void findMaximalDotGraph(DotNode *root,
width = width *96/72; // 96 pixels/inch, 72 points/inch
height = height*96/72; // 96 pixels/inch, 72 points/inch
//printf("Found bounding box (%d,%d) max (%d,%d)\n",width,height,
- // Config::maxDotGraphWidth,Config::maxDotGraphHeight);
+ // Config::instance()->getInt("MAX_DOT_GRAPH_WIDTH"),Config::instance()->getInt("MAX_DOT_GRAPH_HEIGHT"));
- lastFit=(width<Config::maxDotGraphWidth && height<Config::maxDotGraphHeight);
+ lastFit=(width<Config::instance()->getInt("MAX_DOT_GRAPH_WIDTH") && height<Config::instance()->getInt("MAX_DOT_GRAPH_HEIGHT"));
if (lastFit) // image is small enough
{
minDistance=curDistance;
@@ -1042,7 +1042,7 @@ static void findMaximalDotGraph(DotNode *root,
writeDotGraph(root,
format,
baseName,
- lrRank || (curDistance==1 && width>Config::maxDotGraphWidth),
+ lrRank || (curDistance==1 && width>Config::instance()->getInt("MAX_DOT_GRAPH_WIDTH")),
renderParents,
minDistance,
backArrows
@@ -1111,7 +1111,7 @@ void DotClassGraph::writeGraph(QTextStream &out,
QCString dotArgs(4096);
dotArgs.sprintf("-Tgif \"%s.dot\" -o \"%s.gif\"",
baseName.data(),baseName.data());
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Error: Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir);
@@ -1121,7 +1121,7 @@ void DotClassGraph::writeGraph(QTextStream &out,
{
// run dot again to create an image map
dotArgs.sprintf("-Timap \"%s.dot\" -o \"%s.map\"",baseName.data(),baseName.data());
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Error: Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir);
@@ -1152,7 +1152,7 @@ void DotClassGraph::writeGraph(QTextStream &out,
{
QCString dotArgs(4096);
dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"",baseName.data(),baseName.data());
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Error: Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir);
@@ -1165,7 +1165,7 @@ void DotClassGraph::writeGraph(QTextStream &out,
QDir::setCurrent(oldDir);
return;
}
- if (Config::usePDFLatexFlag)
+ if (Config::instance()->getBool("USE_PDFLATEX"))
{
QCString epstopdfArgs(4096);
epstopdfArgs.sprintf("\"%s.eps\" --outfile=\"%s.pdf\"",
@@ -1187,7 +1187,7 @@ void DotClassGraph::writeGraph(QTextStream &out,
"\\end{center}\n"
"\\end{figure}\n";
}
- if (Config::dotCleanUp) thisDir.remove(baseName+".dot");
+ if (Config::instance()->getBool("DOT_CLEANUP")) thisDir.remove(baseName+".dot");
QDir::setCurrent(oldDir);
}
@@ -1313,7 +1313,7 @@ void DotInclDepGraph::writeGraph(QTextStream &out,
QCString dotArgs(4096);
dotArgs.sprintf("-Tgif \"%s.dot\" -o \"%s.gif\"",
baseName.data(),baseName.data());
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir);
@@ -1325,7 +1325,7 @@ void DotInclDepGraph::writeGraph(QTextStream &out,
// run dot again to create an image map
dotArgs.sprintf("-Timap \"%s.dot\" -o \"%s.map\"",
baseName.data(),baseName.data());
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir);
@@ -1349,7 +1349,7 @@ void DotInclDepGraph::writeGraph(QTextStream &out,
QCString dotArgs(4096);
dotArgs.sprintf("-Tps \"%s.dot\" -o \"%s.eps\"",
baseName.data(),baseName.data());
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir);
@@ -1362,7 +1362,7 @@ void DotInclDepGraph::writeGraph(QTextStream &out,
QDir::setCurrent(oldDir);
return;
}
- if (Config::usePDFLatexFlag)
+ if (Config::instance()->getBool("USE_PDFLATEX"))
{
QCString epstopdfArgs(4096);
epstopdfArgs.sprintf("\"%s.eps\" --outfile=\"%s.pdf\"",
@@ -1387,7 +1387,7 @@ void DotInclDepGraph::writeGraph(QTextStream &out,
"\\end{figure}\n";
}
- if (Config::dotCleanUp) thisDir.remove(baseName+".dot");
+ if (Config::instance()->getBool("DOT_CLEANUP")) thisDir.remove(baseName+".dot");
QDir::setCurrent(oldDir);
}
@@ -1440,7 +1440,7 @@ void generateGraphLegend(const char *path)
// run dot to generate the a .gif image from the graph
QCString dotArgs(4096);
dotArgs.sprintf("-Tgif graph_legend.dot -o graph_legend.gif");
- if (iSystem(Config::dotPath+"dot",dotArgs)!=0)
+ if (iSystem(Config::instance()->getString("DOT_PATH")+"dot",dotArgs)!=0)
{
err("Problems running dot. Check your installation!\n");
QDir::setCurrent(oldDir);
diff --git a/src/doxygen.cpp b/src/doxygen.cpp
index ea7f4ba..7d07aa1 100644
--- a/src/doxygen.cpp
+++ b/src/doxygen.cpp
@@ -231,7 +231,7 @@ static void addRelatedPage(const char *name,const QCString &ptitle,
}
QCString pageName;
- if (Config::caseSensitiveNames)
+ if (Config::instance()->getBool("CASE_SENSE_NAMES"))
pageName=pi->name.copy();
else
pageName=pi->name.lower();
@@ -286,13 +286,13 @@ static void addRefItem(int todoId,int testId,int bugId,const char *prefix,
const char *name,const char *title,const char *args=0)
{
- //printf("addRefItem(%s) todoId=%d testId\n",name,todoId,testId);
+ //printf("addRefItem(%s) todoId=%d testId=%d bugId=%d\n",name,todoId,testId,bugId);
////////////////////////////////////////////////////////////
// add item to the todo list
////////////////////////////////////////////////////////////
- if (todoId>0 && Config::generateTodoList)
+ if (todoId>0 && Config::instance()->getBool("GENERATE_TODOLIST"))
{
RefItem *item = todoList.getRefItem(todoId);
ASSERT(item!=0);
@@ -322,7 +322,7 @@ static void addRefItem(int todoId,int testId,int bugId,const char *prefix,
// add item to the test list
////////////////////////////////////////////////////////////
- if (testId>0 && Config::generateTestList)
+ if (testId>0 && Config::instance()->getBool("GENERATE_TESTLIST"))
{
RefItem *item = testList.getRefItem(testId);
ASSERT(item!=0);
@@ -351,7 +351,7 @@ static void addRefItem(int todoId,int testId,int bugId,const char *prefix,
// add item to the bug list
////////////////////////////////////////////////////////////
- if (bugId>0 && Config::generateBugList)
+ if (bugId>0 && Config::instance()->getBool("GENERATE_BUGLIST"))
{
RefItem *item = bugList.getRefItem(bugId);
ASSERT(item!=0);
@@ -371,6 +371,7 @@ static void addRefItem(int todoId,int testId,int bugId,const char *prefix,
doc += "</dt>\n<dd>";
doc += item->text;
doc += "</dd></dl>\n";
+ //printf("Bug page: %s\n",doc.data());
addRelatedPage("bug",theTranslator->trBugList(),doc,0,"generated",1,0,0,0);
item->written=TRUE;
@@ -442,7 +443,7 @@ static void organizeSubGroups(Entry *root)
static void buildFileList(Entry *root)
{
if (((root->section==Entry::FILEDOC_SEC) ||
- ((root->section & Entry::FILE_MASK) && Config::extractAllFlag)) &&
+ ((root->section & Entry::FILE_MASK) && Config::instance()->getBool("EXTRACT_ALL"))) &&
!root->name.isEmpty() && !root->tagInfo // skip any file coming from tag files
)
{
@@ -517,7 +518,7 @@ static void addIncludeFile(ClassDef *cd,FileDef *ifd,Entry *root)
if (
(!root->doc.stripWhiteSpace().isEmpty() ||
!root->brief.stripWhiteSpace().isEmpty() ||
- Config::extractAllFlag
+ Config::instance()->getBool("EXTRACT_ALL")
) && root->protection!=Private
)
{
@@ -653,7 +654,7 @@ static void buildClassList(Entry *root)
cd->setTemplateArguments(root->tArgList);
}
if (!root->doc.isEmpty() || !root->brief.isEmpty() ||
- (root->bodyLine!=-1 && Config::sourceBrowseFlag)
+ (root->bodyLine!=-1 && Config::instance()->getBool("SOURCE_BROWSER"))
)
// block contains something that ends up in the docs
{
@@ -1139,7 +1140,7 @@ static MemberDef *addVariableToClass(
QCString def;
if (!root->type.isEmpty())
{
- if (mtype==MemberDef::Friend || Config::hideScopeNames)
+ if (mtype==MemberDef::Friend || Config::instance()->getBool("HIDE_SCOPE_NAMES"))
{
def=root->type+" "+name+root->args;
}
@@ -1150,7 +1151,7 @@ static MemberDef *addVariableToClass(
}
else
{
- if (Config::hideScopeNames)
+ if (Config::instance()->getBool("HIDE_SCOPE_NAMES"))
{
def=name+root->args;
}
@@ -1272,7 +1273,7 @@ static MemberDef *addVariableToFile(
QCString def;
// determine the definition of the global variable
if (nd && !nd->name().isEmpty() && nd->name().at(0)!='@' &&
- !Config::hideScopeNames
+ !Config::instance()->getBool("HIDE_SCOPE_NAMES")
)
// variable is inside a namespace, so put the scope before the name
{
@@ -1690,7 +1691,7 @@ static void buildMemberList(Entry *root)
name=name.left(i);
}
- //if (Config::includeSourceFlag && !root->body.isEmpty())
+ //if (Config::instance()->get("") && !root->body.isEmpty())
//{
// printf("Function: %s\n-----------------\n%s\n------------------\n",
// rname.data(),root->body.data());
@@ -1721,7 +1722,7 @@ static void buildMemberList(Entry *root)
//md->setScopeTemplateArguments(root->tArgList);
md->addSectionsToDefinition(root->anchors);
QCString def;
- if (!root->relates.isEmpty() || isFriend || Config::hideScopeNames)
+ if (!root->relates.isEmpty() || isFriend || Config::instance()->getBool("HIDE_SCOPE_NAMES"))
{
if (!root->type.isEmpty())
{
@@ -1970,19 +1971,18 @@ static void buildMemberList(Entry *root)
}
}
+ md->setRefItems(root->todoId,root->testId,root->bugId);
if (nd && !nd->name().isEmpty() && nd->name().at(0)!='@')
{
// add member to namespace
nd->insertMember(md);
md->setNamespace(nd);
- md->setRefItems(root->todoId,root->testId,root->bugId);
}
else if (fd)
{
// add member to the file
fd->insertMember(md);
md->setFileDef(fd);
- md->setRefItems(root->todoId,root->testId,root->bugId);
}
// add member to the list of file members
@@ -2122,7 +2122,7 @@ static void transferFunctionDocumentation()
FileDef *fdec = mdec->getFileDef();
// check if not in different but documented files
- if (Config::extractAllFlag ||
+ if (Config::instance()->getBool("EXTRACT_ALL") ||
fdef==fdec ||
(fdef!=0 && (!fdef->hasDocumentation() || !mdec->hasDocumentation()))
)
@@ -2609,7 +2609,7 @@ static void addTodoTestBugReferences()
if (d==0) d=md->getFileDef();
// TODO: i18n this
QCString memLabel="member";
- if (Config::optimizeForCFlag) memLabel="field";
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C")) memLabel="field";
if (d)
{
addRefItem(md->todoId(),md->testId(),md->bugId(),memLabel,d->getOutputFileBase()+":"+md->anchor(),scopeName+"::"+md->name(),md->argsString());
@@ -2630,7 +2630,7 @@ static void addTodoTestBugReferences()
if (d==0) d=md->getFileDef();
// TODO: i18n this
QCString memLabel="member";
- if (Config::optimizeForCFlag) memLabel="global";
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C")) memLabel="global";
if (d)
{
addRefItem(md->todoId(),md->testId(),md->bugId(),memLabel,d->getOutputFileBase()+":"+md->anchor(),md->name(),md->argsString());
@@ -2707,9 +2707,12 @@ static void addMemberDocs(Entry *root,
) && !root->doc.isEmpty()
)
{
+ //printf("overwrite!\n");
md->setDocumentation(root->doc);
}
+ //printf("Adding brief md->brief=`%s' root->brief=`%s'!\n",
+ // md->briefDescription().data(),root->brief.data());
// brief descriptions inside a compound override the documentation
// outside it
if ( /* !md->isStatic() && !root->stat && do not replace doc of static */
@@ -2719,6 +2722,7 @@ static void addMemberDocs(Entry *root,
) && !root->brief.isEmpty()
)
{
+ //printf("overwrite!\n");
md->setBriefDescription(root->brief);
}
@@ -2868,7 +2872,7 @@ static ClassDef *findClassDefinition(FileDef *fd,NamespaceDef *nd,
// with name `name' and argument list `args' (for overloading) and
// function declaration `decl' to the corresponding member definition.
-static bool findUnrelatedFunction(Entry *root,
+static bool findGlobalMember(Entry *root,
const QCString &namespaceName,
const char *name,
const char *tempArg,
@@ -2879,7 +2883,7 @@ static bool findUnrelatedFunction(Entry *root,
if (n.isEmpty()) return FALSE;
if (n.find("::")!=-1) return FALSE; // skip undefined class members
Debug::print(Debug::FindMembers,0,
- "2. findUnrelatedFunction(namespace=%s,name=%s,tempArg=%s,decl=%s)\n",
+ "2. findGlobalMember(namespace=%s,name=%s,tempArg=%s,decl=%s)\n",
namespaceName.data(),name,tempArg,decl);
MemberName *mn=Doxygen::functionNameDict[n+tempArg]; // look in function dictionary
if (mn==0)
@@ -2920,6 +2924,16 @@ static bool findUnrelatedFunction(Entry *root,
(md->argumentList()==0 && root->argList->count()==0) ||
md->isVariable() || md->isTypedef() || /* in case of function pointers */
matchArguments(md->argumentList(),root->argList,0,nsName);
+
+ // for static members we also check if the comment block was found in
+ // the same file. This is needed because static members with the same
+ // name can be in different files. Thus it would be wrong to just
+ // put the comment block at the first syntactically matching member.
+ if (matching && md->isStatic() && md->getDefFileName()!=root->fileName)
+ {
+ matching = FALSE;
+ }
+
if (matching) // add docs to the member
{
Debug::print(Debug::FindMembers,0,"5. Match found\n");
@@ -3040,7 +3054,7 @@ static void substituteTemplateArgNames(ArgumentList *src,
}
/*! This function tries to find a member (in a documented class/file/namespace)
- * that corresponds to the function declaration given in \a funcDecl.
+ * that corresponds to the function/variable declaration given in \a funcDecl.
*
* The \a related field may be used to specify a related class name.
* It is only used if the class name cannot be extracted from the function
@@ -3048,9 +3062,16 @@ static void substituteTemplateArgNames(ArgumentList *src,
*
* The boolean \a overloaded is used to specify whether or not a standard
* overload documentation line should be generated.
+ *
+ * The boolean \a isFunc is a hint that indicates that this is a function
+ * instead of a variable or typedef.
*/
-static void findMember(Entry *root,QCString funcDecl,QCString related,bool overloaded,
- bool isFunc)
+static void findMember(Entry *root,
+ QCString funcDecl,
+ QCString related,
+ bool overloaded,
+ bool isFunc
+ )
{
Debug::print(Debug::FindMembers,0,
"findMember(root=%p,funcDecl=`%s',related=`%s',overload=%d,"
@@ -3061,7 +3082,7 @@ static void findMember(Entry *root,QCString funcDecl,QCString related,bool overl
root->mtArgList,tempArgListToString(root->mtArgList).data(),
root->scopeSpec.data(),root->memberSpec.data(),root->memSpec
);
- //if (Config::includeSourceFlag && !root->body.isEmpty())
+ //if (Config::instance()->get("") && !root->body.isEmpty())
//{
// //printf("Function: %s\n-----------------\n%s\n------------------\n",
// //root->name.data(),root->body.data());
@@ -3297,7 +3318,7 @@ static void findMember(Entry *root,QCString funcDecl,QCString related,bool overl
//printf("scopeName=`%s' className=`%s'\n",scopeName.data(),className.data());
// rebuild the function declaration (needed to get the scope right).
- if (!scopeName.isEmpty() && !isRelated && !isFriend && !Config::hideScopeNames)
+ if (!scopeName.isEmpty() && !isRelated && !isFriend && !Config::instance()->getBool("HIDE_SCOPE_NAMES"))
{
if (!funcType.isEmpty())
{
@@ -3499,6 +3520,7 @@ static void findMember(Entry *root,QCString funcDecl,QCString related,bool overl
(md->argumentList()==0 && root->argList->count()==0) ||
matchArguments(argList, root->argList,className,namespaceName,TRUE,nl);
+
Debug::print(Debug::FindMembers,0,
"6. match results = %d\n",matching);
@@ -3619,7 +3641,7 @@ static void findMember(Entry *root,QCString funcDecl,QCString related,bool overl
}
else // unrelated function with the same name as a member
{
- if (!findUnrelatedFunction(root,namespaceName,funcName,funcTempList,funcArgs,funcDecl))
+ if (!findGlobalMember(root,namespaceName,funcName,funcTempList,funcArgs,funcDecl))
{
warn(root->fileName,root->startLine,
"Warning: Cannot determine class for function\n%s",
@@ -3759,7 +3781,7 @@ static void findMember(Entry *root,QCString funcDecl,QCString related,bool overl
else // unrelated not overloaded member found
{
if (className.isEmpty() &&
- !findUnrelatedFunction(root,namespaceName,funcName,funcTempList,funcArgs,funcDecl))
+ !findGlobalMember(root,namespaceName,funcName,funcTempList,funcArgs,funcDecl))
{
warn(root->fileName,root->startLine,
"Warning: class for member %s cannot "
@@ -3831,8 +3853,9 @@ static void findMemberDocumentation(Entry *root)
compoundKeywordDict.find(root->type)==0 // that is not a keyword
// (to skip forward declaration of class etc.)
)
- ) && !root->stat // not static
- /* && (
+ ) /*
+ && (!root->stat && !root->parent) // not static & global: TODO: fix this hack!
+ && (
!root->doc.isEmpty() || // has detailed docs
!root->brief.isEmpty() || // has brief docs
(root->memSpec&Entry::Inline) || // is inline
@@ -3972,7 +3995,7 @@ static void findEnums(Entry *root)
md->setRefItems(root->todoId,root->testId,root->bugId);
if (nd && !nd->name().isEmpty() && nd->name().at(0)!='@')
{
- if (Config::hideScopeNames)
+ if (Config::instance()->getBool("HIDE_SCOPE_NAMES"))
{
md->setDefinition(name);
}
@@ -4000,7 +4023,7 @@ static void findEnums(Entry *root)
}
else if (cd)
{
- if (Config::hideScopeNames)
+ if (Config::instance()->getBool("HIDE_SCOPE_NAMES"))
{
md->setDefinition(name);
}
@@ -4465,14 +4488,19 @@ static void addSourceReferences()
static void generateClassDocs()
{
// write the installdox script if necessary
- if (Config::generateHtml &&
- (Config::tagFileList.count()>0 || Config::searchEngineFlag))
+ if (Config::instance()->getBool("GENERATE_HTML") &&
+ (Config::instance()->getList("TAGFILES").count()>0 ||
+ Config::instance()->getBool("SEARCHENGINE")
+ )
+ )
+ {
writeInstallScript();
+ }
msg("Generating annotated compound index...\n");
writeAnnotatedIndex(*outputList);
- if (Config::alphaIndexFlag)
+ if (Config::instance()->getBool("ALPHABETICAL_INDEX"))
{
msg("Generating alphabetical compound index...\n");
writeAlphabeticalIndex(*outputList);
@@ -4897,7 +4925,7 @@ static void generatePageDocs()
msg("Generating docs for page %s...\n",pi->name.data());
outputList->disable(OutputGenerator::Man);
QCString pageName;
- if (Config::caseSensitiveNames)
+ if (Config::instance()->getBool("CASE_SENSE_NAMES"))
pageName=pi->name.copy();
else
pageName=pi->name.lower();
@@ -4917,7 +4945,7 @@ static void generatePageDocs()
endFile(*outputList);
outputList->enable(OutputGenerator::Man);
- if (!Config::genTagFile.isEmpty() && pi->name!="todo" && pi->name!="test")
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty() && pi->name!="todo" && pi->name!="test")
{
Doxygen::tagFile << " <compound kind=\"page\">" << endl;
Doxygen::tagFile << " <name>" << pi->name << "</name>" << endl;
@@ -5079,28 +5107,29 @@ static QCString fixSlashes(QCString &s)
static void generateSearchIndex()
{
- if (Config::searchEngineFlag && Config::generateHtml)
+ if (Config::instance()->getBool("SEARCHENGINE") && Config::instance()->getBool("GENERATE_HTML"))
{
// create search index
QCString fileName;
- writeSearchButton(Config::htmlOutputDir);
+ writeSearchButton(Config::instance()->getString("HTML_OUTPUT"));
#if !defined(_WIN32)
// create cgi script
- fileName = Config::htmlOutputDir+"/"+Config::cgiName;
+ fileName = Config::instance()->getString("HTML_OUTPUT")+"/"+Config::instance()->getString("CGI_NAME");
QFile f(fileName);
if (f.open(IO_WriteOnly))
{
QTextStream t(&f);
t << "#!/bin/sh" << endl
- << "DOXYSEARCH=" << Config::binAbsPath << "/doxysearch" << endl
- << "DOXYPATH=" << Config::docAbsPath << " ";
+ << "DOXYSEARCH=" << Config::instance()->getString("BIN_ABSPATH") << "/doxysearch" << endl
+ << "DOXYPATH=" << Config::instance()->getString("DOC_ABSPATH") << " ";
- char *s=Config::extDocPathList.first();
+ QStrList &extDocPaths=Config::instance()->getList("EXT_DOC_PATHS");
+ char *s= extDocPaths.first();
while (s)
{
t << s << " ";
- s=Config::extDocPathList.next();
+ s=extDocPaths.next();
}
t << endl
@@ -5124,11 +5153,11 @@ static void generateSearchIndex()
}
#else /* Windows platform */
// create cgi program
- fileName = Config::cgiName.copy();
+ fileName = Config::instance()->getString("CGI_NAME").copy();
if (fileName.right(4)==".cgi")
fileName=fileName.left(fileName.length()-4);
fileName+=".c";
- fileName.prepend(Config::htmlOutputDir+"/");
+ fileName.prepend(Config::instance()->getString("HTML_OUTPUT")+"/");
QFile f(fileName);
if (f.open(IO_WriteOnly))
{
@@ -5138,9 +5167,9 @@ static void generateSearchIndex()
t << "#include <process.h>" << endl;
t << endl;
t << "const char *DOXYSEARCH = \"" <<
- fixSlashes(Config::binAbsPath) << "\\\\doxysearch.exe\";" << endl;
+ fixSlashes(Config::instance()->getString("BIN_ABSPATH")) << "\\\\doxysearch.exe\";" << endl;
t << "const char *DOXYPATH = \"" <<
- fixSlashes(Config::docAbsPath) << "\";" << endl;
+ fixSlashes(Config::instance()->getString("DOC_ABSPATH")) << "\";" << endl;
t << endl;
t << "int main(void)" << endl;
t << "{" << endl;
@@ -5163,13 +5192,13 @@ static void generateSearchIndex()
#endif /* !defined(_WIN32) */
// create config file
- fileName = Config::htmlOutputDir+"/search.cfg";
+ fileName = Config::instance()->getString("HTML_OUTPUT")+"/search.cfg";
f.setName(fileName);
if (f.open(IO_WriteOnly))
{
QTextStream t(&f);
- t << Config::docURL << "/" << endl
- << Config::cgiURL << "/" << Config::cgiName << endl;
+ t << Config::instance()->getString("DOC_URL") << "/" << endl
+ << Config::instance()->getString("CGI_URL") << "/" << Config::instance()->getString("CGI_NAME") << endl;
f.close();
}
else
@@ -5225,7 +5254,7 @@ static void generateConfigFile(const char *configFile,bool shortList)
bool writeToStdout=(configFile[0]=='-' && configFile[1]=='\0');
if (fileOpened)
{
- writeTemplateConfig(&f,shortList);
+ Config::instance()->writeTemplate(&f,shortList);
if (!writeToStdout)
{
msg("\n\nConfiguration file `%s' created.\n\n",configFile);
@@ -5331,7 +5360,7 @@ static void copyAndFilterFile(const char *fileName,BufStr &dest)
QFileInfo fi(fileName);
if (!fi.exists()) return;
- if (Config::inputFilter.isEmpty())
+ if (Config::instance()->getString("INPUT_FILTER").isEmpty())
{
QFile f(fileName);
if (!f.open(IO_ReadOnly))
@@ -5350,11 +5379,11 @@ static void copyAndFilterFile(const char *fileName,BufStr &dest)
}
else
{
- QCString cmd=Config::inputFilter+" "+fileName;
+ QCString cmd=Config::instance()->getString("INPUT_FILTER")+" "+fileName;
FILE *f=popen(cmd,"r");
if (!f)
{
- err("Error: could not execute filter %s\n",Config::inputFilter.data());
+ err("Error: could not execute filter %s\n",Config::instance()->getString("INPUT_FILTER").data());
return;
}
const int bufSize=1024;
@@ -5382,13 +5411,14 @@ static void copyAndFilterFile(const char *fileName,BufStr &dest)
//----------------------------------------------------------------------------
static void copyStyleSheet()
{
- if (!Config::htmlStyleSheet.isEmpty())
+ QCString &htmlStyleSheet = Config::instance()->getString("HTML_STYLESHEET");
+ if (!htmlStyleSheet.isEmpty())
{
- QFile cssf(Config::htmlStyleSheet);
- QFileInfo cssfi(Config::htmlStyleSheet);
+ QFile cssf(htmlStyleSheet);
+ QFileInfo cssfi(htmlStyleSheet);
if (cssf.open(IO_ReadOnly))
{
- QCString destFileName = Config::htmlOutputDir+"/"+cssfi.fileName().data();
+ QCString destFileName = Config::instance()->getString("HTML_OUTPUT")+"/"+cssfi.fileName().data();
QFile df(destFileName);
if (df.open(IO_WriteOnly))
{
@@ -5405,8 +5435,8 @@ static void copyStyleSheet()
}
else
{
- err("Error: could not open user specified style sheet %s\n",Config::htmlStyleSheet.data());
- Config::htmlStyleSheet.resize(0); // revert to the default
+ err("Error: could not open user specified style sheet %s\n",Config::instance()->getString("HTML_STYLESHEET").data());
+ htmlStyleSheet.resize(0); // revert to the default
}
}
}
@@ -5433,7 +5463,7 @@ static void readFiles(BufStr &output)
// add end filename marker
output.addChar(0x06);
output.addChar('\n');
- if (Config::preprocessingFlag)
+ if (Config::instance()->getBool("ENABLE_PREPROCESSING"))
{
msg("Preprocessing %s...\n",s->data());
preprocessFile(fileName,output);
@@ -5517,7 +5547,8 @@ static int readDir(QFileInfo *fi,
if (resultList) resultList->append(rs);
if (resultDict) resultDict->insert(cfi->absFilePath(),rs);
}
- else if (Config::recursiveFlag && cfi->isDir() && cfi->fileName()!="." &&
+ else if (Config::instance()->getBool("RECURSIVE") &&
+ cfi->isDir() && cfi->fileName()!="." &&
cfi->fileName()!="..")
{
cfi->setFile(cfi->absFilePath());
@@ -5633,9 +5664,10 @@ static int readFileOrDirectory(const char *s,
static void readFormulaRepository()
{
- QFile f(Config::htmlOutputDir+"/formula.repository");
+ QFile f(Config::instance()->getString("HTML_OUTPUT")+"/formula.repository");
if (f.open(IO_ReadOnly)) // open repository
{
+ msg("Reading formula repository...\n");
QTextStream t(&f);
QCString line;
while (!t.eof())
@@ -5707,6 +5739,7 @@ void initDoxygen()
{
#if QT_VERSION >= 200
setlocale(LC_ALL,"");
+ setlocale(LC_NUMERIC,"C");
#endif
initPreprocessor();
@@ -5798,14 +5831,14 @@ void readConfiguration(int argc, char **argv)
{
QCString configFile=fileToString(argv[optind+4]);
if (configFile.isEmpty()) exit(1);
- parseConfig(fileToString(argv[optind+4]),argv[optind+4]);
- configStrToVal();
- substituteEnvironmentVars();
- checkConfig();
+ Config::instance()->parse(fileToString(argv[optind+4]),argv[optind+4]);
+ Config::instance()->convertStrToVal();
+ Config::instance()->substituteEnvironmentVars();
+ Config::instance()->check();
}
else
{
- Config::init();
+ Config::instance()->init();
setTranslator("English");
}
if (optind+3>=argc)
@@ -5836,14 +5869,14 @@ void readConfiguration(int argc, char **argv)
{
QCString configFile=fileToString(argv[optind+3]);
if (configFile.isEmpty()) exit(1);
- parseConfig(fileToString(argv[optind+3]),argv[optind+3]);
- configStrToVal();
- substituteEnvironmentVars();
- checkConfig();
+ Config::instance()->parse(fileToString(argv[optind+3]),argv[optind+3]);
+ Config::instance()->convertStrToVal();
+ Config::instance()->substituteEnvironmentVars();
+ Config::instance()->check();
}
else // use default config
{
- Config::init();
+ Config::instance()->init();
setTranslator("English");
}
if (optind+2>=argc)
@@ -5936,8 +5969,8 @@ void readConfiguration(int argc, char **argv)
}
}
- parseConfig(config,configName);
- configStrToVal();
+ Config::instance()->parse(config,configName);
+ Config::instance()->convertStrToVal();
if (updateConfig)
{
@@ -5945,33 +5978,34 @@ void readConfiguration(int argc, char **argv)
exit(1);
}
- substituteEnvironmentVars();
- checkConfig();
+ Config::instance()->substituteEnvironmentVars();
+ Config::instance()->check();
}
void parseInput()
{
- Doxygen::inputNameDict = new FileNameDict(1009);
+ Doxygen::inputNameDict = new FileNameDict(1009);
Doxygen::includeNameDict = new FileNameDict(1009);
Doxygen::exampleNameDict = new FileNameDict(1009);
- Doxygen::imageNameDict = new FileNameDict(257);
+ Doxygen::imageNameDict = new FileNameDict(257);
- if (!Config::docURL.isEmpty())
+ if (!Config::instance()->getString("DOC_URL").isEmpty())
{
- Doxygen::tagDestinationDict.insert("_doc",new QCString(Config::docURL));
+ Doxygen::tagDestinationDict.insert("_doc",new QCString(Config::instance()->getString("DOC_URL")));
}
- if (!Config::cgiURL.isEmpty())
+ if (!Config::instance()->getString("CGI_URL").isEmpty())
{
- Doxygen::tagDestinationDict.insert("_cgi",new QCString(Config::cgiURL+"/"+Config::cgiName));
+ Doxygen::tagDestinationDict.insert("_cgi",new QCString(Config::instance()->getString("CGI_URL")+"/"+Config::instance()->getString("CGI_NAME")));
}
/**************************************************************************
* Initialize some global constants
**************************************************************************/
- spaces.resize(Config::tabSize+1);
- int sp;for (sp=0;sp<Config::tabSize;sp++) spaces.at(sp)=' ';
- spaces.at(Config::tabSize)='\0';
+ int &tabSize = Config::instance()->getInt("TAB_SIZE");
+ spaces.resize(tabSize+1);
+ int sp;for (sp=0;sp<tabSize;sp++) spaces.at(sp)=' ';
+ spaces.at(tabSize)='\0';
compoundKeywordDict.insert("class",(void *)8);
compoundKeywordDict.insert("struct",(void *)8);
@@ -5985,46 +6019,55 @@ void parseInput()
// gather names of all files in the include path
msg("Searching for include files...\n");
- char *s=Config::includePath.first();
+ QStrList &includePathList = Config::instance()->getList("INCLUDE_PATH");
+ char *s=includePathList.first();
while (s)
{
- QStrList *pl = &Config::includeFilePatternList;
- if (pl->count()==0) pl = &Config::filePatternList;
- readFileOrDirectory(s,0,Doxygen::includeNameDict,0,pl,
- &Config::excludePatternList,0,0);
- s=Config::includePath.next();
+ QStrList &pl = Config::instance()->getList("INCLUDE_FILE_PATTERNS");
+ if (pl.count()==0)
+ {
+ pl = Config::instance()->getList("FILE_PATTERNS");
+ }
+ readFileOrDirectory(s,0,Doxygen::includeNameDict,0,&pl,
+ &Config::instance()->getList("EXCLUDE_PATTERNS"),0,0);
+ s=includePathList.next();
}
msg("Searching for example files...\n");
- s=Config::examplePath.first();
+ QStrList &examplePathList = Config::instance()->getList("EXAMPLE_PATH");
+ s=examplePathList.first();
while (s)
{
- readFileOrDirectory(s,0,Doxygen::exampleNameDict,0,&Config::examplePatternList,
+ readFileOrDirectory(s,0,Doxygen::exampleNameDict,0,
+ &Config::instance()->getList("EXAMPLE_PATTERNS"),
0,0,0);
- s=Config::examplePath.next();
+ s=examplePathList.next();
}
msg("Searching for images...\n");
- s=Config::imagePath.first();
+ QStrList &imagePathList=Config::instance()->getList("IMAGE_PATH");
+ s=imagePathList.first();
while (s)
{
readFileOrDirectory(s,0,Doxygen::imageNameDict,0,0,
0,0,0);
- s=Config::imagePath.next();
+ s=imagePathList.next();
}
msg("Searching for files to exclude\n");
- s=Config::excludeSources.first();
+ QStrList &excludeList = Config::instance()->getList("EXCLUDE");
+ s=excludeList.first();
while (s)
{
- readFileOrDirectory(s,0,0,0,&Config::filePatternList,
+ readFileOrDirectory(s,0,0,0,&Config::instance()->getList("FILE_PATTERNS"),
0,0,&excludeNameDict,FALSE);
- s=Config::excludeSources.next();
+ s=excludeList.next();
}
msg("Reading input files...\n");
int inputSize=0;
- s=Config::inputSources.first();
+ QStrList &inputList=Config::instance()->getList("INPUT");
+ s=inputList.first();
while (s)
{
QCString path=s;
@@ -6034,26 +6077,28 @@ void parseInput()
inputSize+=readFileOrDirectory(path,&Doxygen::inputNameList,
Doxygen::inputNameDict,&excludeNameDict,
- &Config::filePatternList,
- &Config::excludePatternList,
+ &Config::instance()->getList("FILE_PATTERNS"),
+ &Config::instance()->getList("EXCLUDE_PATTERNS"),
&inputFiles,0);
- s=Config::inputSources.next();
+ s=inputList.next();
}
// add predefined macro name to a dictionary
- s=Config::expandAsDefinedList.first();
+ QStrList &expandAsDefinedList =Config::instance()->getList("EXPAND_AS_DEFINED");
+ s=expandAsDefinedList.first();
while (s)
{
if (Doxygen::expandAsDefinedDict[s]==0)
{
Doxygen::expandAsDefinedDict.insert(s,(void *)666);
}
- s=Config::expandAsDefinedList.next();
+ s=expandAsDefinedList.next();
}
// add aliases to a dictionary
Doxygen::aliasDict.setAutoDelete(TRUE);
- s=Config::aliasList.first();
+ QStrList &aliasList = Config::instance()->getList("ALIASES");
+ s=aliasList.first();
while (s)
{
if (Doxygen::aliasDict[s]==0)
@@ -6102,7 +6147,7 @@ void parseInput()
}
}
}
- s=Config::aliasList.next();
+ s=aliasList.next();
}
BufStr input(inputSize+1); // Add one byte extra for \0 termination
@@ -6120,11 +6165,109 @@ void parseInput()
msg("Read %d bytes\n",input.curPos());
}
+ /**************************************************************************
+ * Check/create output directorties *
+ **************************************************************************/
+
+ QCString &outputDirectory = Config::instance()->getString("OUTPUT_DIRECTORY");
+ if (outputDirectory.isEmpty())
+ {
+ outputDirectory=QDir::currentDirPath();
+ }
+ else
+ {
+ QDir dir(outputDirectory);
+ if (!dir.exists())
+ {
+ dir.setPath(QDir::currentDirPath());
+ if (!dir.mkdir(outputDirectory))
+ {
+ err("Error: tag OUTPUT_DIRECTORY: Output directory `%s' does not "
+ "exist and cannot be created\n",outputDirectory.data());
+ exit(1);
+ }
+ else if (!Config::instance()->getBool("QUIET"))
+ {
+ err("Notice: Output directory `%s' does not exist. "
+ "I have created it for you.\n", outputDirectory.data());
+ }
+ dir.cd(outputDirectory);
+ }
+ outputDirectory=dir.absPath();
+ }
+
+ QCString &htmlOutput = Config::instance()->getString("HTML_OUTPUT");
+ bool &generateHtml = Config::instance()->getBool("GENERATE_HTML");
+ if (htmlOutput.isEmpty() && generateHtml)
+ {
+ htmlOutput=outputDirectory+"/html";
+ }
+ else if (htmlOutput && htmlOutput[0]!='/' && htmlOutput[1]!=':')
+ {
+ htmlOutput.prepend(outputDirectory+'/');
+ }
+ QDir htmlDir(htmlOutput);
+ if (generateHtml && !htmlDir.exists() && !htmlDir.mkdir(htmlOutput))
+ {
+ err("Could not create output directory %s\n",htmlOutput.data());
+ exit(1);
+ }
+
+ QCString &latexOutput = Config::instance()->getString("LATEX_OUTPUT");
+ bool &generateLatex = Config::instance()->getBool("GENERATE_LATEX");
+ if (latexOutput.isEmpty() && generateLatex)
+ {
+ latexOutput=outputDirectory+"/latex";
+ }
+ else if (latexOutput && latexOutput[0]!='/' && latexOutput[1]!=':')
+ {
+ latexOutput.prepend(outputDirectory+'/');
+ }
+ QDir latexDir(latexOutput);
+ if (generateLatex && !latexDir.exists() && !latexDir.mkdir(latexOutput))
+ {
+ err("Could not create output directory %s\n",latexOutput.data());
+ exit(1);
+ }
+
+ QCString &rtfOutput = Config::instance()->getString("RTF_OUTPUT");
+ bool &generateRtf = Config::instance()->getBool("GENERATE_RTF");
+ if (rtfOutput.isEmpty() && generateRtf)
+ {
+ rtfOutput=outputDirectory+"/rtf";
+ }
+ else if (rtfOutput && rtfOutput[0]!='/' && rtfOutput[1]!=':')
+ {
+ rtfOutput.prepend(outputDirectory+'/');
+ }
+ QDir rtfDir(rtfOutput);
+ if (generateRtf && !rtfDir.exists() && !rtfDir.mkdir(rtfOutput))
+ {
+ err("Could not create output directory %s\n",rtfOutput.data());
+ exit(1);
+ }
+
+ QCString &manOutput = Config::instance()->getString("MAN_OUTPUT");
+ bool &generateMan = Config::instance()->getBool("GENERATE_MAN");
+ if (manOutput.isEmpty() && generateMan)
+ {
+ manOutput=outputDirectory+"/man";
+ }
+ else if (manOutput && manOutput[0]!='/' && manOutput[1]!=':')
+ {
+ manOutput.prepend(outputDirectory+'/');
+ }
+ QDir manDir(manOutput);
+ if (generateMan && !manDir.exists() && !manDir.mkdir(manOutput))
+ {
+ err("Could not create output directory %s\n",manOutput.data());
+ exit(1);
+ }
+
// Notice: the order of the function calls below is very important!
- if (Config::generateHtml)
+ if (Config::instance()->getBool("GENERATE_HTML"))
{
- msg("Reading formula repository...\n");
readFormulaRepository();
}
@@ -6138,11 +6281,12 @@ void parseInput()
msg("Reading tag files\n");
- s=Config::tagFileList.first();
+ QStrList &tagFileList = Config::instance()->getList("TAGFILES");
+ s=tagFileList.first();
while (s)
{
readTagFile(root,s);
- s=Config::tagFileList.next();
+ s=tagFileList.next();
}
@@ -6226,7 +6370,7 @@ void parseInput()
msg("Adding classes to their packages...\n");
addClassesToPackages();
- if (Config::haveDotFlag && Config::collGraphFlag)
+ if (Config::instance()->getBool("HAVE_DOT") && Config::instance()->getBool("COLLABORATION_GRAPH"))
{
msg("Computing class implementation usage relations...\n");
computeClassImplUsageRelations();
@@ -6235,7 +6379,7 @@ void parseInput()
msg("Adding members to member groups.\n");
addMembersToMemberGroup();
- if (Config::distributeDocFlag)
+ if (Config::instance()->getBool("DISTRIBUTE_GROUP_DOC"))
{
msg("Distributing member group documentation.\n");
distributeMemberGroupDocumentation();
@@ -6244,7 +6388,7 @@ void parseInput()
msg("Building full member lists recursively...\n");
buildCompleteMemberLists();
- if (Config::inheritDocsFlag)
+ if (Config::instance()->getBool("INHERIT_DOCS"))
{
msg("Inheriting documentation...\n");
inheritDocumentation();
@@ -6261,122 +6405,29 @@ void parseInput()
void generateOutput()
{
/**************************************************************************
- * Check/create output directorties *
- **************************************************************************/
- if (Config::outputDir.isEmpty())
- {
- Config::outputDir=QDir::currentDirPath();
- }
- else
- {
- QDir dir(Config::outputDir);
- if (!dir.exists())
- {
- dir.setPath(QDir::currentDirPath());
- if (!dir.mkdir(Config::outputDir))
- {
- err("Error: tag OUTPUT_DIRECTORY: Output directory `%s' does not "
- "exist and cannot be created\n",Config::outputDir.data());
- exit(1);
- }
- else if (!Config::quietFlag)
- {
- err("Notice: Output directory `%s' does not exist. "
- "I have created it for you.\n", Config::outputDir.data());
- }
- dir.cd(Config::outputDir);
- }
- Config::outputDir=dir.absPath();
- }
-
- if (Config::htmlOutputDir.isEmpty() && Config::generateHtml)
- {
- Config::htmlOutputDir=Config::outputDir+"/html";
- }
- else if (Config::htmlOutputDir && Config::htmlOutputDir[0]!='/')
- {
- Config::htmlOutputDir.prepend(Config::outputDir+'/');
- }
- QDir htmlDir(Config::htmlOutputDir);
- if (Config::generateHtml && !htmlDir.exists() &&
- !htmlDir.mkdir(Config::htmlOutputDir))
- {
- err("Could not create output directory %s\n",Config::htmlOutputDir.data());
- exit(1);
- }
-
- if (Config::latexOutputDir.isEmpty() && Config::generateLatex)
- {
- Config::latexOutputDir=Config::outputDir+"/latex";
- }
- else if (Config::latexOutputDir && Config::latexOutputDir[0]!='/')
- {
- Config::latexOutputDir.prepend(Config::outputDir+'/');
- }
- QDir latexDir(Config::latexOutputDir);
- if (Config::generateLatex && !latexDir.exists() &&
- !latexDir.mkdir(Config::latexOutputDir))
- {
- err("Could not create output directory %s\n",Config::latexOutputDir.data());
- exit(1);
- }
-
- if (Config::rtfOutputDir.isEmpty() && Config::generateRTF)
- {
- Config::rtfOutputDir=Config::outputDir+"/rtf";
- }
- else if (Config::rtfOutputDir && Config::rtfOutputDir[0]!='/')
- {
- Config::rtfOutputDir.prepend(Config::outputDir+'/');
- }
- QDir rtfDir(Config::rtfOutputDir);
- if (Config::generateRTF && !rtfDir.exists() &&
- !rtfDir.mkdir(Config::rtfOutputDir))
- {
- err("Could not create output directory %s\n",Config::rtfOutputDir.data());
- exit(1);
- }
-
- if (Config::manOutputDir.isEmpty() && Config::generateMan)
- {
- Config::manOutputDir=Config::outputDir+"/man";
- }
- else if (Config::manOutputDir && Config::manOutputDir[0]!='/')
- {
- Config::manOutputDir.prepend(Config::outputDir+'/');
- }
- QDir manDir(Config::manOutputDir);
- if (Config::generateMan && !manDir.exists() &&
- !manDir.mkdir(Config::manOutputDir))
- {
- err("Could not create output directory %s\n",Config::manOutputDir.data());
- exit(1);
- }
-
- /**************************************************************************
* Initialize output generators *
**************************************************************************/
outputList = new OutputList(TRUE);
- if (Config::generateHtml)
+ if (Config::instance()->getBool("GENERATE_HTML"))
{
outputList->add(new HtmlGenerator);
HtmlGenerator::init();
- if (Config::htmlHelpFlag) HtmlHelp::getInstance()->initialize();
- if (Config::ftvHelpFlag) FTVHelp::getInstance()->initialize();
+ if (Config::instance()->getBool("GENERATE_HTMLHELP")) HtmlHelp::getInstance()->initialize();
+ if (Config::instance()->getBool("GENERATE_TREEVIEW")) FTVHelp::getInstance()->initialize();
copyStyleSheet();
}
- if (Config::generateLatex)
+ if (Config::instance()->getBool("GENERATE_LATEX"))
{
outputList->add(new LatexGenerator);
LatexGenerator::init();
}
- if (Config::generateMan)
+ if (Config::instance()->getBool("GENERATE_MAN"))
{
outputList->add(new ManGenerator);
ManGenerator::init();
}
- if (Config::generateRTF)
+ if (Config::instance()->getBool("GENERATE_RTF"))
{
outputList->add(new RTFGenerator);
RTFGenerator::init();
@@ -6387,13 +6438,14 @@ void generateOutput()
**************************************************************************/
QFile *tag=0;
- if (!Config::genTagFile.isEmpty())
+ QCString &generateTagFile = Config::instance()->getString("GENERATE_TAGFILE");
+ if (!generateTagFile.isEmpty())
{
- tag=new QFile(Config::genTagFile);
+ tag=new QFile(generateTagFile);
if (!tag->open(IO_WriteOnly))
{
err("Error: cannot open tag file %s for writing\n",
- Config::genTagFile.data()
+ generateTagFile.data()
);
exit(1);
}
@@ -6401,8 +6453,8 @@ void generateOutput()
Doxygen::tagFile << "<tagfile>" << endl;
}
- if (Config::generateHtml) writeDoxFont(Config::htmlOutputDir);
- if (Config::generateRTF) writeDoxFont(Config::rtfOutputDir);
+ if (Config::instance()->getBool("GENERATE_HTML")) writeDoxFont(Config::instance()->getString("HTML_OUTPUT"));
+ if (Config::instance()->getBool("GENERATE_RTF")) writeDoxFont(Config::instance()->getString("RTF_OUTPUT"));
//statistics();
@@ -6465,7 +6517,7 @@ void generateOutput()
msg("Generating page index...\n");
writePageIndex(*outputList);
- if (Config::generateLegend)
+ if (Config::instance()->getBool("GENERATE_LEGEND"))
{
msg("Generating graph info page...\n");
writeGraphInfo(*outputList);
@@ -6478,63 +6530,63 @@ void generateOutput()
outputList->writeStyleInfo(0); // write first part
outputList->disableAllBut(OutputGenerator::Latex);
parseText(*outputList,
- theTranslator->trGeneratedAt(dateToString(TRUE),Config::projectName)
+ theTranslator->trGeneratedAt(dateToString(TRUE),Config::instance()->getString("PROJECT_NAME"))
);
outputList->writeStyleInfo(1); // write second part
parseText(*outputList,theTranslator->trWrittenBy());
outputList->writeStyleInfo(2); // write third part
parseText(*outputList,
- theTranslator->trGeneratedAt(dateToString(TRUE),Config::projectName)
+ theTranslator->trGeneratedAt(dateToString(TRUE),Config::instance()->getString("PROJECT_NAME"))
);
outputList->writeStyleInfo(3); // write fourth part
parseText(*outputList,theTranslator->trWrittenBy());
outputList->writeStyleInfo(4); // write last part
outputList->enableAll();
- if (Config::generateRTF)
+ if (Config::instance()->getBool("GENERATE_RTF"))
{
msg("Combining RTF output...\n");
- if (!RTFGenerator::preProcessFileInplace(Config::rtfOutputDir,"refman.rtf"))
+ if (!RTFGenerator::preProcessFileInplace(Config::instance()->getString("RTF_OUTPUT"),"refman.rtf"))
{
err("An error occurred during post-processing the RTF files!\n");
}
}
- if (Config::haveDotFlag && Config::gfxHierarchyFlag)
+ if (Config::instance()->getBool("HAVE_DOT") && Config::instance()->getBool("GRAPHICAL_HIERARCHY"))
{
msg("Generating graphical class hierarchy...\n");
writeGraphicalClassHierarchy(*outputList);
}
- if (Doxygen::formulaList.count()>0 && Config::generateHtml)
+ if (Doxygen::formulaList.count()>0 && Config::instance()->getBool("GENERATE_HTML"))
{
msg("Generating bitmaps for formulas in HTML...\n");
- Doxygen::formulaList.generateBitmaps(Config::htmlOutputDir);
+ Doxygen::formulaList.generateBitmaps(Config::instance()->getString("HTML_OUTPUT"));
}
- if (Config::searchEngineFlag || Config::tagFileList.count()>0)
+ if (Config::instance()->getBool("SEARCHENGINE") || Config::instance()->getList("TAGFILES").count()>0)
{
msg("\nNow copy the file\n\n %s\n\nto the directory where the CGI binaries are "
- "located and don't forget to run\n\n",(Config::htmlOutputDir+"/"+Config::cgiName).data());
+ "located and don't forget to run\n\n",(Config::instance()->getString("HTML_OUTPUT")+"/"+Config::instance()->getString("CGI_NAME")).data());
msg(" %s/installdox\n\nto replace any dummy links.\n\n",
- Config::htmlOutputDir.data());
+ Config::instance()->getString("HTML_OUTPUT").data());
}
- if (Config::generateHtml && Config::htmlHelpFlag)
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP"))
{
HtmlHelp::getInstance()->finalize();
}
- if (Config::generateHtml && Config::ftvHelpFlag)
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW"))
{
FTVHelp::getInstance()->finalize();
}
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << "</tagfile>" << endl;
delete tag;
}
- if (Config::generateHtml && Config::dotCleanUp) removeDoxFont(Config::htmlOutputDir);
- if (Config::generateRTF && Config::dotCleanUp) removeDoxFont(Config::rtfOutputDir);
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("DOT_CLEANUP")) removeDoxFont(Config::instance()->getString("HTML_OUTPUT"));
+ if (Config::instance()->getBool("GENERATE_RTF") && Config::instance()->getBool("DOT_CLEANUP")) removeDoxFont(Config::instance()->getString("RTF_OUTPUT"));
}
diff --git a/src/doxygen.pro.in b/src/doxygen.pro.in
index 11a21a4..3183de8 100644
--- a/src/doxygen.pro.in
+++ b/src/doxygen.pro.in
@@ -18,18 +18,18 @@ TEMPLATE = app.t
CONFIG = console warn_on $extraopts
HEADERS = doxygen.h
SOURCES = main.cpp
-unix:LIBS += -L../lib -ldoxygen -lqtools
+unix:LIBS += -L../lib -ldoxygen -ldoxycfg -lqtools
win32:INCLUDEPATH += .
-win32-mingw:LIBS += -L../lib -ldoxygen -lqtools
-win32-msvc:LIBS += qtools.lib doxygen.lib shell32.lib
+win32-mingw:LIBS += -L../lib -ldoxygen -ldoxycfg -lqtools
+win32-msvc:LIBS += qtools.lib doxygen.lib doxycfg.lib shell32.lib
win32-msvc:TMAKE_LFLAGS += /LIBPATH:..\lib
-win32-borland:LIBS += qtools.lib doxygen.lib shell32.lib
+win32-borland:LIBS += qtools.lib doxygen.lib doxycfg.lib shell32.lib
win32-borland:TMAKE_LFLAGS += -L..\lib
win32:TMAKE_CXXFLAGS += -DQT_NODLL
INCLUDEPATH += ../qtools .
DESTDIR = ../bin
TARGET = doxygen
-unix:TARGETDEPS = ../lib/libdoxygen.a
-win32:TARGETDEPS = ..\lib\doxygen.lib
+unix:TARGETDEPS = ../lib/libdoxygen.a ../lib/libdoxycfg.a
+win32:TARGETDEPS = ..\lib\doxygen.lib ..\lib\doxycfg.lib
OBJECTS_DIR = ../objects
diff --git a/src/filedef.cpp b/src/filedef.cpp
index 59a9d61..6b5edf7 100644
--- a/src/filedef.cpp
+++ b/src/filedef.cpp
@@ -60,7 +60,7 @@ FileDef::FileDef(const char *p,const char *nm,const char *lref)
package = 0;
isSource = FALSE;
docname = nm;
- if (Config::fullPathNameFlag)
+ if (Config::instance()->getBool("FULL_PATH_NAMES"))
{
docname.prepend(stripFromPath(path.copy()));
}
@@ -109,7 +109,7 @@ void FileDef::writeDocumentation(OutputList &ol)
//funcList->countDecMembers();
//QCString fn = name();
- //if (Config::fullPathNameFlag)
+ //if (Config::instance()->getBool("FULL_PATH_NAMES"))
//{
// fn.prepend(stripFromPath(getPath().copy()));
//}
@@ -123,7 +123,7 @@ void FileDef::writeDocumentation(OutputList &ol)
endTitle(ol,getOutputFileBase(),docName());
//ol.newParagraph();
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <compound kind=\"file\">" << endl;
Doxygen::tagFile << " <name>" << convertToXML(name()) << "</name>" << endl;
@@ -153,7 +153,7 @@ void FileDef::writeDocumentation(OutputList &ol)
}
ol.writeSynopsis();
- if (Config::showIncFileFlag)
+ if (Config::instance()->getBool("SHOW_INCLUDE_FILES"))
{
ol.startTextBlock(TRUE);
QListIterator<IncludeInfo> ili(*includeList);
@@ -200,7 +200,7 @@ void FileDef::writeDocumentation(OutputList &ol)
ol.endTextBlock();
}
- if (Config::haveDotFlag && Config::includeGraphFlag)
+ if (Config::instance()->getBool("HAVE_DOT") && Config::instance()->getBool("INCLUDE_GRAPH"))
{
//printf("Graph for file %s\n",name().data());
DotInclDepGraph incDepGraph(this,FALSE);
@@ -213,10 +213,10 @@ void FileDef::writeDocumentation(OutputList &ol)
ol.endInclDepGraph(incDepGraph);
ol.enableAll();
}
- //incDepGraph.writeGraph(Config::htmlOutputDir,fd->getOutputFileBase());
+ //incDepGraph.writeGraph(Config::instance()->getString("HTML_OUTPUT"),fd->getOutputFileBase());
}
- if (Config::haveDotFlag && Config::includedByGraphFlag)
+ if (Config::instance()->getBool("HAVE_DOT") && Config::instance()->getBool("INCLUDED_BY_GRAPH"))
{
//printf("Graph for file %s\n",name().data());
DotInclDepGraph incDepGraph(this,TRUE);
@@ -229,7 +229,7 @@ void FileDef::writeDocumentation(OutputList &ol)
ol.endInclDepGraph(incDepGraph);
ol.enableAll();
}
- //incDepGraph.writeGraph(Config::htmlOutputDir,fd->getOutputFileBase());
+ //incDepGraph.writeGraph(Config::instance()->getString("HTML_OUTPUT"),fd->getOutputFileBase());
}
//printf("%s: generateSourceFile()=%d\n",name().data(),generateSourceFile());
@@ -280,7 +280,7 @@ void FileDef::writeDocumentation(OutputList &ol)
0,
nd->name()
);
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <namespace>" << convertToXML(nd->name()) << "</namespace>" << endl;
}
@@ -317,7 +317,7 @@ void FileDef::writeDocumentation(OutputList &ol)
//doc=doc.stripWhiteSpace();
//int bl=brief.length();
//int dl=doc.length();
- if ((!briefDescription().isEmpty() && Config::repeatBriefFlag) ||
+ if ((!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF")) ||
!documentation().isEmpty()
/* || startBodyLine!=-1 */
)
@@ -334,11 +334,11 @@ void FileDef::writeDocumentation(OutputList &ol)
ol.startGroupHeader();
parseText(ol,theTranslator->trDetailedDescription());
ol.endGroupHeader();
- if (!briefDescription().isEmpty() && Config::repeatBriefFlag)
+ if (!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF"))
{
ol+=briefOutput;
}
- if (!briefDescription().isEmpty() && Config::repeatBriefFlag &&
+ if (!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF") &&
!documentation().isEmpty())
{
ol.newParagraph();
@@ -350,7 +350,7 @@ void FileDef::writeDocumentation(OutputList &ol)
parseDoc(ol,filepath,1,0,0,documentation()+"\n");
}
//printf("Writing source ref for file %s\n",name().data());
- if (Config::sourceBrowseFlag)
+ if (Config::instance()->getBool("SOURCE_BROWSER"))
{
ol.newParagraph();
QCString refText = theTranslator->trDefinedInSourceFile();
@@ -431,10 +431,10 @@ void FileDef::writeDocumentation(OutputList &ol)
ol.startGroupHeader();
parseText(ol,theTranslator->trAuthor());
ol.endGroupHeader();
- parseText(ol,theTranslator->trGeneratedAutomatically(Config::projectName));
+ parseText(ol,theTranslator->trGeneratedAutomatically(Config::instance()->getString("PROJECT_NAME")));
ol.enableAll();
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
writeDocAnchorsToTagFile();
Doxygen::tagFile << " </compound>" << endl;
@@ -462,7 +462,7 @@ void FileDef::writeSource(OutputList &ol)
initParseCodeContext();
ol.startCodeFragment();
parseCode(ol,0,
- fileToString(absFilePath(),Config::filterForSourceFlag),
+ fileToString(absFilePath(),Config::instance()->getBool("FILTER_SOURCE_FILES")),
FALSE,0,this
);
ol.endCodeFragment();
@@ -520,25 +520,25 @@ void FileDef::insertMember(MemberDef *md)
switch(md->memberType())
{
case MemberDef::Variable:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
varMembers.inSort(md);
else
varMembers.append(md);
break;
case MemberDef::Function:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
funcMembers.inSort(md);
else
funcMembers.append(md);
break;
case MemberDef::Typedef:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
typedefMembers.inSort(md);
else
typedefMembers.append(md);
break;
case MemberDef::Enumeration:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
enumMembers.inSort(md);
else
enumMembers.append(md);
@@ -546,13 +546,13 @@ void FileDef::insertMember(MemberDef *md)
case MemberDef::EnumValue: // enum values are shown inside their enums
break;
case MemberDef::Prototype:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
protoMembers.inSort(md);
else
protoMembers.append(md);
break;
case MemberDef::Define:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
defineMembers.inSort(md);
else
defineMembers.append(md);
@@ -566,7 +566,7 @@ void FileDef::insertMember(MemberDef *md)
/*! Adds compound definition \a cd to the list of all compounds of this file */
void FileDef::insertClass(ClassDef *cd)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
classList->inSort(cd);
else
classList->append(cd);
@@ -577,7 +577,7 @@ void FileDef::insertNamespace(NamespaceDef *nd)
{
if (!nd->name().isEmpty() && namespaceDict->find(nd->name())==0)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
namespaceList->inSort(nd);
else
namespaceList->append(nd);
@@ -670,8 +670,8 @@ bool FileDef::generateSourceFile() const
{
QCString extension = name().right(4);
return !isReference() &&
- (Config::sourceBrowseFlag ||
- (Config::verbatimHeaderFlag && guessSection(name())==Entry::HEADER_SEC)
+ (Config::instance()->getBool("SOURCE_BROWSER") ||
+ (Config::instance()->getBool("VERBATIM_HEADERS") && guessSection(name())==Entry::HEADER_SEC)
) &&
extension!=".doc" && extension!=".txt" && extension!=".dox";
}
diff --git a/src/filedef.h b/src/filedef.h
index 1b6395d..30972ef 100644
--- a/src/filedef.h
+++ b/src/filedef.h
@@ -72,7 +72,7 @@ class FileDef : public Definition
/*! Returns the unique file name (this may include part of the path). */
QCString name() const
{
- if (Config::fullPathNameFlag)
+ if (Config::instance()->getBool("FULL_PATH_NAMES"))
return filename;
else
return Definition::name();
diff --git a/src/filename.cpp b/src/filename.cpp
index 7214ee8..ed662f0 100644
--- a/src/filename.cpp
+++ b/src/filename.cpp
@@ -126,7 +126,7 @@ int FileNameList::compareItems(GCI item1, GCI item2)
FileName *f2=(FileName *)item2;
//printf("FileNameList::compareItems `%s'<->`%s'\n",
// f1->fileName(),f2->fileName());
- return Config::fullPathNameFlag ?
+ return Config::instance()->getBool("FULL_PATH_NAMES") ?
stricmp(f1->fullName(),f2->fullName()) :
stricmp(f1->fileName(),f2->fileName());
}
diff --git a/src/filename.h b/src/filename.h
index 59928d7..935a4a5 100644
--- a/src/filename.h
+++ b/src/filename.h
@@ -62,7 +62,7 @@ class FileNameDict : public QDict<FileName>
{
public:
FileNameDict(uint size) :
- QDict<FileName>(size,Config::caseSensitiveNames) {}
+ QDict<FileName>(size,Config::instance()->getBool("CASE_SENSE_NAMES")) {}
~FileNameDict() {}
};
diff --git a/src/formula.cpp b/src/formula.cpp
index 065f036..2eeba75 100644
--- a/src/formula.cpp
+++ b/src/formula.cpp
@@ -70,14 +70,14 @@ void FormulaList::generateBitmaps(const char *path)
if (f.open(IO_WriteOnly))
{
QTextStream t(&f);
- if (Config::latexBatchModeFlag) t << "\\batchmode" << endl;
+ if (Config::instance()->getBool("LATEX_BATCHMODE")) t << "\\batchmode" << endl;
t << "\\documentclass{article}" << endl;
t << "\\usepackage{epsfig}" << endl; // for those who want to include images
- const char *s=Config::extraPackageList.first();
+ const char *s=Config::instance()->getList("EXTRA_PACKAGES").first();
while (s)
{
t << "\\usepackage{" << s << "}\n";
- s=Config::extraPackageList.next();
+ s=Config::instance()->getList("EXTRA_PACKAGES").next();
}
t << "\\pagestyle{empty}" << endl;
t << "\\begin{document}" << endl;
diff --git a/src/ftvhelp.cpp b/src/ftvhelp.cpp
index 650ff82..d671737 100644
--- a/src/ftvhelp.cpp
+++ b/src/ftvhelp.cpp
@@ -249,7 +249,7 @@ struct ImageInfo
static void generateFolderTreeViewData()
{
// Generate tree view script
- QCString fileName=Config::htmlOutputDir+"/treeview.js";
+ QCString fileName=Config::instance()->getString("HTML_OUTPUT")+"/treeview.js";
QFile f(fileName);
if (!f.open(IO_WriteOnly))
{
@@ -264,7 +264,7 @@ static void generateFolderTreeViewData()
}
// Generate alternative index.html as a frame
- fileName=Config::htmlOutputDir+"/index.html";
+ fileName=Config::instance()->getString("HTML_OUTPUT")+"/index.html";
f.setName(fileName);
if (!f.open(IO_WriteOnly))
{
@@ -278,16 +278,16 @@ static void generateFolderTreeViewData()
t << "<meta http-equiv=\"Content-Type\" content=\"text/html;charset="
<< theTranslator->idLanguageCharset() << "\">\n";
t << "<title>";
- if (Config::projectName.isEmpty())
+ if (Config::instance()->getString("PROJECT_NAME").isEmpty())
{
t << "Doxygen Documentation";
}
else
{
- t << Config::projectName;
+ t << Config::instance()->getString("PROJECT_NAME");
}
t << "</title></head>" << endl;
- t << "<frameset cols=\"" << Config::treeViewWidth << ",*\">" << endl;
+ t << "<frameset cols=\"" << Config::instance()->getInt("TREEVIEW_WIDTH") << ",*\">" << endl;
t << " <frame src=\"tree.html\" name=\"treefrm\">" << endl;
t << " <frame src=\"main.html\" name=\"basefrm\">" << endl;
t << "</frameset>" << endl;
@@ -296,7 +296,7 @@ static void generateFolderTreeViewData()
}
// Generate tree view frame
- fileName=Config::htmlOutputDir+"/tree.html";
+ fileName=Config::instance()->getString("HTML_OUTPUT")+"/tree.html";
f.setName(fileName);
if (!f.open(IO_WriteOnly))
{
@@ -308,13 +308,13 @@ static void generateFolderTreeViewData()
QTextStream t(&f);
t << "<html><head>" << endl;
t << "<link rel=\"stylesheet\" href=\"";
- if (Config::htmlStyleSheet.isEmpty())
+ if (Config::instance()->getString("HTML_STYLESHEET").isEmpty())
{
t << "doxygen.css";
}
else
{
- QFileInfo cssfi(Config::htmlStyleSheet);
+ QFileInfo cssfi(Config::instance()->getString("HTML_STYLESHEET"));
if (!cssfi.exists())
{
err("Error: user specified HTML style sheet file does not exist!\n");
@@ -338,7 +338,7 @@ static void generateFolderTreeViewData()
ImageInfo *p = image_info;
while (p->name)
{
- QCString fileName=Config::htmlOutputDir+"/"+p->name;
+ QCString fileName=Config::instance()->getString("HTML_OUTPUT")+"/"+p->name;
QFile f(fileName);
if (f.open(IO_WriteOnly))
f.writeBlock((char *)p->data,p->len);
@@ -380,7 +380,7 @@ FTVHelp *FTVHelp::getInstance()
void FTVHelp::initialize()
{
/* open the contents file */
- QCString fName = Config::htmlOutputDir + "/tree.js";
+ QCString fName = Config::instance()->getString("HTML_OUTPUT") + "/tree.js";
m_cf = new QFile(fName);
if (!m_cf->open(IO_WriteOnly))
{
@@ -390,13 +390,13 @@ void FTVHelp::initialize()
/* Write the header of the contents file */
m_cts.setDevice(m_cf);
m_cts << "foldersTree = gFld(\"<b>";
- if (Config::projectName.isEmpty())
+ if (Config::instance()->getString("PROJECT_NAME").isEmpty())
{
m_cts << "Root";
}
else
{
- m_cts << Config::projectName;
+ m_cts << Config::instance()->getString("PROJECT_NAME");
}
m_cts << "</b>\", \"\", \"\")\n";
}
diff --git a/src/groupdef.cpp b/src/groupdef.cpp
index ebdec58..495f515 100644
--- a/src/groupdef.cpp
+++ b/src/groupdef.cpp
@@ -86,7 +86,7 @@ void GroupDef::distributeMemberGroupDocumentation()
void GroupDef::addFile(const FileDef *def)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
fileList->inSort(def);
else
fileList->append(def);
@@ -94,7 +94,7 @@ void GroupDef::addFile(const FileDef *def)
void GroupDef::addClass(const ClassDef *def)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
classList->inSort(def);
else
classList->append(def);
@@ -102,7 +102,7 @@ void GroupDef::addClass(const ClassDef *def)
void GroupDef::addNamespace(const NamespaceDef *def)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
namespaceList->inSort(def);
else
namespaceList->append(def);
@@ -189,43 +189,43 @@ void GroupDef::insertMember(MemberDef *md)
switch(md->memberType())
{
case MemberDef::Variable:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
varMembers.inSort(md);
else
varMembers.append(md);
break;
case MemberDef::Function:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
funcMembers.inSort(md);
else
funcMembers.append(md);
break;
case MemberDef::Typedef:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
typedefMembers.inSort(md);
else
typedefMembers.append(md);
break;
case MemberDef::Enumeration:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
enumMembers.inSort(md);
else
enumMembers.append(md);
break;
case MemberDef::EnumValue:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
enumValMembers.inSort(md);
else
enumValMembers.append(md);
break;
case MemberDef::Prototype:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
protoMembers.inSort(md);
else
protoMembers.append(md);
break;
case MemberDef::Define:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
defineMembers.inSort(md);
else
defineMembers.append(md);
@@ -238,7 +238,7 @@ void GroupDef::insertMember(MemberDef *md)
void GroupDef::addGroup(const GroupDef *def)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
groupList->inSort(def);
else
groupList->append(def);
@@ -246,7 +246,7 @@ void GroupDef::addGroup(const GroupDef *def)
void GroupDef::addParentGroup(const GroupDef *def)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
parentGroupList->inSort(def);
else
parentGroupList->append(def);
@@ -302,7 +302,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
ol.popGeneratorState();
}
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <compound kind=\"group\">" << endl;
Doxygen::tagFile << " <name>" << convertToXML(name()) << "</name>" << endl;
@@ -324,12 +324,12 @@ void GroupDef::writeDocumentation(OutputList &ol)
ol.docify("file ");
ol.insertMemberAlign();
ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(),0,fd->name());
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <file>" << convertToXML(fd->name()) << "</file>" << endl;
}
ol.endMemberItem(FALSE);
- if (!fd->briefDescription().isEmpty() && Config::briefMemDescFlag)
+ if (!fd->briefDescription().isEmpty() && Config::instance()->getBool("BRIEF_MEMBER_DESC"))
{
ol.startMemberDescription();
parseDoc(ol,defFileName,defLine,0,0,fd->briefDescription());
@@ -353,12 +353,12 @@ void GroupDef::writeDocumentation(OutputList &ol)
ol.docify("namespace ");
ol.insertMemberAlign();
ol.writeObjectLink(nd->getReference(),nd->getOutputFileBase(),0,nd->name());
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <namespace>" << convertToXML(nd->name()) << "</namespace>" << endl;
}
ol.endMemberItem(FALSE);
- if (!nd->briefDescription().isEmpty() && Config::briefMemDescFlag)
+ if (!nd->briefDescription().isEmpty() && Config::instance()->getBool("BRIEF_MEMBER_DESC"))
{
ol.startMemberDescription();
parseDoc(ol,defFileName,defLine,0,0,nd->briefDescription());
@@ -381,12 +381,12 @@ void GroupDef::writeDocumentation(OutputList &ol)
ol.startMemberItem(0);
//ol.insertMemberAlign();
ol.writeObjectLink(gd->getReference(),gd->getOutputFileBase(),0,gd->groupTitle());
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <subgroup>" << convertToXML(gd->name()) << "</subgroup>" << endl;
}
ol.endMemberItem(FALSE);
- if (!gd->briefDescription().isEmpty() && Config::briefMemDescFlag)
+ if (!gd->briefDescription().isEmpty() && Config::instance()->getBool("BRIEF_MEMBER_DESC"))
{
ol.startMemberDescription();
parseDoc(ol,defFileName,defLine,0,0,gd->briefDescription());
@@ -431,7 +431,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
ol.endGroupHeader();
// repeat brief description
- if (!briefDescription().isEmpty() && Config::repeatBriefFlag)
+ if (!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF"))
{
ol+=briefOutput;
ol.newParagraph();
@@ -452,7 +452,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
{
QCString pageName = pi->getOutputFileBase();
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <page>" << convertToXML(pageName) << "</page>" << endl;
}
@@ -531,7 +531,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
varMembers.writeDocumentation(ol,name(),this);
}
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
writeDocAnchorsToTagFile();
Doxygen::tagFile << " </compound>" << endl;
diff --git a/src/htmlgen.cpp b/src/htmlgen.cpp
index 7955af7..7c0331b 100644
--- a/src/htmlgen.cpp
+++ b/src/htmlgen.cpp
@@ -63,7 +63,7 @@ static QCString g_footer;
HtmlGenerator::HtmlGenerator() : OutputGenerator()
{
- dir=Config::htmlOutputDir;
+ dir=Config::instance()->getString("HTML_OUTPUT");
col=0;
}
@@ -80,15 +80,15 @@ void HtmlGenerator::append(const OutputGenerator *g)
void HtmlGenerator::init()
{
- QDir d(Config::htmlOutputDir);
- if (!d.exists() && !d.mkdir(Config::htmlOutputDir))
+ QDir d(Config::instance()->getString("HTML_OUTPUT"));
+ if (!d.exists() && !d.mkdir(Config::instance()->getString("HTML_OUTPUT")))
{
- err("Could not create output directory %s\n",Config::htmlOutputDir.data());
+ err("Could not create output directory %s\n",Config::instance()->getString("HTML_OUTPUT").data());
exit(1);
}
- writeLogo(Config::htmlOutputDir);
- if (!Config::headerFile.isEmpty()) g_header=fileToString(Config::headerFile);
- if (!Config::footerFile.isEmpty()) g_footer=fileToString(Config::footerFile);
+ writeLogo(Config::instance()->getString("HTML_OUTPUT"));
+ if (!Config::instance()->getString("HTML_HEADER").isEmpty()) g_header=fileToString(Config::instance()->getString("HTML_HEADER"));
+ if (!Config::instance()->getString("HTML_FOOTER").isEmpty()) g_footer=fileToString(Config::instance()->getString("HTML_FOOTER"));
}
void HtmlGenerator::writeStyleSheetFile(QFile &file)
@@ -107,17 +107,17 @@ static void writeDefaultHeaderFile(QTextStream &t,const char *title,
"<title>" << title << "</title>\n";
t << "<link ";
if (external)
- t << "doxygen=\"_doc:" << Config::docURL
- << "\" href=\"" << Config::docURL << "/";
+ t << "doxygen=\"_doc:" << Config::instance()->getString("DOC_URL")
+ << "\" href=\"" << Config::instance()->getString("DOC_URL") << "/";
else
t << "href=\"";
- if (Config::htmlStyleSheet.isEmpty())
+ if (Config::instance()->getString("HTML_STYLESHEET").isEmpty())
{
t << "doxygen.css";
}
else
{
- QFileInfo cssfi(Config::htmlStyleSheet);
+ QFileInfo cssfi(Config::instance()->getString("HTML_STYLESHEET"));
if (!cssfi.exists())
{
err("Error: user specified HTML style sheet file does not exist!\n");
@@ -157,7 +157,7 @@ void HtmlGenerator::startFile(const char *name,const char *title,bool external)
lastTitle=title;
if (fileName.right(5)!=".html") fileName+=".html";
startPlainFile(fileName);
- if (Config::htmlHelpFlag)
+ if (Config::instance()->getBool("GENERATE_HTMLHELP"))
{
HtmlHelp::getInstance()->addIndexFile(fileName);
}
@@ -220,8 +220,8 @@ void HtmlGenerator::writeFooter(int part,bool external)
t << endl << "<img ";
if (external)
{
- t << "doxygen=\"_doc:" << Config::docURL
- << "\" src=\"" << Config::docURL << "/";
+ t << "doxygen=\"_doc:" << Config::instance()->getString("DOC_URL")
+ << "\" src=\"" << Config::instance()->getString("DOC_URL") << "/";
}
else
{
@@ -260,7 +260,7 @@ void HtmlGenerator::writeStyleInfo(int part)
{
if (part==0)
{
- if (Config::htmlStyleSheet.isEmpty()) // write default style sheet
+ if (Config::instance()->getString("HTML_STYLESHEET").isEmpty()) // write default style sheet
{
startPlainFile("doxygen.css");
@@ -273,15 +273,15 @@ void HtmlGenerator::writeStyleInfo(int part)
}
else // write user defined style sheet
{
- QFileInfo cssfi(Config::htmlStyleSheet);
+ QFileInfo cssfi(Config::instance()->getString("HTML_STYLESHEET"));
if (!cssfi.exists() || !cssfi.isFile() || !cssfi.isReadable())
{
- err("Error: style sheet %s does not exist or is not readable!", Config::htmlStyleSheet.data());
+ err("Error: style sheet %s does not exist or is not readable!", Config::instance()->getString("HTML_STYLESHEET").data());
}
else
{
startPlainFile(cssfi.fileName());
- t << fileToString(Config::htmlStyleSheet);
+ t << fileToString(Config::instance()->getString("HTML_STYLESHEET"));
endPlainFile();
}
}
@@ -347,7 +347,7 @@ void HtmlGenerator::writeIndexItem(const char *ref,const char *f,
{
t << "</b>";
}
- //if (Config::htmlHelpFlag && f)
+ //if (Config::instance()->getBool("GENERATE_HTMLHELP") && f)
//{
// htmlHelp->addItem(name,((QCString)f)+".html");
//}
@@ -361,7 +361,7 @@ void HtmlGenerator::writeStartAnnoItem(const char *,const char *f,
t << "<a class=\"el\" href=\"" << f << ".html\">";
docify(name);
t << "</a> ";
- //if (Config::htmlHelpFlag && f)
+ //if (Config::instance()->getBool("GENERATE_HTMLHELP") && f)
//{
// htmlHelp->addItem(name, ((QCString)f)+".html");
//}
@@ -438,7 +438,7 @@ void HtmlGenerator::endTextLink()
void HtmlGenerator::startHtmlLink(const char *url)
{
t << "<a ";
- if (Config::ftvHelpFlag) t << "target=\"top\" ";
+ if (Config::instance()->getBool("GENERATE_TREEVIEW")) t << "target=\"top\" ";
t << "href=\"";
if (url) t << url;
t << "\">";
@@ -555,7 +555,7 @@ void HtmlGenerator::codify(const char *str)
switch(c)
{
case '\t': spacesToNextTabStop =
- Config::tabSize - (col%Config::tabSize);
+ Config::instance()->getInt("TAB_SIZE") - (col%Config::instance()->getInt("TAB_SIZE"));
t << spaces.left(spacesToNextTabStop);
col+=spacesToNextTabStop;
break;
@@ -639,7 +639,7 @@ void HtmlGenerator::writeFormula(const char *n,const char *text)
void HtmlGenerator::startMemberList()
{
DBG_HTML(t << "<!-- startMemberList -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
}
else
@@ -651,7 +651,7 @@ void HtmlGenerator::startMemberList()
void HtmlGenerator::endMemberList()
{
DBG_HTML(t << "<!-- endMemberList -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
}
else
@@ -667,7 +667,7 @@ void HtmlGenerator::endMemberList()
void HtmlGenerator::startMemberItem(int annoType)
{
DBG_HTML(t << "<!-- startMemberItem() -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
t << "<tr>";
switch(annoType)
@@ -686,7 +686,7 @@ void HtmlGenerator::startMemberItem(int annoType)
void HtmlGenerator::endMemberItem(bool)
{
//DBG_HTML(t << "<!-- endMemberItem(" << (int)inGroup << "," << fileName << "," << headerName << " -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
t << "</td></tr>";
}
@@ -697,7 +697,7 @@ void HtmlGenerator::endMemberItem(bool)
void HtmlGenerator::insertMemberAlign()
{
DBG_HTML(t << "<!-- insertMemberAlign -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
t << "&nbsp;</td><td valign=bottom>";
}
@@ -706,7 +706,7 @@ void HtmlGenerator::insertMemberAlign()
void HtmlGenerator::startMemberDescription()
{
DBG_HTML(t << "<!-- startMemberDescription -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
//t << "<tr><td><img src=null.gif></td><td><img src=null.gif></td>"
// "<td></td><td><font size=-1><em>";
@@ -721,7 +721,7 @@ void HtmlGenerator::startMemberDescription()
void HtmlGenerator::endMemberDescription()
{
DBG_HTML(t << "<!-- endMemberDescription -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
t << "</em></font><br><br></td></tr>" << endl;
}
@@ -734,7 +734,7 @@ void HtmlGenerator::endMemberDescription()
void HtmlGenerator::startMemberSections()
{
DBG_HTML(t << "<!-- startMemberSections -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
t << "<table border=0 cellpadding=0 cellspacing=0>" << endl;
}
@@ -743,7 +743,7 @@ void HtmlGenerator::startMemberSections()
void HtmlGenerator::endMemberSections()
{
DBG_HTML(t << "<!-- endMemberSections -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
t << "</table>" << endl;
}
@@ -752,7 +752,7 @@ void HtmlGenerator::endMemberSections()
void HtmlGenerator::startMemberHeader()
{
DBG_HTML(t << "<!-- startMemberHeader -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
t << "<tr><td colspan=2><br><h2>";
}
@@ -765,7 +765,7 @@ void HtmlGenerator::startMemberHeader()
void HtmlGenerator::endMemberHeader()
{
DBG_HTML(t << "<!-- endMemberHeader -->" << endl)
- if (Config::htmlAlignMemberFlag)
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS"))
{
t << "</h2></td></tr>" << endl;
}
@@ -778,19 +778,19 @@ void HtmlGenerator::endMemberHeader()
void HtmlGenerator::startMemberSubtitle()
{
DBG_HTML(t << "<!-- startMemberSubtitle -->" << endl)
- if (Config::htmlAlignMemberFlag) t << "<tr><td colspan=2>";
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS")) t << "<tr><td colspan=2>";
}
void HtmlGenerator::endMemberSubtitle()
{
DBG_HTML(t << "<!-- endMemberSubtitle -->" << endl)
- if (Config::htmlAlignMemberFlag) t << "<br><br></td></tr>" << endl;
+ if (Config::instance()->getBool("HTML_ALIGN_MEMBERS")) t << "<br><br></td></tr>" << endl;
}
void HtmlGenerator::startIndexList()
{
t << "<ul>" << endl;
- //if (Config::htmlHelpFlag)
+ //if (Config::instance()->getBool("GENERATE_HTMLHELP"))
//{
// if (htmlHelp->depth()==0) htmlHelp->addItem(lastTitle,lastFile);
// htmlHelp->incDepth();
@@ -800,7 +800,7 @@ void HtmlGenerator::startIndexList()
void HtmlGenerator::endIndexList()
{
t << "</ul>" << endl;
- //if (Config::htmlHelpFlag)
+ //if (Config::instance()->getBool("GENERATE_HTMLHELP"))
//{
// htmlHelp->decDepth();
//}
@@ -936,7 +936,7 @@ void HtmlGenerator::startDotGraph()
void HtmlGenerator::endDotGraph(DotClassGraph &g)
{
- g.writeGraph(t,GIF,Config::htmlOutputDir);
+ g.writeGraph(t,GIF,Config::instance()->getString("HTML_OUTPUT"));
}
void HtmlGenerator::startInclDepGraph()
@@ -945,12 +945,12 @@ void HtmlGenerator::startInclDepGraph()
void HtmlGenerator::endInclDepGraph(DotInclDepGraph &g)
{
- g.writeGraph(t,GIF,Config::htmlOutputDir);
+ g.writeGraph(t,GIF,Config::instance()->getString("HTML_OUTPUT"));
}
void HtmlGenerator::writeGraphicalHierarchy(DotGfxHierarchyTable &g)
{
- g.writeGraph(t,Config::htmlOutputDir);
+ g.writeGraph(t,Config::instance()->getString("HTML_OUTPUT"));
}
void HtmlGenerator::startMemberGroupHeader(bool)
@@ -1009,3 +1009,12 @@ void HtmlGenerator::endIndent()
void HtmlGenerator::addIndexItem(const char *,const char *)
{
}
+
+void HtmlGenerator::writeNonBreakableSpace(int n)
+{
+ int i;
+ for (i=0;i<n;i++)
+ {
+ t << "&nbsp;";
+ }
+}
diff --git a/src/htmlgen.h b/src/htmlgen.h
index 14e427b..d3bbcc4 100644
--- a/src/htmlgen.h
+++ b/src/htmlgen.h
@@ -198,7 +198,7 @@ class HtmlGenerator : public OutputGenerator
void startQuickIndexItem(const char *,const char *);
void endQuickIndexItem();
void writeFormula(const char *,const char *);
- void writeNonBreakableSpace() { t << "&nbsp;&nbsp;&nbsp;"; }
+ void writeNonBreakableSpace(int);
void startImage(const char *,const char *,bool);
void endImage(bool);
diff --git a/src/htmlhelp.cpp b/src/htmlhelp.cpp
index 5d8936e..8b320f5 100644
--- a/src/htmlhelp.cpp
+++ b/src/htmlhelp.cpp
@@ -255,7 +255,7 @@ HtmlHelp *HtmlHelp::getInstance()
void HtmlHelp::initialize()
{
/* open the contents file */
- QCString fName = Config::htmlOutputDir + "/index.hhc";
+ QCString fName = Config::instance()->getString("HTML_OUTPUT") + "/index.hhc";
cf = new QFile(fName);
if (!cf->open(IO_WriteOnly))
{
@@ -272,7 +272,7 @@ void HtmlHelp::initialize()
"<UL>\n";
/* open the contents file */
- fName = Config::htmlOutputDir + "/index.hhk";
+ fName = Config::instance()->getString("HTML_OUTPUT") + "/index.hhk";
kf = new QFile(fName);
if (!kf->open(IO_WriteOnly))
{
@@ -292,13 +292,13 @@ void HtmlHelp::initialize()
void HtmlHelp::createProjectFile()
{
/* Write the project file */
- QCString fName = Config::htmlOutputDir + "/index.hhp";
+ QCString fName = Config::instance()->getString("HTML_OUTPUT") + "/index.hhp";
QFile f(fName);
if (f.open(IO_WriteOnly))
{
QTextStream t(&f);
QCString indexName="index.html";
- if (Config::ftvHelpFlag) indexName="main.html";
+ if (Config::instance()->getBool("GENERATE_TREEVIEW")) indexName="main.html";
t << "[OPTIONS]\n"
"Compatibility=1.1\n"
"Full-text search=Yes\n"
@@ -306,12 +306,12 @@ void HtmlHelp::createProjectFile()
"Default Window=main\n"
"Default topic=" << indexName << "\n"
"Index file=index.hhk\n";
- if (Config::htmlHelpTocFlag) t << "Binary TOC=YES\n";
- if (Config::htmlHelpChiFlag) t << "Create CHI file=YES\n";
- t << "Title=" << Config::projectName << endl << endl;
+ if (Config::instance()->getBool("BINARY_TOC")) t << "Binary TOC=YES\n";
+ if (Config::instance()->getBool("GENERATE_CHI")) t << "Create CHI file=YES\n";
+ t << "Title=" << Config::instance()->getString("PROJECT_NAME") << endl << endl;
t << "[WINDOWS]" << endl;
- t << "main=\"" << Config::projectName << "\",\"index.hhc\","
+ t << "main=\"" << Config::instance()->getString("PROJECT_NAME") << "\",\"index.hhc\","
"\"index.hhk\",\"" << indexName << "\",\"" <<
indexName << "\",,,,,0x23520,,0x3006,,,,,,,,0" << endl << endl;
@@ -389,7 +389,7 @@ void HtmlHelp::addContentsItem(bool isDir,
const char *anchor)
{
// If we're using a binary toc then folders cannot have links.
- if(Config::htmlHelpTocFlag && isDir)
+ if(Config::instance()->getBool("BINARY_TOC") && isDir)
{
ref = 0;
anchor = 0;
diff --git a/src/index.cpp b/src/index.cpp
index 83495b8..b45d693 100644
--- a/src/index.cpp
+++ b/src/index.cpp
@@ -155,7 +155,7 @@ void writeQuickLinks(OutputList &ol,bool compact ,bool ext=FALSE)
if (compact) ol.startCenter(); else ol.startItemList();
if (!compact) ol.writeListItem();
- if (Config::ftvHelpFlag)
+ if (Config::instance()->getBool("GENERATE_TREEVIEW"))
{
ol.startQuickIndexItem(extLink,"main.html");
}
@@ -196,7 +196,7 @@ void writeQuickLinks(OutputList &ol,bool compact ,bool ext=FALSE)
}
if (annotatedClasses>0)
{
- if (Config::alphaIndexFlag)
+ if (Config::instance()->getBool("ALPHABETICAL_INDEX"))
{
if (!compact) ol.writeListItem();
ol.startQuickIndexItem(extLink,"classes.html");
@@ -215,14 +215,14 @@ void writeQuickLinks(OutputList &ol,bool compact ,bool ext=FALSE)
parseText(ol,theTranslator->trFileList());
ol.endQuickIndexItem();
}
- //if (documentedIncludeFiles>0 && Config::verbatimHeaderFlag)
+ //if (documentedIncludeFiles>0 && Config::instance()->getBool("VERBATIM_HEADERS"))
//{
// if (!compact) ol.writeListItem();
// ol.startQuickIndexItem(extLink,"headers.html");
// parseText(ol,theTranslator->trHeaderFiles());
// ol.endQuickIndexItem();
//}
- //if (Config::sourceBrowseFlag)
+ //if (Config::instance()->getBool("SOURCE_BROWSER"))
//{
// if (!compact) ol.writeListItem();
// ol.startQuickIndexItem(extLink,"sources.html");
@@ -264,7 +264,7 @@ void writeQuickLinks(OutputList &ol,bool compact ,bool ext=FALSE)
parseText(ol,theTranslator->trExamples());
ol.endQuickIndexItem();
}
- if (Config::searchEngineFlag)
+ if (Config::instance()->getBool("SEARCHENGINE"))
{
if (!compact) ol.writeListItem();
ol.startQuickIndexItem("_cgi","");
@@ -303,7 +303,7 @@ void endTitle(OutputList &ol,const char *fileName,const char *name)
void startFile(OutputList &ol,const char *name,const char *title,bool external)
{
ol.startFile(name,title,external);
- if (!Config::noIndexFlag) writeQuickLinks(ol,TRUE,external);
+ if (!Config::instance()->getBool("DISABLE_INDEX")) writeQuickLinks(ol,TRUE,external);
}
void endFile(OutputList &ol,bool external)
@@ -311,15 +311,15 @@ void endFile(OutputList &ol,bool external)
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Html);
ol.writeFooter(0,external); // write the footer
- if (Config::footerFile.isEmpty())
+ if (Config::instance()->getString("HTML_FOOTER").isEmpty())
{
parseText(ol,theTranslator->trGeneratedAt(
dateToString(TRUE),
- Config::projectName
+ Config::instance()->getString("PROJECT_NAME")
));
}
ol.writeFooter(1,external); // write the link to the picture
- if (Config::footerFile.isEmpty())
+ if (Config::instance()->getString("HTML_FOOTER").isEmpty())
{
parseText(ol,theTranslator->trWrittenBy());
}
@@ -334,8 +334,8 @@ void writeClassTree(OutputList &ol,BaseClassList *bcl,bool hideSuper)
{
HtmlHelp *htmlHelp=0;
FTVHelp *ftvHelp=0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -415,8 +415,8 @@ void writeClassTree(BaseClassList *cl)
{
HtmlHelp *htmlHelp=0;
FTVHelp *ftvHelp=0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW");
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -471,8 +471,8 @@ void writeClassTree(ClassList *cl)
{
HtmlHelp *htmlHelp=0;
FTVHelp *ftvHelp=0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW");
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -521,8 +521,8 @@ void writeClassHierarchy(OutputList &ol)
HtmlHelp *htmlHelp=0;
FTVHelp *ftvHelp=0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -627,23 +627,23 @@ void writeHierarchicalIndex(OutputList &ol)
QCString title = theTranslator->trClassHierarchy();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
parseText(ol,title);
endTitle(ol,0,0);
ol.startTextBlock();
HtmlHelp *htmlHelp = 0;
FTVHelp *ftvHelp = 0;
- if (Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/)
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/)
{
htmlHelp = HtmlHelp::getInstance();
htmlHelp->addContentsItem(TRUE,htmlHelpTitle,"hierarchy");
}
- if (Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/)
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/)
{
ftvHelp = FTVHelp::getInstance();
ftvHelp->addContentsItem(TRUE,0,"hierarchy",0,ftvHelpTitle);
}
- if (Config::haveDotFlag && Config::gfxHierarchyFlag)
+ if (Config::instance()->getBool("HAVE_DOT") && Config::instance()->getBool("GRAPHICAL_HIERARCHY"))
{
ol.disable(OutputGenerator::Latex);
ol.disable(OutputGenerator::RTF);
@@ -674,18 +674,18 @@ void writeGraphicalClassHierarchy(OutputList &ol)
QCString title = theTranslator->trGraphicalHierarchy();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
parseText(ol,title);
endTitle(ol,0,0);
ol.startTextBlock();
HtmlHelp *htmlHelp = 0;
FTVHelp *ftvHelp = 0;
- if (Config::generateHtml && Config::htmlHelpFlag)
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP"))
{
htmlHelp = HtmlHelp::getInstance();
htmlHelp->addContentsItem(FALSE,htmlHelpTitle,"inherits");
}
- if (Config::generateHtml && Config::ftvHelpFlag)
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW"))
{
ftvHelp = FTVHelp::getInstance();
ftvHelp->addContentsItem(FALSE,0,"inherits",0,ftvHelpTitle);
@@ -750,14 +750,14 @@ void writeFileIndex(OutputList &ol)
QCString title = theTranslator->trFileList();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
parseText(ol,title);
endTitle(ol,0,0);
ol.startTextBlock();
HtmlHelp *htmlHelp = 0;
FTVHelp *ftvHelp = 0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -771,7 +771,7 @@ void writeFileIndex(OutputList &ol)
ftvHelp->incContentsDepth();
}
//ol.newParagraph();
- parseText(ol,theTranslator->trFileListDescription(Config::extractAllFlag));
+ parseText(ol,theTranslator->trFileListDescription(Config::instance()->getBool("EXTRACT_ALL")));
//ol.newParagraph();
ol.endTextBlock();
@@ -779,7 +779,7 @@ void writeFileIndex(OutputList &ol)
OutputNameList outputNameList;
outputNameList.setAutoDelete(TRUE);
- if (Config::fullPathNameFlag)
+ if (Config::instance()->getBool("FULL_PATH_NAMES"))
{
// re-sort input files in (dir,file) output order instead of (file,dir) input order
FileName *fn=Doxygen::inputNameList.first();
@@ -812,7 +812,7 @@ void writeFileIndex(OutputList &ol)
ol.startIndexList();
FileList *fl=0;
- if (Config::fullPathNameFlag)
+ if (Config::instance()->getBool("FULL_PATH_NAMES"))
{
fl = outputNameList.first();
}
@@ -834,7 +834,7 @@ void writeFileIndex(OutputList &ol)
!fd->isReference())
{
QCString path;
- if (Config::fullPathNameFlag)
+ if (Config::instance()->getBool("FULL_PATH_NAMES"))
{
path=stripFromPath(fd->getPath().copy());
}
@@ -920,7 +920,7 @@ void writeFileIndex(OutputList &ol)
}
fd=fl->next();
}
- if (Config::fullPathNameFlag)
+ if (Config::instance()->getBool("FULL_PATH_NAMES"))
{
fl=outputNameList.next();
}
@@ -968,14 +968,14 @@ void writeNamespaceIndex(OutputList &ol)
QCString title = theTranslator->trNamespaceList();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
parseText(ol,title);
endTitle(ol,0,0);
ol.startTextBlock();
HtmlHelp *htmlHelp = 0;
FTVHelp *ftvHelp = 0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -989,7 +989,7 @@ void writeNamespaceIndex(OutputList &ol)
ftvHelp->incContentsDepth();
}
//ol.newParagraph();
- parseText(ol,theTranslator->trNamespaceListDescription(Config::extractAllFlag));
+ parseText(ol,theTranslator->trNamespaceListDescription(Config::instance()->getBool("EXTRACT_ALL")));
//ol.newParagraph();
ol.endTextBlock();
@@ -1065,8 +1065,8 @@ int countAnnotatedClasses()
void writeAnnotatedClassList(OutputList &ol)
{
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
ol.startIndexList();
//ClassDef *cd=Doxygen::classList.first();
//while (cd)
@@ -1107,8 +1107,8 @@ void writeAnnotatedClassList(OutputList &ol)
void writePackageList(OutputList &ol)
{
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
ol.startIndexList();
PackageSDict::Iterator pdi(Doxygen::packageDict);
PackageDef *pd;
@@ -1168,7 +1168,7 @@ void writeAlphabeticalClassList(OutputList &ol)
}
// the number of columns in the table
- const int columns = Config::colsInAlphaIndex;
+ const int columns = Config::instance()->getInt("COLS_IN_ALPHA_INDEX");
int i,j;
int totalItems = headerItems + annotatedClasses; // number of items in the table
@@ -1249,7 +1249,7 @@ void writeAlphabeticalClassList(OutputList &ol)
{
QCString cname;
QCString namesp;
- if (Config::hideScopeNames)
+ if (Config::instance()->getBool("HIDE_SCOPE_NAMES"))
{
cname=cd->displayName();
}
@@ -1275,7 +1275,7 @@ void writeAlphabeticalClassList(OutputList &ol)
}
ol.docify(")");
}
- ol.writeNonBreakableSpace();
+ ol.writeNonBreakableSpace(3);
//printf("item ClassDef=%p %s\n",cd,cd ? cd->name().data() : "<none>");
++(*colIterators[j]);
}
@@ -1304,7 +1304,7 @@ void writeAlphabeticalIndex(OutputList &ol)
ol.disableAllBut(OutputGenerator::Html);
startFile(ol,"classes.html","Alphabetical index");
startTitle(ol,0);
- parseText(ol,Config::projectName+" "+theTranslator->trCompoundIndex());
+ parseText(ol,Config::instance()->getString("PROJECT_NAME")+" "+theTranslator->trCompoundIndex());
endTitle(ol,0,0);
writeAlphabeticalClassList(ol);
endFile(ol);
@@ -1315,8 +1315,8 @@ void writeAlphabeticalIndex(OutputList &ol)
void writeAnnotatedIndex(OutputList &ol)
{
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
if (annotatedClasses==0) return;
@@ -1327,7 +1327,7 @@ void writeAnnotatedIndex(OutputList &ol)
QCString title = theTranslator->trCompoundList();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
parseText(ol,title);
endTitle(ol,0,0);
ol.startTextBlock();
@@ -1365,8 +1365,8 @@ void writeAnnotatedIndex(OutputList &ol)
void writePackageIndex(OutputList &ol)
{
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
if (documentedPackages==0) return;
@@ -1377,7 +1377,7 @@ void writePackageIndex(OutputList &ol)
QCString title = theTranslator->trPackageList();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
parseText(ol,title);
endTitle(ol,0,0);
ol.startTextBlock();
@@ -1568,7 +1568,7 @@ void writeMemberIndex(OutputList &ol)
QCString title = theTranslator->trCompoundMembers();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
startTitle(ol,0);
parseText(ol,title);
endTitle(ol,0,0);
@@ -1577,8 +1577,8 @@ void writeMemberIndex(OutputList &ol)
{
writeQuickMemberIndex(ol,g_memberIndexLetterUsed);
}
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW");
if (hasHtmlHelp)
{
HtmlHelp *htmlHelp = HtmlHelp::getInstance();
@@ -1589,7 +1589,7 @@ void writeMemberIndex(OutputList &ol)
FTVHelp *ftvHelp = FTVHelp::getInstance();
ftvHelp->addContentsItem(FALSE,0,"functions",0,ftvHelpTitle);
}
- parseText(ol,theTranslator->trCompoundMembersDescription(Config::extractAllFlag));
+ parseText(ol,theTranslator->trCompoundMembersDescription(Config::instance()->getBool("EXTRACT_ALL")));
writeMemberList(ol,quickIndex);
endFile(ol);
ol.popGeneratorState();
@@ -1824,7 +1824,7 @@ void writeFileMemberIndex(OutputList &ol)
QCString title = theTranslator->trFileMembers();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
startTitle(ol,0);
parseText(ol,title);
endTitle(ol,0,0);
@@ -1833,8 +1833,8 @@ void writeFileMemberIndex(OutputList &ol)
{
writeQuickMemberIndex(ol,g_fileIndexLetterUsed);
}
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW");
if (hasHtmlHelp)
{
HtmlHelp *htmlHelp = HtmlHelp::getInstance();
@@ -1845,7 +1845,7 @@ void writeFileMemberIndex(OutputList &ol)
FTVHelp *ftvHelp = FTVHelp::getInstance();
ftvHelp->addContentsItem(FALSE,0,"globals",0,ftvHelpTitle);
}
- parseText(ol,theTranslator->trFileMembersDescription(Config::extractAllFlag));
+ parseText(ol,theTranslator->trFileMembersDescription(Config::instance()->getBool("EXTRACT_ALL")));
writeFileMemberList(ol,quickIndex);
endFile(ol);
ol.popGeneratorState();
@@ -1862,7 +1862,7 @@ void writeNamespaceMemberIndex(OutputList &ol)
QCString title = theTranslator->trNamespaceMembers();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
startTitle(ol,0);
parseText(ol,title);
endTitle(ol,0,0);
@@ -1871,8 +1871,8 @@ void writeNamespaceMemberIndex(OutputList &ol)
{
writeQuickMemberIndex(ol,g_namespaceIndexLetterUsed);
}
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW");
if (hasHtmlHelp)
{
HtmlHelp *htmlHelp = HtmlHelp::getInstance();
@@ -1883,7 +1883,7 @@ void writeNamespaceMemberIndex(OutputList &ol)
FTVHelp *ftvHelp = FTVHelp::getInstance();
ftvHelp->addContentsItem(FALSE,0,"namespacemembers",0,ftvHelpTitle);
}
- parseText(ol,theTranslator->trNamespaceMemberDescription(Config::extractAllFlag));
+ parseText(ol,theTranslator->trNamespaceMemberDescription(Config::instance()->getBool("EXTRACT_ALL")));
writeNamespaceMemberList(ol,quickIndex);
endFile(ol);
ol.popGeneratorState();
@@ -1901,14 +1901,14 @@ void writeExampleIndex(OutputList &ol)
QCString title = theTranslator->trExamples();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
parseText(ol,title);
endTitle(ol,0,0);
ol.startTextBlock();
HtmlHelp *htmlHelp = 0;
FTVHelp *ftvHelp = 0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -2005,14 +2005,14 @@ void writePageIndex(OutputList &ol)
QCString title = theTranslator->trRelatedPages();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
parseText(ol,title);
endTitle(ol,0,0);
ol.startTextBlock();
HtmlHelp *htmlHelp = 0;
FTVHelp *ftvHelp = 0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag /*&& !Config::htmlHelpGroupsOnly*/;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP") /*&& !Config::instance()->get("")*/;
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW") /*&& !Config::instance()->get("")*/;
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -2037,7 +2037,7 @@ void writePageIndex(OutputList &ol)
{
QCString pageName,pageTitle;
- if (Config::caseSensitiveNames)
+ if (Config::instance()->getBool("CASE_SENSE_NAMES"))
pageName=pi->name.copy();
else
pageName=pi->name.lower();
@@ -2099,19 +2099,19 @@ int countGroups()
void writeGraphInfo(OutputList &ol)
{
- if (!Config::haveDotFlag || !Config::generateHtml) return;
+ if (!Config::instance()->getBool("HAVE_DOT") || !Config::instance()->getBool("GENERATE_HTML")) return;
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Html);
- generateGraphLegend(Config::htmlOutputDir);
+ generateGraphLegend(Config::instance()->getString("HTML_OUTPUT"));
startFile(ol,"graph_legend","Graph Legend");
startTitle(ol,0);
parseText(ol,theTranslator->trLegendTitle());
endTitle(ol,0,0);
- bool oldStripCommentsState = Config::stripCommentsFlag;
+ bool oldStripCommentsState = Config::instance()->getBool("STRIP_CODE_COMMENTS");
// temporarily disable the stripping of comments for our own code example!
- Config::stripCommentsFlag = FALSE;
+ Config::instance()->getBool("STRIP_CODE_COMMENTS") = FALSE;
parseDoc(ol,"graph_legend",1,0,0,theTranslator->trLegendDocs());
- Config::stripCommentsFlag = oldStripCommentsState;
+ Config::instance()->getBool("STRIP_CODE_COMMENTS") = oldStripCommentsState;
endFile(ol);
ol.popGeneratorState();
}
@@ -2126,8 +2126,8 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
{
HtmlHelp *htmlHelp=0;
FTVHelp *ftvHelp = 0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW");
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -2206,7 +2206,7 @@ void writeGroupTreeNode(OutputList &ol, GroupDef *gd,bool subLevel)
}
- if (Config::htmlHelpTocExpandFlag)
+ if (Config::instance()->getBool("TOC_EXPAND"))
{
// write members
struct MemInfo
@@ -2413,8 +2413,8 @@ void writeGroupHierarchy(OutputList &ol)
#if 0
void writeGroupList(OutputList &ol)
{
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW");
HtmlHelp *htmlHelp = 0;
FTVHelp *ftvHelp = 0;
if (hasHtmlHelp) htmlHelp = HtmlHelp::getInstance();
@@ -2445,7 +2445,7 @@ void writeGroupList(OutputList &ol)
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
- if(!Config::htmlHelpGroupsOnly)
+ if(!Config::instance()->get(""))
{
htmlHelp->addContentsItem(FALSE,gd->groupTitle(),docFile);
}
@@ -2453,7 +2453,7 @@ void writeGroupList(OutputList &ol)
if (hasFtvHelp)
{
ftvHelp = FTVHelp::getInstance();
- if(!Config::htmlHelpGroupsOnly)
+ if(!Config::instance()->get(""))
{
ftvHelp->addContentsItem(FALSE,gd->groupTitle(),docFile);
}
@@ -2476,14 +2476,14 @@ void writeGroupIndex(OutputList &ol)
QCString title = theTranslator->trModules();
QCString htmlHelpTitle = title;
QCString ftvHelpTitle = title;
- if (!Config::projectName.isEmpty()) title.prepend(Config::projectName+" ");
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty()) title.prepend(Config::instance()->getString("PROJECT_NAME")+" ");
parseText(ol,title);
endTitle(ol,0,0);
ol.startTextBlock();
HtmlHelp *htmlHelp = 0;
FTVHelp *ftvHelp = 0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
- bool hasFtvHelp = Config::generateHtml && Config::ftvHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
+ bool hasFtvHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW");
if (hasHtmlHelp)
{
htmlHelp = HtmlHelp::getInstance();
@@ -2502,7 +2502,7 @@ void writeGroupIndex(OutputList &ol)
if (hasHtmlHelp)
{
//writeGroupTree(ol); // KPW - modified to write hierarchial HMTL Help
- //if(!Config::htmlHelpGroupsOnly)
+ //if(!Config::instance()->get(""))
//{
htmlHelp->decContentsDepth();
//}
@@ -2510,7 +2510,7 @@ void writeGroupIndex(OutputList &ol)
if (hasFtvHelp)
{
//writeGroupTree(ol); // KPW - modified to write hierarchial FTV Help
- //if(!Config::htmlHelpGroupsOnly)
+ //if(!Config::instance()->get(""))
//{
ftvHelp->decContentsDepth();
//}
@@ -2527,9 +2527,9 @@ void writeIndex(OutputList &ol)
ol.pushGeneratorState();
QCString projPrefix;
- if (!Config::projectName.isEmpty())
+ if (!Config::instance()->getString("PROJECT_NAME").isEmpty())
{
- projPrefix=Config::projectName+" ";
+ projPrefix=Config::instance()->getString("PROJECT_NAME")+" ";
}
//--------------------------------------------------------------------
@@ -2553,19 +2553,19 @@ void writeIndex(OutputList &ol)
}
QCString indexName="index";
- if (Config::ftvHelpFlag) indexName="main";
+ if (Config::instance()->getBool("GENERATE_TREEVIEW")) indexName="main";
ol.startFile(indexName,title,FALSE);
- if (Config::generateHtml && Config::htmlHelpFlag)
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP"))
{
HtmlHelp::getInstance()->addContentsItem(FALSE,title,indexName);
}
- if (Config::generateHtml && Config::ftvHelpFlag)
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_TREEVIEW"))
{
FTVHelp::getInstance()->addContentsItem(FALSE,0,indexName,0,title);
}
- if (!Config::noIndexFlag) writeQuickLinks(ol,TRUE);
+ if (!Config::instance()->getBool("DISABLE_INDEX")) writeQuickLinks(ol,TRUE);
ol.startTitleHead(0);
if (Doxygen::mainPage && !Doxygen::mainPage->title.isEmpty())
{
@@ -2577,13 +2577,13 @@ void writeIndex(OutputList &ol)
}
ol.endTitleHead(0,0);
ol.newParagraph();
- if (!Config::projectNumber.isEmpty())
+ if (!Config::instance()->getString("PROJECT_NUMBER").isEmpty())
{
ol.startProjectNumber();
- parseDoc(ol,defFileName,defLine,0,0,Config::projectNumber);
+ parseDoc(ol,defFileName,defLine,0,0,Config::instance()->getString("PROJECT_NUMBER"));
ol.endProjectNumber();
}
- if (Config::noIndexFlag && Doxygen::mainPage==0) writeQuickLinks(ol,FALSE);
+ if (Config::instance()->getBool("DISABLE_INDEX") && Doxygen::mainPage==0) writeQuickLinks(ol,FALSE);
if (Doxygen::mainPage)
{
@@ -2601,16 +2601,16 @@ void writeIndex(OutputList &ol)
ol.startFile("refman",0,FALSE);
ol.startIndexSection(isTitlePageStart);
- if (!Config::latexHeaderFile.isEmpty())
+ if (!Config::instance()->getString("LATEX_HEADER").isEmpty())
{
ol.disable(OutputGenerator::Latex);
}
parseText(ol,projPrefix+theTranslator->trReferenceManual());
- if (!Config::projectNumber.isEmpty())
+ if (!Config::instance()->getString("PROJECT_NUMBER").isEmpty())
{
ol.startProjectNumber();
- parseDoc(ol,defFileName,defLine,0,0,Config::projectNumber);
+ parseDoc(ol,defFileName,defLine,0,0,Config::instance()->getString("PROJECT_NUMBER"));
ol.endProjectNumber();
}
ol.endIndexSection(isTitlePageStart);
diff --git a/src/instdox.cpp b/src/instdox.cpp
index b7d3ec4..8d621ca 100644
--- a/src/instdox.cpp
+++ b/src/instdox.cpp
@@ -30,14 +30,14 @@
void writeInstallScript()
{
- QCString fileName=Config::htmlOutputDir+"/installdox";
+ QCString fileName=Config::instance()->getString("HTML_OUTPUT")+"/installdox";
QFile f(fileName);
if (f.open(IO_WriteOnly))
{
QTextStream t(&f);
- t << "#!" << Config::perlPath << endl << endl << "%subst = ( ";
+ t << "#!" << Config::instance()->getString("PERL_PATH") << endl << endl << "%subst = ( ";
- char *s=Config::tagFileList.first();
+ char *s=Config::instance()->getList("TAGFILES").first();
while (s)
{
QCString tagLine=s;
@@ -53,7 +53,7 @@ void writeInstallScript()
}
QFileInfo fi(fileName);
t << "\"" << fi.fileName() << "\", \"\"";
- s=Config::tagFileList.next();
+ s=Config::instance()->getList("TAGFILES").next();
if (s) t << ", ";
}
diff --git a/src/language.cpp b/src/language.cpp
index 59c1221..870a271 100644
--- a/src/language.cpp
+++ b/src/language.cpp
@@ -37,6 +37,7 @@
#include "translator_si.h"
#include "translator_cn.h"
#include "translator_no.h"
+#include "translator_br.h"
#endif
#define L_EQUAL(a) !stricmp(langName,a)
@@ -130,6 +131,10 @@ bool setTranslator(const char *langName)
{
theTranslator=new TranslatorNorwegian;
}
+ else if (L_EQUAL("brazilian"))
+ {
+ theTranslator=new TranslatorBrazilianPortuguese;
+ }
#endif
else // use the default language (i.e. english)
{
diff --git a/src/latexgen.cpp b/src/latexgen.cpp
index cd07ac8..1a65218 100644
--- a/src/latexgen.cpp
+++ b/src/latexgen.cpp
@@ -93,7 +93,7 @@ static QCString escapeMakeIndexChars(LatexGenerator *g,QTextStream &t,const char
LatexGenerator::LatexGenerator() : OutputGenerator()
{
- dir=Config::latexOutputDir;
+ dir=Config::instance()->getString("LATEX_OUTPUT");
col=0;
//printf("LatexGenerator::LatexGenerator() insideTabbing=FALSE\n");
insideTabbing=FALSE;
@@ -132,7 +132,7 @@ OutputGenerator *LatexGenerator::copy()
void LatexGenerator::init()
{
- QCString dir=Config::latexOutputDir;
+ QCString dir=Config::instance()->getString("LATEX_OUTPUT");
QDir d(dir);
if (!d.exists() && !d.mkdir(dir))
{
@@ -162,7 +162,7 @@ void LatexGenerator::init()
<< "\tdvips -o refman.ps refman.dvi" << endl
<< endl
<< "refman.pdf: refman.ps" << endl;
- if (Config::usePDFLatexFlag) // use pdflatex instead of latex
+ if (Config::instance()->getBool("USE_PDFLATEX")) // use pdflatex instead of latex
{
t << "\tpdflatex refman.tex" << endl;
t << "\tmakeindex refman.idx" << endl;
@@ -207,21 +207,25 @@ static void writeDefaultHeaderPart1(QTextStream &t)
// part 1
QCString paperName;
- if (Config::latexBatchModeFlag) t << "\\batchmode" << endl;
- if (Config::paperType=="a4wide") paperName="a4"; else paperName=Config::paperType;
+ if (Config::instance()->getBool("LATEX_BATCHMODE")) t << "\\batchmode" << endl;
+ QCString &paperType=Config::instance()->getEnum("PAPER_TYPE");
+ if (paperType=="a4wide")
+ paperName="a4";
+ else
+ paperName=paperType;
t << "\\documentclass[" << paperName << "paper";
- //if (Config::pdfHyperFlag) t << ",ps2pdf";
+ //if (Config::instance()->getBool("PDF_HYPERLINKS")) t << ",ps2pdf";
t << "]{";
- if (Config::compactLatexFlag) t << "article"; else t << "book";
+ if (Config::instance()->getBool("COMPACT_LATEX")) t << "article"; else t << "book";
t << "}\n";
- if (Config::paperType=="a4wide") t << "\\usepackage{a4wide}\n";
+ if (paperType=="a4wide") t << "\\usepackage{a4wide}\n";
t << "\\usepackage{makeidx}\n"
"\\usepackage{fancyhdr}\n"
"\\usepackage{graphicx}\n"
"\\usepackage{float}\n"
"\\usepackage{alltt}\n"
"\\usepackage{doxygen}\n";
- if (Config::pdfHyperFlag)
+ if (Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "\\usepackage{times}" << endl;
t << "\\ifx\\pdfoutput\\undefined" << endl
@@ -271,11 +275,12 @@ static void writeDefaultHeaderPart1(QTextStream &t)
}
}
- const char *s=Config::extraPackageList.first();
+ QStrList &extraPackages = Config::instance()->getList("EXTRA_PACKAGES");
+ const char *s=extraPackages.first();
while (s)
{
t << "\\usepackage{" << s << "}\n";
- s=Config::extraPackageList.next();
+ s=extraPackages.next();
}
t << "\\makeindex\n"
"\\setcounter{tocdepth}{1}\n"
@@ -304,10 +309,10 @@ static void writeDefaultHeaderPart3(QTextStream &t)
<< "{\\small " << dateToString(TRUE) << "}\\\\" << endl
<< "\\end{center}" << endl
<< "\\end{titlepage}" << endl;
- if (!Config::compactLatexFlag) t << "\\clearemptydoublepage\n";
+ if (!Config::instance()->getBool("COMPACT_LATEX")) t << "\\clearemptydoublepage\n";
t << "\\pagenumbering{roman}\n";
t << "\\tableofcontents\n";
- if (!Config::compactLatexFlag) t << "\\clearemptydoublepage\n";
+ if (!Config::instance()->getBool("COMPACT_LATEX")) t << "\\clearemptydoublepage\n";
t << "\\pagenumbering{arabic}\n";
}
@@ -323,7 +328,7 @@ static void writeDefaultStyleSheetPart1(QTextStream &t)
t << "\\addtolength{\\headwidth}{\\marginparwidth}\n";
t << "\\newcommand{\\clearemptydoublepage}{\\newpage{\\pagestyle{empty}";
t << "\\cleardoublepage}}\n";
- if (!Config::compactLatexFlag)
+ if (!Config::instance()->getBool("COMPACT_LATEX"))
t << "\\renewcommand{\\chaptermark}[1]{\\markboth{#1}{}}\n";
t << "\\renewcommand{\\sectionmark}[1]{\\markright{\\thesection\\ #1}}\n";
t << "\\lhead[\\fancyplain{}{\\bfseries\\thepage}]\n";
@@ -408,12 +413,19 @@ void LatexGenerator::writeStyleSheetFile(QFile &f)
{
QTextStream t(&f);
writeDefaultStyleSheetPart1(t);
+ QCString &projectName = Config::instance()->getString("PROJECT_NAME");
t << "Generated at " << dateToString(TRUE);
- if (Config::projectName.isEmpty()) t << " for " << Config::projectName << " ";
+ if (projectName.isEmpty())
+ {
+ t << " for " << projectName << " ";
+ }
t << "by doxygen written by Dimitri van Heesch \\copyright~1997-2001";
writeDefaultStyleSheetPart2(t);
t << "Generated at " << dateToString(TRUE);
- if (Config::projectName.isEmpty()) t << " for " << Config::projectName << " ";
+ if (projectName.isEmpty())
+ {
+ t << " for " << projectName << " ";
+ }
t << "by doxygen written by Dimitri van Heesch \\copyright~1997-2001";
writeDefaultStyleSheetPart3(t);
}
@@ -442,57 +454,59 @@ void LatexGenerator::startProjectNumber()
void LatexGenerator::startIndexSection(IndexSections is)
{
+ bool &compactLatex = Config::instance()->getBool("COMPACT_LATEX");
+ QCString &latexHeader = Config::instance()->getString("LATEX_HEADER");
switch (is)
{
case isTitlePageStart:
{
- if (Config::latexHeaderFile.isEmpty())
+ if (latexHeader.isEmpty())
{
writeDefaultHeaderPart1(t);
}
else
{
- QCString header = fileToString(Config::latexHeaderFile);
+ QCString header = fileToString(latexHeader);
t << substituteKeywords(header,0);
}
}
break;
case isTitlePageAuthor:
- if (Config::latexHeaderFile.isEmpty())
+ if (latexHeader.isEmpty())
{
writeDefaultHeaderPart2(t);
}
break;
case isMainPage:
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Introduction}\n"
break;
case isPackageIndex:
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Package Index}\n"
break;
case isModuleIndex:
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Module Index}\n"
break;
case isNamespaceIndex:
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Namespace Index}\"
break;
case isClassHierarchyIndex:
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Hierarchical Index}\n"
break;
case isCompoundIndex:
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Annotated Compound Index}\n"
break;
case isFileIndex:
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Annotated File Index}\n"
break;
case isPageIndex:
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Annotated Page Index}\n"
break;
case isPackageDocumentation:
@@ -502,7 +516,7 @@ void LatexGenerator::startIndexSection(IndexSections is)
bool found=FALSE;
while (pd && !found)
{
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{";
found=TRUE;
++pdi;
@@ -518,7 +532,7 @@ void LatexGenerator::startIndexSection(IndexSections is)
{
if (!gd->isReference())
{
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Module Documentation}\n";
found=TRUE;
}
@@ -534,7 +548,7 @@ void LatexGenerator::startIndexSection(IndexSections is)
{
if (nd->isLinkableInProject())
{
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; // Namespace Documentation}\n":
found=TRUE;
}
@@ -550,7 +564,7 @@ void LatexGenerator::startIndexSection(IndexSections is)
{
if (cd->isLinkableInProject())
{
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Compound Documentation}\n";
found=TRUE;
}
@@ -571,7 +585,7 @@ void LatexGenerator::startIndexSection(IndexSections is)
{
if (isFirst)
{
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //File Documentation}\n";
isFirst=FALSE;
break;
@@ -585,13 +599,13 @@ void LatexGenerator::startIndexSection(IndexSections is)
break;
case isExampleDocumentation:
{
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Example Documentation}\n";
}
break;
case isPageDocumentation:
{
- if (Config::compactLatexFlag) t << "\\section"; else t << "\\chapter";
+ if (compactLatex) t << "\\section"; else t << "\\chapter";
t << "{"; //Page Documentation}\n";
}
break;
@@ -602,19 +616,21 @@ void LatexGenerator::startIndexSection(IndexSections is)
void LatexGenerator::endIndexSection(IndexSections is)
{
+ bool &compactLatex = Config::instance()->getBool("COMPACT_LATEX");
+ QCString &latexHeader = Config::instance()->getString("LATEX_HEADER");
switch (is)
{
case isTitlePageStart:
break;
case isTitlePageAuthor:
- if (Config::latexHeaderFile.isEmpty())
+ if (latexHeader.isEmpty())
{
writeDefaultHeaderPart3(t);
}
break;
case isMainPage:
t << "}\n\\label{index}";
- if (Config::pdfHyperFlag) t << "\\hypertarget{index}{}";
+ if (Config::instance()->getBool("PDF_HYPERLINKS")) t << "\\hypertarget{index}{}";
t << "\\input{index}\n";
break;
case isPackageIndex:
@@ -652,7 +668,7 @@ void LatexGenerator::endIndexSection(IndexSections is)
}
while (pd)
{
- if (Config::compactLatexFlag) t << "\\input"; else t << "\\include";
+ if (compactLatex) t << "\\input"; else t << "\\include";
t << "{" << pd->getOutputFileBase() << "}\n";
++pdi;
pd=pdi.current();
@@ -676,7 +692,7 @@ void LatexGenerator::endIndexSection(IndexSections is)
{
if (!gd->isReference())
{
- if (Config::compactLatexFlag) t << "\\input"; else t << "\\include";
+ if (compactLatex) t << "\\input"; else t << "\\include";
t << "{" << gd->getOutputFileBase() << "}\n";
}
gd=Doxygen::groupList.next();
@@ -700,7 +716,7 @@ void LatexGenerator::endIndexSection(IndexSections is)
{
if (nd->isLinkableInProject())
{
- if (Config::compactLatexFlag) t << "\\input"; else t << "\\include";
+ if (compactLatex) t << "\\input"; else t << "\\include";
t << "{" << nd->getOutputFileBase() << "}\n";
}
nd=Doxygen::namespaceList.next();
@@ -724,7 +740,7 @@ void LatexGenerator::endIndexSection(IndexSections is)
{
if (cd->isLinkableInProject())
{
- if (Config::compactLatexFlag) t << "\\input"; else t << "\\include";
+ if (compactLatex) t << "\\input"; else t << "\\include";
t << "{" << cd->getOutputFileBase() << "}\n";
}
cd=Doxygen::classList.next();
@@ -749,7 +765,7 @@ void LatexGenerator::endIndexSection(IndexSections is)
}
else
{
- if (Config::compactLatexFlag) t << "\\input" ; else t << "\\include";
+ if (compactLatex) t << "\\input" ; else t << "\\include";
t << "{" << fd->getOutputFileBase() << "}\n";
}
}
@@ -770,7 +786,7 @@ void LatexGenerator::endIndexSection(IndexSections is)
}
for (++pdi;(pi=pdi.current());++pdi)
{
- if (Config::compactLatexFlag) t << "\\input" ; else t << "\\include";
+ if (compactLatex) t << "\\input" ; else t << "\\include";
t << "{" << convertFileName(pi->name) << "-example}\n";
}
}
@@ -786,11 +802,11 @@ void LatexGenerator::endIndexSection(IndexSections is)
if (!pi->inGroup && !pi->isReference())
{
QCString pageName;
- if (Config::caseSensitiveNames)
+ if (Config::instance()->getBool("CASE_SENSE_NAMES"))
pageName=pi->name.copy();
else
pageName=pi->name.lower();
- if (Config::compactLatexFlag || first) t << "\\input" ; else t << "\\include";
+ if (compactLatex || first) t << "\\input" ; else t << "\\include";
t << "{" << pageName << "}\n";
first=FALSE;
}
@@ -809,7 +825,7 @@ void LatexGenerator::writeStyleInfo(int part)
{
case 0:
{
- //QCString pname=Config::projectName.stripWhiteSpace();
+ //QCString pname=Config::instance()->getString("PROJECT_NAME").stripWhiteSpace();
startPlainFile("doxygen.sty");
writeDefaultStyleSheetPart1(t);
}
@@ -869,7 +885,7 @@ void LatexGenerator::writeIndexItem(const char *ref,const char *fn,
void LatexGenerator::startHtmlLink(const char *url)
{
- if (Config::pdfHyperFlag)
+ if (Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "\\href{";
t << url;
@@ -885,7 +901,7 @@ void LatexGenerator::endHtmlLink()
void LatexGenerator::writeMailLink(const char *url)
{
- if (Config::pdfHyperFlag)
+ if (Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "\\href{mailto:";
t << url;
@@ -920,7 +936,7 @@ void LatexGenerator::writeEndAnnoItem(const char *name)
void LatexGenerator::startTextLink(const char *f,const char *anchor)
{
- if (Config::pdfHyperFlag)
+ if (Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "\\hyperlink{";
if (f) t << f;
@@ -941,7 +957,7 @@ void LatexGenerator::endTextLink()
void LatexGenerator::writeObjectLink(const char *ref, const char *f,
const char *anchor, const char *text)
{
- if (!ref && Config::pdfHyperFlag)
+ if (!ref && Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "\\hyperlink{";
if (f) t << f;
@@ -981,11 +997,18 @@ void LatexGenerator::writeCodeLink(const char *,const char *,
void LatexGenerator::startTitleHead(const char *fileName)
{
- if (Config::pdfHyperFlag && fileName)
+ if (Config::instance()->getBool("PDF_HYPERLINKS") && fileName)
{
t << "\\hypertarget{" << fileName << "}{" << endl;
}
- if (Config::compactLatexFlag) t << "\\subsection{"; else t << "\\section{";
+ if (Config::instance()->getBool("COMPACT_LATEX"))
+ {
+ t << "\\subsection{";
+ }
+ else
+ {
+ t << "\\section{";
+ }
}
void LatexGenerator::endTitleHead(const char *fileName,const char *name)
@@ -998,7 +1021,7 @@ void LatexGenerator::endTitleHead(const char *fileName,const char *name)
docify(name);
t << "}}" << endl;
}
- if (Config::pdfHyperFlag && fileName)
+ if (Config::instance()->getBool("PDF_HYPERLINKS") && fileName)
{
t << "}" << endl;
}
@@ -1006,12 +1029,26 @@ void LatexGenerator::endTitleHead(const char *fileName,const char *name)
void LatexGenerator::startTitle()
{
- if (Config::compactLatexFlag) t << "\\subsection{"; else t << "\\section{";
+ if (Config::instance()->getBool("COMPACT_LATEX"))
+ {
+ t << "\\subsection{";
+ }
+ else
+ {
+ t << "\\section{";
+ }
}
void LatexGenerator::startGroupHeader()
{
- if (Config::compactLatexFlag) t << "\\subsubsection{"; else t << "\\subsection{";
+ if (Config::instance()->getBool("COMPACT_LATEX"))
+ {
+ t << "\\subsubsection{";
+ }
+ else
+ {
+ t << "\\subsection{";
+ }
}
void LatexGenerator::endGroupHeader()
@@ -1021,7 +1058,14 @@ void LatexGenerator::endGroupHeader()
void LatexGenerator::startMemberHeader()
{
- if (Config::compactLatexFlag) t << "\\subsubsection*{"; else t << "\\subsection*{";
+ if (Config::instance()->getBool("COMPACT_LATEX"))
+ {
+ t << "\\subsubsection*{";
+ }
+ else
+ {
+ t << "\\subsection*{";
+ }
}
void LatexGenerator::endMemberHeader()
@@ -1058,8 +1102,8 @@ void LatexGenerator::startMemberDoc(const char *clname,
}
t << "}" << endl;
}
- if (Config::compactLatexFlag) t << "\\paragraph"; else t << "\\subsubsection";
- if (Config::pdfHyperFlag && memname)
+ if (Config::instance()->getBool("COMPACT_LATEX")) t << "\\paragraph"; else t << "\\subsubsection";
+ if (Config::instance()->getBool("PDF_HYPERLINKS") && memname)
{
t << "[";
escapeMakeIndexChars(this,t,memname);
@@ -1072,13 +1116,13 @@ void LatexGenerator::startMemberDoc(const char *clname,
void LatexGenerator::endMemberDoc()
{
t << "}";
- if (Config::compactLatexFlag) t << "\\hfill";
+ if (Config::instance()->getBool("COMPACT_LATEX")) t << "\\hfill";
}
void LatexGenerator::startDoxyAnchor(const char *fName,const char *anchor,
const char *)
{
- if (Config::pdfHyperFlag)
+ if (Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "\\hypertarget{";
if (fName) t << fName;
@@ -1089,7 +1133,7 @@ void LatexGenerator::startDoxyAnchor(const char *fName,const char *anchor,
void LatexGenerator::endDoxyAnchor(const char *fName,const char *anchor)
{
- if (Config::pdfHyperFlag)
+ if (Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "}" << endl;
}
@@ -1102,7 +1146,7 @@ void LatexGenerator::endDoxyAnchor(const char *fName,const char *anchor)
void LatexGenerator::writeAnchor(const char *fName,const char *name)
{
t << "\\label{" << name << "}" << endl;
- if (fName && Config::pdfHyperFlag)
+ if (fName && Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "\\hypertarget{" << fName << "_" << name << "}{}" << endl;
}
@@ -1134,12 +1178,12 @@ void LatexGenerator::addIndexItem(const char *s1,const char *s2)
void LatexGenerator::startSection(const char *lab,const char *,bool sub)
{
- if (Config::pdfHyperFlag)
+ if (Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "\\hypertarget{" << lab << "}{}";
}
t << "\\";
- if (Config::compactLatexFlag)
+ if (Config::instance()->getBool("COMPACT_LATEX"))
{
if (sub) t << "subsubsection{"; else t << "subsection{";
}
@@ -1163,7 +1207,7 @@ void LatexGenerator::writeSectionRef(const char *ref,const char *,
}
else // local reference
{
- if (text && Config::pdfHyperFlag)
+ if (text && Config::instance()->getBool("PDF_HYPERLINKS"))
{
t << "\\hyperlink{";
if (lab) t << lab;
@@ -1256,13 +1300,13 @@ void LatexGenerator::docify(const char *str)
case '>': t << "$>$"; break;
case '|': t << "$|$"; break;
case '~': t << "$\\sim$"; break;
- case '[': if (Config::pdfHyperFlag)
+ case '[': if (Config::instance()->getBool("PDF_HYPERLINKS"))
t << "\\mbox{[}";
else
t << "[";
break;
case ']': if (pc=='[') t << "$\\,$";
- if (Config::pdfHyperFlag)
+ if (Config::instance()->getBool("PDF_HYPERLINKS"))
t << "\\mbox{]}";
else
t << "]";
@@ -1403,6 +1447,7 @@ void LatexGenerator::codify(const char *str)
const char *p=str;
char c;
int spacesToNextTabStop;
+ int &tabSize = Config::instance()->getInt("TAB_SIZE");
while (*p)
{
c=*p++;
@@ -1410,7 +1455,7 @@ void LatexGenerator::codify(const char *str)
{
case 0x0c: break; // remove ^L
case '\t': spacesToNextTabStop =
- Config::tabSize - (col%Config::tabSize);
+ tabSize - (col%tabSize);
t << spaces.left(spacesToNextTabStop);
col+=spacesToNextTabStop;
break;
@@ -1431,7 +1476,7 @@ void LatexGenerator::writeChar(char c)
void LatexGenerator::startClassDiagram()
{
- //if (Config::compactLatexFlag) t << "\\subsubsection"; else t << "\\subsection";
+ //if (Config::instance()->getBool("COMPACT_LATEX")) t << "\\subsubsection"; else t << "\\subsection";
//t << "{";
}
@@ -1480,7 +1525,7 @@ void LatexGenerator::endMemberItem(bool endItem)
t << endl;
}
-void LatexGenerator::writeNonBreakableSpace()
+void LatexGenerator::writeNonBreakableSpace(int)
{
if (insideTabbing)
t << "\\>";
@@ -1565,7 +1610,7 @@ void LatexGenerator::startDotGraph()
void LatexGenerator::endDotGraph(DotClassGraph &g)
{
- g.writeGraph(t,EPS,Config::latexOutputDir);
+ g.writeGraph(t,EPS,Config::instance()->getString("LATEX_OUTPUT"));
}
void LatexGenerator::startInclDepGraph()
@@ -1574,7 +1619,7 @@ void LatexGenerator::startInclDepGraph()
void LatexGenerator::endInclDepGraph(DotInclDepGraph &g)
{
- g.writeGraph(t,EPS,Config::latexOutputDir);
+ g.writeGraph(t,EPS,Config::instance()->getString("LATEX_OUTPUT"));
}
void LatexGenerator::startDescription()
diff --git a/src/latexgen.h b/src/latexgen.h
index 0c6ed8e..d9341dd 100644
--- a/src/latexgen.h
+++ b/src/latexgen.h
@@ -207,7 +207,7 @@ class LatexGenerator : public OutputGenerator
void startQuickIndexItem(const char *,const char *) {}
void endQuickIndexItem() {}
void writeFormula(const char *,const char *);
- void writeNonBreakableSpace();
+ void writeNonBreakableSpace(int);
void startImage(const char *,const char *,bool);
void endImage(bool);
diff --git a/src/libdoxycfg.pro.in b/src/libdoxycfg.pro.in
new file mode 100644
index 0000000..33e3acc
--- /dev/null
+++ b/src/libdoxycfg.pro.in
@@ -0,0 +1,26 @@
+#
+#
+#
+# Copyright (C) 1997-2001 by Dimitri van Heesch.
+#
+# Permission to use, copy, modify, and distribute this software and its
+# documentation under the terms of the GNU General Public License is hereby
+# granted. No representations are made about the suitability of this software
+# for any purpose. It is provided "as is" without express or implied warranty.
+# See the GNU General Public License for more details.
+#
+# Documents produced by Doxygen are derivative works derived from the
+# input used in their production; they are not affected by this license.
+#
+# TMake project file for doxygen
+
+TEMPLATE = libdoxycfg.t
+CONFIG = console warn_on staticlib $extraopts
+HEADERS = config.h
+SOURCES = config.cpp
+win32:TMAKE_CXXFLAGS += -DQT_NODLL
+INCLUDEPATH += ../qtools
+win32:INCLUDEPATH += .
+DESTDIR = ../lib
+TARGET = doxycfg
+OBJECTS_DIR = ../objects
diff --git a/src/libdoxycfg.t b/src/libdoxycfg.t
new file mode 100644
index 0000000..7219648
--- /dev/null
+++ b/src/libdoxycfg.t
@@ -0,0 +1,49 @@
+#
+#
+#
+# Copyright (C) 1997-2001 by Dimitri van Heesch.
+#
+# Permission to use, copy, modify, and distribute this software and its
+# documentation under the terms of the GNU General Public License is hereby
+# granted. No representations are made about the suitability of this software
+# for any purpose. It is provided "as is" without express or implied warranty.
+# See the GNU General Public License for more details.
+#
+# Documents produced by Doxygen are derivative works derived from the
+# input used in their production; they are not affected by this license.
+#!
+#! doxygen.t: This is a custom template for building Doxygen
+#!
+#$ IncludeTemplate("lib.t");
+
+LEX = flex
+YACC = bison
+
+#${
+sub GenerateDep {
+ my($obj,$src,$dep) = @_;
+ my(@objv,$srcv,$i,$s,$o,$d,$c);
+ @objv = split(/\s+/,$obj);
+ @srcv = split(/\s+/,$src);
+ for $i ( 0..$#objv ) {
+ $s = $srcv[$i];
+ $o = $objv[$i];
+ next if $s eq "";
+ $text .= $o . ": " . $s;
+ $text .= " ${linebreak}\n\t\t" . $dep if $dep ne "";
+ if ( $moc_output{$s} ne "" ) {
+ $text .= " ${linebreak}\n\t\t" . $moc_output{$s};
+ }
+ $d = &make_depend($s);
+ $text .= " ${linebreak}\n\t\t" . $d if $d ne "";
+ $text .= "\n";
+ }
+ chop $text;
+}
+#$}
+
+####################
+
+#$ GenerateDep("config.cpp","config.l");
+ $(LEX) -PconfigYY -t config.l >config.cpp
+
diff --git a/src/libdoxygen.pro.in b/src/libdoxygen.pro.in
index b5d4f59..60bfef6 100644
--- a/src/libdoxygen.pro.in
+++ b/src/libdoxygen.pro.in
@@ -32,7 +32,7 @@ HEADERS = doxygen.h scanner.h doc.h classdef.h classlist.h memberdef.h \
SOURCES = doxygen.cpp scanner.cpp doc.cpp classdef.cpp classlist.cpp \
memberdef.cpp membername.cpp index.cpp memberlist.cpp \
entry.cpp logos.cpp instdox.cpp message.cpp code.cpp \
- config.cpp filedef.cpp util.cpp groupdef.cpp \
+ filedef.cpp util.cpp groupdef.cpp \
outputgen.cpp outputlist.cpp htmlgen.cpp latexgen.cpp mangen.cpp \
cppvalue.cpp ce_lex.cpp ce_parse.cpp pre.cpp \
filename.cpp declinfo.cpp defargs.cpp define.cpp \
diff --git a/src/libdoxygen.t b/src/libdoxygen.t
index 3c819c0..82fea0e 100644
--- a/src/libdoxygen.t
+++ b/src/libdoxygen.t
@@ -53,9 +53,6 @@ sub GenerateDep {
#$ GenerateDep("pre.cpp","pre.l");
$(LEX) -PpreYY -t pre.l >pre.cpp
-#$ GenerateDep("config.cpp","config.l");
- $(LEX) -PconfigYY -t config.l >config.cpp
-
#$ GenerateDep("declinfo.cpp","declinfo.l");
$(LEX) -PdeclinfoYY -t declinfo.l >declinfo.cpp
diff --git a/src/mangen.cpp b/src/mangen.cpp
index 36e2334..4a80d6a 100644
--- a/src/mangen.cpp
+++ b/src/mangen.cpp
@@ -27,7 +27,7 @@
ManGenerator::ManGenerator() : OutputGenerator()
{
- dir=Config::manOutputDir+"/man3";
+ dir=Config::instance()->getString("MAN_OUTPUT")+"/man3";
firstCol=TRUE;
paragraph=FALSE;
col=0;
@@ -56,16 +56,16 @@ void ManGenerator::append(const OutputGenerator *g)
void ManGenerator::init()
{
- QDir d(Config::manOutputDir);
- if (!d.exists() && !d.mkdir(Config::manOutputDir))
+ QDir d(Config::instance()->getString("MAN_OUTPUT"));
+ if (!d.exists() && !d.mkdir(Config::instance()->getString("MAN_OUTPUT")))
{
- err("Could not create output directory %s\n",Config::manOutputDir.data());
+ err("Could not create output directory %s\n",Config::instance()->getString("MAN_OUTPUT").data());
exit(1);
}
- d.setPath(Config::manOutputDir+"/man3");
- if (!d.exists() && !d.mkdir(Config::manOutputDir+"/man3"))
+ d.setPath(Config::instance()->getString("MAN_OUTPUT")+"/man3");
+ if (!d.exists() && !d.mkdir(Config::instance()->getString("MAN_OUTPUT")+"/man3"))
{
- err("Could not create output directory %s/man3\n",Config::manOutputDir.data());
+ err("Could not create output directory %s/man3\n",Config::instance()->getString("MAN_OUTPUT").data());
exit(1);
}
}
@@ -105,9 +105,9 @@ void ManGenerator::startFile(const char *name,const char *,bool)
{
fileName=fileName.left(i);
}
- if (convertToQCString(fileName.right(2))!=Config::manExtension)
+ if (convertToQCString(fileName.right(2))!=Config::instance()->getString("MAN_EXTENSION"))
{
- fileName+=Config::manExtension;
+ fileName+=Config::instance()->getString("MAN_EXTENSION");
}
startPlainFile(fileName);
firstCol=TRUE;
@@ -121,10 +121,10 @@ void ManGenerator::endFile()
void ManGenerator::endTitleHead(const char *,const char *name)
{
t << ".TH \"" << name << "\" 3 \"" << dateToString(FALSE) << "\" \"";
- if (Config::projectName.isEmpty())
+ if (Config::instance()->getString("PROJECT_NAME").isEmpty())
t << "Doxygen";
else
- t << Config::projectName;
+ t << Config::instance()->getString("PROJECT_NAME");
t << "\" \\\" -*- nroff -*-" << endl;
t << ".ad l" << endl;
t << ".nh" << endl;
@@ -248,7 +248,7 @@ void ManGenerator::codify(const char *str)
switch(c)
{
case '\t': spacesToNextTabStop =
- Config::tabSize - (col%Config::tabSize);
+ Config::instance()->getInt("TAB_SIZE") - (col%Config::instance()->getInt("TAB_SIZE"));
t << spaces.left(spacesToNextTabStop);
col+=spacesToNextTabStop;
break;
diff --git a/src/mangen.h b/src/mangen.h
index 920f1cb..c606115 100644
--- a/src/mangen.h
+++ b/src/mangen.h
@@ -194,7 +194,7 @@ class ManGenerator : public OutputGenerator
void startQuickIndexItem(const char *,const char *) {}
void endQuickIndexItem() {}
void writeFormula(const char *,const char *) {}
- void writeNonBreakableSpace() { t << " "; }
+ void writeNonBreakableSpace(int n) { int i; for (i=0;i<n;i++) t << " "; }
void startImage(const char *,const char *,bool) {}
void endImage(bool) {}
diff --git a/src/memberdef.cpp b/src/memberdef.cpp
index 8ccf62b..947dabd 100644
--- a/src/memberdef.cpp
+++ b/src/memberdef.cpp
@@ -279,7 +279,7 @@ MemberDef::MemberDef(const char *df,int dl,
indDepth=0;
section=0;
explExt=FALSE;
- maxInitLines=Config::maxInitLines;
+ maxInitLines=Config::instance()->getInt("MAX_INITIALIZER_LINES");
userInitLines=-1;
docEnumValues=FALSE;
// copy function template arguments (if any)
@@ -484,19 +484,19 @@ void MemberDef::writeDeclaration(OutputList &ol,
// (they are displayed by there parent placeholder)
if (annScope) return;
// hide undocumented members unless overwritten by the configuration
- if (!hasDocs && Config::hideMemberFlag) return;
+ if (!hasDocs && Config::instance()->getBool("HIDE_UNDOC_MEMBERS")) return;
// hide members with no detailed desciption and brief descriptions explicitly
// disabled.
- if (Config::hideMemberFlag && documentation().isEmpty() &&
- !Config::briefMemDescFlag && !Config::repeatBriefFlag
+ if (Config::instance()->getBool("HIDE_UNDOC_MEMBERS") && documentation().isEmpty() &&
+ !Config::instance()->getBool("BRIEF_MEMBER_DESC") && !Config::instance()->getBool("REPEAT_BRIEF")
) return;
// hide static file & namespace members unless extract static is on
- if (cd==0 && isStatic() && !Config::extractStaticFlag) return;
+ if (cd==0 && isStatic() && !Config::instance()->getBool("EXTRACT_STATIC")) return;
// hide private member that are put into a member group. Non-grouped
// members are not rendered anyway.
//printf("md->name()=`%s' Protection=%d\n",name().data(),protection());
- if (inGroup && protection()==Private && !Config::extractPrivateFlag) return;
+ if (inGroup && protection()==Private && !Config::instance()->getBool("EXTRACT_PRIVATE")) return;
QCString ltype=type.copy();
// strip `static' keyword from ltype
@@ -508,7 +508,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
if ((ltype.isEmpty() || (i=r.match(ltype,0,&l))==-1) || !enumUsed())
{
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <member kind=\"";
switch (mtype)
@@ -586,7 +586,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
//}
HtmlHelp *htmlHelp=0;
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
if (hasHtmlHelp) htmlHelp = HtmlHelp::getInstance();
// search for the last anonymous scope in the member type
@@ -627,7 +627,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
// If there is no detailed description we need to write the anchor here.
bool detailsVisible = detailsAreVisible();
- if (!detailsVisible && !Config::extractAllFlag && !annMemb)
+ if (!detailsVisible && !Config::instance()->getBool("EXTRACT_ALL") && !annMemb)
{
QCString doxyName=name().copy();
if (!cname.isEmpty()) doxyName.prepend(cname+"::");
@@ -652,7 +652,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
int j;
for (j=0;j<indDepth;j++)
{
- ol.writeNonBreakableSpace();
+ ol.writeNonBreakableSpace(3);
}
}
@@ -678,7 +678,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
int j;
for (j=0;j<indDepth;j++)
{
- ol.writeNonBreakableSpace();
+ ol.writeNonBreakableSpace(3);
}
QCString varName=ltype.right(ltype.length()-ir).stripWhiteSpace();
ol.docify("}");
@@ -711,7 +711,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
linkifyText(TextGeneratorOLImpl(ol),cname,name(),ltype,TRUE);
}
bool htmlOn = ol.isEnabled(OutputGenerator::Html);
- if (htmlOn && Config::htmlAlignMemberFlag && !ltype.isEmpty())
+ if (htmlOn && Config::instance()->getBool("HTML_ALIGN_MEMBERS") && !ltype.isEmpty())
{
ol.disable(OutputGenerator::Html);
}
@@ -729,7 +729,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
//if (manOn) ol.disable(OutputGenerator::Man);
ol.pushGeneratorState();
ol.disableAllBut(OutputGenerator::Html);
- ol.writeNonBreakableSpace();
+ ol.writeNonBreakableSpace(3);
ol.popGeneratorState();
//if (latexOn) ol.enable(OutputGenerator::Latex);
//if (manOn) ol.enable(OutputGenerator::Man);
@@ -805,12 +805,12 @@ void MemberDef::writeDeclaration(OutputList &ol,
}
else
{
- ol.writeNonBreakableSpace();
+ ol.writeNonBreakableSpace(3);
linkifyText(TextGeneratorOLImpl(ol),cname,name(),init);
}
}
- if (!detailsVisible && !Config::extractAllFlag && !annMemb)
+ if (!detailsVisible && !Config::instance()->getBool("EXTRACT_ALL") && !annMemb)
{
ol.endDoxyAnchor(cfname,anchor());
}
@@ -819,7 +819,7 @@ void MemberDef::writeDeclaration(OutputList &ol,
//ol.endMemberItem(gId!=-1,gFile,gHeader,annoClassDef || annMemb);
// write brief description
- if (!briefDescription().isEmpty() && Config::briefMemDescFlag && !annMemb)
+ if (!briefDescription().isEmpty() && Config::instance()->getBool("BRIEF_MEMBER_DESC") && !annMemb)
{
ol.startMemberDescription();
parseDoc(ol,defFileName,defLine,cname,name(),briefDescription());
@@ -858,7 +858,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
)
{
// hide global static functions unless extractStaticFlag is enabled
- if (getClassDef()==0 && isStatic() && !Config::extractStaticFlag) return;
+ if (getClassDef()==0 && isStatic() && !Config::instance()->getBool("EXTRACT_STATIC")) return;
// hide member that are documented in their own group
if (group!=0 && container->definitionType()!=TypeGroup) return;
@@ -874,7 +874,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
bool hasDocs = detailsAreVisible();
//printf("MemberDef::writeDocumentation(): type=`%s' def=`%s'\n",type.data(),definition());
if (
- Config::extractAllFlag || hasDocs
+ Config::instance()->getBool("EXTRACT_ALL") || hasDocs
|| /* member is part of an anonymous scope that is the type of
* another member in the list.
*/
@@ -910,7 +910,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
ol.pushGeneratorState();
- bool hasHtmlHelp = Config::generateHtml && Config::htmlHelpFlag;
+ bool hasHtmlHelp = Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP");
HtmlHelp *htmlHelp = 0;
if (hasHtmlHelp) htmlHelp = HtmlHelp::getInstance();
@@ -979,7 +979,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
//if (cd && (!isRelated() || templateArguments()!=0) &&
// ((al=scopeDefTemplateArguments()) || (al=cd->templateArguments()))
// )
- if (!Config::hideScopeNames)
+ if (!Config::instance()->getBool("HIDE_SCOPE_NAMES"))
{
if (scopeAl && !related) // class template prefix
{
@@ -1028,7 +1028,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
}
else
{
- ol.writeNonBreakableSpace();
+ ol.writeNonBreakableSpace(3);
linkifyText(TextGeneratorOLImpl(ol),scopeName,name(),init);
}
}
@@ -1049,7 +1049,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
if (protection()!=Public || lvirt!=Normal ||
isFriend() || isRelated() || isExplicit() ||
- isMutable() || (isInline() && Config::inlineInfoFlag) ||
+ isMutable() || (isInline() && Config::instance()->getBool("INLINE_INFO")) ||
isSignal() || isSlot() ||
isStatic()
)
@@ -1063,7 +1063,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
else if (isRelated()) sl.append("related");
else
{
- if (Config::inlineInfoFlag && isInline())
+ if (Config::instance()->getBool("INLINE_INFO") && isInline())
sl.append("inline");
if (isExplicit()) sl.append("explicit");
if (isMutable()) sl.append("mutable");
@@ -1115,8 +1115,8 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
/* write brief description */
if (!briefDescription().isEmpty() &&
- (Config::repeatBriefFlag
- /* || (!Config::briefMemDescFlag && documentation().isEmpty())*/
+ (Config::instance()->getBool("REPEAT_BRIEF")
+ /* || (!Config::instance()->getBool("BRIEF_MEMBER_DESC") && documentation().isEmpty())*/
) /* || !annMemb */
)
{
@@ -1195,7 +1195,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
ol.addIndexItem(fmd->name(),cname);
ol.addIndexItem(cname,fmd->name());
- if (Config::generateHtml && Config::htmlHelpFlag)
+ if (Config::instance()->getBool("GENERATE_HTML") && Config::instance()->getBool("GENERATE_HTMLHELP"))
{
HtmlHelp::getInstance()->addIndexItem(cname,fmd->name(),cfname,fmd->anchor());
}
@@ -1275,7 +1275,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
{
ol.writeObjectLink(bcd->getReference(),bcd->getOutputFileBase(),
bmd->anchor(),bcd->name());
- if ( bcd->isLinkableInProject()/* && !Config::pdfHyperFlag*/ )
+ if ( bcd->isLinkableInProject()/* && !Config::instance()->getBool("PDF_HYPERLINKS")*/ )
{
writePageRef(ol,bcd->getOutputFileBase(),bmd->anchor());
}
@@ -1284,7 +1284,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
{
ol.writeObjectLink(bcd->getReference(),bcd->getOutputFileBase(),
0,bcd->name());
- if (bcd->isLinkableInProject()/* && !Config::pdfHyperFlag*/ )
+ if (bcd->isLinkableInProject()/* && !Config::instance()->getBool("PDF_HYPERLINKS")*/ )
{
writePageRef(ol,bcd->getOutputFileBase(),0);
}
@@ -1350,7 +1350,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
{
ol.writeObjectLink(bcd->getReference(),bcd->getOutputFileBase(),
bmd->anchor(),bcd->name());
- if (bcd->isLinkableInProject()/* && !Config::pdfHyperFlag*/ )
+ if (bcd->isLinkableInProject()/* && !Config::instance()->getBool("PDF_HYPERLINKS")*/ )
{
writePageRef(ol,bcd->getOutputFileBase(),bmd->anchor());
}
@@ -1385,7 +1385,7 @@ void MemberDef::writeDocumentation(MemberList *ml,OutputList &ol,
ol.endIndent();
// enable LaTeX again
- //if (Config::extractAllFlag && !hasDocs) ol.enable(OutputGenerator::Latex);
+ //if (Config::instance()->getBool("EXTRACT_ALL") && !hasDocs) ol.enable(OutputGenerator::Latex);
ol.popGeneratorState();
}
@@ -1420,8 +1420,8 @@ bool MemberDef::isLinkableInProject()
return !name().isEmpty() && name().at(0)!='@' &&
((hasDocumentation() && !isReference())
) &&
- (prot!=Private || Config::extractPrivateFlag || isFriend()) && // not a private class member
- (classDef!=0 || Config::extractStaticFlag || !isStatic()); // not a static file/namespace member
+ (prot!=Private || Config::instance()->getBool("EXTRACT_PRIVATE") || isFriend()) && // not a private class member
+ (classDef!=0 || Config::instance()->getBool("EXTRACT_STATIC") || !isStatic()); // not a static file/namespace member
}
bool MemberDef::isLinkable()
@@ -1432,12 +1432,12 @@ bool MemberDef::isLinkable()
bool MemberDef::detailsAreVisible() const
{
return !documentation().isEmpty() || // has detailed docs
- //((Config::sourceBrowseFlag || Config::inlineSourceFlag) && startBodyLine!=-1 && bodyDef) || // has reference to sources
+ //((Config::instance()->getBool("SOURCE_BROWSER") || Config::instance()->getBool("INLINE_SOURCES")) && startBodyLine!=-1 && bodyDef) || // has reference to sources
(mtype==Enumeration && docEnumValues) || // has enum values
(mtype==EnumValue && !briefDescription().isEmpty()) || // is doc enum value
(!briefDescription().isEmpty() &&
- (!Config::briefMemDescFlag || Config::alwaysDetailsFlag) &&
- Config::repeatBriefFlag // has brief description inside detailed area
+ (!Config::instance()->getBool("BRIEF_MEMBER_DESC") || Config::instance()->getBool("ALWAYS_DETAILED_SEC")) &&
+ Config::instance()->getBool("REPEAT_BRIEF") // has brief description inside detailed area
) ||
(initLines>0 && initLines<maxInitLines) ||
(argList!=0 && argList->hasDocumentation())
diff --git a/src/memberlist.cpp b/src/memberlist.cpp
index 2a72173..f15f041 100644
--- a/src/memberlist.cpp
+++ b/src/memberlist.cpp
@@ -54,18 +54,18 @@ void MemberList::countDecMembers(bool inGroup,bool countSubGroups,bool sectionPe
{
//printf("md=%p md->name()=`%s' inGroup=%d getMemberGroup()=%p\n",
// md,md->name().data(),inGroup,md->getMemberGroup());
- if (!(md->getClassDef()==0 && md->isStatic() && !Config::extractStaticFlag) &&
- (!Config::hideMemberFlag || md->hasDocumentation()) &&
+ if (!(md->getClassDef()==0 && md->isStatic() && !Config::instance()->getBool("EXTRACT_STATIC")) &&
+ (!Config::instance()->getBool("HIDE_UNDOC_MEMBERS") || md->hasDocumentation()) &&
(
- (!Config::hideMemberFlag || !md->documentation().isEmpty() ||
- Config::briefMemDescFlag || Config::repeatBriefFlag
- ) || Config::extractAllFlag ||
+ (!Config::instance()->getBool("HIDE_UNDOC_MEMBERS") || !md->documentation().isEmpty() ||
+ Config::instance()->getBool("BRIEF_MEMBER_DESC") || Config::instance()->getBool("REPEAT_BRIEF")
+ ) || Config::instance()->getBool("EXTRACT_ALL") ||
(md->isEnumerate() &&
md->hasDocumentedEnumValues()
)
) &&
inGroup==md->visibleMemberGroup(sectionPerType) &&
- !(inGroup && md->protection()==Private && !Config::extractPrivateFlag)
+ !(inGroup && md->protection()==Private && !Config::instance()->getBool("EXTRACT_PRIVATE"))
)
{
switch(md->memberType())
@@ -83,7 +83,7 @@ void MemberList::countDecMembers(bool inGroup,bool countSubGroups,bool sectionPe
case MemberDef::EnumValue: enumValCnt++,m_count++; break;
case MemberDef::Typedef: typeCnt++,m_count++; break;
case MemberDef::Prototype: protoCnt++,m_count++; break;
- case MemberDef::Define: if (Config::extractAllFlag ||
+ case MemberDef::Define: if (Config::instance()->getBool("EXTRACT_ALL") ||
md->argsString() ||
!md->initializer().isEmpty() ||
md->hasDocumentation()
@@ -122,12 +122,12 @@ void MemberList::countDocMembers(bool listOfGroup)
//printf("%s MemberList::countDocMembers() details=%d\n",
// md->name().data(),md->detailsAreVisible());
bool visibleIfStatic =
- !(md->getClassDef()==0 && md->isStatic() && !Config::extractStaticFlag);
+ !(md->getClassDef()==0 && md->isStatic() && !Config::instance()->getBool("EXTRACT_STATIC"));
bool inOwnGroup = (md->getGroupDef()!=0 && !listOfGroup);
if (visibleIfStatic && !inOwnGroup &&
- (Config::extractAllFlag || md->detailsAreVisible())
+ (Config::instance()->getBool("EXTRACT_ALL") || md->detailsAreVisible())
)
{
if (md->memberType()!=MemberDef::EnumValue) m_count++;
@@ -190,7 +190,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,
if (md->isDefine() &&
(md->argsString() || md->hasDocumentation() ||
!md->initializer().isEmpty() ||
- Config::extractAllFlag) &&
+ Config::instance()->getBool("EXTRACT_ALL")) &&
inGroup==md->visibleMemberGroup(sectionPerType)
)
{
@@ -264,21 +264,21 @@ void MemberList::writePlainDeclarations(OutputList &ol,
for ( ; (md=mli.current()) ; ++mli ) // iterate through the members
{
// see if member is hidden by protection
- if (md->protection()==Private && !Config::extractPrivateFlag) continue;
+ if (md->protection()==Private && !Config::instance()->getBool("EXTRACT_PRIVATE")) continue;
QCString type=md->typeString();
type=type.stripWhiteSpace(); // TODO: is this really needed?
// filter out enums that are in a group iff inGroup holds
- if (md->isEnumerate() && inGroup==md->visibleMemberGroup(sectionPerType) /*&& (hasDocs || !Config::hideMemberFlag)*/)
+ if (md->isEnumerate() && inGroup==md->visibleMemberGroup(sectionPerType) /*&& (hasDocs || !Config::instance()->getBool("HIDE_UNDOC_MEMBERS"))*/)
{
// filter out invisible enums
- if ( !Config::hideMemberFlag || // do not hide undocumented members or
+ if ( !Config::instance()->getBool("HIDE_UNDOC_MEMBERS") || // do not hide undocumented members or
!md->documentation().isEmpty() || // member has detailed descr. or
md->hasDocumentedEnumValues() || // member has documented enum vales.
(
!md->briefDescription().isEmpty() &&
- Config::briefMemDescFlag // brief descr. is shown or
+ Config::instance()->getBool("BRIEF_MEMBER_DESC") // brief descr. is shown or
)
)
{
@@ -290,7 +290,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,
{
if (md->isLinkableInProject() || md->hasDocumentedEnumValues())
{
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <member kind=\"enumeration\">" << endl;
Doxygen::tagFile << " <name>" << convertToXML(md->name()) << "</name>" << endl;
@@ -319,8 +319,8 @@ void MemberList::writePlainDeclarations(OutputList &ol,
while (fmd)
{
/* in html we start a new line after a number of items */
- if (fmdl->count()>(uint)Config::enumValuesPerLine
- && (enumMemCount%(uint)Config::enumValuesPerLine)==0
+ if (fmdl->count()>(uint)Config::instance()->getInt("ENUM_VALUES_PER_LINE")
+ && (enumMemCount%(uint)Config::instance()->getInt("ENUM_VALUES_PER_LINE"))==0
)
{
typeDecl.pushGeneratorState();
@@ -332,7 +332,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,
if (fmd->hasDocumentation()) // enum value has docs
{
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <member kind=\"enumvalue\">" << endl;
Doxygen::tagFile << " <name>" << convertToXML(fmd->name()) << "</name>" << endl;
@@ -361,7 +361,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,
typeDecl.enable(OutputGenerator::Man);
enumMemCount++;
}
- if (fmdl->count()>(uint)Config::enumValuesPerLine)
+ if (fmdl->count()>(uint)Config::instance()->getInt("ENUM_VALUES_PER_LINE"))
{
typeDecl.pushGeneratorState();
typeDecl.disableAllBut(OutputGenerator::Html);
@@ -395,7 +395,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,
ol.insertMemberAlign();
ol+=typeDecl; // append the enum values.
ol.endMemberItem(FALSE);
- if (!md->briefDescription().isEmpty() && Config::briefMemDescFlag)
+ if (!md->briefDescription().isEmpty() && Config::instance()->getBool("BRIEF_MEMBER_DESC"))
{
ol.startMemberDescription();
parseDoc(ol,
@@ -460,11 +460,13 @@ void MemberList::writePlainDeclarations(OutputList &ol,
{
QCString type=md->typeString();
//printf("Friend: type=%s name=%s\n",type.data(),md->name().data());
- if (md->hasDocumentation() && type!="friend class")
+ bool isFriendClass = type=="friend class";
+ if (!isFriendClass)
{
md->writeDeclaration(ol,cd,nd,fd,gd,inGroup);
}
- else // friend is undocumented as a member but it is a class,
+ else // isFriendClass
+ // friend is undocumented as a member but it is a class,
// so generate a link to the class if that is documented.
{
ClassDef *cd=getClass(md->name());
@@ -484,7 +486,7 @@ void MemberList::writePlainDeclarations(OutputList &ol,
ol.writeObjectLink(cd->getReference(),cd->getOutputFileBase(),0,cd->name());
ol.endMemberItem(FALSE);
}
- else if (!Config::hideMemberFlag) // no documentation
+ else if (!Config::instance()->getBool("HIDE_UNDOC_MEMBERS")) // no documentation
{
ol.startMemberItem(0);
ol.docify("class ");
diff --git a/src/message.cpp b/src/message.cpp
index 57aba79..29f4d31 100644
--- a/src/message.cpp
+++ b/src/message.cpp
@@ -32,9 +32,9 @@ static FILE *warnFile = stderr;
void initWarningFormat()
{
- int filePos = Config::warnFormat.find("$file");
- int linePos = Config::warnFormat.find("$line");
- int textPos = Config::warnFormat.find("$text");
+ int filePos = Config::instance()->getString("WARN_FORMAT").find("$file");
+ int linePos = Config::instance()->getString("WARN_FORMAT").find("$line");
+ int textPos = Config::instance()->getString("WARN_FORMAT").find("$text");
// sort items on position (there are 6 cases)
warnFormatOrder = 1;
@@ -68,7 +68,7 @@ void initWarningFormat()
substitute(
substitute(
substitute(
- Config::warnFormat,
+ Config::instance()->getString("WARN_FORMAT"),
"$file","%s"
),
"$text","%s"
@@ -81,16 +81,16 @@ void initWarningFormat()
// replace(QRegExp("\\$line"),"%d")+
// '\n';
- if (!Config::warnLogFile.isEmpty())
+ if (!Config::instance()->getString("WARN_LOGFILE").isEmpty())
{
- warnFile = fopen(Config::warnLogFile,"w");
+ warnFile = fopen(Config::instance()->getString("WARN_LOGFILE"),"w");
}
}
void msg(const char *fmt, ...)
{
- if (!Config::quietFlag)
+ if (!Config::instance()->getBool("QUIET"))
{
va_list args;
va_start(args, fmt);
@@ -101,9 +101,9 @@ void msg(const char *fmt, ...)
void warn(const char *file,int line,const char *fmt, ...)
{
- if (Config::warningFlag)
+ if (Config::instance()->getBool("WARNINGS"))
{
- if (file==0) file="<unknwon>";
+ if (file==0) file="<unknown>";
char text[4096];
va_list args;
va_start(args, fmt);
@@ -125,7 +125,7 @@ void warn(const char *file,int line,const char *fmt, ...)
void warn_cont(const char *fmt, ...)
{
- if (Config::warningFlag)
+ if (Config::instance()->getBool("WARNINGS"))
{
va_list args;
va_start(args, fmt);
@@ -136,7 +136,7 @@ void warn_cont(const char *fmt, ...)
void warn_undoc(const char *file,int line,const char *fmt, ...)
{
- if (Config::warningUndocFlag)
+ if (Config::instance()->getBool("WARN_IF_UNDOCUMENTED"))
{
if (file==0) file="<unknwon>";
char text[4096];
diff --git a/src/namespacedef.cpp b/src/namespacedef.cpp
index 7dc3023..ff70859 100644
--- a/src/namespacedef.cpp
+++ b/src/namespacedef.cpp
@@ -68,7 +68,7 @@ void NamespaceDef::insertUsedFile(const char *f)
{
if (files.find(f)==-1)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
files.inSort(f);
else
files.append(f);
@@ -79,7 +79,7 @@ void NamespaceDef::insertClass(ClassDef *cd)
{
if (classDict->find(cd->name())==0)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
classList->inSort(cd);
else
classList->append(cd);
@@ -131,43 +131,43 @@ void NamespaceDef::insertMember(MemberDef *md)
switch(md->memberType())
{
case MemberDef::Variable:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
varMembers.inSort(md);
else
varMembers.append(md);
break;
case MemberDef::Function:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
funcMembers.inSort(md);
else
funcMembers.append(md);
break;
case MemberDef::Typedef:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
typedefMembers.inSort(md);
else
typedefMembers.append(md);
break;
case MemberDef::Enumeration:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
enumMembers.inSort(md);
else
enumMembers.append(md);
break;
case MemberDef::EnumValue:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
enumValMembers.inSort(md);
else
enumValMembers.append(md);
break;
case MemberDef::Prototype:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
protoMembers.inSort(md);
else
protoMembers.append(md);
break;
case MemberDef::Define:
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
defineMembers.inSort(md);
else
defineMembers.append(md);
@@ -198,7 +198,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
parseText(ol,theTranslator->trNamespaceReference(name()));
endTitle(ol,getOutputFileBase(),name());
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <compound kind=\"namespace\">" << endl;
Doxygen::tagFile << " <name>" << convertToXML(name()) << "</name>" << endl;
@@ -241,7 +241,7 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
allMemberList.writeDeclarations(ol,0,this,0,0,0,0);
ol.endMemberSections();
- if ((!briefDescription().isEmpty() && Config::repeatBriefFlag) ||
+ if ((!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF")) ||
!documentation().isEmpty())
{
ol.writeRuler();
@@ -256,11 +256,11 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
parseText(ol,theTranslator->trDetailedDescription());
ol.endGroupHeader();
ol.startTextBlock();
- if (!briefDescription().isEmpty() && Config::repeatBriefFlag)
+ if (!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF"))
{
ol+=briefOutput;
}
- if (!briefDescription().isEmpty() && Config::repeatBriefFlag &&
+ if (!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF") &&
!documentation().isEmpty())
{
ol.newParagraph();
@@ -350,9 +350,9 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
ol.startGroupHeader();
parseText(ol,theTranslator->trAuthor());
ol.endGroupHeader();
- parseText(ol,theTranslator->trGeneratedAutomatically(Config::projectName));
+ parseText(ol,theTranslator->trGeneratedAutomatically(Config::instance()->getString("PROJECT_NAME")));
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
writeDocAnchorsToTagFile();
Doxygen::tagFile << " </compound>" << endl;
diff --git a/src/outputgen.h b/src/outputgen.h
index 06ae375..9ec3edf 100644
--- a/src/outputgen.h
+++ b/src/outputgen.h
@@ -223,7 +223,7 @@ class BaseOutputDocInterface
virtual void lineBreak() = 0;
virtual void addIndexItem(const char *s1,const char *s2) = 0;
virtual void writeFormula(const char *,const char *) = 0;
- virtual void writeNonBreakableSpace() = 0;
+ virtual void writeNonBreakableSpace(int) = 0;
virtual void startImage(const char *,const char *,bool) = 0;
virtual void endImage(bool) = 0;
virtual void startDescTable() = 0;
diff --git a/src/outputlist.h b/src/outputlist.h
index 3a6898d..abbe8f8 100644
--- a/src/outputlist.h
+++ b/src/outputlist.h
@@ -353,8 +353,8 @@ class OutputList : public OutputDocInterface
{ forall(&OutputGenerator::endQuickIndexItem); }
void writeFormula(const char *n,const char *t)
{ forall(&OutputGenerator::writeFormula,n,t); }
- void writeNonBreakableSpace()
- { forall(&OutputGenerator::writeNonBreakableSpace); }
+ void writeNonBreakableSpace(int num)
+ { forall(&OutputGenerator::writeNonBreakableSpace,num); }
void startImage(const char *n,const char *s,bool c)
{ forall(&OutputGenerator::startImage,n,s,c); }
void endImage(bool c)
diff --git a/src/packagedef.cpp b/src/packagedef.cpp
index 4f2ae02..c6a8bfb 100644
--- a/src/packagedef.cpp
+++ b/src/packagedef.cpp
@@ -42,7 +42,7 @@ PackageDef::~PackageDef()
void PackageDef::addClass(const ClassDef *def)
{
- if (Config::sortMembersFlag)
+ if (Config::instance()->getBool("SORT_MEMBER_DOCS"))
classList->inSort(def);
else
classList->append(def);
@@ -73,7 +73,7 @@ void PackageDef::writeDocumentation(OutputList &ol)
ol.popGeneratorState();
}
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
Doxygen::tagFile << " <compound kind=\"package\">" << endl;
}
@@ -86,7 +86,7 @@ void PackageDef::writeDocumentation(OutputList &ol)
classList->writeDeclaration(ol,&ct,theTranslator->trClasses());
ol.endMemberSections();
- if (!Config::genTagFile.isEmpty())
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty())
{
writeDocAnchorsToTagFile();
Doxygen::tagFile << " </compound>" << endl;
@@ -105,7 +105,7 @@ void PackageDef::writeDocumentation(OutputList &ol)
ol.endGroupHeader();
// repeat brief description
- if (!briefDescription().isEmpty() && Config::repeatBriefFlag)
+ if (!briefDescription().isEmpty() && Config::instance()->getBool("REPEAT_BRIEF"))
{
ol+=briefOutput;
ol.newParagraph();
diff --git a/src/page.h b/src/page.h
index c448631..c644a4d 100644
--- a/src/page.h
+++ b/src/page.h
@@ -76,7 +76,7 @@ class PageInfo
void writeDocAnchorsToTagFile()
{
- if (!Config::genTagFile.isEmpty() && sectionDict)
+ if (!Config::instance()->getString("GENERATE_TAGFILE").isEmpty() && sectionDict)
{
QDictIterator<SectionInfo> sdi(*sectionDict);
SectionInfo *si;
diff --git a/src/pre.l b/src/pre.l
index e3e378c..b2b9a2b 100644
--- a/src/pre.l
+++ b/src/pre.l
@@ -34,6 +34,7 @@
#include <qdict.h>
#include <qregexp.h>
#include <qfileinfo.h>
+#include <qdir.h>
#include "pre.h"
#include "constexp.h"
@@ -95,6 +96,10 @@ static QCString g_guardExpr;
static int g_curlyCount;
static bool g_nospaces; // add extra spaces during macro expansion
+static bool g_macroExpansion; // from the configuration
+static bool g_expandOnlyPredef; // from the configuration
+
+
static void setFileName(const char *name)
{
bool ambig;
@@ -156,8 +161,40 @@ static Define *isDefined(const char *name)
return 0;
}
-static FILE *findFile(const char *fileName)
+static FILE *checkAndOpenFile(const QCString &absName)
{
+ FILE *f = 0;
+ QFileInfo fi(absName);
+ if (fi.exists() && fi.isFile())
+ {
+ if (!Config::instance()->getString("INPUT_FILTER").isEmpty())
+ {
+ QCString cmd = Config::instance()->getString("INPUT_FILTER")+" "+absName;
+ f=popen(cmd,"r");
+ if (!f) err("Error: could not execute filter %s\n",cmd.data());
+ }
+ else
+ {
+ f=fopen(absName,"r");
+ if (!f) err("Error: could not open file %s for reading\n",absName.data());
+ }
+ }
+ return f;
+}
+
+static FILE *findFile(const char *fileName,bool localInclude)
+{
+ if (localInclude && g_yyFileDef)
+ {
+ QCString absName = g_yyFileDef->getPath()+"/"+fileName;
+ FILE *f = checkAndOpenFile(absName);
+ if (f)
+ {
+ setFileName(absName);
+ g_yyLineNr=1;
+ return f;
+ }
+ }
if (g_pathList==0)
{
return 0;
@@ -165,29 +202,15 @@ static FILE *findFile(const char *fileName)
char *s=g_pathList->first();
while (s)
{
- QCString absName=(QCString)s+"/"+fileName;
- QFileInfo fi(absName);
- if (fi.exists() && fi.isFile())
+ QCString absName = (QCString)s+"/"+fileName;
+ FILE *f = checkAndOpenFile(absName);
+ if (f)
{
- FILE *f;
- if (!Config::inputFilter.isEmpty())
- {
- QCString cmd = Config::inputFilter+" "+absName;
- f=popen(cmd,"r");
- if (!f) err("Error: could not execute filter %s\n",cmd.data());
- }
- else
- {
- f=fopen(absName,"r");
- if (!f) err("Error: could not open file %s for reading\n",absName.data());
- }
- if (f)
- {
- setFileName(absName);
- g_yyLineNr=1;
- return f;
- }
+ setFileName(absName);
+ g_yyLineNr=1;
+ return f;
}
+
s=g_pathList->next();
}
return 0;
@@ -869,7 +892,7 @@ static inline void outputArray(const char *a,int len)
static void readIncludeFile(const QCString &inc)
{
- if (!Config::searchIncludeFlag) return; // do not read include files
+ if (!Config::instance()->getBool("SEARCH_INCLUDES")) return; // do not read include files
uint i=0;
// find the start of the include file name
@@ -892,8 +915,9 @@ static void readIncludeFile(const QCString &inc)
FILE *f;
QCString oldFileName = g_yyFileName.copy();
FileDef *oldFileDef = g_yyFileDef;
+ int oldLineNr = g_yyLineNr;
//printf("Searching for `%s'\n",incFileName.data());
- if ((f=findFile(incFileName))) // see if the include file can be found
+ if ((f=findFile(incFileName,localInclude))) // see if the include file can be found
{
if (Debug::isFlagSet(Debug::Preprocessor))
{
@@ -910,15 +934,21 @@ static void readIncludeFile(const QCString &inc)
g_yyFileDef->addIncludedByDependency(oldFileDef,oldFileDef->name(),localInclude);
}
}
- // store the state of the old file
FileState *fs=new FileState;
fs->bufState=YY_CURRENT_BUFFER;
- fs->lineNr=g_yyLineNr;
+ fs->lineNr=oldLineNr;
fs->fileName=oldFileName;
fs->filePtr=f;
// push the state on the stack
g_includeStack.push(fs);
// set the scanner to the include file
+
+ // TODO: Enable this to deal with file changes due to
+ // #include's within { .. } blocks
+ //QCString lineStr;
+ //lineStr.sprintf("# 1 \"%s\" 1\n",g_yyFileName.data());
+ //outputArray(lineStr.data(),lineStr.length());
+
preYYin=f;
yy_switch_to_buffer(yy_create_buffer(preYYin, YY_BUF_SIZE));
}
@@ -1037,7 +1067,7 @@ BN [ \t\r\n]
outputChar(*yytext);
BEGIN( CopyString );
}
-<CopyString>[^\"\\]+ {
+<CopyString>[^\"\\\r\n]+ {
outputArray(yytext,yyleng);
}
<CopyString>\\. {
@@ -1051,10 +1081,10 @@ BN [ \t\r\n]
Define *def=0;
//printf("Search for define %s\n",yytext);
if ((g_includeStack.isEmpty() || g_curlyCount>0) &&
- Config::macroExpansionFlag &&
+ g_macroExpansion &&
/* (expandDefine=fileDefineCache->findDefine(g_yyFileName,yytext)) */
(def=g_fileDefineDict->find(yytext)) &&
- (!Config::onlyPredefinedFlag || def->isPredefined)
+ (!g_expandOnlyPredef || def->isPredefined)
)
{
//printf("Found it!\n");
@@ -1081,10 +1111,10 @@ BN [ \t\r\n]
Define *def=0;
//printf("Search for define %s\n",yytext);
if ((g_includeStack.isEmpty() || g_curlyCount>0) &&
- Config::macroExpansionFlag &&
+ g_macroExpansion &&
(def=g_fileDefineDict->find(yytext)) &&
def->nargs==-1 &&
- (!Config::onlyPredefinedFlag || def->isPredefined)
+ (!g_expandOnlyPredef || def->isPredefined)
)
{
//printf("Found it!\n");
@@ -1162,8 +1192,8 @@ BN [ \t\r\n]
<ReadString>. {
g_defArgsStr+=*yytext;
}
-<Command>"include"{B}*/{ID} {
- if (Config::macroExpansionFlag)
+<Command>"include"{B}+/{ID} {
+ if (g_macroExpansion)
BEGIN(IncludeID);
}
<Command>"include"{B}*[<"] {
@@ -1396,14 +1426,6 @@ BN [ \t\r\n]
}
<Include>[^\">\n]+[\">] {
g_incName+=yytext;
- //int l=incName.length();
- //QCString incFileName=incName.left(l-1);
- //if (fileDefineCache->fileCached(incFileName))
- //{
- // printf("file already cached!\n");
- // fileDefineCache->merge(incFileName,g_yyFileName);
- //}
- //else if ((f=findFile(incFileName)))
readIncludeFile(g_incName);
BEGIN(Start);
@@ -1457,7 +1479,7 @@ BN [ \t\r\n]
//{
// addDefine();
//}
- if (/*!Config::onlyPredefinedFlag &&*/ (def=g_fileDefineDict->find(g_defName))==0)
+ if ((def=g_fileDefineDict->find(g_defName))==0)
{
g_fileDefineDict->insert(g_defName,newDefine());
}
@@ -1491,12 +1513,14 @@ BN [ \t\r\n]
g_quoteArg=FALSE;
BEGIN(DefineText);
}
-<DefineArg>{ID}("..."?) {
+<DefineArg>{ID}{B}*("..."?) {
//printf("Define addArg(%s)\n",yytext);
QCString argName=yytext;
g_defVarArgs = yytext[yyleng-1]=='.';
if (g_defVarArgs) // strip ellipsis
- argName=argName.left(argName.length()-3);
+ {
+ argName=argName.left(argName.length()-3).stripWhiteSpace();
+ }
g_defArgsStr+=yytext;
g_argDict->insert(argName,new int(g_defArgs));
g_defArgs++;
@@ -1679,7 +1703,7 @@ BN [ \t\r\n]
{
FileState *fs=g_includeStack.pop();
//fileDefineCache->merge(g_yyFileName,fs->fileName);
- if (Config::inputFilter.isEmpty())
+ if (Config::instance()->getString("INPUT_FILTER").isEmpty())
fclose(fs->filePtr);
else
pclose(fs->filePtr);
@@ -1689,7 +1713,16 @@ BN [ \t\r\n]
g_yyLineNr=fs->lineNr;
setFileName(fs->fileName.copy());
//printf("######## FileName %s\n",g_yyFileName.data());
+
+ // TODO: Enable this to deal with file changes due to
+ // #include's within { .. } blocks
+ //QCString lineStr;
+ //lineStr.sprintf("# %d \"%s\" 2",g_yyLineNr,g_yyFileName.data());
+ //outputArray(lineStr.data(),lineStr.length());
+
delete fs; fs=0;
+
+
}
}
<*>"/*" {
@@ -1813,6 +1846,8 @@ void preprocessFile(const char *fileName,BufStr &output)
uint orgOffset=output.curPos();
//#endif
+ g_macroExpansion = Config::instance()->getBool("MACRO_EXPANSION");
+ g_expandOnlyPredef = Config::instance()->getBool("EXPAND_ONLY_PREDEF");
g_curlyCount=0;
g_nospaces=FALSE;
g_outputBuf=&output;
@@ -1824,7 +1859,7 @@ void preprocessFile(const char *fileName,BufStr &output)
g_expandedDict->clear();
// add predefined macros
- char *defStr = Config::predefined.first();
+ char *defStr = Config::instance()->getList("PREDEFINED").first();
while (defStr)
{
//printf("Predefined: `%s'\n",defStr);
@@ -1913,10 +1948,11 @@ void preprocessFile(const char *fileName,BufStr &output)
// def->name.data(),def->definition.data(),def->nargs);
}
- defStr=Config::predefined.next();
+ defStr=Config::instance()->getList("PREDEFINED").next();
}
- if (Config::inputFilter.isEmpty())
+ QCString &inputFilter = Config::instance()->getString("INPUT_FILTER");
+ if (inputFilter.isEmpty())
{
preYYin = fopen(fileName,"r");
if (!preYYin)
@@ -1927,7 +1963,7 @@ void preprocessFile(const char *fileName,BufStr &output)
}
else
{
- QCString cmd = Config::inputFilter+" "+fileName;
+ QCString cmd = inputFilter+" "+fileName;
preYYin = popen(cmd,"r");
if (!preYYin)
{
@@ -1945,7 +1981,7 @@ void preprocessFile(const char *fileName,BufStr &output)
g_guardExpr.resize(0);
preYYlex();
- if (Config::inputFilter.isEmpty())
+ if (inputFilter.isEmpty())
fclose(preYYin);
else
pclose(preYYin);
diff --git a/src/rtfgen.cpp b/src/rtfgen.cpp
index 9b9196f..2ce7b48 100644
--- a/src/rtfgen.cpp
+++ b/src/rtfgen.cpp
@@ -81,6 +81,11 @@ static QCString formatBmkStr(const char *name)
}
p++;
}
+ // Word doesn't like bookmarks that do not start with a alphabetical char
+ if (!isalpha(result.at(0)))
+ {
+ result.prepend("BM");
+ }
}
return result;
}
@@ -97,7 +102,7 @@ static QCString dateToRTFDateString()
RTFGenerator::RTFGenerator() : OutputGenerator()
{
- dir=Config::rtfOutputDir;
+ dir=Config::instance()->getString("RTF_OUTPUT");
col=0;
//insideTabbing=FALSE;
m_listLevel = 0;
@@ -690,7 +695,7 @@ static void loadExtensions(const char *name)
void RTFGenerator::init()
{
- QCString dir=Config::rtfOutputDir;
+ QCString dir=Config::instance()->getString("RTF_OUTPUT");
QDir d(dir);
if (!d.exists() && !d.mkdir(dir))
{
@@ -711,13 +716,17 @@ void RTFGenerator::init()
}
// overwrite some (or all) definitions from file
- if (!Config::rtfStylesheetFile.isEmpty())
- loadStylesheet(Config::rtfStylesheetFile, Rtf_Style);
+ QCString &rtfStyleSheetFile = Config::instance()->getString("RTF_STYLESHEET_FILE");
+ if (!rtfStyleSheetFile.isEmpty())
+ {
+ loadStylesheet(rtfStyleSheetFile, Rtf_Style);
+ }
// If user has defined an extension file, load its contents.
- if (Config::rtfExtensionsFile)
+ QCString &rtfExtensionsFile = Config::instance()->getString("RTF_EXTENSIONS_FILE");
+ if (!rtfExtensionsFile.isEmpty())
{
- loadExtensions(Config::rtfExtensionsFile);
+ loadExtensions(rtfExtensionsFile);
}
}
@@ -811,7 +820,7 @@ void RTFGenerator::beginRTFChapter()
t << Rtf_Style_Reset;
// if we are compact, no extra page breaks...
- if (Config::compactRTFFlag)
+ if (Config::instance()->getBool("COMPACT_RTF"))
{
// t <<"\\sect\\sectd\\sbknone\n";
t <<"\\sect\\sbknone\n";
@@ -831,7 +840,7 @@ void RTFGenerator::beginRTFSection()
t << Rtf_Style_Reset;
// if we are compact, no extra page breaks...
- if (Config::compactRTFFlag)
+ if (Config::instance()->getBool("COMPACT_RTF"))
{
// t <<"\\sect\\sectd\\sbknone\n";
t <<"\\sect\\sbknone\n";
@@ -1042,7 +1051,7 @@ void RTFGenerator::endIndexSection(IndexSections is)
// User has overridden document title in extensions file
t << "}" << title;
else
- t << "}" << Config::projectName;
+ t << "}" << Config::instance()->getString("PROJECT_NAME");
break;
case isTitlePageAuthor:
{
@@ -1087,7 +1096,7 @@ void RTFGenerator::endIndexSection(IndexSections is)
t << Rtf_Style_Reset << Rtf_Style["SubTitle"]->reference << endl; // set to subtitle style
t << "{\\field\\fldedit {\\*\\fldinst AUTHOR \\\\*MERGEFORMAT}{\\fldrslt AUTHOR}}\\par" << endl;
- t << "Version " << Config::projectNumber << "\\par";
+ t << "Version " << Config::instance()->getString("PROJECT_NUMBER") << "\\par";
t << "{\\field\\fldedit {\\*\\fldinst CREATEDATE \\\\*MERGEFORMAT}"
"{\\fldrslt CREATEDATE}}\\par"<<endl;
t << "\\page\\page";
@@ -1307,7 +1316,7 @@ void RTFGenerator::endIndexSection(IndexSections is)
if (!pi->inGroup && !pi->isReference())
{
QCString pageName;
- if (Config::caseSensitiveNames)
+ if (Config::instance()->getBool("CASE_SENSE_NAMES"))
pageName=pi->name.copy();
else
pageName=pi->name.lower();
@@ -1476,7 +1485,7 @@ void RTFGenerator::writeIndexItem(const char *ref,const char *fn,
void RTFGenerator::startHtmlLink(const char *url)
{
- if (Config::rtfHyperFlag)
+ if (Config::instance()->getBool("RTF_HYPERLINKS"))
{
t << "{\\field {\\*\\fldinst { HYPERLINK \\\\l \"";
t << url;
@@ -1491,7 +1500,7 @@ void RTFGenerator::startHtmlLink(const char *url)
void RTFGenerator::endHtmlLink()
{
- if (Config::rtfHyperFlag)
+ if (Config::instance()->getBool("RTF_HYPERLINKS"))
{
t << "}}}" << endl;
}
@@ -1514,7 +1523,7 @@ void RTFGenerator::writeStartAnnoItem(const char *,const char *f,
DBG_RTF(t << "{\\comment (writeStartAnnoItem)}" << endl)
t << "{\\b ";
if (path) docify(path);
- if (f && Config::rtfHyperFlag)
+ if (f && Config::instance()->getBool("RTF_HYPERLINKS"))
{
t << "{\\field {\\*\\fldinst { HYPERLINK \\\\l \"";
t << formatBmkStr(f);
@@ -1589,7 +1598,7 @@ void RTFGenerator::endSubsubsection()
void RTFGenerator::startTextLink(const char *f,const char *anchor)
{
- if (Config::rtfHyperFlag)
+ if (Config::instance()->getBool("RTF_HYPERLINKS"))
{
QCString ref;
if (f)
@@ -1611,7 +1620,7 @@ void RTFGenerator::startTextLink(const char *f,const char *anchor)
void RTFGenerator::endTextLink()
{
- if (Config::rtfHyperFlag)
+ if (Config::instance()->getBool("RTF_HYPERLINKS"))
{
t << "}}}" << endl;
}
@@ -1620,7 +1629,7 @@ void RTFGenerator::endTextLink()
void RTFGenerator::writeObjectLink(const char *ref, const char *f,
const char *anchor, const char *text)
{
- if (!ref && Config::rtfHyperFlag)
+ if (!ref && Config::instance()->getBool("RTF_HYPERLINKS"))
{
QCString refName;
if (f)
@@ -1676,7 +1685,7 @@ void RTFGenerator::endPageRef(const char *clname, const char *anchor)
void RTFGenerator::writeCodeLink(const char *ref,const char *f,
const char *anchor,const char *name)
{
- if (!ref && Config::rtfHyperFlag)
+ if (!ref && Config::instance()->getBool("RTF_HYPERLINKS"))
{
QCString refName;
if (f)
@@ -1731,7 +1740,7 @@ void RTFGenerator::endTitleHead(const char *fileName,const char *name)
// writeAnchor(0,name);
//}
//
- //if (Config::rtfHyperFlag && fileName)
+ //if (Config::instance()->getBool("RTF_HYPERLINKS") && fileName)
//{
writeAnchor(fileName,0);
//}
@@ -1741,7 +1750,7 @@ void RTFGenerator::endTitleHead(const char *fileName,const char *name)
void RTFGenerator::startTitle()
{
DBG_RTF(t <<"{\\comment startTitle}" << endl)
- if (Config::compactRTFFlag)
+ if (Config::instance()->getBool("COMPACT_RTF"))
beginRTFSection();
else
beginRTFChapter();
@@ -2045,7 +2054,7 @@ void RTFGenerator::codify(const char *str)
c=*p++;
switch(c)
{
- case '\t': spacesToNextTabStop = Config::tabSize - (col%Config::tabSize);
+ case '\t': spacesToNextTabStop = Config::instance()->getInt("TAB_SIZE") - (col%Config::instance()->getInt("TAB_SIZE"));
t << spaces.left(spacesToNextTabStop);
col+=spacesToNextTabStop;
break;
@@ -2142,7 +2151,7 @@ void RTFGenerator::endCodeFragment()
m_omitParagraph = TRUE;
}
-void RTFGenerator::writeNonBreakableSpace()
+void RTFGenerator::writeNonBreakableSpace(int)
{
t << "\\~ ";
}
@@ -2519,7 +2528,7 @@ void RTFGenerator::endDotGraph(DotClassGraph &g)
{
newParagraph();
- g.writeGraph(t,GIF,Config::rtfOutputDir,TRUE,FALSE);
+ g.writeGraph(t,GIF,Config::instance()->getString("RTF_OUTPUT"),TRUE,FALSE);
// display the file
t << "{" << endl;
@@ -2538,7 +2547,7 @@ void RTFGenerator::endInclDepGraph(DotInclDepGraph &g)
{
newParagraph();
- g.writeGraph(t,GIF,Config::rtfOutputDir,FALSE);
+ g.writeGraph(t,GIF,Config::instance()->getString("RTF_OUTPUT"),FALSE);
//QCString diskName = g.diskName();
diff --git a/src/rtfgen.h b/src/rtfgen.h
index 0fda052..2e8bff4 100644
--- a/src/rtfgen.h
+++ b/src/rtfgen.h
@@ -190,7 +190,7 @@ class RTFGenerator : public OutputGenerator
void startQuickIndexItem(const char *,const char *) {}
void endQuickIndexItem() {}
void writeFormula(const char *,const char *);
- void writeNonBreakableSpace();
+ void writeNonBreakableSpace(int);
void startImage(const char *,const char *,bool);
void endImage(bool);
diff --git a/src/scanner.l b/src/scanner.l
index 6cc0da8..204c32e 100644
--- a/src/scanner.l
+++ b/src/scanner.l
@@ -170,6 +170,7 @@ static void initParser()
isTypedef = FALSE;
autoGroupNameStack.clear();
insideTryBlock = FALSE;
+ insideIDL = FALSE;
}
static void initEntry()
@@ -333,15 +334,35 @@ static void checkDocs()
static QCString extractName(const QCString &s)
{
- static const QRegExp id("[a-z_A-Z][a-z_A-Z0-9]*");
- int i,p=0,l;
- while ((i=id.match(s,p,&l))!=-1)
- {
- QCString idstr=s.mid(i,l);
- if (idstr!="struct" && idstr!="class" && idstr!="union") return idstr;
- p=i+l;
- }
- return "";
+ //static const QRegExp id("[a-z_A-Z][a-z_A-Z0-9]*");
+ //int i,p=0,l;
+ //while ((i=id.match(s,p,&l))!=-1)
+ //{
+ // QCString idstr=s.mid(i,l);
+ // if (idstr!="struct" && idstr!="class" && idstr!="union")
+ // {
+ //
+ // return idstr;
+ // }
+ // p=i+l;
+ //}
+ //return "";
+ QCString result=s;
+ if (result.left(7)=="struct ") result=result.right(result.length()-7);
+ if (result.left(6)=="class " ) result=result.right(result.length()-6);
+ if (result.left(6)=="union " ) result=result.right(result.length()-6);
+ int l=result.length()-1;
+ while (l>=0 &&
+ (result.at(l)=='*' || result.at(l)==' ' || isspace(result.at(l)))
+ ) l--;
+ return removeRedundantWhiteSpace(result.left(l+1));
+}
+
+static void setContext()
+{
+ QCString fileName = yyFileName;
+ insideIDL = fileName.right(4)==".idl";
+ insideJava = fileName.right(5)==".java";
}
/* ----------------------------------------------------------------- */
@@ -430,6 +451,7 @@ TITLE [tT][iI][tT][lL][eE]
%x SkipSquare
%x TypedefName
%x TryFunctionBlock
+%x TryFunctionBlockEnd
%x Comment
%x Doc
%x JavaDoc
@@ -520,8 +542,7 @@ TITLE [tT][iI][tT][lL][eE]
for( i = 0 ; yytext[i+1] != 6 ; i++ )
yyFileName[i] = yytext[i+1] ;
yyFileName[i] = 0 ;
- insideIDL = i>4 && strcmp(&yyFileName[i-4],".idl")==0;
- insideJava = i>5 && strcmp(&yyFileName[i-5],".java")==0;
+ setContext();
msg("Parsing file %s...\n",yyFileName);
current_root = global_root ;
initParser();
@@ -567,7 +588,7 @@ TITLE [tT][iI][tT][lL][eE]
}
<NextSemi>"'"\\[0-7]{1,3}"'"
<NextSemi>"'"\\."'"
-<NextSemi>"'"."'"
+<NextSemi>"'".{1,4}"'"
<NextSemi>\" {
lastStringContext=NextSemi;
BEGIN(SkipString);
@@ -1080,13 +1101,17 @@ TITLE [tT][iI][tT][lL][eE]
<IDLUnionCase>":" { BEGIN(FindMembers); }
<IDLUnionCase>\n { yyLineNr++; }
<IDLUnionCase>.
-<TryFunctionBlock>\n
+<TryFunctionBlock>\n { yyLineNr++; }
<TryFunctionBlock>"{" {
curlyCount=0;
- lastCurlyContext = FindMembers ;
+ lastCurlyContext = TryFunctionBlockEnd ;
BEGIN( SkipCurly );
}
<TryFunctionBlock>.
+<TryFunctionBlockEnd>"catch" { BEGIN(TryFunctionBlock); }
+<TryFunctionBlockEnd>. { unput(*yytext);
+ BEGIN( FindMembers );
+ }
<EndCppQuote>")" {
insideCppQuote=FALSE;
BEGIN(FindMembers);
@@ -1166,7 +1191,7 @@ TITLE [tT][iI][tT][lL][eE]
current->brief.resize(0);
BEGIN(AfterDocLine);
}
- else if (yytext[yyleng-2]=='*' && Config::autoBriefFlag)
+ else if (yytext[yyleng-2]=='*' && Config::instance()->getBool("JAVADOC_AUTOBRIEF"))
{
current->brief.resize(0);
BEGIN(AfterDocBrief);
@@ -1186,7 +1211,7 @@ TITLE [tT][iI][tT][lL][eE]
current->brief.resize(0);
BEGIN(AfterDocLine);
}
- else if (yytext[yyleng-2]=='*' && Config::autoBriefFlag)
+ else if (yytext[yyleng-2]=='*' && Config::instance()->getBool("JAVADOC_AUTOBRIEF"))
{
current->brief.resize(0);
BEGIN(AfterDocBrief);
@@ -1212,7 +1237,7 @@ TITLE [tT][iI][tT][lL][eE]
current->brief.resize(0);
BEGIN(AfterDocLine);
}
- else if (yytext[yyleng-2]=='*' && Config::autoBriefFlag)
+ else if (yytext[yyleng-2]=='*' && Config::instance()->getBool("JAVADOC_AUTOBRIEF"))
{
current->brief.resize(0);
BEGIN(AfterDocBrief);
@@ -1285,7 +1310,7 @@ TITLE [tT][iI][tT][lL][eE]
}
<ReadInitializer>"'"\\[0-7]{1,3}"'"
<ReadInitializer>"'"\\."'"
-<ReadInitializer>"'"."'"
+<ReadInitializer>"'".{1,4}"'"
<ReadInitializer>\n {
current->initializer+=*yytext;
yyLineNr++;
@@ -1335,7 +1360,7 @@ TITLE [tT][iI][tT][lL][eE]
}
<CopyRound>"'"\\[0-7]{1,3}"'" { *pCopyRoundString+=yytext; }
<CopyRound>"'"\\."'" { *pCopyRoundString+=yytext; }
-<CopyRound>"'"."'" { *pCopyRoundString+=yytext; }
+<CopyRound>"'".{1,4}"'" { *pCopyRoundString+=yytext; }
<CopyRound>[^"'()\n]+ {
*pCopyRoundString+=yytext;
}
@@ -1358,7 +1383,7 @@ TITLE [tT][iI][tT][lL][eE]
}
<CopyCurly>"'"\\[0-7]{1,3}"'" { *pCopyCurlyString+=yytext; }
<CopyCurly>"'"\\."'" { *pCopyCurlyString+=yytext; }
-<CopyCurly>"'"."'" { *pCopyCurlyString+=yytext; }
+<CopyCurly>"'".{1,4}"'" { *pCopyCurlyString+=yytext; }
<CopyCurly>[^"'{}\/\n]+ {
*pCopyCurlyString+=yytext;
}
@@ -1515,9 +1540,9 @@ TITLE [tT][iI][tT][lL][eE]
lastContext = ReadBody ;
BEGIN( Comment ) ;
}
-<ReadBody>"'"\\[0-7]{1,3}"'" { current->program += yytext; }
-<ReadBody>"'"\\."'" { current->program += yytext; }
-<ReadBody>"'"."'" { current->program += yytext; }
+<ReadBody>"'"\\[0-7]{1,3}"'" { current->program += yytext; }
+<ReadBody>"'"\\."'" { current->program += yytext; }
+<ReadBody>"'".{1,4}"'" { current->program += yytext; }
<ReadBody>"{" { current->program += yytext ;
++curlyCount ;
}
@@ -1944,7 +1969,7 @@ TITLE [tT][iI][tT][lL][eE]
*copyArgString+=yytext;
fullArgString+=yytext;
}
-<ReadFuncArgType,ReadTempArgs,CopyArgRound,CopyArgSharp>"'"."'" {
+<ReadFuncArgType,ReadTempArgs,CopyArgRound,CopyArgSharp>"'".{1,4}"'" {
*copyArgString+=yytext;
fullArgString+=yytext;
}
@@ -2175,7 +2200,7 @@ TITLE [tT][iI][tT][lL][eE]
afterDocTerminator = '}';
if (yytext[yyleng-3]=='/')
BEGIN(AfterDocLine);
- else if (yytext[yyleng-2]=='*' && Config::autoBriefFlag)
+ else if (yytext[yyleng-2]=='*' && Config::instance()->getBool("JAVADOC_AUTOBRIEF"))
BEGIN(AfterDocBrief);
else
BEGIN(AfterDoc);
@@ -2192,7 +2217,7 @@ TITLE [tT][iI][tT][lL][eE]
<SkipCurly>"'"\\."'" {
//addToBody(yytext);
}
-<SkipCurly>"'"."'" {
+<SkipCurly>"'".{1,4}"'" {
//addToBody(yytext);
}
<SkipCurly>\" {
@@ -2288,7 +2313,8 @@ TITLE [tT][iI][tT][lL][eE]
BEGIN( ClassVar );
}
<ClassVar>{SCOPENAME}{BN}*/"(" {
- if (insideIDL && strncmp(yytext,"switch",6)==0)
+ err("Inside IDL = %d\n",insideIDL);
+ if (insideIDL && strncmp(yytext,"switch",6)==0 && !isId(yytext[6]))
{
// Corba IDL style union
roundCount=0;
@@ -2496,7 +2522,7 @@ TITLE [tT][iI][tT][lL][eE]
lastDocContext = YY_START;
if (current_root->section & Entry::SCOPE_MASK)
current->inside = current_root->name+"::";
- if (!Config::autoBriefFlag) // use the Qt style
+ if (!Config::instance()->getBool("JAVADOC_AUTOBRIEF")) // use the Qt style
{
tmpDocType=-1;
if (YY_START==ReadBody)
@@ -3496,7 +3522,7 @@ TITLE [tT][iI][tT][lL][eE]
newDocState();
}
<Doc>[a-z_A-Z0-9]+ { current->doc += yytext; }
-<Doc,AfterDoc,LineDoc,ClassDoc>("\\\\"|"@@") { current->doc += yytext; }
+<Doc,PageDoc,AfterDoc,LineDoc,ClassDoc>("\\\\"|"@@") { current->doc += yytext; }
<Doc>. { current->doc += *yytext; }
<DefLineDoc,LineDoc>. { current->brief += *yytext; }
<Doc>\n { yyLineNr++; current->doc += *yytext; }
@@ -3767,6 +3793,7 @@ static void parseCompounds(Entry *rt)
BEGIN( FindMembers ) ;
current_root = ce ;
strcpy( yyFileName, ce->fileName ) ;
+ setContext();
yyLineNr = ce->startLine ;
//printf("---> Inner block starts at line %d\n",yyLineNr);
//current->reset();
diff --git a/src/translator.h b/src/translator.h
index 59aad27..2764c03 100644
--- a/src/translator.h
+++ b/src/translator.h
@@ -169,7 +169,7 @@ class Translator
/*! header that is put before the list of member attributes. */
virtual QCString trMemberDataDocumentation()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "Field Documentation";
}
@@ -242,7 +242,7 @@ class Translator
/*! This is put above each page as a link to the list of annotated classes */
virtual QCString trCompoundList()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "Data Structures";
}
@@ -263,7 +263,7 @@ class Translator
/*! This is put above each page as a link to all members of compounds. */
virtual QCString trCompoundMembers()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "Data Fields";
}
@@ -276,7 +276,7 @@ class Translator
/*! This is put above each page as a link to all members of files. */
virtual QCString trFileMembers()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "Globals";
}
@@ -317,7 +317,7 @@ class Translator
virtual QCString trCompoundListDescription()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "Here are the data structures with brief descriptions:";
}
@@ -332,12 +332,41 @@ class Translator
virtual QCString trCompoundMembersDescription(bool extractAll)
{
QCString result="Here is a list of all ";
- if (!extractAll) result+="documented ";
- result+="class members with links to ";
+ if (!extractAll)
+ {
+ result+="documented ";
+ }
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ result+="struct and union fields";
+ }
+ else
+ {
+ result+="class members";
+ }
+ result+=" with links to ";
if (extractAll)
- result+="the class documentation for each member:";
+ {
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ result+="the struct/union documentation for each field:";
+ }
+ else
+ {
+ result+="the class documentation for each member:";
+ }
+ }
else
- result+="the classes they belong to:";
+ {
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
+ {
+ result+="the structures/unions they belong to:";
+ }
+ else
+ {
+ result+="the classes they belong to:";
+ }
+ }
return result;
}
@@ -347,7 +376,7 @@ class Translator
QCString result="Here is a list of all ";
if (!extractAll) result+="documented ";
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
result+="functions, variables, defines, enums, and typedefs";
}
@@ -409,7 +438,7 @@ class Translator
*/
virtual QCString trCompoundIndex()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "Data Structure Index";
}
@@ -552,7 +581,7 @@ class Translator
*/
virtual QCString trCompounds()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "Data Structures";
}
@@ -992,7 +1021,7 @@ class Translator
}
virtual QCString trPublicAttribs()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "Data Fields";
}
@@ -1195,7 +1224,7 @@ class Translator
/*! Used for Java classes in the summary section of Java packages */
virtual QCString trClasses()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "Data Structures";
}
diff --git a/src/translator_br.h b/src/translator_br.h
new file mode 100644
index 0000000..4919737
--- /dev/null
+++ b/src/translator_br.h
@@ -0,0 +1,889 @@
+/******************************************************************************
+ *
+ *
+ *
+ * Copyright (C) 1997-2001 by Dimitri van Heesch.
+ *
+ * Permission to use, copy, modify, and distribute this software and its
+ * documentation under the terms of the GNU General Public License is hereby
+ * granted. No representations are made about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
+ * See the GNU General Public License for more details.
+ *
+ * Documents produced by Doxygen are derivative works derived from the
+ * input used in their production; they are not affected by this license.
+ *
+ * The translation into Brasilian Portuguese was provided by
+ * Fabio "FJTC" Jun Takada Chino <chino@grad.icmc.sc.usp.br>
+ * Based on the original translation to Portuguese provided by
+ * Rui Godinho Lopes <ruiglopes@yahoo.com>
+ */
+
+#ifndef TRANSLATOR_BR_H
+#define TRANSLATOR_BR_H
+
+#include "translator.h"
+
+/*
+* I used the name brazilian in language.cpp.
+*/
+class TranslatorBrazilianPortuguese : public Translator
+{
+ public:
+ QCString idLanguage()
+ { return "brazilian"; }
+ /*! returns the name of the package that is included by LaTeX */
+ QCString latexBabelPackage()
+ { return "portuguese_br"; }
+
+ /*! used in the compound documentation before a list of related functions. */
+ QCString trRelatedFunctions()
+ { return "Funções relacionadas"; }
+
+ /*! subscript for the related functions. */
+ QCString trRelatedSubscript()
+ { return "(Note que não são funções membro)"; }
+
+ /*! header that is put before the detailed description of files, classes and namespaces. */
+ QCString trDetailedDescription()
+ { return "Descrição"; }
+
+ /*! header that is put before the list of typedefs. */
+ QCString trMemberTypedefDocumentation()
+ { return "Tipos definidos"; }
+
+ /*! header that is put before the list of enumerations. */
+ QCString trMemberEnumerationDocumentation()
+ { return "Enumerações"; }
+
+ /*! header that is put before the list of member functions. */
+ QCString trMemberFunctionDocumentation()
+ { return "Métodos"; }
+
+ /*! header that is put before the list of member attributes. */
+ QCString trMemberDataDocumentation()
+ { return "Atributos"; }
+
+ /*! this is the text of a link put after brief descriptions. */
+ QCString trMore()
+ { return "Mais..."; }
+
+ /*! put in the class documentation */
+ QCString trListOfAllMembers()
+ { return "Mostrar lista completa dos membros"; }
+
+ /*! used as the title of the "list of all members" page of a class */
+ QCString trMemberList()
+ { return "Lista dos membros"; }
+
+ /*! this is the first part of a sentence that is followed by a class name */
+ QCString trThisIsTheListOfAllMembers()
+ { return "Esta é a lista de todos os membros de "; }
+
+ /*! this is the remainder of the sentence after the class name */
+ QCString trIncludingInheritedMembers()
+ { return ", incluindo os membros herdados."; }
+
+ /*! this is put at the author sections at the bottom of man pages.
+ * parameter s is name of the project name.
+ */
+ QCString trGeneratedAutomatically(const char *s)
+ { QCString result="Gerado automaticamente por Doxygen";
+ if (s) result+=(QCString)" para "+s;
+ result+=" a partir do código fonte.";
+ return result;
+ }
+
+ /*! put after an enum name in the list of all members */
+ QCString trEnumName()
+ { return "enumeração"; }
+
+ /*! put after an enum value in the list of all members */
+ QCString trEnumValue()
+ { return "valor enumerado"; }
+
+ /*! put after an undocumented member in the list of all members */
+ QCString trDefinedIn()
+ { return "definido em"; }
+
+ /*! put as in introduction in the verbatim header file of a class.
+ * parameter f is the name of the include file.
+ */
+ QCString trIncludeFile()
+ { return "Arquivo incluído"; }
+ QCString trVerbatimText(const char *f)
+ { return (QCString)"Este texto foi originado pelo arquivo incluído "+f+"."; }
+
+ // quick reference sections
+
+ /*! This is put above each page as a link to the list of all groups of
+ * compounds or files (see the \group command).
+ */
+ QCString trModules()
+ { return "Módulos"; }
+
+ /*! This is put above each page as a link to the class hierarchy */
+ QCString trClassHierarchy()
+ { return "Hierarquia de classes"; }
+
+ /*! This is put above each page as a link to the list of annotated classes */
+ QCString trCompoundList()
+ { return "Lista de componentes";
+
+ /*! This is put above each page as a link to the list of documented files */}
+ QCString trFileList()
+ { return "Lista de arquivos"; }
+
+ /*! This is put above each page as a link to the list of all verbatim headers */
+ QCString trHeaderFiles()
+ { return "Arquivos Incluídos"; }
+
+ /*! This is put above each page as a link to all members of compounds. */
+ QCString trCompoundMembers()
+ { return "Componentes"; }
+
+ /*! This is put above each page as a link to all members of files. */
+ QCString trFileMembers()
+ { return "Declarações"; }
+
+ /*! This is put above each page as a link to all related pages. */
+ QCString trRelatedPages()
+ { return "Paginas relacionadas"; }
+
+ /*! This is put above each page as a link to all examples. */
+ QCString trExamples()
+ { return "Exemplos"; }
+
+ /*! This is put above each page as a link to the search engine. */
+ QCString trSearch()
+ { return "Localizar"; }
+
+ /*! This is an introduction to the class hierarchy. */
+ QCString trClassHierarchyDescription()
+ { return "Esta lista de heranças está organizada, dentro do possível, por ordem alfabética:"; }
+
+ /*! This is an introduction to the list with all files. */
+ QCString trFileListDescription(bool extractAll)
+ {
+ QCString result="Lista de todos os arquivos ";
+ if (!extractAll) result+="documentados ";
+ result+="com uma breve descrição:";
+ return result;
+ }
+
+ /*! This is an introduction to the annotated compound list. */
+ QCString trCompoundListDescription()
+ { return "Lista de classes, estruturas, uniões e interfaces com breves descrições:";
+ }
+
+ /*! This is an introduction to the page with all class members. */
+ QCString trCompoundMembersDescription(bool extractAll)
+ {
+ QCString result="Lista de todos os membros ";
+ if (!extractAll) result+="documentados ";
+ result+="com links para ";
+ if (extractAll) result+="a documentação das respectivas classes:";
+ else result+="o arquivo a que pertencem:";
+ return result;
+ }
+
+ /*! This is an introduction to the page with all file members. */
+ QCString trFileMembersDescription(bool extractAll)
+ {
+ QCString result="Lista de todos os membros ";
+ if (!extractAll) result+="documentados ";
+ result+="com links para ";
+ if (extractAll) result+="a documentação correspondente:";
+ else result+="os arquivos onde foram definidos:";
+ return result;
+ }
+
+ /*! This is an introduction to the page with the list of all header files. */
+ QCString trHeaderFilesDescription()
+ { return "Lista de todos os arquivos cabeçalho que constituem a API:"; }
+
+ /*! This is an introduction to the page with the list of all examples */
+ QCString trExamplesDescription()
+ { return "Lista de todos os exemplos:"; }
+
+ /*! This is an introduction to the page with the list of related pages */
+ QCString trRelatedPagesDescription()
+ { return "Lista de documentação relacionada:"; }
+
+ /*! This is an introduction to the page with the list of class/file groups */
+ QCString trModulesDescription()
+ { return "Lista de todos os módulos:"; }
+
+ /*! This sentences is used in the annotated class/file lists if no brief
+ * description is given.
+ */
+ QCString trNoDescriptionAvailable()
+ { return "Nenhuma descrição disponível"; }
+
+ // index titles (the project name is prepended for these)
+
+
+ /*! This is used in HTML as the title of index.html. */
+ QCString trDocumentation()
+ { return "Documentação"; }
+
+ /*! This is used in LaTeX as the title of the chapter with the
+ * index of all groups.
+ */
+ QCString trModuleIndex()
+ { return "Índice dos módulos"; }
+
+ /*! This is used in LaTeX as the title of the chapter with the
+ * class hierarchy.
+ */
+ QCString trHierarchicalIndex()
+ { return "Índice da hierarquia"; }
+
+ /*! This is used in LaTeX as the title of the chapter with the
+ * annotated compound index.
+ */
+ QCString trCompoundIndex()
+ { return "Índice dos componentes"; }
+
+ /*! This is used in LaTeX as the title of the chapter with the
+ * list of all files.
+ */
+ QCString trFileIndex()
+ { return "Índice dos arquivos"; }
+
+ /*! This is used in LaTeX as the title of the chapter containing
+ * the documentation of all groups.
+ */
+ QCString trModuleDocumentation()
+ { return "Documentação do módulo"; }
+
+ /*! This is used in LaTeX as the title of the chapter containing
+ * the documentation of all classes, structs and unions.
+ */
+ QCString trClassDocumentation()
+ { return "Documentação da classe"; }
+
+ /*! This is used in LaTeX as the title of the chapter containing
+ * the documentation of all files.
+ */
+ QCString trFileDocumentation()
+ { return "Documentação do arquivo"; }
+
+ /*! This is used in LaTeX as the title of the chapter containing
+ * the documentation of all examples.
+ */
+ QCString trExampleDocumentation()
+ { return "Documentação do exemplo"; }
+
+ /*! This is used in LaTeX as the title of the chapter containing
+ * the documentation of all related pages.
+ */
+ QCString trPageDocumentation()
+ { return "Documentação da página"; }
+
+ /*! This is used in LaTeX as the title of the document */
+ QCString trReferenceManual()
+ { return "Manual de referência"; }
+
+ /*! This is used in the documentation of a file as a header before the
+ * list of defines
+ */
+ QCString trDefines()
+ { return "Definição de macros"; }
+
+ /*! This is used in the documentation of a file as a header before the
+ * list of function prototypes
+ */
+ QCString trFuncProtos()
+ { return "Protótipos de funções"; }
+
+ /*! This is used in the documentation of a file as a header before the
+ * list of typedefs
+ */
+ QCString trTypedefs()
+ { return "Definições de tipos"; }
+
+ /*! This is used in the documentation of a file as a header before the
+ * list of enumerations
+ */
+ QCString trEnumerations()
+ { return "Enumerações"; }
+
+ /*! This is used in the documentation of a file as a header before the
+ * list of (global) functions
+ */
+ QCString trFunctions()
+ { return "Funções"; }
+
+ /*! This is used in the documentation of a file as a header before the
+ * list of (global) variables
+ */
+ QCString trVariables()
+ { return "Variáveis"; }
+
+ /*! This is used in the documentation of a file as a header before the
+ * list of (global) variables
+ */
+ QCString trEnumerationValues()
+ { return "Valores da enumeração"; }
+
+ /*! This is used in man pages as the author section. */
+ QCString trAuthor()
+ { return "Autor"; }
+
+ /*! This is used in the documentation of a file before the list of
+ * documentation blocks for defines
+ */
+ QCString trDefineDocumentation()
+ { return "Macros"; }
+
+ /*! This is used in the documentation of a file/namespace before the list
+ * of documentation blocks for function prototypes
+ */
+ QCString trFunctionPrototypeDocumentation()
+ { return "Protótipos das funções"; }
+
+ /*! This is used in the documentation of a file/namespace before the list
+ * of documentation blocks for typedefs
+ */
+ QCString trTypedefDocumentation()
+ { return "Tipos"; }
+
+ /*! This is used in the documentation of a file/namespace before the list
+ * of documentation blocks for enumeration types
+ */
+ QCString trEnumerationTypeDocumentation()
+ { return "Enumerações"; }
+
+ /*! This is used in the documentation of a file/namespace before the list
+ * of documentation blocks for enumeration values
+ */
+ QCString trEnumerationValueDocumentation()
+ { return "Elementos da enumeração"; }
+
+ /*! This is used in the documentation of a file/namespace before the list
+ * of documentation blocks for functions
+ */
+ QCString trFunctionDocumentation()
+ { return "Funções"; }
+
+ /*! This is used in the documentation of a file/namespace before the list
+ * of documentation blocks for variables
+ */
+ QCString trVariableDocumentation()
+ { return "Variáveis"; }
+
+ /*! This is used in the documentation of a file/namespace/group before
+ * the list of links to documented compounds
+ */
+ QCString trCompounds()
+ { return "Componentes"; }
+
+ /*! This is used in the documentation of a group before the list of
+ * links to documented files
+ */
+ QCString trFiles()
+ { return "Arquivos"; }
+
+ /*! This is used in the standard footer of each page and indicates when
+ * the page was generated
+ */
+ QCString trGeneratedAt(const char *date,const char *projName)
+ {
+ QCString result=(QCString)"Criado em "+date;
+ if (projName) result+=(QCString)" para "+projName;
+ result+=(QCString)" por";
+ return result;
+ }
+ /*! This is part of the sentence used in the standard footer of each page.
+ */
+ QCString trWrittenBy()
+ {
+ return "escrito por";
+ }
+
+ /*! this text is put before a class diagram */
+ QCString trClassDiagram(const char *clName)
+ {
+ return (QCString)"Diagrama de heranças da classe "+clName;
+ }
+
+ /*! this text is generated when the \internal command is used. */
+ QCString trForInternalUseOnly()
+ { return "Apenas para uso interno."; }
+
+ /*! this text is generated when the \reimp command is used. */
+ QCString trReimplementedForInternalReasons()
+ { return "Redefinido por razões internas. A interface não foi afetada.";
+ }
+
+ /*! this text is generated when the \warning command is used. */
+ QCString trWarning()
+ { return "Aviso"; }
+
+ /*! this text is generated when the \bug command is used. */
+ QCString trBugsAndLimitations()
+ { return "Bugs e limitações"; }
+
+ /*! this text is generated when the \version command is used. */
+ QCString trVersion()
+ { return "Versão"; }
+
+ /*! this text is generated when the \date command is used. */
+ QCString trDate()
+ { return "Data"; }
+
+ /*! this text is generated when the \author command is used. */
+ QCString trAuthors()
+ { return "Autor(es)"; }
+
+ /*! this text is generated when the \return command is used. */
+ QCString trReturns()
+ { return "Retorna"; }
+
+ /*! this text is generated when the \sa command is used. */
+ QCString trSeeAlso()
+ { return "Veja também"; }
+
+ /*! this text is generated when the \param command is used. */
+ QCString trParameters()
+ { return "Parâmetros"; }
+
+ /*! this text is generated when the \exception command is used. */
+ QCString trExceptions()
+ { return "Exceções"; }
+
+ /*! this text is used in the title page of a LaTeX document. */
+ QCString trGeneratedBy()
+ { return "Criado por"; }
+
+ // new since 0.49-990307
+
+ virtual QCString trNamespaceList()
+ { return "Lista de namespaces"; }
+
+ /*! used as an introduction to the namespace list */
+ virtual QCString trNamespaceListDescription(bool extractAll)
+ {
+ QCString result="Lista ";
+ if (!extractAll) result+="de toda a documentação ";
+ result+="dos namespaces com uma breve descrição:";
+ return result;
+ }
+
+ /*! used in the class documentation as a header before the list of all
+ * friends of a class
+ */
+ virtual QCString trFriends()
+ { return "Amigos"; }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 0.49-990405
+//////////////////////////////////////////////////////////////////////////
+
+ /*! used in the class documentation as a header before the list of all
+ * related classes
+ */
+ virtual QCString trRelatedFunctionDocumentation()
+ { return "Funções relacionadas e classes amigas"; }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 0.49-990425
+//////////////////////////////////////////////////////////////////////////
+
+ /*! used as the title of the HTML page of a class/struct/union */
+ virtual QCString trCompoundReference(const char *clName,
+ ClassDef::CompoundType compType,
+ bool isTemplate)
+ {
+ QCString result="Referencia ";
+ switch(compType)
+ {
+ case ClassDef::Class: result+="à classe "; break;
+ case ClassDef::Struct: result+="à estrutura "; break;
+ case ClassDef::Union: result+="à união "; break;
+ case ClassDef::Interface: result+="à interface "; break;
+ case ClassDef::Exception: result+="à excepção "; break;
+ }
+
+ if (isTemplate)
+ result+="<template> ";
+
+ result+=(QCString)clName;
+ return result;
+ }
+
+ /*! used as the title of the HTML page of a file */
+ virtual QCString trFileReference(const char *fileName)
+ {
+ QCString result= "Referencia ao arquivo ";
+ result += fileName;
+ return result;
+ }
+
+ /*! used as the title of the HTML page of a namespace */
+ virtual QCString trNamespaceReference(const char *namespaceName)
+ {
+ QCString result= "Referencia ao namespace ";
+ result += namespaceName;
+ return result;
+ }
+
+ /*! \mgroup Class sections
+ * these are for the member sections of a class, struct or union
+ */
+ virtual QCString trPublicMembers()
+ { return "Membros públicos"; }
+ virtual QCString trPublicSlots()
+ { return "Slots públicos"; }
+ virtual QCString trSignals()
+ { return "Sinais"; }
+ virtual QCString trStaticPublicMembers()
+ { return "Membros públicos estáticos"; }
+ virtual QCString trProtectedMembers()
+ { return "Membros protegidos"; }
+ virtual QCString trProtectedSlots()
+ { return "Slots protegidos"; }
+ virtual QCString trStaticProtectedMembers()
+ { return "Membros protegidos estáticos"; }
+ virtual QCString trPrivateMembers()
+ { return "Membros privados"; }
+ virtual QCString trPrivateSlots()
+ { return "Slots privados"; }
+ virtual QCString trStaticPrivateMembers()
+ { return "Membros privados estáticos"; }
+ /*! \endmgroup */
+
+ /*! this function is used to produce a comma-separated list of items.
+ * use generateMarker(i) to indicate where item i should be put.
+ */
+ virtual QCString trWriteList(int numEntries)
+ {
+ QCString result;
+ int i;
+ // the inherits list contain `numEntries' classes
+ for (i=0;i<numEntries;i++)
+ {
+ // use generateMarker to generate placeholders for the class links!
+ result+=generateMarker(i); // generate marker for entry i in the list
+ // (order is left to right)
+
+ if (i!=numEntries-1) // not the last entry, so we need a separator
+ {
+ if (i<numEntries-2) // not the fore last entry
+ result+=", ";
+ else // the fore last entry
+ result+=", e ";
+ }
+ }
+ return result;
+ }
+
+ /*! used in class documentation to produce a list of base classes,
+ * if class diagrams are disabled.
+ */
+ virtual QCString trInheritsList(int numEntries)
+ {
+ return "Derivada de "+trWriteList(numEntries)+".";
+ }
+
+ /*! used in class documentation to produce a list of super classes,
+ * if class diagrams are disabled.
+ */
+ virtual QCString trInheritedByList(int numEntries)
+ {
+ return "Herdado por "+trWriteList(numEntries)+".";
+ }
+
+ /*! used in member documentation blocks to produce a list of
+ * members that are hidden by this one.
+ */
+ virtual QCString trReimplementedFromList(int numEntries)
+ {
+ return "Reimplementado de "+trWriteList(numEntries)+".";
+ }
+
+ /*! used in member documentation blocks to produce a list of
+ * all member that overwrite the implementation of this member.
+ */
+ virtual QCString trReimplementedInList(int numEntries)
+ {
+ return "Reimplementado em "+trWriteList(numEntries)+".";
+ }
+
+ /*! This is put above each page as a link to all members of namespaces. */
+ virtual QCString trNamespaceMembers()
+ { return "Membros do namespace"; }
+
+ /*! This is an introduction to the page with all namespace members */
+ virtual QCString trNamespaceMemberDescription(bool extractAll)
+ {
+ QCString result="Lista ";
+ if (extractAll) result+="de todos os ";
+ else result+="de toda a documentação dos ";
+ result+="membros do namespace com links para ";
+ if (extractAll) result+="a documentação de cada membro:";
+ else result+="o namespace correspondente:";
+ return result;
+ }
+
+ /*! This is used in LaTeX as the title of the chapter with the
+ * index of all namespaces.
+ */
+ virtual QCString trNamespaceIndex()
+ { return "Índice dos namespaces"; }
+
+ /*! This is used in LaTeX as the title of the chapter containing
+ * the documentation of all namespaces.
+ */
+ virtual QCString trNamespaceDocumentation()
+ { return "Namespaces"; }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 0.49-990522
+//////////////////////////////////////////////////////////////////////////
+
+ /*! This is used in the documentation before the list of all
+ * namespaces in a file.
+ */
+ virtual QCString trNamespaces()
+ { return "Namespaces"; }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 0.49-990728
+//////////////////////////////////////////////////////////////////////////
+
+ /*! This is put at the bottom of a class documentation page and is
+ * followed by a list of files that were used to generate the page.
+ */
+ virtual QCString trGeneratedFromFiles(ClassDef::CompoundType compType,
+ bool single)
+ { // here s is one of " Class", " Struct" or " Union"
+ // single is true implies a single file
+ QCString result=(QCString)"A documentação para ";
+ switch(compType)
+ {
+ case ClassDef::Class: result+="esta classe"; break;
+ case ClassDef::Struct: result+="esta estrutura"; break;
+ case ClassDef::Union: result+="esta união"; break;
+ case ClassDef::Interface: result+="esta interface"; break;
+ case ClassDef::Exception: result+="esta exceção"; break;
+ }
+ result+=" foi gerada a partir ";
+ if (single) result+=" do seguinte arquivo:";
+ else result+="dos seguintes arquivos:";
+ return result;
+ }
+
+ /*! This is in the (quick) index as a link to the alphabetical compound
+ * list.
+ */
+ virtual QCString trAlphabeticalList()
+ {
+ return "Lista em ordem alfabética";
+ }
+
+
+//////////////////////////////////////////////////////////////////////////
+// new since 0.49-990901
+//////////////////////////////////////////////////////////////////////////
+
+ /*! This is used as the heading text for the retval command. */
+ virtual QCString trReturnValues()
+ { return "Valores retornados"; }
+
+ /*! This is in the (quick) index as a link to the main page (index.html)
+ */
+ virtual QCString trMainPage()
+ { return "Página principal"; }
+
+ /*! This is used in references to page that are put in the LaTeX
+ * documentation. It should be an abbreviation of the word page.
+ */
+ virtual QCString trPageAbbreviation()
+ { return "p. "; }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 0.49-991003
+//////////////////////////////////////////////////////////////////////////
+
+ virtual QCString trSources()
+ {
+ return "Fontes";
+ }
+ virtual QCString trDefinedAtLineInSourceFile()
+ {
+ return "Definido na linha @0 do arquivo @1.";
+ }
+ virtual QCString trDefinedInSourceFile()
+ {
+ return "Definido no arquivo @0.";
+ }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 0.49-991205
+//////////////////////////////////////////////////////////////////////////
+
+ virtual QCString trDeprecated()
+ {
+ return "Desaprovado";
+ }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 1.0.0
+//////////////////////////////////////////////////////////////////////////
+
+ /*! this text is put before a collaboration diagram */
+ virtual QCString trCollaborationDiagram(const char *clName)
+ {
+ return (QCString)"Diagrama de colaboração para "+clName+":";
+ }
+ /*! this text is put before an include dependency graph */
+ virtual QCString trInclDepGraph(const char *fName)
+ {
+ return (QCString)"Diagrama de dependências de inclusão para "+fName+":";
+ }
+ /*! header that is put before the list of constructor/destructors. */
+ virtual QCString trConstructorDocumentation()
+ {
+ return "Construtores e Destrutores";
+ }
+ /*! Used in the file documentation to point to the corresponding sources. */
+ virtual QCString trGotoSourceCode()
+ {
+ return "Ir para o código fonte deste arquivo.";
+ }
+ /*! Used in the file sources to point to the corresponding documentation. */
+ virtual QCString trGotoDocumentation()
+ {
+ return "Ir para a documentação deste arquivo.";
+ }
+ /*! Text for the \pre command */
+ virtual QCString trPrecondition()
+ {
+ return "Precondição";
+ }
+ /*! Text for the \post command */
+ virtual QCString trPostcondition()
+ {
+ return "Poscondição";
+ }
+ /*! Text for the \invariant command */
+ virtual QCString trInvariant()
+ {
+ return "Invariante";
+ }
+ /*! Text shown before a multi-line variable/enum initialization */
+ virtual QCString trInitialValue()
+ {
+ return "Valor inicial:";
+ }
+ /*! Text used the source code in the file index */
+ virtual QCString trCode()
+ {
+ return "código";
+ }
+ virtual QCString trGraphicalHierarchy()
+ {
+ return "Representação gráfica da hierarquia da classe";
+ }
+ virtual QCString trGotoGraphicalHierarchy()
+ {
+ return "Ir para a representação gráfica da hierarquia da classe";
+ }
+ virtual QCString trGotoTextualHierarchy()
+ {
+ return "Ir para a representação textual da hierarquia da classe";
+ }
+ virtual QCString trPageIndex()
+ {
+ return "Índice da página";
+ }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 1.1.0
+//////////////////////////////////////////////////////////////////////////
+
+ virtual QCString trNote()
+ {
+ return "Nota";
+ }
+ virtual QCString trPublicTypes()
+ {
+ return "Tipos Públicos";
+ }
+ virtual QCString trPublicAttribs()
+ {
+ return "Atributos Públicos";
+ }
+ virtual QCString trStaticPublicAttribs()
+ {
+ return "Atributos Públicos Estáticos";
+ }
+ virtual QCString trProtectedTypes()
+ {
+ return "Tipos Protegidos";
+ }
+ virtual QCString trProtectedAttribs()
+ {
+ return "Atributos Protegidos";
+ }
+ virtual QCString trStaticProtectedAttribs()
+ {
+ return "Atributos Protegidos Estáticos";
+ }
+ virtual QCString trPrivateTypes()
+ {
+ return "Tipos Privados";
+ }
+ virtual QCString trPrivateAttribs()
+ {
+ return "Atributos Privados";
+ }
+ virtual QCString trStaticPrivateAttribs()
+ {
+ return "Atributos Privados Estáticos";
+ }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 1.1.3
+//////////////////////////////////////////////////////////////////////////
+
+ /*! Used as a marker that is put before a todo item */
+ virtual QCString trTodo()
+ {
+ return "Tarefa";
+ }
+ /*! Used as the header of the todo list */
+ virtual QCString trTodoList()
+ {
+ return "Lista de tarefas";
+ }
+
+//////////////////////////////////////////////////////////////////////////
+// new since 1.1.4
+//////////////////////////////////////////////////////////////////////////
+
+ virtual QCString trReferencedBy()
+ {
+ return "Referenciado por";
+ }
+ virtual QCString trRemarks()
+ {
+ return "Observações";
+ }
+ virtual QCString trAttention()
+ {
+ return "Atenção";
+ }
+ virtual QCString trInclByDepGraph()
+ {
+ return "Este gráfico mostra quais são os arquivos que incluem diretamente ou indiretamente este arquivo:";
+ }
+ virtual QCString trSince()
+ {
+ return "Desde";
+ }
+
+};
+#endif
diff --git a/src/translator_ru.h b/src/translator_ru.h
index 641aa46..4345139 100644
--- a/src/translator_ru.h
+++ b/src/translator_ru.h
@@ -62,7 +62,7 @@ class TranslatorRussian : public Translator
}
QCString trMemberDataDocumentation()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "ïÐÉÓÁÎÉÅ ÐÏÌÅÊ";
}
@@ -123,7 +123,7 @@ class TranslatorRussian : public Translator
}
QCString trCompoundList()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "óÔÒÕËÔÕÒÙ ÄÁÎÎÙÈ";
}
@@ -143,7 +143,7 @@ class TranslatorRussian : public Translator
}
QCString trCompoundMembers()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "ðÏÌÑ ÓÔÒÕËÔÕÒ";
}
@@ -154,7 +154,7 @@ class TranslatorRussian : public Translator
}
QCString trFileMembers()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "çÌÏÂÁÌØÎÙÅ ÉÍÅÎÁ";
}
@@ -192,7 +192,7 @@ class TranslatorRussian : public Translator
}
QCString trCompoundListDescription()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "óÔÒÕËÔÕÒÙ ÄÁÎÎÙÈ É ÉÈ ËÒÁÔËÏÅ ÏÐÉÓÁÎÉÅ: ";
}
@@ -219,7 +219,7 @@ class TranslatorRussian : public Translator
QCString result="óÐÉÓÏË ×ÓÅÈ ";
if (!extractAll) result+="ÄÏËÕÍÅÎÔÉÒÏ×ÁÎÎÙÈ ";
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
result+="ÆÕÎËÃÉÊ, ÐÅÒÅÍÅÎÎÙÈ, ÍÁËÒÏÏÐÒÅÄÅÌÅÎÉÊ, "
"ÐÅÒÅÞÉÓÌÅÎÉÊ É ÏÐÒÅÄÅÌÅÎÉÊ ÔÉÐÏ×";
@@ -269,7 +269,7 @@ class TranslatorRussian : public Translator
}
QCString trCompoundIndex()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "óÐÉÓÏË ÓÔÒÕËÔÕÒ ÄÁÎÎÙÈ";
}
@@ -370,7 +370,7 @@ class TranslatorRussian : public Translator
}
QCString trCompounds()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "óÔÒÕËÔÕÒÙ ÄÁÎÎÙÈ";
}
@@ -730,7 +730,7 @@ class TranslatorRussian : public Translator
}
QCString trPublicAttribs()
{
- if (Config::optimizeForCFlag)
+ if (Config::instance()->getBool("OPTIMIZE_OUTPUT_FOR_C"))
{
return "ðÏÌÑ ÄÁÎÎÙÈ";
}
diff --git a/src/util.cpp b/src/util.cpp
index 5e9f840..41ecedd 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -24,6 +24,7 @@
#include "qtbc.h"
#include <qregexp.h>
#include <qfileinfo.h>
+#include <qdir.h>
#include "util.h"
#include "message.h"
@@ -279,8 +280,8 @@ void writePageRef(OutputDocInterface &od,const char *cn,const char *mn)
od.disable(OutputGenerator::Html);
od.disable(OutputGenerator::Man);
- if (Config::pdfHyperFlag) od.disable(OutputGenerator::Latex);
- if (Config::rtfHyperFlag) od.disable(OutputGenerator::RTF);
+ if (Config::instance()->getBool("PDF_HYPERLINKS")) od.disable(OutputGenerator::Latex);
+ if (Config::instance()->getBool("RTF_HYPERLINKS")) od.disable(OutputGenerator::RTF);
od.startPageRef();
od.docify(theTranslator->trPageAbbreviation());
od.endPageRef(cn,mn);
@@ -300,11 +301,11 @@ QCString generateMarker(int id)
}
/*! strip part of \a path if it matches
- * one of the paths in the Config::stripFromPath list
+ * one of the paths in the Config::instance()->getList("STRIP_FROM_PATH") list
*/
QCString stripFromPath(const QCString &path)
{
- const char *s=Config::stripFromPath.first();
+ const char *s=Config::instance()->getList("STRIP_FROM_PATH").first();
while (s)
{
QCString prefix = s;
@@ -312,7 +313,7 @@ QCString stripFromPath(const QCString &path)
{
return path.right(path.length()-prefix.length());
}
- s = Config::stripFromPath.next();
+ s = Config::instance()->getList("STRIP_FROM_PATH").next();
}
return path;
}
@@ -380,7 +381,7 @@ NamespaceDef *getResolvedNamespace(const char *name)
}
}
-ClassDef *getResolvedClass(const char *name,bool *pIsTypeDef)
+ClassDef *getResolvedClass(const char *name,bool *pIsTypeDef,QCString *pTemplSpec)
{
if (name==0 || name[0]=='\0') return 0;
QCString *subst = Doxygen::typedefDict[name];
@@ -412,6 +413,7 @@ ClassDef *getResolvedClass(const char *name,bool *pIsTypeDef)
ClassDef *cd = Doxygen::classDict[subst->data()];
if (cd==0 && (i=subst->find('<'))>0) // try unspecialized version as well
{
+ if (pTemplSpec) *pTemplSpec = subst->right(subst->length()-i);
return Doxygen::classDict[subst->left(i)];
}
else
@@ -810,7 +812,7 @@ QCString fileToString(const char *name,bool filter)
err("Error: file `%s' not found\n",name);
return "";
}
- if (Config::inputFilter.isEmpty() || !filter)
+ if (Config::instance()->getString("INPUT_FILTER").isEmpty() || !filter)
{
f.setName(name);
fileOpened=f.open(IO_ReadOnly);
@@ -830,11 +832,11 @@ QCString fileToString(const char *name,bool filter)
}
else // filter the input
{
- QCString cmd=Config::inputFilter+" "+name;
+ QCString cmd=Config::instance()->getString("INPUT_FILTER")+" "+name;
FILE *f=popen(cmd,"r");
if (!f)
{
- err("Error: could not execute filter %s\n",Config::inputFilter.data());
+ err("Error: could not execute filter %s\n",Config::instance()->getString("INPUT_FILTER").data());
return "";
}
const int bSize=4096;
@@ -1759,7 +1761,7 @@ bool getDefs(const QCString &scName,const QCString &memberName,
//printf(" >Searching for arbitrary member\n");
for (mmli.toFirst();(mmd=mmli.current());++mmli)
{
- if (//(mmd->protection()!=Private || Config::extractPrivateFlag) &&
+ if (//(mmd->protection()!=Private || Config::instance()->getBool("EXTRACT_PRIVATE")) &&
//(
//mmd->hasDocumentation()
/*mmd->detailsAreVisible()*/
@@ -2071,7 +2073,7 @@ bool generateRef(OutputDocInterface &od,const char *scName,
{
od.writeObjectLink(cd->getReference(),
cd->getOutputFileBase(),0,linkText);
- if (!cd->isReference() /*&& !Config::pdfHyperFlag*/)
+ if (!cd->isReference() /*&& !Config::instance()->getBool("PDF_HYPERLINKS")*/)
{
writePageRef(od,cd->getOutputFileBase(),0);
}
@@ -2080,7 +2082,7 @@ bool generateRef(OutputDocInterface &od,const char *scName,
{
od.writeObjectLink(nd->getReference(),
nd->getOutputFileBase(),0,linkText);
- if (!nd->getReference() /*&& !Config::pdfHyperFlag*/)
+ if (!nd->getReference() /*&& !Config::instance()->getBool("PDF_HYPERLINKS")*/)
{
writePageRef(od,nd->getOutputFileBase(),0);
}
@@ -2367,7 +2369,7 @@ QCString convertFileName(const QCString &s)
{
if (s.at(i)!='/' && s.at(i)!='.')
{
- if (Config::caseSensitiveNames)
+ if (Config::instance()->getBool("CASE_SENSE_NAMES"))
{
result+=s[i];
}
@@ -2408,7 +2410,7 @@ QCString substitute(const char *s,const char *src,const char *dst)
FileDef *findFileDef(const FileNameDict *fnDict,const char *n,bool &ambig)
{
ambig=FALSE;
- QCString name=n;
+ QCString name=convertToQCString(QDir::cleanDirPath(n));
QCString path;
if (name.isEmpty()) return 0;
int slashPos=QMAX(name.findRev('/'),name.findRev('\\'));
@@ -2485,15 +2487,15 @@ QCString substituteKeywords(const QCString &s,const char *title)
result = substitute(result,"$datetime",dateToString(TRUE));
result = substitute(result,"$date",dateToString(FALSE));
result = substitute(result,"$doxygenversion",versionString);
- result = substitute(result,"$projectname",Config::projectName);
- result = substitute(result,"$projectnumber",Config::projectNumber);
+ result = substitute(result,"$projectname",Config::instance()->getString("PROJECT_NAME"));
+ result = substitute(result,"$projectnumber",Config::instance()->getString("PROJECT_NUMBER"));
return result;
}
//----------------------------------------------------------------------
/*! Returns the character index within \a name of the first prefix
- * in Config::ignorePrefixList that matches \a name at the left hand side,
+ * in Config::instance()->getList("IGNORE_PREFIX") that matches \a name at the left hand side,
* or zero if no match was found
*/
int getPrefixIndex(const QCString &name)
@@ -2501,7 +2503,7 @@ int getPrefixIndex(const QCString &name)
int ni = name.findRev("::");
if (ni==-1) ni=0; else ni+=2;
//printf("getPrefixIndex(%s) ni=%d\n",name.data(),ni);
- char *s = Config::ignorePrefixList.first();
+ char *s = Config::instance()->getList("IGNORE_PREFIX").first();
while (s)
{
const char *ps=s;
@@ -2512,7 +2514,7 @@ int getPrefixIndex(const QCString &name)
{
return ni+i;
}
- s = Config::ignorePrefixList.next();
+ s = Config::instance()->getList("IGNORE_PREFIX").next();
}
return ni;
}
@@ -2580,7 +2582,7 @@ QCString convertNameToFile(const char *name,bool allowDots)
case '.': if (allowDots) result+="."; else result+="_"; break;
case ' ': break;
default:
- if (Config::caseSensitiveNames)
+ if (Config::instance()->getBool("CASE_SENSE_NAMES"))
result+=c;
else
result+=tolower(c);
diff --git a/src/util.h b/src/util.h
index b9cf560..84ad1be 100644
--- a/src/util.h
+++ b/src/util.h
@@ -101,7 +101,9 @@ extern QCString convertFileName(const QCString &s);
extern QCString substitute(const char *s,const char *src,const char *dst);
extern QCString resolveDefines(const char *n);
extern ClassDef *getClass(const char *key);
-extern ClassDef *getResolvedClass(const char *key,bool *pIsTypeDef=0);
+extern ClassDef *getResolvedClass(const char *key,
+ bool *pIsTypeDef=0,
+ QCString *pTemplSpec=0);
extern NamespaceDef *getResolvedNamespace(const char *key);
extern FileDef *findFileDef(const FileNameDict *fnDict,const char *n,
bool &ambig);