summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--INSTALL4
-rw-r--r--README4
-rw-r--r--addon/doxywizard/doxywizard.cpp12
-rwxr-xr-xconfigure2
-rw-r--r--doc/config.doc19
-rw-r--r--doc/language.doc9
-rw-r--r--doc/translator_report.txt34
-rw-r--r--qtools/Doxyfile41
-rw-r--r--src/classdef.cpp28
-rw-r--r--src/code.l26
-rw-r--r--src/commentscan.l43
-rw-r--r--src/config.l4
-rw-r--r--src/config.xml24
-rw-r--r--src/configoptions.cpp41
-rw-r--r--src/docparser.cpp50
-rw-r--r--src/docparser.h19
-rw-r--r--src/docsets.cpp2
-rw-r--r--src/docvisitor.h2
-rw-r--r--src/dot.cpp11
-rw-r--r--src/doxygen.cpp48
-rw-r--r--src/doxygen.h2
-rw-r--r--src/filedef.cpp12
-rw-r--r--src/fortrancode.l24
-rw-r--r--src/ftvhelp.cpp38
-rw-r--r--src/groupdef.cpp2
-rw-r--r--src/htmldocvisitor.cpp44
-rw-r--r--src/htmldocvisitor.h1
-rw-r--r--src/htmlgen.cpp272
-rw-r--r--src/htmlgen.h3
-rw-r--r--src/htmlhelp.cpp2
-rw-r--r--src/index.cpp634
-rw-r--r--src/index.h5
-rw-r--r--src/latexdocvisitor.cpp4
-rw-r--r--src/latexdocvisitor.h1
-rw-r--r--src/latexgen.cpp2
-rw-r--r--src/layout.cpp6
-rw-r--r--src/libdoxygen.pro.in2
-rw-r--r--src/libdoxygen.t6
-rw-r--r--src/logos.cpp4
-rw-r--r--src/mandocvisitor.cpp4
-rw-r--r--src/mandocvisitor.h1
-rw-r--r--src/memberdef.cpp73
-rw-r--r--src/memberdef.h8
-rw-r--r--src/membergroup.h1
-rw-r--r--src/memberlist.cpp14
-rw-r--r--src/namespacedef.cpp10
-rw-r--r--src/pagedef.cpp6
-rw-r--r--src/perlmodgen.cpp5
-rw-r--r--src/printdocvisitor.h5
-rw-r--r--src/pycode.l24
-rw-r--r--src/qhp.cpp17
-rw-r--r--src/qhp.h3
-rw-r--r--src/rtfdocvisitor.cpp4
-rw-r--r--src/rtfdocvisitor.h1
-rw-r--r--src/rtfgen.cpp2
-rw-r--r--src/scanner.l3
-rw-r--r--src/search.css210
-rw-r--r--src/search.js456
-rw-r--r--src/search_css.h210
-rw-r--r--src/search_js.h456
-rw-r--r--src/sortdict.h6
-rw-r--r--src/tagreader.cpp4
-rw-r--r--src/textdocvisitor.h1
-rw-r--r--src/util.cpp6
-rw-r--r--src/util.h6
-rw-r--r--src/vhdlcode.l24
-rw-r--r--src/vhdldocgen.cpp48
-rw-r--r--src/vhdlscanner.l10
-rw-r--r--src/xmldocvisitor.cpp7
-rw-r--r--src/xmldocvisitor.h1
70 files changed, 2826 insertions, 287 deletions
diff --git a/INSTALL b/INSTALL
index 79fd565..81b8294 100644
--- a/INSTALL
+++ b/INSTALL
@@ -1,7 +1,7 @@
-DOXYGEN Version 1.5.9-20090522
+DOXYGEN Version 1.5.9-20090622
Please read the installation section of the manual
(http://www.doxygen.org/install.html) for instructions.
--------
-Dimitri van Heesch (22 May 2009)
+Dimitri van Heesch (22 June 2009)
diff --git a/README b/README
index 604f849..8d60917 100644
--- a/README
+++ b/README
@@ -1,4 +1,4 @@
-DOXYGEN Version 1.5.9_20090522
+DOXYGEN Version 1.5.9_20090622
Please read INSTALL for compilation instructions.
@@ -17,4 +17,4 @@ to subscribe to the lists or to visit the archives.
Enjoy,
-Dimitri van Heesch (dimitri@stack.nl) (22 May 2009)
+Dimitri van Heesch (dimitri@stack.nl) (22 June 2009)
diff --git a/addon/doxywizard/doxywizard.cpp b/addon/doxywizard/doxywizard.cpp
index 5928524..2c30b14 100644
--- a/addon/doxywizard/doxywizard.cpp
+++ b/addon/doxywizard/doxywizard.cpp
@@ -293,16 +293,16 @@ void MainWindow::loadSettings()
{
QVariant geometry = m_settings.value(QString::fromAscii("main/geometry"), QVariant::Invalid);
QVariant state = m_settings.value(QString::fromAscii("main/state"), QVariant::Invalid);
- QVariant expState = m_settings.value(QString::fromAscii("expert/state"), QVariant::Invalid);
- QVariant expState2 = m_settings.value(QString::fromAscii("expert/state2"), QVariant::Invalid);
+ //QVariant expState = m_settings.value(QString::fromAscii("expert/state"), QVariant::Invalid);
+ //QVariant expState2 = m_settings.value(QString::fromAscii("expert/state2"), QVariant::Invalid);
QVariant wizState = m_settings.value(QString::fromAscii("wizard/state"), QVariant::Invalid);
QVariant loadSettings = m_settings.value(QString::fromAscii("wizard/loadsettings"), QVariant::Invalid);
//QVariant workingDir = m_settings.value(QString::fromAscii("main/defdir"), QVariant::Invalid);
if (geometry !=QVariant::Invalid) restoreGeometry(geometry.toByteArray());
if (state !=QVariant::Invalid) restoreState (state.toByteArray());
- if (expState !=QVariant::Invalid) m_expert->restoreState(expState.toByteArray());
- if (expState2 !=QVariant::Invalid) m_expert->restoreInnerState(expState2.toByteArray());
+ //if (expState !=QVariant::Invalid) m_expert->restoreState(expState.toByteArray());
+ //if (expState2 !=QVariant::Invalid) m_expert->restoreInnerState(expState2.toByteArray());
if (wizState !=QVariant::Invalid) m_wizard->restoreState(wizState.toByteArray());
//if (workingDir!=QVariant::Invalid)
//{
@@ -330,8 +330,8 @@ void MainWindow::saveSettings()
m_settings.setValue(QString::fromAscii("main/geometry"), saveGeometry());
m_settings.setValue(QString::fromAscii("main/state"), saveState());
- m_settings.setValue(QString::fromAscii("expert/state"), m_expert->saveState());
- m_settings.setValue(QString::fromAscii("expert/state2"), m_expert->saveInnerState());
+ //m_settings.setValue(QString::fromAscii("expert/state"), m_expert->saveState());
+ //m_settings.setValue(QString::fromAscii("expert/state2"), m_expert->saveInnerState());
m_settings.setValue(QString::fromAscii("wizard/state"), m_wizard->saveState());
}
diff --git a/configure b/configure
index 49102bb..4675673 100755
--- a/configure
+++ b/configure
@@ -20,7 +20,7 @@ doxygen_version_minor=5
doxygen_version_revision=9
#NOTE: Setting version_mmn to "NO" will omit mmn info from the package.
-doxygen_version_mmn=NO
+doxygen_version_mmn=20090622
bin_dirs=`echo $PATH | sed -e "s/:/ /g"`
diff --git a/doc/config.doc b/doc/config.doc
index 8525593..7f9fe92 100644
--- a/doc/config.doc
+++ b/doc/config.doc
@@ -1135,7 +1135,7 @@ FILE_VERSION_INFO = "cleartool desc -fmt \%Vn"
will point to the HTML generated by the htags(1) tool instead of doxygen
built-in source browser. The htags tool is part of GNU's global source
tagging system (see http://www.gnu.org/software/global/global.html).
- The use it do the following:
+ To use it do the following:
-# Install the latest version of global (i.e. 4.8.6 or better)
-# Enable SOURCE_BROWSER and USE_HTAGS in the config file
@@ -1478,15 +1478,8 @@ FILE_VERSION_INFO = "cleartool desc -fmt \%Vn"
If the tag value is set to FRAME, a side panel will be generated
containing a tree-like index structure (just like the one that
is generated for HTML Help). For this to work a browser that supports
- JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+,
- Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are
- probably better off using the HTML help feature. Other possible values
- for this tag are: \c HIERARCHIES, which will generate the Groups, Directories,
- and Class Hierarchy pages using a tree view instead of an ordered list;
- ALL, which combines the behavior of \c FRAME and \c HIERARCHIES, and \c NONE,
- which disables this behavior completely. For backwards compatibility
- with previous releases of Doxygen, the values YES and NO are equivalent
- to FRAME and NONE respectively.
+ JavaScript, DHTML, CSS and frames is required (i.e. any modern browser).
+ Windows users are probably better off using the HTML help feature.
Via custom stylesheets (see \ref cfg_html_stylesheet "HTML_STYLESHEET")
one can further \ref doxygen_finetune "fine tune" the look of the index.
@@ -1494,6 +1487,12 @@ FILE_VERSION_INFO = "cleartool desc -fmt \%Vn"
example that shows how to put an image at the root of the tree instead of
the \ref cfg_project_name "project name".
+\anchor cfg_use_inline_trees
+<dt>\c USE_INLINE_TREES
+ \addindex USE_INLINE_TREES
+By enabling USE_INLINE_TREES, doxygen will generate the Groups, Directories,
+and Class Hierarchy pages using a tree view instead of an ordered list.
+
\anchor cfg_treeview_width
<dt>\c TREEVIEW_WIDTH <dd>
\addindex TREEVIEW_WIDTH
diff --git a/doc/language.doc b/doc/language.doc
index a7da0df..2058967 100644
--- a/doc/language.doc
+++ b/doc/language.doc
@@ -216,9 +216,9 @@ when the translator was updated.
</tr>
<tr bgcolor="#ffffff">
<td>Polish</td>
- <td>Piotr Kaminski<br/>Grzegorz Kowal</td>
- <td>Piotr.Kaminski at ctm dot gdynia dot pl<br/>g_kowal at poczta dot onet dot pl</td>
- <td>1.4.6</td>
+ <td>Piotr Kaminski<br/>Grzegorz Kowal<br/>Krzysztof Kral</td>
+ <td>Piotr.Kaminski at ctm dot gdynia dot pl<br/>g_kowal at poczta dot onet dot pl<br/>krzysztof.kral at gmail dot com</td>
+ <td>up-to-date</td>
</tr>
<tr bgcolor="#ffffff">
<td>Portuguese</td>
@@ -373,8 +373,9 @@ when the translator was updated.
\hline
Persian & Ali Nadalizadeh & {\tt\tiny nadalizadeh@gmail.com} & up-to-date \\
\hline
- Polish & Piotr Kaminski & {\tt\tiny Piotr.Kaminski@ctm.gdynia.pl} & 1.4.6 \\
+ Polish & Piotr Kaminski & {\tt\tiny Piotr.Kaminski@ctm.gdynia.pl} & up-to-date \\
~ & Grzegorz Kowal & {\tt\tiny g\_kowal@poczta.onet.pl} & ~ \\
+ ~ & Krzysztof Kral & {\tt\tiny krzysztof.kral@gmail.com} & ~ \\
\hline
Portuguese & Rui Godinho Lopes & {\tt\tiny ruiglopes@yahoo.com} & 1.3.3 \\
\hline
diff --git a/doc/translator_report.txt b/doc/translator_report.txt
index c6c721d..2d86d6c 100644
--- a/doc/translator_report.txt
+++ b/doc/translator_report.txt
@@ -10,7 +10,7 @@ Persian, Polish, Portuguese, Romanian, Russian, Serbian,
SerbianCyrilic, Slovak, Slovene, Spanish, Swedish, Turkish, Ukrainian,
and Vietnamese.
-Of them, 24 translators are up-to-date, 14 translators are based on
+Of them, 25 translators are up-to-date, 13 translators are based on
some adapter class, and 2 are English based.
----------------------------------------------------------------------
@@ -35,6 +35,7 @@ still may be some details listed even for them:
TranslatorKorean
TranslatorMacedonian
TranslatorPersian
+ TranslatorPolish -- Remove the obsolete methods (never used).
TranslatorRomanian
TranslatorRussian
TranslatorSerbianCyrilic
@@ -54,7 +55,6 @@ must be implemented to become up-to-date:
TranslatorFrench 1.5.4 22 methods to implement
TranslatorDanish 1.5.4 22 methods to implement
TranslatorSlovene 1.4.6 24 methods to implement
- TranslatorPolish 1.4.6 23 methods to implement
TranslatorNorwegian 1.4.6 23 methods to implement
TranslatorLithuanian 1.4.6 24 methods to implement
TranslatorIndonesian 1.4.6 23 methods to implement
@@ -472,36 +472,10 @@ TranslatorNorwegian (TranslatorAdapter_1_4_6) 23 methods to implement
virtual QCString trNoDescriptionAvailable()
-TranslatorPolish (TranslatorAdapter_1_4_6) 23 methods to implement
+TranslatorPolish (Translator)
----------------
- Implements 193 of the required methods.
-
- Missing methods (should be implemented):
-
- virtual QCString trCompoundMembersDescriptionFortran(bool extractAll)
- virtual QCString trGeneratedFromFilesFortran(ClassDef::CompoundType compType, bool single)
- virtual QCString trSubprograms()
- virtual QCString trModulesListDescription(bool extractAll)
- virtual QCString trModulesList()
- virtual QCString trTypeConstraints()
- virtual QCString trMemberFunctionDocumentationFortran()
- virtual QCString trCompoundListDescriptionFortran()
- virtual QCString trTypeDocumentation()
- virtual QCString trModuleReference(const char * namespaceName)
- virtual QCString trModulesMemberDescription(bool extractAll)
- virtual QCString trModulesMembers()
- virtual QCString trModulesIndex()
- virtual QCString trCompoundListFortran()
- virtual QCString trDataTypes()
- virtual QCString trCompoundIndexFortran()
- virtual QCString trSubprogram(bool first_capital, bool singular)
- virtual QCString trCallerGraph()
- virtual QCString trCompoundReferenceFortran(const char * clName, ClassDef::CompoundType compType, bool isTemplate)
- virtual QCString trType(bool first_capital, bool singular)
- virtual QCString trModule(bool first_capital, bool singular)
- virtual QCString trCompoundMembersFortran()
- virtual QCString trSubprogramDocumentation()
+ Implements 216 of the required methods.
Obsolete methods (should be removed, never used):
diff --git a/qtools/Doxyfile b/qtools/Doxyfile
index 16b681e..3ee0cd3 100644
--- a/qtools/Doxyfile
+++ b/qtools/Doxyfile
@@ -1,4 +1,4 @@
-# Doxyfile 1.5.4
+# Doxyfile 1.5.9
#---------------------------------------------------------------------------
# Project related configuration options
@@ -7,7 +7,7 @@ DOXYFILE_ENCODING = UTF-8
PROJECT_NAME = Doxygen
PROJECT_NUMBER =
OUTPUT_DIRECTORY = ../qtools_docs
-CREATE_SUBDIRS = NO
+CREATE_SUBDIRS = YES
OUTPUT_LANGUAGE = English
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
@@ -21,7 +21,6 @@ SHORT_NAMES = NO
JAVADOC_AUTOBRIEF = YES
QT_AUTOBRIEF = NO
MULTILINE_CPP_IS_BRIEF = NO
-DETAILS_AT_TOP = NO
INHERIT_DOCS = YES
SEPARATE_MEMBER_PAGES = NO
TAB_SIZE = 8
@@ -29,12 +28,16 @@ ALIASES =
OPTIMIZE_OUTPUT_FOR_C = NO
OPTIMIZE_OUTPUT_JAVA = NO
OPTIMIZE_FOR_FORTRAN = NO
+OPTIMIZE_OUTPUT_VHDL = NO
+EXTENSION_MAPPING =
BUILTIN_STL_SUPPORT = NO
CPP_CLI_SUPPORT = NO
SIP_SUPPORT = NO
+IDL_PROPERTY_SUPPORT = YES
DISTRIBUTE_GROUP_DOC = NO
SUBGROUPING = YES
TYPEDEF_HIDES_STRUCT = NO
+SYMBOL_CACHE_SIZE = 0
#---------------------------------------------------------------------------
# Build related configuration options
#---------------------------------------------------------------------------
@@ -55,6 +58,7 @@ SHOW_INCLUDE_FILES = YES
INLINE_INFO = YES
SORT_MEMBER_DOCS = YES
SORT_BRIEF_DOCS = NO
+SORT_GROUP_NAMES = NO
SORT_BY_SCOPE_NAME = NO
GENERATE_TODOLIST = YES
GENERATE_TESTLIST = YES
@@ -62,9 +66,11 @@ GENERATE_BUGLIST = YES
GENERATE_DEPRECATEDLIST= YES
ENABLED_SECTIONS =
MAX_INITIALIZER_LINES = 30
-SHOW_USED_FILES = YES
SHOW_DIRECTORIES = NO
+SHOW_FILES = YES
+SHOW_NAMESPACES = YES
FILE_VERSION_FILTER =
+LAYOUT_FILE =
#---------------------------------------------------------------------------
# configuration options related to warning and progress messages
#---------------------------------------------------------------------------
@@ -122,18 +128,31 @@ HTML_HEADER =
HTML_FOOTER =
HTML_STYLESHEET =
HTML_ALIGN_MEMBERS = YES
-GENERATE_HTMLHELP = NO
-GENERATE_DOCSET = YES
HTML_DYNAMIC_SECTIONS = NO
+GENERATE_DOCSET = YES
+DOCSET_FEEDNAME = "Doxygen generated docs"
+DOCSET_BUNDLE_ID = org.doxygen.Project
+GENERATE_HTMLHELP = NO
CHM_FILE =
HHC_LOCATION =
GENERATE_CHI = NO
+CHM_INDEX_ENCODING =
BINARY_TOC = NO
TOC_EXPAND = NO
+GENERATE_QHP = NO
+QCH_FILE =
+QHP_NAMESPACE =
+QHP_VIRTUAL_FOLDER = doc
+QHP_CUST_FILTER_NAME =
+QHP_CUST_FILTER_ATTRS =
+QHP_SECT_FILTER_ATTRS =
+QHG_LOCATION =
DISABLE_INDEX = NO
ENUM_VALUES_PER_LINE = 4
-GENERATE_TREEVIEW = NO
+GENERATE_TREEVIEW = YES
+USE_INLINE_TREES = NO
TREEVIEW_WIDTH = 250
+FORMULA_FONTSIZE = 10
#---------------------------------------------------------------------------
# configuration options related to the LaTeX output
#---------------------------------------------------------------------------
@@ -149,6 +168,7 @@ PDF_HYPERLINKS = NO
USE_PDFLATEX = NO
LATEX_BATCHMODE = NO
LATEX_HIDE_INDICES = NO
+LATEX_SOURCE_CODE = NO
#---------------------------------------------------------------------------
# configuration options related to the RTF output
#---------------------------------------------------------------------------
@@ -211,6 +231,9 @@ CLASS_DIAGRAMS = YES
MSCGEN_PATH =
HIDE_UNDOC_RELATIONS = YES
HAVE_DOT = YES
+DOT_FONTNAME = FreeSans
+DOT_FONTSIZE = 10
+DOT_FONTPATH =
CLASS_GRAPH = YES
COLLABORATION_GRAPH = YES
GROUP_GRAPHS = YES
@@ -232,6 +255,6 @@ DOT_MULTI_TARGETS = NO
GENERATE_LEGEND = YES
DOT_CLEANUP = YES
#---------------------------------------------------------------------------
-# Configuration::additions related to the search engine
+# Options related to the search engine
#---------------------------------------------------------------------------
-SEARCHENGINE = NO
+SEARCHENGINE = YES
diff --git a/src/classdef.cpp b/src/classdef.cpp
index 198fc4d..168162b 100644
--- a/src/classdef.cpp
+++ b/src/classdef.cpp
@@ -294,7 +294,7 @@ QCString ClassDef::displayName() const
}
if (m_impl->compType==ClassDef::Protocol && n.right(2)=="-p")
{
- n="< "+n.left(n.length()-2)+" >";
+ n="<"+n.left(n.length()-2)+">";
}
return n;
}
@@ -1442,11 +1442,11 @@ void ClassDef::writeDocumentation(OutputList &ol)
}
}
- if (Config_getBool("SEARCHENGINE"))
- {
- Doxygen::searchIndex->setCurrentDoc(pageTitle,getOutputFileBase());
- Doxygen::searchIndex->addWord(localName(),TRUE);
- }
+ //if (Config_getBool("SEARCHENGINE"))
+ //{
+ // Doxygen::searchIndex->setCurrentDoc(pageTitle,getOutputFileBase());
+ // Doxygen::searchIndex->addWord(localName(),TRUE);
+ //}
bool exampleFlag=hasExamples();
//---------------------------------------- start flexible part -------------------------------
@@ -1801,7 +1801,9 @@ void ClassDef::writeMemberList(OutputList &ol)
ol.writeObjectLink(cd->getReference(),
cd->getOutputFileBase(),
0,
- cd->displayName());
+ md->category() ?
+ md->category()->displayName() :
+ cd->displayName());
ol.writeString("</td>");
ol.writeString("<td>");
}
@@ -2146,7 +2148,6 @@ static bool isStandardFunc(MemberDef *md)
* with that of this class. Must only be called for classes without
* subclasses!
*/
-
void ClassDef::mergeMembers()
{
if (m_impl->membersMerged) return;
@@ -2398,6 +2399,7 @@ void ClassDef::mergeMembers()
void ClassDef::mergeCategory(ClassDef *category)
{
category->setCategoryOf(this);
+ category->setArtificial(TRUE);
MemberNameInfoSDict *srcMnd = category->memberNameInfoSDict();
MemberNameInfoSDict *dstMnd = m_impl->allMemberNameInfoSDict;
@@ -2415,8 +2417,7 @@ void ClassDef::mergeCategory(ClassDef *category)
}
else // new method name
{
- // create a deep copy of the list (only the MemberInfo's will be
- // copied, not the actual MemberDef's)
+ // create a deep copy of the list
MemberNameInfo *newMni = 0;
newMni = new MemberNameInfo(srcMni->memberName());
@@ -2425,12 +2426,15 @@ void ClassDef::mergeCategory(ClassDef *category)
MemberInfo *mi;
for (;(mi=mnii.current());++mnii)
{
- //printf("Adding!\n");
+ //printf("Adding '%s'\n",mi->memberDef->name().data());
MemberInfo *newMi=new MemberInfo(mi->memberDef,mi->prot,mi->virt,mi->inherited);
newMi->scopePath=mi->scopePath;
newMi->ambigClass=mi->ambigClass;
- newMi->ambiguityResolutionScope=mi->ambiguityResolutionScope.copy();
+ newMi->ambiguityResolutionScope=mi->ambiguityResolutionScope;
newMni->append(newMi);
+ mi->memberDef->moveTo(this);
+ mi->memberDef->setCategory(category);
+ internalInsertMember(mi->memberDef,mi->prot,FALSE);
}
// add it to the dictionary
diff --git a/src/code.l b/src/code.l
index 27ddf50..02e6858 100644
--- a/src/code.l
+++ b/src/code.l
@@ -410,22 +410,22 @@ static void popScope()
static void setCurrentDoc(const QCString &name,const QCString &base,const QCString &anchor="")
{
- static bool searchEngineEnabled=Config_getBool("SEARCHENGINE") &&
- Config_getBool("SOURCE_BROWSER");
- if (searchEngineEnabled)
- {
- Doxygen::searchIndex->setCurrentDoc(name,base,anchor);
- }
+ //static bool searchEngineEnabled=Config_getBool("SEARCHENGINE") &&
+ // Config_getBool("SOURCE_BROWSER");
+ //if (searchEngineEnabled)
+ //{
+ // Doxygen::searchIndex->setCurrentDoc(name,base,anchor);
+ //}
}
static void addToSearchIndex(const char *text)
{
- static bool searchEngineEnabled=Config_getBool("SEARCHENGINE") &&
- Config_getBool("SOURCE_BROWSER");
- if (searchEngineEnabled)
- {
- Doxygen::searchIndex->addWord(text,FALSE);
- }
+ //static bool searchEngineEnabled=Config_getBool("SEARCHENGINE") &&
+ // Config_getBool("SOURCE_BROWSER");
+ //if (searchEngineEnabled)
+ //{
+ // Doxygen::searchIndex->addWord(text,FALSE);
+ //}
}
static void setClassScope(const QCString &name)
@@ -1928,7 +1928,7 @@ OPERATOR {ARITHOP}|{ASSIGNOP}|{LOGICOP}|{BITOP}
endFontClass();
BEGIN( Body );
}
-<Body>^[ \t]*"#" {
+<Body,Bases>^[ \t]*"#" {
startFontClass("preprocessor");
g_lastSkipCppContext = YY_START;
g_code->codify(yytext);
diff --git a/src/commentscan.l b/src/commentscan.l
index 181a15a..0ddb9fa 100644
--- a/src/commentscan.l
+++ b/src/commentscan.l
@@ -405,6 +405,7 @@ static int g_memberGroupId = DOX_NOGROUP;
static QCString g_memberGroupHeader;
static QCString g_memberGroupDocs;
static QCString g_memberGroupRelates;
+static QCString g_compoundName;
//-----------------------------------------------------------------------------
@@ -2033,6 +2034,11 @@ static bool handleExample(const QCString &)
static bool handleDetails(const QCString &)
{
+ if (inContext!=OutputBrief)
+ {
+ addOutput("\n\n"); // treat @details outside brief description
+ // as a new paragraph
+ }
setOutput(OutputDoc);
return FALSE;
}
@@ -2455,13 +2461,14 @@ bool parseCommentBlock(/* in */ ParserInterface *parser,
//---------------------------------------------------------------------------
-void groupEnterFile(const char *,int)
+void groupEnterFile(const char *fileName,int)
{
g_autoGroupStack.setAutoDelete(TRUE);
g_autoGroupStack.clear();
g_memberGroupId = DOX_NOGROUP;
g_memberGroupDocs.resize(0);
g_memberGroupRelates.resize(0);
+ g_compoundName=fileName;
}
void groupLeaveFile(const char *fileName,int line)
@@ -2488,10 +2495,21 @@ void groupEnterCompound(const char *fileName,int line,const char *name)
g_memberGroupId=DOX_NOGROUP;
g_memberGroupRelates.resize(0);
g_memberGroupDocs.resize(0);
+ g_compoundName = name;
+ int i = g_compoundName.find('(');
+ if (i!=-1)
+ {
+ g_compoundName=g_compoundName.left(i); // strip category (Obj-C)
+ }
+ if (g_compoundName.isEmpty())
+ {
+ g_compoundName=fileName;
+ }
}
void groupLeaveCompound(const char *,int,const char *)
{
+ //printf("groupLeaveCompound(%s)\n",name);
//if (g_memberGroupId!=DOX_NOGROUP)
//{
// warn(fileName,line,"Warning: end of compound %s while inside a member group\n",name);
@@ -2499,8 +2517,27 @@ void groupLeaveCompound(const char *,int,const char *)
g_memberGroupId=DOX_NOGROUP;
g_memberGroupRelates.resize(0);
g_memberGroupDocs.resize(0);
+ g_compoundName.resize(0);
}
+static int findExistingGroup(int &groupId,const MemberGroupInfo *info)
+{
+ //printf("findExistingGroup %s:%s\n",info->header.data(),info->compoundName.data());
+ QIntDictIterator<MemberGroupInfo> di(Doxygen::memGrpInfoDict);
+ MemberGroupInfo *mi;
+ for (di.toFirst();(mi=di.current());++di)
+ {
+ if (g_compoundName==mi->compoundName && // same file or scope
+ stricmp(mi->header,info->header)==0 // same header
+ )
+ {
+ //printf("Found it!\n");
+ return di.currentKey(); // put the item in this group
+ }
+ }
+ groupId++; // start new group
+ return groupId;
+}
void openGroup(Entry *e,const char *,int)
{
@@ -2515,11 +2552,11 @@ void openGroup(Entry *e,const char *,int)
if (g_memberGroupId==DOX_NOGROUP) // no group started yet
{
static int curGroupId=0;
- g_memberGroupId = curGroupId++;
- //printf("new group id=%d header=%s\n",g_memberGroupId,g_memberGroupHeader.data());
MemberGroupInfo *info = new MemberGroupInfo;
info->header = g_memberGroupHeader.stripWhiteSpace();
+ info->compoundName = g_compoundName;
+ g_memberGroupId = findExistingGroup(curGroupId,info);
Doxygen::memGrpInfoDict.insert(g_memberGroupId,info);
g_memberGroupRelates = e->relates;
diff --git a/src/config.l b/src/config.l
index 1f72fe6..2ee393e 100644
--- a/src/config.l
+++ b/src/config.l
@@ -178,11 +178,11 @@ void ConfigBool::convertStrToVal()
QCString val = m_valueString.stripWhiteSpace().lower();
if (!val.isEmpty())
{
- if (val=="yes" || val=="true" || val=="1")
+ if (val=="yes" || val=="true" || val=="1" || val=="all")
{
m_value=TRUE;
}
- else if (val=="no" || val=="false" || val=="0")
+ else if (val=="no" || val=="false" || val=="0" || val=="none")
{
m_value=FALSE;
}
diff --git a/src/config.xml b/src/config.xml
index 9d6e144..882c96b 100644
--- a/src/config.xml
+++ b/src/config.xml
@@ -873,27 +873,19 @@ the value YES disables it.
This tag can be used to set the number of enum values (range [1..20])
that doxygen will group on one line in the generated HTML documentation.
' minval='1' maxval='20' defval='4' depends='GENERATE_HTML'/>
- <option type='enum' id='GENERATE_TREEVIEW' defval='NONE' docs='
+ <option type='bool' id='GENERATE_TREEVIEW' defval='0' docs='
The GENERATE_TREEVIEW tag is used to specify whether a tree-like index
structure should be generated to display hierarchical information.
If the tag value is set to FRAME, a side panel will be generated
containing a tree-like index structure (just like the one that
is generated for HTML Help). For this to work a browser that supports
-JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+,
-Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are
-probably better off using the HTML help feature. Other possible values
-for this tag are: HIERARCHIES, which will generate the Groups, Directories,
-and Class Hierarchy pages using a tree view instead of an ordered list;
-ALL, which combines the behavior of FRAME and HIERARCHIES; and NONE, which
-disables this behavior completely. For backwards compatibility with previous
-releases of Doxygen, the values YES and NO are equivalent to FRAME and NONE
-respectively.
-' depends='GENERATE_HTML'>
- <value name='NONE'/>
- <value name='FRAME'/>
- <value name='HIERARCHIES'/>
- <value name='ALL'/>
- </option>
+JavaScript, DHTML, CSS and frames is required (i.e. any modern browser).
+Windows users are probably better off using the HTML help feature.
+' depends='GENERATE_HTML'/>
+ <option type='bool' id='USE_INLINE_TREES' defval='0' docs='
+By enabling USE_INLINE_TREES, doxygen will generate the Groups, Directories,
+and Class Hierarchy pages using a tree view instead of an ordered list.
+' depends='GENERATE_HTML'/>
<option type='int' id='TREEVIEW_WIDTH' docs='
If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be
used to set the initial width (in pixels) of the frame in which the tree
diff --git a/src/configoptions.cpp b/src/configoptions.cpp
index f95b834..bea89b6 100644
--- a/src/configoptions.cpp
+++ b/src/configoptions.cpp
@@ -630,14 +630,6 @@ void addConfigOptions(Config *cfg)
);
//----
cb = cfg->addBool(
- "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.",
- TRUE
- );
- //----
- cb = cfg->addBool(
"SHOW_DIRECTORIES",
"If the sources in your project are distributed over multiple directories \n"
"then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy \n"
@@ -1291,29 +1283,26 @@ void addConfigOptions(Config *cfg)
);
ci->addDependency("GENERATE_HTML");
//----
- ce = cfg->addEnum(
+ cb = cfg->addBool(
"GENERATE_TREEVIEW",
"The GENERATE_TREEVIEW tag is used to specify whether a tree-like index \n"
"structure should be generated to display hierarchical information. \n"
"If the tag value is set to FRAME, a side panel will be generated \n"
"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, DHTML, CSS and frames is required (for instance Mozilla 1.0+, \n"
- "Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are \n"
- "probably better off using the HTML help feature. Other possible values \n"
- "for this tag are: HIERARCHIES, which will generate the Groups, Directories, \n"
- "and Class Hierarchy pages using a tree view instead of an ordered list; \n"
- "ALL, which combines the behavior of FRAME and HIERARCHIES; and NONE, which \n"
- "disables this behavior completely. For backwards compatibility with previous \n"
- "releases of Doxygen, the values YES and NO are equivalent to FRAME and NONE \n"
- "respectively.",
- "NONE"
- );
- ce->addValue("NONE");
- ce->addValue("FRAME");
- ce->addValue("HIERARCHIES");
- ce->addValue("ALL");
- ce->addDependency("GENERATE_HTML");
+ "JavaScript, DHTML, CSS and frames is required (i.e. any modern browser). \n"
+ "Windows users are probably better off using the HTML help feature.",
+ FALSE
+ );
+ cb->addDependency("GENERATE_HTML");
+ //----
+ cb = cfg->addBool(
+ "USE_INLINE_TREES",
+ "By enabling USE_INLINE_TREES, doxygen will generate the Groups, Directories, \n"
+ "and Class Hierarchy pages using a tree view instead of an ordered list.",
+ FALSE
+ );
+ cb->addDependency("GENERATE_HTML");
//----
ci = cfg->addInt(
"TREEVIEW_WIDTH",
@@ -2095,6 +2084,8 @@ void addConfigOptions(Config *cfg)
FALSE
);
//----
+ cfg->addObsolete("SHOW_USED_FILES");
+ //----
cfg->addObsolete("USE_WINDOWS_ENCODING");
//----
cfg->addObsolete("DETAILS_AT_TOP");
diff --git a/src/docparser.cpp b/src/docparser.cpp
index 0295ba0..2def120 100644
--- a/src/docparser.cpp
+++ b/src/docparser.cpp
@@ -257,7 +257,7 @@ static QCString findAndCopyImage(const char *fileName,DocImage::Type type)
inImage.readBlock(buffer,inImage.size());
outImage.writeBlock(buffer,inImage.size());
outImage.flush();
- delete buffer;
+ delete[] buffer;
if (type==DocImage::Html) Doxygen::indexList.addImageFile(result);
}
else
@@ -1544,10 +1544,10 @@ DocWord::DocWord(DocNode *parent,const QString &word) :
m_parent(parent), m_word(word)
{
//printf("new word %s url=%s\n",word.data(),g_searchUrl.data());
- if (!g_searchUrl.isEmpty())
- {
- Doxygen::searchIndex->addWord(word,FALSE);
- }
+ //if (!g_searchUrl.isEmpty())
+ //{
+ // Doxygen::searchIndex->addWord(word,FALSE);
+ //}
}
//---------------------------------------------------------------------------
@@ -1560,10 +1560,10 @@ DocLinkedWord::DocLinkedWord(DocNode *parent,const QString &word,
m_tooltip(tooltip)
{
//printf("new word %s url=%s\n",word.data(),g_searchUrl.data());
- if (!g_searchUrl.isEmpty())
- {
- Doxygen::searchIndex->addWord(word,FALSE);
- }
+ //if (!g_searchUrl.isEmpty())
+ //{
+ // Doxygen::searchIndex->addWord(word,FALSE);
+ //}
}
//---------------------------------------------------------------------------
@@ -3832,7 +3832,7 @@ void DocSimpleSect::accept(DocVisitor *v)
v->visitPost(this);
}
-int DocSimpleSect::parse(bool userTitle)
+int DocSimpleSect::parse(bool userTitle,bool needsSeparator)
{
DBG(("DocSimpleSect::parse() start\n"));
g_nodeStack.push(this);
@@ -3856,6 +3856,7 @@ int DocSimpleSect::parse(bool userTitle)
((DocPara *)m_children.last())->markLast(FALSE);
}
par->markLast();
+ if (needsSeparator) m_children.append(new DocSimpleSectSep(this));
m_children.append(par);
// parse the contents of the paragraph
@@ -4136,6 +4137,7 @@ int DocParamSect::parse(const QString &cmdName,bool xmlContext, Direction d)
int DocPara::handleSimpleSection(DocSimpleSect::Type t, bool xmlContext)
{
DocSimpleSect *ss=0;
+ bool needsSeparator = FALSE;
if (!m_children.isEmpty() && // previous element
m_children.last()->kind()==Kind_SimpleSect && // was a simple sect
((DocSimpleSect *)m_children.last())->type()==t && // of same type
@@ -4143,6 +4145,7 @@ int DocPara::handleSimpleSection(DocSimpleSect::Type t, bool xmlContext)
{
// append to previous section
ss=(DocSimpleSect *)m_children.last();
+ needsSeparator = TRUE;
}
else // start new section
{
@@ -4156,7 +4159,7 @@ int DocPara::handleSimpleSection(DocSimpleSect::Type t, bool xmlContext)
}
else
{
- rv = ss->parse(t==DocSimpleSect::User);
+ rv = ss->parse(t==DocSimpleSect::User,needsSeparator);
}
return (rv!=TK_NEWPARA) ? rv : RetVal_OK;
}
@@ -6059,7 +6062,7 @@ void DocRoot::parse()
DocNode *validatingParseDoc(const char *fileName,int startLine,
Definition *ctx,MemberDef *md,
- const char *input,bool indexWords,
+ const char *input,bool /*indexWords*/,
bool isExample, const char *exampleName,
bool singleLine, bool linkFromIndex)
{
@@ -6071,7 +6074,7 @@ DocNode *validatingParseDoc(const char *fileName,int startLine,
//g_token = new TokenInfo;
// store parser state so we can re-enter this function if needed
- bool fortranOpt = Config_getBool("OPTIMIZE_FOR_FORTRAN");
+ //bool fortranOpt = Config_getBool("OPTIMIZE_FOR_FORTRAN");
docParserPushContext();
if (ctx &&
@@ -6098,9 +6101,9 @@ DocNode *validatingParseDoc(const char *fileName,int startLine,
}
//printf("g_context=%s\n",g_context.data());
+#if 0 // needed for PHP based search engine, now obsolete
if (indexWords && md && Config_getBool("SEARCHENGINE"))
{
-
g_searchUrl=md->getOutputFileBase();
Doxygen::searchIndex->setCurrentDoc(
(fortranOpt?theTranslator->trSubprogram(TRUE,TRUE):theTranslator->trMember(TRUE,TRUE))+" "+md->qualifiedName(),
@@ -6174,6 +6177,7 @@ DocNode *validatingParseDoc(const char *fileName,int startLine,
{
g_searchUrl="";
}
+#endif
g_fileName = fileName;
g_relPath = (!linkFromIndex && ctx) ?
@@ -6295,18 +6299,18 @@ void docFindSections(const char *input,
void initDocParser()
{
- if (Config_getBool("SEARCHENGINE"))
- {
- Doxygen::searchIndex = new SearchIndex;
- }
- else
- {
- Doxygen::searchIndex = 0;
- }
+// if (Config_getBool("SEARCHENGINE"))
+// {
+// Doxygen::searchIndex = new SearchIndex;
+// }
+// else
+// {
+// Doxygen::searchIndex = 0;
+// }
}
void finializeDocParser()
{
- delete Doxygen::searchIndex;
+// delete Doxygen::searchIndex;
}
diff --git a/src/docparser.h b/src/docparser.h
index fc930dd..5ecfb4b 100644
--- a/src/docparser.h
+++ b/src/docparser.h
@@ -126,7 +126,7 @@ class DocNode
Kind_Formula = 38,
Kind_SecRefItem = 39,
Kind_SecRefList = 40,
- //Kind_Language = 41,
+ Kind_SimpleSectSep = 41,
Kind_LinkedWord = 42,
Kind_ParamSect = 43,
Kind_ParamList = 44,
@@ -928,7 +928,7 @@ class DocSimpleSect : public CompAccept<DocSimpleSect>, public DocNode
QCString typeString() const;
DocNode *parent() const { return m_parent; }
void accept(DocVisitor *v);
- int parse(bool userTitle);
+ int parse(bool userTitle,bool needsSeparator);
int parseRcs();
int parseXml();
void appendLinkWord(const QString &word);
@@ -940,6 +940,21 @@ class DocSimpleSect : public CompAccept<DocSimpleSect>, public DocNode
DocTitle * m_title;
};
+/*! Node representing a separator between two simple sections of the
+ * same type.
+ */
+class DocSimpleSectSep : public DocNode
+{
+ public:
+ DocSimpleSectSep(DocNode *parent) : m_parent(parent) {}
+ Kind kind() const { return Kind_SimpleSectSep; }
+ DocNode *parent() const { return m_parent; }
+ void accept(DocVisitor *v) { v->visit(this); }
+
+ private:
+ DocNode *m_parent;
+};
+
/*! Node representing a parameter section */
class DocParamSect : public CompAccept<DocParamSect>, public DocNode
{
diff --git a/src/docsets.cpp b/src/docsets.cpp
index 2c12f37..fe43791 100644
--- a/src/docsets.cpp
+++ b/src/docsets.cpp
@@ -129,7 +129,7 @@ void DocSets::initialize()
err("Could not open file %s for writing\n",notes.data());
exit(1);
}
- QCString indexName=usingTreeIndex()?"main":"index";
+ QCString indexName=Config_getBool("GENERATE_TREEVIEW")?"main":"index";
m_nts.setDevice(m_nf);
m_nts.setEncoding(QTextStream::UnicodeUTF8);
m_nts << "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" << endl;
diff --git a/src/docvisitor.h b/src/docvisitor.h
index 9cbec1a..cb2c857 100644
--- a/src/docvisitor.h
+++ b/src/docvisitor.h
@@ -77,6 +77,7 @@ class DocParamList;
class DocInternalRef;
class DocCopy;
class DocText;
+class DocSimpleSectSep;
/*! @brief Abstract visitor that participates in the visitor pattern.
*/
@@ -105,6 +106,7 @@ class DocVisitor
virtual void visit(DocFormula *) = 0;
virtual void visit(DocLinkedWord *) = 0;
virtual void visit(DocIndexEntry *) = 0;
+ virtual void visit(DocSimpleSectSep *) = 0;
/*! @} */
/*! @name Visitor functions for internal nodes
diff --git a/src/dot.cpp b/src/dot.cpp
index a5c87cd..6382488 100644
--- a/src/dot.cpp
+++ b/src/dot.cpp
@@ -1129,7 +1129,7 @@ void DotGfxHierarchyTable::writeGraph(QTextStream &out,const char *path) const
}
Doxygen::indexList.addImageFile(imgName);
// write image and map in a table row
- QCString mapLabel = convertNameToFile(n->m_label);
+ QCString mapLabel = escapeCharsInString(n->m_label,FALSE);
out << "<tr><td><img src=\"" << imgName << "\" border=\"0\" alt=\"\" usemap=\"#"
<< mapLabel << "_map\"/>" << endl;
out << "<map name=\"" << mapLabel << "_map\" id=\"" << mapLabel << "\">" << endl;
@@ -1917,7 +1917,8 @@ QCString DotClassGraph::writeGraph(QTextStream &out,
if (format==BITMAP && generateImageMap) // produce HTML to include the image
{
- QCString mapLabel = convertNameToFile(m_startNode->m_label+"_"+mapName);
+ QCString mapLabel = escapeCharsInString(m_startNode->m_label,FALSE)+"_"+
+ escapeCharsInString(mapName,FALSE);
out << "<center><img src=\"" << relPath << baseName << "."
<< imgExt << "\" border=\"0\" usemap=\"#"
<< mapLabel << "\" alt=\"";
@@ -2191,7 +2192,7 @@ QCString DotInclDepGraph::writeGraph(QTextStream &out,
if (m_inverse) baseName+="_dep";
baseName+="_incl";
baseName=convertNameToFile(baseName);
- QCString mapName=m_startNode->m_label.copy();
+ QCString mapName=escapeCharsInString(m_startNode->m_label,FALSE);
if (m_inverse) mapName+="dep";
QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT");
@@ -2625,7 +2626,7 @@ QCString DotDirDeps::writeGraph(QTextStream &out,
QDir thisDir;
QCString baseName=m_dir->getOutputFileBase()+"_dep";
- QCString mapName=baseName;
+ QCString mapName=escapeCharsInString(baseName,FALSE);
QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT");
// todo: create check, update md5 checksum
@@ -3174,7 +3175,7 @@ QCString DotGroupCollaboration::writeGraph( QTextStream &t, GraphOutputFormat fo
if (writeImageMap)
{
- QCString mapLabel = convertNameToFile(baseName);
+ QCString mapLabel = escapeCharsInString(baseName,FALSE);
t << "<center><table><tr><td><img src=\"" << relPath << imgName
<< "\" border=\"0\" alt=\"\" usemap=\"#"
<< mapLabel << "_map\"/>" << endl;
diff --git a/src/doxygen.cpp b/src/doxygen.cpp
index 51bd291..81cb544 100644
--- a/src/doxygen.cpp
+++ b/src/doxygen.cpp
@@ -124,7 +124,7 @@ QDict<RefList> *Doxygen::xrefLists = new QDict<RefList>; // dictionary of cross
bool Doxygen::parseSourcesNeeded = FALSE;
double Doxygen::sysElapsedTime = 0.0;
QTime Doxygen::runningTime;
-SearchIndex * Doxygen::searchIndex=0;
+//SearchIndex * Doxygen::searchIndex=0;
QDict<DefinitionIntf> *Doxygen::symbolMap;
bool Doxygen::outputToWizard=FALSE;
QDict<int> * Doxygen::htmlDirMap = 0;
@@ -1168,8 +1168,8 @@ static void addClassToContext(EntryNav *rootNav)
}
cd=new ClassDef(root->fileName,root->startLine,fullName,sec,
tagName,refFileName);
- Debug::print(Debug::Classes,0," New class `%s' (sec=0x%08x)! #tArgLists=%d cd=%p\n",
- fullName.data(),root->section,root->tArgLists ? (int)root->tArgLists->count() : -1,cd);
+ Debug::print(Debug::Classes,0," New class `%s' (sec=0x%08x)! #tArgLists=%d\n",
+ fullName.data(),root->section,root->tArgLists ? (int)root->tArgLists->count() : -1);
cd->setDocumentation(root->doc,root->docFile,root->docLine); // copy docs to definition
cd->setBriefDescription(root->brief,root->briefFile,root->briefLine);
cd->setIsObjectiveC(root->objc);
@@ -7524,6 +7524,29 @@ static void flushUnresolvedRelations()
Doxygen::lookupCache.remove(ci.currentKey());
}
}
+
+ MemberNameSDict::Iterator fnli(*Doxygen::functionNameSDict);
+ MemberName *fn;
+ for (;(fn=fnli.current());++fnli) // for each global function name
+ {
+ MemberNameIterator fni(*fn);
+ MemberDef *fmd;
+ for (;(fmd=fni.current());++fni) // for each function with that name
+ {
+ fmd->invalidateCachedArgumentTypes();
+ }
+ }
+ MemberNameSDict::Iterator mnli(*Doxygen::memberNameSDict);
+ for (;(fn=mnli.current());++mnli) // for each class method name
+ {
+ MemberNameIterator mni(*fn);
+ MemberDef *fmd;
+ for (;(fmd=mni.current());++mni) // for each function with that name
+ {
+ fmd->invalidateCachedArgumentTypes();
+ }
+ }
+
}
//----------------------------------------------------------------------------
@@ -7763,7 +7786,7 @@ static void buildPageList(EntryNav *rootNav)
QCString title=root->args.stripWhiteSpace();
if (title.isEmpty()) title=theTranslator->trMainPage();
addRefItem(root->sli,"page",
- usingTreeIndex()?"main":"index",
+ Config_getBool("GENERATE_TREEVIEW")?"main":"index",
title
);
@@ -7783,7 +7806,7 @@ static void findMainPage(EntryNav *rootNav)
{
//printf("Found main page! \n======\n%s\n=======\n",root->doc.data());
QCString title=root->args.stripWhiteSpace();
- QCString indexName=usingTreeIndex()?"main":"index";
+ QCString indexName=Config_getBool("GENERATE_TREEVIEW")?"main":"index";
Doxygen::mainPage = new PageDef(root->fileName,root->startLine,
indexName, root->brief+root->doc+root->inbodyDocs,title);
//setFileNameForSections(root->anchors,"index",Doxygen::mainPage);
@@ -10230,7 +10253,7 @@ void generateOutput()
#if 0
if (Config_getBool("GENERATE_INDEXLOG")) Doxygen::indexList.addIndex(new IndexLog);
#endif
- if (usingTreeIndex()) Doxygen::indexList.addIndex(new FTVHelp);
+ if (Config_getBool("GENERATE_TREEVIEW")) Doxygen::indexList.addIndex(new FTVHelp);
if (Config_getBool("GENERATE_DOCSET")) Doxygen::indexList.addIndex(new DocSets);
Doxygen::indexList.initialize();
Doxygen::indexList.addImageFile("tab_r.gif");
@@ -10310,6 +10333,14 @@ void generateOutput()
g_outputList->writeStyleInfo(4); // write last part
g_outputList->enableAll();
+ // generate search indices (need to do this before writing other HTML
+ // pages as these contain a drop down menu with options depending on
+ // what categories we find in this function.
+ if (Config_getBool("SEARCHENGINE"))
+ {
+ writeSearchIndex();
+ }
+
//statistics();
// count the number of documented elements in the lists we have built.
@@ -10383,6 +10414,7 @@ void generateOutput()
msg("Generating file member index...\n");
writeFileMemberIndex(*g_outputList);
+
//writeDirDependencyGraph(Config_getString("HTML_OUTPUT"));
@@ -10493,12 +10525,16 @@ void generateOutput()
}
QDir::setCurrent(oldDir);
}
+
+#if 0 // old PHP based search engine
if (Config_getBool("SEARCHENGINE"))
{
msg("Generating search index\n");
HtmlGenerator::writeSearchPage();
Doxygen::searchIndex->write(Config_getString("HTML_OUTPUT")+"/search.idx");
}
+#endif
+
if (Debug::isFlagSet(Debug::Time))
{
msg("Total elapsed time: %.3f seconds\n(of which %.3f seconds waiting for external tools to finish)\n",
diff --git a/src/doxygen.h b/src/doxygen.h
index c8e8c58..1aee032 100644
--- a/src/doxygen.h
+++ b/src/doxygen.h
@@ -113,7 +113,7 @@ class Doxygen
static bool parseSourcesNeeded;
static double sysElapsedTime;
static QTime runningTime;
- static SearchIndex *searchIndex;
+ //static SearchIndex *searchIndex;
static QDict<DefinitionIntf> *symbolMap;
static bool outputToWizard;
static QDict<int> *htmlDirMap;
diff --git a/src/filedef.cpp b/src/filedef.cpp
index 85aa6ed..bcfcc01 100644
--- a/src/filedef.cpp
+++ b/src/filedef.cpp
@@ -168,7 +168,7 @@ void FileDef::writeDetailedDescription(OutputList &ol,const QCString &title)
{
ol.writeRuler();
ol.pushGeneratorState();
- ol.disable(OutputGenerator::Html);
+ ol.disableAllBut(OutputGenerator::Html);
ol.writeAnchor(0,"_details");
ol.popGeneratorState();
ol.startGroupHeader();
@@ -514,11 +514,11 @@ void FileDef::writeDocumentation(OutputList &ol)
ol.enableAll();
}
- if (Config_getBool("SEARCHENGINE"))
- {
- Doxygen::searchIndex->setCurrentDoc(pageTitle,getOutputFileBase());
- Doxygen::searchIndex->addWord(localName(),TRUE);
- }
+ //if (Config_getBool("SEARCHENGINE"))
+ //{
+ // Doxygen::searchIndex->setCurrentDoc(pageTitle,getOutputFileBase());
+ // Doxygen::searchIndex->addWord(localName(),TRUE);
+ //}
if (!Config_getString("GENERATE_TAGFILE").isEmpty())
{
diff --git a/src/fortrancode.l b/src/fortrancode.l
index 183f4d9..59b16fc 100644
--- a/src/fortrancode.l
+++ b/src/fortrancode.l
@@ -166,20 +166,24 @@ static void startFontClass(const char *s)
static void setCurrentDoc(const QCString &name,const QCString &base,const QCString &anchor="")
{
- static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
- if (searchEngineEnabled)
- {
- Doxygen::searchIndex->setCurrentDoc(name,base,anchor);
- }
+ (void)name;
+ (void)base;
+ (void)anchor;
+ //static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
+ //if (searchEngineEnabled)
+ //{
+ // Doxygen::searchIndex->setCurrentDoc(name,base,anchor);
+ //}
}
static void addToSearchIndex(const char *text)
{
- static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
- if (searchEngineEnabled)
- {
- Doxygen::searchIndex->addWord(text,FALSE);
- }
+ (void)text;
+ //static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
+ //if (searchEngineEnabled)
+ //{
+ // Doxygen::searchIndex->addWord(text,FALSE);
+ //}
}
/*! start a new line of code, inserting a line number if g_sourceFileDef
diff --git a/src/ftvhelp.cpp b/src/ftvhelp.cpp
index e602cfe..285988a 100644
--- a/src/ftvhelp.cpp
+++ b/src/ftvhelp.cpp
@@ -18,6 +18,7 @@
#include "message.h"
#include "doxygen.h"
#include "language.h"
+#include "htmlgen.h"
#define MAX_INDENT 1024
@@ -566,6 +567,7 @@ void FTVHelp::generateTreeView(QString* OutString)
{
QCString fileName;
QFile f;
+ static bool searchEngine = Config_getBool("SEARCHENGINE");
generateTreeViewImages();
@@ -621,12 +623,21 @@ void FTVHelp::generateTreeView(QString* OutString)
if (m_topLevelIndex)
{
+ if (searchEngine)
+ {
+ t << "<!-- This comment will put IE 6, 7 and 8 in quirks mode -->" << endl;
+ }
t << "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n";
t << "<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"en\" lang=\"en\">\n";
t << " <head>\n";
t << " <meta http-equiv=\"Content-Type\" content=\"text/xhtml;charset=UTF-8\"/>\n";
t << " <meta http-equiv=\"Content-Style-Type\" content=\"text/css\" />\n";
t << " <meta http-equiv=\"Content-Language\" content=\"en\" />\n";
+ if (searchEngine)
+ {
+ t << " <link href=\"search/search.css\" rel=\"stylesheet\" type=\"text/css\"/>" << endl;
+ t << " <script type=\"text/javaScript\" src=\"search/search.js\"></script>" << endl;
+ }
t << " <link rel=\"stylesheet\" href=\"";
QCString cssname=Config_getString("HTML_STYLESHEET");
if (cssname.isEmpty())
@@ -707,7 +718,32 @@ void FTVHelp::generateTreeView(QString* OutString)
{
t << " </head>\n";
t << "\n";
- t << " <body class=\"ftvtree\">\n";
+ t << " <body class=\"ftvtree\"";
+ if (searchEngine)
+ {
+ t << " onload='searchBox.OnSelectItem(0);'";
+ }
+ t << ">\n";
+ if (searchEngine)
+ {
+ t << " <script type=\"text/javascript\"><!--\n";
+ t << " var searchBox = new SearchBox(\"searchBox\", \"search\", true);\n";
+ t << " --></script>\n";
+ t << " <div id=\"MSearchBox\" class=\"MSearchBoxInactive\">\n";
+ t << " <div class=\"MSearchBoxRow\"><span class=\"MSearchBoxLeft\">\n";
+ t << " <input type=\"text\" id=\"MSearchField\" value=\"Search\" \n";
+ t << " onfocus=\"searchBox.OnSearchFieldFocus(true)\" \n";
+ t << " onblur=\"searchBox.OnSearchFieldFocus(false)\" \n";
+ t << " onkeyup=\"searchBox.OnSearchFieldChange()\"/>\n";
+ t << " </span><span class=\"MSearchBoxRight\">\n";
+ t << " <img id=\"MSearchSelect\" src=\"search/search.png\"\n";
+ t << " onmouseover=\"return searchBox.OnSearchSelectShow()\"\n";
+ t << " onmouseout=\"return searchBox.OnSearchSelectHide()\"\n";
+ t << " alt=\"\"/>\n";
+ t << " </span></div><div class=\"MSearchBoxSpacer\">&nbsp;</div>\n";
+ t << " </div>\n";
+ HtmlGenerator::writeSearchFooter(t,QCString());
+ }
t << " <div class=\"directory\">\n";
t << " <h3 class=\"swap\"><span>";
QCString &projName = Config_getString("PROJECT_NAME");
diff --git a/src/groupdef.cpp b/src/groupdef.cpp
index 23d897f..166acd8 100644
--- a/src/groupdef.cpp
+++ b/src/groupdef.cpp
@@ -812,6 +812,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
addGroupListToTitle(ol,this);
endTitle(ol,getOutputFileBase(),title);
+#if 0
if (Config_getBool("SEARCHENGINE"))
{
Doxygen::searchIndex->setCurrentDoc(title,getOutputFileBase());
@@ -823,6 +824,7 @@ void GroupDef::writeDocumentation(OutputList &ol)
p=i+l;
}
}
+#endif
if (!Config_getString("GENERATE_TAGFILE").isEmpty())
{
diff --git a/src/htmldocvisitor.cpp b/src/htmldocvisitor.cpp
index b24625f..f3c3393 100644
--- a/src/htmldocvisitor.cpp
+++ b/src/htmldocvisitor.cpp
@@ -474,6 +474,12 @@ void HtmlDocVisitor::visit(DocIndexEntry *)
{
}
+void HtmlDocVisitor::visit(DocSimpleSectSep *)
+{
+ m_t << "</dd>" << endl;
+ m_t << "<dd>" << endl;
+}
+
//--------------------------------------
// visitor functions for compound nodes
//--------------------------------------
@@ -542,6 +548,37 @@ bool isLastChildNode(T *parent, DocNode *node)
return parent->children().getLast()==node;
}
+bool isSeparatedParagraph(DocSimpleSect *parent,DocPara *par)
+{
+ QList<DocNode> nodes = parent->children();
+ int i = nodes.findRef(par);
+ if (i==-1) return FALSE;
+ int count = parent->children().count();
+ if (count>1 && i==0)
+ {
+ if (nodes.at(i+1)->kind()==DocNode::Kind_SimpleSectSep)
+ {
+ return TRUE;
+ }
+ }
+ else if (count>1 && i==count-1)
+ {
+ if (nodes.at(i-1)->kind()==DocNode::Kind_SimpleSectSep)
+ {
+ return TRUE;
+ }
+ }
+ else if (count>2 && i>0 && i<count-1)
+ {
+ if (nodes.at(i-1)->kind()==DocNode::Kind_SimpleSectSep &&
+ nodes.at(i+1)->kind()==DocNode::Kind_SimpleSectSep)
+ {
+ return TRUE;
+ }
+ }
+ return FALSE;
+}
+
int getParagraphContext(DocPara *p,bool &isFirst,bool &isLast)
{
int t=0;
@@ -592,6 +629,13 @@ int getParagraphContext(DocPara *p,bool &isFirst,bool &isLast)
isLast =isLastChildNode ((DocSimpleSect*)p->parent(),p);
if (isFirst) t=2;
if (isLast) t=4;
+ if (isSeparatedParagraph((DocSimpleSect*)p->parent(),p))
+ // if the paragraph is enclosed with separators it will
+ // be included in <dd>..</dd> so avoid addition paragraph
+ // markers
+ {
+ isFirst=isLast=TRUE;
+ }
break;
default:
break;
diff --git a/src/htmldocvisitor.h b/src/htmldocvisitor.h
index 929fb5c..a20d619 100644
--- a/src/htmldocvisitor.h
+++ b/src/htmldocvisitor.h
@@ -52,6 +52,7 @@ class HtmlDocVisitor : public DocVisitor
void visit(DocIncOperator *);
void visit(DocFormula *);
void visit(DocIndexEntry *);
+ void visit(DocSimpleSectSep *);
//--------------------------------------
// visitor functions for compound nodes
diff --git a/src/htmlgen.cpp b/src/htmlgen.cpp
index 49dd8e2..0383f55 100644
--- a/src/htmlgen.cpp
+++ b/src/htmlgen.cpp
@@ -48,9 +48,11 @@ static const char defaultStyleSheet[] =
#include "doxygen_css.h"
;
+#if 0 // old PHP based search engine
static const char search_script[]=
#include "search_php.h"
;
+#endif
static QCString g_header;
static QCString g_footer;
@@ -347,6 +349,141 @@ static unsigned char tab_r_gif[] = {
};
static unsigned int tab_r_gif_len = 2585;
+static unsigned char search_png[] = {
+ 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d,
+ 0x49, 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x10,
+ 0x08, 0x02, 0x00, 0x00, 0x00, 0x99, 0x7a, 0xc8, 0x4c, 0x00, 0x00, 0x01,
+ 0xd6, 0x49, 0x44, 0x41, 0x54, 0x28, 0x15, 0x8d, 0x92, 0xbb, 0xae, 0x41,
+ 0x51, 0x10, 0x86, 0xcf, 0x66, 0x0b, 0x22, 0x44, 0x23, 0x4a, 0xb7, 0xd0,
+ 0x11, 0x09, 0x71, 0x49, 0xbc, 0x82, 0xc2, 0x2b, 0xa0, 0xd6, 0x29, 0x74,
+ 0x1e, 0x42, 0xeb, 0x11, 0x44, 0x41, 0x43, 0x45, 0x27, 0x48, 0x08, 0x91,
+ 0x10, 0x51, 0xba, 0x14, 0x42, 0x21, 0x91, 0x10, 0x97, 0xf3, 0xb1, 0x9c,
+ 0x9d, 0x13, 0x97, 0x93, 0x33, 0xc5, 0xda, 0xb3, 0x66, 0xfe, 0xff, 0x9f,
+ 0x59, 0x33, 0x5b, 0xba, 0x5e, 0xaf, 0x5f, 0x77, 0xbb, 0x5c, 0x2e, 0xd2,
+ 0xdd, 0xc4, 0xf5, 0x3f, 0xa7, 0xac, 0x30, 0x3b, 0x9d, 0x4e, 0xbf, 0xdf,
+ 0x9f, 0x4e, 0xa7, 0x44, 0xdc, 0x6e, 0xb7, 0xdf, 0xef, 0x0f, 0x87, 0xc3,
+ 0x7f, 0x4b, 0x48, 0xa7, 0xd3, 0x89, 0x7a, 0xd5, 0x6a, 0xb5, 0x5c, 0x2e,
+ 0x9f, 0xcf, 0x67, 0xea, 0x43, 0x50, 0xa9, 0x54, 0x6a, 0xb5, 0x3a, 0x91,
+ 0x48, 0xc4, 0xe3, 0x71, 0xb2, 0x9f, 0x24, 0x64, 0x70, 0xad, 0x56, 0xab,
+ 0x54, 0x2a, 0x19, 0x0c, 0x86, 0x50, 0x28, 0xe4, 0xf5, 0x7a, 0x81, 0x0e,
+ 0x87, 0xc3, 0x76, 0xbb, 0x4d, 0xd0, 0x62, 0xb1, 0x44, 0xa3, 0xd1, 0x8f,
+ 0x64, 0x12, 0xdd, 0x6e, 0x97, 0xfa, 0x91, 0x48, 0x84, 0x3a, 0x5a, 0xad,
+ 0x96, 0x52, 0x4e, 0xa7, 0x13, 0xd1, 0x5a, 0xad, 0x46, 0x8a, 0xe6, 0xf1,
+ 0xdf, 0xf2, 0x55, 0x0c, 0x6c, 0x32, 0x99, 0x70, 0x52, 0xd6, 0x68, 0x34,
+ 0xea, 0xf5, 0x7a, 0x9d, 0x4e, 0x87, 0xc3, 0x55, 0xa4, 0xde, 0xd2, 0x44,
+ 0x50, 0x06, 0x21, 0xde, 0x49, 0x4d, 0x59, 0x7e, 0xcc, 0x8f, 0x07, 0x23,
+ 0x01, 0x82, 0x14, 0x36, 0x1a, 0x8d, 0x8a, 0xc5, 0xe2, 0x6f, 0x95, 0x54,
+ 0x2a, 0xc5, 0x03, 0x6f, 0xfd, 0xd0, 0x24, 0x67, 0xaf, 0xd7, 0x43, 0x48,
+ 0x41, 0x70, 0xc5, 0x77, 0xb9, 0x5c, 0x9c, 0xe0, 0x40, 0x2b, 0xd9, 0x64,
+ 0x32, 0x29, 0x46, 0x73, 0x23, 0xfb, 0x7c, 0x3e, 0xce, 0x66, 0xb3, 0x59,
+ 0xa9, 0x54, 0x56, 0xab, 0xd5, 0x72, 0xb9, 0xc4, 0x69, 0x34, 0x1a, 0x04,
+ 0xd9, 0x99, 0x98, 0x36, 0xe8, 0x74, 0x3a, 0x4d, 0x04, 0xa6, 0xc0, 0xe3,
+ 0x4b, 0x74, 0xb5, 0xdb, 0xed, 0xd8, 0x53, 0xbd, 0x5e, 0xa7, 0x6d, 0x1a,
+ 0x26, 0xca, 0xce, 0x18, 0x21, 0xa5, 0x6c, 0x36, 0x5b, 0x2e, 0x97, 0x33,
+ 0x99, 0x4c, 0x04, 0xb1, 0xc1, 0x60, 0xa0, 0x30, 0xb9, 0xaa, 0xf3, 0xf9,
+ 0x3c, 0x1c, 0xbb, 0xdd, 0x6e, 0x36, 0x9b, 0x41, 0x23, 0x04, 0xdf, 0xe3,
+ 0xf1, 0xb0, 0xa1, 0xed, 0x76, 0x4b, 0x17, 0xe3, 0xf1, 0x38, 0x18, 0x0c,
+ 0x32, 0x11, 0xd0, 0x56, 0xab, 0xf5, 0xa6, 0xf1, 0x63, 0x92, 0x78, 0x09,
+ 0x75, 0xf6, 0xfb, 0xfd, 0xe1, 0x70, 0x10, 0x05, 0x35, 0x1a, 0x0d, 0x8a,
+ 0x9b, 0xcd, 0xa6, 0x50, 0x28, 0xac, 0xd7, 0x6b, 0x87, 0xc3, 0x91, 0xcd,
+ 0x66, 0x59, 0xc1, 0x0f, 0xeb, 0xf1, 0xbd, 0xb5, 0x2d, 0x5e, 0x85, 0x0a,
+ 0xa6, 0x5c, 0x09, 0xa2, 0xb5, 0x58, 0x2c, 0xe0, 0xa3, 0x92, 0xc9, 0x64,
+ 0x02, 0x81, 0xc0, 0x33, 0x59, 0x70, 0x04, 0xff, 0x29, 0x47, 0x0a, 0xfe,
+ 0x7c, 0x3e, 0x9f, 0xcd, 0x66, 0xb1, 0x58, 0x8c, 0x5f, 0xe0, 0x09, 0xf6,
+ 0x68, 0x1b, 0xdc, 0x53, 0x42, 0x08, 0x11, 0x3f, 0x1e, 0x8f, 0xcc, 0x8f,
+ 0xb5, 0xbf, 0xfe, 0x67, 0x0f, 0x32, 0xd0, 0xdf, 0x0d, 0xbf, 0xb6, 0xf0,
+ 0x56, 0xfa, 0x1b, 0x21, 0x36, 0x05, 0xd3, 0x4d, 0xe6, 0x17, 0x7f, 0x00,
+ 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae, 0x42, 0x60, 0x82
+};
+static unsigned int search_png_len = 527;
+
+static unsigned char close_png[] = {
+ 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d,
+ 0x49, 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x0f,
+ 0x08, 0x02, 0x00, 0x00, 0x00, 0x5b, 0x76, 0x69, 0x23, 0x00, 0x00, 0x01,
+ 0xa0, 0x49, 0x44, 0x41, 0x54, 0x28, 0x15, 0x8d, 0x91, 0x3b, 0xaf, 0x01,
+ 0x51, 0x14, 0x85, 0xef, 0x3c, 0x5c, 0x42, 0xbc, 0x49, 0xbc, 0x12, 0x8d,
+ 0x02, 0x85, 0x76, 0x42, 0x49, 0xa3, 0x95, 0xe8, 0xfd, 0x1e, 0x9d, 0x9f,
+ 0x20, 0x51, 0xf2, 0x13, 0x24, 0x3a, 0x85, 0x82, 0x4a, 0xa2, 0x20, 0x9a,
+ 0x29, 0x86, 0x10, 0xef, 0x47, 0x98, 0xe1, 0x7e, 0x73, 0x8f, 0xea, 0x56,
+ 0xf7, 0x24, 0x8e, 0x73, 0xd6, 0x59, 0x7b, 0xed, 0xb5, 0xf6, 0x48, 0xcd,
+ 0x66, 0xf3, 0xeb, 0x7f, 0x4b, 0x95, 0x24, 0x49, 0x30, 0x5f, 0xaf, 0x97,
+ 0xae, 0xeb, 0xeb, 0xf5, 0xfa, 0x74, 0x3a, 0x01, 0xfa, 0x7c, 0xbe, 0x68,
+ 0x34, 0x9a, 0x4c, 0x26, 0x65, 0x59, 0x16, 0x84, 0x0f, 0xf5, 0x7e, 0xbf,
+ 0x4f, 0x26, 0x93, 0xdb, 0xed, 0xa6, 0xaa, 0xaa, 0xcb, 0xe5, 0xe2, 0xf9,
+ 0xf9, 0x7c, 0x52, 0xb9, 0xd9, 0x6c, 0xf2, 0xf9, 0x3c, 0x08, 0x6c, 0xbb,
+ 0x02, 0xbd, 0xf1, 0x78, 0x0c, 0xbb, 0x58, 0x2c, 0xa2, 0xf4, 0xfd, 0xbb,
+ 0x50, 0xd5, 0x34, 0xcd, 0x34, 0xcd, 0xd9, 0x6c, 0x06, 0x01, 0x9a, 0xca,
+ 0x8f, 0x6a, 0x78, 0xa5, 0x52, 0xa9, 0x5c, 0x2e, 0x1f, 0x0e, 0x87, 0x6e,
+ 0xb7, 0x0b, 0x58, 0xab, 0xd5, 0xc2, 0xe1, 0x30, 0xf2, 0xa3, 0xd1, 0x68,
+ 0xb5, 0x5a, 0xc5, 0xe3, 0x71, 0xdb, 0x00, 0xfe, 0x1c, 0x0e, 0xc7, 0x72,
+ 0xb9, 0x84, 0xe7, 0xf7, 0xfb, 0xeb, 0xf5, 0xba, 0x65, 0x59, 0xf0, 0x2e,
+ 0x97, 0xcb, 0x74, 0x3a, 0x7d, 0xbf, 0xdf, 0xfb, 0xfd, 0x3e, 0x91, 0x48,
+ 0xc8, 0x50, 0xc9, 0x81, 0x45, 0x8c, 0xf6, 0x7a, 0xbd, 0xe3, 0xf1, 0x18,
+ 0x0c, 0x06, 0x23, 0x91, 0x08, 0xbc, 0x4e, 0xa7, 0xb3, 0xdd, 0x6e, 0x11,
+ 0xa6, 0x27, 0x34, 0xdb, 0x2b, 0x7f, 0x8a, 0xa2, 0x00, 0x71, 0xc0, 0x1c,
+ 0x08, 0x8b, 0x58, 0x8f, 0xc7, 0x03, 0xdb, 0xa8, 0xf0, 0x0a, 0x62, 0x3f,
+ 0x87, 0x42, 0x21, 0x4e, 0xc4, 0x14, 0xfe, 0xce, 0xe7, 0x33, 0x4e, 0xd0,
+ 0x6e, 0x34, 0x1a, 0x84, 0x83, 0xe0, 0xf5, 0x7a, 0xd9, 0x6d, 0x55, 0x86,
+ 0x47, 0xc6, 0x5c, 0x2e, 0x47, 0x8d, 0xe8, 0xdb, 0x6e, 0xb7, 0xf1, 0x17,
+ 0x08, 0x04, 0x0a, 0x85, 0x02, 0x7d, 0x18, 0x0b, 0x34, 0xa5, 0x5a, 0xad,
+ 0x72, 0x32, 0x0c, 0x83, 0x39, 0x90, 0xa0, 0xdf, 0xef, 0xef, 0x76, 0x3b,
+ 0xcc, 0xcc, 0xe7, 0x73, 0x3c, 0x0c, 0x06, 0x03, 0x0a, 0xb2, 0xd9, 0x2c,
+ 0x05, 0x52, 0xab, 0xd5, 0xa2, 0xc2, 0xe3, 0xf1, 0x0c, 0x87, 0xc3, 0xeb,
+ 0xf5, 0x8a, 0x3c, 0x3c, 0xfc, 0x01, 0x32, 0x07, 0xb7, 0xdb, 0xcd, 0x10,
+ 0xb1, 0xc4, 0xd5, 0x86, 0x58, 0x64, 0xac, 0x54, 0x2a, 0x8b, 0xc5, 0x82,
+ 0xc1, 0x09, 0x55, 0xc4, 0x62, 0xb1, 0x58, 0x3a, 0x9d, 0xe6, 0x2a, 0x38,
+ 0x9f, 0x0f, 0x8b, 0x18, 0x73, 0x49, 0xa5, 0x52, 0x99, 0x4c, 0xc6, 0xe9,
+ 0x74, 0xf2, 0x46, 0x7c, 0xc6, 0x07, 0xc8, 0x99, 0x4c, 0xec, 0x1f, 0x55,
+ 0x51, 0x47, 0x23, 0xd1, 0x4b, 0x5c, 0xff, 0xec, 0x3f, 0x83, 0x85, 0xe4,
+ 0x1a, 0x44, 0x83, 0x01, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e,
+ 0x44, 0xae, 0x42, 0x60, 0x82
+};
+static unsigned int close_png_len = 473;
+
+static unsigned char close_active_png[] = {
+ 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d,
+ 0x49, 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x0f,
+ 0x08, 0x02, 0x00, 0x00, 0x00, 0x5b, 0x76, 0x69, 0x23, 0x00, 0x00, 0x01,
+ 0xa0, 0x49, 0x44, 0x41, 0x54, 0x28, 0x15, 0x8d, 0x91, 0x3d, 0x8f, 0x01,
+ 0x51, 0x14, 0x86, 0x77, 0x3e, 0xd6, 0x47, 0x22, 0xbe, 0x82, 0x10, 0x14,
+ 0xa2, 0x21, 0x12, 0x09, 0x89, 0x0a, 0x85, 0x4a, 0x68, 0xf4, 0x12, 0x3f,
+ 0x82, 0x52, 0xaf, 0x92, 0x68, 0x75, 0x5a, 0x7f, 0x41, 0x42, 0x47, 0xa3,
+ 0xa0, 0x42, 0x68, 0x49, 0x44, 0x47, 0x10, 0xf1, 0x11, 0xec, 0x33, 0x7b,
+ 0x67, 0xb7, 0xd8, 0x6a, 0x4f, 0x32, 0x33, 0x77, 0xee, 0x79, 0xce, 0x7b,
+ 0xdf, 0x73, 0xae, 0xd4, 0xe9, 0x74, 0x3e, 0xfe, 0x17, 0xea, 0x2f, 0xf6,
+ 0x7c, 0x3e, 0x17, 0x8b, 0xc5, 0x66, 0xb3, 0xd9, 0xef, 0xf7, 0x92, 0x24,
+ 0x39, 0x9d, 0xce, 0x40, 0x20, 0x10, 0x8d, 0x46, 0x15, 0x45, 0x11, 0x8c,
+ 0x8e, 0x9e, 0xcf, 0xe7, 0xc1, 0x60, 0xc0, 0x5b, 0x55, 0x55, 0xa3, 0xd1,
+ 0x28, 0xcb, 0xf2, 0xe5, 0x72, 0x59, 0x2e, 0x97, 0x54, 0x66, 0xb3, 0x59,
+ 0x8b, 0xc5, 0x02, 0x2d, 0xf3, 0xa0, 0xd7, 0xef, 0xf7, 0xc9, 0x55, 0x2a,
+ 0x95, 0x70, 0x38, 0xfc, 0xf9, 0x1d, 0x7e, 0xbf, 0xbf, 0x5c, 0x2e, 0xdf,
+ 0x6e, 0xb7, 0xd1, 0x68, 0x04, 0x00, 0xa6, 0x94, 0x4a, 0xa5, 0xf9, 0x7c,
+ 0x4e, 0x35, 0x5c, 0xb1, 0x58, 0x4c, 0x26, 0x93, 0xb3, 0xd9, 0xcc, 0x6c,
+ 0x36, 0xd7, 0x6a, 0xb5, 0x58, 0x2c, 0x66, 0xb5, 0x5a, 0x27, 0x93, 0x09,
+ 0x1e, 0x5c, 0x2e, 0x97, 0x66, 0x60, 0xbd, 0x5e, 0x73, 0xee, 0x78, 0x3c,
+ 0x4e, 0xa7, 0xd3, 0xe4, 0xaa, 0xd5, 0xea, 0xeb, 0xf5, 0x72, 0x38, 0x1c,
+ 0x9c, 0x33, 0x1c, 0x0e, 0xdf, 0xef, 0xf7, 0x6e, 0xb7, 0x8b, 0x44, 0x22,
+ 0x9a, 0x81, 0xc3, 0xe1, 0x00, 0xba, 0xdd, 0x6e, 0x5b, 0xad, 0xd6, 0xf1,
+ 0x78, 0xb4, 0xd9, 0x6c, 0x82, 0x6b, 0x36, 0x9b, 0xd8, 0xa5, 0xc5, 0xd3,
+ 0xe9, 0x04, 0xa6, 0xa1, 0x34, 0x21, 0x02, 0x4f, 0xc2, 0x16, 0x9b, 0x8f,
+ 0xc7, 0x03, 0x55, 0x83, 0xc1, 0x80, 0x0a, 0xa1, 0xa3, 0x1e, 0x8f, 0x87,
+ 0x15, 0x6f, 0xfc, 0x09, 0x3d, 0xa1, 0x5d, 0xaf, 0xd7, 0x83, 0xc1, 0x20,
+ 0x29, 0x36, 0x75, 0x34, 0x14, 0x0a, 0x61, 0x2e, 0x97, 0xcb, 0xfd, 0x9e,
+ 0xdb, 0x68, 0x34, 0x04, 0x9d, 0xcf, 0xe7, 0x39, 0x47, 0x14, 0x68, 0x13,
+ 0xf0, 0x7a, 0xbd, 0x74, 0x36, 0x9d, 0x4e, 0xed, 0x76, 0x7b, 0xb7, 0xdb,
+ 0x5d, 0xad, 0x56, 0xd7, 0xeb, 0x95, 0xb1, 0x30, 0xb4, 0x76, 0xbb, 0xed,
+ 0x76, 0xbb, 0x53, 0xa9, 0x14, 0x05, 0x92, 0xb8, 0x58, 0xc6, 0xde, 0xeb,
+ 0xf5, 0xb8, 0x27, 0xfa, 0xa5, 0x0f, 0x61, 0x8e, 0x34, 0xc5, 0x85, 0x42,
+ 0x81, 0x4a, 0x0c, 0x68, 0xaa, 0x7c, 0x20, 0x12, 0x89, 0x84, 0xc9, 0x64,
+ 0x62, 0x41, 0x37, 0x74, 0xe9, 0xf3, 0xf9, 0xe2, 0xf1, 0x78, 0x26, 0x93,
+ 0xe1, 0x97, 0x4d, 0x18, 0xfd, 0x62, 0xf1, 0x8a, 0x24, 0x57, 0xc5, 0xd8,
+ 0xe9, 0x9a, 0xc4, 0xfd, 0x7e, 0x47, 0x8c, 0x4d, 0xd6, 0x22, 0x74, 0x54,
+ 0xfc, 0x20, 0x40, 0xfc, 0xa4, 0xfe, 0x7e, 0xbf, 0x00, 0xa8, 0x79, 0xe1,
+ 0x90, 0xdb, 0x2c, 0x9e, 0xe1, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e,
+ 0x44, 0xae, 0x42, 0x60, 0x82
+};
+static unsigned int close_active_png_len = 473;
static const char tabs_css[] =
"/* tabs styles, based on http://www.alistapart.com/articles/slidingdoors */\n"
@@ -408,7 +545,7 @@ static const char tabs_css[] =
" white-space : nowrap;\n"
"}\n"
"\n"
-"DIV.tabs INPUT\n"
+"DIV.tabs #MSearchBox\n"
"{\n"
" float : right;\n"
" display : inline;\n"
@@ -456,25 +593,15 @@ static const char tabs_css[] =
"}\n"
;
-struct tab_data_item
+struct img_data_item
{
const char *name;
unsigned char *content;
unsigned int len;
};
-static tab_data_item tab_data[] =
+static void writeImgData(const char *dir,img_data_item *data)
{
- { "tab_b.gif", tab_b_gif, tab_b_gif_len },
- { "tab_l.gif", tab_l_gif, tab_l_gif_len },
- { "tab_r.gif", tab_r_gif, tab_r_gif_len },
- { "tabs.css", (unsigned char *)tabs_css, 0 },
- { 0, 0, 0 }
-};
-
-static void writeTabData(const char *dir)
-{
- tab_data_item *data = tab_data;
while (data->name)
{
QCString fileName;
@@ -493,6 +620,34 @@ static void writeTabData(const char *dir)
}
}
+static img_data_item tab_data[] =
+{
+ { "tab_b.gif", tab_b_gif, tab_b_gif_len },
+ { "tab_l.gif", tab_l_gif, tab_l_gif_len },
+ { "tab_r.gif", tab_r_gif, tab_r_gif_len },
+ { "tabs.css", (unsigned char *)tabs_css, 0 },
+ { 0, 0, 0 }
+};
+
+static void writeTabData(const char *dir)
+{
+ writeImgData(dir,tab_data);
+}
+
+static img_data_item search_data[] =
+{
+ { "search.png", search_png, search_png_len },
+ { "close.png", close_png, close_png_len },
+ { "close_active.png", close_active_png, close_active_png_len },
+ { 0, 0, 0 }
+};
+
+void HtmlGenerator::writeSearchData(const char *dir)
+{
+ writeImgData(dir,search_data);
+}
+
+
//------------------------------------------------------------------------
unsigned char open_gif[] = {
@@ -568,6 +723,12 @@ static void writeDefaultHeaderFile(QTextStream &t, const char *title,
else
relPathStr=relPath;
+ static bool generateTreeView = Config_getBool("GENERATE_TREEVIEW");
+ static bool searchEngine = Config_getBool("SEARCHENGINE");
+ if (searchEngine && !generateTreeView)
+ {
+ t << "<!-- This comment will put IE 6, 7 and 8 in quirks mode -->" << endl;
+ }
// t << "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">\n";
// t << "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">\n";
t << "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n";
@@ -577,6 +738,11 @@ static void writeDefaultHeaderFile(QTextStream &t, const char *title,
t << convertToHtml(title);
t << "</title>\n";
t << "<link href=\"" << relPathStr << "tabs.css\" rel=\"stylesheet\" type=\"text/css\"/>\n";
+ if (searchEngine && !generateTreeView)
+ {
+ t << "<link href=\"" << relPathStr << "search/search.css\" rel=\"stylesheet\" type=\"text/css\"/>\n";
+ t << "<script type=\"text/javaScript\" src=\"" << relPathStr << "search/search.js\"></script>\n";
+ }
t << "<link ";
t << "href=\"";
if (Config_getString("HTML_STYLESHEET").isEmpty())
@@ -595,7 +761,15 @@ static void writeDefaultHeaderFile(QTextStream &t, const char *title,
}
t << "\" rel=\"stylesheet\" type=\"text/css\"/>\n";
- t << "</head>\n<body>\n";
+ t << "</head>\n";
+ if (searchEngine && !generateTreeView)
+ {
+ t << "<body onload='searchBox.OnSelectItem(0);'>\n";
+ }
+ else
+ {
+ t << "<body>\n";
+ }
}
@@ -706,12 +880,51 @@ void HtmlGenerator::startFile(const char *name,const char *,
}
t << "<!-- " << theTranslator->trGeneratedBy() << " Doxygen "
<< versionString << " -->" << endl;
+ static bool generateTreeView = Config_getBool("GENERATE_TREEVIEW");
+ static bool searchEngine = Config_getBool("SEARCHENGINE");
+ if (searchEngine && !generateTreeView)
+ {
+ t << "<script type=\"text/javascript\"><!--\n";
+ t << "var searchBox = new SearchBox(\"searchBox\", \""
+ << relPath<< "search\",false);\n";
+ t << "--></script>\n";
+ }
generateDynamicSections(t,relPath);
}
+void HtmlGenerator::writeSearchFooter(QTextStream &t,const QCString &relPath)
+{
+ t << "<!--- window showing the filter options -->\n";
+ t << "<div id=\"MSearchSelectWindow\"\n";
+ t << " onmouseover=\"return searchBox.OnSearchSelectShow()\"\n";
+ t << " onmouseout=\"return searchBox.OnSearchSelectHide()\">\n";
+ writeSearchCategories(t);
+ t << "</div>\n";
+ t << "\n";
+ t << "<!-- iframe showing the search results (closed by default) -->\n";
+ t << "<div id=\"MSearchResultsWindow\">\n";
+ t << "<a href=\"javascript:searchBox.CloseResultsWindow()\" \n";
+ t << " id=\"MSearchResultsWindowClose\"\n";
+ t << " onmouseover=\"return searchBox.OnCloseHighlight(true)\"\n";
+ t << " onmouseout=\"return searchBox.OnCloseHighlight(false)\">"
+ << "<img border=\"0\" src=\"" << relPath << "search/close.png\" "
+ << "alt=\"\"/></a>\n";
+ t << "<iframe src=\"\" frameborder=\"0\" \n";
+ t << " name=\"MSearchResults\" id=\"MSearchResults\">\n";
+ t << "</iframe>\n";
+ t << "</div>\n";
+ t << "\n";
+}
+
static void writePageFooter(QTextStream &t,const QCString &lastTitle,
const QCString relPath)
{
+ static bool generateTreeView = Config_getBool("GENERATE_TREEVIEW");
+ static bool searchEngine = Config_getBool("SEARCHENGINE");
+ if (searchEngine && !generateTreeView)
+ {
+ HtmlGenerator::writeSearchFooter(t,relPath);
+ }
if (g_footer.isEmpty())
{
t << "<hr size=\"1\"/><address style=\"text-align: right;\"><small>";
@@ -988,8 +1201,9 @@ void HtmlGenerator::endTextLink()
void HtmlGenerator::startHtmlLink(const char *url)
{
+ static bool generateTreeView = Config_getBool("GENERATE_TREEVIEW");
t << "<a ";
- if (usingTreeIndex()) t << "target=\"top\" ";
+ if (generateTreeView) t << "target=\"top\" ";
t << "href=\"";
if (url) t << url;
t << "\">";
@@ -1151,6 +1365,8 @@ void HtmlGenerator::endClassDiagram(const ClassDiagram &d,
t << "_map\" alt=\"\"/>" << endl;
t << "<map id=\"";
docify(name);
+ t << "_map\" name=\"";
+ docify(name);
t << "_map\">" << endl;
d.writeImage(t,dir,relPath,fileName);
@@ -1273,7 +1489,7 @@ void HtmlGenerator::startMemberSections()
{
t << "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\">" << endl;
// HTML is not recursively decomposable, sorry
- t << "<tr><td></td></tr>" << endl;
+ //t << "<tr><td></td></tr>" << endl;
}
}
@@ -1291,7 +1507,7 @@ void HtmlGenerator::startMemberHeader()
DBG_HTML(t << "<!-- startMemberHeader -->" << endl)
if (Config_getBool("HTML_ALIGN_MEMBERS"))
{
- t << "<tr><td colspan=\"2\"><br/><h2>";
+ t << "<tr><td colspan=\"2\"><h2>";
}
else
{
@@ -1840,6 +2056,7 @@ static void renderQuickLinksAsTabs(QTextStream &t,const QCString &relPath,
}
if (hlEntry->parent()==LayoutDocManager::instance().rootNavEntry())
{
+#if 0 // old PHP based search engine
// last item of the top row -> special case for search engine
if (Config_getBool("SEARCHENGINE"))
{
@@ -1864,6 +2081,25 @@ static void renderQuickLinksAsTabs(QTextStream &t,const QCString &relPath,
{
endQuickIndexList(t,TRUE);
}
+#endif
+ static bool generateTreeView = Config_getBool("GENERATE_TREEVIEW");
+ static bool searchEngine = Config_getBool("SEARCHENGINE");
+ if (searchEngine && !generateTreeView)
+ {
+ t << " <li>\n";
+ t << " <div id=\"MSearchBox\" class=\"MSearchBoxInactive\">\n";
+ t << " <img id=\"MSearchSelect\" src=\"" << relPath << "search/search.png\"\n";
+ t << " onmouseover=\"return searchBox.OnSearchSelectShow()\"\n";
+ t << " onmouseout=\"return searchBox.OnSearchSelectHide()\"\n";
+ t << " alt=\"\"/>\n";
+ t << " <input type=\"text\" id=\"MSearchField\" value=\"Search\" \n";
+ t << " onfocus=\"searchBox.OnSearchFieldFocus(true)\" \n";
+ t << " onblur=\"searchBox.OnSearchFieldFocus(false)\" \n";
+ t << " onkeyup=\"searchBox.OnSearchFieldChange()\"/>\n";
+ t << " </div>\n";
+ t << " </li>\n";
+ }
+ endQuickIndexList(t,TRUE);
}
else // normal case
{
@@ -1953,6 +2189,7 @@ void HtmlGenerator::writeQuickLinks(bool compact,HighlightedItem hli)
writeDefaultQuickLinks(t,compact,hli,relPath);
}
+#if 0 // old PHP based search results page
void HtmlGenerator::writeSearchPage()
{
if (Config_getBool("SEARCHENGINE") && Config_getBool("GENERATE_HTML"))
@@ -2030,6 +2267,7 @@ void HtmlGenerator::writeSearchPage()
}
}
}
+#endif
void HtmlGenerator::generateSectionImages()
{
diff --git a/src/htmlgen.h b/src/htmlgen.h
index 76467a2..f710c69 100644
--- a/src/htmlgen.h
+++ b/src/htmlgen.h
@@ -244,7 +244,8 @@ class HtmlGenerator : public OutputGenerator
{ t << "<a name=\"" << anchor << "\"></a>"; }
void linkableSymbol(int,const char *,Definition *,Definition *) {}
- static void writeSearchPage();
+ static void writeSearchFooter(QTextStream &t,const QCString &relPath);
+ static void writeSearchData(const char *dir);
static void generateSectionImages();
private:
diff --git a/src/htmlhelp.cpp b/src/htmlhelp.cpp
index d11d16d..f120a93 100644
--- a/src/htmlhelp.cpp
+++ b/src/htmlhelp.cpp
@@ -464,7 +464,7 @@ void HtmlHelp::createProjectFile()
QCString indexName="index"+Doxygen::htmlFileExtension;
- if (usingTreeIndex()) indexName="main"+Doxygen::htmlFileExtension;
+ if (Config_getBool("GENERATE_TREEVIEW")) indexName="main"+Doxygen::htmlFileExtension;
t << "[OPTIONS]\n";
if (!Config_getString("CHM_FILE").isEmpty())
{
diff --git a/src/index.cpp b/src/index.cpp
index bcfe4eb..ae71d93 100644
--- a/src/index.cpp
+++ b/src/index.cpp
@@ -35,6 +35,7 @@
#include "util.h"
#include "groupdef.h"
#include "language.h"
+#include "htmlgen.h"
#include "htmlhelp.h"
#include "ftvhelp.h"
#include "dot.h"
@@ -45,6 +46,14 @@
#define MAX_ITEMS_BEFORE_MULTIPAGE_INDEX 200
#define MAX_ITEMS_BEFORE_QUICK_INDEX 30
+static const char search_styleSheet[] =
+#include "search_css.h"
+;
+
+static const char search_script[]=
+#include "search_js.h"
+;
+
int annotatedClasses;
int hierarchyClasses;
int documentedFiles;
@@ -632,9 +641,9 @@ void writeHierarchicalIndex(OutputList &ol)
ol.parseText(theTranslator->trClassHierarchyDescription());
ol.endTextBlock();
- FTVHelp* ftv = NULL;
- QCString& TreeView=Config_getEnum("GENERATE_TREEVIEW");
- if (TreeView=="HIERARCHIES" || TreeView=="ALL")
+ FTVHelp* ftv = 0;
+ bool treeView=Config_getBool("USE_INLINE_TREES");
+ if (treeView)
ftv = new FTVHelp(false);
writeClassHierarchy(ol,ftv);
@@ -2172,6 +2181,605 @@ void writeNamespaceMemberIndex(OutputList &ol)
//----------------------------------------------------------------------------
+#define NUM_SEARCH_INDICES 13
+#define SEARCH_INDEX_ALL 0
+#define SEARCH_INDEX_CLASSES 1
+#define SEARCH_INDEX_NAMESPACES 2
+#define SEARCH_INDEX_FILES 3
+#define SEARCH_INDEX_FUNCTIONS 4
+#define SEARCH_INDEX_VARIABLES 5
+#define SEARCH_INDEX_TYPEDEFS 6
+#define SEARCH_INDEX_ENUMS 7
+#define SEARCH_INDEX_ENUMVALUES 8
+#define SEARCH_INDEX_PROPERTIES 9
+#define SEARCH_INDEX_EVENTS 10
+#define SEARCH_INDEX_RELATED 11
+#define SEARCH_INDEX_DEFINES 12
+
+class SearchIndexList : public SDict< QList<Definition> >
+{
+ public:
+ SearchIndexList(int size=17) : SDict< QList<Definition> >(size,FALSE) {}
+ ~SearchIndexList() {}
+ void append(Definition *d)
+ {
+ QList<Definition> *l = find(d->name());
+ if (l==0)
+ {
+ l=new QList<Definition>;
+ SDict< QList<Definition> >::append(d->name(),l);
+ }
+ l->append(d);
+ }
+ int compareItems(GCI item1, GCI item2)
+ {
+ QList<Definition> *md1=(QList<Definition> *)item1;
+ QList<Definition> *md2=(QList<Definition> *)item2;
+ QCString n1 = md1->first()->localName();
+ QCString n2 = md2->first()->localName();
+ return stricmp(n1.data(),n2.data());
+ }
+};
+
+static void addMemberToSearchIndex(
+ SearchIndexList symbols[NUM_SEARCH_INDICES][MEMBER_INDEX_ENTRIES],
+ int symbolCount[NUM_SEARCH_INDICES],
+ MemberDef *md)
+{
+ static bool hideFriendCompounds = Config_getBool("HIDE_FRIEND_COMPOUNDS");
+ bool isLinkable = md->isLinkable();
+ ClassDef *cd=0;
+ NamespaceDef *nd=0;
+ FileDef *fd=0;
+ if (isLinkable &&
+ (cd=md->getClassDef()) &&
+ cd->isLinkable() &&
+ cd->templateMaster()==0)
+ {
+ QCString n = md->name();
+ int letter = tolower(n.at(0)) & 0x7f;
+ if (!n.isEmpty())
+ {
+ bool isFriendToHide = hideFriendCompounds &&
+ (QCString(md->typeString())=="friend class" ||
+ QCString(md->typeString())=="friend struct" ||
+ QCString(md->typeString())=="friend union");
+ if (!(md->isFriend() && isFriendToHide))
+ {
+ symbols[SEARCH_INDEX_ALL][letter].append(md);
+ symbolCount[SEARCH_INDEX_ALL]++;
+ }
+ if (md->isFunction() || md->isSlot() || md->isSignal())
+ {
+ symbols[SEARCH_INDEX_FUNCTIONS][letter].append(md);
+ symbolCount[SEARCH_INDEX_FUNCTIONS]++;
+ }
+ else if (md->isVariable())
+ {
+ symbols[SEARCH_INDEX_VARIABLES][letter].append(md);
+ symbolCount[SEARCH_INDEX_VARIABLES]++;
+ }
+ else if (md->isTypedef())
+ {
+ symbols[SEARCH_INDEX_TYPEDEFS][letter].append(md);
+ symbolCount[SEARCH_INDEX_TYPEDEFS]++;
+ }
+ else if (md->isEnumerate())
+ {
+ symbols[SEARCH_INDEX_ENUMS][letter].append(md);
+ symbolCount[SEARCH_INDEX_ENUMS]++;
+ }
+ else if (md->isEnumValue())
+ {
+ symbols[SEARCH_INDEX_ENUMVALUES][letter].append(md);
+ symbolCount[SEARCH_INDEX_ENUMVALUES]++;
+ }
+ else if (md->isProperty())
+ {
+ symbols[SEARCH_INDEX_PROPERTIES][letter].append(md);
+ symbolCount[SEARCH_INDEX_PROPERTIES]++;
+ }
+ else if (md->isEvent())
+ {
+ symbols[SEARCH_INDEX_EVENTS][letter].append(md);
+ symbolCount[SEARCH_INDEX_EVENTS]++;
+ }
+ else if (md->isRelated() || md->isForeign() ||
+ (md->isFriend() && !isFriendToHide))
+ {
+ symbols[SEARCH_INDEX_RELATED][letter].append(md);
+ symbolCount[SEARCH_INDEX_RELATED]++;
+ }
+ }
+ }
+ else if (isLinkable &&
+ ((nd=md->getNamespaceDef()) && nd->isLinkable()) ||
+ ((fd=md->getFileDef()) && fd->isLinkable())
+ )
+ {
+ QCString n = md->name();
+ int letter = tolower(n.at(0)) & 0x7f;
+ if (!n.isEmpty())
+ {
+ symbols[SEARCH_INDEX_ALL][letter].append(md);
+ symbolCount[SEARCH_INDEX_ALL]++;
+
+ if (md->isFunction())
+ {
+ symbols[SEARCH_INDEX_FUNCTIONS][letter].append(md);
+ symbolCount[SEARCH_INDEX_FUNCTIONS]++;
+ }
+ else if (md->isVariable())
+ {
+ symbols[SEARCH_INDEX_VARIABLES][letter].append(md);
+ symbolCount[SEARCH_INDEX_VARIABLES]++;
+ }
+ else if (md->isTypedef())
+ {
+ symbols[SEARCH_INDEX_TYPEDEFS][letter].append(md);
+ symbolCount[SEARCH_INDEX_TYPEDEFS]++;
+ }
+ else if (md->isEnumerate())
+ {
+ symbols[SEARCH_INDEX_ENUMS][letter].append(md);
+ symbolCount[SEARCH_INDEX_ENUMS]++;
+ }
+ else if (md->isEnumValue())
+ {
+ symbols[SEARCH_INDEX_ENUMVALUES][letter].append(md);
+ symbolCount[SEARCH_INDEX_ENUMVALUES]++;
+ }
+ else if (md->isDefine())
+ {
+ symbols[SEARCH_INDEX_DEFINES][letter].append(md);
+ symbolCount[SEARCH_INDEX_DEFINES]++;
+ }
+ }
+ }
+}
+
+static QCString searchId(const QCString &s)
+{
+ int c;
+ uint i;
+ QCString result;
+ for (i=0;i<s.length();i++)
+ {
+ c=s.at(i);
+ if ((c>='0' && c<='9') || (c>='A' && c<='Z') || (c>='a' && c<='z'))
+ {
+ result+=(char)tolower(c);
+ }
+ else
+ {
+ char val[4];
+ sprintf(val,"_%02x",c);
+ result+=val;
+ }
+ }
+ return result;
+}
+
+static int g_searchIndexCount[NUM_SEARCH_INDICES];
+static SearchIndexList g_searchIndexSymbols[NUM_SEARCH_INDICES][MEMBER_INDEX_ENTRIES];
+static const char *g_searchIndexName[NUM_SEARCH_INDICES] =
+{
+ "all",
+ "classes",
+ "namespaces",
+ "files",
+ "functions",
+ "variables",
+ "typedefs",
+ "enums",
+ "enumvalues",
+ "properties",
+ "events",
+ "related",
+ "defines"
+};
+
+
+class SearchIndexCategoryMapping
+{
+ public:
+ SearchIndexCategoryMapping()
+ {
+ categoryLabel[SEARCH_INDEX_ALL] = theTranslator->trAll();
+ categoryLabel[SEARCH_INDEX_CLASSES] = theTranslator->trClasses();
+ categoryLabel[SEARCH_INDEX_NAMESPACES] = theTranslator->trNamespace(TRUE,FALSE);
+ categoryLabel[SEARCH_INDEX_FILES] = theTranslator->trFile(TRUE,FALSE);
+ categoryLabel[SEARCH_INDEX_FUNCTIONS] = theTranslator->trFunctions();
+ categoryLabel[SEARCH_INDEX_VARIABLES] = theTranslator->trVariables();
+ categoryLabel[SEARCH_INDEX_TYPEDEFS] = theTranslator->trTypedefs();
+ categoryLabel[SEARCH_INDEX_ENUMS] = theTranslator->trEnumerations();
+ categoryLabel[SEARCH_INDEX_ENUMVALUES] = theTranslator->trEnumerationValues();
+ categoryLabel[SEARCH_INDEX_PROPERTIES] = theTranslator->trProperties();
+ categoryLabel[SEARCH_INDEX_EVENTS] = theTranslator->trEvents();
+ categoryLabel[SEARCH_INDEX_RELATED] = theTranslator->trFriends();
+ categoryLabel[SEARCH_INDEX_DEFINES] = theTranslator->trDefines();
+ }
+ QString categoryLabel[NUM_SEARCH_INDICES];
+};
+
+void writeSearchIndex()
+{
+ if (!Config_getBool("GENERATE_HTML")) return;
+ static bool treeView = Config_getBool("GENERATE_TREEVIEW");
+
+ ClassSDict::Iterator cli(*Doxygen::classSDict);
+ ClassDef *cd;
+ for (;(cd=cli.current());++cli)
+ {
+ int letter = tolower(cd->localName().at(0));
+ if (cd->isLinkable() && isId(letter))
+ {
+ g_searchIndexSymbols[SEARCH_INDEX_ALL][letter].append(cd);
+ g_searchIndexSymbols[SEARCH_INDEX_CLASSES][letter].append(cd);
+ g_searchIndexCount[SEARCH_INDEX_ALL]++;
+ g_searchIndexCount[SEARCH_INDEX_CLASSES]++;
+ }
+ }
+ NamespaceSDict::Iterator nli(*Doxygen::namespaceSDict);
+ NamespaceDef *nd;
+ for (;(nd=nli.current());++nli)
+ {
+ int letter = tolower(nd->name().at(0));
+ if (nd->isLinkable() && isId(letter))
+ {
+ g_searchIndexSymbols[SEARCH_INDEX_ALL][letter].append(nd);
+ g_searchIndexSymbols[SEARCH_INDEX_NAMESPACES][letter].append(nd);
+ g_searchIndexCount[SEARCH_INDEX_ALL]++;
+ g_searchIndexCount[SEARCH_INDEX_NAMESPACES]++;
+ }
+ }
+ FileNameListIterator fnli(*Doxygen::inputNameList);
+ FileName *fn;
+ for (;(fn=fnli.current());++fnli)
+ {
+ FileNameIterator fni(*fn);
+ FileDef *fd;
+ for (;(fd=fni.current());++fni)
+ {
+ int letter = tolower(fd->name().at(0));
+ if (fd->isLinkable() && isId(letter))
+ {
+ g_searchIndexSymbols[SEARCH_INDEX_ALL][letter].append(fd);
+ g_searchIndexSymbols[SEARCH_INDEX_FILES][letter].append(fd);
+ g_searchIndexCount[SEARCH_INDEX_ALL]++;
+ g_searchIndexCount[SEARCH_INDEX_FILES]++;
+ }
+ }
+ }
+ {
+ MemberNameSDict::Iterator mnli(*Doxygen::memberNameSDict);
+ MemberName *mn;
+ // for each member name
+ for (mnli.toFirst();(mn=mnli.current());++mnli)
+ {
+ MemberDef *md;
+ MemberNameIterator mni(*mn);
+ // for each member definition
+ for (mni.toFirst();(md=mni.current());++mni)
+ {
+ addMemberToSearchIndex(g_searchIndexSymbols,g_searchIndexCount,md);
+ }
+ }
+ }
+ {
+ MemberNameSDict::Iterator fnli(*Doxygen::functionNameSDict);
+ MemberName *mn;
+ // for each member name
+ for (fnli.toFirst();(mn=fnli.current());++fnli)
+ {
+ MemberDef *md;
+ MemberNameIterator mni(*mn);
+ // for each member definition
+ for (mni.toFirst();(md=mni.current());++mni)
+ {
+ addMemberToSearchIndex(g_searchIndexSymbols,g_searchIndexCount,md);
+ }
+ }
+ }
+
+ int i,p;
+ for (i=0;i<NUM_SEARCH_INDICES;i++)
+ {
+ for (p=0;p<MEMBER_INDEX_ENTRIES;p++)
+ {
+ if (g_searchIndexSymbols[i][p].count()>0)
+ {
+ g_searchIndexSymbols[i][p].sort();
+ }
+ }
+ }
+
+ //ol.pushGeneratorState();
+ //ol.disableAllBut(OutputGenerator::Html);
+ QCString htmlDirName = Config_getString("HTML_OUTPUT")+"/search";
+ QDir htmlDir(htmlDirName);
+ if (!htmlDir.exists() && !htmlDir.mkdir(htmlDirName))
+ {
+ err("Could not create search results directory '%s/search'\n",htmlDirName.data());
+ return;
+ }
+
+ HtmlGenerator::writeSearchData(htmlDirName);
+
+ for (i=0;i<NUM_SEARCH_INDICES;i++)
+ {
+ for (p=0;p<MEMBER_INDEX_ENTRIES;p++)
+ {
+ if (g_searchIndexSymbols[i][p].count()>0)
+ {
+ QCString fileName;
+ fileName.sprintf("/%s_%02x.html",g_searchIndexName[i],p);
+ fileName.prepend(htmlDirName);
+ QFile outFile(fileName);
+ if (outFile.open(IO_WriteOnly))
+ {
+ QTextStream t(&outFile);
+ t << "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\""
+ " \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">" << endl;
+ t << "<html><head><title></title>" << endl;
+ t << "<link rel=\"stylesheet\" type=\"text/css\" href=\"search.css\"/>" << endl;
+ t << "<script type=\"text/javascript\" src=\"search.js\"></script>" << endl;
+ t << "</head>" << endl;
+ t << "<body class=\"SRPage\">" << endl;
+ t << "<div id=\"SRIndex\">" << endl;
+ // TODO: translate "Loading"
+ t << "<div class=\"SRStatus\" id=\"Loading\">Loading...</div>" << endl;
+
+ SDict<QList<Definition> >::Iterator li(g_searchIndexSymbols[i][p]);
+ QList<Definition> *dl;
+ for (li.toFirst();(dl=li.current());++li)
+ {
+ Definition *d = dl->first();
+ QCString id = d->localName();
+ t << "<div class=\"SRResult\" id=\"SR_"
+ << searchId(d->localName()) << "\">" << endl;
+ t << " <div class=\"SREntry\">\n";
+ if (dl->count()==1) // item with a unique name
+ {
+ MemberDef *md = 0;
+ bool isMemberDef = d->definitionType()==Definition::TypeMember;
+ if (isMemberDef) md = (MemberDef*)d;
+ t << " <a class=\"SRSymbol\" href=\"../" <<
+ d->getOutputFileBase() << Doxygen::htmlFileExtension;
+ if (isMemberDef)
+ {
+ t << "#" << ((MemberDef *)d)->anchor();
+ }
+ t << "\" target=\"";
+ if (treeView) t << "basefrm"; else t << "_parent";
+ t << "\">"
+ << convertToXML(d->localName())
+ << "</a>" << endl;
+ if (d->getOuterScope()!=Doxygen::globalScope)
+ {
+ t << " <span class=\"SRScope\">"
+ << convertToXML(d->getOuterScope()->name())
+ << "</span>" << endl;
+ }
+ else if (isMemberDef)
+ {
+ FileDef *fd = ((MemberDef *)d)->getBodyDef();
+ if (fd==0) fd = ((MemberDef *)d)->getFileDef();
+ if (fd)
+ {
+ t << " <span class=\"SRScope\">"
+ << convertToXML(fd->localName())
+ << "</span>" << endl;
+ }
+ }
+ }
+ else // multiple items with the same name
+ {
+ t << " <a class=\"SRSymbol\" href=\"javascript:searchResults.Toggle('SR_"
+ << searchId(d->localName()) << "')\">"
+ << convertToXML(d->localName()) << "</a>" << endl;
+ t << " <div class=\"SRChildren\">" << endl;
+
+ QListIterator<Definition> di(*dl);
+ bool overloadedFunction = FALSE;
+ Definition *prevScope = 0;
+ for (di.toFirst();(d=di.current());)
+ {
+ ++di;
+ Definition *scope = d->getOuterScope();
+ Definition *next = di.current();
+ Definition *nextScope = 0;
+ MemberDef *md = 0;
+ bool isMemberDef = d->definitionType()==Definition::TypeMember;
+ if (isMemberDef) md = (MemberDef*)d;
+ if (next) nextScope = next->getOuterScope();
+
+ t << " <a class=\"SRScope\" href=\"../" <<
+ d->getOutputFileBase() << Doxygen::htmlFileExtension;
+ if (isMemberDef)
+ {
+ t << "#" << ((MemberDef *)d)->anchor();
+ }
+ t << "\" target=\"";
+ if (treeView) t << "basefrm"; else t << "_parent";
+ t << "\">";
+ bool found=FALSE;
+ overloadedFunction = ((prevScope!=0 && scope==prevScope) ||
+ (scope && scope==nextScope)
+ ) && md &&
+ (md->isFunction() || md->isSlot());
+ QCString prefix;
+ if (md) prefix=convertToXML(md->localName());
+ if (overloadedFunction) // overloaded member function
+ {
+ prefix+=convertToXML(md->argsString());
+ // show argument list to disambiguate overloaded functions
+ }
+ else if (md) // unique member function
+ {
+ prefix+="()"; // only to show it is a function
+ }
+ if (d->definitionType()==Definition::TypeClass)
+ {
+ t << convertToXML(((ClassDef*)d)->displayName());
+ found = TRUE;
+ }
+ else if (d->definitionType()==Definition::TypeNamespace)
+ {
+ t << convertToXML(((NamespaceDef*)d)->displayName());
+ found = TRUE;
+ }
+ else if (scope==0 || scope==Doxygen::globalScope) // in global scope
+ {
+ if (md)
+ {
+ FileDef *fd = md->getBodyDef();
+ if (fd==0) fd = md->getFileDef();
+ if (fd)
+ {
+ if (!prefix.isEmpty()) prefix+=":&nbsp;";
+ t << prefix << convertToXML(fd->localName());
+ found = TRUE;
+ }
+ }
+ }
+ else if (md && (md->getClassDef() || md->getNamespaceDef()))
+ // member in class or namespace scope
+ {
+ static bool optimizeOutputJava = Config_getBool("OPTIMIZE_OUTPUT_JAVA");
+ t << convertToXML(d->getOuterScope()->qualifiedName()) << (optimizeOutputJava ? "." : "::");
+ t << prefix;
+ found = TRUE;
+ }
+ else if (scope) // some thing else? -> show scope
+ {
+ t << prefix << convertToXML(scope->name());
+ found = TRUE;
+ }
+ if (!found) // fallback
+ {
+ // TODO: translate "global namespace"
+ t << prefix << "(global namespace)";
+ }
+ t << "</a>" << endl;
+ prevScope = scope;
+ }
+ t << " </div>" << endl; // SRChildren
+ }
+ t << " </div>" << endl; // SREntry
+ t << "</div>" << endl; // SRResult
+ }
+ // TODO: translate "Searching"
+ t << "<div class=\"SRStatus\" id=\"Searching\">Searching...</div>" << endl;
+ // TODO: translate "No Matches"
+ t << "<div class=\"SRStatus\" id=\"NoMatches\">No Matches</div>" << endl;
+
+ t << "<script type=\"text/javascript\"><!--" << endl;
+ t << "document.getElementById(\"Loading\").style.display=\"none\";" << endl;
+ t << "document.getElementById(\"NoMatches\").style.display=\"none\";" << endl;
+ t << "var searchResults = new SearchResults(\"searchResults\");" << endl;
+ t << "searchResults.Search();" << endl;
+ t << "--></script>" << endl;
+
+ t << "</div>" << endl; // SRIndex
+
+ t << "</body>" << endl;
+ t << "</html>" << endl;
+
+ }
+ else
+ {
+ err("Failed to open file '%s' for writing...\n",fileName.data());
+ }
+ }
+ }
+ }
+ //ol.popGeneratorState();
+
+ {
+ QFile f(htmlDirName+"/search.js");
+ if (f.open(IO_WriteOnly))
+ {
+ QTextStream t(&f);
+ t << "// Search script generated by doxygen" << endl;
+ t << "// Copyright (C) 2009 by Dimitri van Heesch." << endl << endl;
+ t << "// The code in this file is loosly based on main.js, part of Natural Docs," << endl;
+ t << "// which is Copyright (C) 2003-2008 Greg Valure" << endl;
+ t << "// Natural Docs is licensed under the GPL." << endl << endl;
+ t << "var indexSectionsWithContent =" << endl;
+ t << "{" << endl;
+ bool first=TRUE;
+ for (i=0;i<NUM_SEARCH_INDICES;i++)
+ {
+ if (g_searchIndexCount[i]>0)
+ {
+ if (!first) t << "," << endl;
+ t << " \"" << g_searchIndexName[i] << "\": \"";
+ for (p=32;p<MEMBER_INDEX_ENTRIES;p++)
+ {
+ t << (g_searchIndexSymbols[i][p].count()>0 ? "1" : "0");
+ }
+ t << "\"";
+ first=FALSE;
+ }
+ }
+ if (!first) t << "\n";
+ t << "};" << endl << endl;
+
+ t << search_script;
+ }
+ }
+ {
+ QFile f(htmlDirName+"/search.css");
+ if (f.open(IO_WriteOnly))
+ {
+ QTextStream t(&f);
+ t << search_styleSheet;
+ }
+ }
+ {
+ QFile f(htmlDirName+"/nomatches.html");
+ if (f.open(IO_WriteOnly))
+ {
+ QTextStream t(&f);
+ t << "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" "
+ "\"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">" << endl;
+ t << "<html><head><title></title>" << endl;
+ t << "<link rel=\"stylesheet\" type=\"text/css\" href=\"search.css\"/>" << endl;
+ t << "<script type=\"text/javascript\" src=\"search.js\"></script>" << endl;
+ t << "</head>" << endl;
+ t << "<body class=\"SRPage\">" << endl;
+ t << "<div id=\"SRIndex\">" << endl;
+ // TODO: translate "No Matches"
+ t << "<div class=\"SRStatus\" id=\"NoMatches\">No Matches</div>" << endl;
+ t << "</div>" << endl;
+ t << "</body>" << endl;
+ t << "</html>" << endl;
+ }
+ }
+}
+
+void writeSearchCategories(QTextStream &t)
+{
+ static SearchIndexCategoryMapping map;
+ int i,j=0;
+ for (i=0;i<NUM_SEARCH_INDICES;i++)
+ {
+ if (g_searchIndexCount[i]>0)
+ {
+ t << "<a class=\"SelectItem\" href=\"javascript:void(0)\" "
+ << "onclick=\"searchBox.OnSelectItem(" << j << ",'"
+ << g_searchIndexName[i] << "')\">"
+ << "<span class=\"SelectionMark\">&nbsp;</span>"
+ << convertToXML(map.categoryLabel[i])
+ << "</a>";
+ j++;
+ }
+ }
+}
+
+//----------------------------------------------------------------------------
+
void writeExampleIndex(OutputList &ol)
{
if (Doxygen::exampleSDict->count()==0) return;
@@ -2750,9 +3358,9 @@ void writeGroupIndex(OutputList &ol)
ol.parseText(theTranslator->trModulesDescription());
ol.endTextBlock();
- FTVHelp* ftv = NULL;
- QCString& TreeView=Config_getEnum("GENERATE_TREEVIEW");
- if (TreeView=="HIERARCHIES" || TreeView=="ALL")
+ FTVHelp* ftv = 0;
+ bool treeView=Config_getBool("USE_INLINE_TREES");
+ if (treeView)
ftv = new FTVHelp(false);
writeGroupHierarchy(ol,ftv);
@@ -2794,9 +3402,9 @@ void writeDirIndex(OutputList &ol)
ol.parseText(theTranslator->trDirDescription());
ol.endTextBlock();
- FTVHelp* ftv = NULL;
- QCString& TreeView=Config_getEnum("GENERATE_TREEVIEW");
- if (TreeView=="HIERARCHIES" || TreeView=="ALL")
+ FTVHelp* ftv = 0;
+ bool treeView=Config_getBool("USE_INLINE_TREES");
+ if (treeView)
ftv = new FTVHelp(false);
writeDirHierarchy(ol,ftv);
@@ -2861,7 +3469,7 @@ void writeIndex(OutputList &ol)
title = substitute(Doxygen::mainPage->title(),"%","");
}
- QCString indexName=usingTreeIndex()?"main":"index";
+ QCString indexName=Config_getBool("GENERATE_TREEVIEW")?"main":"index";
ol.startFile(indexName,0,title);
if (Doxygen::mainPage)
@@ -2901,7 +3509,11 @@ void writeIndex(OutputList &ol)
if (!Config_getString("PROJECT_NUMBER").isEmpty())
{
ol.startProjectNumber();
- ol.parseDoc(defFileName,defLine,Doxygen::mainPage,0,Config_getString("PROJECT_NUMBER"),TRUE,FALSE);
+ ol.parseDoc(defFileName,defLine,
+ Doxygen::mainPage,0,
+ Config_getString("PROJECT_NUMBER"),
+ TRUE,FALSE,0,
+ TRUE,FALSE);
ol.endProjectNumber();
}
if (Config_getBool("DISABLE_INDEX") && Doxygen::mainPage==0)
diff --git a/src/index.h b/src/index.h
index 56b0681..72ac764 100644
--- a/src/index.h
+++ b/src/index.h
@@ -24,6 +24,7 @@
class MemberDef;
class OutputList;
+class QTextStream;
class IndexIntf
@@ -252,4 +253,8 @@ void addClassMemberNameToIndex(MemberDef *md);
void addFileMemberNameToIndex(MemberDef *md);
void addNamespaceMemberNameToIndex(MemberDef *md);
+// search engine
+void writeSearchIndex();
+void writeSearchCategories(QTextStream &t);
+
#endif
diff --git a/src/latexdocvisitor.cpp b/src/latexdocvisitor.cpp
index 453f5d6..e0831b9 100644
--- a/src/latexdocvisitor.cpp
+++ b/src/latexdocvisitor.cpp
@@ -462,6 +462,10 @@ void LatexDocVisitor::visit(DocIndexEntry *i)
m_t << "}}";
}
+void LatexDocVisitor::visit(DocSimpleSectSep *)
+{
+}
+
//--------------------------------------
// visitor functions for compound nodes
//--------------------------------------
diff --git a/src/latexdocvisitor.h b/src/latexdocvisitor.h
index 1f8f2a9..45faf76 100644
--- a/src/latexdocvisitor.h
+++ b/src/latexdocvisitor.h
@@ -53,6 +53,7 @@ class LatexDocVisitor : public DocVisitor
void visit(DocIncOperator *);
void visit(DocFormula *);
void visit(DocIndexEntry *);
+ void visit(DocSimpleSectSep *);
//--------------------------------------
// visitor functions for compound nodes
diff --git a/src/latexgen.cpp b/src/latexgen.cpp
index aca7fac..37a3454 100644
--- a/src/latexgen.cpp
+++ b/src/latexgen.cpp
@@ -659,7 +659,7 @@ void LatexGenerator::endIndexSection(IndexSections is)
break;
case isMainPage:
{
- QCString indexName=usingTreeIndex()?"main":"index";
+ QCString indexName=Config_getBool("GENERATE_TREEVIEW")?"main":"index";
t << "}\n\\label{index}";
if (Config_getBool("PDF_HYPERLINKS")) t << "\\hypertarget{index}{}";
t << "\\input{" << indexName << "}\n";
diff --git a/src/layout.cpp b/src/layout.cpp
index ab2c130..1594796 100644
--- a/src/layout.cpp
+++ b/src/layout.cpp
@@ -758,7 +758,9 @@ class LayoutParser : public QXmlDefaultHandler
if (!m_rootNav->find(LayoutNavEntry::MainPage))
{
// no MainPage node... add one the first item of the root node...
- new LayoutNavEntry(m_rootNav,LayoutNavEntry::MainPage, TRUE, usingTreeIndex() ? "main" : "index",theTranslator->trMainPage(),TRUE);
+ new LayoutNavEntry(m_rootNav,LayoutNavEntry::MainPage, TRUE,
+ Config_getBool("GENERATE_TREEVIEW") ? "main" : "index",
+ theTranslator->trMainPage(),TRUE);
}
}
@@ -776,7 +778,7 @@ class LayoutParser : public QXmlDefaultHandler
QCString baseFile; // base name of the file containing the index page
} mapping[] =
{
- { "mainpage", LayoutNavEntry::MainPage, theTranslator->trMainPage(), QCString(), usingTreeIndex() ? "main" : "index" },
+ { "mainpage", LayoutNavEntry::MainPage, theTranslator->trMainPage(), QCString(), Config_getBool("GENERATE_TREEVIEW") ? "main" : "index" },
{ "pages", LayoutNavEntry::Pages, theTranslator->trRelatedPages(), QCString(), "pages" },
{ "modules", LayoutNavEntry::Modules, theTranslator->trModules(), QCString(), "modules" },
{ "namespaces", LayoutNavEntry::Namespaces, javaOpt ? theTranslator->trPackages() :
diff --git a/src/libdoxygen.pro.in b/src/libdoxygen.pro.in
index 2eabf69..d66fed1 100644
--- a/src/libdoxygen.pro.in
+++ b/src/libdoxygen.pro.in
@@ -98,6 +98,8 @@ HEADERS = bufstr.h \
scanner.h \
searchindex.h \
search_php.h \
+ search_js.h \
+ search_css.h \
section.h \
sortdict.h \
store.h \
diff --git a/src/libdoxygen.t b/src/libdoxygen.t
index b37eb1b..f9d4d5a 100644
--- a/src/libdoxygen.t
+++ b/src/libdoxygen.t
@@ -108,6 +108,12 @@ compound_xsd.h: compound.xsd
layout_default.h: layout_default.xml
cat layout_default.xml | $(TO_C_CMD) >layout_default.h
+search_js.h: search.js
+ cat search.js | $(TO_C_CMD) >search_js.h
+
+search_css.h: search.css
+ cat search.css | $(TO_C_CMD) >search_css.h
+
search_php.h: search.php
cat search.php | $(TO_C_CMD) >search_php.h
diff --git a/src/logos.cpp b/src/logos.cpp
index c682f61..ccb596e 100644
--- a/src/logos.cpp
+++ b/src/logos.cpp
@@ -133,6 +133,7 @@ unsigned char doxygen_png_data[] = {
};
unsigned int doxygen_png_len = 1281;
+#if 0
unsigned char search_png[] = {
0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d,
0x49, 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x1a,
@@ -291,6 +292,7 @@ unsigned char search_png[] = {
0x00, 0x49, 0x45, 0x4e, 0x44, 0xae, 0x42, 0x60, 0x82
};
unsigned int search_png_len = 1857;
+#endif
// Stripped version of FreeSans.ttf part of FreeFonts package,
@@ -2223,6 +2225,7 @@ void writeLogo(const char *dir)
f.close();
}
+#if 0
void writeSearchButton(const char *dir)
{
QCString fileName=(QCString)dir+"/search.png";
@@ -2235,6 +2238,7 @@ void writeSearchButton(const char *dir)
}
f.close();
}
+#endif
void writeDoxFont(const char *dir)
{
diff --git a/src/mandocvisitor.cpp b/src/mandocvisitor.cpp
index 4dd8010..8f84779 100644
--- a/src/mandocvisitor.cpp
+++ b/src/mandocvisitor.cpp
@@ -337,6 +337,10 @@ void ManDocVisitor::visit(DocIndexEntry *)
{
}
+void ManDocVisitor::visit(DocSimpleSectSep *)
+{
+}
+
//--------------------------------------
// visitor functions for compound nodes
//--------------------------------------
diff --git a/src/mandocvisitor.h b/src/mandocvisitor.h
index 0be9507..2610557 100644
--- a/src/mandocvisitor.h
+++ b/src/mandocvisitor.h
@@ -51,6 +51,7 @@ class ManDocVisitor : public DocVisitor
void visit(DocIncOperator *);
void visit(DocFormula *);
void visit(DocIndexEntry *);
+ void visit(DocSimpleSectSep *);
//--------------------------------------
// visitor functions for compound nodes
diff --git a/src/memberdef.cpp b/src/memberdef.cpp
index 7bbfed4..630b6ff 100644
--- a/src/memberdef.cpp
+++ b/src/memberdef.cpp
@@ -449,6 +449,8 @@ class MemberDefImpl
bool docsForDefinition; // TRUE => documentation block is put before
// definition.
// FALSE => block is put before declaration.
+
+ ClassDef *category;
};
MemberDefImpl::MemberDefImpl() :
@@ -460,7 +462,8 @@ MemberDefImpl::MemberDefImpl() :
tArgList(0),
typeConstraints(0),
defTmpArgLists(0),
- classSectionSDict(0)
+ classSectionSDict(0),
+ category(0)
{
}
@@ -634,6 +637,24 @@ MemberDef::MemberDef(const char *df,int dl,
m_flushPending = FALSE;
}
+void MemberDef::moveTo(Definition *scope)
+{
+ setOuterScope(scope);
+ if (scope->definitionType()==Definition::TypeClass)
+ {
+ m_impl->classDef = (ClassDef*)scope;
+ }
+ else if (scope->definitionType()==Definition::TypeFile)
+ {
+ m_impl->fileDef = (FileDef*)scope;
+ }
+ else if (scope->definitionType()==Definition::TypeNamespace)
+ {
+ m_impl->nspace = (NamespaceDef*)scope;
+ }
+}
+
+
/*! Destroys the member definition. */
MemberDef::~MemberDef()
{
@@ -1176,12 +1197,12 @@ void MemberDef::writeDeclaration(OutputList &ol,
}
// write search index info
- if (Config_getBool("SEARCHENGINE") && !isReference())
- {
- Doxygen::searchIndex->setCurrentDoc(qualifiedName(),getOutputFileBase(),anchor());
- Doxygen::searchIndex->addWord(localName(),TRUE);
- Doxygen::searchIndex->addWord(qualifiedName(),FALSE);
- }
+ //if (Config_getBool("SEARCHENGINE") && !isReference())
+ //{
+ // Doxygen::searchIndex->setCurrentDoc(qualifiedName(),getOutputFileBase(),anchor());
+ // Doxygen::searchIndex->addWord(localName(),TRUE);
+ // Doxygen::searchIndex->addWord(qualifiedName(),FALSE);
+ //}
QCString cname = d->name();
QCString cfname = getOutputFileBase();
@@ -1496,7 +1517,9 @@ void MemberDef::writeDeclaration(OutputList &ol,
)
{
ol.startMemberDescription();
- ol.parseDoc(briefFile(),briefLine(),getOuterScope()?getOuterScope():d,this,briefDescription(),TRUE,FALSE);
+ ol.parseDoc(briefFile(),briefLine(),
+ getOuterScope()?getOuterScope():d,this,briefDescription(),
+ TRUE,FALSE,0,TRUE,FALSE);
if (detailsVisible)
{
ol.pushGeneratorState();
@@ -3846,6 +3869,19 @@ void MemberDef::setMemberDeclaration(MemberDef *md)
m_impl->memDec=md;
}
+ClassDef *MemberDef::category() const
+{
+ makeResident();
+ return m_impl->category;
+}
+
+void MemberDef::setCategory(ClassDef *def)
+{
+ makeResident();
+ m_impl->category = def;
+}
+
+
void MemberDef::cacheTypedefVal(ClassDef*val, const QCString & templSpec, const QCString &resolvedType)
{
makeResident();
@@ -3938,6 +3974,7 @@ void MemberDef::flushToDisk() const
marshalBool (Doxygen::symbolStorage,m_impl->tspec);
marshalBool (Doxygen::symbolStorage,m_impl->groupHasDocs);
marshalBool (Doxygen::symbolStorage,m_impl->docsForDefinition);
+ marshalObjPointer (Doxygen::symbolStorage,m_impl->category);
marshalUInt(Doxygen::symbolStorage,END_MARKER);
// function doesn't modify the object conceptually but compiler doesn't know this.
@@ -4035,6 +4072,7 @@ void MemberDef::loadFromDisk() const
m_impl->tspec = unmarshalBool (Doxygen::symbolStorage);
m_impl->groupHasDocs = unmarshalBool (Doxygen::symbolStorage);
m_impl->docsForDefinition = unmarshalBool (Doxygen::symbolStorage);
+ m_impl->category = (ClassDef*)unmarshalObjPointer (Doxygen::symbolStorage);
marker = unmarshalUInt(Doxygen::symbolStorage);
assert(marker==END_MARKER);
}
@@ -4150,4 +4188,23 @@ void MemberDef::copyArgumentNames(MemberDef *bmd)
}
}
+static void invalidateCachedTypesInArgumentList(ArgumentList *al)
+{
+ if (al)
+ {
+ ArgumentListIterator ali(*al);
+ Argument *a;
+ for (ali.toFirst();(a=ali.current());++ali)
+ {
+ a->canType.resize(0);
+ }
+ }
+}
+
+void MemberDef::invalidateCachedArgumentTypes()
+{
+ makeResident();
+ invalidateCachedTypesInArgumentList(m_impl->defArgList);
+ invalidateCachedTypesInArgumentList(m_impl->declArgList);
+}
diff --git a/src/memberdef.h b/src/memberdef.h
index 8f47022..a171220 100644
--- a/src/memberdef.h
+++ b/src/memberdef.h
@@ -72,6 +72,8 @@ class MemberDef : public Definition
const ArgumentList *al);
~MemberDef();
DefType definitionType() const { return TypeMember; }
+ // move this member into a different scope
+ void moveTo(Definition *);
//-----------------------------------------------------------------------------------
// ---- getters -----
@@ -231,6 +233,8 @@ class MemberDef : public Definition
MemberDef *inheritsDocsFrom() const;
MemberDef *getGroupAlias() const;
+ ClassDef *category() const;
+
//-----------------------------------------------------------------------------------
// ---- setters -----
//-----------------------------------------------------------------------------------
@@ -314,6 +318,8 @@ class MemberDef : public Definition
void cacheTypedefVal(ClassDef *val,const QCString &templSpec,const QCString &resolvedType);
void invalidateTypedefValCache();
+
+ void invalidateCachedArgumentTypes();
// declaration <-> definition relation
void setMemberDefinition(MemberDef *md);
@@ -321,6 +327,8 @@ class MemberDef : public Definition
void setAnonymousUsed();
void copyArgumentNames(MemberDef *bmd);
+
+ void setCategory(ClassDef *);
//-----------------------------------------------------------------------------------
// --- actions ----
diff --git a/src/membergroup.h b/src/membergroup.h
index e718176..e7bd457 100644
--- a/src/membergroup.h
+++ b/src/membergroup.h
@@ -118,6 +118,7 @@ struct MemberGroupInfo
QCString header;
QCString doc;
QCString docFile;
+ QCString compoundName;
};
//class MemberGroupDict : public QIntDict<MemberGroup>
diff --git a/src/memberlist.cpp b/src/memberlist.cpp
index 8e8c93c..8091362 100644
--- a/src/memberlist.cpp
+++ b/src/memberlist.cpp
@@ -342,12 +342,16 @@ void MemberList::writeDeclarations(OutputList &ol,
ol.parseText(title);
ol.endMemberHeader();
}
- if (subtitle && subtitle[0]!=0)
+ if (subtitle)
{
- //printf("subtitle=`%s'\n",subtitle);
- ol.startMemberSubtitle();
- ol.parseDoc("[generated]",-1,ctx,0,subtitle,FALSE,FALSE);
- ol.endMemberSubtitle();
+ QCString st=subtitle;
+ st = st.stripWhiteSpace();
+ if (!st.isEmpty())
+ {
+ ol.startMemberSubtitle();
+ ol.parseDoc("[generated]",-1,ctx,0,subtitle,FALSE,FALSE);
+ ol.endMemberSubtitle();
+ }
}
// TODO: Two things need to be worked out for proper VHDL output:
diff --git a/src/namespacedef.cpp b/src/namespacedef.cpp
index bac6779..689fd26 100644
--- a/src/namespacedef.cpp
+++ b/src/namespacedef.cpp
@@ -401,11 +401,11 @@ void NamespaceDef::writeDocumentation(OutputList &ol)
addGroupListToTitle(ol,this);
endTitle(ol,getOutputFileBase(),displayName());
- if (Config_getBool("SEARCHENGINE"))
- {
- Doxygen::searchIndex->setCurrentDoc(pageTitle,getOutputFileBase());
- Doxygen::searchIndex->addWord(localName(),TRUE);
- }
+ //if (Config_getBool("SEARCHENGINE"))
+ //{
+ // Doxygen::searchIndex->setCurrentDoc(pageTitle,getOutputFileBase());
+ // Doxygen::searchIndex->addWord(localName(),TRUE);
+ //}
bool generateTagFile = !Config_getString("GENERATE_TAGFILE").isEmpty();
if (generateTagFile)
diff --git a/src/pagedef.cpp b/src/pagedef.cpp
index 9091581..1f451cc 100644
--- a/src/pagedef.cpp
+++ b/src/pagedef.cpp
@@ -120,9 +120,9 @@ void PageDef::writeDocumentation(OutputList &ol)
{
ol.startSection(si->label,si->title,si->type);
ol.parseDoc(docFile(),docLine(),this,0,si->title,TRUE,FALSE,0,TRUE,FALSE);
- stringToSearchIndex(getOutputFileBase(),
- theTranslator->trPage(TRUE,TRUE)+" "+si->title,
- si->title);
+ //stringToSearchIndex(getOutputFileBase(),
+ // theTranslator->trPage(TRUE,TRUE)+" "+si->title,
+ // si->title);
ol.endSection(si->label,si->type);
}
ol.popGeneratorState();
diff --git a/src/perlmodgen.cpp b/src/perlmodgen.cpp
index b3018bc..d38b835 100644
--- a/src/perlmodgen.cpp
+++ b/src/perlmodgen.cpp
@@ -306,6 +306,7 @@ public:
void visit(DocIncOperator *);
void visit(DocFormula *);
void visit(DocIndexEntry *);
+ void visit(DocSimpleSectSep *);
//--------------------------------------
// visitor functions for compound nodes
@@ -732,6 +733,10 @@ void PerlModDocVisitor::visit(DocIndexEntry *)
#endif
}
+void PerlModDocVisitor::visit(DocSimpleSectSep *)
+{
+}
+
//--------------------------------------
// visitor functions for compound nodes
//--------------------------------------
diff --git a/src/printdocvisitor.h b/src/printdocvisitor.h
index b0c9b5f..efc1c6c 100644
--- a/src/printdocvisitor.h
+++ b/src/printdocvisitor.h
@@ -210,6 +210,11 @@ class PrintDocVisitor : public DocVisitor
indent_leaf();
printf("<indexentry>%s</indexentry\n",i->entry().data());
}
+ void visit(DocSimpleSectSep *)
+ {
+ indent_leaf();
+ printf("<simplesectsep/>");
+ }
//--------------------------------------
diff --git a/src/pycode.l b/src/pycode.l
index 5955e85..aa72b43 100644
--- a/src/pycode.l
+++ b/src/pycode.l
@@ -281,20 +281,24 @@ static int countLines()
static void setCurrentDoc(const QCString &name,const QCString &base,const QCString &anchor="")
{
- static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
- if (searchEngineEnabled)
- {
- Doxygen::searchIndex->setCurrentDoc(name,base,anchor);
- }
+ (void)name;
+ (void)base;
+ (void)anchor;
+ //static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
+ //if (searchEngineEnabled)
+ //{
+ // Doxygen::searchIndex->setCurrentDoc(name,base,anchor);
+ //}
}
static void addToSearchIndex(const char *text)
{
- static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
- if (searchEngineEnabled)
- {
- Doxygen::searchIndex->addWord(text,FALSE);
- }
+ (void)text;
+ //static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
+ //if (searchEngineEnabled)
+ //{
+ // Doxygen::searchIndex->addWord(text,FALSE);
+ //}
}
diff --git a/src/qhp.cpp b/src/qhp.cpp
index ba7983d..15ecdab 100644
--- a/src/qhp.cpp
+++ b/src/qhp.cpp
@@ -188,10 +188,25 @@ void Qhp::addIndexItem(const char * level1, const char * level2,
const char * contRef, const char * /*memRef*/,
const char * anchor, const MemberDef * /*md*/)
{
+ QCString ref;
+ if ((m_prevIdName!=level1) || (m_prevIdRef!=contRef))
+ {
+ m_prevIdName = level1;
+ m_prevIdRef = contRef;
+
+ ref = makeFileName(contRef);
+ const char * attributes[] =
+ { "name", level1,
+ "id", level1,
+ "ref", ref,
+ 0
+ };
+ m_index.openClose("keyword", attributes);
+ }
/*
<keyword name="foo" id="MyApplication::foo" ref="doc.html#foo"/>
*/
- QCString ref = makeRef(contRef, anchor);
+ ref = makeRef(contRef, anchor);
QCString id(level1);
id += "::";
id += level2;
diff --git a/src/qhp.h b/src/qhp.h
index 38d17fd..4ab779c 100644
--- a/src/qhp.h
+++ b/src/qhp.h
@@ -61,6 +61,9 @@ class Qhp : public IndexIntf
int m_prevSectionLevel;
int m_sectionLevel;
+
+ QCString m_prevIdName;
+ QCString m_prevIdRef;
};
#endif // DOXYGEN_QHP_H
diff --git a/src/rtfdocvisitor.cpp b/src/rtfdocvisitor.cpp
index 4d30b2d..5732bff 100644
--- a/src/rtfdocvisitor.cpp
+++ b/src/rtfdocvisitor.cpp
@@ -537,6 +537,10 @@ void RTFDocVisitor::visit(DocIndexEntry *i)
m_lastIsPara=FALSE;
}
+void RTFDocVisitor::visit(DocSimpleSectSep *)
+{
+}
+
//--------------------------------------
// visitor functions for compound nodes
//--------------------------------------
diff --git a/src/rtfdocvisitor.h b/src/rtfdocvisitor.h
index 70c960a..11f7c03 100644
--- a/src/rtfdocvisitor.h
+++ b/src/rtfdocvisitor.h
@@ -51,6 +51,7 @@ class RTFDocVisitor : public DocVisitor
void visit(DocIncOperator *);
void visit(DocFormula *);
void visit(DocIndexEntry *);
+ void visit(DocSimpleSectSep *);
//--------------------------------------
// visitor functions for compound nodes
diff --git a/src/rtfgen.cpp b/src/rtfgen.cpp
index 557b3fd..e321508 100644
--- a/src/rtfgen.cpp
+++ b/src/rtfgen.cpp
@@ -611,7 +611,7 @@ void RTFGenerator::endIndexSection(IndexSections is)
t << "{\\tc \\v " << substitute(Doxygen::mainPage->title(),"%","") << "}"<< endl;
}
t << "{\\field\\fldedit{\\*\\fldinst INCLUDETEXT \"";
- if (usingTreeIndex()) t << "main"; else t << "index";
+ if (Config_getBool("GENERATE_TREEVIEW")) t << "main"; else t << "index";
t << ".rtf\" \\\\*MERGEFORMAT}{\\fldrslt includedstuff}}\n";
break;
//case isPackageIndex:
diff --git a/src/scanner.l b/src/scanner.l
index d189bef..7862507 100644
--- a/src/scanner.l
+++ b/src/scanner.l
@@ -1000,7 +1000,6 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
lineCount() ;
}
<FindMembers>[\-+]{BN}* {
- printf("Found - insideObj=%d\n",insideObjC);
if (!insideObjC)
{
REJECT;
@@ -4710,7 +4709,7 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
current->args += ' ';
current->args += name;
}
-<ClassVar,Bases>\n/{BN}*[^{,] {
+<ClassVar,Bases>\n/{BN}*[^{, \t\n] {
if (!insideObjC)
{
REJECT;
diff --git a/src/search.css b/src/search.css
new file mode 100644
index 0000000..7f316ab
--- /dev/null
+++ b/src/search.css
@@ -0,0 +1,210 @@
+/*---------------- Search Box */
+
+#MSearchBox {
+ padding: 0px;
+ margin: 0px;
+ border: none;
+ border: 1px solid #84B0C7;
+ white-space: nowrap;
+ -moz-border-radius: 8px;
+ -webkit-border-top-left-radius: 8px;
+ -webkit-border-top-right-radius: 8px;
+ -webkit-border-bottom-left-radius: 8px;
+ -webkit-border-bottom-right-radius: 8px;
+}
+#MSearchField {
+ font: 9pt Arial, Verdana, sans-serif;
+ color: #999999;
+ background-color: #FFFFFF;
+ font-style: normal;
+ cursor: pointer;
+ padding: 0px 1px;
+ margin: 0px 6px 0px 0px;
+ border: none;
+ outline: none;
+}
+#MSearchBox.MSearchBoxInactive:hover #MSearchField {
+ background-color: #FFFFFF;
+ padding: 0px 1px;
+ margin: 0px 6px 0px 0px;
+ border: none;
+}
+.MSearchBoxActive #MSearchField {
+ background-color: #FFFFFF;
+ color: #000000;
+ padding: 0px 1px;
+ margin: 0px 6px 0px 0px;
+ border: none;
+}
+#MSearchSelect {
+ float : none;
+ display : inline;
+ background : none;
+ font: 9pt Verdana, sans-serif;
+ margin-right: -6px;
+ padding: 0;
+ border: none;
+ margin: 0px 0px 0px 6px;
+ vertical-align: bottom;
+ padding: 0px 0px;
+ background-color: #84B0C7;
+}
+.MSearchBoxLeft {
+ display: block;
+ text-align: left;
+ float: left;
+ margin-left: 6px;
+}
+.MSearchBoxRight {
+ display: block;
+ float: right;
+ text-align: right;
+ margin-right: 6px;
+}
+.MSearchBoxSpacer {
+ font-size: 0px;
+ clear: both;
+}
+.MSearchBoxRow {
+ font-size: 0px;
+ clear: both;
+}
+
+/*---------------- Search filter selection */
+
+#MSearchSelectWindow {
+ display: none;
+ position: absolute;
+ left: 0; top: 0;
+ border: 1px solid #A0A0A0;
+ background-color: #FAFAFA;
+ z-index: 1;
+ padding-top: 4px;
+ padding-bottom: 4px;
+ -moz-border-radius: 4px;
+ -webkit-border-top-left-radius: 4px;
+ -webkit-border-top-right-radius: 4px;
+ -webkit-border-bottom-left-radius: 4px;
+ -webkit-border-bottom-right-radius: 4px;
+ -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);
+ }
+.SelectItem {
+ font: 8pt Arial, Verdana, sans-serif;
+ padding-left: 2px;
+ padding-right: 12px;
+ border: 0px;
+}
+span.SelectionMark {
+ margin-right: 4px;
+ font-family: monospace;
+ outline-style: none;
+ text-decoration: none;
+}
+a.SelectItem {
+ display: block;
+ outline-style: none;
+ color: #000000;
+ text-decoration: none;
+ padding-left: 6px;
+ padding-right: 12px;
+}
+a.SelectItem:visited,
+a.SelectItem:active {
+ color: #000000;
+ outline-style: none;
+ text-decoration: none;
+}
+a.SelectItem:hover {
+ color: #FFFFFF;
+ background-color: #2A50E4;
+ outline-style: none;
+ text-decoration: none;
+ cursor: pointer;
+ display: block;
+}
+
+/*---------------- Search results window */
+
+iframe#MSearchResults {
+ width: 60ex;
+ height: 15em;
+ }
+#MSearchResultsWindow {
+ display: none;
+ position: absolute;
+ left: 0; top: 0;
+ border: 1px solid #000000;
+ background-color: #EEF3F5;
+ }
+#MSearchResultsWindowClose {
+ font-weight: bold;
+ font-size: 8pt;
+ display: block;
+ padding: 0px;
+ margin: 0px;
+ text-align: right;
+ text-decoration: none;
+ outline-style: none;
+ }
+#MSearchResultsWindowClose:link,
+#MSearchResultsWindowClose:visited {
+ color: #8A8A8A;
+ background-color: #8A8A8A;
+ }
+#MSearchResultsWindowClose:active,
+#MSearchResultsWindowClose:hover {
+ color: #9E9E9E;
+ background-color: #9E9E9E;
+ }
+
+/* ----------------------------------- */
+
+
+#SRIndex {
+ clear:both;
+ padding-bottom: 15px;
+}
+
+.SREntry {
+ font-size: 10pt;
+ padding-left: 1ex;
+}
+.SRPage .SREntry {
+ font-size: 8pt;
+ padding: 1px 5px;
+}
+body.SRPage {
+ margin: 5px 2px;
+}
+
+.SRChildren {
+ padding-left: 3ex; padding-bottom: .5em
+}
+.SRPage .SRChildren {
+ display: none;
+}
+.SRSymbol {
+ font-weight: bold; color: #153788;
+ font-family: Arial, Verdana, sans-serif;
+ text-decoration: none;
+ outline: none;
+}
+
+a.SRScope {
+ display: block;
+ color: #153788;
+ font-family: Arial, Verdana, sans-serif;
+ text-decoration: none;
+ outline: none;
+}
+
+.SRPage .SRStatus {
+ padding: 2px 5px;
+ font-size: 8pt;
+ font-style: italic;
+}
+
+.SRResult {
+ display: none;
+}
+
diff --git a/src/search.js b/src/search.js
new file mode 100644
index 0000000..02af28d
--- /dev/null
+++ b/src/search.js
@@ -0,0 +1,456 @@
+function convertToId(search)
+{
+ var result = '';
+ for (i=0;i<search.length;i++)
+ {
+ var c = search.charAt(i);
+ var cn = c.charCodeAt(0);
+ if (c.match(/[a-z0-9]/))
+ {
+ result+=c;
+ }
+ else if (cn<16)
+ {
+ result+="_0"+cn.toString(16);
+ }
+ else
+ {
+ result+="_"+cn.toString(16);
+ }
+ }
+ return result;
+}
+
+function getXPos(item)
+{
+ var x = 0;
+ if (item.offsetWidth)
+ {
+ while (item && item!=document.body)
+ {
+ x += item.offsetLeft;
+ item = item.offsetParent;
+ }
+ }
+ return x;
+}
+
+function getYPos(item)
+{
+ var y = 0;
+ if (item.offsetWidth)
+ {
+ while (item && item!=document.body)
+ {
+ y += item.offsetTop;
+ item = item.offsetParent;
+ }
+ }
+ return y;
+}
+
+/* A class handling everything associated with the search panel.
+
+ Parameters:
+ name - The name of the global variable that will be
+ storing this instance. Is needed to be able to set timeouts.
+ resultPath - path to use for external files
+*/
+function SearchBox(name, resultsPath, inFrame)
+{
+ if (!name || !resultsPath) { alert("Missing parameters to SearchBox."); }
+
+ // ---------- Instance variables
+ this.name = name;
+ this.resultsPath = resultsPath;
+ this.keyTimeout = 0;
+ this.keyTimeoutLength = 500;
+ this.closeSelectionTimeout = 300;
+ this.lastSearchValue = "";
+ this.lastResultsPage = "";
+ this.hideTimeout = 0;
+ this.searchTopic = "all";
+ this.searchActive = false;
+ this.insideFrame = inFrame;
+
+ // ----------- DOM Elements
+
+ this.DOMSearchField = function()
+ { return document.getElementById("MSearchField"); }
+
+ this.DOMSearchSelect = function()
+ { return document.getElementById("MSearchSelect"); }
+
+ this.DOMSearchSelectWindow = function()
+ { return document.getElementById("MSearchSelectWindow"); }
+
+ this.DOMPopupSearchResults = function()
+ { return document.getElementById("MSearchResults"); }
+
+ this.DOMPopupSearchResultsWindow = function()
+ { return document.getElementById("MSearchResultsWindow"); }
+
+ this.DOMSearchResultWindowClose = function()
+ { return document.getElementById("MSearchResultsWindowClose"); }
+
+ this.DOMSearchBox = function()
+ { return document.getElementById("MSearchBox"); }
+
+ // ------------ Event Handlers
+
+ // Called when focus is added or removed from the search field.
+ this.OnSearchFieldFocus = function(isActive)
+ {
+ this.Activate(isActive);
+ }
+
+ this.OnSearchSelectShow = function()
+ {
+ var searchSelectWindow = this.DOMSearchSelectWindow();
+ var searchField = this.DOMSearchSelect();
+
+ if (this.insideFrame)
+ {
+ var left = getXPos(searchField);
+ var top = getYPos(searchField);
+ left += searchField.offsetWidth + 6;
+ top += searchField.offsetHeight;
+
+ // show search selection popup
+ searchSelectWindow.style.display='block';
+ left -= searchSelectWindow.offsetWidth;
+ searchSelectWindow.style.left = left + 'px';
+ searchSelectWindow.style.top = top + 'px';
+ }
+ else
+ {
+ var left = getXPos(searchField);
+ var top = getYPos(searchField);
+ top += searchField.offsetHeight;
+
+ // show search selection popup
+ searchSelectWindow.style.display='block';
+ searchSelectWindow.style.left = left + 'px';
+ searchSelectWindow.style.top = top + 'px';
+ }
+
+ // stop selection hide timer
+ if (this.hideTimeout)
+ {
+ clearTimeout(this.hideTimeout);
+ this.hideTimeout=0;
+ }
+ return false; // to avoid "image drag" default event
+ }
+
+ this.OnSearchSelectHide = function()
+ {
+ this.hideTimeout = setTimeout(this.name +".CloseSelectionWindow()",
+ this.closeSelectionTimeout);
+ }
+
+ // Called when the content of the search field is changed.
+ this.OnSearchFieldChange = function()
+ {
+ if (this.keyTimeout) // kill running timer
+ {
+ clearTimeout(this.keyTimeout);
+ this.keyTimeout = 0;
+ }
+
+ // strip whitespaces
+ var searchValue = this.DOMSearchField().value.replace(/ +/g, "");
+
+ if (searchValue != this.lastSearchValue) // search value has changed
+ {
+ if (searchValue != "") // non-empty search
+ {
+ // set timer for search update
+ this.keyTimeout = setTimeout(this.name + '.Search()',
+ this.keyTimeoutLength);
+ }
+ else // empty search field
+ {
+ this.DOMPopupSearchResultsWindow().style.display = 'none';
+ this.lastSearchValue = '';
+ }
+ }
+ }
+
+ // Called when an search filter selection is made.
+ // set item with index id as the active item
+ this.OnSelectItem = function(id,topic)
+ {
+ var i,j=0;
+ var win=this.DOMSearchSelectWindow();
+ for (i=0;i<win.childNodes.length;i++)
+ {
+ var child = win.childNodes[i]; // get span within a
+ if (child.className=='SelectItem')
+ {
+ var node = child.firstChild;
+ if (j==id)
+ {
+ // add a tickmark: see http://doogalbellend.blogspot.com/2007/05/even-more-on-tick-marks-in-html.html
+ node.innerHTML='&bull;';
+ }
+ else
+ {
+ node.innerHTML='&nbsp;';
+ }
+ j++;
+ }
+ }
+ if (topic)
+ {
+ this.searchTopic = topic;
+ var searchValue = this.DOMSearchField().value.replace(/ +/g, "");
+ if (searchValue != "" && this.searchActive) // something was found -> do a search
+ {
+ this.Search();
+ }
+ }
+ else
+ {
+ this.Activate(false);
+ }
+ }
+
+ this.OnCloseHighlight = function(active)
+ {
+ var close = this.DOMSearchResultWindowClose();
+ if (active)
+ {
+ close.firstChild.src = this.resultsPath + '/close_active.png';
+ }
+ else
+ {
+ close.firstChild.src = this.resultsPath + '/close.png';
+ }
+ return false;
+ }
+
+ // --------- Actions
+
+ // Closes the results window.
+ this.CloseResultsWindow = function()
+ {
+ this.DOMPopupSearchResultsWindow().style.display = "none";
+ this.Activate(false);
+ }
+
+ this.CloseSelectionWindow = function()
+ {
+ this.DOMSearchSelectWindow().style.display = "none";
+ }
+
+ // Performs a search.
+ this.Search = function()
+ {
+ this.keyTimeout = 0;
+
+ // strip leading whitespace
+ var searchValue = this.DOMSearchField().value.replace(/^ +/, "");
+
+ var code = searchValue.toLowerCase().charCodeAt(0);
+ var hexCode;
+ if (code<16)
+ {
+ hexCode="0"+code.toString(16);
+ }
+ else
+ {
+ hexCode=code.toString(16);
+ }
+
+ var resultsPage;
+ var resultsPageWithSearch;
+ var hasResultsPage;
+
+ // indexSectionsWithContent is defined in searchdata.js
+ if (indexSectionsWithContent[this.searchTopic].charAt(code-32) == '1')
+ {
+ resultsPage = this.resultsPath + '/' + this.searchTopic + '_' + hexCode + '.html';
+ resultsPageWithSearch = resultsPage+'?'+escape(searchValue);
+ hasResultsPage = true;
+ }
+ else // nothing available for this search term
+ {
+ resultsPage = this.resultsPath + '/nomatches.html';
+ resultsPageWithSearch = resultsPage;
+ hasResultsPage = false;
+ }
+
+ window.frames.MSearchResults.location.href = resultsPageWithSearch;
+ var domPopupSearchResultsWindow = this.DOMPopupSearchResultsWindow();
+
+ if (domPopupSearchResultsWindow.style.display!="block")
+ {
+ if (this.insideFrame)
+ {
+ var domSearchBox = this.DOMSearchBox();
+ var domPopupSearchResults = this.DOMPopupSearchResults();
+ this.DOMSearchResultWindowClose().style.textAlign = 'left';
+ domPopupSearchResultsWindow.style.position = 'relative';
+ domPopupSearchResultsWindow.style.display = 'block';
+ var width = document.body.clientWidth - 8; // the -8 is for IE :-(
+ domPopupSearchResultsWindow.style.width = width + 'px';
+ domPopupSearchResults.style.width = width + 'px';
+ }
+ else
+ {
+ var domSearchField = this.DOMSearchField();
+ var domPopupSearchResults = this.DOMPopupSearchResults();
+ var left = getXPos(domSearchField) + domSearchField.offsetWidth;
+ var top = getYPos(domSearchField) + domSearchField.offsetHeight + 1;
+ domPopupSearchResultsWindow.style.display = 'block';
+ left -= domPopupSearchResults.offsetWidth;
+ domPopupSearchResultsWindow.style.top = top + 'px';
+ domPopupSearchResultsWindow.style.left = left + 'px';
+ }
+ }
+
+ this.lastSearchValue = searchValue;
+ this.lastResultsPage = resultsPage;
+ }
+
+ // -------- Activation Functions
+
+ // Activates or deactivates the search panel, resetting things to
+ // their default values if necessary.
+ this.Activate = function(isActive)
+ {
+ if (isActive || // open it
+ this.DOMPopupSearchResultsWindow().style.display == 'block'
+ )
+ {
+ this.DOMSearchBox().className = 'MSearchBoxActive';
+
+ var searchField = this.DOMSearchField();
+
+ if (searchField.value == 'Search') // clear "Search" term upon entry
+ {
+ searchField.value = '';
+ this.searchActive = true;
+ }
+ }
+ else if (!isActive) // directly remove the panel
+ {
+ this.DOMSearchBox().className = 'MSearchBoxInactive';
+ this.DOMSearchField().value = 'Search';
+ this.searchActive = false;
+ this.lastSearchValue = ''
+ this.lastResultsPage = '';
+ }
+ }
+}
+
+// -----------------------------------------------------------------------
+
+// The class that handles everything on the search results page.
+function SearchResults(name)
+{
+ // The number of matches from the last run of <Search()>.
+ this.lastMatchCount = 0;
+
+ // Toggles the visibility of the passed element ID.
+ this.Toggle = function(id)
+ {
+ var parentElement = document.getElementById(id);
+ var element = parentElement.firstChild;
+
+ while (element && element!=parentElement)
+ {
+ if (element.nodeName == 'DIV' && element.className == 'SRChildren')
+ {
+ if (element.style.display == 'block')
+ {
+ element.style.display = 'none';
+ }
+ else
+ {
+ element.style.display = 'block';
+ }
+ }
+
+ if (element.nodeName == 'DIV' && element.hasChildNodes())
+ {
+ element = element.firstChild;
+ }
+ else if (element.nextSibling)
+ {
+ element = element.nextSibling;
+ }
+ else
+ {
+ do
+ {
+ element = element.parentNode;
+ }
+ while (element && element!=parentElement && !element.nextSibling);
+
+ if (element && element!=parentElement)
+ {
+ element = element.nextSibling;
+ }
+ }
+ }
+ }
+
+ // Searches for the passed string. If there is no parameter,
+ // it takes it from the URL query.
+ //
+ // Always returns true, since other documents may try to call it
+ // and that may or may not be possible.
+ this.Search = function(search)
+ {
+ if (!search) // get search word from URL
+ {
+ search = window.location.search;
+ search = search.substring(1); // Remove the leading '?'
+ search = unescape(search);
+ }
+
+ search = search.replace(/^ +/, ""); // strip leading spaces
+ search = search.replace(/ +$/, ""); // strip trailing spaces
+ search = search.toLowerCase();
+ search = convertToId(search);
+
+ var resultRows = document.getElementsByTagName("div");
+ var matches = 0;
+
+ var i = 0;
+ while (i < resultRows.length)
+ {
+ var row = resultRows.item(i);
+ if (row.className == "SRResult")
+ {
+ var rowMatchName = row.id.toLowerCase();
+ rowMatchName = rowMatchName.replace(/^sr\d*_/, ''); // strip 'sr123_'
+
+ if (search.length<=rowMatchName.length &&
+ rowMatchName.substr(0, search.length)==search)
+ {
+ row.style.display = "block";
+ matches++;
+ }
+ else
+ {
+ row.style.display = "none";
+ }
+ }
+ i++;
+ }
+ document.getElementById("Searching").style.display="none";
+ if (matches == 0) // no results
+ {
+ document.getElementById("NoMatches").style.display="block";
+ }
+ else // at least one result
+ {
+ document.getElementById("NoMatches").style.display="none";
+ }
+ this.lastMatchCount = matches;
+ return true;
+ }
+}
diff --git a/src/search_css.h b/src/search_css.h
new file mode 100644
index 0000000..177dbe3
--- /dev/null
+++ b/src/search_css.h
@@ -0,0 +1,210 @@
+"/*---------------- Search Box */\n"
+"\n"
+"#MSearchBox { \n"
+" padding: 0px;\n"
+" margin: 0px;\n"
+" border: none;\n"
+" border: 1px solid #84B0C7;\n"
+" white-space: nowrap;\n"
+" -moz-border-radius: 8px;\n"
+" -webkit-border-top-left-radius: 8px;\n"
+" -webkit-border-top-right-radius: 8px;\n"
+" -webkit-border-bottom-left-radius: 8px;\n"
+" -webkit-border-bottom-right-radius: 8px;\n"
+"}\n"
+"#MSearchField {\n"
+" font: 9pt Arial, Verdana, sans-serif;\n"
+" color: #999999;\n"
+" background-color: #FFFFFF;\n"
+" font-style: normal;\n"
+" cursor: pointer;\n"
+" padding: 0px 1px;\n"
+" margin: 0px 6px 0px 0px;\n"
+" border: none;\n"
+" outline: none;\n"
+"}\n"
+"#MSearchBox.MSearchBoxInactive:hover #MSearchField {\n"
+" background-color: #FFFFFF;\n"
+" padding: 0px 1px;\n"
+" margin: 0px 6px 0px 0px;\n"
+" border: none;\n"
+"}\n"
+".MSearchBoxActive #MSearchField {\n"
+" background-color: #FFFFFF;\n"
+" color: #000000;\n"
+" padding: 0px 1px;\n"
+" margin: 0px 6px 0px 0px;\n"
+" border: none;\n"
+"}\n"
+"#MSearchSelect {\n"
+" float : none;\n"
+" display : inline;\n"
+" background : none;\n"
+" font: 9pt Verdana, sans-serif;\n"
+" margin-right: -6px;\n"
+" padding: 0;\n"
+" border: none;\n"
+" margin: 0px 0px 0px 6px;\n"
+" vertical-align: bottom;\n"
+" padding: 0px 0px;\n"
+" background-color: #84B0C7;\n"
+"}\n"
+".MSearchBoxLeft {\n"
+" display: block;\n"
+" text-align: left;\n"
+" float: left;\n"
+" margin-left: 6px;\n"
+"}\n"
+".MSearchBoxRight {\n"
+" display: block;\n"
+" float: right;\n"
+" text-align: right;\n"
+" margin-right: 6px;\n"
+"}\n"
+".MSearchBoxSpacer {\n"
+" font-size: 0px;\n"
+" clear: both;\n"
+"}\n"
+".MSearchBoxRow {\n"
+" font-size: 0px;\n"
+" clear: both;\n"
+"}\n"
+"\n"
+"/*---------------- Search filter selection */\n"
+"\n"
+"#MSearchSelectWindow {\n"
+" display: none;\n"
+" position: absolute;\n"
+" left: 0; top: 0;\n"
+" border: 1px solid #A0A0A0;\n"
+" background-color: #FAFAFA;\n"
+" z-index: 1;\n"
+" padding-top: 4px;\n"
+" padding-bottom: 4px;\n"
+" -moz-border-radius: 4px;\n"
+" -webkit-border-top-left-radius: 4px;\n"
+" -webkit-border-top-right-radius: 4px;\n"
+" -webkit-border-bottom-left-radius: 4px;\n"
+" -webkit-border-bottom-right-radius: 4px;\n"
+" -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);\n"
+" }\n"
+".SelectItem {\n"
+" font: 8pt Arial, Verdana, sans-serif;\n"
+" padding-left: 2px;\n"
+" padding-right: 12px;\n"
+" border: 0px;\n"
+"}\n"
+"span.SelectionMark {\n"
+" margin-right: 4px;\n"
+" font-family: monospace;\n"
+" outline-style: none;\n"
+" text-decoration: none;\n"
+"}\n"
+"a.SelectItem {\n"
+" display: block;\n"
+" outline-style: none;\n"
+" color: #000000; \n"
+" text-decoration: none;\n"
+" padding-left: 6px;\n"
+" padding-right: 12px;\n"
+"}\n"
+"a.SelectItem:visited,\n"
+"a.SelectItem:active {\n"
+" color: #000000; \n"
+" outline-style: none;\n"
+" text-decoration: none;\n"
+"}\n"
+"a.SelectItem:hover {\n"
+" color: #FFFFFF;\n"
+" background-color: #2A50E4;\n"
+" outline-style: none;\n"
+" text-decoration: none;\n"
+" cursor: pointer;\n"
+" display: block;\n"
+"}\n"
+"\n"
+"/*---------------- Search results window */\n"
+"\n"
+"iframe#MSearchResults {\n"
+" width: 60ex;\n"
+" height: 15em;\n"
+" }\n"
+"#MSearchResultsWindow {\n"
+" display: none;\n"
+" position: absolute;\n"
+" left: 0; top: 0;\n"
+" border: 1px solid #000000;\n"
+" background-color: #EEF3F5;\n"
+" }\n"
+"#MSearchResultsWindowClose {\n"
+" font-weight: bold;\n"
+" font-size: 8pt;\n"
+" display: block;\n"
+" padding: 0px;\n"
+" margin: 0px;\n"
+" text-align: right;\n"
+" text-decoration: none;\n"
+" outline-style: none;\n"
+" }\n"
+"#MSearchResultsWindowClose:link,\n"
+"#MSearchResultsWindowClose:visited {\n"
+" color: #8A8A8A;\n"
+" background-color: #8A8A8A;\n"
+" }\n"
+"#MSearchResultsWindowClose:active,\n"
+"#MSearchResultsWindowClose:hover {\n"
+" color: #9E9E9E;\n"
+" background-color: #9E9E9E;\n"
+" }\n"
+"\n"
+"/* ----------------------------------- */\n"
+"\n"
+"\n"
+"#SRIndex {\n"
+" clear:both; \n"
+" padding-bottom: 15px;\n"
+"}\n"
+"\n"
+".SREntry {\n"
+" font-size: 10pt;\n"
+" padding-left: 1ex;\n"
+"}\n"
+".SRPage .SREntry {\n"
+" font-size: 8pt;\n"
+" padding: 1px 5px;\n"
+"}\n"
+"body.SRPage {\n"
+" margin: 5px 2px;\n"
+"}\n"
+"\n"
+".SRChildren {\n"
+" padding-left: 3ex; padding-bottom: .5em \n"
+"}\n"
+".SRPage .SRChildren {\n"
+" display: none;\n"
+"}\n"
+".SRSymbol {\n"
+" font-weight: bold; color: #153788;\n"
+" font-family: Arial, Verdana, sans-serif;\n"
+" text-decoration: none;\n"
+" outline: none;\n"
+"}\n"
+"\n"
+"a.SRScope {\n"
+" display: block;\n"
+" color: #153788; \n"
+" font-family: Arial, Verdana, sans-serif;\n"
+" text-decoration: none;\n"
+" outline: none;\n"
+"}\n"
+"\n"
+".SRPage .SRStatus {\n"
+" padding: 2px 5px;\n"
+" font-size: 8pt;\n"
+" font-style: italic;\n"
+"}\n"
+"\n"
+".SRResult {\n"
+" display: none;\n"
+"}\n"
+"\n"
diff --git a/src/search_js.h b/src/search_js.h
new file mode 100644
index 0000000..7a401e6
--- /dev/null
+++ b/src/search_js.h
@@ -0,0 +1,456 @@
+"function convertToId(search)\n"
+"{\n"
+" var result = '';\n"
+" for (i=0;i<search.length;i++)\n"
+" {\n"
+" var c = search.charAt(i);\n"
+" var cn = c.charCodeAt(0);\n"
+" if (c.match(/[a-z0-9]/))\n"
+" {\n"
+" result+=c;\n"
+" }\n"
+" else if (cn<16) \n"
+" {\n"
+" result+=\"_0\"+cn.toString(16);\n"
+" }\n"
+" else \n"
+" {\n"
+" result+=\"_\"+cn.toString(16);\n"
+" }\n"
+" }\n"
+" return result;\n"
+"}\n"
+"\n"
+"function getXPos(item)\n"
+"{\n"
+" var x = 0;\n"
+" if (item.offsetWidth)\n"
+" {\n"
+" while (item && item!=document.body)\n"
+" {\n"
+" x += item.offsetLeft;\n"
+" item = item.offsetParent;\n"
+" }\n"
+" }\n"
+" return x;\n"
+"}\n"
+"\n"
+"function getYPos(item)\n"
+"{\n"
+" var y = 0;\n"
+" if (item.offsetWidth)\n"
+" {\n"
+" while (item && item!=document.body)\n"
+" {\n"
+" y += item.offsetTop;\n"
+" item = item.offsetParent;\n"
+" }\n"
+" }\n"
+" return y;\n"
+"}\n"
+"\n"
+"/* A class handling everything associated with the search panel.\n"
+"\n"
+" Parameters:\n"
+" name - The name of the global variable that will be \n"
+" storing this instance. Is needed to be able to set timeouts.\n"
+" resultPath - path to use for external files\n"
+"*/\n"
+"function SearchBox(name, resultsPath, inFrame)\n"
+"{\n"
+" if (!name || !resultsPath) { alert(\"Missing parameters to SearchBox.\"); }\n"
+" \n"
+" // ---------- Instance variables\n"
+" this.name = name;\n"
+" this.resultsPath = resultsPath;\n"
+" this.keyTimeout = 0;\n"
+" this.keyTimeoutLength = 500;\n"
+" this.closeSelectionTimeout = 300;\n"
+" this.lastSearchValue = \"\";\n"
+" this.lastResultsPage = \"\";\n"
+" this.hideTimeout = 0;\n"
+" this.searchTopic = \"all\";\n"
+" this.searchActive = false;\n"
+" this.insideFrame = inFrame;\n"
+"\n"
+" // ----------- DOM Elements\n"
+"\n"
+" this.DOMSearchField = function()\n"
+" { return document.getElementById(\"MSearchField\"); }\n"
+"\n"
+" this.DOMSearchSelect = function()\n"
+" { return document.getElementById(\"MSearchSelect\"); }\n"
+"\n"
+" this.DOMSearchSelectWindow = function()\n"
+" { return document.getElementById(\"MSearchSelectWindow\"); }\n"
+"\n"
+" this.DOMPopupSearchResults = function()\n"
+" { return document.getElementById(\"MSearchResults\"); }\n"
+"\n"
+" this.DOMPopupSearchResultsWindow = function()\n"
+" { return document.getElementById(\"MSearchResultsWindow\"); }\n"
+"\n"
+" this.DOMSearchResultWindowClose = function()\n"
+" { return document.getElementById(\"MSearchResultsWindowClose\"); }\n"
+"\n"
+" this.DOMSearchBox = function()\n"
+" { return document.getElementById(\"MSearchBox\"); }\n"
+"\n"
+" // ------------ Event Handlers\n"
+"\n"
+" // Called when focus is added or removed from the search field.\n"
+" this.OnSearchFieldFocus = function(isActive)\n"
+" {\n"
+" this.Activate(isActive);\n"
+" }\n"
+"\n"
+" this.OnSearchSelectShow = function()\n"
+" {\n"
+" var searchSelectWindow = this.DOMSearchSelectWindow();\n"
+" var searchField = this.DOMSearchSelect();\n"
+"\n"
+" if (this.insideFrame)\n"
+" {\n"
+" var left = getXPos(searchField);\n"
+" var top = getYPos(searchField);\n"
+" left += searchField.offsetWidth + 6;\n"
+" top += searchField.offsetHeight;\n"
+"\n"
+" // show search selection popup\n"
+" searchSelectWindow.style.display='block';\n"
+" left -= searchSelectWindow.offsetWidth;\n"
+" searchSelectWindow.style.left = left + 'px';\n"
+" searchSelectWindow.style.top = top + 'px';\n"
+" }\n"
+" else\n"
+" {\n"
+" var left = getXPos(searchField);\n"
+" var top = getYPos(searchField);\n"
+" top += searchField.offsetHeight;\n"
+"\n"
+" // show search selection popup\n"
+" searchSelectWindow.style.display='block';\n"
+" searchSelectWindow.style.left = left + 'px';\n"
+" searchSelectWindow.style.top = top + 'px';\n"
+" }\n"
+"\n"
+" // stop selection hide timer\n"
+" if (this.hideTimeout) \n"
+" {\n"
+" clearTimeout(this.hideTimeout);\n"
+" this.hideTimeout=0;\n"
+" }\n"
+" return false; // to avoid \"image drag\" default event\n"
+" }\n"
+"\n"
+" this.OnSearchSelectHide = function()\n"
+" {\n"
+" this.hideTimeout = setTimeout(this.name +\".CloseSelectionWindow()\",\n"
+" this.closeSelectionTimeout);\n"
+" }\n"
+"\n"
+" // Called when the content of the search field is changed.\n"
+" this.OnSearchFieldChange = function()\n"
+" {\n"
+" if (this.keyTimeout) // kill running timer\n"
+" {\n"
+" clearTimeout(this.keyTimeout);\n"
+" this.keyTimeout = 0;\n"
+" }\n"
+"\n"
+" // strip whitespaces\n"
+" var searchValue = this.DOMSearchField().value.replace(/ +/g, \"\");\n"
+"\n"
+" if (searchValue != this.lastSearchValue) // search value has changed\n"
+" {\n"
+" if (searchValue != \"\") // non-empty search\n"
+" {\n"
+" // set timer for search update\n"
+" this.keyTimeout = setTimeout(this.name + '.Search()',\n"
+" this.keyTimeoutLength);\n"
+" }\n"
+" else // empty search field\n"
+" {\n"
+" this.DOMPopupSearchResultsWindow().style.display = 'none';\n"
+" this.lastSearchValue = '';\n"
+" }\n"
+" }\n"
+" }\n"
+"\n"
+" // Called when an search filter selection is made.\n"
+" // set item with index id as the active item\n"
+" this.OnSelectItem = function(id,topic)\n"
+" {\n"
+" var i,j=0;\n"
+" var win=this.DOMSearchSelectWindow(); \n"
+" for (i=0;i<win.childNodes.length;i++)\n"
+" {\n"
+" var child = win.childNodes[i]; // get span within a\n"
+" if (child.className=='SelectItem')\n"
+" {\n"
+" var node = child.firstChild;\n"
+" if (j==id)\n"
+" {\n"
+" // add a tickmark: see http://doogalbellend.blogspot.com/2007/05/even-more-on-tick-marks-in-html.html\n"
+" node.innerHTML='&bull;';\n"
+" } \n"
+" else\n"
+" {\n"
+" node.innerHTML='&nbsp;';\n"
+" }\n"
+" j++;\n"
+" }\n"
+" }\n"
+" if (topic)\n"
+" {\n"
+" this.searchTopic = topic;\n"
+" var searchValue = this.DOMSearchField().value.replace(/ +/g, \"\");\n"
+" if (searchValue != \"\" && this.searchActive) // something was found -> do a search\n"
+" {\n"
+" this.Search();\n"
+" }\n"
+" }\n"
+" else\n"
+" {\n"
+" this.Activate(false);\n"
+" }\n"
+" }\n"
+"\n"
+" this.OnCloseHighlight = function(active)\n"
+" {\n"
+" var close = this.DOMSearchResultWindowClose();\n"
+" if (active)\n"
+" {\n"
+" close.firstChild.src = this.resultsPath + '/close_active.png';\n"
+" }\n"
+" else\n"
+" {\n"
+" close.firstChild.src = this.resultsPath + '/close.png';\n"
+" }\n"
+" return false;\n"
+" }\n"
+"\n"
+" // --------- Actions\n"
+"\n"
+" // Closes the results window.\n"
+" this.CloseResultsWindow = function()\n"
+" {\n"
+" this.DOMPopupSearchResultsWindow().style.display = \"none\";\n"
+" this.Activate(false);\n"
+" }\n"
+"\n"
+" this.CloseSelectionWindow = function()\n"
+" {\n"
+" this.DOMSearchSelectWindow().style.display = \"none\";\n"
+" }\n"
+"\n"
+" // Performs a search.\n"
+" this.Search = function()\n"
+" {\n"
+" this.keyTimeout = 0;\n"
+"\n"
+" // strip leading whitespace\n"
+" var searchValue = this.DOMSearchField().value.replace(/^ +/, \"\");\n"
+"\n"
+" var code = searchValue.toLowerCase().charCodeAt(0);\n"
+" var hexCode;\n"
+" if (code<16) \n"
+" {\n"
+" hexCode=\"0\"+code.toString(16);\n"
+" }\n"
+" else \n"
+" {\n"
+" hexCode=code.toString(16);\n"
+" }\n"
+"\n"
+" var resultsPage;\n"
+" var resultsPageWithSearch;\n"
+" var hasResultsPage;\n"
+"\n"
+" // indexSectionsWithContent is defined in searchdata.js\n"
+" if (indexSectionsWithContent[this.searchTopic].charAt(code-32) == '1')\n"
+" {\n"
+" resultsPage = this.resultsPath + '/' + this.searchTopic + '_' + hexCode + '.html';\n"
+" resultsPageWithSearch = resultsPage+'?'+escape(searchValue);\n"
+" hasResultsPage = true;\n"
+" }\n"
+" else // nothing available for this search term\n"
+" {\n"
+" resultsPage = this.resultsPath + '/nomatches.html';\n"
+" resultsPageWithSearch = resultsPage;\n"
+" hasResultsPage = false;\n"
+" }\n"
+"\n"
+" window.frames.MSearchResults.location.href = resultsPageWithSearch; \n"
+" var domPopupSearchResultsWindow = this.DOMPopupSearchResultsWindow();\n"
+"\n"
+" if (domPopupSearchResultsWindow.style.display!=\"block\")\n"
+" {\n"
+" if (this.insideFrame)\n"
+" {\n"
+" var domSearchBox = this.DOMSearchBox();\n"
+" var domPopupSearchResults = this.DOMPopupSearchResults();\n"
+" this.DOMSearchResultWindowClose().style.textAlign = 'left';\n"
+" domPopupSearchResultsWindow.style.position = 'relative';\n"
+" domPopupSearchResultsWindow.style.display = 'block';\n"
+" var width = document.body.clientWidth - 8; // the -8 is for IE :-(\n"
+" domPopupSearchResultsWindow.style.width = width + 'px';\n"
+" domPopupSearchResults.style.width = width + 'px';\n"
+" }\n"
+" else\n"
+" {\n"
+" var domSearchField = this.DOMSearchField();\n"
+" var domPopupSearchResults = this.DOMPopupSearchResults();\n"
+" var left = getXPos(domSearchField) + domSearchField.offsetWidth;\n"
+" var top = getYPos(domSearchField) + domSearchField.offsetHeight + 1;\n"
+" domPopupSearchResultsWindow.style.display = 'block';\n"
+" left -= domPopupSearchResults.offsetWidth;\n"
+" domPopupSearchResultsWindow.style.top = top + 'px';\n"
+" domPopupSearchResultsWindow.style.left = left + 'px';\n"
+" }\n"
+" }\n"
+"\n"
+" this.lastSearchValue = searchValue;\n"
+" this.lastResultsPage = resultsPage;\n"
+" }\n"
+"\n"
+" // -------- Activation Functions\n"
+"\n"
+" // Activates or deactivates the search panel, resetting things to \n"
+" // their default values if necessary. \n"
+" this.Activate = function(isActive)\n"
+" {\n"
+" if (isActive || // open it\n"
+" this.DOMPopupSearchResultsWindow().style.display == 'block' \n"
+" )\n"
+" {\n"
+" this.DOMSearchBox().className = 'MSearchBoxActive';\n"
+"\n"
+" var searchField = this.DOMSearchField();\n"
+"\n"
+" if (searchField.value == 'Search') // clear \"Search\" term upon entry\n"
+" { \n"
+" searchField.value = ''; \n"
+" this.searchActive = true;\n"
+" }\n"
+" }\n"
+" else if (!isActive) // directly remove the panel\n"
+" {\n"
+" this.DOMSearchBox().className = 'MSearchBoxInactive';\n"
+" this.DOMSearchField().value = 'Search';\n"
+" this.searchActive = false;\n"
+" this.lastSearchValue = ''\n"
+" this.lastResultsPage = '';\n"
+" }\n"
+" }\n"
+"}\n"
+"\n"
+"// -----------------------------------------------------------------------\n"
+"\n"
+"// The class that handles everything on the search results page.\n"
+"function SearchResults(name)\n"
+"{\n"
+" // The number of matches from the last run of <Search()>.\n"
+" this.lastMatchCount = 0;\n"
+"\n"
+" // Toggles the visibility of the passed element ID.\n"
+" this.Toggle = function(id)\n"
+" {\n"
+" var parentElement = document.getElementById(id);\n"
+" var element = parentElement.firstChild;\n"
+"\n"
+" while (element && element!=parentElement)\n"
+" {\n"
+" if (element.nodeName == 'DIV' && element.className == 'SRChildren')\n"
+" {\n"
+" if (element.style.display == 'block')\n"
+" { \n"
+" element.style.display = 'none'; \n"
+" }\n"
+" else\n"
+" { \n"
+" element.style.display = 'block'; \n"
+" }\n"
+" }\n"
+"\n"
+" if (element.nodeName == 'DIV' && element.hasChildNodes())\n"
+" { \n"
+" element = element.firstChild; \n"
+" }\n"
+" else if (element.nextSibling)\n"
+" { \n"
+" element = element.nextSibling; \n"
+" }\n"
+" else\n"
+" {\n"
+" do\n"
+" {\n"
+" element = element.parentNode;\n"
+" }\n"
+" while (element && element!=parentElement && !element.nextSibling);\n"
+"\n"
+" if (element && element!=parentElement)\n"
+" { \n"
+" element = element.nextSibling; \n"
+" }\n"
+" }\n"
+" }\n"
+" }\n"
+"\n"
+" // Searches for the passed string. If there is no parameter, \n"
+" // it takes it from the URL query.\n"
+" //\n"
+" // Always returns true, since other documents may try to call it \n"
+" // and that may or may not be possible.\n"
+" this.Search = function(search)\n"
+" {\n"
+" if (!search) // get search word from URL\n"
+" {\n"
+" search = window.location.search;\n"
+" search = search.substring(1); // Remove the leading '?'\n"
+" search = unescape(search);\n"
+" }\n"
+"\n"
+" search = search.replace(/^ +/, \"\"); // strip leading spaces\n"
+" search = search.replace(/ +$/, \"\"); // strip trailing spaces\n"
+" search = search.toLowerCase();\n"
+" search = convertToId(search);\n"
+"\n"
+" var resultRows = document.getElementsByTagName(\"div\");\n"
+" var matches = 0;\n"
+"\n"
+" var i = 0;\n"
+" while (i < resultRows.length)\n"
+" {\n"
+" var row = resultRows.item(i);\n"
+" if (row.className == \"SRResult\")\n"
+" {\n"
+" var rowMatchName = row.id.toLowerCase();\n"
+" rowMatchName = rowMatchName.replace(/^sr\\d*_/, ''); // strip 'sr123_'\n"
+"\n"
+" if (search.length<=rowMatchName.length && \n"
+" rowMatchName.substr(0, search.length)==search)\n"
+" {\n"
+" row.style.display = \"block\";\n"
+" matches++;\n"
+" }\n"
+" else\n"
+" { \n"
+" row.style.display = \"none\"; \n"
+" }\n"
+" }\n"
+" i++;\n"
+" }\n"
+" document.getElementById(\"Searching\").style.display=\"none\";\n"
+" if (matches == 0) // no results\n"
+" { \n"
+" document.getElementById(\"NoMatches\").style.display=\"block\"; \n"
+" }\n"
+" else // at least one result\n"
+" { \n"
+" document.getElementById(\"NoMatches\").style.display=\"none\"; \n"
+" }\n"
+" this.lastMatchCount = matches;\n"
+" return true;\n"
+" }\n"
+"}\n"
diff --git a/src/sortdict.h b/src/sortdict.h
index bc0488d..ddabdcd 100644
--- a/src/sortdict.h
+++ b/src/sortdict.h
@@ -107,14 +107,14 @@ class SDict
* \param size The size of the dictionary. Should be a prime number for
* best distribution of elements.
*/
- SDict(int size) : m_sizeIndex(0)
+ SDict(int size,bool caseSensitive=TRUE) : m_sizeIndex(0)
{
m_list = new SList<T>(this);
#if AUTORESIZE
while ((uint)size>SDict_primes[m_sizeIndex]) m_sizeIndex++;
- m_dict = new QDict<T>(SDict_primes[m_sizeIndex]);
+ m_dict = new QDict<T>(SDict_primes[m_sizeIndex],caseSensitive);
#else
- m_dict = new QDict<T>(size);
+ m_dict = new QDict<T>(size,caseSensitive);
#endif
}
diff --git a/src/tagreader.cpp b/src/tagreader.cpp
index 1292ac4..6e6f47c 100644
--- a/src/tagreader.cpp
+++ b/src/tagreader.cpp
@@ -1182,6 +1182,10 @@ void TagFileParser::buildLists(Entry *root)
case TagClassInfo::Category: ce->spec = Entry::Category; break;
}
ce->name = tci->name;
+ if (tci->kind==TagClassInfo::Protocol)
+ {
+ ce->name+="-p";
+ }
addDocAnchors(ce,tci->docAnchors);
TagInfo *ti = new TagInfo;
ti->tagName = m_tagName;
diff --git a/src/textdocvisitor.h b/src/textdocvisitor.h
index 321e9c6..1e0d09d 100644
--- a/src/textdocvisitor.h
+++ b/src/textdocvisitor.h
@@ -50,6 +50,7 @@ class TextDocVisitor : public DocVisitor
void visit(DocIncOperator *) {}
void visit(DocFormula *) {}
void visit(DocIndexEntry *) {}
+ void visit(DocSimpleSectSep *){}
//--------------------------------------
// visitor functions for compound nodes
diff --git a/src/util.cpp b/src/util.cpp
index 5072721..ec8f8db 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -6401,6 +6401,7 @@ QCString stripLeadingAndTrailingEmptyLines(const QCString &s)
return s.mid(li,bi-li);
}
+#if 0
void stringToSearchIndex(const QCString &docBaseUrl,const QCString &title,
const QCString &str,bool priority,const QCString &anchor)
{
@@ -6417,6 +6418,7 @@ void stringToSearchIndex(const QCString &docBaseUrl,const QCString &title,
}
}
}
+#endif
//--------------------------------------------------------------------------
@@ -6813,8 +6815,8 @@ void writeTypeConstraints(OutputList &ol,Definition *d,ArgumentList *al)
bool usingTreeIndex()
{
- QCString& TreeView=Config_getEnum("GENERATE_TREEVIEW");
- return TreeView=="FRAME" || TreeView=="ALL" || TreeView=="YES";
+ static bool treeView = Config_getBool("USE_INLINE_TREES");
+ return treeView;
}
void stackTrace()
diff --git a/src/util.h b/src/util.h
index 2b248a3..d3d10fd 100644
--- a/src/util.h
+++ b/src/util.h
@@ -325,9 +325,9 @@ bool findAndRemoveWord(QCString &s,const QCString &word);
QCString stripLeadingAndTrailingEmptyLines(const QCString &s);
-void stringToSearchIndex(const QCString &docUrlBase,const QCString &title,
- const QCString &str, bool priority=FALSE,
- const QCString &anchor="");
+//void stringToSearchIndex(const QCString &docUrlBase,const QCString &title,
+// const QCString &str, bool priority=FALSE,
+// const QCString &anchor="");
bool updateLanguageMapping(const QCString &extension,const QCString &parser);
SrcLangExt getLanguageFromFileName(const QCString fileName);
diff --git a/src/vhdlcode.l b/src/vhdlcode.l
index 8b442ef..a7f0d7f 100644
--- a/src/vhdlcode.l
+++ b/src/vhdlcode.l
@@ -114,11 +114,14 @@ static void startFontClass(const char *s);
static void setCurrentDoc(const QCString &name,const QCString &base,const QCString &anchor="")
{
- static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
- if (searchEngineEnabled)
- {
- Doxygen::searchIndex->setCurrentDoc(name,base,anchor);
- }
+ (void)name;
+ (void)base;
+ (void)anchor;
+ //static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
+ //if (searchEngineEnabled)
+ //{
+ // Doxygen::searchIndex->setCurrentDoc(name,base,anchor);
+ //}
}
static bool checkString(QCString &name)
@@ -160,11 +163,12 @@ static bool checkString(QCString &name)
static void addToSearchIndex(const char *text)
{
- static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
- if (searchEngineEnabled)
- {
- Doxygen::searchIndex->addWord(text,FALSE);
- }
+ (void)text;
+ //static bool searchEngineEnabled=Config_getBool("SEARCHENGINE");
+ //if (searchEngineEnabled)
+ //{
+ // Doxygen::searchIndex->addWord(text,FALSE);
+ //}
}
diff --git a/src/vhdldocgen.cpp b/src/vhdldocgen.cpp
index 280e068..ad5f8df 100644
--- a/src/vhdldocgen.cpp
+++ b/src/vhdldocgen.cpp
@@ -1745,7 +1745,7 @@ void VhdlDocGen::writeVhdlDeclarations(MemberList* ml,
VhdlDocGen::writeVHDLDeclarations(ml,ol,cd,0,fd,gd,theTranslator_vhdlType(VhdlDocGen::CONFIG,FALSE),0,FALSE,VhdlDocGen::CONFIG);
}
-static void setConfigurationType(MemberList *ml)
+static void setGlobalType(MemberList *ml)
{
if (ml==0) return;
MemberDef *mdd=0;
@@ -1756,6 +1756,14 @@ static void setConfigurationType(MemberList *ml)
{
mdd->setMemberSpecifiers(VhdlDocGen::CONFIG);
}
+ else if (strcmp(mdd->typeString(),"library")==0)
+ {
+ mdd->setMemberSpecifiers(VhdlDocGen::LIBRARY);
+ }
+ else if (strcmp(mdd->typeString(),"package")==0)
+ {
+ mdd->setMemberSpecifiers(VhdlDocGen::USE);
+ }
}
}
@@ -1814,8 +1822,28 @@ void VhdlDocGen::writeVHDLDeclaration(MemberDef* mdef,OutputList &ol,
LockingPtr<MemberDef> lock(mdef,mdef);
Definition *d=0;
- ASSERT (cd!=0 || nd!=0 || fd!=0 || gd!=0); // member should belong to something
- if (cd) d=cd; else if (nd) d=nd; else if (fd) d=fd; else d=gd;
+
+ /* some vhdl files contain only a configuration description
+
+ library work;
+ configuration cfg_tb_jtag_gotoBackup of tb_jtag_gotoBackup is
+ for RTL
+ end for;
+ end cfg_tb_jtag_gotoBackup;
+
+ in this case library work does not belong to an entity, package ...
+
+ */
+
+ ASSERT(cd!=0 || nd!=0 || fd!=0 || gd!=0 ||
+ mdef->getMemberSpecifiers()==VhdlDocGen::LIBRARY ||
+ mdef->getMemberSpecifiers()==VhdlDocGen::USE
+ ); // member should belong to something
+ if (cd) d=cd;
+ else if (nd) d=nd;
+ else if (fd) d=fd;
+ else if (gd) d=gd;
+ else d=(Definition*)mdef;
// write tag file information of this member
if (!Config_getString("GENERATE_TAGFILE").isEmpty())
@@ -1862,12 +1890,12 @@ void VhdlDocGen::writeVHDLDeclaration(MemberDef* mdef,OutputList &ol,
}
// write search index info
- if (Config_getBool("SEARCHENGINE"))
- {
- Doxygen::searchIndex->setCurrentDoc(mdef->qualifiedName(),mdef->getOutputFileBase(),mdef->anchor());
- Doxygen::searchIndex->addWord(mdef->localName(),TRUE);
- Doxygen::searchIndex->addWord(mdef->qualifiedName(),FALSE);
- }
+ //if (Config_getBool("SEARCHENGINE"))
+ //{
+ // Doxygen::searchIndex->setCurrentDoc(mdef->qualifiedName(),mdef->getOutputFileBase(),mdef->anchor());
+ // Doxygen::searchIndex->addWord(mdef->localName(),TRUE);
+ // Doxygen::searchIndex->addWord(mdef->qualifiedName(),FALSE);
+ //}
QCString cname = d->name();
QCString cfname = mdef->getOutputFileBase();
@@ -2187,7 +2215,7 @@ void VhdlDocGen::writeVHDLDeclarations(MemberList* ml,OutputList &ol,
ClassDef *cd,NamespaceDef *nd,FileDef *fd,GroupDef *gd,
const char *title,const char *subtitle,bool /*showEnumValues*/,int type)
{
- setConfigurationType(ml);
+ setGlobalType(ml);
if (!membersHaveSpecificType(ml,type)) return;
if (title)
diff --git a/src/vhdlscanner.l b/src/vhdlscanner.l
index 2acd2dc..8e7b9de 100644
--- a/src/vhdlscanner.l
+++ b/src/vhdlscanner.l
@@ -1798,6 +1798,7 @@ static void mergeGrouping(const Entry* ce,int)
void mapLibPackage(const Entry* ce)
{
+ Entry *lastComp=0;
while (TRUE)
{
bool found = FALSE;
@@ -1820,9 +1821,18 @@ void mapLibPackage(const Entry* ce)
found=TRUE;
rt->spec=-1; //nullify entry
rt->section=0;
+ lastComp=temp;
break;
}
}//for
+ if (lastComp && rt->spec!=-1)
+ {
+ Entry *ee=new Entry(*rt); //append a copy to entries sublist
+ lastComp->addSubEntry(ee);
+ found=TRUE;
+ rt->spec=-1; //nullify entry
+ rt->section=0;
+ }
}//if
}//for
if (!found) // nothing left to do
diff --git a/src/xmldocvisitor.cpp b/src/xmldocvisitor.cpp
index 764aa88..76970b0 100644
--- a/src/xmldocvisitor.cpp
+++ b/src/xmldocvisitor.cpp
@@ -323,6 +323,11 @@ void XmlDocVisitor::visit(DocIndexEntry *ie)
"</indexentry>";
}
+void XmlDocVisitor::visit(DocSimpleSectSep *)
+{
+ m_t << "<simplesectsep/>";
+}
+
//--------------------------------------
// visitor functions for compound nodes
//--------------------------------------
@@ -683,7 +688,7 @@ void XmlDocVisitor::visitPre(DocImage *img)
inImage.readBlock(buffer,inImage.size());
outImage.writeBlock(buffer,inImage.size());
outImage.flush();
- delete buffer;
+ delete[] buffer;
}
}
}
diff --git a/src/xmldocvisitor.h b/src/xmldocvisitor.h
index 6a12d7b..be505ae 100644
--- a/src/xmldocvisitor.h
+++ b/src/xmldocvisitor.h
@@ -51,6 +51,7 @@ class XmlDocVisitor : public DocVisitor
void visit(DocIncOperator *);
void visit(DocFormula *);
void visit(DocIndexEntry *);
+ void visit(DocSimpleSectSep *);
//--------------------------------------
// visitor functions for compound nodes