From adff8506a1c654db63ef362bbc90cddf7c156dd7 Mon Sep 17 00:00:00 2001 From: Dimitri van Heesch Date: Sun, 18 Apr 2010 13:59:11 +0000 Subject: Release-1.6.3-20100418 --- Doxyfile | 2 +- INSTALL | 4 +- README | 4 +- addon/doxywizard/doxywizard.cpp | 19 +++- addon/doxywizard/expert.cpp | 5 +- configure | 2 +- qtools/Doxyfile | 2 +- src/definition.cpp | 50 ++++++---- src/definition.h | 1 + src/dirdef.cpp | 12 ++- src/docparser.cpp | 27 +++++- src/docparser.h | 2 +- src/doctokenizer.l | 8 +- src/doxygen.cpp | 2 + src/doxygen.css | 2 + src/doxygen_css.h | 2 + src/htmldocvisitor.cpp | 7 ++ src/htmlgen.cpp | 197 ++++++++++++++++++++++++++++++++++------ src/htmlgen.h | 1 + src/htmlhelp.cpp | 41 +++------ src/image.cpp | 30 +++++- src/index.cpp | 20 ++-- src/language.cpp | 4 +- src/latexdocvisitor.cpp | 2 +- src/latexgen.cpp | 28 ++++-- src/mangen.cpp | 5 +- src/pre.l | 36 ++++++-- src/scanner.l | 21 +++-- src/translator.h | 12 +++ src/translator_adapter.h | 20 +++- src/translator_br.h | 2 +- src/translator_ca.h | 2 +- src/translator_cz.h | 2 +- src/translator_de.h | 2 +- src/translator_en.h | 59 +++++++++++- src/translator_eo.h | 2 +- src/translator_es.h | 2 +- src/translator_fa.h | 4 +- src/translator_fr.h | 2 +- src/translator_hr.h | 2 +- src/translator_kr.h | 2 +- src/translator_nl.h | 57 ++++++++++-- src/translator_pl.h | 2 +- src/translatordecoder.h | 17 ++++ src/util.cpp | 21 ++++- src/xmlgen.cpp | 1 + 46 files changed, 583 insertions(+), 164 deletions(-) diff --git a/Doxyfile b/Doxyfile index 269439e..661941c 100644 --- a/Doxyfile +++ b/Doxyfile @@ -224,7 +224,7 @@ GENERATE_AUTOGEN_DEF = NO #--------------------------------------------------------------------------- # configuration options related to the Perl module output #--------------------------------------------------------------------------- -GENERATE_PERLMOD = YES +GENERATE_PERLMOD = NO PERLMOD_LATEX = NO PERLMOD_PRETTY = YES PERLMOD_MAKEVAR_PREFIX = diff --git a/INSTALL b/INSTALL index 24b8bb3..0754aa8 100644 --- a/INSTALL +++ b/INSTALL @@ -1,7 +1,7 @@ -DOXYGEN Version 1.6.3-20100324 +DOXYGEN Version 1.6.3-20100418 Please read the installation section of the manual (http://www.doxygen.org/install.html) for instructions. -------- -Dimitri van Heesch (24 March 2010) +Dimitri van Heesch (18 April 2010) diff --git a/README b/README index 50f1dea..6474d5a 100644 --- a/README +++ b/README @@ -1,4 +1,4 @@ -DOXYGEN Version 1.6.3_20100324 +DOXYGEN Version 1.6.3_20100418 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) (24 March 2010) +Dimitri van Heesch (dimitri@stack.nl) (18 April 2010) diff --git a/addon/doxywizard/doxywizard.cpp b/addon/doxywizard/doxywizard.cpp index 2001687..b746db1 100644 --- a/addon/doxywizard/doxywizard.cpp +++ b/addon/doxywizard/doxywizard.cpp @@ -101,14 +101,10 @@ MainWindow::MainWindow() setCentralWidget(topPart); statusBar()->showMessage(tr("Welcome to Doxygen"),messageTimeout); - loadSettings(); m_runProcess = new QProcess; m_running = false; m_timer = new QTimer; - updateLaunchButtonState(); - m_modified = false; - updateTitle(); // connect signals and slots connect(tabs,SIGNAL(currentChanged(int)),SLOT(selectTab(int))); @@ -123,6 +119,12 @@ MainWindow::MainWindow() connect(m_saveLog,SIGNAL(clicked()),SLOT(saveLog())); connect(showSettings,SIGNAL(clicked()),SLOT(showSettings())); connect(m_expert,SIGNAL(changed()),SLOT(configChanged())); + + loadSettings(); + updateLaunchButtonState(); + m_modified = false; + updateTitle(); + m_wizard->refresh(); } void MainWindow::closeEvent(QCloseEvent *event) @@ -274,6 +276,7 @@ void MainWindow::makeDefaults() //printf("MainWindow:makeDefaults()\n"); m_expert->saveSettings(&m_settings); m_settings.setValue(QString::fromAscii("wizard/loadsettings"), true); + m_settings.sync(); } } @@ -288,6 +291,7 @@ void MainWindow::resetToDefaults() //printf("MainWindow:resetToDefaults()\n"); m_expert->resetToDefaults(); m_settings.setValue(QString::fromAscii("wizard/loadsettings"), false); + m_settings.sync(); m_wizard->refresh(); } } @@ -298,6 +302,7 @@ void MainWindow::loadSettings() QVariant state = m_settings.value(QString::fromAscii("main/state"), 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("wizard/workingdir"), QVariant::Invalid); if (geometry !=QVariant::Invalid) restoreGeometry(geometry.toByteArray()); if (state !=QVariant::Invalid) restoreState (state.toByteArray()); @@ -307,6 +312,11 @@ void MainWindow::loadSettings() m_expert->loadSettings(&m_settings); } + if (workingDir!=QVariant::Invalid && QDir(workingDir.toString()).exists()) + { + setWorkingDir(workingDir.toString()); + } + for (int i=0;i<10;i++) { QString entry = m_settings.value(QString().sprintf("recent/config%d",i)).toString(); @@ -322,6 +332,7 @@ void MainWindow::saveSettings() m_settings.setValue(QString::fromAscii("main/geometry"), saveGeometry()); m_settings.setValue(QString::fromAscii("main/state"), saveState()); m_settings.setValue(QString::fromAscii("wizard/state"), m_wizard->saveState()); + m_settings.setValue(QString::fromAscii("wizard/workingdir"), m_workingDir->text()); } void MainWindow::selectTab(int id) diff --git a/addon/doxywizard/expert.cpp b/addon/doxywizard/expert.cpp index 9b665ca..e328ef0 100644 --- a/addon/doxywizard/expert.cpp +++ b/addon/doxywizard/expert.cpp @@ -321,9 +321,9 @@ void Expert::loadSettings(QSettings *s) { i.next(); QVariant var = s->value(SA("config/")+i.key()); - //printf("Loading key %s: type=%d\n",qPrintable(i.key()),var.type()); if (i.value()) { + //printf("Loading key %s: type=%d value='%s'\n",qPrintable(i.key()),var.type(),qPrintable(var.toString())); i.value()->value() = var; i.value()->update(); } @@ -336,9 +336,10 @@ void Expert::saveSettings(QSettings *s) while (i.hasNext()) { i.next(); + //printf("Saving key %s: type=%d value='%s'\n",qPrintable(i.key()),i.value()->value().type(),qPrintable(i.value()->value().toString())); if (i.value()) { - s->value(SA("config/")+i.key(),i.value()->value()); + s->setValue(SA("config/")+i.key(),i.value()->value()); } } } diff --git a/configure b/configure index b9b63dc..c58bb2f 100755 --- a/configure +++ b/configure @@ -20,7 +20,7 @@ doxygen_version_minor=6 doxygen_version_revision=3 #NOTE: Setting version_mmn to "NO" will omit mmn info from the package. -doxygen_version_mmn=20100324 +doxygen_version_mmn=20100418 bin_dirs=`echo $PATH | sed -e "s/:/ /g"` diff --git a/qtools/Doxyfile b/qtools/Doxyfile index 1727cf9..2ca19ff 100644 --- a/qtools/Doxyfile +++ b/qtools/Doxyfile @@ -155,7 +155,7 @@ GENERATE_ECLIPSEHELP = YES ECLIPSE_DOC_ID = org.doxygen.qtools DISABLE_INDEX = NO ENUM_VALUES_PER_LINE = 4 -GENERATE_TREEVIEW = NO +GENERATE_TREEVIEW = YES USE_INLINE_TREES = NO TREEVIEW_WIDTH = 250 FORMULA_FONTSIZE = 10 diff --git a/src/definition.cpp b/src/definition.cpp index a53586f..7db9417 100644 --- a/src/definition.cpp +++ b/src/definition.cpp @@ -839,7 +839,8 @@ void Definition::writeInlineCode(OutputList &ol,const char *scopeName) actualStart, // startLine actualEnd, // endLine TRUE, // inlineFragment - thisMd // memberDef + thisMd, // memberDef + FALSE // show line numbers ); ol.endCodeFragment(); ol.endParagraph(); @@ -1237,34 +1238,43 @@ QCString Definition::convertNameToFile(const char *name,bool allowDots) const } } -void Definition::writePathFragment(OutputList &ol) const +QCString Definition::pathFragment() const { makeResident(); + QCString result; if (m_impl->outerScope && m_impl->outerScope!=Doxygen::globalScope) { - m_impl->outerScope->writePathFragment(ol); -#if 0 - if (m_impl->outerScope->definitionType()==Definition::TypeClass || - m_impl->outerScope->definitionType()==Definition::TypeNamespace) + result = m_impl->outerScope->pathFragment(); + } + if (isLinkable()) + { + if (!result.isEmpty()) result+="/"; + if (definitionType()==Definition::TypeGroup && ((const GroupDef*)this)->groupTitle()) { - if (Config_getBool("OPTIMIZE_OUTPUT_JAVA") || - Config_getBool("OPTIMIZE_OUTPUT_VHDL") - ) - { - ol.writeString("."); - } - else - { - ol.writeString("::"); - } + result+=((const GroupDef*)this)->groupTitle(); + } + else if (definitionType()==Definition::TypePage && !((const PageDef*)this)->title().isEmpty()) + { + result+=((const PageDef*)this)->title(); } else { - ol.writeString(" "); - ol.writeString("»"); - ol.writeString(" "); + result+=m_impl->localName; } -#endif + } + else + { + result+=m_impl->localName; + } + return result; +} + +void Definition::writePathFragment(OutputList &ol) const +{ + makeResident(); + if (m_impl->outerScope && m_impl->outerScope!=Doxygen::globalScope) + { + m_impl->outerScope->writePathFragment(ol); } ol.writeString("
  • "); if (isLinkable()) diff --git a/src/definition.h b/src/definition.h index 9c3c1c5..a647756 100644 --- a/src/definition.h +++ b/src/definition.h @@ -308,6 +308,7 @@ class Definition : public DefinitionIntf, public LockableObj void writeNavigationPath(OutputList &ol) const; virtual void writeQuickMemberLinks(OutputList &,MemberDef *) const {} virtual void writeSummaryLinks(OutputList &) {} + QCString pathFragment() const; /*! Writes the documentation anchors of the definition to * the Doxygen::tagFile stream. diff --git a/src/dirdef.cpp b/src/dirdef.cpp index bc0f4f9..0d9faf6 100644 --- a/src/dirdef.cpp +++ b/src/dirdef.cpp @@ -193,6 +193,7 @@ void DirDef::writeDirectoryGraph(OutputList &ol) ol.startParagraph(); ol.startDirDepGraph(); //TODO: ol.parseText(theTranslator->trDirDepGraph()); + ol.parseText((QCString)"Directory dependency graph for "+displayName()+":"); ol.endDirDepGraph(dirDep); ol.endParagraph(); ol.enableAll(); @@ -722,12 +723,15 @@ void DirRelation::writeDocumentation(OutputList &ol) ol.writeString(""); ol.writeString(""); // TODO: translate me! "File in %s" - ol.writeString(""); // TODO: translate me! "Includes file in %s" - ol.writeString(""); ol.writeString(""); diff --git a/src/docparser.cpp b/src/docparser.cpp index d0b8fb0..cd7e956 100644 --- a/src/docparser.cpp +++ b/src/docparser.cpp @@ -535,10 +535,10 @@ static void detectNoDocumentedParams() } else if ( // see if return needs to documented g_memberDef->hasDocumentedReturnType() || - returnType.isEmpty() || // empty return type - returnType.find("void")!=-1 || // void return type - !g_memberDef->isConstructor() || // a constructor - !g_memberDef->isDestructor() // or destructor + returnType.isEmpty() || // empty return type + returnType.find("void")!=-1 || // void return type + g_memberDef->isConstructor() || // a constructor + g_memberDef->isDestructor() // or destructor ) { g_memberDef->setHasDocumentedReturnType(TRUE); @@ -670,7 +670,24 @@ static bool findDocsForMemberOrCompound(const char *commandName, if (l==0) return FALSE; int funcStart=cmdArg.find('('); - if (funcStart==-1) funcStart=l; + if (funcStart==-1) + { + funcStart=l; + } + else + { + // Check for the case of operator() and the like. + // beware of scenarios like operator()((foo)bar) + int secondParen = cmdArg.find('(', funcStart+1); + int leftParen = cmdArg.find(')', funcStart+1); + if (leftParen!=-1 && secondParen!=-1) + { + if (leftParen, public DocNode DocCopy(DocNode *parent,const QString &link,bool copyBrief,bool copyDetails) : m_parent(parent), m_link(link), m_copyBrief(copyBrief), m_copyDetails(copyDetails) { } - Kind kind() const { return Kind_IndexEntry; } + Kind kind() const { return Kind_Copy; } QString link() const { return m_link; } DocNode *parent() const { return m_parent; } void accept(DocVisitor *v) { CompAccept::accept(this,v); } diff --git a/src/doctokenizer.l b/src/doctokenizer.l index 52cb7d1..a7bcead 100644 --- a/src/doctokenizer.l +++ b/src/doctokenizer.l @@ -327,10 +327,10 @@ OPMASK ({BLANK}*{OPNORM}{FUNCARG}) OPMASKOPT ({BLANK}*{OPNORM}{FUNCARG}?)|({OPCAST}{FUNCARG}) LNKWORD1 ("::"|"#")?{SCOPEMASK} CVSPEC {BLANK}*("const"|"volatile") -LNKWORD2 ({SCOPEPRE}*"operator"{OPMASK})|({SCOPEPRE}"operator"{OPMASKOPT})|(("::"|"#"){SCOPEPRE}*"operator"{OPMASKOPT}) +LNKWORD2 (({SCOPEPRE}*"operator"{OPMASK})|({SCOPEPRE}"operator"{OPMASKOPT})|(("::"|"#"){SCOPEPRE}*"operator"{OPMASKOPT})){CVSPEC}? LNKWORD3 ([0-9a-z_A-Z\-]+("/"|"\\"))*[0-9a-z_A-Z\-]+("."[0-9a-z_A-Z]+)+ CHARWORDQ [^ \t\n\r\\@<>()\[\]:;\?{}&%$#,."] -WORD1 "%"?{CHARWORDQ}+|"{"|"}"|("\""[^"\n]*\n?[^"\n]*"\"") +WORD1 "%"?{CHARWORDQ}+|"{"|"}"|"'\"'"|("\""[^"\n]*\n?[^"\n]*"\"") WORD2 "."|","|"("|")"|"["|"]"|":"|";"|"\?" WORD1NQ "%"?{CHARWORDQ}+ WORD2NQ "."|","|"("|")"|"["|"]"|":"|";"|"\?" @@ -472,8 +472,8 @@ REFWORD {LABELID}|{REFWORD2} "$"{ID}":"[^\n$]+"$" { /* RCS tag */ QString tagName(yytext+1); int index=tagName.find(':'); - g_token->name = tagName.left(index); - g_token->text = tagName.mid(index+1,tagName.length()-index-2); + g_token->name = tagName.left(index+1); + g_token->text = tagName.mid(index+2,tagName.length()-index-3); return TK_RCSTAG; } "$("{ID}")" { /* environment variable */ diff --git a/src/doxygen.cpp b/src/doxygen.cpp index 87e66d1..c07b2b7 100644 --- a/src/doxygen.cpp +++ b/src/doxygen.cpp @@ -8103,6 +8103,7 @@ static void generateExampleDocs() startTitle(*g_outputList,n); g_outputList->docify(pd->name()); endTitle(*g_outputList,n,0); + g_outputList->startContents(); g_outputList->parseDoc(pd->docFile(), // file pd->docLine(), // startLine pd, // context @@ -8112,6 +8113,7 @@ static void generateExampleDocs() TRUE, // is example pd->name() ); + g_outputList->endContents(); endFile(*g_outputList); } g_outputList->enable(OutputGenerator::Man); diff --git a/src/doxygen.css b/src/doxygen.css index b9053a7..28c5241 100644 --- a/src/doxygen.css +++ b/src/doxygen.css @@ -628,6 +628,8 @@ div.summary a div.header { + background-image:url('nav_h.png'); + background-repeat:repeat-x; background-color: ##FA; margin: 0px; border-bottom: 1px solid ##CC; diff --git a/src/doxygen_css.h b/src/doxygen_css.h index 3d91609..ff941b3 100644 --- a/src/doxygen_css.h +++ b/src/doxygen_css.h @@ -628,6 +628,8 @@ "\n" "div.header\n" "{\n" +" background-image:url('nav_h.png');\n" +" background-repeat:repeat-x;\n" " background-color: ##FA;\n" " margin: 0px;\n" " border-bottom: 1px solid ##CC;\n" diff --git a/src/htmldocvisitor.cpp b/src/htmldocvisitor.cpp index 194faa5..c15d71a 100644 --- a/src/htmldocvisitor.cpp +++ b/src/htmldocvisitor.cpp @@ -89,6 +89,11 @@ static bool mustBeOutsideParagraph(DocNode *n) case DocNode::Kind_SecRefList: /*
    */ case DocNode::Kind_HorRuler: + /* CopyDoc gets paragraph markers from the wrapping DocPara node, + * but needs to insert them for all documentation being copied to + * preserve formatting. + */ + case DocNode::Kind_Copy: return TRUE; case DocNode::Kind_StyleChange: return ((DocStyleChange*)n)->style()==DocStyleChange::Preformatted || @@ -715,6 +720,7 @@ void HtmlDocVisitor::visitPre(DocPara *p) case DocNode::Kind_AutoListItem: case DocNode::Kind_SimpleSect: case DocNode::Kind_XRefItem: + case DocNode::Kind_Copy: needsTag = TRUE; break; case DocNode::Kind_Root: @@ -795,6 +801,7 @@ void HtmlDocVisitor::visitPost(DocPara *p) case DocNode::Kind_AutoListItem: case DocNode::Kind_SimpleSect: case DocNode::Kind_XRefItem: + case DocNode::Kind_Copy: needsTag = TRUE; break; case DocNode::Kind_Root: diff --git a/src/htmlgen.cpp b/src/htmlgen.cpp index a844dcb..012a3e2 100644 --- a/src/htmlgen.cpp +++ b/src/htmlgen.cpp @@ -64,6 +64,7 @@ static QCString g_footer; //------------------------- Pictures for the Tabs ------------------------ +// active static unsigned char tab_a_png[36] = { 31, 42, 59, 69, 73, 74, 75, 77, 77, @@ -72,6 +73,7 @@ static unsigned char tab_a_png[36] = 96, 96, 97, 98, 98, 99, 99, 99, 100 }; +// normal background static unsigned char tab_b_png[36] = { 240, 239, 238, 237, 235, 234, 234, 232, 231, @@ -80,6 +82,14 @@ static unsigned char tab_b_png[36] = 196, 195, 193, 192, 190, 189, 188, 188, 188 }; +// shadowed header +static unsigned char header_png[12] = +{ + 255, 240, 241, 242, 243, 244, + 245, 246, 247, 248, 249, 250 +}; + +// hovering static unsigned char tab_h_png[36] = { 199, 198, 196, 196, 195, 194, 193, 192, 189, @@ -88,6 +98,7 @@ static unsigned char tab_h_png[36] = 153, 152, 149, 148, 147, 145, 145, 150, 161 }; +// separator static unsigned char tab_s_png[36] = { 187, 186, 185, 183, 182, 181, 180, 178, 176, @@ -96,6 +107,7 @@ static unsigned char tab_s_png[36] = 138, 136, 134, 131, 131, 128, 126, 125, 124 }; + static unsigned char bc_s_png[240] = { 150,187,187,148,148,148,148,148, @@ -692,6 +704,7 @@ static colored_img_data_item colored_tab_data[] = { "tab_b.png", 1, 36, tab_b_png, 0 }, { "tab_h.png", 1, 36, tab_h_png, 0 }, { "tab_s.png", 1, 36, tab_s_png, 0 }, + { "nav_h.png", 1, 12, header_png, 0 }, { "bc_s.png", 8, 32, bc_s_png, bc_s_a_png }, { "doxygen.png", 104,31, doxygen_png, doxygen_a_png }, { "closed.png", 9, 9, closed_png, closed_a_png }, @@ -939,6 +952,7 @@ static void generateDynamicSections(QTextStream &t,const QCString &relPath) if (Config_getBool("HTML_DYNAMIC_SECTIONS")) { t << +#if 0 "\n"; +#endif + "\n"; } } @@ -1031,6 +1083,7 @@ void HtmlGenerator::startFile(const char *name,const char *, t << "-->\n"; } generateDynamicSections(t,relPath); + m_sectionCount=0; } void HtmlGenerator::writeSearchFooter(QTextStream &t,const QCString &relPath) @@ -1494,17 +1547,84 @@ void HtmlGenerator::writeChar(char c) docify(cs); } +//--- helper function for dynamic sections ------------------------- + +static void startSectionHeader(QTextStream &t,int sectionCount) +{ + static bool dynamicSections = Config_getBool("HTML_DYNAMIC_SECTIONS"); + if (dynamicSections) + { + t << "
    " << endl; + t << " "; + } + else + { + t << "
    " << endl; + } +} + +static void endSectionHeader(QTextStream &t) +{ + t << "
    " << endl; +} + +static void startSectionSummary(QTextStream &t,int sectionCount) +{ + static bool dynamicSections = Config_getBool("HTML_DYNAMIC_SECTIONS"); + if (dynamicSections) + { + t << "
    " << endl; + } +} + +static void endSectionSummary(QTextStream &t) +{ + static bool dynamicSections = Config_getBool("HTML_DYNAMIC_SECTIONS"); + if (dynamicSections) + { + t << "
    " << endl; + } +} + +static void startSectionContent(QTextStream &t,int sectionCount) +{ + static bool dynamicSections = Config_getBool("HTML_DYNAMIC_SECTIONS"); + if (dynamicSections) + { + t << "
    " << endl; + } + else + { + t << "
    " << endl; + } +} + +static void endSectionContent(QTextStream &t) +{ + t << "
    " << endl; +} + +//---------------------------- + void HtmlGenerator::startClassDiagram() { - //t << "

    "; - t << "

    " << endl; + startSectionHeader(t,m_sectionCount); } void HtmlGenerator::endClassDiagram(const ClassDiagram &d, const char *fileName,const char *name) { - t << "
    " << endl; - t << "
    " << endl; + endSectionHeader(t); + startSectionSummary(t,m_sectionCount); + endSectionSummary(t); + startSectionContent(t,m_sectionCount); t << "
    " << endl; t << " " << endl; d.writeImage(t,dir,relPath,fileName); - t << "
    " << endl; - t << "
    " << endl; + endSectionContent(t); + m_sectionCount++; } @@ -1880,13 +2000,16 @@ void HtmlGenerator::endMemberDoc(bool hasArgs) void HtmlGenerator::startDotGraph() { - t << "
    " << endl; + startSectionHeader(t,m_sectionCount); } void HtmlGenerator::endDotGraph(const DotClassGraph &g) { - t << "
    " << endl; - t << "
    " << endl; + endSectionHeader(t); + startSectionSummary(t,m_sectionCount); + endSectionSummary(t); + startSectionContent(t,m_sectionCount); + g.writeGraph(t,BITMAP,dir,relPath); if (Config_getBool("GENERATE_LEGEND")) { @@ -1896,59 +2019,81 @@ void HtmlGenerator::endDotGraph(const DotClassGraph &g) endHtmlLink(); t << "]"; } - t << "
    " << endl; + + endSectionContent(t); + m_sectionCount++; } void HtmlGenerator::startInclDepGraph() { - t << "
    " << endl; + startSectionHeader(t,m_sectionCount); } void HtmlGenerator::endInclDepGraph(const DotInclDepGraph &g) { - t << "
    " << endl; - t << "
    " << endl; + endSectionHeader(t); + startSectionSummary(t,m_sectionCount); + endSectionSummary(t); + startSectionContent(t,m_sectionCount); + g.writeGraph(t,BITMAP,dir,relPath); - t << "
    " << endl; + + endSectionContent(t); + m_sectionCount++; } void HtmlGenerator::startGroupCollaboration() { - t << "
    " << endl; + startSectionHeader(t,m_sectionCount); } void HtmlGenerator::endGroupCollaboration(const DotGroupCollaboration &g) { - t << "
    " << endl; - t << "
    " << endl; + endSectionHeader(t); + startSectionSummary(t,m_sectionCount); + endSectionSummary(t); + startSectionContent(t,m_sectionCount); + g.writeGraph(t,BITMAP,dir,relPath); - t << "
    " << endl; + + endSectionContent(t); + m_sectionCount++; } void HtmlGenerator::startCallGraph() { - t << "
    " << endl; + startSectionHeader(t,m_sectionCount); } void HtmlGenerator::endCallGraph(const DotCallGraph &g) { - t << "
    " << endl; - t << "
    " << endl; + endSectionHeader(t); + startSectionSummary(t,m_sectionCount); + endSectionSummary(t); + startSectionContent(t,m_sectionCount); + g.writeGraph(t,BITMAP,dir,relPath); - t << "
    " << endl; + + endSectionContent(t); + m_sectionCount++; } void HtmlGenerator::startDirDepGraph() { - t << "
    " << endl; + startSectionHeader(t,m_sectionCount); } void HtmlGenerator::endDirDepGraph(const DotDirDeps &g) { - t << "
    " << endl; - t << "
    " << endl; + endSectionHeader(t); + startSectionSummary(t,m_sectionCount); + endSectionSummary(t); + startSectionContent(t,m_sectionCount); + g.writeGraph(t,BITMAP,dir,relPath); - t << "
    " << endl; + + endSectionContent(t); + m_sectionCount++; } void HtmlGenerator::writeGraphicalHierarchy(const DotGfxHierarchyTable &g) diff --git a/src/htmlgen.h b/src/htmlgen.h index 32964bf..e795bf9 100644 --- a/src/htmlgen.h +++ b/src/htmlgen.h @@ -261,6 +261,7 @@ class HtmlGenerator : public OutputGenerator HtmlGenerator(const HtmlGenerator &g); int col; + int m_sectionCount; }; #endif diff --git a/src/htmlhelp.cpp b/src/htmlhelp.cpp index 8362519..731ef2d 100644 --- a/src/htmlhelp.cpp +++ b/src/htmlhelp.cpp @@ -24,6 +24,7 @@ #include #include #include "qtextcodec.h" +#include "sortdict.h" #include "htmlhelp.h" #include "config.h" @@ -43,28 +44,15 @@ struct IndexField bool reversed; }; -class IndexFieldList : public QList +class IndexFieldSDict : public SDict { public: + IndexFieldSDict() : SDict(17) {} + ~IndexFieldSDict() {} int compareItems(GCI item1, GCI item2) { return stricmp(((IndexField *)item1)->name,((IndexField *)item2)->name); } - ~IndexFieldList() {} -}; - -class IndexFieldListIterator : public QListIterator -{ - public: - IndexFieldListIterator( const IndexFieldList &list) : - QListIterator(list) {} -}; - -class IndexFieldDict : public QDict -{ - public: - IndexFieldDict(int size) : QDict(size) {} - ~IndexFieldDict() {} }; /*! A helper class for HtmlHelp that manages a two level index in @@ -80,22 +68,19 @@ class HtmlHelpIndex bool hasLink,bool reversed); void writeFields(QTextStream &t); private: - IndexFieldList *list; - IndexFieldDict *dict; + IndexFieldSDict *dict; }; /*! Constructs a new HtmlHelp index */ HtmlHelpIndex::HtmlHelpIndex() { - list = new IndexFieldList; - dict = new IndexFieldDict(10007); - list->setAutoDelete(TRUE); + dict = new IndexFieldSDict; + dict->setAutoDelete(TRUE); } /*! Destroys the HtmlHelp index */ HtmlHelpIndex::~HtmlHelpIndex() { - delete list; delete dict; } @@ -132,8 +117,7 @@ void HtmlHelpIndex::addItem(const char *level1,const char *level2, f->anchor = anchor; f->link = hasLink; f->reversed = reversed; - list->inSort(f); - dict->insert(key,f); + dict->append(key,f); } } @@ -165,7 +149,8 @@ void HtmlHelpIndex::addItem(const char *level1,const char *level2, */ void HtmlHelpIndex::writeFields(QTextStream &t) { - IndexFieldListIterator ifli(*list); + dict->sort(); + IndexFieldSDict::Iterator ifli(*dict); IndexField *f; QCString lastLevel1; bool level2Started=FALSE; @@ -506,15 +491,11 @@ void HtmlHelp::createProjectFile() s = indexFiles.next(); } t << "tabs.css" << endl; -#if 0 - t << "tab_b.gif" << endl; - t << "tab_l.gif" << endl; - t << "tab_r.gif" << endl; -#endif t << "tab_a.png" << endl; t << "tab_b.png" << endl; t << "tab_h.png" << endl; t << "tab_s.png" << endl; + t << "nav_h.png" << endl; if (Config_getBool("HTML_DYNAMIC_SECTIONS")) { t << "open.gif" << endl; diff --git a/src/image.cpp b/src/image.cpp index 66c281c..76f9661 100644 --- a/src/image.cpp +++ b/src/image.cpp @@ -20,8 +20,9 @@ #include "image.h" //#include "gifenc.h" #include -#include "lodepng.h" #include +#include "lodepng.h" +#include "config.h" typedef unsigned char Byte; @@ -210,6 +211,33 @@ static Color palette2[] = Image::Image(int w,int h) { + static int hue = Config_getInt("HTML_COLORSTYLE_HUE"); + static int sat = Config_getInt("HTML_COLORSTYLE_SAT"); + static int gamma = Config_getInt("HTML_COLORSTYLE_GAMMA"); + + double red1,green1,blue1; + double red2,green2,blue2; + + ColoredImage::hsl2rgb(hue/360.0, // hue + sat/255.0, // saturation + pow(235/255.0,gamma/100.0), // luma (gamma corrected) + &red1,&green1,&blue1 + ); + + ColoredImage::hsl2rgb(hue/360.0, // hue + sat/255.0, // saturation + pow(138/255.0,gamma/100.0), // luma (gamma corrected) + &red2,&green2,&blue2 + ); + + palette[2].red = (int)(red1 * 255.0); + palette[2].green = (int)(green1 * 255.0); + palette[2].blue = (int)(blue1 * 255.0); + + palette[3].red = (int)(red2 * 255.0); + palette[3].green = (int)(green2 * 255.0); + palette[3].blue = (int)(blue2 * 255.0); + data = new uchar[w*h]; memset(data,0,w*h); width = w; diff --git a/src/index.cpp b/src/index.cpp index 7e494f8..390fc55 100644 --- a/src/index.cpp +++ b/src/index.cpp @@ -2605,6 +2605,7 @@ void writeJavascriptSearchIndex() if (outFile.open(IO_WriteOnly)) { QTextStream t(&outFile); + t.setEncoding(QTextStream::UnicodeUTF8); t << "" << endl; t << "" << endl; @@ -2641,12 +2642,17 @@ void writeJavascriptSearchIndex() << "class=\"SRSymbol\" "; if (!d->getReference().isEmpty()) { - QCString *dest; - t << "doxygen=\"" << d->getReference() << ":../"; - if ((dest=Doxygen::tagDestinationDict[d->getReference()])) t << *dest << "/"; - t << "\" "; - t << "href=\"../"; - if ((dest=Doxygen::tagDestinationDict[d->getReference()])) t << *dest << "/"; + QCString *dest = Doxygen::tagDestinationDict[d->getReference()]; + if (dest && *dest=='.') // relative path (see bug 593679) + { + t << "doxygen=\"" << d->getReference() << ":../" + << *dest << "/\" href=\"../" << *dest << "/"; + } + else if (dest) // absolute path + { + t << "doxygen=\"" << d->getReference() << ":" + << *dest << "/\" href=\"" << *dest << "/"; + } } else { @@ -2842,6 +2848,7 @@ void writeJavascriptSearchIndex() if (f.open(IO_WriteOnly)) { QTextStream t(&f); + t.setEncoding(QTextStream::UnicodeUTF8); 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; @@ -2892,6 +2899,7 @@ void writeJavascriptSearchIndex() if (f.open(IO_WriteOnly)) { QTextStream t(&f); + t.setEncoding(QTextStream::UnicodeUTF8); t << "" << endl; t << "" << endl; diff --git a/src/language.cpp b/src/language.cpp index 840fece..90fe85d 100644 --- a/src/language.cpp +++ b/src/language.cpp @@ -223,7 +223,7 @@ bool setTranslator(const char *langName) #ifdef LANG_ES else if (L_EQUAL("spanish")) { - theTranslator=new TranslatorDecoder(new TranslatorSpanish); + theTranslator=new TranslatorSpanish; } #endif #ifdef LANG_FI @@ -247,7 +247,7 @@ bool setTranslator(const char *langName) #ifdef LANG_PL else if (L_EQUAL("polish")) { - theTranslator=new TranslatorDecoder(new TranslatorPolish); + theTranslator=new TranslatorPolish; } #endif #ifdef LANG_PT diff --git a/src/latexdocvisitor.cpp b/src/latexdocvisitor.cpp index d6d4437..7897731 100644 --- a/src/latexdocvisitor.cpp +++ b/src/latexdocvisitor.cpp @@ -185,7 +185,7 @@ void LatexDocVisitor::visit(DocSymbol *s) m_t << "\\^{" << s->letter() << "}"; break; case DocSymbol::Slash: if (tolower(s->letter())=='o') - m_t << "\\" << s->letter(); + m_t << "{\\" << s->letter() << "}"; else m_t << s->letter(); break; diff --git a/src/latexgen.cpp b/src/latexgen.cpp index 6cd986e..3f72ff4 100644 --- a/src/latexgen.cpp +++ b/src/latexgen.cpp @@ -914,7 +914,8 @@ void LatexGenerator::endIndexSection(IndexSections is) { if (!gd->isReference()) { - if (compactLatex) t << "\\input"; else t << "\\include"; + //if (compactLatex) t << "\\input"; else t << "\\include"; + t << "\\input"; t << "{" << gd->getOutputFileBase() << "}\n"; } } @@ -937,7 +938,8 @@ void LatexGenerator::endIndexSection(IndexSections is) { if (dd->isLinkableInProject()) { - if (compactLatex) t << "\\input"; else t << "\\include"; + //if (compactLatex) t << "\\input"; else t << "\\include"; + t << "\\input"; t << "{" << dd->getOutputFileBase() << "}\n"; } } @@ -960,7 +962,8 @@ void LatexGenerator::endIndexSection(IndexSections is) { if (nd->isLinkableInProject()) { - if (compactLatex) t << "\\input"; else t << "\\include"; + //if (compactLatex) t << "\\input"; else t << "\\include"; + t << "\\input"; t << "{" << nd->getOutputFileBase() << "}\n"; } ++nli; @@ -984,7 +987,8 @@ void LatexGenerator::endIndexSection(IndexSections is) { if (cd->isLinkableInProject() && cd->templateMaster()==0) { - if (compactLatex) t << "\\input"; else t << "\\include"; + //if (compactLatex) t << "\\input"; else t << "\\include"; + t << "\\input"; t << "{" << cd->getOutputFileBase() << "}\n"; } } @@ -1006,17 +1010,20 @@ void LatexGenerator::endIndexSection(IndexSections is) t << "}\n\\input{" << fd->getOutputFileBase() << "}\n"; if (sourceBrowser && m_prettyCode && fd->generateSourceFile()) { - t << "\\include{" << fd->getSourceFileBase() << "}\n"; + //t << "\\include{" << fd->getSourceFileBase() << "}\n"; + t << "\\input{" << fd->getSourceFileBase() << "}\n"; } isFirst=FALSE; } else { - if (compactLatex) t << "\\input" ; else t << "\\include"; + //if (compactLatex) t << "\\input" ; else t << "\\include"; + t << "\\input" ; t << "{" << fd->getOutputFileBase() << "}\n"; if (sourceBrowser && m_prettyCode && fd->generateSourceFile()) { - t << "\\include{" << fd->getSourceFileBase() << "}\n"; + //t << "\\include{" << fd->getSourceFileBase() << "}\n"; + t << "\\input{" << fd->getSourceFileBase() << "}\n"; } } } @@ -1037,7 +1044,8 @@ void LatexGenerator::endIndexSection(IndexSections is) } for (++pdi;(pd=pdi.current());++pdi) { - if (compactLatex) t << "\\input" ; else t << "\\include"; + //if (compactLatex) t << "\\input" ; else t << "\\include"; + t << "\\input"; t << "{" << pd->getOutputFileBase() << "}\n"; } } @@ -1077,7 +1085,9 @@ void LatexGenerator::endIndexSection(IndexSections is) void LatexGenerator::writePageLink(const char *name, bool first) { bool &compactLatex = Config_getBool("COMPACT_LATEX"); - if (compactLatex || first) t << "\\input" ; else t << "\\include"; + // next is remove for bug615957 + //if (compactLatex || first) t << "\\input" ; else t << "\\include"; + t << "\\input" ; t << "{" << name << "}\n"; } diff --git a/src/mangen.cpp b/src/mangen.cpp index 12c4e2d..67c389b 100644 --- a/src/mangen.cpp +++ b/src/mangen.cpp @@ -409,7 +409,10 @@ void ManGenerator::startDoxyAnchor(const char *,const char *manName, // - truncate after an (optional) :: QCString baseName = name; int i=baseName.findRev("::"); - if (i!=-1) baseName=baseName.right(baseName.length()-i-1); + if (i!=-1) baseName=baseName.right(baseName.length()-i-2); + + //printf("Converting man link '%s'->'%s'->'%s'\n", + // name,baseName.data(),buildFileName(baseName).data()); // - remove dangerous characters and append suffix, then add dir prefix QCString fileName=dir+"/"+buildFileName( baseName ); diff --git a/src/pre.l b/src/pre.l index 1ee4fbe..1f8316f 100644 --- a/src/pre.l +++ b/src/pre.l @@ -188,7 +188,9 @@ static bool macroIsAccessible(Define *def) } if (def && def->fileDef==g_inputFileDef) { - return def->lineNrname().data(),def->name.data(),def->lineNr,g_yyLineNr); + return def->lineNr<=g_yyLineNr; } if (g_inputFileDef && def && def->fileDef) // check if g_inputFileDef actually includes def->fileDef { @@ -198,6 +200,7 @@ static bool macroIsAccessible(Define *def) // g_inputFileDef->name().data(),def->name.data(),def->fileDef->name().data(),b); return b; } + //printf("not accessible!\n"); return FALSE; } @@ -1883,34 +1886,47 @@ CHARLIT (("'"\\[0-7]{1,3}"'")|("'"\\."'")|("'"[^'\\\n]{1,4}"'")) g_defVarArgs = FALSE; BEGIN(DefineArg); } -{ID}/{B}* { // define with content +{ID}{B}+"1" { // special case: define with 1 -> can be "guard" //printf("Define `%s'\n",yytext); g_argDict = 0; g_defArgs = -1; g_defArgsStr.resize(0); - g_defText.resize(0); - g_defLitText.resize(0); g_defName = yytext; + g_defName = g_defName.left(g_defName.length()-1).stripWhiteSpace(); g_defVarArgs = FALSE; - //QCString tmp=(QCString)"#define "+g_defName+g_defArgsStr; - //outputArray(tmp.data(),tmp.length()); - //g_quoteArg=FALSE; - //g_insideComment=FALSE; - //BEGIN(DefineText); if ( g_defName!=g_lastGuardName || !g_expectGuard) { // define may appear in the output QCString tmp=(QCString)"#define "+g_defName; outputArray(tmp.data(),tmp.length()); g_quoteArg=FALSE; g_insideComment=FALSE; + g_lastGuardName.resize(0); + g_defText="1"; + g_defLitText="1"; BEGIN(DefineText); } else // define is a guard => hide { - g_lastGuardName.resize(0); + g_defText.resize(0); + g_defLitText.resize(0); BEGIN(Start); } } +{ID}/{B}* { // define with content + //printf("Define `%s'\n",yytext); + g_argDict = 0; + g_defArgs = -1; + g_defArgsStr.resize(0); + g_defText.resize(0); + g_defLitText.resize(0); + g_defName = yytext; + g_defVarArgs = FALSE; + QCString tmp=(QCString)"#define "+g_defName+g_defArgsStr; + outputArray(tmp.data(),tmp.length()); + g_quoteArg=FALSE; + g_insideComment=FALSE; + BEGIN(DefineText); + } {ID}/{B}*"\n" { // empty define g_argDict = 0; g_defArgs = -1; diff --git a/src/scanner.l b/src/scanner.l index cf1e2bb..7501855 100644 --- a/src/scanner.l +++ b/src/scanner.l @@ -566,7 +566,6 @@ ID "$"?[a-z_A-Z\x80-\xFF][a-z_A-Z0-9\x80-\xFF]* SCOPEID {ID}({ID}*{BN}*"::"{BN}*)*({ID}?) SCOPENAME "$"?(({ID}?{BN}*"::"{BN}*)*)(((~|!){BN}*)?{ID}) TSCOPE {ID}("<"[a-z_A-Z0-9 \t\*\&,]*">")? -FTSCOPE {ID}("<"[a-z_A-Z0-9\*\&,]*">")? CSSCOPENAME (({ID}?{BN}*"."{BN}*)*)((~{BN}*)?{ID}) PRE [pP][rR][eE] CODE [cC][oO][dD][eE] @@ -1603,7 +1602,7 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) current->tArgLists->setAutoDelete(TRUE); } ArgumentList *al = new ArgumentList; - current->spec |= (yytext[0]=='g') ? Entry::Generic : Entry::Template; + //current->spec |= (yytext[0]=='g') ? Entry::Generic : Entry::Template; current->tArgLists->append(al); currentArgumentList = al; templateStr="<"; @@ -1832,7 +1831,7 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) {B}+ { current->type+=yytext; } -({FTSCOPE}"::")*{FTSCOPE} { +({TSCOPE}"::")*{TSCOPE} { current->type+=yytext; BEGIN(QtPropName); } @@ -2001,8 +2000,9 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) BEGIN( SkipCurly ); } . -"catch" { BEGIN(TryFunctionBlock); } -\n { unput(*yytext); // added to fix bug id 601138 +{BN}*"catch" { lineCount(); BEGIN(TryFunctionBlock); // {BN}* added to fix bug 611193 + } +\n { unput(*yytext); // rule added to fix bug id 601138 BEGIN( FindMembers ); } . { unput(*yytext); @@ -4330,6 +4330,10 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) yyLineNr++; } . { } +":" { // for "class : public base {} var;" construct, see bug 608359 + unput(':'); + BEGIN(ClassVar); + } ";" { current->section = Entry::EMPTY_SEC ; current->type.resize(0) ; @@ -4368,7 +4372,8 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) current->tArgLists->setAutoDelete(TRUE); } ArgumentList *al = new ArgumentList; - current->spec |= Entry::Template; + // check bug 612858 before enabling the next line + //current->spec |= Entry::Template; current->tArgLists->append(al); currentArgumentList = al; templateStr="<"; @@ -4846,6 +4851,10 @@ TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?) ")" { if (--roundCount<=0) BEGIN ( lastSkipRoundContext ); } +\" { + lastStringContext=SkipRound; + BEGIN(SkipString); + } ","|(">"({BN}*"{")?)|({BN}+"implements"{BN}*) { lineCount(); if (insideProtocolList) { diff --git a/src/translator.h b/src/translator.h index 86f36ab..bd19092 100644 --- a/src/translator.h +++ b/src/translator.h @@ -486,6 +486,18 @@ class Translator virtual QCString trSearching() = 0; virtual QCString trNoMatches() = 0; +////////////////////////////////////////////////////////////////////////// +// new since 1.6.3 +////////////////////////////////////////////////////////////////////////// + + virtual QCString trDirDependency(const char *name) = 0; + virtual QCString trFileIn(const char *name) = 0; + virtual QCString trIncludesFileIn(const char *name) = 0; + virtual QCString trDateTime(int year,int month,int day,int dayOfWeek, + int hour,int minutes,int seconds, + bool includeTime) = 0; + + }; #endif diff --git a/src/translator_adapter.h b/src/translator_adapter.h index 869b25d..74819bd 100644 --- a/src/translator_adapter.h +++ b/src/translator_adapter.h @@ -41,7 +41,25 @@ class TranslatorAdapterBase : public Translator }; -class TranslatorAdapter_1_6_0 : public TranslatorAdapterBase +class TranslatorAdapter_1_6_3 : public TranslatorAdapterBase +{ + public: + virtual QCString updateNeededMessage() + { return createUpdateNeededMessage(idLanguage(),"release 1.6.3"); } + + virtual QCString trDirDependency(const char *name) + { return english.trDirDependency(name); } + virtual QCString trFileIn(const char *name) + { return english.trFileIn(name); } + virtual QCString trIncludesFileIn(const char *name) + { return english.trIncludesFileIn(name); } + virtual QCString trDateTime(int year,int month,int day,int dayOfWeek, + int hour,int minutes,int seconds, + bool includeTime) + { return english.trDateTime(year,month,day,dayOfWeek,hour,minutes,seconds,includeTime); } +}; + +class TranslatorAdapter_1_6_0 : public TranslatorAdapter_1_6_3 { public: virtual QCString updateNeededMessage() diff --git a/src/translator_br.h b/src/translator_br.h index 662fc51..850e4dc 100644 --- a/src/translator_br.h +++ b/src/translator_br.h @@ -35,7 +35,7 @@ #ifndef TRANSLATOR_BR_H #define TRANSLATOR_BR_H -class TranslatorBrazilian : public Translator +class TranslatorBrazilian : public TranslatorAdapter_1_6_3 { public: diff --git a/src/translator_ca.h b/src/translator_ca.h index db2ebf9..6c90abd 100644 --- a/src/translator_ca.h +++ b/src/translator_ca.h @@ -40,7 +40,7 @@ Translator class (by the local maintainer) when the localized translator is made up-to-date again. */ -class TranslatorCatalan : public Translator +class TranslatorCatalan : public TranslatorAdapter_1_6_3 { public: diff --git a/src/translator_cz.h b/src/translator_cz.h index b3605d6..a50f40d 100644 --- a/src/translator_cz.h +++ b/src/translator_cz.h @@ -79,7 +79,7 @@ // something else. It is difficult to find the general translation // for all kinds in the Czech language. -class TranslatorCzech : public Translator +class TranslatorCzech : public TranslatorAdapter_1_6_3 { public: // --- Language control methods ------------------- diff --git a/src/translator_de.h b/src/translator_de.h index d3e3a61..5188f45 100644 --- a/src/translator_de.h +++ b/src/translator_de.h @@ -129,7 +129,7 @@ #ifndef TRANSLATOR_DE_H #define TRANSLATOR_DE_H -class TranslatorGerman : public Translator +class TranslatorGerman : public TranslatorAdapter_1_6_3 { public: diff --git a/src/translator_en.h b/src/translator_en.h index 1b82bd2..a61e192 100644 --- a/src/translator_en.h +++ b/src/translator_en.h @@ -74,7 +74,8 @@ class TranslatorEnglish : public Translator return ""; } - /*! return the language charset. This will be used for the HTML output */ + /*! return the language charset. This will be used + when transcoding the translatable strings in this file to UTF-8 */ virtual QCString idLanguageCharset() { return "iso-8859-1"; @@ -1814,6 +1815,62 @@ class TranslatorEnglish : public Translator return "No Matches"; } +////////////////////////////////////////////////////////////////////////// +// new since 1.6.3 (missing items for the directory pages) +////////////////////////////////////////////////////////////////////////// + + /*! introduction text for the directory dependency graph */ + virtual QCString trDirDependency(const char *name) + { + return (QCString)"Directory dependency graph for "+name; + } + + /*! when clicking a directory dependency label, a page with a + * table is shown. The heading for the first column mentions the + * source file that has a relation to another file. + */ + virtual QCString trFileIn(const char *name) + { + return (QCString)"File in "+name; + } + + /*! when clicking a directory dependency label, a page with a + * table is shown. The heading for the second column mentions the + * destination file that is included. + */ + virtual QCString trIncludesFileIn(const char *name) + { + return (QCString)"Includes file in "+name; + } + + /** Compiles a date string. + * @param year Year in 4 digits + * @param month Month of the year: 1=January + * @param day Day of the Month: 1..31 + * @param dayOfWeek Day of the week: 1=Monday..7=Sunday + * @param hour Hour of the day: 0..23 + * @param minutes Minutes in the hour: 0..59 + * @param seconds Seconds within the minute: 0..59 + * @param includeTime Include time in the result string? + */ + virtual QCString trDateTime(int year,int month,int day,int dayOfWeek, + int hour,int minutes,int seconds, + bool includeTime) + { + static const char *days[] = { "Mon","Tue","Wed","Thu","Fri","Sat","Sun" }; + static const char *months[] = { "Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec" }; + QCString sdate; + sdate.sprintf("%s %s %d %d",days[dayOfWeek-1],months[month-1],day,year); + if (includeTime) + { + QCString stime; + stime.sprintf(" %.2d:%.2d:%.2d",hour,minutes,seconds); + sdate+=stime; + } + return sdate; + } + + }; #endif diff --git a/src/translator_eo.h b/src/translator_eo.h index c0610e6..59d47ec 100644 --- a/src/translator_eo.h +++ b/src/translator_eo.h @@ -40,7 +40,7 @@ Translator class (by the local maintainer) when the localized translator is made up-to-date again. */ -class TranslatorEsperanto : public Translator +class TranslatorEsperanto : public TranslatorAdapter_1_6_3 { public: diff --git a/src/translator_es.h b/src/translator_es.h index bd663bc..f15145e 100644 --- a/src/translator_es.h +++ b/src/translator_es.h @@ -30,7 +30,7 @@ #ifndef TRANSLATOR_ES_H #define TRANSLATOR_ES_H -class TranslatorSpanish : public Translator +class TranslatorSpanish : public TranslatorAdapter_1_6_3 { public: diff --git a/src/translator_fa.h b/src/translator_fa.h index a7dad2b..fc90abe 100644 --- a/src/translator_fa.h +++ b/src/translator_fa.h @@ -27,8 +27,8 @@ #ifndef TRANSLATOR_FA_H #define TRANSLATOR_FA_H -#define HtmlRightToLeft QCString("
    ") -#define HtmlLeftToRight QCString("
    ") +#define HtmlRightToLeft QCString("
    ") +#define HtmlLeftToRight QCString("
    ") #define HtmlDivEnd QCString("
    ") diff --git a/src/translator_fr.h b/src/translator_fr.h index b1ee2da..95a7790 100644 --- a/src/translator_fr.h +++ b/src/translator_fr.h @@ -100,7 +100,7 @@ // Translator class (by the local maintainer) when the localized // translator is made up-to-date again. -class TranslatorFrench : public Translator +class TranslatorFrench : public TranslatorAdapter_1_6_3 { public: diff --git a/src/translator_hr.h b/src/translator_hr.h index cb229d4..aeca4d1 100644 --- a/src/translator_hr.h +++ b/src/translator_hr.h @@ -78,7 +78,7 @@ #ifndef TRANSLATOR_HR_H #define TRANSLATOR_HR_H -class TranslatorCroatian : public Translator +class TranslatorCroatian : public TranslatorAdapter_1_6_3 { private: diff --git a/src/translator_kr.h b/src/translator_kr.h index 6fd1831..8cb691a 100644 --- a/src/translator_kr.h +++ b/src/translator_kr.h @@ -50,7 +50,7 @@ Translator class (by the local maintainer) when the localized translator is made up-to-date again. */ -class TranslatorKorean : public Translator +class TranslatorKorean : public TranslatorAdapter_1_6_3 { protected: friend class TranslatorAdapterBase; diff --git a/src/translator_nl.h b/src/translator_nl.h index f8e57b7..595f944 100644 --- a/src/translator_nl.h +++ b/src/translator_nl.h @@ -1127,19 +1127,19 @@ class TranslatorDutch : public Translator * hierarchy. */ virtual QCString trDirIndex() - { return "Directory Hiërarchie"; } + { return "Folder Hiërarchie"; } /*! This is used as the name of the chapter containing the documentation * of the directories. */ virtual QCString trDirDocumentation() - { return "Directory Documentatie"; } + { return "Folder Documentatie"; } /*! This is used as the title of the directory index and also in the * Quick links of a HTML page, to link to the directory hierarchy. */ virtual QCString trDirectories() - { return "Directories"; } + { return "Folders"; } /*! This returns a sentences that introduces the directory hierarchy. * and the fact that it is sorted alphabetically per level @@ -1153,15 +1153,15 @@ class TranslatorDutch : public Translator * directory is passed via \a dirName. */ virtual QCString trDirReference(const char *dirName) - { QCString result=dirName; result+=" Directory Referentie"; return result; } + { QCString result=dirName; result+=" Folder Referentie"; return result; } /*! This returns the word directory with or without starting capital * (\a first_capital) and in sigular or plural form (\a singular). */ virtual QCString trDir(bool first_capital, bool singular) { - QCString result((first_capital ? "Director" : "director")); - if (singular) result+="y"; else result+="ies"; + QCString result((first_capital ? "Folder" : "folder")); + if (!singular) result+="s"; return result; } @@ -1407,6 +1407,51 @@ class TranslatorDutch : public Translator return "Niets gevonden"; } +////////////////////////////////////////////////////////////////////////// +// new since 1.6.3 (missing items for the directory pages) +////////////////////////////////////////////////////////////////////////// + + /*! introduction text for the directory dependency graph */ + virtual QCString trDirDependency(const char *name) + { + return (QCString)"Folder afhankelijkheidsgraaf voor "+name; + } + + /*! when clicking a directory dependency label, a page with a + * table is shown. The heading for the first column mentions the + * source file that has a relation to another file. + */ + virtual QCString trFileIn(const char *name) + { + return (QCString)"Bestand in "+name; + } + + /*! when clicking a directory dependency label, a page with a + * table is shown. The heading for the second column mentions the + * destination file that is included. + */ + virtual QCString trIncludesFileIn(const char *name) + { + return (QCString)"Includeert bestand in "+name; + } + virtual QCString trDateTime(int year,int month,int day,int dayOfWeek, + int hour,int minutes,int seconds, + bool includeTime) + { + static const char *days[] = { "Ma","Di","Wo","Do","Vr","Za","Zo" }; + static const char *months[] = { "Jan","Feb","Maa","Apr","Mei","Jun","Jul","Aug","Sep","Okt","Nov","Dec" }; + QCString sdate; + sdate.sprintf("%s %d %s %d",days[dayOfWeek-1],day,months[month-1],year); + if (includeTime) + { + QCString stime; + stime.sprintf(" %.2d:%.2d:%.2d",hour,minutes,seconds); + sdate+=stime; + } + return sdate; + } + + }; diff --git a/src/translator_pl.h b/src/translator_pl.h index d67238d..92f7aeb 100644 --- a/src/translator_pl.h +++ b/src/translator_pl.h @@ -20,7 +20,7 @@ #ifndef TRANSLATOR_PL_H #define TRANSLATOR_PL_H -class TranslatorPolish : public Translator +class TranslatorPolish : public TranslatorAdapter_1_6_3 { public: diff --git a/src/translatordecoder.h b/src/translatordecoder.h index 72ab11c..aa3fe3c 100644 --- a/src/translatordecoder.h +++ b/src/translatordecoder.h @@ -723,6 +723,23 @@ class TranslatorDecoder : public Translator { return toUtf8(m_translator->trNoMatches()); } ////////////////////////////////////////////////////////////////////////// +// new since 1.6.3 +////////////////////////////////////////////////////////////////////////// + + QCString trDirDependency(const char *name) + { return toUtf8(m_translator->trDirDependency(fromUtf8(name))); } + QCString trFileIn(const char *name) + { return toUtf8(m_translator->trFileIn(fromUtf8(name))); } + QCString trIncludesFileIn(const char *name) + { return toUtf8(m_translator->trIncludesFileIn(fromUtf8(name))); } + QCString trDateTime(int year,int month,int day,int dayOfWeek, + int hour,int minutes,int seconds,bool includeTime) + { return toUtf8(m_translator->trDateTime(year,month,day,dayOfWeek, + hour,minutes,seconds,includeTime)); + } + + +////////////////////////////////////////////////////////////////////////// private: Translator *m_translator; void *m_toUtf8; diff --git a/src/util.cpp b/src/util.cpp index 1bb85f2..f6213cd 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -2255,6 +2255,16 @@ QCString fileToString(const char *name,bool filter) QCString dateToString(bool includeTime) { + QDateTime current = QDateTime::currentDateTime(); + return theTranslator->trDateTime(current.date().year(), + current.date().month(), + current.date().day(), + current.date().dayOfWeek(), + current.time().hour(), + current.time().minute(), + current.time().second(), + includeTime); +#if 0 if (includeTime) { return convertToQCString(QDateTime::currentDateTime().toString()); @@ -2269,6 +2279,7 @@ QCString dateToString(bool includeTime) d.year()); return result; } +#endif } QCString yearToString() @@ -3684,7 +3695,7 @@ bool getDefs(const QCString &scName,const QCString &memberName, //printf("mName=%s mn=%p\n",mName.data(),mn); if (!forceEmptyScope && mn && !(scopeName.isEmpty() && mScope.isEmpty())) { - //printf(" >member name found\n"); + //printf(" >member name '%s' found\n",mName.data()); int scopeOffset=scopeName.length(); do { @@ -3695,13 +3706,13 @@ bool getDefs(const QCString &scName,const QCString &memberName, } else if (!mScope.isEmpty()) { - className=mScope.copy(); + className=mScope; } - //printf("Trying class scope %s\n",className.data()); - ClassDef *fcd=0; + ClassDef *fcd=getResolvedClass(Doxygen::globalScope,0,className); + //printf("Trying class scope %s: %p\n",className.data(),fcd); // todo: fill in correct fileScope! - if ((fcd=getResolvedClass(Doxygen::globalScope,0,className)) && // is it a documented class + if (fcd && // is it a documented class fcd->isLinkable() ) { diff --git a/src/xmlgen.cpp b/src/xmlgen.cpp index cdd0377..400180e 100644 --- a/src/xmlgen.cpp +++ b/src/xmlgen.cpp @@ -1802,6 +1802,7 @@ static void generateXMLForPage(PageDef *pd,QTextStream &ti,bool isExample) { t << " " << convertToXML(si->title) << "" << endl; } + writeInnerPages(pd->getSubPages(),t); t << " " << endl; if (isExample) { -- cgit v0.12
    File in "); - m_src->writePathFragment(ol); + ol.writeString(""); + ol.parseText(theTranslator->trFileIn(m_src->pathFragment())); + //m_src->writePathFragment(ol); ol.writeString("Includes file in "); - m_dst->dir()->writePathFragment(ol); + ol.writeString(""); + //ol.writeString("Includes file in "); + //m_dst->dir()->writePathFragment(ol); + ol.parseText(theTranslator->trIncludesFileIn(m_dst->dir()->pathFragment())); ol.writeString("