Skip to content

Commit 5bd253e

Browse files
committed
Various tweaks and fixes for the HTML outline panel
1 parent 9f5f608 commit 5bd253e

19 files changed

+73
-98
lines changed

src/classdef.cpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2991,8 +2991,12 @@ void ClassDefImpl::writeDocumentation(OutputList &ol) const
29912991
break;
29922992
}
29932993
}
2994-
bool hasAllMembersPage = hasAllMembersLink && !m_allMemberNameInfoLinkedMap.empty() && !Config_getBool(OPTIMIZE_OUTPUT_FOR_C);
2995-
startFile(ol,getOutputFileBase(),name(),pageTitle,hli,!generateTreeView,QCString(),0,hasAllMembersPage);
2994+
QCString memListFile;
2995+
if (hasAllMembersLink && !m_allMemberNameInfoLinkedMap.empty() && !Config_getBool(OPTIMIZE_OUTPUT_FOR_C))
2996+
{
2997+
memListFile = getMemberListFileName();
2998+
}
2999+
startFile(ol,getOutputFileBase(),name(),pageTitle,hli,!generateTreeView,QCString(),0,memListFile);
29963000
if (!generateTreeView)
29973001
{
29983002
if (getOuterScope()!=Doxygen::globalScope)

src/classlist.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ void ClassLinkedRefMap::writeDocumentation(OutputList &ol,const Definition * con
9898
if (!found)
9999
{
100100
ol.writeRuler();
101-
ol.startGroupHeader();
101+
ol.startGroupHeader("inline_classes");
102102
ol.parseText(fortranOpt?theTranslator->trTypeDocumentation():
103103
theTranslator->trClassDocumentation());
104104
ol.endGroupHeader();

src/docbookgen.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ class DocbookGenerator : public OutputGenerator, public OutputGenIntf
261261
void writeGraphicalHierarchy(DotGfxHierarchyTable &) override {DB_GEN_NEW}
262262
void startQuickIndices() override {DB_GEN_EMPTY}
263263
void endQuickIndices() override {DB_GEN_EMPTY}
264-
void writeSplitBar(const QCString &,bool) override {DB_GEN_EMPTY}
264+
void writeSplitBar(const QCString &,const QCString &) override {DB_GEN_EMPTY}
265265
void writeNavigationPath(const QCString &) override {DB_GEN_NEW}
266266
void writeLogo() override {DB_GEN_NEW}
267267
void writeQuickLinks(HighlightedItem,const QCString &,bool) override {DB_GEN_EMPTY}

src/htmlgen.cpp

Lines changed: 10 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -432,9 +432,7 @@ static QCString substituteHtmlKeywords(const QCString &file,
432432
if (disableIndex || !Config_getBool(HTML_DYNAMIC_MENUS) || Config_getBool(FULL_SIDEBAR))
433433
{
434434
searchCssJs += "<script type=\"text/javascript\">\n"
435-
"/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */\n"
436435
" $(function() { init_search(); });\n"
437-
"/* @license-end */\n"
438436
"</script>";
439437
}
440438
}
@@ -443,11 +441,9 @@ static QCString substituteHtmlKeywords(const QCString &file,
443441
if (disableIndex || !Config_getBool(HTML_DYNAMIC_MENUS))
444442
{
445443
searchCssJs += "<script type=\"text/javascript\">\n"
446-
"/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */\n"
447444
" $(function() {\n"
448445
" if ($('.searchresults').length > 0) { searchBox.DOMSearchField().focus(); }\n"
449446
" });\n"
450-
" /* @license-end */\n"
451447
"</script>\n";
452448
}
453449

@@ -1471,18 +1467,14 @@ void HtmlGenerator::startFile(const QCString &name,const QCString &,
14711467
if (searchEngine /*&& !generateTreeView*/)
14721468
{
14731469
m_t << "<script type=\"text/javascript\">\n";
1474-
m_t << "/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */\n";
14751470
m_t << "var searchBox = new SearchBox(\"searchBox\", \""
14761471
<< m_relPath<< "search/\",'" << Doxygen::htmlFileExtension << "');\n";
1477-
m_t << "/* @license-end */\n";
14781472
m_t << "</script>\n";
14791473
}
14801474
if (Config_getBool(HTML_CODE_FOLDING))
14811475
{
14821476
m_t << "<script type=\"text/javascript\">\n";
1483-
m_t << "/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */\n";
14841477
m_t << "$(function() { codefold.init(); });\n";
1485-
m_t << "/* @license-end */\n";
14861478
m_t << "</script>\n";
14871479
}
14881480
m_sectionCount=0;
@@ -2927,7 +2919,6 @@ static void writeDefaultQuickLinks(TextStream &t,
29272919
t << "<script type=\"text/javascript\" src=\"" << relPath << "menudata.js\"></script>\n";
29282920
t << "<script type=\"text/javascript\" src=\"" << relPath << "menu.js\"></script>\n";
29292921
t << "<script type=\"text/javascript\">\n";
2930-
t << "/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */\n";
29312922
t << "$(function() {\n";
29322923
t << " initMenu('" << relPath << "',"
29332924
<< (searchEngine && !(generateTreeView && fullSidebar)?"true":"false") << ","
@@ -2953,7 +2944,6 @@ static void writeDefaultQuickLinks(TextStream &t,
29532944
}
29542945
}
29552946
t << "});\n";
2956-
t << "/* @license-end */\n";
29572947
t << "</script>\n";
29582948
t << "<div id=\"main-nav\"></div>\n";
29592949
}
@@ -3006,7 +2996,7 @@ void HtmlGenerator::endQuickIndices()
30062996
}
30072997
}
30082998

3009-
QCString HtmlGenerator::writeSplitBarAsString(const QCString &name,const QCString &relpath,bool showListOfAllMembers)
2999+
QCString HtmlGenerator::writeSplitBarAsString(const QCString &name,const QCString &relpath,const QCString &allMembersFile)
30103000
{
30113001
bool generateTreeView = Config_getBool(GENERATE_TREEVIEW);
30123002
QCString result;
@@ -3031,12 +3021,7 @@ QCString HtmlGenerator::writeSplitBarAsString(const QCString &name,const QCStrin
30313021
" </div>\n"
30323022
"</div>\n"
30333023
"<script type=\"text/javascript\">\n"
3034-
"/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */\n"
3035-
"$(function(){initNavTree('" + fn +
3036-
"','" + relpath +
3037-
"'" + QCString(showListOfAllMembers ? ",true" : "") +
3038-
"); initResizable(true); });\n"
3039-
"/* @license-end */\n"
3024+
"$(function(){initNavTree('" + fn + "','" + relpath + "','" + allMembersFile + "'); initResizable(true); });\n"
30403025
"</script>\n";
30413026
if (Config_getBool(DISABLE_INDEX) || !Config_getBool(FULL_SIDEBAR))
30423027
{
@@ -3046,17 +3031,15 @@ QCString HtmlGenerator::writeSplitBarAsString(const QCString &name,const QCStrin
30463031
else
30473032
{
30483033
result += "<script type=\"text/javascript\">\n"
3049-
"/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */\n"
30503034
"$(function(){ initResizable(false); });\n"
3051-
"/* @license-end */\n"
30523035
"</script>\n";
30533036
}
30543037
return result;
30553038
}
30563039

3057-
void HtmlGenerator::writeSplitBar(const QCString &name,bool showListOfAllMembers)
3040+
void HtmlGenerator::writeSplitBar(const QCString &name,const QCString &allMembersFile)
30583041
{
3059-
m_t << writeSplitBarAsString(name,m_relPath,showListOfAllMembers);
3042+
m_t << writeSplitBarAsString(name,m_relPath,allMembersFile);
30603043
}
30613044

30623045
void HtmlGenerator::writeNavigationPath(const QCString &s)
@@ -3141,10 +3124,8 @@ void HtmlGenerator::writeSearchPage()
31413124
t << "<!-- " << theTranslator->trGeneratedBy() << " Doxygen "
31423125
<< getDoxygenVersion() << " -->\n";
31433126
t << "<script type=\"text/javascript\">\n";
3144-
t << "/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */\n";
3145-
t << "var searchBox = new SearchBox(\"searchBox\", \""
3127+
t << "var searchBox = new SearchBox(\"searchBox\", \""
31463128
<< "search/\",'" << Doxygen::htmlFileExtension << "');\n";
3147-
t << "/* @license-end */\n";
31483129
t << "</script>\n";
31493130

31503131
if (!disableIndex && !quickLinksAfterSplitbar)
@@ -3155,7 +3136,7 @@ void HtmlGenerator::writeSearchPage()
31553136
{
31563137
t << "</div><!-- top -->\n";
31573138
}
3158-
t << writeSplitBarAsString("search.php",QCString(),false);
3139+
t << writeSplitBarAsString("search.php",QCString(),QCString());
31593140
if (quickLinksAfterSplitbar)
31603141
{
31613142
writeDefaultQuickLinks(t,HighlightedItem::Search,QCString(),QCString(),false);
@@ -3208,10 +3189,8 @@ void HtmlGenerator::writeExternalSearchPage()
32083189
t << "<!-- " << theTranslator->trGeneratedBy() << " Doxygen "
32093190
<< getDoxygenVersion() << " -->\n";
32103191
t << "<script type=\"text/javascript\">\n";
3211-
t << "/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */\n";
3212-
t << "var searchBox = new SearchBox(\"searchBox\", \""
3192+
t << "var searchBox = new SearchBox(\"searchBox\", \""
32133193
<< "search/\",'" << Doxygen::htmlFileExtension << "');\n";
3214-
t << "/* @license-end */\n";
32153194
t << "</script>\n";
32163195

32173196
if (!disableIndex && !quickLinksAfterSplitbar)
@@ -3222,7 +3201,7 @@ void HtmlGenerator::writeExternalSearchPage()
32223201
{
32233202
t << "</div><!-- top -->\n";
32243203
}
3225-
t << writeSplitBarAsString("search.php",QCString(),false);
3204+
t << writeSplitBarAsString("search.php",QCString(),QCString());
32263205
if (quickLinksAfterSplitbar)
32273206
{
32283207
writeDefaultQuickLinks(t,HighlightedItem::Search,QCString(),QCString(),false);
@@ -3558,8 +3537,10 @@ void HtmlGenerator::writePageOutline()
35583537
{
35593538
m_t << "<div id=\"page-nav\" class=\"page-nav-panel\">\n";
35603539
m_t << "<div id=\"page-nav-resize-handle\"></div>\n";
3540+
m_t << "<div id=\"page-nav-tree\">\n";
35613541
m_t << "<div id=\"page-nav-contents\">\n";
35623542
m_t << "</div><!-- page-nav-contents -->\n";
3543+
m_t << "</div><!-- page-nav-tree -->\n";
35633544
m_t << "</div><!-- page-nav -->\n";
35643545
}
35653546

src/htmlgen.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ class HtmlGenerator : public OutputGenerator, public OutputGenIntf
111111
static void writeSearchPage();
112112
static void writeExternalSearchPage();
113113
static QCString writeLogoAsString(const QCString &path);
114-
static QCString writeSplitBarAsString(const QCString &name,const QCString &relpath,bool showListOfAllMembers);
114+
static QCString writeSplitBarAsString(const QCString &name,const QCString &relpath,const QCString &allMembersFile);
115115
static QCString getMathJaxMacros();
116116
static QCString getNavTreeCss();
117117
void clearBuffer();
@@ -248,7 +248,7 @@ class HtmlGenerator : public OutputGenerator, public OutputGenIntf
248248
void endPageRef(const QCString &,const QCString &) override {}
249249
void startQuickIndices() override {}
250250
void endQuickIndices() override;
251-
void writeSplitBar(const QCString &name,bool showListOfAllMembers) override;
251+
void writeSplitBar(const QCString &name,const QCString &allMembersFile) override;
252252
void writeNavigationPath(const QCString &s) override;
253253
void writeLogo() override;
254254
void writeQuickLinks(HighlightedItem hli,const QCString &file,bool extraTabs) override;

src/index.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -400,7 +400,7 @@ void endTitle(OutputList &ol,const QCString &fileName,const QCString &name)
400400

401401
void startFile(OutputList &ol,const QCString &name,const QCString &manName,
402402
const QCString &title,HighlightedItem hli,bool additionalIndices,
403-
const QCString &altSidebarName, int hierarchyLevel, bool showListOfAllMembers)
403+
const QCString &altSidebarName, int hierarchyLevel, const QCString &allMembersFile)
404404
{
405405
bool disableIndex = Config_getBool(DISABLE_INDEX);
406406
bool generateTreeView = Config_getBool(GENERATE_TREEVIEW);
@@ -416,7 +416,7 @@ void startFile(OutputList &ol,const QCString &name,const QCString &manName,
416416
{
417417
ol.endQuickIndices();
418418
}
419-
ol.writeSplitBar(!altSidebarName.isEmpty() ? altSidebarName : name, showListOfAllMembers);
419+
ol.writeSplitBar(!altSidebarName.isEmpty() ? altSidebarName : name, allMembersFile);
420420
if (quickLinksAfterSplitbar)
421421
{
422422
ol.writeQuickLinks(hli,name);
@@ -3201,7 +3201,7 @@ static void writeClassMemberIndexFiltered(OutputList &ol, ClassMemberHighlight::
32013201
writeQuickLinks();
32023202
}
32033203
ol.endQuickIndices();
3204-
ol.writeSplitBar(fileName,false);
3204+
ol.writeSplitBar(fileName,QCString());
32053205
if (quickLinksAfterSplitbar)
32063206
{
32073207
writeQuickLinks();
@@ -3387,7 +3387,7 @@ static void writeFileMemberIndexFiltered(OutputList &ol, FileMemberHighlight::En
33873387
writeQuickLinks();
33883388
}
33893389
ol.endQuickIndices();
3390-
ol.writeSplitBar(fileName,false);
3390+
ol.writeSplitBar(fileName,QCString());
33913391
if (quickLinksAfterSplitbar)
33923392
{
33933393
writeQuickLinks();
@@ -3571,7 +3571,7 @@ static void writeNamespaceMemberIndexFiltered(OutputList &ol,
35713571
writeQuickLinks();
35723572
}
35733573
ol.endQuickIndices();
3574-
ol.writeSplitBar(fileName,false);
3574+
ol.writeSplitBar(fileName,QCString());
35753575
if (quickLinksAfterSplitbar)
35763576
{
35773577
writeQuickLinks();
@@ -3748,7 +3748,7 @@ static void writeModuleMemberIndexFiltered(OutputList &ol,
37483748
writeQuickLinks();
37493749
}
37503750
ol.endQuickIndices();
3751-
ol.writeSplitBar(fileName,false);
3751+
ol.writeSplitBar(fileName,QCString());
37523752
if (quickLinksAfterSplitbar)
37533753
{
37543754
writeQuickLinks();
@@ -4863,7 +4863,7 @@ static void writeIndex(OutputList &ol)
48634863
ol.writeQuickLinks(HighlightedItem::Main,QCString());
48644864
}
48654865
ol.endQuickIndices();
4866-
ol.writeSplitBar(indexName,false);
4866+
ol.writeSplitBar(indexName,QCString());
48674867
if (quickLinksAfterSplitbar)
48684868
{
48694869
ol.writeQuickLinks(HighlightedItem::Main,QCString());
@@ -4936,7 +4936,7 @@ static void writeIndex(OutputList &ol)
49364936
ol.writeString("<a href=\"" + fn + "\"></a>\n");
49374937
Doxygen::indexList->addIndexFile(fn);
49384938

4939-
if (Doxygen::mainPage->localToc().isHtmlEnabled() && Doxygen::mainPage->hasSections() && generateTreeView)
4939+
if (Doxygen::mainPage && Doxygen::mainPage->localToc().isHtmlEnabled() && Doxygen::mainPage->hasSections() && generateTreeView)
49404940
{
49414941
ol.writeString("</div><!-- doc-content -->\n");
49424942
ol.endContents();

src/index.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,7 @@ void endTitle(OutputList &ol,const QCString &fileName,const QCString &name);
228228
void startFile(OutputList &ol,const QCString &name,const QCString &manName,
229229
const QCString &title,HighlightedItem hli=HighlightedItem::None,
230230
bool additionalIndices=false,const QCString &altSidebarName=QCString(), int hierarchyLevel=0,
231-
bool showListOfAllMembers=false);
231+
const QCString &allMembersFile=QCString());
232232
void endFile(OutputList &ol,bool skipNavIndex=FALSE,bool skipEndContents=FALSE,
233233
const QCString &navPath=QCString());
234234
void endFileWithNavPath(OutputList &ol,const DefinitionMutable *d,bool showPageNavigation=true);

src/latexgen.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ class LatexGenerator : public OutputGenerator, public OutputGenIntf
236236
void endPageRef(const QCString &,const QCString &) override;
237237
void startQuickIndices() override {}
238238
void endQuickIndices() override {}
239-
void writeSplitBar(const QCString &,bool) override {}
239+
void writeSplitBar(const QCString &,const QCString &) override {}
240240
void writeNavigationPath(const QCString &) override {}
241241
void writeLogo() override {}
242242
void writeQuickLinks(HighlightedItem,const QCString &,bool) override {}

src/mangen.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ class ManGenerator : public OutputGenerator, public OutputGenIntf
206206
void endPageRef(const QCString &,const QCString &) override {}
207207
void startQuickIndices() override {}
208208
void endQuickIndices() override {}
209-
void writeSplitBar(const QCString &,bool) override {}
209+
void writeSplitBar(const QCString &,const QCString &) override {}
210210
void writeNavigationPath(const QCString &) override {}
211211
void writeLogo() override {}
212212
void writeQuickLinks(HighlightedItem,const QCString &,bool) override {}

src/moduledef.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -966,7 +966,10 @@ void ModuleDefImpl::writeFiles(OutputList &ol,const QCString &title)
966966
if (fd)
967967
{
968968
ol.startMemberDeclaration();
969-
ol.startMemberItem(fd->anchor(),OutputGenerator::MemberItemType::Normal);
969+
QCString fname = fd->displayName();
970+
QCString anc = fd->anchor();
971+
if (anc.isEmpty()) anc=fname; else anc.prepend(fname+"_");
972+
ol.startMemberItem(anc,OutputGenerator::MemberItemType::Normal);
970973
ol.docify(theTranslator->trFile(FALSE,TRUE)+" ");
971974
ol.insertMemberAlign();
972975
QCString path=fd->getPath();
@@ -976,7 +979,7 @@ void ModuleDefImpl::writeFiles(OutputList &ol,const QCString &title)
976979
}
977980
if (fd->isLinkable())
978981
{
979-
ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(),QCString(),fd->displayName());
982+
ol.writeObjectLink(fd->getReference(),fd->getOutputFileBase(),QCString(),fname);
980983
}
981984
else
982985
{

0 commit comments

Comments
 (0)