57#define MAX_ITEMS_BEFORE_MULTIPAGE_INDEX 200
58#define MAX_ITEMS_BEFORE_QUICK_INDEX 30
60constexpr auto alphaSepar =
"<div class=\"alphasepar\"></div>";
64static void countFiles(
int &htmlFiles,
int &files);
142 return p->classIndexLetterUsed[
static_cast<int>(e)];
147 return p->fileIndexLetterUsed[
static_cast<int>(e)];
152 return p->namespaceIndexLetterUsed[
static_cast<int>(e)];
157 return p->moduleIndexLetterUsed[
static_cast<int>(e)];
162 p->documentedClassMembers[i]=0;
163 p->classIndexLetterUsed[i].clear();
168 p->documentedFileMembers[i]=0;
169 p->fileIndexLetterUsed[i].clear();
174 p->documentedNamespaceMembers[i]=0;
175 p->namespaceIndexLetterUsed[i].clear();
180 p->documentedModuleMembers[i]=0;
181 p->moduleIndexLetterUsed[i].clear();
186 auto it = map.find(letter);
189 it->second.push_back(md);
193 map.emplace(letter,std::vector<const MemberDef*>({md}));
199 p->documentedClassMembers[i]++;
205 p->documentedFileMembers[i]++;
211 p->documentedNamespaceMembers[i]++;
217 p->documentedModuleMembers[i]++;
226 for (
auto &[name,list] : map)
228 std::stable_sort(list.begin(),list.end(),
238 int result = dstricmp_sort(md1->name(),md2->name());
241 result = dstricmp_sort(md1->qualifiedName(),md2->qualifiedName());
248 for (
auto &idx : p->classIndexLetterUsed)
250 sortMemberIndexList(idx);
252 for (
auto &idx : p->fileIndexLetterUsed)
254 sortMemberIndexList(idx);
256 for (
auto &idx : p->namespaceIndexLetterUsed)
258 sortMemberIndexList(idx);
260 for (
auto &idx : p->moduleIndexLetterUsed)
262 sortMemberIndexList(idx);
353 ol.
writeString(
" <div id=\"navrow4\" class=\"tabs3\">\n");
357 ol.
writeString(
" <div id=\"navrow3\" class=\"tabs2\">\n");
369 bool hl,
bool ,
bool &first)
407 const DString &altSidebarName,
int hierarchyLevel,
const DString &allMembersFile)
412 bool quickLinksAfterSplitbar = !disableIndex && generateTreeView && fullSidebar;
413 ol.
startFile(name,isSource,manName,title,hierarchyLevel);
415 if (!disableIndex && !quickLinksAfterSplitbar)
419 if (!additionalIndices)
424 if (quickLinksAfterSplitbar)
440 if (generateTreeView)
457 if (generateTreeview)
467 endFile(ol,generateTreeview,
true,navPath);
476 bool isDir = md->
isEnumerate() && std::any_of(enumList.
begin(),enumList.
end(),[](
const auto &emd) { return emd->hasDocumentation(); });
479 bool lAddToIndex = addToIndex && !namespaceMemberInFileDocs;
500 for (
const auto &emd : enumList)
502 if (emd->hasDocumentation())
505 lAddToIndex = addToIndex && !namespaceMemberInFileDocs;
507 emd->qualifiedName() : emd->name();
508 if (emd->getOuterScope()==def ||
513 ename,emd->getReference(),emd->getOutputFileBase(),emd->anchor(),
false,lAddToIndex && emd->getGroupDef()==
nullptr);
533 bool addToIndex=
true,
bool preventSeparateIndex=
false,
538 for (
const auto &cd : def->getClasses())
540 if (cd->isLinkable()) numClasses++;
545 for (
const auto &cd : *concepts)
547 if (cd->isLinkable()) numConcepts++;
550 bool hasMembers = !def->getMemberLists().
empty() || !def->getMemberGroups().empty() || (numClasses>0) || (numConcepts>0);
552 def->getReference(),def->getOutputFileBase(),anchor,
553 hasMembers && !preventSeparateIndex,
558 if (hasMembers || numClasses>0 || numConcepts>0)
563 auto kind = lde->kind();
564 if (kind==LayoutDocEntry::MemberDef)
572 for (
const auto &md : *ml)
574 if (md->visibleInIndex())
582 else if (kind==LayoutDocEntry::NamespaceClasses ||
583 kind==LayoutDocEntry::FileClasses ||
584 kind==LayoutDocEntry::ClassNestedClasses ||
585 kind==LayoutDocEntry::ModuleClasses
588 for (
const auto &cd : def->getClasses())
590 if (cd->isLinkable() && (cd->partOfGroups().empty() || def->definitionType()==
Definition::TypeGroup))
594 addMembersToIndex(cd,LayoutDocManager::Class,cd->displayName(lde->kind()==LayoutDocEntry::FileClasses),cd->anchor(),
595 addToIndex && (isNestedClass || (cd->isSimple() && inlineSimpleStructs)),
596 preventSeparateIndex || cd->isEmbeddedInOuterScope());
600 else if ((kind==LayoutDocEntry::FileConcepts || kind==LayoutDocEntry::ModuleConcepts) && concepts)
602 for (
const auto &cd : *concepts)
604 if (cd->isLinkable() && (cd->partOfGroups().empty() || def->definitionType()==
Definition::TypeGroup))
607 cd->getReference(),cd->getOutputFileBase(),
DString(),
626 if (bcl.empty())
return;
628 for (
const auto &bcd : bcl)
655 bool hasChildren = visitedClasses.find(cd)==visitedClasses.end() &&
670 .setAutolinkSupport(
false));
711 visitedClasses.insert(cd);
744 for (
const auto &fd : dd->
getFiles())
746 bool genSourceFile =
false;
747 if (fd->visibleInIndex(genSourceFile))
757 for(
const auto &subdd : dd->
subDirs())
773 "maximum nesting level exceeded for directory {}: "
774 "check for possible recursive directory relation!",dd->
name());
783 bool tocExpand =
true;
784 bool isDir = !dd->
subDirs().empty() ||
810 .setAutolinkSupport(
false));
823 for(
const auto &subdd : dd->
subDirs())
833 for (
const auto &fd : dd->
getFiles())
840 bool genSourceFile =
false;
841 if (fd->visibleInIndex(genSourceFile))
845 else if (genSourceFile)
853 for (
const auto &fd : dd->
getFiles())
856 bool doc = fd->visibleInIndex(src);
861 reference = fd->getReference();
862 outputBase = fd->getOutputFileBase();
875 .setAutolinkSupport(
false));
878 if (ftv && (src || doc))
882 reference,outputBase,
891 if (tocExpand && addToIndex)
896 for (
const auto &fd : dd->
getFiles())
899 bool doc = fd->visibleInIndex(src);
903 !fd->isLinkableViaGroup(),
false,&fd->getConcepts());
909 fd->getSourceFileBase(),
DString(),
false,
true, fd);
945 for (
const auto &fd : *fn)
947 if (fd->getDirDef()==
nullptr)
950 bool doc = fd->visibleInIndex(src);
954 reference = fd->getReference();
955 outputBase = fd->getOutputFileBase();
960 reference, outputBase,
DString(),
961 false,
false,fd.get());
972 false, fd->displayName(),
DString(),
973 fd->getSourceFileBase(),
DString(),
false,
true, fd.get());
994 for (
const auto &cd : cl)
997 if (cd->getLanguage()==SrcLangExt::VHDL)
1005 else if (sliceOpt && cd->compoundType() != ct)
1016 if (cd->isVisibleInHierarchy())
1028 bool hasChildren = visitedClasses.find(cd.get())==visitedClasses.end() &&
1032 if (cd->isLinkable())
1043 .setSingleLine(
true)
1044 .setAutolinkSupport(
false));
1045 ol.
endIndexItem(cd->getReference(),cd->getOutputFileBase());
1046 if (cd->isReference())
1049 ol.
docify(
" [external]");
1054 if (cd->getLanguage()!=SrcLangExt::VHDL)
1061 ftv->
addContentsItem(hasChildren,cd->displayName(),cd->getReference(),cd->getOutputFileBase(),cd->anchor(),
false,
false,cd.get(),escapedName);
1078 if (cd->getLanguage()==SrcLangExt::VHDL && hasChildren)
1081 visitedClasses.insert(cd.get());
1083 else if (hasChildren)
1086 visitedClasses.insert(cd.get());
1125 for (
const auto &cd : cl)
1127 if (sliceOpt && cd->compoundType() != ct)
1133 if (cd->isVisibleInHierarchy())
1135 if (!cd->subClasses().empty())
1165 bool addToIndex = lne==
nullptr || lne->
visible();
1271 bool addToIndex = lne==
nullptr || lne->
visible();
1376 bool addToIndex = lne==
nullptr || lne->
visible();
1478 for (
const auto &fd: *fn)
1481 bool doc = fd->visibleInIndex(src);
1551 .setSingleLine(
true)
1552 .setLinkFromIndex(
true));
1583 if (dir->hasDocumentation())
1608 bool addToIndex = lne==
nullptr || lne->
visible();
1641 std::unordered_map<std::string,size_t> pathMap;
1642 std::vector<FilesInDir> outputFiles;
1647 for (
const auto &fd : *fn)
1650 if (path.
empty()) path=
"[external]";
1651 auto it = pathMap.
find(path.
str());
1652 if (it!=pathMap.end())
1654 outputFiles.at(it->second).files.push_back(fd.get());
1658 pathMap.emplace(path.
str(),outputFiles.size());
1659 outputFiles.emplace_back(path);
1660 outputFiles.back().files.push_back(fd.get());
1666 std::stable_sort(outputFiles.begin(),
1668 [](
const auto &fp1,
const auto &fp2) { return dstricmp_sort(fp1.path,fp2.path)<0; });
1670 for (
auto &fp : outputFiles)
1675 for (
const auto &fp : outputFiles)
1677 for (
const auto &fd : fp.files)
1687 for (
const auto &fd : *fn)
1730 if (nd->isLinkableInProject()) count++;
1741 if (cd->isLinkableInProject()) count++;
1752template<
class ListType>
1756 for (
const auto &cdi : cl)
1782 if (ccd->isLinkableInProject() && !ccd->isImplicitTemplateInstance())
1821 if (lde->kind()==LayoutDocEntry::MemberDef)
1829 for (
const auto &md : *ml)
1832 if (md->visibleInIndex())
1847 if (lde->kind()==LayoutDocEntry::MemberDecl)
1855 for (
const auto &md : *ml)
1858 if (md->visibleInIndex())
1872 bool rootOnly,
bool addToIndex);
1875 bool rootOnly,
bool addToIndex)
1882 bool hasChildren = hasNestedNamespace ||
1902 bool isDir = hasChildren || visibleMembers>0;
1903 if (isLinkable || isDir)
1912 if (addToIndex && isDir)
1926 if (addToIndex && isDir)
1935 bool rootOnly,
bool addToIndex)
1937 for (
const auto &nd : nsLinkedMap)
1939 if (nd->isVisibleInHierarchy())
1947 bool rootOnly,
bool addToIndex)
1949 for (
const auto &nd : nsLinkedMap)
1951 if (nd->isVisibleInHierarchy())
2036 for (
const auto &nd : nsLinkedMap)
2045 for (
const auto &nd : nsLinkedMap)
2060 bool addToIndex = lne==
nullptr || lne->
visible();
2080 if (nd->isLinkableInProject())
2089 if (nd->getLanguage()==SrcLangExt::VHDL)
2099 bool hasBrief = !nd->briefDescription().empty();
2107 nd->briefDescription(
true),
2109 .setSingleLine(
true)
2110 .setLinkFromIndex(
true));
2159 if (sliceOpt && cd->compoundType() != ct)
2163 if (cd->isLinkableInProject() && !cd->isImplicitTemplateInstance())
2165 if (!cd->isEmbeddedInOuterScope())
2187 if (cd->getLanguage()==SrcLangExt::VHDL &&
2200 if (sliceOpt && cd->compoundType() != ct)
2206 if (cd->isEmbeddedInOuterScope())
2212 if (cd->isLinkableInProject() && !cd->isImplicitTemplateInstance())
2215 if (cd->getLanguage()==SrcLangExt::VHDL)
2223 bool hasBrief = !cd->briefDescription().empty();
2231 cd->briefDescription(
true),
2233 .setSingleLine(
true)
2234 .setLinkFromIndex(
true));
2250 return (c<127 && c>31);
2255 if (startLetter.
empty())
return startLetter;
2256 const char *p = startLetter.
data();
2266 const char hex[]=
"0123456789abcdef";
2269 result+=hex[
static_cast<unsigned char>(c)>>4];
2270 result+=hex[
static_cast<unsigned char>(c)&0xf];
2292 if (sliceOpt && cd->compoundType() != ct)
2297 if (cd->isLinkableInProject() && !cd->isImplicitTemplateInstance())
2301 std::string letter =
getUTF8CharAt(cd->className().str(),index);
2302 if (!letter.empty())
2310 DString alphaLinks =
"<div class=\"qindex\">";
2312 for (
const auto &letter : indexLettersUsed)
2317 alphaLinks +=
"<a class=\"qindex\" href=\"#letter_" +
2321 alphaLinks +=
"</div>\n";
2324 std::map<std::string, std::vector<const ClassDef*> > classesByLetter;
2331 if (sliceOpt && cd->compoundType() != ct)
2336 if (cd->isLinkableInProject() && !cd->isImplicitTemplateInstance())
2338 DString className = cd->className();
2341 if (!letter.empty())
2344 auto it = classesByLetter.find(letter);
2345 if (it!=classesByLetter.end())
2347 it->second.push_back(cd.get());
2351 classesByLetter.emplace(letter, std::vector<const ClassDef*>({ cd.get() }));
2358 for (
auto &[letter,list] : classesByLetter)
2360 std::stable_sort(list.begin(), list.end(),
2361 [](
const auto &c1,
const auto &c2)
2363 DString n1 = c1->className();
2364 DString n2 = c2->className();
2365 return dstricmp_sort(n1.data()+getPrefixIndex(n1), n2.data()+getPrefixIndex(n2))<0;
2370 if (!classesByLetter.empty())
2374 for (
const auto &cl : classesByLetter)
2376 DString parity = (counter++%2)==0 ?
"even" :
"odd";
2377 ol.
writeString(
"<dl class=\"classindex " + parity +
"\">\n");
2392 for (
const auto &cd : cl.second)
2411 cd->getOutputFileBase(),cd->anchor(),cname);
2412 if (!namesp.
empty())
2445 bool addToIndex = lne==
nullptr || lne->
visible();
2474 bool addToIndex = lne==
nullptr || lne->
visible();
2503 bool addToIndex = lne==
nullptr || lne->
visible();
2532 bool addToIndex = lne==
nullptr || lne->
visible();
2594 bool addToIndex = lne==
nullptr || lne->
visible();
2658 LayoutNavEntry::ClassList,LayoutNavEntry::Classes,
2672 LayoutNavEntry::InterfaceList,LayoutNavEntry::Interfaces,
2675 "annotatedinterfaces",
2686 LayoutNavEntry::StructList,LayoutNavEntry::Structs,
2700 LayoutNavEntry::ExceptionList,LayoutNavEntry::Exceptions,
2703 "annotatedexceptions",
2725 if (fd && prevFileName!=fd->
name())
2730 prevFileName = fd->
name();
2766 int index =
static_cast<int>(type);
2767 const int numIndices = 4;
2768 ASSERT(index<numIndices);
2774 static writeLinkForMember_t writeLinkForMemberMap[numIndices] =
2784 bool firstSection=
true;
2785 bool firstItem=
true;
2788 for (
const auto &kv : memberIndexMap)
2792 auto it = memberIndexMap.find(page);
2793 if (it != memberIndexMap.end())
2804 if (mil==
nullptr || mil->empty())
continue;
2805 for (
const auto &md : *mil)
2807 const char *sep =
nullptr;
2808 bool isFunc=!md->isObjCMethod() &&
2809 (md->isFunction() || md->isSlot() || md->isSignal());
2812 if (name.
data()+startIndex!=prevName)
2814 if ((prevName.
empty() ||
2815 tolower(name.
at(startIndex))!=tolower(prevName.
at(0))) &&
2822 DString title =
"- "+letter+
" -";
2830 else if (!useSections && first)
2841 if (isFunc) ol.
docify(
"()");
2846 sep =
" : ";
2847 prevName = name.
data()+startIndex;
2854 if (index<numIndices)
2857 writeLinkForMemberMap[index](ol,md,sep,prevDefName);
2873 bool hideFriendCompounds =
Config_getBool(HIDE_FRIEND_COMPOUNDS);
2883 if (!letter.empty())
2887 if (!(md->
isFriend() && isFriendToHide) &&
2922 (md->
isFriend() && !isFriendToHide))
2939 if (!letter.empty())
2987 if (!letter.empty())
3039 if (!letter.empty())
3074 DString fullName,
bool multiPage)
3078 for (
const auto &[letter,list] : map)
3087 anchor=fullName+extension+
"#index_";
3089 anchor=fullName+
"_"+is+extension+
"#index_";
3097<script type="text/javascript">
3098function updateNavHighlight() {
3099 var currentHash = window.location.hash;
3100 var navItems = document.querySelectorAll('#navrow4 .tablist li');
3102 for (var i = 0; i < navItems.length; i++) {
3103 var item = navItems[i];
3104 var link = item.querySelector('a');
3105 item.classList.remove('current');
3106 if (link && link.getAttribute('href') === currentHash) {
3107 item.classList.add('current');
3112 var target = document.querySelector(currentHash);
3114 target.scrollIntoView();
3118updateNavHighlight();
3119window.addEventListener('hashchange', updateNavHighlight);
3129 DString alphaLinks =
"<div class=\"qindex\">";
3131 for (
const auto &[letter,list] : map)
3135 for (
const auto &[letterUC,letter] : usedLetters)
3144 anchor=fullName+extension+
"#index_";
3146 anchor=fullName+
"_"+is+extension+
"#index_";
3151 alphaLinks +=
"<a class=\"qindex\" href=\"" + anchor +
3155 alphaLinks +=
"</div>\n";
3188 return &cmhlInfo[hl];
3194 if (index.numDocumentedClassMembers(hl)==0)
return;
3200 bool quickLinksAfterSplitbar = !disableIndex && generateTreeView && fullSidebar;
3202 bool multiPageIndex=
false;
3205 multiPageIndex=
true;
3215 bool addToIndex = lne==
nullptr || lne->
visible();
3225 for (
const auto &[letter,list] : index.isClassIndexLetterUsed(hl))
3243 auto writeQuickLinks = [&,cap_letter=letter]()
3284 if (!disableIndex && !quickLinksAfterSplitbar)
3290 if (quickLinksAfterSplitbar)
3306 if (dynamicMenus || disableIndex)
3312 multiPageIndex ? letter : std::string(),
3313 index.isClassIndexLetterUsed(hl),
3328 bool addToIndex = lne==
nullptr || lne->
visible();
3381 return &fmhlInfo[hl];
3387 if (index.numDocumentedFileMembers(hl)==0)
return;
3393 bool quickLinksAfterSplitbar = !disableIndex && generateTreeView && fullSidebar;
3395 bool multiPageIndex=
false;
3398 multiPageIndex=
true;
3407 bool addToIndex = lne==
nullptr || lne->
visible();
3417 for (
const auto &[letter,list] : index.isFileIndexLetterUsed(hl))
3435 auto writeQuickLinks = [&,cap_letter=letter]()
3474 if (!disableIndex && !quickLinksAfterSplitbar)
3480 if (quickLinksAfterSplitbar)
3496 if (dynamicMenus || disableIndex)
3502 multiPageIndex ? letter : std::string(),
3503 index.isFileIndexLetterUsed(hl),
3566 return &nmhlInfo[hl];
3575 if (index.numDocumentedNamespaceMembers(hl)==0)
return;
3581 bool quickLinksAfterSplitbar = !disableIndex && generateTreeView && fullSidebar;
3583 bool multiPageIndex=
false;
3586 multiPageIndex=
true;
3595 bool addToIndex = lne==
nullptr || lne->
visible();
3605 for (
const auto &[letter,list] : index.isNamespaceIndexLetterUsed(hl))
3623 auto writeQuickLinks = [&,cap_letter=letter]()
3662 if (!disableIndex && !quickLinksAfterSplitbar)
3668 if (quickLinksAfterSplitbar)
3686 multiPageIndex ? letter : std::string(),
3687 index.isNamespaceIndexLetterUsed(hl),
3743 return &nmhlInfo[hl];
3752 if (index.numDocumentedModuleMembers(hl)==0)
return;
3758 bool quickLinksAfterSplitbar = !disableIndex && generateTreeView && fullSidebar;
3760 bool multiPageIndex=
false;
3763 multiPageIndex=
true;
3772 bool addToIndex = lne==
nullptr || lne->
visible();
3782 for (
const auto &[letter,list] : index.isModuleIndexLetterUsed(hl))
3800 auto writeQuickLinks = [&,cap_letter=letter]()
3839 if (!disableIndex && !quickLinksAfterSplitbar)
3845 if (quickLinksAfterSplitbar)
3861 if (dynamicMenus || disableIndex)
3867 multiPageIndex ? letter : std::string(),
3868 index.isModuleIndexLetterUsed(hl),
3884 bool addToIndex = lne==
nullptr || lne->
visible();
3913 bool addToIndex = lne==
nullptr || lne->
visible();
3937 DString n=pd->getOutputFileBase();
3938 if (!pd->title().empty())
3972 docPages=indexPages=0;
3975 if (pd->visibleInIndex() && !pd->hasParentPage())
3979 if (pd->documentedPage())
3992 bool addToIndex = lne==
nullptr || lne->
visible();
3993 if (!addToIndex)
return;
4000 DString pageTitle, pageTitleAsHtml;
4003 pageTitle=pd->
name();
4012 hasSubPages,pageTitle,
4014 DString(),hasSubPages,
true,pd,pageTitleAsHtml);
4019 hasSubPages || hasSections,pageTitle,
4021 DString(),hasSubPages,
true,pd,pageTitleAsHtml);
4025 bool doIndent = (hasSections || hasSubPages) && !reuseRoot;
4095 if (!gd->isReference())
4111 if (dd->isLinkableInProject())
4131 bool oldStripCommentsState =
Config_getBool(STRIP_CODE_COMMENTS);
4144 size_t s = legendDocs.
find(
"<center>");
4145 size_t e = legendDocs.
find(
"</center>");
4149 legendDocs = legendDocs.
left(s+8) +
"[!-- SVG 0 --]" + legendDocs.
mid(e);
4179 "maximum nesting level exceeded for group {}: check for possible recursive group relation!",gd->
name());
4192 size_t numSubItems = 0;
4195 if (ml->listType().isDocumentation())
4197 numSubItems += ml->size();
4202 numSubItems += gd->
getFiles().size();
4204 numSubItems += gd->
getDirs().size();
4207 bool isDir = hasSubGroups || hasSubPages || numSubItems>0;
4216 isDir,
true,
nullptr,titleAsHtml);
4223 false,
false,gd,titleAsHtml);
4235 .setSingleLine(
true)
4236 .setAutolinkSupport(
false));
4242 ol.
docify(
" [external]");
4248 if (lde->kind()==LayoutDocEntry::MemberDef && addToIndex)
4256 for (
const auto &md : *ml)
4259 isDir = !enumList.
empty() && md->isEnumerate();
4260 if (md->isVisible() && !md->isAnonymous())
4263 md->qualifiedName(),md->getReference(),
4264 md->getOutputFileBase(),md->anchor(),
false,addToIndex);
4269 for (
const auto &emd : enumList)
4271 if (emd->isVisible())
4274 emd->qualifiedName(),emd->getReference(),emd->getOutputFileBase(),
4275 emd->anchor(),
false,addToIndex);
4284 else if (lde->kind()==LayoutDocEntry::GroupClasses && addToIndex)
4292 if (cd->isVisible() )
4295 LayoutDocManager::Class,
4303 else if (lde->kind()==LayoutDocEntry::GroupNamespaces && addToIndex &&
Config_getBool(SHOW_NAMESPACES))
4307 if (nd->isVisible())
4310 nd->displayName(),nd->getReference(),
4315 else if (lde->kind()==LayoutDocEntry::GroupConcepts && addToIndex)
4319 if (cd->isVisible())
4322 cd->displayName(),cd->getReference(),
4323 cd->getOutputFileBase(),
DString(),
false,addToIndex);
4327 else if (lde->kind()==LayoutDocEntry::GroupFiles && addToIndex)
4329 for (
const auto &fd : gd->
getFiles())
4331 if (fd->isVisible())
4334 fd->displayName(),fd->getReference(),
4335 fd->getOutputFileBase(),
DString(),
false,fd->isLinkableViaGroup());
4339 else if (lde->kind()==LayoutDocEntry::GroupDirs && addToIndex)
4341 for (
const auto &dd : gd->
getDirs())
4343 if (dd->isVisible())
4346 dd->shortName(),dd->getReference(),
4347 dd->getOutputFileBase(),
DString(),
false,
false);
4351 else if (lde->kind()==LayoutDocEntry::GroupPageDocs && addToIndex)
4353 for (
const auto &pd : gd->
getPages())
4361 pageTitle=pd->
name();
4366 hasSubPages || hasSections,
4371 hasSubPages || hasSections,
4375 if (hasSections || hasSubPages)
4384 if (hasSections || hasSubPages)
4390 else if (lde->kind()==LayoutDocEntry::GroupNestedGroups)
4451 bool addToIndex = lne==
nullptr || lne->
visible();
4512 FTVHelp* ftv,
bool addToIndex)
4515 bool isDir=visibleMembers>0;
4535 .setSingleLine(
true)
4536 .setAutolinkSupport(
false));
4541 ol.
docify(
" [external]");
4544 if (addToIndex && isDir)
4556 if (addToIndex && isDir)
4600 bool addToIndex = lne==
nullptr || lne->
visible();
4659 for (
const auto &cd : concepts)
4661 if (cd->isLinkableInProject())
4666 cd->getOutputFileBase(),
DString(),
false,cd->partOfGroups().
empty(),cd);
4671 cd->getOutputFileBase(),
DString(),
false,cd->partOfGroups().
empty());
4678 bool rootOnly,
bool addToIndex);
4681 bool rootOnly,
bool addToIndex)
4683 for (
const auto &nd : nsLinkedMap)
4691 bool rootOnly,
bool addToIndex)
4745 if ((cd->getOuterScope()==
nullptr ||
4751 false,cd->localName(),cd->getReference(),cd->getOutputFileBase(),
4756 false,cd->localName(),cd->getReference(),cd->getOutputFileBase(),
4772 bool addToIndex = lne==
nullptr || lne->
visible();
4793 if (cd->isLinkableInProject())
4805 bool hasBrief = !cd->briefDescription().empty();
4813 cd->briefDescription(
true),
4815 .setSingleLine(
true)
4816 .setLinkFromIndex(
true));
4878 if (entry->visible()) count++;
4883 for (
const auto &entry: lne->
children())
4885 if (entry->visible())
4887 ol.
writeString(
"<li><a href=\""+entry->url()+
"\"><span>"+
4914 if (!projectName.
empty())
4916 projPrefix=projectName+
" ";
4968 bool quickLinksAfterSplitbar = !disableIndex && generateTreeView && fullSidebar;
4970 if (!disableIndex && !quickLinksAfterSplitbar)
4976 if (quickLinksAfterSplitbar)
4981 bool headerWritten=
false;
5006 .setSingleLine(
true));
5007 headerWritten =
true;
5012 if (!projectName.
empty())
5017 headerWritten =
true;
5046 .setIndexWords(
true));
5085 msg(
"Generating main page...\n");
5094 if (projPrefix.
empty())
5128 if (index.numDocumentedPages()>0)
5143 if (index.numDocumentedModules()>0)
5149 if (index.numDocumentedGroups()>0)
5155 if (index.numDocumentedDirs()>0)
5161 if (
Config_getBool(SHOW_NAMESPACES) && (index.numDocumentedNamespaces()>0))
5171 if (index.numDocumentedConcepts()>0)
5177 if (index.numHierarchyInterfaces()>0)
5183 if (index.numHierarchyClasses()>0)
5197 if (index.numHierarchyExceptions()>0)
5203 if (index.numAnnotatedInterfacesPrinted()>0)
5209 if (index.numAnnotatedClassesPrinted()>0)
5219 if (index.numAnnotatedStructsPrinted()>0)
5225 if (index.numAnnotatedExceptionsPrinted()>0)
5240 if (index.numDocumentedModules()>0)
5246 if (index.numDocumentedGroups()>0)
5252 if (index.numDocumentedDirs()>0)
5258 if (index.numDocumentedNamespaces()>0)
5264 if (index.numDocumentedConcepts()>0)
5270 if (index.numAnnotatedInterfacesPrinted()>0)
5276 if (index.numAnnotatedClassesPrinted()>0)
5282 if (index.numAnnotatedStructsPrinted()>0)
5288 if (index.numAnnotatedExceptionsPrinted()>0)
5316 auto isRef = [](
const DString &s)
5318 return s.startsWith(
"@ref") || s.startsWith(
"\\ref");
5322 for (
const auto &lne : entries)
5325 size_t idx =
static_cast<size_t>(kind);
5329 size_t newSize = idx+1;
5331 for (
size_t i=oldSize; i<newSize; i++)
indexWritten.at(i)=
false;
5334 bool addToIndex=lne->
visible();
5335 bool needsClosing=
false;
5340 case LayoutNavEntry::MainPage:
5341 msg(
"Generating index page...\n");
5344 case LayoutNavEntry::Pages:
5345 msg(
"Generating page index...\n");
5348 case LayoutNavEntry::Topics:
5349 msg(
"Generating topic index...\n");
5352 case LayoutNavEntry::Modules:
5354 if (index.numDocumentedModules()>0 && addToIndex)
5362 case LayoutNavEntry::ModuleList:
5363 msg(
"Generating module index...\n");
5366 case LayoutNavEntry::ModuleMembers:
5367 msg(
"Generating module member index...\n");
5370 case LayoutNavEntry::Namespaces:
5375 if (index.numDocumentedNamespaces()>0 && addToIndex)
5383 msg(
"Generating namespace index...\n");
5389 case LayoutNavEntry::NamespaceList:
5394 msg(
"Generating namespace index...\n");
5399 case LayoutNavEntry::NamespaceMembers:
5400 msg(
"Generating namespace member index...\n");
5403 case LayoutNavEntry::Classes:
5404 if (index.numAnnotatedClasses()>0 && addToIndex)
5412 msg(
"Generating annotated compound index...\n");
5416 case LayoutNavEntry::Concepts:
5417 msg(
"Generating concept index...\n");
5420 case LayoutNavEntry::ClassList:
5421 msg(
"Generating annotated compound index...\n");
5424 case LayoutNavEntry::ClassIndex:
5425 msg(
"Generating alphabetical compound index...\n");
5428 case LayoutNavEntry::ClassHierarchy:
5429 msg(
"Generating hierarchical class index...\n");
5433 msg(
"Generating graphical class hierarchy...\n");
5437 case LayoutNavEntry::ClassMembers:
5440 msg(
"Generating member index...\n");
5444 case LayoutNavEntry::Interfaces:
5445 if (sliceOpt && index.numAnnotatedInterfaces()>0 && addToIndex)
5452 case LayoutNavEntry::InterfaceList:
5455 msg(
"Generating annotated interface index...\n");
5459 case LayoutNavEntry::InterfaceIndex:
5462 msg(
"Generating alphabetical interface index...\n");
5466 case LayoutNavEntry::InterfaceHierarchy:
5469 msg(
"Generating hierarchical interface index...\n");
5473 msg(
"Generating graphical interface hierarchy...\n");
5478 case LayoutNavEntry::Structs:
5479 if (sliceOpt && index.numAnnotatedStructs()>0 && addToIndex)
5486 case LayoutNavEntry::StructList:
5489 msg(
"Generating annotated struct index...\n");
5493 case LayoutNavEntry::StructIndex:
5496 msg(
"Generating alphabetical struct index...\n");
5500 case LayoutNavEntry::Exceptions:
5501 if (sliceOpt && index.numAnnotatedExceptions()>0 && addToIndex)
5508 case LayoutNavEntry::ExceptionList:
5511 msg(
"Generating annotated exception index...\n");
5515 case LayoutNavEntry::ExceptionIndex:
5518 msg(
"Generating alphabetical exception index...\n");
5522 case LayoutNavEntry::ExceptionHierarchy:
5525 msg(
"Generating hierarchical exception index...\n");
5529 msg(
"Generating graphical exception hierarchy...\n");
5534 case LayoutNavEntry::Files:
5536 if (
Config_getBool(SHOW_FILES) && index.numDocumentedFiles()>0 && addToIndex)
5544 msg(
"Generating file index...\n");
5549 case LayoutNavEntry::FileList:
5550 msg(
"Generating file index...\n");
5553 case LayoutNavEntry::FileGlobals:
5554 msg(
"Generating file member index...\n");
5557 case LayoutNavEntry::Examples:
5558 msg(
"Generating example index...\n");
5561 case LayoutNavEntry::User:
5566 bool isRelative=url.
at(0)==
'!';
5567 if (!url.
empty() && !isRelative)
5575 case LayoutNavEntry::UserGroup:
5587 bool isRelative=url.
at(0)==
'!';
5605 case LayoutNavEntry::None:
5606 ASSERT(kind != LayoutNavEntry::None);
5609 if (kind!=LayoutNavEntry::User && kind!=LayoutNavEntry::UserGroup)
5619 case LayoutNavEntry::Modules:
5620 case LayoutNavEntry::Namespaces:
5621 case LayoutNavEntry::Classes:
5622 case LayoutNavEntry::Files:
5623 case LayoutNavEntry::UserGroup:
5645 case LayoutNavEntry::MainPage:
return true;
5646 case LayoutNavEntry::User:
return true;
5647 case LayoutNavEntry::UserGroup:
return true;
5648 case LayoutNavEntry::Pages:
return index.numIndexedPages()>0;
5649 case LayoutNavEntry::Topics:
return index.numDocumentedGroups()>0;
5650 case LayoutNavEntry::Modules:
return index.numDocumentedModules()>0;
5651 case LayoutNavEntry::ModuleList:
return index.numDocumentedModules()>0;
5653 case LayoutNavEntry::Namespaces:
return index.numDocumentedNamespaces()>0 && showNamespaces;
5654 case LayoutNavEntry::NamespaceList:
return index.numDocumentedNamespaces()>0 && showNamespaces;
5656 case LayoutNavEntry::Concepts:
return index.numDocumentedConcepts()>0;
5657 case LayoutNavEntry::Classes:
return index.numAnnotatedClasses()>0;
5658 case LayoutNavEntry::ClassList:
return index.numAnnotatedClasses()>0;
5659 case LayoutNavEntry::ClassIndex:
return index.numAnnotatedClasses()>0;
5660 case LayoutNavEntry::ClassHierarchy:
return index.numHierarchyClasses()>0;
5662 case LayoutNavEntry::Interfaces:
return index.numAnnotatedInterfaces()>0;
5663 case LayoutNavEntry::InterfaceList:
return index.numAnnotatedInterfaces()>0;
5664 case LayoutNavEntry::InterfaceIndex:
return index.numAnnotatedInterfaces()>0;
5665 case LayoutNavEntry::InterfaceHierarchy:
return index.numHierarchyInterfaces()>0;
5666 case LayoutNavEntry::Structs:
return index.numAnnotatedStructs()>0;
5667 case LayoutNavEntry::StructList:
return index.numAnnotatedStructs()>0;
5668 case LayoutNavEntry::StructIndex:
return index.numAnnotatedStructs()>0;
5669 case LayoutNavEntry::Exceptions:
return index.numAnnotatedExceptions()>0;
5670 case LayoutNavEntry::ExceptionList:
return index.numAnnotatedExceptions()>0;
5671 case LayoutNavEntry::ExceptionIndex:
return index.numAnnotatedExceptions()>0;
5672 case LayoutNavEntry::ExceptionHierarchy:
return index.numHierarchyExceptions()>0;
5673 case LayoutNavEntry::Files:
return index.numDocumentedFiles()>0 && showFiles;
5674 case LayoutNavEntry::FileList:
return index.numDocumentedFiles()>0 && showFiles;
5677 case LayoutNavEntry::None:
5678 ASSERT(kind != LayoutNavEntry::None);
5686 std::function<std::size_t(std::size_t)> numDocumented,
5688 const T *(*getInfo)(
size_t hl),
5692 bool firstMember=
true;
5693 for (std::size_t i=0;i<total;i++)
5695 if (numDocumented(i)>0)
5711 bool multiPageIndex=
false;
5714 multiPageIndex=
true;
5716 t <<
",children:[\n";
5717 bool firstLetter=
true;
5718 for (
const auto &[letter,list] : getMemberList(i))
5720 if (!firstLetter) t <<
",\n";
5725 DString fullName = getInfo(i)->fname;
5726 if (!multiPageIndex || firstLetter)
5727 anchor=fullName+extension+
"#index_";
5729 anchor=fullName+
"_"+is+extension+
"#index_";
5748 for (
const auto &entry : root->
children())
5754 bool firstChild =
true;
5755 if (!first) t <<
",";
5756 t <<
"children:[\n";
5757 for (
const auto &entry : root->
children())
5761 if (!firstChild) t <<
",\n";
5764 if (
isURL(url)) url =
"^" + url;
5767 bool hasChildren=
false;
5768 if (entry->kind()==LayoutNavEntry::ModuleMembers)
5770 auto numDoc = [](std::size_t i) {
5773 auto memList = [](std::size_t i) {
5778 if (entry->kind()==LayoutNavEntry::NamespaceMembers)
5780 auto numDoc = [](std::size_t i) {
5783 auto memList = [](std::size_t i) {
5788 else if (entry->kind()==LayoutNavEntry::ClassMembers)
5790 auto numDoc = [](std::size_t i) {
5793 auto memList = [](std::size_t i) {
5798 else if (entry->kind()==LayoutNavEntry::FileGlobals)
5800 auto numDoc = [](std::size_t i) {
5803 auto memList = [](std::size_t i) {
5812 if (hasChildren) t <<
"]";
5829 t <<
"var menudata={";
5831 if (hasChildren) t <<
"]";
A abstract class representing of a compound symbol.
virtual bool isVisibleInHierarchy() const =0
the class is visible in a class diagram, or class hierarchy
virtual const BaseClassList & baseClasses() const =0
Returns the list of base classes from which this class directly inherits.
virtual bool isSimple() const =0
virtual Protection protection() const =0
Return the protection level (Public,Protected,Private) in which this compound was found.
virtual bool isImplicitTemplateInstance() const =0
CompoundType
The various compound types.
virtual CompoundType compoundType() const =0
Returns the type of compound this is, i.e. class/struct/union/...
virtual ClassLinkedRefMap getClasses() const =0
returns the classes nested into this class
virtual const BaseClassList & subClasses() const =0
Returns the list of sub classes that directly derive from this class.
static const DString crawlFileName
A String class for use with Doxygen wrapping std::string and adding some additional functionality off...
DString mid(size_t index, size_t len=npos) const
bool empty() const
Returns true iff the string is empty (std::string compatible alias for isEmpty()).
DString & replace(size_t index, size_t len, const char *s)
static constexpr size_t npos
value used to indicate 'not found' or 'to the end of the string', matching std::string::npos
char & at(size_t i)
Returns a reference to the character at index i.
DString & prepend(const char *s)
size_t find(char c, size_t pos=0) const
DString left(size_t len) const
const std::string & str() const
const char * data() const
Returns a pointer to the contents of the string in the form of a 0-terminated C string.
bool startsWith(const char *s) const
size_t length() const
Returns the length of the string, not counting the 0-terminator.
The common base class of all entity definitions found in the sources.
virtual DString briefDescription(bool abbreviate=false) const =0
virtual bool isVisible() const =0
virtual DString briefFile() const =0
virtual SrcLangExt getLanguage() const =0
Returns the programming language this definition was written in.
virtual bool hasSections() const =0
virtual DString getDefFileName() const =0
virtual bool isLinkable() const =0
virtual int getDefLine() const =0
virtual DefType definitionType() const =0
virtual const DString & name() const =0
virtual const DString & localName() const =0
virtual int briefLine() const =0
virtual bool hasDocumentation() const =0
virtual bool isLinkableInProject() const =0
virtual bool isAnonymous() const =0
virtual DString navigationPathAsString() const =0
virtual DString displayName(bool includeScope=true) const =0
virtual DString qualifiedName() const =0
virtual DString anchor() const =0
virtual DString getReference() const =0
virtual const GroupList & partOfGroups() const =0
virtual Definition * getOuterScope() const =0
virtual DString getSourceFileBase() const =0
virtual bool isReference() const =0
virtual DString getOutputFileBase() const =0
virtual void writePageNavigation(OutputList &) const =0
virtual void writeSummaryLinks(OutputList &) const =0
A model of a directory symbol.
virtual const DString shortName() const =0
virtual const DirList & subDirs() const =0
virtual const FileList & getFiles() const =0
Represents a graphical class hierarchy.
Representation of a legend explaining the meaning of boxes, arrows, and colors.
void writeGraph(const DString &path)
static NamespaceLinkedMap * namespaceLinkedMap
static ConceptLinkedMap * conceptLinkedMap
static std::unique_ptr< PageDef > mainPage
static FileNameLinkedMap * inputNameLinkedMap
static ClassLinkedMap * classLinkedMap
static PageLinkedMap * exampleLinkedMap
static NamespaceDefMutable * globalScope
static IndexList * indexList
static ClassLinkedMap * hiddenClassLinkedMap
static PageLinkedMap * pageLinkedMap
static DString htmlFileExtension
static DirLinkedMap * dirLinkedMap
static GroupLinkedMap * groupLinkedMap
A class that generates a dynamic tree view side panel.
void addContentsItem(bool isDir, const DString &name, const DString &ref, const DString &file, const DString &anchor, bool separateIndex, bool addToNavIndex, const Definition *def, const DString &nameAsHtml=DString())
void generateTreeViewInline(TextStream &t)
A model of a file symbol.
virtual DString getPath() const =0
virtual DString includeName() const =0
virtual bool generateSourceFile() const =0
virtual bool isDocumentationFile() const =0
A model of a group of symbols.
virtual DString groupTitle() const =0
virtual const DirList & getDirs() const =0
virtual const GroupList & getSubGroups() const =0
virtual const FileList & getFiles() const =0
virtual const MemberLists & getMemberLists() const =0
virtual const ConceptLinkedRefMap & getConcepts() const =0
virtual const PageLinkedRefMap & getPages() const =0
virtual const NamespaceLinkedRefMap & getNamespaces() const =0
virtual bool isASubGroup() const =0
virtual bool isVisibleInHierarchy() const =0
virtual const ClassLinkedRefMap & getClasses() const =0
virtual MemberList * getMemberList(MemberListType lt) const =0
static DString fixSpaces(const DString &s)
void incrementDocumentedNamespaceMembers(int i, const std::string &letter, const MemberDef *md)
int numAnnotatedInterfacesPrinted() const
void addClassMemberNameToIndex(const MemberDef *md)
std::vector< const MemberDef * > MemberIndexList
void resetDocumentedNamespaceMembers(int i)
int numDocumentedFiles() const
int numDocumentedNamespaces() const
int numIndexedPages() const
int numAnnotatedClassesPrinted() const
int numDocumentedGroups() const
void resetDocumentedModuleMembers(int i)
int numDocumentedModules() const
void incrementDocumentedFileMembers(int i, const std::string &letter, const MemberDef *md)
int numAnnotatedStructs() const
int numDocumentedConcepts() const
void addNamespaceMemberNameToIndex(const MemberDef *md)
void resetDocumentedClassMembers(int i)
int numAnnotatedStructsPrinted() const
void incrementDocumentedClassMembers(int i, const std::string &letter, const MemberDef *md)
MemberIndexMap isClassIndexLetterUsed(ClassMemberHighlight::Enum e) const
void addFileMemberNameToIndex(const MemberDef *md)
void incrementDocumentedModuleMembers(int i, const std::string &letter, const MemberDef *md)
int numHierarchyInterfaces() const
int numDocumentedClassMembers(ClassMemberHighlight::Enum e) const
int numDocumentedModuleMembers(ModuleMemberHighlight::Enum e) const
void addModuleMemberNameToIndex(const MemberDef *md)
int numDocumentedNamespaceMembers(NamespaceMemberHighlight::Enum e) const
int numDocumentedPages() const
int numHierarchyExceptions() const
int numAnnotatedExceptionsPrinted() const
int numDocumentedFileMembers(FileMemberHighlight::Enum e) const
int numAnnotatedExceptions() const
MemberIndexMap isFileIndexLetterUsed(FileMemberHighlight::Enum e) const
void sortMemberIndexLists()
std::map< std::string, MemberIndexList > MemberIndexMap
static Index & instance()
void countDataStructures()
int numHierarchyClasses() const
MemberIndexMap isModuleIndexLetterUsed(ModuleMemberHighlight::Enum e) const
void resetDocumentedFileMembers(int i)
int numDocumentedDirs() const
int numAnnotatedInterfaces() const
std::unique_ptr< Private > p
int numAnnotatedClasses() const
MemberIndexMap isNamespaceIndexLetterUsed(NamespaceMemberHighlight::Enum e) const
void addIndexFile(const DString &name)
void addContentsItem(bool isDir, const DString &name, const DString &ref, const DString &file, const DString &anchor, bool separateIndex=false, bool addToNavIndex=false, const Definition *def=nullptr, const DString &nameAsHtml=DString())
void enable()
enable the indices
void disable()
disable the indices
static LayoutDocManager & instance()
Returns a reference to this singleton.
LayoutNavEntry * rootNavEntry() const
returns the (invisible) root of the navigation tree.
std::unique_ptr< ClassDef > Ptr
const T * find(const std::string &key) const
A model of a class/file/namespace member symbol.
virtual bool isSignal() const =0
virtual bool isFriend() const =0
virtual bool isForeign() const =0
virtual bool isRelated() const =0
virtual bool isSequence() const =0
virtual const ClassDef * getClassDef() const =0
virtual GroupDef * getGroupDef()=0
virtual bool isTypedef() const =0
virtual bool isSlot() const =0
virtual const MemberVector & enumFieldList() const =0
virtual const FileDef * getFileDef() const =0
virtual bool isEvent() const =0
virtual bool isFunction() const =0
virtual bool isDictionary() const =0
virtual const ModuleDef * getModuleDef() const =0
virtual bool isDefine() const =0
virtual const NamespaceDef * getNamespaceDef() const =0
virtual bool isEnumerate() const =0
virtual bool isVariable() const =0
virtual bool isStrong() const =0
virtual DString typeString() const =0
virtual const MemberDef * getEnumScope() const =0
virtual bool isEnumValue() const =0
virtual bool isProperty() const =0
A list of MemberDef objects as shown in documentation sections.
A vector of MemberDef object.
bool empty() const noexcept
iterator begin() noexcept
virtual MemberList * getMemberList(MemberListType lt) const =0
virtual int countVisibleMembers() const =0
virtual bool isPrimaryInterface() const =0
virtual const ConceptLinkedRefMap & getConcepts() const =0
virtual const ClassLinkedRefMap & getClasses() const =0
int numDocumentedModules() const
static ModuleManager & instance()
An abstract interface of a namespace symbol.
virtual MemberList * getMemberList(MemberListType lt) const =0
virtual ConceptLinkedRefMap getConcepts() const =0
virtual ClassLinkedRefMap getStructs() const =0
virtual ClassLinkedRefMap getExceptions() const =0
virtual NamespaceLinkedRefMap getNamespaces() const =0
virtual int countVisibleMembers() const =0
virtual ClassLinkedRefMap getClasses() const =0
virtual ClassLinkedRefMap getInterfaces() const =0
Class representing a list of output generators that are written to in parallel.
void writeFooter(const DString &navPath)
void startTitleHead(const DString &fileName)
void parseText(const DString &textStr)
void endTitleHead(const DString &fileName, const DString &name)
void disable(OutputType o)
void startParagraph(const DString &classDef=DString())
void writeObjectLink(const DString &ref, const DString &file, const DString &anchor, const DString &name)
void enable(OutputType o)
void endIndexItem(const DString &ref, const DString &file)
void endTextBlock(bool paraBreak=false)
void docify(const DString &s)
void writeGraphicalHierarchy(DotGfxHierarchyTable &g)
void startHeaderSection()
void endIndexSection(IndexSection is)
void writeString(const DString &text)
void endIndexValue(const DString &name, bool b)
void startProjectNumber()
void endSection(const DString &lab, SectionType t)
void startIndexItem(const DString &ref, const DString &file)
void pushGeneratorState()
void startFile(const DString &name, bool isSource, const DString &manName, const DString &title, int hierarchyLevel=0)
void disableAllBut(OutputType o)
void startTextBlock(bool dense=false)
void startPageDoc(const DString &pageTitle)
void startIndexValue(bool b)
void startTextLink(const DString &file, const DString &anchor)
void writeSplitBar(const DString &name, const DString &allMembersFile)
void generateDoc(const DString &fileName, int startLine, const Definition *ctx, const MemberDef *md, const DString &docStr, const DocOptions &options)
void startSection(const DString &lab, const DString &title, SectionType t)
void startIndexListItem()
void writeQuickLinks(HighlightedItem hli, const DString &file, bool extraTabs=false)
void startIndexSection(IndexSection is)
A model of a page symbol.
virtual void addSectionsToIndex()=0
virtual bool visibleInIndex() const =0
virtual const PageLinkedRefMap & getSubPages() const =0
virtual bool hasSubPages() const =0
virtual DString title() const =0
class that provide information about a section.
static SectionManager & instance()
returns a reference to the singleton
static constexpr int Subsection
Text streaming class that buffers data.
std::string str() const
Return the contents of the buffer as a std::string object.
virtual DString trCompoundMembers()=0
virtual DString trFileDocumentation()=0
virtual DString trFunctionAndProc()=0
virtual DString trTypedefs()=0
virtual DString trConceptList()=0
virtual DString trTopics()=0
virtual DString trModulesMembers()=0
virtual DString trEnumerations()=0
virtual DString trFileMembersDescriptionTotal(FileMemberHighlight::Enum hl)=0
virtual DString trExceptionDocumentation()=0
virtual DString trInterfaceIndex()=0
virtual DString trNamespaceMembers()=0
virtual DString trNamespaceList()=0
virtual DString trExceptionList()=0
virtual DString trCode()=0
virtual DString trClassDocumentation()=0
virtual DString trHierarchicalIndex()=0
virtual DString trExceptionHierarchyDescription()=0
virtual DString trInterfaceList()=0
virtual DString trSequences()=0
virtual DString trFunctions()=0
virtual DString trReferenceManual()=0
virtual DString trInterfaceListDescription()=0
virtual DString trConceptIndex()=0
virtual DString trTopicIndex()=0
virtual DString trGotoTextualHierarchy()=0
virtual DString trExceptionHierarchy()=0
virtual DString trCompoundList()=0
virtual DString trModuleIndex()=0
virtual DString trInterfaceHierarchy()=0
virtual DString trTypeDocumentation()=0
virtual DString trInterfaceDocumentation()=0
virtual DString trStructListDescription()=0
virtual DString trDocumentation(const DString &projName)=0
virtual DString trExamplesDescription()=0
virtual DString trNamespaceDocumentation()=0
virtual DString trFileList()=0
virtual DString trModules()=0
virtual DString trLegendDocs()=0
virtual DString trDefines()=0
virtual DString trRelatedPages()=0
virtual DString trLegendTitle()=0
virtual DString trRelatedSymbols()=0
virtual DString trFileMembers()=0
virtual DString trDirectories()=0
virtual DString trInterfaceHierarchyDescription()=0
virtual DString trStructIndex()=0
virtual DString trExceptionIndex()=0
virtual DString trModuleDocumentation()=0
virtual DString trExceptionListDescription()=0
virtual DString trProperties()=0
virtual DString trRelatedPagesDescription()=0
virtual DString trCompoundIndexFortran()=0
virtual DString trCompoundListDescription()=0
virtual DString trTopicListDescription()=0
virtual DString trModulesIndex()=0
virtual DString trModuleMembersDescriptionTotal(ModuleMemberHighlight::Enum hl)=0
virtual DString trFileListDescription(bool extractAll)=0
virtual DString trClassHierarchyDescription()=0
virtual DString trConceptListDescription(bool extractAll)=0
virtual DString trSubprograms()=0
virtual DString trAll()=0
virtual DString trTopicDocumentation()=0
virtual DString trGeneratedBy()=0
virtual DString trVariables()=0
virtual DString trConceptDocumentation()=0
virtual DString trEnumerationValues()=0
virtual DString trDirDocumentation()=0
virtual DString trModulesListDescription(bool extractAll)=0
virtual DString trStructList()=0
virtual DString trNamespaceListDescription(bool extractAll)=0
virtual DString trCompoundMembersDescriptionTotal(ClassMemberHighlight::Enum hl)=0
virtual DString trClassHierarchy()=0
virtual DString trDirIndex()=0
virtual DString trCompoundIndex()=0
virtual DString trDesignUnitIndex()=0
virtual DString trConstants()=0
virtual DString trStructDocumentation()=0
virtual DString trMainPage()=0
virtual DString trEvents()=0
virtual DString trDictionaries()=0
virtual DString trFileIndex()=0
virtual DString trExamples()=0
virtual DString trNamespaceMembersDescriptionTotal(NamespaceMemberHighlight::Enum hl)=0
virtual DString trGotoGraphicalHierarchy()=0
virtual DString trNamespaceIndex()=0
static DString getProtectionName(int prot)
static VhdlClasses convert(Protection prot)
bool classHasVisibleRoot(const BaseClassList &bcl)
bool classVisibleInIndex(const ClassDef *cd)
bool classHasVisibleChildren(const ClassDef *cd)
std::vector< BaseClassDef > BaseClassList
std::unordered_set< const ClassDef * > ClassDefSet
#define Config_updateBool(name, value)
#define Config_getBool(name)
#define Config_getString(name)
std::map< std::string, std::string > StringMap
Definition * toDefinition(DefinitionMutable *dm)
DString parseCommentAsText(const Definition *scope, const MemberDef *md, const DString &doc, const DString &fileName, int lineNr)
DString parseCommentAsHtml(const Definition *scope, const MemberDef *member, const DString &doc, const DString &fileName, int lineNr)
DString substitute(const DString &s, const DString &src, const DString &dst)
substitute all occurrences of src in s by dst
int dstricmp(const char *s1, const char *s2)
uint32_t dstrlen(const char *str)
Returns the length of string str, or 0 if a null pointer is passed.
bool compareFileDefs(const FileDef *fd1, const FileDef *fd2)
std::unique_ptr< FileDef > createFileDef(const DString &p, const DString &n, const DString &ref, const DString &dn)
constexpr auto JAVASCRIPT_LICENSE_TEXT
static void writePages(PageDef *pd, FTVHelp *ftv, bool reuseRoot=false)
static void writeConceptTreeInsideNamespace(const NamespaceLinkedRefMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex)
static DString letterToLabel(const DString &startLetter)
static void writeClassTreeInsideNamespaceElement(const NamespaceDef *nd, FTVHelp *ftv, bool rootOnly, bool addToIndex, ClassDef::CompoundType ct)
static void writeIndexHierarchyEntries(OutputList &ol, const LayoutNavEntryList &entries)
static void writeClassTreeToOutput(OutputList &ol, const BaseClassList &bcl, int level, FTVHelp *ftv, bool addToIndex, ClassDefSet &visitedClasses)
#define MAX_ITEMS_BEFORE_QUICK_INDEX
static void startQuickIndexList(OutputList &ol, bool letterTabs=false)
static void writeFileLinkForMember(OutputList &ol, const MemberDef *md, const DString &separator, DString &prevFileName)
static void writeFileMemberIndexFiltered(OutputList &ol, FileMemberHighlight::Enum hl)
#define MAX_ITEMS_BEFORE_MULTIPAGE_INDEX
static void writeNamespaceTree(const NamespaceLinkedRefMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex)
static bool renderQuickLinksAsJs(std::ostream &t, LayoutNavEntry *root, bool first)
static void writeGraphicalClassHierarchy(OutputList &ol)
static void writeAnnotatedStructIndex(OutputList &ol)
static void startQuickIndexItem(OutputList &ol, const DString &l, bool hl, bool, bool &first)
static void writeAlphabeticalExceptionIndex(OutputList &ol)
static void writeDirIndex(OutputList &ol)
static void writeClassMemberIndex(OutputList &ol)
void writeGraphInfo(OutputList &ol)
static std::vector< bool > indexWritten
static int countConcepts()
static void writeAnnotatedIndex(OutputList &ol)
static void writeClassMemberIndexFiltered(OutputList &ol, ClassMemberHighlight::Enum hl)
static void writeAnnotatedClassList(OutputList &ol, ClassDef::CompoundType ct)
static void writeFileIndex(OutputList &ol)
static void writeGraphicalInterfaceHierarchy(OutputList &ol)
static void endQuickIndexList(OutputList &ol)
static void writeAlphabeticalIndex(OutputList &ol)
static int countClassHierarchy(ClassDef::CompoundType ct)
static void writeAnnotatedInterfaceIndex(OutputList &ol)
static void writePageIndex(OutputList &ol)
void endTitle(OutputList &ol, const DString &fileName, const DString &name)
static void writeNamespaceIndex(OutputList &ol)
static void writeClassTreeInsideNamespace(const NamespaceLinkedRefMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex, ClassDef::CompoundType ct)
void renderMemberIndicesAsJs(std::ostream &t, std::function< std::size_t(std::size_t)> numDocumented, std::function< Index::MemberIndexMap(std::size_t)> getMemberList, const T *(*getInfo)(size_t hl), std::size_t total)
static void writeAnnotatedExceptionIndex(OutputList &ol)
static void writeHierarchicalInterfaceIndex(OutputList &ol)
static void writeNamespaceMembers(const NamespaceDef *nd, bool addToIndex)
static void countRelatedPages(int &docPages, int &indexPages)
static void writeUserGroupStubPage(OutputList &ol, LayoutNavEntry *lne)
static void writeNamespaceMemberIndexFiltered(OutputList &ol, NamespaceMemberHighlight::Enum hl)
static void writeNamespaceTreeElement(const NamespaceDef *nd, FTVHelp *ftv, bool rootOnly, bool addToIndex)
void addMembersToIndex(T *def, LayoutDocManager::LayoutPart part, const DString &name, const DString &anchor, bool addToIndex=true, bool preventSeparateIndex=false, const ConceptLinkedRefMap *concepts=nullptr)
static void writeTopicIndex(OutputList &ol)
static void writeClassTree(const ListType &cl, FTVHelp *ftv, bool addToIndex, bool globalOnly, ClassDef::CompoundType ct)
static void writeModuleMemberIndex(OutputList &ol)
static void writeConceptRootList(FTVHelp *ftv, bool addToIndex)
static const FmhlInfo * getFmhlInfo(size_t hl)
constexpr auto alphaSepar
static void writeGraphicalExceptionHierarchy(OutputList &ol)
static const MmhlInfo * getMmhlInfo(size_t hl)
static void writeClassLinkForMember(OutputList &ol, const MemberDef *md, const DString &separator, DString &prevClassName)
static void countFiles(int &htmlFiles, int &files)
static void writeClassHierarchy(OutputList &ol, FTVHelp *ftv, bool addToIndex, ClassDef::CompoundType ct)
static void writeSingleFileIndex(OutputList &ol, const FileDef *fd)
static void writeExampleIndex(OutputList &ol)
static int countClassesInTreeList(const ClassLinkedMap &cl, ClassDef::CompoundType ct)
static void writeAlphabeticalInterfaceIndex(OutputList &ol)
static void endQuickIndexItem(OutputList &ol)
static void writeAnnotatedIndexGeneric(OutputList &ol, const AnnotatedIndexContext ctx)
static const NmhlInfo * getNmhlInfo(size_t hl)
const ClassDef * get_pointer(const Ptr &p)
static int countAnnotatedClasses(int *cp, ClassDef::CompoundType ct)
static void writeModuleLinkForMember(OutputList &ol, const MemberDef *md, const DString &separator, DString &prevModuleName)
static void writeAlphabeticalStructIndex(OutputList &ol)
static void writeGroupHierarchy(OutputList &ol, FTVHelp *ftv, bool addToIndex)
static void writeModuleMembers(const ModuleDef *mod, bool addToIndex)
static void writeConceptTreeInsideNamespaceElement(const NamespaceDef *nd, FTVHelp *ftv, bool rootOnly, bool addToIndex)
static const CmhlInfo * getCmhlInfo(size_t hl)
static void writeDirHierarchy(OutputList &ol, FTVHelp *ftv, bool addToIndex)
std::set< std::string > UsedIndexLetters
static void writeConceptList(const ConceptLinkedRefMap &concepts, FTVHelp *ftv, bool addToIndex)
static void writeNamespaceLinkForMember(OutputList &ol, const MemberDef *md, const DString &separator, DString &prevNamespaceName)
void writeIndexHierarchy(OutputList &ol)
static void writeMemberIndex(OutputList &ol, const Index::MemberIndexMap &map, DString fullName, bool multiPage)
static void writeModuleList(OutputList &ol, FTVHelp *ftv, bool addToIndex)
static bool dirHasVisibleChildren(const DirDef *dd)
static int countNamespaces()
static void endIndexHierarchy(OutputList &ol, int level)
const int maxItemsBeforeQuickIndex
void endFileWithNavPath(OutputList &ol, const DefinitionMutable *d, bool showPageNavigation)
static void writeConceptIndex(OutputList &ol)
void endFile(OutputList &ol, bool skipNavIndex, bool skipEndContents, const DString &navPath)
static void writeModuleIndex(OutputList &ol)
static void MemberIndexMap_add(Index::MemberIndexMap &map, const std::string &letter, const MemberDef *md)
static void writeIndex(OutputList &ol)
static void writeDirTreeNode(OutputList &ol, const DirDef *dd, int level, FTVHelp *ftv, bool addToIndex)
static void startIndexHierarchy(OutputList &ol, int level)
static bool quickLinkVisible(LayoutNavEntry::Kind kind)
void startTitle(OutputList &ol, const DString &fileName, const DefinitionMutable *def)
static void writeModuleTreeNode(OutputList &ol, const ModuleDef *mod, FTVHelp *ftv, bool addToIndex)
static void writeHierarchicalExceptionIndex(OutputList &ol)
static void writeNamespaceMemberIndex(OutputList &ol)
static void writeHierarchicalIndex(OutputList &ol)
static void writeMenuData()
static void writeGroupTreeNode(OutputList &ol, const GroupDef *gd, int level, FTVHelp *ftv, bool addToIndex)
static void writeMemberToIndex(const Definition *def, const MemberDef *md, bool addToIndex)
static void writeMemberList(OutputList &ol, bool useSections, const std::string &page, const Index::MemberIndexMap &memberIndexMap, Definition::DefType type)
static void writeQuickMemberIndex(OutputList &ol, const Index::MemberIndexMap &map, const std::string &page, DString fullName, bool multiPage)
static void writeFileMemberIndex(OutputList &ol)
static void writeClassTreeForList(OutputList &ol, const ClassLinkedMap &cl, bool &started, FTVHelp *ftv, bool addToIndex, ClassDef::CompoundType ct, ClassDefSet &visitedClasses)
static void writeModuleMemberIndexFiltered(OutputList &ol, ModuleMemberHighlight::Enum hl)
static void writeAlphabeticalClassList(OutputList &ol, ClassDef::CompoundType ct, int)
void startFile(OutputList &ol, const DString &name, bool isSource, const DString &manName, const DString &title, HighlightedItem hli, bool additionalIndices, const DString &altSidebarName, int hierarchyLevel, const DString &allMembersFile)
@ isNamespaceDocumentation
Translator * theTranslator
std::vector< std::unique_ptr< LayoutNavEntry > > LayoutNavEntryList
#define warn(file, line, fmt,...)
std::ofstream openOutputStream(const DString &name, bool append=false)
bool namespaceHasNestedNamespace(const NamespaceDef *nd)
bool namespaceHasNestedClass(const NamespaceDef *nd, bool filterClasses, ClassDef::CompoundType ct)
NamespaceDef * getResolvedNamespace(const DString &name)
bool namespaceHasNestedConcept(const NamespaceDef *nd)
Portable versions of functions that are platform dependent.
const LayoutNavEntry::Kind fallbackKind
AnnotatedIndexContext(int numAnno, int numPrint, LayoutNavEntry::Kind lk, LayoutNavEntry::Kind fk, const DString &title, const DString &intro, ClassDef::CompoundType ct, const DString &fn, HighlightedItem hi)
const DString listDefaultTitleText
const DString fileBaseName
const ClassDef::CompoundType compoundType
const HighlightedItem hiItem
const LayoutNavEntry::Kind listKind
const DString listDefaultIntroText
Helper class representing a class member in the navigation menu.
CmhlInfo(const char *fn, const DString &t)
Helper class to pass options when calling OutputList::generateDoc().
Helper class representing a file member in the navigation menu.
FmhlInfo(const char *fn, const DString &t)
std::array< MemberIndexMap, ModuleMemberHighlight::Total > moduleIndexLetterUsed
std::array< MemberIndexMap, ClassMemberHighlight::Total > classIndexLetterUsed
int annotatedExceptionsPrinted
int annotatedStructsPrinted
std::array< int, FileMemberHighlight::Total > documentedFileMembers
std::array< MemberIndexMap, FileMemberHighlight::Total > fileIndexLetterUsed
std::array< int, ModuleMemberHighlight::Total > documentedModuleMembers
int annotatedInterfacesPrinted
std::array< int, NamespaceMemberHighlight::Total > documentedNamespaceMembers
std::array< int, ClassMemberHighlight::Total > documentedClassMembers
std::array< MemberIndexMap, NamespaceMemberHighlight::Total > namespaceIndexLetterUsed
int annotatedClassesPrinted
Represents of a member declaration list with configurable title and subtitle.
Represents of a member definition list with configurable title.
Base class for the layout of a navigation item at the top of the HTML pages.
const LayoutNavEntryList & children() const
LayoutNavEntry * find(LayoutNavEntry::Kind k, const DString &file=DString()) const
Helper class representing a module member in the navigation menu.
MmhlInfo(const char *fn, const DString &t)
Helper class representing a namespace member in the navigation menu.
NmhlInfo(const char *fn, const DString &t)
bool isTypeAClassFriend(const DString &type)
std::string convertUTF8ToUpper(const std::string &input)
Converts the input string into a upper case version, also taking into account non-ASCII characters th...
std::string convertUTF8ToLower(const std::string &input)
Converts the input string into a lower case version, also taking into account non-ASCII characters th...
std::string getUTF8CharAt(const std::string &input, size_t pos)
Returns the UTF8 character found at byte position pos in the input string.
Various UTF8 related helper functions.
bool isURL(const DString &url)
Checks whether the given url starts with a supported protocol.
DString filterTitle(const DString &title)
DString correctURL(const DString &url, const DString &relPath)
Corrects URL url according to the relative path relPath.
DString convertToJSString(const DString &s, bool keepEntities, bool singleQuotes)
DString convertToId(const DString &s)
DString convertToHtml(const DString &s, bool keepEntities)
void addHtmlExtensionIfMissing(DString &fName)
void extractNamespaceName(const DString &scopeName, DString &className, DString &namespaceName, bool allowEmptyClass)
int getPrefixIndex(const DString &name)
DString getLanguageSpecificSeparator(SrcLangExt lang, bool classScope)
DString getDotImageExtension()
DString stripFromPath(const DString &path)
A bunch of utility functions.