Doxygen
Loading...
Searching...
No Matches
index.cpp File Reference

This file contains functions for the various index pages. More...

#include <cstdlib>
#include <array>
#include <assert.h>
#include "message.h"
#include "index.h"
#include "indexlist.h"
#include "doxygen.h"
#include "config.h"
#include "filedef.h"
#include "outputlist.h"
#include "util.h"
#include "groupdef.h"
#include "language.h"
#include "htmlgen.h"
#include "htmlhelp.h"
#include "ftvhelp.h"
#include "dot.h"
#include "dotgfxhierarchytable.h"
#include "dotlegendgraph.h"
#include "pagedef.h"
#include "dirdef.h"
#include "vhdldocgen.h"
#include "layout.h"
#include "memberlist.h"
#include "classlist.h"
#include "namespacedef.h"
#include "filename.h"
#include "tooltip.h"
#include "utf8.h"
#include "portable.h"
#include "moduledef.h"
#include "sitemap.h"
+ Include dependency graph for index.cpp:

Go to the source code of this file.

Classes

struct  Index::Private
 
class  AlphaIndexTableCell
 Class representing a cell in the alphabetical class index. More...
 
struct  AnnotatedIndexContext
 
struct  CmhlInfo
 Helper class representing a class member in the navigation menu. More...
 
struct  FmhlInfo
 Helper class representing a file member in the navigation menu. More...
 
struct  NmhlInfo
 Helper class representing a namespace member in the navigation menu. More...
 
struct  MmhlInfo
 Helper class representing a module member in the navigation menu. More...
 

Macros

#define MAX_ITEMS_BEFORE_MULTIPAGE_INDEX   200
 
#define MAX_ITEMS_BEFORE_QUICK_INDEX   30
 

Typedefs

using UsedIndexLetters = std::set<std::string>
 

Functions

static int countClassHierarchy (ClassDef::CompoundType ct)
 
static void countFiles (int &htmlFiles, int &files)
 
static int countGroups ()
 
static int countDirs ()
 
static int countNamespaces ()
 
static int countConcepts ()
 
static int countAnnotatedClasses (int *cp, ClassDef::CompoundType ct)
 
static void countRelatedPages (int &docPages, int &indexPages)
 
static void MemberIndexMap_add (Index::MemberIndexMap &map, const std::string &letter, const MemberDef *md)
 
static void startIndexHierarchy (OutputList &ol, int level)
 
static void endIndexHierarchy (OutputList &ol, int level)
 
static void startQuickIndexList (OutputList &ol, bool letterTabs=FALSE)
 
static void endQuickIndexList (OutputList &ol)
 
static void startQuickIndexItem (OutputList &ol, const QCString &l, bool hl, bool, bool &first)
 
static void endQuickIndexItem (OutputList &ol)
 
void startTitle (OutputList &ol, const QCString &fileName, const DefinitionMutable *def)
 
void endTitle (OutputList &ol, const QCString &fileName, const QCString &name)
 
void startFile (OutputList &ol, const QCString &name, const QCString &manName, const QCString &title, HighlightedItem hli, bool additionalIndices, const QCString &altSidebarName, int hierarchyLevel)
 
void endFile (OutputList &ol, bool skipNavIndex, bool skipEndContents, const QCString &navPath)
 
void endFileWithNavPath (OutputList &ol, const Definition *d)
 
static void writeMemberToIndex (const Definition *def, const MemberDef *md, bool addToIndex)
 
template<class T >
void addMembersToIndex (T *def, LayoutDocManager::LayoutPart part, const QCString &name, const QCString &anchor, bool addToIndex=TRUE, bool preventSeparateIndex=FALSE, const ConceptLinkedRefMap *concepts=nullptr)
 
static void writeClassTreeToOutput (OutputList &ol, const BaseClassList &bcl, int level, FTVHelp *ftv, bool addToIndex, ClassDefSet &visitedClasses)
 
static bool dirHasVisibleChildren (const DirDef *dd)
 
static void writeDirTreeNode (OutputList &ol, const DirDef *dd, int level, FTVHelp *ftv, bool addToIndex)
 
static void writeDirHierarchy (OutputList &ol, FTVHelp *ftv, bool addToIndex)
 
static void writeClassTreeForList (OutputList &ol, const ClassLinkedMap &cl, bool &started, FTVHelp *ftv, bool addToIndex, ClassDef::CompoundType ct, ClassDefSet &visitedClasses)
 
static void writeClassHierarchy (OutputList &ol, FTVHelp *ftv, bool addToIndex, ClassDef::CompoundType ct)
 
static int countClassesInTreeList (const ClassLinkedMap &cl, ClassDef::CompoundType ct)
 
static void writeHierarchicalIndex (OutputList &ol)
 
static void writeGraphicalClassHierarchy (OutputList &ol)
 
static void writeHierarchicalInterfaceIndex (OutputList &ol)
 
static void writeGraphicalInterfaceHierarchy (OutputList &ol)
 
static void writeHierarchicalExceptionIndex (OutputList &ol)
 
static void writeGraphicalExceptionHierarchy (OutputList &ol)
 
static void writeSingleFileIndex (OutputList &ol, const FileDef *fd)
 
static void writeFileIndex (OutputList &ol)
 
template<typename Ptr >
const ClassDefget_pointer (const Ptr &p)
 
template<>
const ClassDefget_pointer (const ClassLinkedMap::Ptr &p)
 
template<>
const ClassDefget_pointer (const ClassLinkedRefMap::Ptr &p)
 
template<class ListType >
static void writeClassTree (const ListType &cl, FTVHelp *ftv, bool addToIndex, bool globalOnly, ClassDef::CompoundType ct)
 
static void writeNamespaceMembers (const NamespaceDef *nd, bool addToIndex)
 
static void writeModuleMembers (const ModuleDef *mod, bool addToIndex)
 
static void writeConceptList (const ConceptLinkedRefMap &concepts, FTVHelp *ftv, bool addToIndex)
 
static void writeNamespaceTree (const NamespaceLinkedRefMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex)
 
static void writeNamespaceTreeElement (const NamespaceDef *nd, FTVHelp *ftv, bool rootOnly, bool addToIndex)
 
static void writeNamespaceTree (const NamespaceLinkedMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex)
 
static void writeClassTreeInsideNamespace (const NamespaceLinkedRefMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex, ClassDef::CompoundType ct)
 
static void writeClassTreeInsideNamespaceElement (const NamespaceDef *nd, FTVHelp *ftv, bool rootOnly, bool addToIndex, ClassDef::CompoundType ct)
 
static void writeClassTreeInsideNamespace (const NamespaceLinkedMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex, ClassDef::CompoundType ct)
 
static void writeNamespaceIndex (OutputList &ol)
 
static void writeAnnotatedClassList (OutputList &ol, ClassDef::CompoundType ct)
 
bool isId1 (int c)
 
static QCString letterToLabel (const QCString &startLetter)
 
static void writeAlphabeticalClassList (OutputList &ol, ClassDef::CompoundType ct, int)
 
static void writeAlphabeticalIndex (OutputList &ol)
 
static void writeAlphabeticalInterfaceIndex (OutputList &ol)
 
static void writeAlphabeticalStructIndex (OutputList &ol)
 
static void writeAlphabeticalExceptionIndex (OutputList &ol)
 
static void writeAnnotatedIndexGeneric (OutputList &ol, const AnnotatedIndexContext ctx)
 
static void writeAnnotatedIndex (OutputList &ol)
 
static void writeAnnotatedInterfaceIndex (OutputList &ol)
 
static void writeAnnotatedStructIndex (OutputList &ol)
 
static void writeAnnotatedExceptionIndex (OutputList &ol)
 
static void writeClassLinkForMember (OutputList &ol, const MemberDef *md, const QCString &separator, QCString &prevClassName)
 
static void writeFileLinkForMember (OutputList &ol, const MemberDef *md, const QCString &separator, QCString &prevFileName)
 
static void writeNamespaceLinkForMember (OutputList &ol, const MemberDef *md, const QCString &separator, QCString &prevNamespaceName)
 
static void writeModuleLinkForMember (OutputList &ol, const MemberDef *md, const QCString &separator, QCString &prevModuleName)
 
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, QCString fullName, bool multiPage)
 
static const CmhlInfogetCmhlInfo (size_t hl)
 
static void writeClassMemberIndexFiltered (OutputList &ol, ClassMemberHighlight::Enum hl)
 
static void writeClassMemberIndex (OutputList &ol)
 
static const FmhlInfogetFmhlInfo (size_t hl)
 
static void writeFileMemberIndexFiltered (OutputList &ol, FileMemberHighlight::Enum hl)
 
static void writeFileMemberIndex (OutputList &ol)
 
static const NmhlInfogetNmhlInfo (size_t hl)
 
static void writeNamespaceMemberIndexFiltered (OutputList &ol, NamespaceMemberHighlight::Enum hl)
 
static void writeNamespaceMemberIndex (OutputList &ol)
 
static const MmhlInfogetMmhlInfo (size_t hl)
 
static void writeModuleMemberIndexFiltered (OutputList &ol, ModuleMemberHighlight::Enum hl)
 
static void writeModuleMemberIndex (OutputList &ol)
 
static void writeExampleIndex (OutputList &ol)
 
static bool mainPageHasOwnTitle ()
 
static void writePages (PageDef *pd, FTVHelp *ftv)
 
static void writePageIndex (OutputList &ol)
 
void writeGraphInfo (OutputList &ol)
 
static void writeGroupTreeNode (OutputList &ol, const GroupDef *gd, int level, FTVHelp *ftv, bool addToIndex)
 
static void writeGroupHierarchy (OutputList &ol, FTVHelp *ftv, bool addToIndex)
 
static void writeTopicIndex (OutputList &ol)
 
static void writeModuleTreeNode (OutputList &ol, const ModuleDef *mod, FTVHelp *ftv, bool addToIndex)
 
static void writeModuleList (OutputList &ol, FTVHelp *ftv, bool addToIndex)
 
static void writeModuleIndex (OutputList &ol)
 
static void writeConceptTreeInsideNamespaceElement (const NamespaceDef *nd, FTVHelp *ftv, bool rootOnly, bool addToIndex)
 
static void writeConceptTreeInsideNamespace (const NamespaceLinkedRefMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex)
 
static void writeConceptRootList (FTVHelp *ftv, bool addToIndex)
 
static void writeConceptIndex (OutputList &ol)
 
static void writeUserGroupStubPage (OutputList &ol, LayoutNavEntry *lne)
 
static void writeIndex (OutputList &ol)
 
static void writeIndexHierarchyEntries (OutputList &ol, const LayoutNavEntryList &entries)
 
static bool quickLinkVisible (LayoutNavEntry::Kind kind)
 
template<class T >
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 bool renderQuickLinksAsJs (std::ostream &t, LayoutNavEntry *root, bool first)
 
static void writeMenuData ()
 
void writeIndexHierarchy (OutputList &ol)
 

Variables

const int maxItemsBeforeQuickIndex = MAX_ITEMS_BEFORE_QUICK_INDEX
 
static std::vector< bool > indexWritten
 

Detailed Description

This file contains functions for the various index pages.

Definition in file index.cpp.

Macro Definition Documentation

◆ MAX_ITEMS_BEFORE_MULTIPAGE_INDEX

◆ MAX_ITEMS_BEFORE_QUICK_INDEX

#define MAX_ITEMS_BEFORE_QUICK_INDEX   30

Definition at line 56 of file index.cpp.

Typedef Documentation

◆ UsedIndexLetters

using UsedIndexLetters = std::set<std::string>

Definition at line 2243 of file index.cpp.

Function Documentation

◆ addMembersToIndex()

template<class T >
void addMembersToIndex ( T * def,
LayoutDocManager::LayoutPart part,
const QCString & name,
const QCString & anchor,
bool addToIndex = TRUE,
bool preventSeparateIndex = FALSE,
const ConceptLinkedRefMap * concepts = nullptr )

Definition at line 518 of file index.cpp.

523{
524 int numClasses=0;
525 for (const auto &cd : def->getClasses())
526 {
527 if (cd->isLinkable()) numClasses++;
528 }
529 int numConcepts=0;
530 if (concepts)
531 {
532 for (const auto &cd : *concepts)
533 {
534 if (cd->isLinkable()) numConcepts++;
535 }
536 }
537 bool hasMembers = !def->getMemberLists().empty() || !def->getMemberGroups().empty() || (numClasses>0) || (numConcepts>0);
538 Doxygen::indexList->addContentsItem(hasMembers,name,
539 def->getReference(),def->getOutputFileBase(),anchor,
540 hasMembers && !preventSeparateIndex,
541 addToIndex,
542 def);
543 //printf("addMembersToIndex(def=%s hasMembers=%d numClasses=%d)\n",qPrint(def->name()),hasMembers,numClasses);
544 if (hasMembers || numClasses>0 || numConcepts>0)
545 {
546 Doxygen::indexList->incContentsDepth();
547 for (const auto &lde : LayoutDocManager::instance().docEntries(part))
548 {
549 auto kind = lde->kind();
550 if (kind==LayoutDocEntry::MemberDef)
551 {
552 const LayoutDocEntryMemberDef *lmd = dynamic_cast<const LayoutDocEntryMemberDef*>(lde.get());
553 if (lmd)
554 {
555 MemberList *ml = def->getMemberList(lmd->type);
556 if (ml)
557 {
558 for (const auto &md : *ml)
559 {
560 if (md->visibleInIndex())
561 {
562 writeMemberToIndex(def,md,addToIndex);
563 }
564 }
565 }
566 }
567 }
568 else if (kind==LayoutDocEntry::NamespaceClasses ||
569 kind==LayoutDocEntry::FileClasses ||
570 kind==LayoutDocEntry::ClassNestedClasses ||
571 kind==LayoutDocEntry::ModuleClasses
572 )
573 {
574 for (const auto &cd : def->getClasses())
575 {
576 if (cd->isLinkable() && (cd->partOfGroups().empty() || def->definitionType()==Definition::TypeGroup))
577 {
578 bool inlineSimpleStructs = Config_getBool(INLINE_SIMPLE_STRUCTS);
579 bool isNestedClass = def->definitionType()==Definition::TypeClass;
580 addMembersToIndex(cd,LayoutDocManager::Class,cd->displayName(lde->kind()==LayoutDocEntry::FileClasses),cd->anchor(),
581 addToIndex && (isNestedClass || (cd->isSimple() && inlineSimpleStructs)),
582 preventSeparateIndex || cd->isEmbeddedInOuterScope());
583 }
584 }
585 }
586 else if ((kind==LayoutDocEntry::FileConcepts || kind==LayoutDocEntry::ModuleConcepts) && concepts)
587 {
588 for (const auto &cd : *concepts)
589 {
590 if (cd->isLinkable() && (cd->partOfGroups().empty() || def->definitionType()==Definition::TypeGroup))
591 {
592 Doxygen::indexList->addContentsItem(false,cd->displayName(),
593 cd->getReference(),cd->getOutputFileBase(),QCString(),
594 addToIndex,
595 false,
596 cd);
597 }
598 }
599 }
600 }
601
602 Doxygen::indexList->decContentsDepth();
603 }
604}
static IndexList * indexList
Definition doxygen.h:134
static LayoutDocManager & instance()
Returns a reference to this singleton.
Definition layout.cpp:1423
A list of MemberDef objects as shown in documentation sections.
Definition memberlist.h:108
This is an alternative implementation of QCString.
Definition qcstring.h:101
#define Config_getBool(name)
Definition config.h:33
static void addMembersToIndex()
Definition doxygen.cpp:7954
static void writeMemberToIndex(const Definition *def, const MemberDef *md, bool addToIndex)
Definition index.cpp:458
Represents of a member definition list with configurable title.
Definition layout.h:125
MemberListType type
Definition layout.h:130

References addMembersToIndex(), Config_getBool, FALSE, Doxygen::indexList, LayoutDocManager::instance(), TRUE, LayoutDocEntryMemberDef::type, Definition::TypeClass, Definition::TypeGroup, and writeMemberToIndex().

◆ countAnnotatedClasses()

static int countAnnotatedClasses ( int * cp,
ClassDef::CompoundType ct )
static

Definition at line 2093 of file index.cpp.

2094{
2095 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
2096 int count=0;
2097 int countPrinted=0;
2098 for (const auto &cd : *Doxygen::classLinkedMap)
2099 {
2100 if (sliceOpt && cd->compoundType() != ct)
2101 {
2102 continue;
2103 }
2104 if (cd->isLinkableInProject() && !cd->isImplicitTemplateInstance())
2105 {
2106 if (!cd->isEmbeddedInOuterScope())
2107 {
2108 countPrinted++;
2109 }
2110 count++;
2111 }
2112 }
2113 *cp = countPrinted;
2114 return count;
2115}
static ClassLinkedMap * classLinkedMap
Definition doxygen.h:96

References Doxygen::classLinkedMap, and Config_getBool.

Referenced by Index::countDataStructures().

◆ countClassesInTreeList()

static int countClassesInTreeList ( const ClassLinkedMap & cl,
ClassDef::CompoundType ct )
static

Definition at line 1081 of file index.cpp.

1082{
1083 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
1084 int count=0;
1085 for (const auto &cd : cl)
1086 {
1087 if (sliceOpt && cd->compoundType() != ct)
1088 {
1089 continue;
1090 }
1091 if (!classHasVisibleRoot(cd->baseClasses())) // filter on root classes
1092 {
1093 if (cd->isVisibleInHierarchy()) // should it be visible
1094 {
1095 if (!cd->subClasses().empty()) // should have sub classes
1096 {
1097 count++;
1098 }
1099 }
1100 }
1101 }
1102 return count;
1103}
bool classHasVisibleRoot(const BaseClassList &bcl)

References classHasVisibleRoot(), and Config_getBool.

Referenced by countClassHierarchy().

◆ countClassHierarchy()

static int countClassHierarchy ( ClassDef::CompoundType ct)
static

Definition at line 1105 of file index.cpp.

1106{
1107 int count=0;
1110 return count;
1111}
static ClassLinkedMap * hiddenClassLinkedMap
Definition doxygen.h:97
static int countClassesInTreeList(const ClassLinkedMap &cl, ClassDef::CompoundType ct)
Definition index.cpp:1081

References Doxygen::classLinkedMap, countClassesInTreeList(), and Doxygen::hiddenClassLinkedMap.

Referenced by Index::countDataStructures().

◆ countConcepts()

static int countConcepts ( )
static

Definition at line 1673 of file index.cpp.

1674{
1675 int count=0;
1676 for (const auto &cd : *Doxygen::conceptLinkedMap)
1677 {
1678 if (cd->isLinkableInProject()) count++;
1679 }
1680 return count;
1681}
static ConceptLinkedMap * conceptLinkedMap
Definition doxygen.h:98

References Doxygen::conceptLinkedMap.

Referenced by Index::countDataStructures().

◆ countDirs()

static int countDirs ( )
static

Definition at line 3930 of file index.cpp.

3931{
3932 int count=0;
3933 for (const auto &dd : *Doxygen::dirLinkedMap)
3934 {
3935 if (dd->isLinkableInProject())
3936 {
3937 count++;
3938 }
3939 }
3940 return count;
3941}
static DirLinkedMap * dirLinkedMap
Definition doxygen.h:129

References Doxygen::dirLinkedMap.

Referenced by Index::countDataStructures().

◆ countFiles()

static void countFiles ( int & htmlFiles,
int & files )
static

Definition at line 1432 of file index.cpp.

1433{
1434 allFiles=0;
1435 docFiles=0;
1436 for (const auto &fn : *Doxygen::inputNameLinkedMap)
1437 {
1438 for (const auto &fd: *fn)
1439 {
1440 bool src = false;
1441 bool doc = fileVisibleInIndex(fd.get(),src);
1442 if (doc || src)
1443 {
1444 allFiles++;
1445 }
1446 if (doc)
1447 {
1448 docFiles++;
1449 }
1450 }
1451 }
1452}
static FileNameLinkedMap * inputNameLinkedMap
Definition doxygen.h:105
bool fileVisibleInIndex(const FileDef *fd, bool &genSourceFile)
Definition util.cpp:6416

References fileVisibleInIndex(), and Doxygen::inputNameLinkedMap.

Referenced by Index::countDataStructures().

◆ countGroups()

static int countGroups ( )
static

Definition at line 3914 of file index.cpp.

3915{
3916 int count=0;
3917 for (const auto &gd : *Doxygen::groupLinkedMap)
3918 {
3919 if (!gd->isReference())
3920 {
3921 //gd->visited=FALSE;
3922 count++;
3923 }
3924 }
3925 return count;
3926}
static GroupLinkedMap * groupLinkedMap
Definition doxygen.h:114

References Doxygen::groupLinkedMap.

Referenced by Index::countDataStructures().

◆ countNamespaces()

static int countNamespaces ( )
static

Definition at line 1662 of file index.cpp.

1663{
1664 int count=0;
1665 for (const auto &nd : *Doxygen::namespaceLinkedMap)
1666 {
1667 if (nd->isLinkableInProject()) count++;
1668 }
1669 return count;
1670}
static NamespaceLinkedMap * namespaceLinkedMap
Definition doxygen.h:115

References Doxygen::namespaceLinkedMap.

Referenced by Index::countDataStructures().

◆ countRelatedPages()

static void countRelatedPages ( int & docPages,
int & indexPages )
static

Definition at line 3783 of file index.cpp.

3784{
3785 docPages=indexPages=0;
3786 for (const auto &pd : *Doxygen::pageLinkedMap)
3787 {
3788 if (pd->visibleInIndex() && !pd->hasParentPage())
3789 {
3790 indexPages++;
3791 }
3792 if (pd->documentedPage())
3793 {
3794 docPages++;
3795 }
3796 }
3797}
static PageLinkedMap * pageLinkedMap
Definition doxygen.h:100

References Doxygen::pageLinkedMap.

Referenced by Index::countDataStructures().

◆ dirHasVisibleChildren()

static bool dirHasVisibleChildren ( const DirDef * dd)
static

Definition at line 718 of file index.cpp.

719{
720 if (dd->hasDocumentation()) return TRUE;
721
722 for (const auto &fd : dd->getFiles())
723 {
724 bool genSourceFile = false;
725 if (fileVisibleInIndex(fd,genSourceFile))
726 {
727 return TRUE;
728 }
729 if (genSourceFile)
730 {
731 return TRUE;
732 }
733 }
734
735 for(const auto &subdd : dd->subDirs())
736 {
737 if (dirHasVisibleChildren(subdd))
738 {
739 return TRUE;
740 }
741 }
742 return FALSE;
743}
virtual bool hasDocumentation() const =0
virtual const DirList & subDirs() const =0
virtual const FileList & getFiles() const =0
static bool dirHasVisibleChildren(const DirDef *dd)
Definition index.cpp:718
#define TRUE
Definition qcstring.h:37
#define FALSE
Definition qcstring.h:34

References dirHasVisibleChildren(), FALSE, fileVisibleInIndex(), DirDef::getFiles(), Definition::hasDocumentation(), DirDef::subDirs(), and TRUE.

Referenced by dirHasVisibleChildren(), and writeDirTreeNode().

◆ endFile()

void endFile ( OutputList & ol,
bool skipNavIndex,
bool skipEndContents,
const QCString & navPath )

Definition at line 421 of file index.cpp.

423{
424 bool generateTreeView = Config_getBool(GENERATE_TREEVIEW);
427 if (!skipNavIndex)
428 {
429 if (!skipEndContents) ol.endContents();
430 if (generateTreeView)
431 {
432 ol.writeString("</div><!-- doc-content -->\n");
433 }
434 }
435
436 ol.writeFooter(navPath); // write the footer
438 ol.endFile();
439}
void writeString(const QCString &text)
Definition outputlist.h:412
void endContents()
Definition outputlist.h:619
void endFile()
Definition outputlist.h:402
void pushGeneratorState()
void disableAllBut(OutputType o)
void popGeneratorState()
void writeFooter(const QCString &navPath)
Definition outputlist.h:400

References Config_getBool, OutputList::disableAllBut(), OutputList::endContents(), OutputList::endFile(), Html, OutputList::popGeneratorState(), OutputList::pushGeneratorState(), OutputList::writeFooter(), and OutputList::writeString().

Referenced by endFileWithNavPath(), generateExampleDocs(), writeAlphabeticalExceptionIndex(), writeAlphabeticalIndex(), writeAlphabeticalInterfaceIndex(), writeAlphabeticalStructIndex(), writeAnnotatedIndexGeneric(), writeClassMemberIndexFiltered(), writeConceptIndex(), GroupDefImpl::writeDocumentation(), ModuleDefImpl::writeDocumentation(), PageDefImpl::writeDocumentation(), MemberList::writeDocumentationPage(), writeExampleIndex(), writeFileIndex(), writeFileMemberIndexFiltered(), writeGraphicalClassHierarchy(), writeGraphicalExceptionHierarchy(), writeGraphicalInterfaceHierarchy(), writeGraphInfo(), writeHierarchicalExceptionIndex(), writeHierarchicalIndex(), writeHierarchicalInterfaceIndex(), writeIndex(), ClassDefImpl::writeMemberList(), writeModuleIndex(), writeModuleMemberIndexFiltered(), writeNamespaceIndex(), writeNamespaceMemberIndexFiltered(), writePageIndex(), writeTopicIndex(), and writeUserGroupStubPage().

◆ endFileWithNavPath()

void endFileWithNavPath ( OutputList & ol,
const Definition * d )

Definition at line 441 of file index.cpp.

442{
443 bool generateTreeView = Config_getBool(GENERATE_TREEVIEW);
444 QCString navPath;
445 if (generateTreeView)
446 {
449 ol.writeString("</div><!-- doc-content -->\n");
451 navPath = d->navigationPathAsString();
452 }
453 endFile(ol,generateTreeView,TRUE,navPath);
454}
virtual QCString navigationPathAsString() const =0
void endFile(OutputList &ol, bool skipNavIndex, bool skipEndContents, const QCString &navPath)
Definition index.cpp:421

References Config_getBool, OutputList::disableAllBut(), endFile(), Html, Definition::navigationPathAsString(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), TRUE, and OutputList::writeString().

Referenced by ClassDefImpl::writeDocumentation(), ConceptDefImpl::writeDocumentation(), DirDefImpl::writeDocumentation(), DirRelation::writeDocumentation(), FileDefImpl::writeDocumentation(), NamespaceDefImpl::writeDocumentation(), PageDefImpl::writeDocumentation(), MemberList::writeDocumentationPage(), and FileDefImpl::writeSourceFooter().

◆ endIndexHierarchy()

◆ endQuickIndexItem()

static void endQuickIndexItem ( OutputList & ol)
static

◆ endQuickIndexList()

static void endQuickIndexList ( OutputList & ol)
static

◆ endTitle()

◆ get_pointer() [1/3]

template<>
const ClassDef * get_pointer ( const ClassLinkedMap::Ptr & p)

Definition at line 1686 of file index.cpp.

1686{ return p.get(); }

◆ get_pointer() [2/3]

template<>
const ClassDef * get_pointer ( const ClassLinkedRefMap::Ptr & p)

Definition at line 1687 of file index.cpp.

1687{ return p; }

◆ get_pointer() [3/3]

template<typename Ptr >
const ClassDef * get_pointer ( const Ptr & p)

Referenced by writeClassTree().

◆ getCmhlInfo()

static const CmhlInfo * getCmhlInfo ( size_t hl)
static

Definition at line 3076 of file index.cpp.

3077{
3078 bool fortranOpt = Config_getBool(OPTIMIZE_FOR_FORTRAN);
3079 bool vhdlOpt = Config_getBool(OPTIMIZE_OUTPUT_VHDL);
3080 static CmhlInfo cmhlInfo[] =
3081 {
3082 CmhlInfo("functions", theTranslator->trAll()),
3083 CmhlInfo("functions_func",
3084 fortranOpt ? theTranslator->trSubprograms() :
3085 vhdlOpt ? theTranslator->trFunctionAndProc() :
3086 theTranslator->trFunctions()),
3087 CmhlInfo("functions_vars",theTranslator->trVariables()),
3088 CmhlInfo("functions_type",theTranslator->trTypedefs()),
3089 CmhlInfo("functions_enum",theTranslator->trEnumerations()),
3090 CmhlInfo("functions_eval",theTranslator->trEnumerationValues()),
3091 CmhlInfo("functions_prop",theTranslator->trProperties()),
3092 CmhlInfo("functions_evnt",theTranslator->trEvents()),
3093 CmhlInfo("functions_rela",theTranslator->trRelatedSymbols())
3094 };
3095 return &cmhlInfo[hl];
3096}
Translator * theTranslator
Definition language.cpp:71
Helper class representing a class member in the navigation menu.
Definition index.cpp:3070

References Config_getBool, and theTranslator.

Referenced by renderQuickLinksAsJs(), and writeClassMemberIndexFiltered().

◆ getFmhlInfo()

static const FmhlInfo * getFmhlInfo ( size_t hl)
static

Definition at line 3243 of file index.cpp.

3244{
3245 bool fortranOpt = Config_getBool(OPTIMIZE_FOR_FORTRAN);
3246 bool vhdlOpt = Config_getBool(OPTIMIZE_OUTPUT_VHDL);
3247 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
3248 static FmhlInfo fmhlInfo[] =
3249 {
3250 FmhlInfo("globals", theTranslator->trAll()),
3251 FmhlInfo("globals_func",
3252 fortranOpt ? theTranslator->trSubprograms() :
3253 vhdlOpt ? theTranslator->trFunctionAndProc() :
3254 theTranslator->trFunctions()),
3255 FmhlInfo("globals_vars",sliceOpt ? theTranslator->trConstants() : theTranslator->trVariables()),
3256 FmhlInfo("globals_type",theTranslator->trTypedefs()),
3257 FmhlInfo("globals_sequ",theTranslator->trSequences()),
3258 FmhlInfo("globals_dict",theTranslator->trDictionaries()),
3259 FmhlInfo("globals_enum",theTranslator->trEnumerations()),
3260 FmhlInfo("globals_eval",theTranslator->trEnumerationValues()),
3261 FmhlInfo("globals_defs",theTranslator->trDefines())
3262 };
3263 return &fmhlInfo[hl];
3264}
Helper class representing a file member in the navigation menu.
Definition index.cpp:3237

References Config_getBool, and theTranslator.

Referenced by renderQuickLinksAsJs(), and writeFileMemberIndexFiltered().

◆ getMmhlInfo()

static const MmhlInfo * getMmhlInfo ( size_t hl)
static

Definition at line 3569 of file index.cpp.

3570{
3571 static MmhlInfo nmhlInfo[] =
3572 {
3573 MmhlInfo("modulemembers", theTranslator->trAll()),
3574 MmhlInfo("modulemembers_func",theTranslator->trFunctions()),
3575 MmhlInfo("modulemembers_vars",theTranslator->trVariables()),
3576 MmhlInfo("modulemembers_type",theTranslator->trTypedefs()),
3577 MmhlInfo("modulemembers_enum",theTranslator->trEnumerations()),
3578 MmhlInfo("modulemembers_eval",theTranslator->trEnumerationValues())
3579 };
3580 return &nmhlInfo[hl];
3581}
Helper class representing a module member in the navigation menu.
Definition index.cpp:3563

References theTranslator.

Referenced by renderQuickLinksAsJs(), and writeModuleMemberIndexFiltered().

◆ getNmhlInfo()

static const NmhlInfo * getNmhlInfo ( size_t hl)
static

Definition at line 3404 of file index.cpp.

3405{
3406 bool fortranOpt = Config_getBool(OPTIMIZE_FOR_FORTRAN);
3407 bool vhdlOpt = Config_getBool(OPTIMIZE_OUTPUT_VHDL);
3408 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
3409 static NmhlInfo nmhlInfo[] =
3410 {
3411 NmhlInfo("namespacemembers", theTranslator->trAll()),
3412 NmhlInfo("namespacemembers_func",
3413 fortranOpt ? theTranslator->trSubprograms() :
3414 vhdlOpt ? theTranslator->trFunctionAndProc() :
3415 theTranslator->trFunctions()),
3416 NmhlInfo("namespacemembers_vars",sliceOpt ? theTranslator->trConstants() : theTranslator->trVariables()),
3417 NmhlInfo("namespacemembers_type",theTranslator->trTypedefs()),
3418 NmhlInfo("namespacemembers_sequ",theTranslator->trSequences()),
3419 NmhlInfo("namespacemembers_dict",theTranslator->trDictionaries()),
3420 NmhlInfo("namespacemembers_enum",theTranslator->trEnumerations()),
3421 NmhlInfo("namespacemembers_eval",theTranslator->trEnumerationValues())
3422 };
3423 return &nmhlInfo[hl];
3424}
Helper class representing a namespace member in the navigation menu.
Definition index.cpp:3398

References Config_getBool, and theTranslator.

Referenced by renderQuickLinksAsJs(), and writeNamespaceMemberIndexFiltered().

◆ isId1()

bool isId1 ( int c)
inline

Definition at line 2192 of file index.cpp.

2193{
2194 return (c<127 && c>31); // printable ASCII character
2195}

Referenced by letterToLabel().

◆ letterToLabel()

static QCString letterToLabel ( const QCString & startLetter)
static

Definition at line 2197 of file index.cpp.

2198{
2199 if (startLetter.isEmpty()) return startLetter;
2200 const char *p = startLetter.data();
2201 char c = *p;
2202 QCString result;
2203 if (isId1(c))
2204 {
2205 result+=c;
2206 }
2207 else
2208 {
2209 result="0x";
2210 const char hex[]="0123456789abcdef";
2211 while ((c=*p++))
2212 {
2213 result+=hex[static_cast<unsigned char>(c)>>4];
2214 result+=hex[static_cast<unsigned char>(c)&0xf];
2215 }
2216 }
2217 return result;
2218}
bool isEmpty() const
Returns TRUE iff the string is empty.
Definition qcstring.h:150
const char * data() const
Returns a pointer to the contents of the string in the form of a 0-terminated C string.
Definition qcstring.h:159
static constexpr auto hex
bool isId1(int c)
Definition index.cpp:2192

References QCString::data(), hex, QCString::isEmpty(), and isId1().

Referenced by renderMemberIndicesAsJs(), writeAlphabeticalClassList(), writeClassMemberIndexFiltered(), writeFileMemberIndexFiltered(), writeMemberList(), writeModuleMemberIndexFiltered(), writeNamespaceMemberIndexFiltered(), and writeQuickMemberIndex().

◆ mainPageHasOwnTitle()

static bool mainPageHasOwnTitle ( )
static

Definition at line 3801 of file index.cpp.

3802{
3803 QCString projectName = Config_getString(PROJECT_NAME);
3804 QCString title;
3806 {
3807 title = filterTitle(Doxygen::mainPage->title());
3808 }
3809 return !projectName.isEmpty() && mainPageHasTitle() && qstricmp(title,projectName)!=0;
3810}
static std::unique_ptr< PageDef > mainPage
Definition doxygen.h:101
#define Config_getString(name)
Definition config.h:32
int qstricmp(const char *s1, const char *s2)
Definition qcstring.cpp:442
bool mainPageHasTitle()
Definition util.cpp:6611
QCString filterTitle(const QCString &title)
Definition util.cpp:5920

References Config_getString, filterTitle(), QCString::isEmpty(), Doxygen::mainPage, mainPageHasTitle(), and qstricmp().

Referenced by writePages().

◆ MemberIndexMap_add()

static void MemberIndexMap_add ( Index::MemberIndexMap & map,
const std::string & letter,
const MemberDef * md )
static

Definition at line 180 of file index.cpp.

181{
182 auto it = map.find(letter);
183 if (it!=map.end())
184 {
185 it->second.push_back(md);
186 }
187 else
188 {
189 map.emplace(letter,std::vector<const MemberDef*>({md}));
190 }
191}

Referenced by Index::incrementDocumentedClassMembers(), Index::incrementDocumentedFileMembers(), Index::incrementDocumentedModuleMembers(), and Index::incrementDocumentedNamespaceMembers().

◆ quickLinkVisible()

static bool quickLinkVisible ( LayoutNavEntry::Kind kind)
static

Definition at line 5388 of file index.cpp.

5389{
5390 const auto &index = Index::instance();
5391 bool showNamespaces = Config_getBool(SHOW_NAMESPACES);
5392 bool showFiles = Config_getBool(SHOW_FILES);
5393 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
5394 switch (kind)
5395 {
5396 case LayoutNavEntry::MainPage: return TRUE;
5397 case LayoutNavEntry::User: return TRUE;
5398 case LayoutNavEntry::UserGroup: return TRUE;
5399 case LayoutNavEntry::Pages: return index.numIndexedPages()>0;
5400 case LayoutNavEntry::Topics: return index.numDocumentedGroups()>0;
5401 case LayoutNavEntry::Modules: return index.numDocumentedModules()>0;
5402 case LayoutNavEntry::ModuleList: return index.numDocumentedModules()>0;
5403 case LayoutNavEntry::ModuleMembers: return index.numDocumentedModuleMembers(ModuleMemberHighlight::All)>0;
5404 case LayoutNavEntry::Namespaces: return index.numDocumentedNamespaces()>0 && showNamespaces;
5405 case LayoutNavEntry::NamespaceList: return index.numDocumentedNamespaces()>0 && showNamespaces;
5406 case LayoutNavEntry::NamespaceMembers: return index.numDocumentedNamespaceMembers(NamespaceMemberHighlight::All)>0;
5407 case LayoutNavEntry::Concepts: return index.numDocumentedConcepts()>0;
5408 case LayoutNavEntry::Classes: return index.numAnnotatedClasses()>0;
5409 case LayoutNavEntry::ClassList: return index.numAnnotatedClasses()>0;
5410 case LayoutNavEntry::ClassIndex: return index.numAnnotatedClasses()>0;
5411 case LayoutNavEntry::ClassHierarchy: return index.numHierarchyClasses()>0;
5412 case LayoutNavEntry::ClassMembers: return index.numDocumentedClassMembers(ClassMemberHighlight::All)>0 && !sliceOpt;
5413 case LayoutNavEntry::Interfaces: return index.numAnnotatedInterfaces()>0;
5414 case LayoutNavEntry::InterfaceList: return index.numAnnotatedInterfaces()>0;
5415 case LayoutNavEntry::InterfaceIndex: return index.numAnnotatedInterfaces()>0;
5416 case LayoutNavEntry::InterfaceHierarchy: return index.numHierarchyInterfaces()>0;
5417 case LayoutNavEntry::Structs: return index.numAnnotatedStructs()>0;
5418 case LayoutNavEntry::StructList: return index.numAnnotatedStructs()>0;
5419 case LayoutNavEntry::StructIndex: return index.numAnnotatedStructs()>0;
5420 case LayoutNavEntry::Exceptions: return index.numAnnotatedExceptions()>0;
5421 case LayoutNavEntry::ExceptionList: return index.numAnnotatedExceptions()>0;
5422 case LayoutNavEntry::ExceptionIndex: return index.numAnnotatedExceptions()>0;
5423 case LayoutNavEntry::ExceptionHierarchy: return index.numHierarchyExceptions()>0;
5424 case LayoutNavEntry::Files: return index.numDocumentedFiles()>0 && showFiles;
5425 case LayoutNavEntry::FileList: return index.numDocumentedFiles()>0 && showFiles;
5426 case LayoutNavEntry::FileGlobals: return index.numDocumentedFileMembers(FileMemberHighlight::All)>0;
5427 case LayoutNavEntry::Examples: return !Doxygen::exampleLinkedMap->empty();
5428 case LayoutNavEntry::None: // should never happen, means not properly initialized
5429 assert(kind != LayoutNavEntry::None);
5430 return FALSE;
5431 }
5432 return FALSE;
5433}
static PageLinkedMap * exampleLinkedMap
Definition doxygen.h:99
static Index & instance()
Definition index.cpp:106

References ClassMemberHighlight::All, FileMemberHighlight::All, ModuleMemberHighlight::All, NamespaceMemberHighlight::All, Config_getBool, Doxygen::exampleLinkedMap, FALSE, Index::instance(), and TRUE.

◆ renderMemberIndicesAsJs()

template<class T >
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 )

Definition at line 5436 of file index.cpp.

5441{
5442 // index items per category member lists
5443 bool firstMember=TRUE;
5444 for (std::size_t i=0;i<total;i++)
5445 {
5446 if (numDocumented(i)>0)
5447 {
5448 t << ",";
5449 if (firstMember)
5450 {
5451 t << "children:[";
5452 firstMember=FALSE;
5453 }
5454 t << "\n{text:\"" << convertToJSString(getInfo(i)->title) << "\",url:\""
5455 << convertToJSString(getInfo(i)->fname+Doxygen::htmlFileExtension) << "\"";
5456
5457 // Check if we have many members, then add sub entries per letter...
5458 // quick alphabetical index
5459 bool quickIndex = numDocumented(i)>maxItemsBeforeQuickIndex;
5460 if (quickIndex)
5461 {
5462 bool multiPageIndex=FALSE;
5463 if (numDocumented(i)>MAX_ITEMS_BEFORE_MULTIPAGE_INDEX)
5464 {
5465 multiPageIndex=TRUE;
5466 }
5467 t << ",children:[\n";
5468 bool firstLetter=TRUE;
5469 for (const auto &[letter,list] : getMemberList(i))
5470 {
5471 if (!firstLetter) t << ",\n";
5472 QCString ci(letter);
5473 QCString is(letterToLabel(ci));
5474 QCString anchor;
5476 QCString fullName = getInfo(i)->fname;
5477 if (!multiPageIndex || firstLetter)
5478 anchor=fullName+extension+"#index_";
5479 else // other pages of multi page index
5480 anchor=fullName+"_"+is+extension+"#index_";
5481 t << "{text:\"" << convertToJSString(ci) << "\",url:\""
5482 << convertToJSString(anchor+convertToId(is)) << "\"}";
5483 firstLetter=FALSE;
5484 }
5485 t << "]";
5486 }
5487 t << "}";
5488 }
5489 }
5490 if (!firstMember)
5491 {
5492 t << "]";
5493 }
5494}
static QCString htmlFileExtension
Definition doxygen.h:122
#define MAX_ITEMS_BEFORE_MULTIPAGE_INDEX
Definition index.cpp:55
const int maxItemsBeforeQuickIndex
Definition index.cpp:341
static QCString letterToLabel(const QCString &startLetter)
Definition index.cpp:2197
QCString convertToJSString(const QCString &s)
Definition util.cpp:4377
QCString convertToId(const QCString &s)
Definition util.cpp:4226

References convertToId(), convertToJSString(), FALSE, Doxygen::htmlFileExtension, letterToLabel(), MAX_ITEMS_BEFORE_MULTIPAGE_INDEX, maxItemsBeforeQuickIndex, and TRUE.

Referenced by renderQuickLinksAsJs().

◆ renderQuickLinksAsJs()

static bool renderQuickLinksAsJs ( std::ostream & t,
LayoutNavEntry * root,
bool first )
static

Definition at line 5496 of file index.cpp.

5497{
5498 int count=0;
5499 for (const auto &entry : root->children())
5500 {
5501 if (entry->visible() && quickLinkVisible(entry->kind())) count++;
5502 }
5503 if (count>0) // at least one item is visible
5504 {
5505 bool firstChild = TRUE;
5506 if (!first) t << ",";
5507 t << "children:[\n";
5508 for (const auto &entry : root->children())
5509 {
5510 if (entry->visible() && quickLinkVisible(entry->kind()))
5511 {
5512 if (!firstChild) t << ",\n";
5513 firstChild=FALSE;
5514 QCString url = entry->url();
5515 if (isURL(url)) url = "^" + url;
5516 t << "{text:\"" << convertToJSString(entry->title()) << "\",url:\""
5517 << convertToJSString(url) << "\"";
5518 bool hasChildren=FALSE;
5519 if (entry->kind()==LayoutNavEntry::ModuleMembers)
5520 {
5521 auto numDoc = [](std::size_t i) {
5523 };
5524 auto memList = [](std::size_t i) {
5526 };
5527 renderMemberIndicesAsJs(t,numDoc,memList,getMmhlInfo,static_cast<std::size_t>(ModuleMemberHighlight::Total));
5528 }
5529 if (entry->kind()==LayoutNavEntry::NamespaceMembers)
5530 {
5531 auto numDoc = [](std::size_t i) {
5533 };
5534 auto memList = [](std::size_t i) {
5536 };
5537 renderMemberIndicesAsJs(t,numDoc,memList,getNmhlInfo,static_cast<std::size_t>(NamespaceMemberHighlight::Total));
5538 }
5539 else if (entry->kind()==LayoutNavEntry::ClassMembers)
5540 {
5541 auto numDoc = [](std::size_t i) {
5543 };
5544 auto memList = [](std::size_t i) {
5546 };
5547 renderMemberIndicesAsJs(t,numDoc,memList,getCmhlInfo,static_cast<std::size_t>(ClassMemberHighlight::Total));
5548 }
5549 else if (entry->kind()==LayoutNavEntry::FileGlobals)
5550 {
5551 auto numDoc = [](std::size_t i) {
5553 };
5554 auto memList = [](std::size_t i) {
5556 };
5557 renderMemberIndicesAsJs(t,numDoc,memList,getFmhlInfo,static_cast<std::size_t>(FileMemberHighlight::Total));
5558 }
5559 else // recursive into child list
5560 {
5561 hasChildren = renderQuickLinksAsJs(t,entry.get(),FALSE);
5562 }
5563 if (hasChildren) t << "]";
5564 t << "}";
5565 }
5566 }
5567 }
5568 return count>0;
5569}
MemberIndexMap isClassIndexLetterUsed(ClassMemberHighlight::Enum e) const
Definition index.cpp:136
int numDocumentedClassMembers(ClassMemberHighlight::Enum e) const
Definition index.cpp:131
int numDocumentedModuleMembers(ModuleMemberHighlight::Enum e) const
Definition index.cpp:134
int numDocumentedNamespaceMembers(NamespaceMemberHighlight::Enum e) const
Definition index.cpp:133
int numDocumentedFileMembers(FileMemberHighlight::Enum e) const
Definition index.cpp:132
MemberIndexMap isFileIndexLetterUsed(FileMemberHighlight::Enum e) const
Definition index.cpp:141
MemberIndexMap isModuleIndexLetterUsed(ModuleMemberHighlight::Enum e) const
Definition index.cpp:151
MemberIndexMap isNamespaceIndexLetterUsed(NamespaceMemberHighlight::Enum e) const
Definition index.cpp:146
static bool quickLinkVisible(LayoutNavEntry::Kind kind)
Definition htmlgen.cpp:2707
static bool renderQuickLinksAsJs(std::ostream &t, LayoutNavEntry *root, bool first)
Definition index.cpp:5496
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)
Definition index.cpp:5436
static const FmhlInfo * getFmhlInfo(size_t hl)
Definition index.cpp:3243
static const MmhlInfo * getMmhlInfo(size_t hl)
Definition index.cpp:3569
static const NmhlInfo * getNmhlInfo(size_t hl)
Definition index.cpp:3404
static const CmhlInfo * getCmhlInfo(size_t hl)
Definition index.cpp:3076
const LayoutNavEntryList & children() const
Definition layout.h:209
bool isURL(const QCString &url)
Checks whether the given url starts with a supported protocol.
Definition util.cpp:6245

References LayoutNavEntry::children(), convertToJSString(), FALSE, getCmhlInfo(), getFmhlInfo(), getMmhlInfo(), getNmhlInfo(), Index::instance(), Index::isClassIndexLetterUsed(), Index::isFileIndexLetterUsed(), Index::isModuleIndexLetterUsed(), Index::isNamespaceIndexLetterUsed(), isURL(), Index::numDocumentedClassMembers(), Index::numDocumentedFileMembers(), Index::numDocumentedModuleMembers(), Index::numDocumentedNamespaceMembers(), quickLinkVisible(), renderMemberIndicesAsJs(), renderQuickLinksAsJs(), ClassMemberHighlight::Total, FileMemberHighlight::Total, ModuleMemberHighlight::Total, NamespaceMemberHighlight::Total, and TRUE.

Referenced by renderQuickLinksAsJs(), and writeMenuData().

◆ startFile()

void startFile ( OutputList & ol,
const QCString & name,
const QCString & manName,
const QCString & title,
HighlightedItem hli,
bool additionalIndices,
const QCString & altSidebarName,
int hierarchyLevel )

Definition at line 402 of file index.cpp.

405{
406 bool disableIndex = Config_getBool(DISABLE_INDEX);
407 ol.startFile(name,manName,title,hierarchyLevel);
409 if (!disableIndex)
410 {
411 ol.writeQuickLinks(hli,name);
412 }
413 if (!additionalIndices)
414 {
415 ol.endQuickIndices();
416 }
417 ol.writeSplitBar(!altSidebarName.isEmpty() ? altSidebarName : name);
418 ol.writeSearchInfo();
419}
void writeSearchInfo()
Definition outputlist.h:398
void writeSplitBar(const QCString &name)
Definition outputlist.h:607
void startFile(const QCString &name, const QCString &manName, const QCString &title, int hierarchyLevel=0)
void startQuickIndices()
Definition outputlist.h:603
void endQuickIndices()
Definition outputlist.h:605
void writeQuickLinks(HighlightedItem hli, const QCString &file)
Definition outputlist.h:613

References Config_getBool, OutputList::endQuickIndices(), QCString::isEmpty(), OutputList::startFile(), OutputList::startQuickIndices(), OutputList::writeQuickLinks(), OutputList::writeSearchInfo(), and OutputList::writeSplitBar().

Referenced by generateExampleDocs(), writeAlphabeticalExceptionIndex(), writeAlphabeticalIndex(), writeAlphabeticalInterfaceIndex(), writeAlphabeticalStructIndex(), writeAnnotatedIndexGeneric(), writeConceptIndex(), ClassDefImpl::writeDocumentation(), ConceptDefImpl::writeDocumentation(), DirDefImpl::writeDocumentation(), DirRelation::writeDocumentation(), FileDefImpl::writeDocumentation(), GroupDefImpl::writeDocumentation(), ModuleDefImpl::writeDocumentation(), NamespaceDefImpl::writeDocumentation(), PageDefImpl::writeDocumentation(), MemberList::writeDocumentationPage(), writeExampleIndex(), writeFileIndex(), writeGraphicalClassHierarchy(), writeGraphicalExceptionHierarchy(), writeGraphicalInterfaceHierarchy(), writeGraphInfo(), writeHierarchicalExceptionIndex(), writeHierarchicalIndex(), writeHierarchicalInterfaceIndex(), ClassDefImpl::writeMemberList(), writeModuleIndex(), writeNamespaceIndex(), writePageIndex(), FileDefImpl::writeSourceHeader(), writeTopicIndex(), and writeUserGroupStubPage().

◆ startIndexHierarchy()

◆ startQuickIndexItem()

static void startQuickIndexItem ( OutputList & ol,
const QCString & l,
bool hl,
bool ,
bool & first )
static

Definition at line 366 of file index.cpp.

368{
369 first=FALSE;
370 ol.writeString(" <li");
371 if (hl) ol.writeString(" class=\"current\"");
372 ol.writeString("><a ");
373 ol.writeString("href=\"");
374 ol.writeString(l);
375 ol.writeString("\">");
376 ol.writeString("<span>");
377}

References FALSE, and OutputList::writeString().

Referenced by writeClassMemberIndexFiltered(), writeFileMemberIndexFiltered(), writeModuleMemberIndexFiltered(), writeNamespaceMemberIndexFiltered(), and writeQuickMemberIndex().

◆ startQuickIndexList()

static void startQuickIndexList ( OutputList & ol,
bool letterTabs = FALSE )
static

Definition at line 347 of file index.cpp.

348{
349 if (letterTabs)
350 {
351 ol.writeString(" <div id=\"navrow4\" class=\"tabs3\">\n");
352 }
353 else
354 {
355 ol.writeString(" <div id=\"navrow3\" class=\"tabs2\">\n");
356 }
357 ol.writeString(" <ul class=\"tablist\">\n");
358}

References FALSE, and OutputList::writeString().

Referenced by writeClassMemberIndexFiltered(), writeFileMemberIndexFiltered(), writeModuleMemberIndexFiltered(), writeNamespaceMemberIndexFiltered(), and writeQuickMemberIndex().

◆ startTitle()

void startTitle ( OutputList & ol,
const QCString & fileName,
const DefinitionMutable * def )

Definition at line 386 of file index.cpp.

387{
389 if (def) def->writeSummaryLinks(ol);
390 ol.startTitleHead(fileName);
393}
virtual void writeSummaryLinks(OutputList &) const =0
void startTitleHead(const QCString &fileName)
Definition outputlist.h:404
void startHeaderSection()
Definition outputlist.h:466

References OutputList::disable(), Man, OutputList::pushGeneratorState(), OutputList::startHeaderSection(), OutputList::startTitleHead(), and DefinitionMutable::writeSummaryLinks().

Referenced by generateExampleDocs(), writeAlphabeticalExceptionIndex(), writeAlphabeticalIndex(), writeAlphabeticalInterfaceIndex(), writeAlphabeticalStructIndex(), writeAnnotatedIndexGeneric(), writeConceptIndex(), ClassDefImpl::writeDocumentation(), ConceptDefImpl::writeDocumentation(), DirDefImpl::writeDocumentation(), FileDefImpl::writeDocumentation(), NamespaceDefImpl::writeDocumentation(), writeExampleIndex(), writeFileIndex(), writeGraphicalClassHierarchy(), writeGraphicalExceptionHierarchy(), writeGraphicalInterfaceHierarchy(), writeGraphInfo(), writeHierarchicalExceptionIndex(), writeHierarchicalIndex(), writeHierarchicalInterfaceIndex(), ClassDefImpl::writeMemberList(), writeModuleIndex(), writeNamespaceIndex(), writePageIndex(), FileDefImpl::writeSourceHeader(), writeTopicIndex(), and writeUserGroupStubPage().

◆ writeAlphabeticalClassList()

static void writeAlphabeticalClassList ( OutputList & ol,
ClassDef::CompoundType ct,
int  )
static

Definition at line 2246 of file index.cpp.

2247{
2248 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
2249
2250 // What starting letters are used
2251 UsedIndexLetters indexLettersUsed;
2252
2253 // first count the number of headers
2254 for (const auto &cd : *Doxygen::classLinkedMap)
2255 {
2256 if (sliceOpt && cd->compoundType() != ct)
2257 continue;
2258 if (cd->isLinkableInProject() && !cd->isImplicitTemplateInstance())
2259 {
2260 if (cd->getLanguage()==SrcLangExt::VHDL && !(VhdlDocGen::convert(cd->protection())==VhdlDocGen::ENTITYCLASS ))// no architecture
2261 continue;
2262
2263 // get the first UTF8 character (after the part that should be ignored)
2264 int index = getPrefixIndex(cd->className());
2265 std::string letter = getUTF8CharAt(cd->className().str(),index);
2266 if (!letter.empty())
2267 {
2268 indexLettersUsed.insert(convertUTF8ToUpper(letter));
2269 }
2270 }
2271 }
2272
2273 // write quick link index (row of letters)
2274 QCString alphaLinks = "<div class=\"qindex\">";
2275 bool first=true;
2276 for (const auto &letter : indexLettersUsed)
2277 {
2278 if (!first) alphaLinks += "&#160;|&#160;";
2279 first=false;
2280 QCString li = letterToLabel(letter.c_str());
2281 alphaLinks += "<a class=\"qindex\" href=\"#letter_" +
2282 li + "\">" +
2283 QCString(letter) + "</a>";
2284 }
2285 alphaLinks += "</div>\n";
2286 ol.writeString(alphaLinks);
2287
2288 std::map<std::string, std::vector<const ClassDef*> > classesByLetter;
2289
2290 // fill the columns with the class list (row elements in each column,
2291 // expect for the columns with number >= itemsInLastRow, which get one
2292 // item less.
2293 for (const auto &cd : *Doxygen::classLinkedMap)
2294 {
2295 if (sliceOpt && cd->compoundType() != ct)
2296 continue;
2297 if (cd->getLanguage()==SrcLangExt::VHDL && !(VhdlDocGen::convert(cd->protection())==VhdlDocGen::ENTITYCLASS ))// no architecture
2298 continue;
2299
2300 if (cd->isLinkableInProject() && !cd->isImplicitTemplateInstance())
2301 {
2302 QCString className = cd->className();
2303 int index = getPrefixIndex(className);
2304 std::string letter = getUTF8CharAt(className.str(),index);
2305 if (!letter.empty())
2306 {
2307 letter = convertUTF8ToUpper(letter);
2308 auto it = classesByLetter.find(letter);
2309 if (it!=classesByLetter.end()) // add class to the existing list
2310 {
2311 it->second.push_back(cd.get());
2312 }
2313 else // new entry
2314 {
2315 classesByLetter.emplace(letter, std::vector<const ClassDef*>({ cd.get() }));
2316 }
2317 }
2318 }
2319 }
2320
2321 // sort the class lists per letter while ignoring the prefix
2322 for (auto &[letter,list] : classesByLetter)
2323 {
2324 std::stable_sort(list.begin(), list.end(),
2325 [](const auto &c1,const auto &c2)
2326 {
2327 QCString n1 = c1->className();
2328 QCString n2 = c2->className();
2329 return qstricmp_sort(n1.data()+getPrefixIndex(n1), n2.data()+getPrefixIndex(n2))<0;
2330 });
2331 }
2332
2333 // generate table
2334 if (!classesByLetter.empty())
2335 {
2336 ol.writeString("<div class=\"classindex\">\n");
2337 int counter=0;
2338 for (const auto &cl : classesByLetter)
2339 {
2340 QCString parity = (counter++%2)==0 ? "even" : "odd";
2341 ol.writeString("<dl class=\"classindex " + parity + "\">\n");
2342
2343 // write character heading
2344 ol.writeString("<dt class=\"alphachar\">");
2345 QCString s = letterToLabel(cl.first.c_str());
2346 ol.writeString("<a id=\"letter_");
2347 ol.writeString(s);
2348 ol.writeString("\" name=\"letter_");
2349 ol.writeString(s);
2350 ol.writeString("\">");
2351 ol.writeString(cl.first.c_str());
2352 ol.writeString("</a>");
2353 ol.writeString("</dt>\n");
2354
2355 // write class links
2356 for (const auto &cd : cl.second)
2357 {
2358 ol.writeString("<dd>");
2359 QCString namesp,cname;
2360 extractNamespaceName(cd->name(),cname,namesp);
2361 QCString nsDispName;
2362 SrcLangExt lang = cd->getLanguage();
2364 if (sep!="::")
2365 {
2366 nsDispName=substitute(namesp,"::",sep);
2367 cname=substitute(cname,"::",sep);
2368 }
2369 else
2370 {
2371 nsDispName=namesp;
2372 }
2373
2374 ol.writeObjectLink(cd->getReference(),
2375 cd->getOutputFileBase(),cd->anchor(),cname);
2376 if (!namesp.isEmpty())
2377 {
2378 ol.writeString(" (");
2379 NamespaceDef *nd = getResolvedNamespace(namesp);
2380 if (nd && nd->isLinkable())
2381 {
2383 nd->getOutputFileBase(),QCString(),nsDispName);
2384 }
2385 else
2386 {
2387 ol.docify(nsDispName);
2388 }
2389 ol.writeString(")");
2390 }
2391 ol.writeString("</dd>");
2392 }
2393
2394 ol.writeString("</dl>\n");
2395 }
2396 ol.writeString("</div>\n");
2397 }
2398}
virtual bool isLinkable() const =0
virtual QCString getReference() const =0
virtual QCString getOutputFileBase() const =0
An abstract interface of a namespace symbol.
void writeObjectLink(const QCString &ref, const QCString &file, const QCString &anchor, const QCString &name)
Definition outputlist.h:440
void docify(const QCString &s)
Definition outputlist.h:438
const std::string & str() const
Definition qcstring.h:526
static VhdlClasses convert(Protection prot)
Definition vhdldocgen.h:80
std::set< std::string > UsedIndexLetters
Definition index.cpp:2243
NamespaceDef * getResolvedNamespace(const QCString &name)
QCString substitute(const QCString &s, const QCString &src, const QCString &dst)
substitute all occurrences of src in s by dst
Definition qcstring.cpp:477
SrcLangExt
Language as given by extension.
Definition types.h:42
std::string convertUTF8ToUpper(const std::string &input)
Converts the input string into a upper case version, also taking into account non-ASCII characters th...
Definition utf8.cpp:192
std::string getUTF8CharAt(const std::string &input, size_t pos)
Returns the UTF8 character found at byte position pos in the input string.
Definition utf8.cpp:127
void extractNamespaceName(const QCString &scopeName, QCString &className, QCString &namespaceName, bool allowEmptyClass)
Definition util.cpp:4051
QCString getLanguageSpecificSeparator(SrcLangExt lang, bool classScope)
Returns the scope separator to use given the programming language lang.
Definition util.cpp:6229
int getPrefixIndex(const QCString &name)
Definition util.cpp:3590

References Doxygen::classLinkedMap, Config_getBool, VhdlDocGen::convert(), convertUTF8ToUpper(), OutputList::docify(), VhdlDocGen::ENTITYCLASS, extractNamespaceName(), getLanguageSpecificSeparator(), Definition::getOutputFileBase(), getPrefixIndex(), Definition::getReference(), getResolvedNamespace(), getUTF8CharAt(), QCString::isEmpty(), Definition::isLinkable(), letterToLabel(), QCString::str(), substitute(), VHDL, OutputList::writeObjectLink(), and OutputList::writeString().

Referenced by writeAlphabeticalExceptionIndex(), writeAlphabeticalIndex(), writeAlphabeticalInterfaceIndex(), and writeAlphabeticalStructIndex().

◆ writeAlphabeticalExceptionIndex()

static void writeAlphabeticalExceptionIndex ( OutputList & ol)
static

Definition at line 2489 of file index.cpp.

2490{
2491 if (Index::instance().numAnnotatedExceptions()==0) return;
2492 ol.pushGeneratorState();
2494 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ExceptionIndex);
2495 QCString title = lne ? lne->title() : theTranslator->trExceptionIndex();
2496 bool addToIndex = lne==nullptr || lne->visible();
2497
2498 startFile(ol,"exceptions",QCString(),title,HighlightedItem::Exceptions);
2499
2500 startTitle(ol,QCString());
2501 ol.parseText(title);
2502 endTitle(ol,QCString(),QCString());
2503
2504 if (addToIndex)
2505 {
2506 Doxygen::indexList->addContentsItem(FALSE,title,QCString(),"exceptions",QCString(),FALSE,TRUE);
2507 }
2508
2509 ol.startContents();
2510 writeAlphabeticalClassList(ol, ClassDef::Exception, Index::instance().numAnnotatedExceptions());
2511 endFile(ol); // contains ol.endContents()
2512
2513 ol.popGeneratorState();
2514}
@ Exception
Definition classdef.h:115
LayoutNavEntry * rootNavEntry() const
returns the (invisible) root of the navigation tree.
Definition layout.cpp:1434
void startContents()
Definition outputlist.h:617
void parseText(const QCString &textStr)
void startTitle(OutputList &ol, const QCString &fileName, const DefinitionMutable *def)
Definition index.cpp:386
void endTitle(OutputList &ol, const QCString &fileName, const QCString &name)
Definition index.cpp:395
void startFile(OutputList &ol, const QCString &name, const QCString &manName, const QCString &title, HighlightedItem hli, bool additionalIndices, const QCString &altSidebarName, int hierarchyLevel)
Definition index.cpp:402
static void writeAlphabeticalClassList(OutputList &ol, ClassDef::CompoundType ct, int)
Definition index.cpp:2246
Base class for the layout of a navigation item at the top of the HTML pages.
Definition layout.h:140
QCString title() const
Definition layout.h:199
bool visible()
Definition layout.h:203
LayoutNavEntry * find(LayoutNavEntry::Kind k, const QCString &file=QCString()) const
Definition layout.cpp:122

References OutputList::disableAllBut(), endFile(), endTitle(), ClassDef::Exception, Exceptions, FALSE, LayoutNavEntry::find(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), startTitle(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), and writeAlphabeticalClassList().

Referenced by writeIndexHierarchyEntries().

◆ writeAlphabeticalIndex()

static void writeAlphabeticalIndex ( OutputList & ol)
static

Definition at line 2402 of file index.cpp.

2403{
2404 if (Index::instance().numAnnotatedClasses()==0) return;
2405 ol.pushGeneratorState();
2407 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ClassIndex);
2408 QCString title = lne ? lne->title() : theTranslator->trCompoundIndex();
2409 bool addToIndex = lne==nullptr || lne->visible();
2410
2411 startFile(ol,"classes",QCString(),title,HighlightedItem::Classes);
2412
2413 startTitle(ol,QCString());
2414 ol.parseText(title);
2415 endTitle(ol,QCString(),QCString());
2416
2417 if (addToIndex)
2418 {
2419 Doxygen::indexList->addContentsItem(FALSE,title,QCString(),"classes",QCString(),FALSE,TRUE);
2420 }
2421
2422 ol.startContents();
2423 writeAlphabeticalClassList(ol, ClassDef::Class, Index::instance().numAnnotatedClasses());
2424 endFile(ol); // contains ol.endContents()
2425
2426 ol.popGeneratorState();
2427}

References ClassDef::Class, Classes, OutputList::disableAllBut(), endFile(), endTitle(), FALSE, LayoutNavEntry::find(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), startTitle(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), and writeAlphabeticalClassList().

Referenced by writeIndexHierarchyEntries().

◆ writeAlphabeticalInterfaceIndex()

static void writeAlphabeticalInterfaceIndex ( OutputList & ol)
static

Definition at line 2431 of file index.cpp.

2432{
2433 if (Index::instance().numAnnotatedInterfaces()==0) return;
2434 ol.pushGeneratorState();
2436 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::InterfaceIndex);
2437 QCString title = lne ? lne->title() : theTranslator->trInterfaceIndex();
2438 bool addToIndex = lne==nullptr || lne->visible();
2439
2440 startFile(ol,"interfaces",QCString(),title,HighlightedItem::Interfaces);
2441
2442 startTitle(ol,QCString());
2443 ol.parseText(title);
2444 endTitle(ol,QCString(),QCString());
2445
2446 if (addToIndex)
2447 {
2448 Doxygen::indexList->addContentsItem(FALSE,title,QCString(),"interfaces",QCString(),FALSE,TRUE);
2449 }
2450
2451 ol.startContents();
2452 writeAlphabeticalClassList(ol, ClassDef::Interface, Index::instance().numAnnotatedInterfaces());
2453 endFile(ol); // contains ol.endContents()
2454
2455 ol.popGeneratorState();
2456}
@ Interface
Definition classdef.h:112

References OutputList::disableAllBut(), endFile(), endTitle(), FALSE, LayoutNavEntry::find(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), ClassDef::Interface, Interfaces, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), startTitle(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), and writeAlphabeticalClassList().

Referenced by writeIndexHierarchyEntries().

◆ writeAlphabeticalStructIndex()

static void writeAlphabeticalStructIndex ( OutputList & ol)
static

Definition at line 2460 of file index.cpp.

2461{
2462 if (Index::instance().numAnnotatedStructs()==0) return;
2463 ol.pushGeneratorState();
2465 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::StructIndex);
2466 QCString title = lne ? lne->title() : theTranslator->trStructIndex();
2467 bool addToIndex = lne==nullptr || lne->visible();
2468
2469 startFile(ol,"structs",QCString(),title,HighlightedItem::Structs);
2470
2471 startTitle(ol,QCString());
2472 ol.parseText(title);
2473 endTitle(ol,QCString(),QCString());
2474
2475 if (addToIndex)
2476 {
2477 Doxygen::indexList->addContentsItem(FALSE,title,QCString(),"structs",QCString(),FALSE,TRUE);
2478 }
2479
2480 ol.startContents();
2481 writeAlphabeticalClassList(ol, ClassDef::Struct, Index::instance().numAnnotatedStructs());
2482 endFile(ol); // contains ol.endContents()
2483
2484 ol.popGeneratorState();
2485}

References OutputList::disableAllBut(), endFile(), endTitle(), FALSE, LayoutNavEntry::find(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), startTitle(), ClassDef::Struct, Structs, theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), and writeAlphabeticalClassList().

Referenced by writeIndexHierarchyEntries().

◆ writeAnnotatedClassList()

static void writeAnnotatedClassList ( OutputList & ol,
ClassDef::CompoundType ct )
static

Definition at line 2118 of file index.cpp.

2119{
2120 //LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ClassList);
2121 //bool addToIndex = lne==nullptr || lne->visible();
2122 bool first=TRUE;
2123
2124 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
2125
2126 for (const auto &cd : *Doxygen::classLinkedMap)
2127 {
2128 if (cd->getLanguage()==SrcLangExt::VHDL &&
2129 (VhdlDocGen::convert(cd->protection())==VhdlDocGen::PACKAGECLASS ||
2131 ) // no architecture
2132 {
2133 continue;
2134 }
2135 if (first)
2136 {
2137 ol.startIndexList();
2138 first=FALSE;
2139 }
2140
2141 if (sliceOpt && cd->compoundType() != ct)
2142 {
2143 continue;
2144 }
2145
2146 ol.pushGeneratorState();
2147 if (cd->isEmbeddedInOuterScope())
2148 {
2152 }
2153 if (cd->isLinkableInProject() && !cd->isImplicitTemplateInstance())
2154 {
2155 ol.startIndexKey();
2156 if (cd->getLanguage()==SrcLangExt::VHDL)
2157 {
2159 ol.docify(prot);
2160 ol.writeString(" ");
2161 }
2162 ol.writeObjectLink(QCString(),cd->getOutputFileBase(),cd->anchor(),cd->displayName());
2163 ol.endIndexKey();
2164 bool hasBrief = !cd->briefDescription().isEmpty();
2165 ol.startIndexValue(hasBrief);
2166 if (hasBrief)
2167 {
2168 ol.generateDoc(
2169 cd->briefFile(),cd->briefLine(),
2170 cd.get(),nullptr,
2171 cd->briefDescription(TRUE),
2172 FALSE, // indexWords
2173 FALSE, // isExample
2174 QCString(), // example name
2175 TRUE, // single line
2176 TRUE, // link from index
2177 Config_getBool(MARKDOWN_SUPPORT)
2178 );
2179 }
2180 ol.endIndexValue(cd->getOutputFileBase(),hasBrief);
2181
2182 //if (addToIndex)
2183 //{
2184 // addMembersToIndex(cd,LayoutDocManager::Class,cd->displayName(),cd->anchor());
2185 //}
2186 }
2187 ol.popGeneratorState();
2188 }
2189 if (!first) ol.endIndexList();
2190}
void endIndexValue(const QCString &name, bool b)
Definition outputlist.h:428
void startIndexKey()
Definition outputlist.h:422
void endIndexKey()
Definition outputlist.h:424
void generateDoc(const QCString &fileName, int startLine, const Definition *ctx, const MemberDef *md, const QCString &docStr, bool indexWords, bool isExample, const QCString &exampleName, bool singleLine, bool linkFromIndex, bool markdownSupport)
void startIndexValue(bool b)
Definition outputlist.h:426
static QCString getProtectionName(int prot)

References Doxygen::classLinkedMap, Config_getBool, VhdlDocGen::convert(), OutputList::disable(), Docbook, OutputList::docify(), OutputList::endIndexKey(), OutputList::endIndexList(), OutputList::endIndexValue(), FALSE, OutputList::generateDoc(), VhdlDocGen::getProtectionName(), Latex, VhdlDocGen::PACKAGECLASS, VhdlDocGen::PACKBODYCLASS, OutputList::popGeneratorState(), OutputList::pushGeneratorState(), RTF, OutputList::startIndexKey(), OutputList::startIndexList(), OutputList::startIndexValue(), TRUE, VHDL, OutputList::writeObjectLink(), and OutputList::writeString().

Referenced by writeAnnotatedIndexGeneric().

◆ writeAnnotatedExceptionIndex()

static void writeAnnotatedExceptionIndex ( OutputList & ol)
static

Definition at line 2660 of file index.cpp.

2661{
2662 const auto &index = Index::instance();
2664 AnnotatedIndexContext(index.numAnnotatedExceptions(),index.numAnnotatedExceptionsPrinted(),
2665 LayoutNavEntry::ExceptionList,LayoutNavEntry::Exceptions,
2666 theTranslator->trExceptionList(),theTranslator->trExceptionListDescription(),
2668 "annotatedexceptions",
2670}
static void writeAnnotatedIndexGeneric(OutputList &ol, const AnnotatedIndexContext ctx)
Definition index.cpp:2543
@ AnnotatedExceptions
Definition index.h:76

References AnnotatedExceptions, ClassDef::Exception, Index::instance(), theTranslator, and writeAnnotatedIndexGeneric().

Referenced by writeIndexHierarchyEntries().

◆ writeAnnotatedIndex()

static void writeAnnotatedIndex ( OutputList & ol)
static

Definition at line 2618 of file index.cpp.

2619{
2620 const auto &index = Index::instance();
2622 AnnotatedIndexContext(index.numAnnotatedClasses(),index.numAnnotatedClassesPrinted(),
2623 LayoutNavEntry::ClassList,LayoutNavEntry::Classes,
2624 theTranslator->trCompoundList(),theTranslator->trCompoundListDescription(),
2626 "annotated",
2628}
@ AnnotatedClasses
Definition index.h:73

References AnnotatedClasses, ClassDef::Class, Index::instance(), theTranslator, and writeAnnotatedIndexGeneric().

Referenced by writeIndexHierarchyEntries().

◆ writeAnnotatedIndexGeneric()

static void writeAnnotatedIndexGeneric ( OutputList & ol,
const AnnotatedIndexContext ctx )
static

Definition at line 2543 of file index.cpp.

2544{
2545 //printf("writeAnnotatedIndex: count=%d printed=%d\n",
2546 // annotatedClasses,annotatedClassesPrinted);
2547 if (ctx.numAnnotated==0) return;
2548
2549 ol.pushGeneratorState();
2551 if (ctx.numPrinted==0)
2552 {
2555 }
2557 if (lne==nullptr) lne = LayoutDocManager::instance().rootNavEntry()->find(ctx.fallbackKind); // fall back
2558 QCString title = lne ? lne->title() : ctx.listDefaultTitleText;
2559 bool addToIndex = lne==nullptr || lne->visible();
2560
2561 startFile(ol,ctx.fileBaseName,QCString(),title,ctx.hiItem);
2562
2563 startTitle(ol,QCString());
2564 ol.parseText(title);
2565 endTitle(ol,QCString(),QCString());
2566
2567 ol.startContents();
2568
2569 ol.startTextBlock();
2570 ol.parseText(lne ? lne->intro() : ctx.listDefaultIntroText);
2571 ol.endTextBlock();
2572
2573 // ---------------
2574 // Linear class index for Latex/RTF
2575 // ---------------
2576 ol.pushGeneratorState();
2578 Doxygen::indexList->disable();
2579
2581
2582 Doxygen::indexList->enable();
2583 ol.popGeneratorState();
2584
2585 // ---------------
2586 // Hierarchical class index for HTML
2587 // ---------------
2588 ol.pushGeneratorState();
2590
2591 {
2592 if (addToIndex)
2593 {
2594 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),ctx.fileBaseName,QCString(),TRUE,TRUE);
2595 Doxygen::indexList->incContentsDepth();
2596 }
2597 FTVHelp ftv(false);
2600 TextStream t;
2601 ftv.generateTreeViewInline(t);
2602 ol.writeString(t.str().c_str());
2603 if (addToIndex)
2604 {
2605 Doxygen::indexList->decContentsDepth();
2606 }
2607 }
2608
2609 ol.popGeneratorState();
2610 // ------
2611
2612 endFile(ol); // contains ol.endContents()
2613 ol.popGeneratorState();
2614}
A class that generates a dynamic tree view side panel.
Definition ftvhelp.h:41
void endTextBlock(bool paraBreak=FALSE)
Definition outputlist.h:671
void startTextBlock(bool dense=FALSE)
Definition outputlist.h:669
Text streaming class that buffers data.
Definition textstream.h:36
std::string str() const
Return the contents of the buffer as a std::string object.
Definition textstream.h:229
static void writeAnnotatedClassList(OutputList &ol, ClassDef::CompoundType ct)
Definition index.cpp:2118
static void writeClassTreeInsideNamespace(const NamespaceLinkedRefMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex, ClassDef::CompoundType ct)
Definition index.cpp:1969
static void writeClassTree(const ListType &cl, FTVHelp *ftv, bool addToIndex, bool globalOnly, ClassDef::CompoundType ct)
Definition index.cpp:1690
const LayoutNavEntry::Kind fallbackKind
Definition index.cpp:2535
const ClassDef::CompoundType compoundType
Definition index.cpp:2538
const HighlightedItem hiItem
Definition index.cpp:2540
const QCString fileBaseName
Definition index.cpp:2539
const LayoutNavEntry::Kind listKind
Definition index.cpp:2534
const QCString listDefaultTitleText
Definition index.cpp:2536
const int numAnnotated
Definition index.cpp:2532
const QCString listDefaultIntroText
Definition index.cpp:2537
QCString intro() const
Definition layout.h:200

References Doxygen::classLinkedMap, AnnotatedIndexContext::compoundType, OutputList::disable(), OutputList::disableAllBut(), endFile(), OutputList::endTextBlock(), endTitle(), AnnotatedIndexContext::fallbackKind, AnnotatedIndexContext::fileBaseName, LayoutNavEntry::find(), FTVHelp::generateTreeViewInline(), AnnotatedIndexContext::hiItem, Html, Doxygen::indexList, LayoutDocManager::instance(), LayoutNavEntry::intro(), Latex, AnnotatedIndexContext::listDefaultIntroText, AnnotatedIndexContext::listDefaultTitleText, AnnotatedIndexContext::listKind, Man, Doxygen::namespaceLinkedMap, AnnotatedIndexContext::numAnnotated, AnnotatedIndexContext::numPrinted, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), RTF, OutputList::startContents(), startFile(), OutputList::startTextBlock(), startTitle(), TextStream::str(), LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), writeAnnotatedClassList(), writeClassTree(), writeClassTreeInsideNamespace(), and OutputList::writeString().

Referenced by writeAnnotatedExceptionIndex(), writeAnnotatedIndex(), writeAnnotatedInterfaceIndex(), and writeAnnotatedStructIndex().

◆ writeAnnotatedInterfaceIndex()

static void writeAnnotatedInterfaceIndex ( OutputList & ol)
static

Definition at line 2632 of file index.cpp.

2633{
2634 const auto &index = Index::instance();
2636 AnnotatedIndexContext(index.numAnnotatedInterfaces(),index.numAnnotatedInterfacesPrinted(),
2637 LayoutNavEntry::InterfaceList,LayoutNavEntry::Interfaces,
2638 theTranslator->trInterfaceList(),theTranslator->trInterfaceListDescription(),
2640 "annotatedinterfaces",
2642}
@ AnnotatedInterfaces
Definition index.h:74

References AnnotatedInterfaces, Index::instance(), ClassDef::Interface, theTranslator, and writeAnnotatedIndexGeneric().

Referenced by writeIndexHierarchyEntries().

◆ writeAnnotatedStructIndex()

static void writeAnnotatedStructIndex ( OutputList & ol)
static

Definition at line 2646 of file index.cpp.

2647{
2648 const auto &index = Index::instance();
2650 AnnotatedIndexContext(index.numAnnotatedStructs(),index.numAnnotatedStructsPrinted(),
2651 LayoutNavEntry::StructList,LayoutNavEntry::Structs,
2652 theTranslator->trStructList(),theTranslator->trStructListDescription(),
2654 "annotatedstructs",
2656}
@ AnnotatedStructs
Definition index.h:75

References AnnotatedStructs, Index::instance(), ClassDef::Struct, theTranslator, and writeAnnotatedIndexGeneric().

Referenced by writeIndexHierarchyEntries().

◆ writeClassHierarchy()

static void writeClassHierarchy ( OutputList & ol,
FTVHelp * ftv,
bool addToIndex,
ClassDef::CompoundType ct )
static

Definition at line 1054 of file index.cpp.

1055{
1056 ClassDefSet visitedClasses;
1057 if (ftv)
1058 {
1059 ol.pushGeneratorState();
1061 }
1062 bool started=FALSE;
1063 writeClassTreeForList(ol,*Doxygen::classLinkedMap,started,ftv,addToIndex,ct,visitedClasses);
1064 writeClassTreeForList(ol,*Doxygen::hiddenClassLinkedMap,started,ftv,addToIndex,ct,visitedClasses);
1065 if (started)
1066 {
1067 endIndexHierarchy(ol,0);
1068 if (addToIndex)
1069 {
1070 Doxygen::indexList->decContentsDepth();
1071 }
1072 }
1073 if (ftv)
1074 {
1075 ol.popGeneratorState();
1076 }
1077}
std::unordered_set< const ClassDef * > ClassDefSet
Definition classdef.h:95
static void endIndexHierarchy(OutputList &ol, int level)
Definition index.cpp:323
static void writeClassTreeForList(OutputList &ol, const ClassLinkedMap &cl, bool &started, FTVHelp *ftv, bool addToIndex, ClassDef::CompoundType ct, ClassDefSet &visitedClasses)
Definition index.cpp:955

References Doxygen::classLinkedMap, OutputList::disable(), endIndexHierarchy(), FALSE, Doxygen::hiddenClassLinkedMap, Html, Doxygen::indexList, OutputList::popGeneratorState(), OutputList::pushGeneratorState(), and writeClassTreeForList().

Referenced by writeHierarchicalExceptionIndex(), writeHierarchicalIndex(), and writeHierarchicalInterfaceIndex().

◆ writeClassLinkForMember()

static void writeClassLinkForMember ( OutputList & ol,
const MemberDef * md,
const QCString & separator,
QCString & prevClassName )
static

Definition at line 2673 of file index.cpp.

2675{
2676 const ClassDef *cd=md->getClassDef();
2677 if ( cd && prevClassName!=cd->displayName())
2678 {
2679 ol.writeString(separator);
2681 cd->displayName());
2682 prevClassName = cd->displayName();
2683 }
2684}
A abstract class representing of a compound symbol.
Definition classdef.h:104
virtual QCString anchor() const =0
virtual QCString displayName(bool includeScope=TRUE) const =0
virtual const ClassDef * getClassDef() const =0

References Definition::anchor(), Definition::displayName(), MemberDef::getClassDef(), Definition::getOutputFileBase(), Definition::getReference(), OutputList::writeObjectLink(), and OutputList::writeString().

Referenced by writeMemberList().

◆ writeClassMemberIndex()

static void writeClassMemberIndex ( OutputList & ol)
static

Definition at line 3206 of file index.cpp.

3207{
3208 const auto &index = Index::instance();
3209 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ClassMembers);
3210 bool addToIndex = lne==nullptr || lne->visible();
3211
3212 if (index.numDocumentedClassMembers(ClassMemberHighlight::All)>0 && addToIndex)
3213 {
3214 Doxygen::indexList->addContentsItem(TRUE,lne ? lne->title() : theTranslator->trCompoundMembers(),QCString(),"functions",QCString());
3215 Doxygen::indexList->incContentsDepth();
3216 }
3226 if (index.numDocumentedClassMembers(ClassMemberHighlight::All)>0 && addToIndex)
3227 {
3228 Doxygen::indexList->decContentsDepth();
3229 }
3230
3231}
static void writeClassMemberIndexFiltered(OutputList &ol, ClassMemberHighlight::Enum hl)
Definition index.cpp:3098

References ClassMemberHighlight::All, ClassMemberHighlight::Enums, ClassMemberHighlight::EnumValues, ClassMemberHighlight::Events, LayoutNavEntry::find(), ClassMemberHighlight::Functions, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), ClassMemberHighlight::Properties, ClassMemberHighlight::Related, LayoutDocManager::rootNavEntry(), theTranslator, LayoutNavEntry::title(), TRUE, ClassMemberHighlight::Typedefs, ClassMemberHighlight::Variables, LayoutNavEntry::visible(), and writeClassMemberIndexFiltered().

Referenced by writeIndexHierarchyEntries().

◆ writeClassMemberIndexFiltered()

static void writeClassMemberIndexFiltered ( OutputList & ol,
ClassMemberHighlight::Enum hl )
static

Definition at line 3098 of file index.cpp.

3099{
3100 const auto &index = Index::instance();
3101 if (index.numDocumentedClassMembers(hl)==0) return;
3102
3103 bool disableIndex = Config_getBool(DISABLE_INDEX);
3104
3105 bool multiPageIndex=FALSE;
3106 if (index.numDocumentedClassMembers(hl)>MAX_ITEMS_BEFORE_MULTIPAGE_INDEX)
3107 {
3108 multiPageIndex=TRUE;
3109 }
3110
3111 ol.pushGeneratorState();
3113
3115 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ClassMembers);
3116 QCString title = lne ? lne->title() : theTranslator->trCompoundMembers();
3117 if (hl!=ClassMemberHighlight::All) title+=QCString(" - ")+getCmhlInfo(hl)->title;
3118 bool addToIndex = lne==nullptr || lne->visible();
3119
3120 if (addToIndex)
3121 {
3122 Doxygen::indexList->addContentsItem(multiPageIndex,getCmhlInfo(hl)->title,QCString(),
3123 getCmhlInfo(hl)->fname,QCString(),multiPageIndex,TRUE);
3124 if (multiPageIndex) Doxygen::indexList->incContentsDepth();
3125 }
3126
3127 bool first=TRUE;
3128 for (const auto &[letter,list] : index.isClassIndexLetterUsed(hl))
3129 {
3130 QCString fileName = getCmhlInfo(hl)->fname;
3131 if (multiPageIndex)
3132 {
3133 QCString cs(letter);
3134 if (!first)
3135 {
3136 fileName+="_"+letterToLabel(cs);
3137 }
3138 if (addToIndex)
3139 {
3140 Doxygen::indexList->addContentsItem(FALSE,cs,QCString(),fileName,QCString(),FALSE,TRUE);
3141 }
3142 }
3143 bool quickIndex = index.numDocumentedClassMembers(hl)>maxItemsBeforeQuickIndex;
3144
3145 ol.startFile(fileName+extension,QCString(),title);
3146 ol.startQuickIndices();
3147 if (!disableIndex)
3148 {
3150 if (!Config_getBool(HTML_DYNAMIC_MENUS))
3151 {
3153
3154 // index item for global member list
3157 ol.writeString(fixSpaces(getCmhlInfo(0)->title));
3159
3160 // index items per category member lists
3161 for (int i=1;i<ClassMemberHighlight::Total;i++)
3162 {
3163 if (index.numDocumentedClassMembers(static_cast<ClassMemberHighlight::Enum>(i))>0)
3164 {
3166 ol.writeString(fixSpaces(getCmhlInfo(i)->title));
3167 //printf("multiPageIndex=%d first=%d fileName=%s file=%s title=%s\n",
3168 // multiPageIndex,first,qPrint(fileName),getCmhlInfo(i)->fname,qPrint(getCmhlInfo(i)->title));
3170 }
3171 }
3172
3174
3175 // quick alphabetical index
3176 if (quickIndex)
3177 {
3178 writeQuickMemberIndex(ol,index.isClassIndexLetterUsed(hl),letter,
3179 getCmhlInfo(hl)->fname,multiPageIndex);
3180 }
3181 }
3182 }
3183 ol.endQuickIndices();
3184 ol.writeSplitBar(fileName);
3185 ol.writeSearchInfo();
3186
3187 ol.startContents();
3188
3189 ol.startTextBlock();
3190 ol.parseText(hl == ClassMemberHighlight::All && lne ? lne->intro() : theTranslator->trCompoundMembersDescriptionTotal(hl));
3191 ol.endTextBlock();
3192
3193 writeMemberList(ol,quickIndex,
3194 multiPageIndex ? letter : std::string(),
3195 index.isClassIndexLetterUsed(hl),
3197 endFile(ol);
3198 first=FALSE;
3199 }
3200
3201 if (multiPageIndex && addToIndex) Doxygen::indexList->decContentsDepth();
3202
3203 ol.popGeneratorState();
3204}
static void endQuickIndexList(OutputList &ol)
Definition index.cpp:360
static void startQuickIndexItem(OutputList &ol, const QCString &l, bool hl, bool, bool &first)
Definition index.cpp:366
static void endQuickIndexItem(OutputList &ol)
Definition index.cpp:379
static void writeQuickMemberIndex(OutputList &ol, const Index::MemberIndexMap &map, const std::string &page, QCString fullName, bool multiPage)
Definition index.cpp:3040
static void writeMemberList(OutputList &ol, bool useSections, const std::string &page, const Index::MemberIndexMap &memberIndexMap, Definition::DefType type)
Definition index.cpp:2727
static void startQuickIndexList(OutputList &ol, bool letterTabs=FALSE)
Definition index.cpp:347
QCString title
Definition index.cpp:3073
const char * fname
Definition index.cpp:3072
QCString fixSpaces(const QCString &s)
Definition util.h:464

References ClassMemberHighlight::All, Config_getBool, OutputList::disableAllBut(), endFile(), endQuickIndexItem(), endQuickIndexList(), OutputList::endQuickIndices(), OutputList::endTextBlock(), FALSE, LayoutNavEntry::find(), fixSpaces(), CmhlInfo::fname, Functions, getCmhlInfo(), Html, Doxygen::htmlFileExtension, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), letterToLabel(), MAX_ITEMS_BEFORE_MULTIPAGE_INDEX, maxItemsBeforeQuickIndex, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), OutputList::startFile(), startQuickIndexItem(), startQuickIndexList(), OutputList::startQuickIndices(), OutputList::startTextBlock(), theTranslator, CmhlInfo::title, LayoutNavEntry::title(), ClassMemberHighlight::Total, TRUE, Definition::TypeClass, LayoutNavEntry::visible(), writeMemberList(), OutputList::writeQuickLinks(), writeQuickMemberIndex(), OutputList::writeSearchInfo(), OutputList::writeSplitBar(), and OutputList::writeString().

Referenced by writeClassMemberIndex().

◆ writeClassTree()

template<class ListType >
static void writeClassTree ( const ListType & cl,
FTVHelp * ftv,
bool addToIndex,
bool globalOnly,
ClassDef::CompoundType ct )
static

Definition at line 1690 of file index.cpp.

1691{
1692 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
1693 for (const auto &cdi : cl)
1694 {
1695 const ClassDef *cd = get_pointer(cdi);
1696 if (cd->getLanguage()==SrcLangExt::VHDL)
1697 {
1700 )// no architecture
1701 {
1702 continue;
1703 }
1704 }
1705
1706 if (sliceOpt && cd->compoundType() != ct)
1707 {
1708 continue;
1709 }
1710
1711 if (!globalOnly ||
1712 cd->getOuterScope()==nullptr ||
1714 )
1715 {
1716 int count=0;
1717 for (const auto &ccd : cd->getClasses())
1718 {
1719 if (ccd->isLinkableInProject() && !ccd->isImplicitTemplateInstance())
1720 {
1721 count++;
1722 }
1723 }
1725 {
1726 if (ftv)
1727 {
1728 ftv->addContentsItem(count>0,cd->displayName(FALSE),cd->getReference(),
1729 cd->getOutputFileBase(),cd->anchor(),FALSE,TRUE,cd);
1730 }
1731 if (addToIndex &&
1732 (cd->getOuterScope()==nullptr ||
1734 )
1735 )
1736 {
1737 addMembersToIndex(cd,LayoutDocManager::Class,
1738 cd->displayName(FALSE),
1739 cd->anchor(),
1740 cd->partOfGroups().empty() && !cd->isSimple());
1741 }
1742 if (count>0)
1743 {
1744 if (ftv) ftv->incContentsDepth();
1745 writeClassTree(cd->getClasses(),ftv,addToIndex,FALSE,ct);
1746 if (ftv) ftv->decContentsDepth();
1747 }
1748 }
1749 }
1750 }
1751}
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
virtual CompoundType compoundType() const =0
Returns the type of compound this is, i.e.
virtual ClassLinkedRefMap getClasses() const =0
returns the classes nested into this class
virtual SrcLangExt getLanguage() const =0
Returns the programming language this definition was written in.
virtual DefType definitionType() const =0
virtual const GroupList & partOfGroups() const =0
virtual Definition * getOuterScope() const =0
static NamespaceDefMutable * globalScope
Definition doxygen.h:121
void addContentsItem(bool isDir, const QCString &name, const QCString &ref, const QCString &file, const QCString &anchor, bool separateIndex, bool addToNavIndex, const Definition *def)
Definition ftvhelp.cpp:184
void decContentsDepth()
Definition ftvhelp.cpp:153
void incContentsDepth()
Definition ftvhelp.cpp:142
bool classVisibleInIndex(const ClassDef *cd)
const ClassDef * get_pointer(const Ptr &p)

References FTVHelp::addContentsItem(), addMembersToIndex(), Definition::anchor(), classVisibleInIndex(), ClassDef::compoundType(), Config_getBool, VhdlDocGen::convert(), FTVHelp::decContentsDepth(), Definition::definitionType(), Definition::displayName(), FALSE, get_pointer(), ClassDef::getClasses(), Definition::getLanguage(), Definition::getOuterScope(), Definition::getOutputFileBase(), Definition::getReference(), Doxygen::globalScope, FTVHelp::incContentsDepth(), ClassDef::isImplicitTemplateInstance(), ClassDef::isSimple(), VhdlDocGen::PACKAGECLASS, VhdlDocGen::PACKBODYCLASS, Definition::partOfGroups(), ClassDef::protection(), TRUE, Definition::TypeClass, VHDL, and writeClassTree().

Referenced by writeAnnotatedIndexGeneric(), writeClassTree(), writeClassTreeInsideNamespaceElement(), writeModuleTreeNode(), and writeNamespaceTreeElement().

◆ writeClassTreeForList()

static void writeClassTreeForList ( OutputList & ol,
const ClassLinkedMap & cl,
bool & started,
FTVHelp * ftv,
bool addToIndex,
ClassDef::CompoundType ct,
ClassDefSet & visitedClasses )
static

Definition at line 955 of file index.cpp.

957{
958 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
959 for (const auto &cd : cl)
960 {
961 //printf("class %s classHasVisibleRoot=%d isVisibleInHierarchy=%d\n",
962 // qPrint(cd->name()),
963 // classHasVisibleRoot(cd->baseClasses()),
964 // cd->isVisibleInHierarchy()
965 // );
966 bool b = false;
967 if (cd->getLanguage()==SrcLangExt::VHDL)
968 {
969 if (VhdlDocGen::convert(cd->protection())!=VhdlDocGen::ENTITYCLASS)
970 {
971 continue;
972 }
973 b=!classHasVisibleRoot(cd->subClasses());
974 }
975 else if (sliceOpt && cd->compoundType() != ct)
976 {
977 continue;
978 }
979 else
980 {
981 b=!classHasVisibleRoot(cd->baseClasses());
982 }
983
984 if (b) //filter on root classes
985 {
986 if (cd->isVisibleInHierarchy()) // should it be visible
987 {
988 if (!started)
989 {
991 if (addToIndex)
992 {
993 Doxygen::indexList->incContentsDepth();
994 }
995 started=TRUE;
996 }
998 bool hasChildren = visitedClasses.find(cd.get())==visitedClasses.end() &&
999 classHasVisibleChildren(cd.get());
1000 //printf("list: Has children %s: %d\n",qPrint(cd->name()),hasChildren);
1001 if (cd->isLinkable())
1002 {
1003 //printf("Writing class %s isLinkable()=%d isLinkableInProject()=%d cd->isImplicitTemplateinstance()=%d\n",
1004 // qPrint(cd->displayName()),cd->isLinkable(),cd->isLinkableInProject(),cd->isImplicitTemplateInstance());
1005 ol.startIndexItem(cd->getReference(),cd->getOutputFileBase());
1006 ol.parseText(cd->displayName());
1007 ol.endIndexItem(cd->getReference(),cd->getOutputFileBase());
1008 if (cd->isReference())
1009 {
1010 ol.startTypewriter();
1011 ol.docify(" [external]");
1012 ol.endTypewriter();
1013 }
1014 if (addToIndex)
1015 {
1016 if (cd->getLanguage()!=SrcLangExt::VHDL) // prevents double insertion in Design Unit List
1017 Doxygen::indexList->addContentsItem(hasChildren,cd->displayName(),cd->getReference(),cd->getOutputFileBase(),cd->anchor(),FALSE,FALSE);
1018 }
1019 if (ftv)
1020 {
1021 ftv->addContentsItem(hasChildren,cd->displayName(),cd->getReference(),cd->getOutputFileBase(),cd->anchor(),FALSE,FALSE,cd.get());
1022 }
1023 }
1024 else
1025 {
1027 ol.parseText(cd->displayName());
1029 if (addToIndex)
1030 {
1031 Doxygen::indexList->addContentsItem(hasChildren,cd->displayName(),QCString(),QCString(),QCString(),FALSE,FALSE);
1032 }
1033 if (ftv)
1034 {
1035 ftv->addContentsItem(hasChildren,cd->displayName(),QCString(),QCString(),QCString(),FALSE,FALSE,cd.get());
1036 }
1037 }
1038 if (cd->getLanguage()==SrcLangExt::VHDL && hasChildren)
1039 {
1040 writeClassTreeToOutput(ol,cd->baseClasses(),1,ftv,addToIndex,visitedClasses);
1041 visitedClasses.insert(cd.get());
1042 }
1043 else if (hasChildren)
1044 {
1045 writeClassTreeToOutput(ol,cd->subClasses(),1,ftv,addToIndex,visitedClasses);
1046 visitedClasses.insert(cd.get());
1047 }
1048 ol.endIndexListItem();
1049 }
1050 }
1051 }
1052}
void startIndexItem(const QCString &ref, const QCString &file)
Definition outputlist.h:434
void endIndexItem(const QCString &ref, const QCString &file)
Definition outputlist.h:436
void startTypewriter()
Definition outputlist.h:450
void endIndexListItem()
Definition outputlist.h:416
void endTypewriter()
Definition outputlist.h:452
void startIndexListItem()
Definition outputlist.h:414
bool classHasVisibleChildren(const ClassDef *cd)
static void writeClassTreeToOutput(OutputList &ol, const BaseClassList &bcl, int level, FTVHelp *ftv, bool addToIndex, ClassDefSet &visitedClasses)
Definition index.cpp:610
static void startIndexHierarchy(OutputList &ol, int level)
Definition index.cpp:307

References FTVHelp::addContentsItem(), classHasVisibleChildren(), classHasVisibleRoot(), Config_getBool, VhdlDocGen::convert(), OutputList::docify(), OutputList::endIndexItem(), OutputList::endIndexListItem(), OutputList::endTypewriter(), VhdlDocGen::ENTITYCLASS, FALSE, Doxygen::indexList, OutputList::parseText(), startIndexHierarchy(), OutputList::startIndexItem(), OutputList::startIndexListItem(), OutputList::startTypewriter(), TRUE, VHDL, and writeClassTreeToOutput().

Referenced by writeClassHierarchy().

◆ writeClassTreeInsideNamespace() [1/2]

static void writeClassTreeInsideNamespace ( const NamespaceLinkedMap & nsLinkedMap,
FTVHelp * ftv,
bool rootOnly,
bool addToIndex,
ClassDef::CompoundType ct )
static

Definition at line 1978 of file index.cpp.

1980{
1981 for (const auto &nd : nsLinkedMap)
1982 {
1983 writeClassTreeInsideNamespaceElement(nd.get(),ftv,rootOnly,addToIndex,ct);
1984 }
1985}
static void writeClassTreeInsideNamespaceElement(const NamespaceDef *nd, FTVHelp *ftv, bool rootOnly, bool addToIndex, ClassDef::CompoundType ct)
Definition index.cpp:1897

References writeClassTreeInsideNamespaceElement().

◆ writeClassTreeInsideNamespace() [2/2]

static void writeClassTreeInsideNamespace ( const NamespaceLinkedRefMap & nsLinkedMap,
FTVHelp * ftv,
bool rootOnly,
bool addToIndex,
ClassDef::CompoundType ct )
static

Definition at line 1969 of file index.cpp.

1971{
1972 for (const auto &nd : nsLinkedMap)
1973 {
1974 writeClassTreeInsideNamespaceElement(nd,ftv,rootOnly,addToIndex,ct);
1975 }
1976}

References writeClassTreeInsideNamespaceElement().

Referenced by writeAnnotatedIndexGeneric(), and writeClassTreeInsideNamespaceElement().

◆ writeClassTreeInsideNamespaceElement()

static void writeClassTreeInsideNamespaceElement ( const NamespaceDef * nd,
FTVHelp * ftv,
bool rootOnly,
bool addToIndex,
ClassDef::CompoundType ct )
static

Definition at line 1897 of file index.cpp.

1899{
1900 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
1901 if (!nd->isAnonymous() &&
1902 (!rootOnly || nd->getOuterScope()==Doxygen::globalScope))
1903 {
1904 bool isDir = namespaceHasNestedClass(nd,sliceOpt,ct);
1905 bool isLinkable = nd->isLinkableInProject();
1906
1907 //printf("writeClassTreeInsideNamespaceElement namespace %s isLinkable=%d isDir=%d\n",qPrint(nd->name()),isLinkable,isDir);
1908
1909 QCString ref;
1910 QCString file;
1911 if (isLinkable)
1912 {
1913 ref = nd->getReference();
1914 file = nd->getOutputFileBase();
1915 if (nd->getLanguage()==SrcLangExt::VHDL) // UGLY HACK
1916 {
1917 file=file.replace(0,qstrlen("namespace"),"class");
1918 }
1919 }
1920
1921 if (isDir)
1922 {
1923 ftv->addContentsItem(isDir,nd->localName(),ref,file,QCString(),FALSE,TRUE,nd);
1924
1925 if (addToIndex)
1926 {
1927 // the namespace entry is already shown under the namespace list so don't
1928 // add it to the nav index and don't create a separate index file for it otherwise
1929 // it will overwrite the one written for the namespace list.
1930 Doxygen::indexList->addContentsItem(isDir,nd->localName(),ref,file,QCString(),
1931 false, // separateIndex
1932 false // addToNavIndex
1933 );
1934 }
1935 if (addToIndex)
1936 {
1937 Doxygen::indexList->incContentsDepth();
1938 }
1939
1940 ftv->incContentsDepth();
1941 writeClassTreeInsideNamespace(nd->getNamespaces(),ftv,FALSE,addToIndex,ct);
1942 ClassLinkedRefMap d = nd->getClasses();
1943 if (sliceOpt)
1944 {
1945 if (ct == ClassDef::Interface)
1946 {
1947 d = nd->getInterfaces();
1948 }
1949 else if (ct == ClassDef::Struct)
1950 {
1951 d = nd->getStructs();
1952 }
1953 else if (ct == ClassDef::Exception)
1954 {
1955 d = nd->getExceptions();
1956 }
1957 }
1958 writeClassTree(d,ftv,addToIndex,FALSE,ct);
1959 ftv->decContentsDepth();
1960
1961 if (addToIndex)
1962 {
1963 Doxygen::indexList->decContentsDepth();
1964 }
1965 }
1966 }
1967}
virtual const QCString & localName() const =0
virtual bool isLinkableInProject() const =0
virtual bool isAnonymous() const =0
virtual ClassLinkedRefMap getStructs() const =0
virtual ClassLinkedRefMap getExceptions() const =0
virtual NamespaceLinkedRefMap getNamespaces() const =0
virtual ClassLinkedRefMap getClasses() const =0
virtual ClassLinkedRefMap getInterfaces() const =0
QCString & replace(size_t index, size_t len, const char *s)
Definition qcstring.cpp:212
bool namespaceHasNestedClass(const NamespaceDef *nd, bool filterClasses, ClassDef::CompoundType ct)
uint32_t qstrlen(const char *str)
Returns the length of string str, or 0 if a null pointer is passed.
Definition qcstring.h:58

References FTVHelp::addContentsItem(), Config_getBool, FTVHelp::decContentsDepth(), ClassDef::Exception, FALSE, NamespaceDef::getClasses(), NamespaceDef::getExceptions(), NamespaceDef::getInterfaces(), Definition::getLanguage(), NamespaceDef::getNamespaces(), Definition::getOuterScope(), Definition::getOutputFileBase(), Definition::getReference(), NamespaceDef::getStructs(), Doxygen::globalScope, FTVHelp::incContentsDepth(), Doxygen::indexList, ClassDef::Interface, Definition::isAnonymous(), Definition::isLinkableInProject(), Definition::localName(), namespaceHasNestedClass(), qstrlen(), QCString::replace(), ClassDef::Struct, TRUE, VHDL, writeClassTree(), and writeClassTreeInsideNamespace().

Referenced by writeClassTreeInsideNamespace(), and writeClassTreeInsideNamespace().

◆ writeClassTreeToOutput()

static void writeClassTreeToOutput ( OutputList & ol,
const BaseClassList & bcl,
int level,
FTVHelp * ftv,
bool addToIndex,
ClassDefSet & visitedClasses )
static

Generates HTML Help tree of classes

Definition at line 610 of file index.cpp.

611{
612 if (bcl.empty()) return;
613 bool started=FALSE;
614 for (const auto &bcd : bcl)
615 {
616 ClassDef *cd=bcd.classDef;
618 {
619 continue;
620 }
621
622 bool b = cd->getLanguage()==SrcLangExt::VHDL ? classHasVisibleRoot(cd->subClasses()) : classHasVisibleRoot(cd->baseClasses());
623
624 if (cd->isVisibleInHierarchy() && b) // classHasVisibleRoot(cd->baseClasses()))
625 {
626 if (!started)
627 {
628 startIndexHierarchy(ol,level);
629 if (addToIndex)
630 {
631 Doxygen::indexList->incContentsDepth();
632 }
633 if (ftv)
634 {
635 ftv->incContentsDepth();
636 }
637 started=TRUE;
638 }
640 //printf("Passed...\n");
641 bool hasChildren = visitedClasses.find(cd)==visitedClasses.end() &&
643 //printf("tree4: Has children %s: %d\n",qPrint(cd->name()),hasChildren);
644 if (cd->isLinkable())
645 {
646 //printf("Writing class %s\n",qPrint(cd->displayName()));
647 ol.startIndexItem(cd->getReference(),cd->getOutputFileBase());
648 ol.parseText(cd->displayName());
649 ol.endIndexItem(cd->getReference(),cd->getOutputFileBase());
650 if (cd->isReference())
651 {
652 ol.startTypewriter();
653 ol.docify(" [external]");
654 ol.endTypewriter();
655 }
656 if (addToIndex)
657 {
658 Doxygen::indexList->addContentsItem(hasChildren,cd->displayName(),cd->getReference(),cd->getOutputFileBase(),cd->anchor());
659 }
660 if (ftv)
661 {
662 if (cd->getLanguage()==SrcLangExt::VHDL)
663 {
664 ftv->addContentsItem(hasChildren,bcd.usedName,cd->getReference(),cd->getOutputFileBase(),cd->anchor(),FALSE,FALSE,cd);
665 }
666 else
667 {
668 ftv->addContentsItem(hasChildren,cd->displayName(),cd->getReference(),cd->getOutputFileBase(),cd->anchor(),FALSE,FALSE,cd);
669 }
670 }
671 }
672 else
673 {
675 ol.parseText(cd->name());
677 if (addToIndex)
678 {
679 Doxygen::indexList->addContentsItem(hasChildren,cd->displayName(),QCString(),QCString(),QCString());
680 }
681 if (ftv)
682 {
683 ftv->addContentsItem(hasChildren,cd->displayName(),QCString(),QCString(),QCString(),FALSE,FALSE,cd);
684 }
685 }
686 if (hasChildren)
687 {
688 //printf("Class %s at %p visited=%d\n",qPrint(cd->name()),cd,cd->visited);
689 visitedClasses.insert(cd);
690 if (cd->getLanguage()==SrcLangExt::VHDL)
691 {
692 writeClassTreeToOutput(ol,cd->baseClasses(),level+1,ftv,addToIndex,visitedClasses);
693 }
694 else
695 {
696 writeClassTreeToOutput(ol,cd->subClasses(),level+1,ftv,addToIndex,visitedClasses);
697 }
698 }
699 ol.endIndexListItem();
700 }
701 }
702 if (started)
703 {
704 endIndexHierarchy(ol,level);
705 if (addToIndex)
706 {
707 Doxygen::indexList->decContentsDepth();
708 }
709 if (ftv)
710 {
711 ftv->decContentsDepth();
712 }
713 }
714}
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 const BaseClassList & subClasses() const =0
Returns the list of sub classes that directly derive from this class.
virtual const QCString & name() const =0
if(strLen >35 &&floatingIndex >30 &&autoBreak)
Definition util.cpp:949

References FTVHelp::addContentsItem(), Definition::anchor(), ClassDef::baseClasses(), classHasVisibleChildren(), classHasVisibleRoot(), VhdlDocGen::convert(), FTVHelp::decContentsDepth(), Definition::displayName(), OutputList::docify(), endIndexHierarchy(), OutputList::endIndexItem(), OutputList::endIndexListItem(), OutputList::endTypewriter(), VhdlDocGen::ENTITYCLASS, FALSE, Definition::getLanguage(), Definition::getOutputFileBase(), Definition::getReference(), FTVHelp::incContentsDepth(), Doxygen::indexList, Definition::isLinkable(), Definition::isReference(), ClassDef::isVisibleInHierarchy(), Definition::name(), OutputList::parseText(), ClassDef::protection(), startIndexHierarchy(), OutputList::startIndexItem(), OutputList::startIndexListItem(), OutputList::startTypewriter(), ClassDef::subClasses(), TRUE, VHDL, and writeClassTreeToOutput().

Referenced by writeClassTreeForList(), and writeClassTreeToOutput().

◆ writeConceptIndex()

static void writeConceptIndex ( OutputList & ol)
static

Definition at line 4566 of file index.cpp.

4567{
4568 if (Index::instance().numDocumentedConcepts()==0) return;
4569 ol.pushGeneratorState();
4570 // 1.{
4573 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Concepts);
4574 QCString title = lne ? lne->title() : theTranslator->trConceptList();
4575 bool addToIndex = lne==nullptr || lne->visible();
4576
4577 startFile(ol,"concepts",QCString(),title,HighlightedItem::Concepts);
4578 startTitle(ol,QCString());
4579 ol.parseText(title);
4580 endTitle(ol,QCString(),QCString());
4581 ol.startContents();
4582 ol.startTextBlock();
4583 ol.parseText(lne ? lne->intro() : theTranslator->trConceptListDescription(Config_getBool(EXTRACT_ALL)));
4584 ol.endTextBlock();
4585
4586 // ---------------
4587 // Normal group index for Latex/RTF
4588 // ---------------
4589 // 2.{
4590 ol.pushGeneratorState();
4592
4593 bool first=TRUE;
4594 for (const auto &cd : *Doxygen::conceptLinkedMap)
4595 {
4596 if (cd->isLinkableInProject())
4597 {
4598 if (first)
4599 {
4600 ol.startIndexList();
4601 first=FALSE;
4602 }
4603 //ol.writeStartAnnoItem("namespace",nd->getOutputFileBase(),0,nd->name());
4604 ol.startIndexKey();
4605 ol.writeObjectLink(QCString(),cd->getOutputFileBase(),QCString(),cd->displayName());
4606 ol.endIndexKey();
4607
4608 bool hasBrief = !cd->briefDescription().isEmpty();
4609 ol.startIndexValue(hasBrief);
4610 if (hasBrief)
4611 {
4612 //ol.docify(" (");
4613 ol.generateDoc(
4614 cd->briefFile(),cd->briefLine(),
4615 cd.get(),nullptr,
4616 cd->briefDescription(TRUE),
4617 FALSE, // index words
4618 FALSE, // isExample
4619 QCString(), // example name
4620 TRUE, // single line
4621 TRUE, // link from index
4622 Config_getBool(MARKDOWN_SUPPORT)
4623 );
4624 //ol.docify(")");
4625 }
4626 ol.endIndexValue(cd->getOutputFileBase(),hasBrief);
4627
4628 }
4629 }
4630 if (!first) ol.endIndexList();
4631
4632 ol.popGeneratorState();
4633 // 2.}
4634
4635 // ---------------
4636 // interactive group index for HTML
4637 // ---------------
4638 // 2.{
4639 ol.pushGeneratorState();
4641
4642 {
4643 if (addToIndex)
4644 {
4645 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),"concepts",QCString(),TRUE,TRUE);
4646 Doxygen::indexList->incContentsDepth();
4647 }
4648 FTVHelp ftv(false);
4649 for (const auto &nd : *Doxygen::namespaceLinkedMap)
4650 {
4651 writeConceptTreeInsideNamespaceElement(nd.get(),&ftv,true,addToIndex);
4652 }
4653 writeConceptRootList(&ftv,addToIndex);
4654 TextStream t;
4655 ftv.generateTreeViewInline(t);
4656 ol.writeString(t.str().c_str());
4657 if (addToIndex)
4658 {
4659 Doxygen::indexList->decContentsDepth();
4660 }
4661 }
4662 ol.popGeneratorState();
4663 // 2.}
4664
4665 endFile(ol);
4666 ol.popGeneratorState();
4667 // 1.}
4668}
static void writeConceptRootList(FTVHelp *ftv, bool addToIndex)
Definition index.cpp:4544
static void writeConceptTreeInsideNamespaceElement(const NamespaceDef *nd, FTVHelp *ftv, bool rootOnly, bool addToIndex)
Definition index.cpp:4493

References Doxygen::conceptLinkedMap, Concepts, Config_getBool, OutputList::disable(), OutputList::disableAllBut(), Docbook, endFile(), OutputList::endIndexKey(), OutputList::endIndexList(), OutputList::endIndexValue(), OutputList::endTextBlock(), endTitle(), FALSE, LayoutNavEntry::find(), OutputList::generateDoc(), FTVHelp::generateTreeViewInline(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), Man, Doxygen::namespaceLinkedMap, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startIndexKey(), OutputList::startIndexList(), OutputList::startIndexValue(), OutputList::startTextBlock(), startTitle(), TextStream::str(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), writeConceptRootList(), writeConceptTreeInsideNamespaceElement(), OutputList::writeObjectLink(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writeConceptList()

static void writeConceptList ( const ConceptLinkedRefMap & concepts,
FTVHelp * ftv,
bool addToIndex )
static

Definition at line 4460 of file index.cpp.

4461{
4462 for (const auto &cd : concepts)
4463 {
4464 if (cd->isLinkableInProject())
4465 {
4466 if (ftv)
4467 {
4468 ftv->addContentsItem(false,cd->displayName(FALSE),cd->getReference(),
4469 cd->getOutputFileBase(),QCString(),false,cd->partOfGroups().empty(),cd);
4470 }
4471 if (addToIndex)
4472 {
4473 Doxygen::indexList->addContentsItem(false,cd->displayName(FALSE),cd->getReference(),
4474 cd->getOutputFileBase(),QCString(),false,cd->partOfGroups().empty());
4475 }
4476 }
4477 }
4478}

References FTVHelp::addContentsItem(), FALSE, and Doxygen::indexList.

Referenced by writeConceptTreeInsideNamespaceElement(), writeModuleTreeNode(), and writeNamespaceTreeElement().

◆ writeConceptRootList()

static void writeConceptRootList ( FTVHelp * ftv,
bool addToIndex )
static

Definition at line 4544 of file index.cpp.

4545{
4546 for (const auto &cd : *Doxygen::conceptLinkedMap)
4547 {
4548 if ((cd->getOuterScope()==nullptr ||
4549 cd->getOuterScope()==Doxygen::globalScope) && cd->isLinkableInProject()
4550 )
4551 {
4552 //printf("*** adding %s hasSubPages=%d hasSections=%d\n",qPrint(pageTitle),hasSubPages,hasSections);
4553 ftv->addContentsItem(
4554 false,cd->localName(),cd->getReference(),cd->getOutputFileBase(),
4555 QCString(),false,cd->partOfGroups().empty(),cd.get());
4556 if (addToIndex)
4557 {
4558 Doxygen::indexList->addContentsItem(
4559 false,cd->localName(),cd->getReference(),cd->getOutputFileBase(),
4560 QCString(),false,cd->partOfGroups().empty(),cd.get());
4561 }
4562 }
4563 }
4564}

References FTVHelp::addContentsItem(), Doxygen::conceptLinkedMap, Doxygen::globalScope, and Doxygen::indexList.

Referenced by writeConceptIndex().

◆ writeConceptTreeInsideNamespace()

static void writeConceptTreeInsideNamespace ( const NamespaceLinkedRefMap & nsLinkedMap,
FTVHelp * ftv,
bool rootOnly,
bool addToIndex )
static

Definition at line 4483 of file index.cpp.

4485{
4486 for (const auto &nd : nsLinkedMap)
4487 {
4488 writeConceptTreeInsideNamespaceElement(nd,ftv,rootOnly,addToIndex);
4489 }
4490}

References writeConceptTreeInsideNamespaceElement().

Referenced by writeConceptTreeInsideNamespaceElement().

◆ writeConceptTreeInsideNamespaceElement()

static void writeConceptTreeInsideNamespaceElement ( const NamespaceDef * nd,
FTVHelp * ftv,
bool rootOnly,
bool addToIndex )
static

Definition at line 4493 of file index.cpp.

4495{
4496 if (!nd->isAnonymous() &&
4497 (!rootOnly || nd->getOuterScope()==Doxygen::globalScope))
4498 {
4499 bool isDir = namespaceHasNestedConcept(nd);
4500 bool isLinkable = nd->isLinkableInProject();
4501
4502 //printf("writeConceptTreeInsideNamespaceElement namespace %s isLinkable=%d isDir=%d\n",qPrint(nd->name()),isLinkable,isDir);
4503
4504 QCString ref;
4505 QCString file;
4506 if (isLinkable)
4507 {
4508 ref = nd->getReference();
4509 file = nd->getOutputFileBase();
4510 }
4511
4512 if (isDir)
4513 {
4514 ftv->addContentsItem(isDir,nd->localName(),ref,file,QCString(),FALSE,TRUE,nd);
4515
4516 if (addToIndex)
4517 {
4518 // the namespace entry is already shown under the namespace list so don't
4519 // add it to the nav index and don't create a separate index file for it otherwise
4520 // it will overwrite the one written for the namespace list.
4521 Doxygen::indexList->addContentsItem(isDir,nd->localName(),ref,file,QCString(),
4522 false, // separateIndex
4523 false // addToNavIndex
4524 );
4525 }
4526 if (addToIndex)
4527 {
4528 Doxygen::indexList->incContentsDepth();
4529 }
4530
4531 ftv->incContentsDepth();
4533 writeConceptList(nd->getConcepts(),ftv,addToIndex);
4534 ftv->decContentsDepth();
4535
4536 if (addToIndex)
4537 {
4538 Doxygen::indexList->decContentsDepth();
4539 }
4540 }
4541 }
4542}
virtual ConceptLinkedRefMap getConcepts() const =0
static void writeConceptTreeInsideNamespace(const NamespaceLinkedRefMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex)
Definition index.cpp:4483
static void writeConceptList(const ConceptLinkedRefMap &concepts, FTVHelp *ftv, bool addToIndex)
Definition index.cpp:4460
bool namespaceHasNestedConcept(const NamespaceDef *nd)

References FTVHelp::addContentsItem(), FTVHelp::decContentsDepth(), FALSE, NamespaceDef::getConcepts(), NamespaceDef::getNamespaces(), Definition::getOuterScope(), Definition::getOutputFileBase(), Definition::getReference(), Doxygen::globalScope, FTVHelp::incContentsDepth(), Doxygen::indexList, Definition::isAnonymous(), Definition::isLinkableInProject(), Definition::localName(), namespaceHasNestedConcept(), TRUE, writeConceptList(), and writeConceptTreeInsideNamespace().

Referenced by writeConceptIndex(), and writeConceptTreeInsideNamespace().

◆ writeDirHierarchy()

static void writeDirHierarchy ( OutputList & ol,
FTVHelp * ftv,
bool addToIndex )
static

Definition at line 891 of file index.cpp.

892{
893 if (ftv)
894 {
897 }
899 for (const auto &dd : *Doxygen::dirLinkedMap)
900 {
901 if (dd->getOuterScope()==Doxygen::globalScope)
902 {
903 writeDirTreeNode(ol,dd.get(),0,ftv,addToIndex);
904 }
905 }
906 if (ftv)
907 {
908 for (const auto &fn : *Doxygen::inputNameLinkedMap)
909 {
910 for (const auto &fd : *fn)
911 {
912 if (fd->getDirDef()==nullptr) // top level file
913 {
914 bool src = false;
915 bool doc = fileVisibleInIndex(fd.get(),src);
916 QCString reference, outputBase;
917 if (doc)
918 {
919 reference = fd->getReference();
920 outputBase = fd->getOutputFileBase();
921 }
922 if (doc || src)
923 {
924 ftv->addContentsItem(FALSE,fd->displayName(),
925 reference, outputBase, QCString(),
926 FALSE,FALSE,fd.get());
927 }
928 if (addToIndex)
929 {
930 if (doc)
931 {
932 addMembersToIndex(fd.get(),LayoutDocManager::File,fd->displayName(),QCString(),TRUE,FALSE,&fd->getConcepts());
933 }
934 else if (src)
935 {
936 Doxygen::indexList->addContentsItem(
937 FALSE, fd->displayName(), QCString(),
938 fd->getSourceFileBase(), QCString(), FALSE, TRUE, fd.get());
939 }
940 }
941 }
942 }
943 }
944 }
945 endIndexHierarchy(ol,0);
946 if (ftv)
947 {
949 }
950}
static void writeDirTreeNode(OutputList &ol, const DirDef *dd, int level, FTVHelp *ftv, bool addToIndex)
Definition index.cpp:746

References FTVHelp::addContentsItem(), addMembersToIndex(), Doxygen::dirLinkedMap, OutputList::disable(), endIndexHierarchy(), FALSE, fileVisibleInIndex(), Doxygen::globalScope, Html, Doxygen::indexList, Doxygen::inputNameLinkedMap, OutputList::popGeneratorState(), OutputList::pushGeneratorState(), startIndexHierarchy(), TRUE, and writeDirTreeNode().

Referenced by writeFileIndex().

◆ writeDirTreeNode()

static void writeDirTreeNode ( OutputList & ol,
const DirDef * dd,
int level,
FTVHelp * ftv,
bool addToIndex )
static

Definition at line 746 of file index.cpp.

747{
748 if (level>20)
749 {
750 warn(dd->getDefFileName(),dd->getDefLine(),
751 "maximum nesting level exceeded for directory %s: "
752 "check for possible recursive directory relation!",qPrint(dd->name())
753 );
754 return;
755 }
756
757 if (!dirHasVisibleChildren(dd))
758 {
759 return;
760 }
761
762 bool tocExpand = TRUE; //Config_getBool(TOC_EXPAND);
763 bool isDir = !dd->subDirs().empty() || // there are subdirs
764 (tocExpand && // or toc expand and
765 !dd->getFiles().empty() // there are files
766 );
767 //printf("gd='%s': pageDict=%d\n",qPrint(gd->name()),gd->pageDict->count());
768 if (addToIndex)
769 {
770 Doxygen::indexList->addContentsItem(isDir,dd->shortName(),dd->getReference(),dd->getOutputFileBase(),QCString(),TRUE,TRUE);
771 Doxygen::indexList->incContentsDepth();
772 }
773 if (ftv)
774 {
775 ftv->addContentsItem(isDir,dd->shortName(),dd->getReference(),
777 ftv->incContentsDepth();
778 }
779
782 ol.parseText(dd->shortName());
784 if (dd->isReference())
785 {
786 ol.startTypewriter();
787 ol.docify(" [external]");
788 ol.endTypewriter();
789 }
790
791 // write sub directories
792 if (dd->subDirs().size()>0)
793 {
794 startIndexHierarchy(ol,level+1);
795 for(const auto &subdd : dd->subDirs())
796 {
797 writeDirTreeNode(ol,subdd,level+1,ftv,addToIndex);
798 }
799 endIndexHierarchy(ol,level+1);
800 }
801
802 int fileCount=0;
803 if (!dd->getFiles().empty())
804 {
805 for (const auto &fd : dd->getFiles())
806 {
807 //bool allExternals = Config_getBool(ALLEXTERNALS);
808 //if ((allExternals && fd->isLinkable()) || fd->isLinkableInProject())
809 //{
810 // fileCount++;
811 //}
812 bool genSourceFile = false;
813 if (fileVisibleInIndex(fd,genSourceFile))
814 {
815 fileCount++;
816 }
817 else if (genSourceFile)
818 {
819 fileCount++;
820 }
821 }
822 if (fileCount>0)
823 {
824 startIndexHierarchy(ol,level+1);
825 for (const auto &fd : dd->getFiles())
826 {
827 bool src = false;
828 bool doc = fileVisibleInIndex(fd,src);
829 QCString reference;
830 QCString outputBase;
831 if (doc)
832 {
833 reference = fd->getReference();
834 outputBase = fd->getOutputFileBase();
835 }
836 if (doc || src)
837 {
839 ol.startIndexItem(reference,outputBase);
840 ol.parseText(fd->displayName());
841 ol.endIndexItem(reference,outputBase);
842 ol.endIndexListItem();
843 if (ftv && (src || doc))
844 {
846 fd->displayName(),
847 reference,outputBase,
848 QCString(),FALSE,FALSE,fd);
849 }
850 }
851 }
852 endIndexHierarchy(ol,level+1);
853 }
854 }
855
856 if (tocExpand && addToIndex)
857 {
858 // write files of this directory
859 if (fileCount>0)
860 {
861 for (const auto &fd : dd->getFiles())
862 {
863 bool src = false;
864 bool doc = fileVisibleInIndex(fd,src);
865 if (doc)
866 {
867 addMembersToIndex(fd,LayoutDocManager::File,fd->displayName(),QCString(),
868 !fd->isLinkableViaGroup(),FALSE,&fd->getConcepts());
869 }
870 else if (src)
871 {
872 Doxygen::indexList->addContentsItem(
873 FALSE, fd->name(), QCString(),
874 fd->getSourceFileBase(), QCString(), FALSE, TRUE, fd);
875 }
876 }
877 }
878 }
879 ol.endIndexListItem();
880
881 if (addToIndex)
882 {
883 Doxygen::indexList->decContentsDepth();
884 }
885 if (ftv)
886 {
887 ftv->decContentsDepth();
888 }
889}
virtual QCString getDefFileName() const =0
virtual int getDefLine() const =0
virtual bool isReference() const =0
virtual const QCString shortName() const =0
#define warn(file, line, fmt,...)
Definition message.h:59
const char * qPrint(const char *s)
Definition qcstring.h:661

References FTVHelp::addContentsItem(), addMembersToIndex(), FTVHelp::decContentsDepth(), dirHasVisibleChildren(), OutputList::docify(), endIndexHierarchy(), OutputList::endIndexItem(), OutputList::endIndexListItem(), OutputList::endTypewriter(), FALSE, fileVisibleInIndex(), Definition::getDefFileName(), Definition::getDefLine(), DirDef::getFiles(), Definition::getOutputFileBase(), Definition::getReference(), FTVHelp::incContentsDepth(), Doxygen::indexList, Definition::isReference(), Definition::name(), OutputList::parseText(), qPrint(), DirDef::shortName(), startIndexHierarchy(), OutputList::startIndexItem(), OutputList::startIndexListItem(), OutputList::startTypewriter(), DirDef::subDirs(), TRUE, warn, and writeDirTreeNode().

Referenced by writeDirHierarchy(), and writeDirTreeNode().

◆ writeExampleIndex()

static void writeExampleIndex ( OutputList & ol)
static

Definition at line 3718 of file index.cpp.

3719{
3720 if (Doxygen::exampleLinkedMap->empty()) return;
3721 ol.pushGeneratorState();
3724 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Examples);
3725 QCString title = lne ? lne->title() : theTranslator->trExamples();
3726 bool addToIndex = lne==nullptr || lne->visible();
3727
3728 startFile(ol,"examples",QCString(),title,HighlightedItem::Examples);
3729
3730 startTitle(ol,QCString());
3731 ol.parseText(title);
3732 endTitle(ol,QCString(),QCString());
3733
3734 ol.startContents();
3735
3736 if (addToIndex)
3737 {
3738 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),"examples",QCString(),TRUE,TRUE);
3739 Doxygen::indexList->incContentsDepth();
3740 }
3741
3742 ol.startTextBlock();
3743 ol.parseText(lne ? lne->intro() : theTranslator->trExamplesDescription());
3744 ol.endTextBlock();
3745
3746 ol.startItemList();
3747 for (const auto &pd : *Doxygen::exampleLinkedMap)
3748 {
3749 ol.startItemListItem();
3750 QCString n=pd->getOutputFileBase();
3751 if (!pd->title().isEmpty())
3752 {
3753 ol.writeObjectLink(QCString(),n,QCString(),pd->title());
3754 if (addToIndex)
3755 {
3756 Doxygen::indexList->addContentsItem(FALSE,filterTitle(pd->title()),pd->getReference(),n,QCString(),FALSE,TRUE);
3757 }
3758 }
3759 else
3760 {
3761 ol.writeObjectLink(QCString(),n,QCString(),pd->name());
3762 if (addToIndex)
3763 {
3764 Doxygen::indexList->addContentsItem(FALSE,pd->name(),pd->getReference(),n,QCString(),FALSE,TRUE);
3765 }
3766 }
3767 ol.endItemListItem();
3768 //ol.writeString("\n");
3769 }
3770 ol.endItemList();
3771
3772 if (addToIndex)
3773 {
3774 Doxygen::indexList->decContentsDepth();
3775 }
3776 endFile(ol);
3777 ol.popGeneratorState();
3778}
void startItemListItem()
Definition outputlist.h:458
void endItemListItem()
Definition outputlist.h:460

References OutputList::disable(), Docbook, endFile(), OutputList::endItemList(), OutputList::endItemListItem(), OutputList::endTextBlock(), endTitle(), Doxygen::exampleLinkedMap, Examples, FALSE, filterTitle(), LayoutNavEntry::find(), Doxygen::indexList, LayoutDocManager::instance(), LayoutNavEntry::intro(), Man, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startItemList(), OutputList::startItemListItem(), OutputList::startTextBlock(), startTitle(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), and OutputList::writeObjectLink().

Referenced by writeIndexHierarchyEntries().

◆ writeFileIndex()

static void writeFileIndex ( OutputList & ol)
static

Definition at line 1534 of file index.cpp.

1535{
1536 if (Index::instance().numDocumentedFiles()==0 || !Config_getBool(SHOW_FILES)) return;
1537
1538 ol.pushGeneratorState();
1541
1542 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::FileList);
1543 if (lne==nullptr) lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Files); // fall back
1544 QCString title = lne ? lne->title() : theTranslator->trFileList();
1545 bool addToIndex = lne==nullptr || lne->visible();
1546
1547 startFile(ol,"files",QCString(),title,HighlightedItem::Files);
1548 startTitle(ol,QCString());
1549 //if (!Config_getString(PROJECT_NAME).isEmpty())
1550 //{
1551 // title.prepend(Config_getString(PROJECT_NAME)+" ");
1552 //}
1553 ol.parseText(title);
1554 endTitle(ol,QCString(),QCString());
1555 ol.startContents();
1556 ol.startTextBlock();
1557
1558 if (addToIndex)
1559 {
1560 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),"files",QCString(),TRUE,TRUE);
1561 Doxygen::indexList->incContentsDepth();
1562 }
1563
1564 ol.parseText(lne ? lne->intro() : theTranslator->trFileListDescription(Config_getBool(EXTRACT_ALL)));
1565 ol.endTextBlock();
1566
1567 // ---------------
1568 // Flat file index
1569 // ---------------
1570
1571 // 1. {
1572 ol.pushGeneratorState();
1574
1575 ol.startIndexList();
1576 if (Config_getBool(FULL_PATH_NAMES))
1577 {
1578 std::unordered_map<std::string,size_t> pathMap;
1579 std::vector<FilesInDir> outputFiles;
1580
1581 // re-sort input files in (dir,file) output order instead of (file,dir) input order
1582 for (const auto &fn : *Doxygen::inputNameLinkedMap)
1583 {
1584 for (const auto &fd : *fn)
1585 {
1586 QCString path=fd->getPath();
1587 if (path.isEmpty()) path="[external]";
1588 auto it = pathMap.find(path.str());
1589 if (it!=pathMap.end()) // existing path -> append
1590 {
1591 outputFiles.at(it->second).files.push_back(fd.get());
1592 }
1593 else // new path -> create path entry + append
1594 {
1595 pathMap.emplace(path.str(),outputFiles.size());
1596 outputFiles.emplace_back(path);
1597 outputFiles.back().files.push_back(fd.get());
1598 }
1599 }
1600 }
1601
1602 // sort the files by path
1603 std::stable_sort(outputFiles.begin(),
1604 outputFiles.end(),
1605 [](const auto &fp1,const auto &fp2) { return qstricmp_sort(fp1.path,fp2.path)<0; });
1606 // sort the files inside the directory by name
1607 for (auto &fp : outputFiles)
1608 {
1609 std::stable_sort(fp.files.begin(), fp.files.end(), compareFileDefs);
1610 }
1611 // write the results
1612 for (const auto &fp : outputFiles)
1613 {
1614 for (const auto &fd : fp.files)
1615 {
1616 writeSingleFileIndex(ol,fd);
1617 }
1618 }
1619 }
1620 else
1621 {
1622 for (const auto &fn : *Doxygen::inputNameLinkedMap)
1623 {
1624 for (const auto &fd : *fn)
1625 {
1626 writeSingleFileIndex(ol,fd.get());
1627 }
1628 }
1629 }
1630 ol.endIndexList();
1631
1632 // 1. }
1633 ol.popGeneratorState();
1634
1635 // ---------------
1636 // Hierarchical file index for HTML
1637 // ---------------
1638 ol.pushGeneratorState();
1640
1641 {
1642 FTVHelp ftv(false);
1643 writeDirHierarchy(ol,&ftv,addToIndex);
1644 TextStream t;
1645 ftv.generateTreeViewInline(t);
1646 ol.writeString(t.str().c_str());
1647 }
1648
1649 ol.popGeneratorState();
1650 // ------
1651
1652 if (addToIndex)
1653 {
1654 Doxygen::indexList->decContentsDepth();
1655 }
1656
1657 endFile(ol);
1658 ol.popGeneratorState();
1659}
int find(char c, int index=0, bool cs=TRUE) const
Definition qcstring.cpp:43
bool compareFileDefs(const FileDef *fd1, const FileDef *fd2)
Definition filedef.cpp:1885
static void writeSingleFileIndex(OutputList &ol, const FileDef *fd)
Definition index.cpp:1454
static void writeDirHierarchy(OutputList &ol, FTVHelp *ftv, bool addToIndex)
Definition index.cpp:891

References compareFileDefs(), Config_getBool, OutputList::disable(), OutputList::disableAllBut(), Docbook, endFile(), OutputList::endIndexList(), OutputList::endTextBlock(), endTitle(), Files, LayoutNavEntry::find(), QCString::find(), FTVHelp::generateTreeViewInline(), Html, Doxygen::indexList, Doxygen::inputNameLinkedMap, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), QCString::isEmpty(), Man, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startIndexList(), OutputList::startTextBlock(), startTitle(), QCString::str(), TextStream::str(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), writeDirHierarchy(), writeSingleFileIndex(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writeFileLinkForMember()

static void writeFileLinkForMember ( OutputList & ol,
const MemberDef * md,
const QCString & separator,
QCString & prevFileName )
static

Definition at line 2686 of file index.cpp.

2688{
2689 const FileDef *fd=md->getFileDef();
2690 if (fd && prevFileName!=fd->name())
2691 {
2692 ol.writeString(separator);
2694 fd->name());
2695 prevFileName = fd->name();
2696 }
2697}
A model of a file symbol.
Definition filedef.h:99
virtual const FileDef * getFileDef() const =0

References Definition::anchor(), MemberDef::getFileDef(), Definition::getOutputFileBase(), Definition::getReference(), Definition::name(), OutputList::writeObjectLink(), and OutputList::writeString().

Referenced by writeMemberList().

◆ writeFileMemberIndex()

static void writeFileMemberIndex ( OutputList & ol)
static

Definition at line 3369 of file index.cpp.

3370{
3371 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::FileGlobals);
3372 bool addToIndex = lne==nullptr || lne->visible();
3373 if (Index::instance().numDocumentedFileMembers(FileMemberHighlight::All)>0 && addToIndex)
3374 {
3375 Doxygen::indexList->addContentsItem(true,lne ? lne->title() : theTranslator->trFileMembers(),QCString(),"globals",QCString());
3376 Doxygen::indexList->incContentsDepth();
3377 }
3387 if (Index::instance().numDocumentedFileMembers(FileMemberHighlight::All)>0 && addToIndex)
3388 {
3389 Doxygen::indexList->decContentsDepth();
3390 }
3391
3392}
static void writeFileMemberIndexFiltered(OutputList &ol, FileMemberHighlight::Enum hl)
Definition index.cpp:3266

References FileMemberHighlight::All, FileMemberHighlight::Defines, FileMemberHighlight::Dictionaries, FileMemberHighlight::Enums, FileMemberHighlight::EnumValues, LayoutNavEntry::find(), FileMemberHighlight::Functions, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutDocManager::rootNavEntry(), FileMemberHighlight::Sequences, theTranslator, LayoutNavEntry::title(), FileMemberHighlight::Typedefs, FileMemberHighlight::Variables, LayoutNavEntry::visible(), and writeFileMemberIndexFiltered().

Referenced by writeIndexHierarchyEntries().

◆ writeFileMemberIndexFiltered()

static void writeFileMemberIndexFiltered ( OutputList & ol,
FileMemberHighlight::Enum hl )
static

Definition at line 3266 of file index.cpp.

3267{
3268 const auto &index = Index::instance();
3269 if (index.numDocumentedFileMembers(hl)==0) return;
3270
3271 bool disableIndex = Config_getBool(DISABLE_INDEX);
3272
3273 bool multiPageIndex=FALSE;
3274 if (Index::instance().numDocumentedFileMembers(hl)>MAX_ITEMS_BEFORE_MULTIPAGE_INDEX)
3275 {
3276 multiPageIndex=TRUE;
3277 }
3278
3279 ol.pushGeneratorState();
3281
3283 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::FileGlobals);
3284 QCString title = lne ? lne->title() : theTranslator->trFileMembers();
3285 bool addToIndex = lne==nullptr || lne->visible();
3286
3287 if (addToIndex)
3288 {
3289 Doxygen::indexList->addContentsItem(multiPageIndex,getFmhlInfo(hl)->title,QCString(),
3290 getFmhlInfo(hl)->fname,QCString(),multiPageIndex,TRUE);
3291 if (multiPageIndex) Doxygen::indexList->incContentsDepth();
3292 }
3293
3294 bool first=TRUE;
3295 for (const auto &[letter,list] : index.isFileIndexLetterUsed(hl))
3296 {
3297 QCString fileName = getFmhlInfo(hl)->fname;
3298 if (multiPageIndex)
3299 {
3300 QCString cs(letter);
3301 if (!first)
3302 {
3303 fileName+="_"+letterToLabel(cs);
3304 }
3305 if (addToIndex)
3306 {
3307 Doxygen::indexList->addContentsItem(FALSE,cs,QCString(),fileName,QCString(),FALSE,TRUE);
3308 }
3309 }
3310 bool quickIndex = index.numDocumentedFileMembers(hl)>maxItemsBeforeQuickIndex;
3311
3312 ol.startFile(fileName+extension,QCString(),title);
3313 ol.startQuickIndices();
3314 if (!disableIndex)
3315 {
3317 if (!Config_getBool(HTML_DYNAMIC_MENUS))
3318 {
3320
3321 // index item for all file member lists
3324 ol.writeString(fixSpaces(getFmhlInfo(0)->title));
3326
3327 // index items for per category member lists
3328 for (int i=1;i<FileMemberHighlight::Total;i++)
3329 {
3330 if (Index::instance().numDocumentedFileMembers(static_cast<FileMemberHighlight::Enum>(i))>0)
3331 {
3333 getFmhlInfo(i)->fname+Doxygen::htmlFileExtension,hl==i,TRUE,first);
3334 ol.writeString(fixSpaces(getFmhlInfo(i)->title));
3336 }
3337 }
3338
3340
3341 if (quickIndex)
3342 {
3343 writeQuickMemberIndex(ol,index.isFileIndexLetterUsed(hl),letter,
3344 getFmhlInfo(hl)->fname,multiPageIndex);
3345 }
3346 }
3347 }
3348 ol.endQuickIndices();
3349 ol.writeSplitBar(fileName);
3350 ol.writeSearchInfo();
3351
3352 ol.startContents();
3353
3354 ol.startTextBlock();
3355 ol.parseText(hl == FileMemberHighlight::All && lne ? lne->intro() : theTranslator->trFileMembersDescriptionTotal(hl));
3356 ol.endTextBlock();
3357
3358 writeMemberList(ol,quickIndex,
3359 multiPageIndex ? letter : std::string(),
3360 index.isFileIndexLetterUsed(hl),
3362 endFile(ol);
3363 first=FALSE;
3364 }
3365 if (multiPageIndex && addToIndex) Doxygen::indexList->decContentsDepth();
3366 ol.popGeneratorState();
3367}
const char * fname
Definition index.cpp:3239

References FileMemberHighlight::All, Config_getBool, OutputList::disableAllBut(), endFile(), endQuickIndexItem(), endQuickIndexList(), OutputList::endQuickIndices(), OutputList::endTextBlock(), FALSE, LayoutNavEntry::find(), fixSpaces(), FmhlInfo::fname, getFmhlInfo(), Globals, Html, Doxygen::htmlFileExtension, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), letterToLabel(), MAX_ITEMS_BEFORE_MULTIPAGE_INDEX, maxItemsBeforeQuickIndex, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), OutputList::startFile(), startQuickIndexItem(), startQuickIndexList(), OutputList::startQuickIndices(), OutputList::startTextBlock(), theTranslator, LayoutNavEntry::title(), FileMemberHighlight::Total, TRUE, Definition::TypeFile, LayoutNavEntry::visible(), writeMemberList(), OutputList::writeQuickLinks(), writeQuickMemberIndex(), OutputList::writeSearchInfo(), OutputList::writeSplitBar(), and OutputList::writeString().

Referenced by writeFileMemberIndex().

◆ writeGraphicalClassHierarchy()

static void writeGraphicalClassHierarchy ( OutputList & ol)
static

Definition at line 1196 of file index.cpp.

1197{
1198 if (Index::instance().numHierarchyClasses()==0) return;
1200 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ClassHierarchy);
1201 QCString title = lne ? lne->title() : theTranslator->trClassHierarchy();
1202 startFile(ol,"inherits",QCString(),title,HighlightedItem::ClassHierarchy,FALSE,"hierarchy");
1203 startTitle(ol,QCString());
1204 ol.parseText(title);
1205 endTitle(ol,QCString(),QCString());
1206 ol.startContents();
1207 ol.startTextBlock();
1208 ol.startParagraph();
1209 ol.startTextLink("hierarchy",QCString());
1210 ol.parseText(theTranslator->trGotoTextualHierarchy());
1211 ol.endTextLink();
1212 ol.endParagraph();
1213 ol.endTextBlock();
1216 endFile(ol);
1217 ol.enableAll();
1218}
Represents a graphical class hierarchy.
void writeGraphicalHierarchy(DotGfxHierarchyTable &g)
Definition outputlist.h:667
void startParagraph(const QCString &classDef=QCString())
Definition outputlist.h:408
void endParagraph()
Definition outputlist.h:410
void endTextLink()
Definition outputlist.h:445
void enableAll()
void startTextLink(const QCString &file, const QCString &anchor)
Definition outputlist.h:443

References ClassHierarchy, OutputList::disableAllBut(), OutputList::enableAll(), endFile(), OutputList::endParagraph(), OutputList::endTextBlock(), OutputList::endTextLink(), endTitle(), FALSE, LayoutNavEntry::find(), Html, Index::instance(), LayoutDocManager::instance(), OutputList::parseText(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startParagraph(), OutputList::startTextBlock(), OutputList::startTextLink(), startTitle(), theTranslator, LayoutNavEntry::title(), and OutputList::writeGraphicalHierarchy().

Referenced by writeIndexHierarchyEntries().

◆ writeGraphicalExceptionHierarchy()

static void writeGraphicalExceptionHierarchy ( OutputList & ol)
static

Definition at line 1406 of file index.cpp.

1407{
1408 if (Index::instance().numHierarchyExceptions()==0) return;
1410 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ExceptionHierarchy);
1411 QCString title = lne ? lne->title() : theTranslator->trExceptionHierarchy();
1412 startFile(ol,"exceptioninherits",QCString(),title,HighlightedItem::ExceptionHierarchy,FALSE,"exceptionhierarchy");
1413 startTitle(ol,QCString());
1414 ol.parseText(title);
1415 endTitle(ol,QCString(),QCString());
1416 ol.startContents();
1417 ol.startTextBlock();
1418 ol.startParagraph();
1419 ol.startTextLink("exceptionhierarchy",QCString());
1420 ol.parseText(theTranslator->trGotoTextualHierarchy());
1421 ol.endTextLink();
1422 ol.endParagraph();
1423 ol.endTextBlock();
1426 endFile(ol);
1427 ol.enableAll();
1428}
@ ExceptionHierarchy
Definition index.h:67

References OutputList::disableAllBut(), OutputList::enableAll(), endFile(), OutputList::endParagraph(), OutputList::endTextBlock(), OutputList::endTextLink(), endTitle(), ClassDef::Exception, ExceptionHierarchy, FALSE, LayoutNavEntry::find(), Html, Index::instance(), LayoutDocManager::instance(), OutputList::parseText(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startParagraph(), OutputList::startTextBlock(), OutputList::startTextLink(), startTitle(), theTranslator, LayoutNavEntry::title(), and OutputList::writeGraphicalHierarchy().

Referenced by writeIndexHierarchyEntries().

◆ writeGraphicalInterfaceHierarchy()

static void writeGraphicalInterfaceHierarchy ( OutputList & ol)
static

Definition at line 1301 of file index.cpp.

1302{
1303 if (Index::instance().numHierarchyInterfaces()==0) return;
1305 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::InterfaceHierarchy);
1306 QCString title = lne ? lne->title() : theTranslator->trInterfaceHierarchy();
1307 startFile(ol,"interfaceinherits",QCString(),title,HighlightedItem::InterfaceHierarchy,FALSE,"interfacehierarchy");
1308 startTitle(ol,QCString());
1309 ol.parseText(title);
1310 endTitle(ol,QCString(),QCString());
1311 ol.startContents();
1312 ol.startTextBlock();
1313 ol.startParagraph();
1314 ol.startTextLink("interfacehierarchy",QCString());
1315 ol.parseText(theTranslator->trGotoTextualHierarchy());
1316 ol.endTextLink();
1317 ol.endParagraph();
1318 ol.endTextBlock();
1321 endFile(ol);
1322 ol.enableAll();
1323}
@ InterfaceHierarchy
Definition index.h:66

References OutputList::disableAllBut(), OutputList::enableAll(), endFile(), OutputList::endParagraph(), OutputList::endTextBlock(), OutputList::endTextLink(), endTitle(), FALSE, LayoutNavEntry::find(), Html, Index::instance(), LayoutDocManager::instance(), ClassDef::Interface, InterfaceHierarchy, OutputList::parseText(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startParagraph(), OutputList::startTextBlock(), OutputList::startTextLink(), startTitle(), theTranslator, LayoutNavEntry::title(), and OutputList::writeGraphicalHierarchy().

Referenced by writeIndexHierarchyEntries().

◆ writeGraphInfo()

void writeGraphInfo ( OutputList & ol)

Definition at line 3946 of file index.cpp.

3947{
3948 if (!Config_getBool(HAVE_DOT) || !Config_getBool(GENERATE_HTML)) return;
3949 ol.pushGeneratorState();
3951
3952 DotLegendGraph gd;
3953 gd.writeGraph(Config_getString(HTML_OUTPUT));
3954
3955 bool oldStripCommentsState = Config_getBool(STRIP_CODE_COMMENTS);
3956 bool oldCreateSubdirs = Config_getBool(CREATE_SUBDIRS);
3957 // temporarily disable the stripping of comments for our own code example!
3958 Config_updateBool(STRIP_CODE_COMMENTS,FALSE);
3959 // temporarily disable create subdirs for linking to our example
3960 Config_updateBool(CREATE_SUBDIRS,FALSE);
3961
3962 startFile(ol,"graph_legend",QCString(),theTranslator->trLegendTitle());
3963 startTitle(ol,QCString());
3964 ol.parseText(theTranslator->trLegendTitle());
3965 endTitle(ol,QCString(),QCString());
3966 ol.startContents();
3967 QCString legendDocs = theTranslator->trLegendDocs();
3968 int s = legendDocs.find("<center>");
3969 int e = legendDocs.find("</center>");
3970 QCString imgExt = getDotImageExtension();
3971 if (imgExt=="svg" && s!=-1 && e!=-1)
3972 {
3973 legendDocs = legendDocs.left(s+8) + "[!-- " + "SVG 0 --]" + legendDocs.mid(e);
3974 //printf("legendDocs=%s\n",qPrint(legendDocs));
3975 }
3976
3977 {
3978 auto fd = createFileDef("","graph_legend.dox");
3979 ol.generateDoc("graph_legend",1,fd.get(),nullptr,legendDocs,FALSE,FALSE,
3981 }
3982
3983 // restore config settings
3984 Config_updateBool(STRIP_CODE_COMMENTS,oldStripCommentsState);
3985 Config_updateBool(CREATE_SUBDIRS,oldCreateSubdirs);
3986
3987 endFile(ol);
3988 ol.popGeneratorState();
3989}
Representation of a legend explaining the meaning of boxes, arrows, and colors.
void writeGraph(const QCString &path)
QCString mid(size_t index, size_t len=static_cast< size_t >(-1)) const
Definition qcstring.h:226
QCString left(size_t len) const
Definition qcstring.h:214
#define Config_updateBool(name, value)
Definition config.h:40
std::unique_ptr< FileDef > createFileDef(const QCString &p, const QCString &n, const QCString &ref, const QCString &dn)
Definition filedef.cpp:265
QCString getDotImageExtension()
Definition util.cpp:6616

References Config_getBool, Config_getString, Config_updateBool, createFileDef(), OutputList::disableAllBut(), endFile(), endTitle(), FALSE, QCString::find(), OutputList::generateDoc(), getDotImageExtension(), Html, QCString::left(), QCString::mid(), OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), OutputList::startContents(), startFile(), startTitle(), theTranslator, and DotLegendGraph::writeGraph().

Referenced by generateOutput().

◆ writeGroupHierarchy()

static void writeGroupHierarchy ( OutputList & ol,
FTVHelp * ftv,
bool addToIndex )
static

Definition at line 4228 of file index.cpp.

4229{
4230 if (ftv)
4231 {
4232 ol.pushGeneratorState();
4234 }
4235 startIndexHierarchy(ol,0);
4236 for (const auto &gd : *Doxygen::groupLinkedMap)
4237 {
4238 if (gd->isVisibleInHierarchy())
4239 {
4240 writeGroupTreeNode(ol,gd.get(),0,ftv,addToIndex);
4241 }
4242 }
4243 endIndexHierarchy(ol,0);
4244 if (ftv)
4245 {
4246 ol.popGeneratorState();
4247 }
4248}
static void writeGroupTreeNode(OutputList &ol, const GroupDef *gd, int level, FTVHelp *ftv, bool addToIndex)
Definition index.cpp:3997

References OutputList::disable(), endIndexHierarchy(), Doxygen::groupLinkedMap, Html, OutputList::popGeneratorState(), OutputList::pushGeneratorState(), startIndexHierarchy(), and writeGroupTreeNode().

Referenced by writeTopicIndex().

◆ writeGroupTreeNode()

static void writeGroupTreeNode ( OutputList & ol,
const GroupDef * gd,
int level,
FTVHelp * ftv,
bool addToIndex )
static

write groups as hierarchical trees

Definition at line 3997 of file index.cpp.

3998{
3999 //bool fortranOpt = Config_getBool(OPTIMIZE_FOR_FORTRAN);
4000 //bool vhdlOpt = Config_getBool(OPTIMIZE_OUTPUT_VHDL);
4001 if (level>20)
4002 {
4003 warn(gd->getDefFileName(),gd->getDefLine(),
4004 "maximum nesting level exceeded for group %s: check for possible recursive group relation!",qPrint(gd->name())
4005 );
4006 return;
4007 }
4008
4009 /* Some groups should appear twice under different parent-groups.
4010 * That is why we should not check if it was visited
4011 */
4012 if ((!gd->isASubGroup() || level>0) && gd->isVisible() && gd->isVisibleInHierarchy())
4013 {
4014 //printf("gd->name()=%s #members=%d\n",qPrint(gd->name()),gd->countMembers());
4015 // write group info
4016 bool hasSubGroups = !gd->getSubGroups().empty();
4017 bool hasSubPages = !gd->getPages().empty();
4018 size_t numSubItems = 0;
4019 for (const auto &ml : gd->getMemberLists())
4020 {
4021 if (ml->listType().isDocumentation())
4022 {
4023 numSubItems += ml->size();
4024 }
4025 }
4026 numSubItems += gd->getNamespaces().size();
4027 numSubItems += gd->getClasses().size();
4028 numSubItems += gd->getFiles().size();
4029 numSubItems += gd->getConcepts().size();
4030 numSubItems += gd->getDirs().size();
4031 numSubItems += gd->getPages().size();
4032
4033 bool isDir = hasSubGroups || hasSubPages || numSubItems>0;
4034 //printf("gd='%s': pageDict=%d\n",qPrint(gd->name()),gd->pageDict->count());
4035 if (addToIndex)
4036 {
4037 Doxygen::indexList->addContentsItem(isDir,gd->groupTitle(),gd->getReference(),gd->getOutputFileBase(),QCString(),isDir,TRUE);
4038 Doxygen::indexList->incContentsDepth();
4039 }
4040 if (ftv)
4041 {
4042 ftv->addContentsItem(hasSubGroups,gd->groupTitle(),
4044 FALSE,FALSE,gd);
4045 ftv->incContentsDepth();
4046 }
4047
4048 //ol.writeListItem();
4049 //ol.startTextLink(gd->getOutputFileBase(),0);
4050 //parseText(ol,gd->groupTitle());
4051 //ol.endTextLink();
4052
4053 ol.startIndexListItem();
4055 ol.parseText(gd->groupTitle());
4057 if (gd->isReference())
4058 {
4059 ol.startTypewriter();
4060 ol.docify(" [external]");
4061 ol.endTypewriter();
4062 }
4063
4064 for (const auto &lde : LayoutDocManager::instance().docEntries(LayoutDocManager::Group))
4065 {
4066 if (lde->kind()==LayoutDocEntry::MemberDef && addToIndex)
4067 {
4068 const LayoutDocEntryMemberDef *lmd = dynamic_cast<const LayoutDocEntryMemberDef*>(lde.get());
4069 if (lmd)
4070 {
4071 MemberList *ml = gd->getMemberList(lmd->type);
4072 if (ml)
4073 {
4074 for (const auto &md : *ml)
4075 {
4076 const MemberVector &enumList = md->enumFieldList();
4077 isDir = !enumList.empty() && md->isEnumerate();
4078 if (md->isVisible() && !md->isAnonymous())
4079 {
4080 Doxygen::indexList->addContentsItem(isDir,
4081 md->qualifiedName(),md->getReference(),
4082 md->getOutputFileBase(),md->anchor(),FALSE,addToIndex);
4083 }
4084 if (isDir)
4085 {
4086 Doxygen::indexList->incContentsDepth();
4087 for (const auto &emd : enumList)
4088 {
4089 if (emd->isVisible())
4090 {
4091 Doxygen::indexList->addContentsItem(FALSE,
4092 emd->qualifiedName(),emd->getReference(),emd->getOutputFileBase(),
4093 emd->anchor(),FALSE,addToIndex);
4094 }
4095 }
4096 Doxygen::indexList->decContentsDepth();
4097 }
4098 }
4099 }
4100 }
4101 }
4102 else if (lde->kind()==LayoutDocEntry::GroupClasses && addToIndex)
4103 {
4104 for (const auto &cd : gd->getClasses())
4105 {
4106 //bool nestedClassInSameGroup =
4107 // cd->getOuterScope() && cd->getOuterScope()->definitionType()==Definition::TypeClass &&
4108 // cd->getOuterScope()->partOfGroups().empty() && cd->getOuterScope()->partOfGroups()->contains(gd);
4109 //printf("===== GroupClasses: %s visible=%d nestedClassInSameGroup=%d\n",qPrint(cd->name()),cd->isVisible(),nestedClassInSameGroup);
4110 if (cd->isVisible() /*&& !nestedClassInSameGroup*/)
4111 {
4113 LayoutDocManager::Class,
4114 cd->displayName(),
4115 cd->anchor(),
4116 addToIndex,
4117 TRUE);
4118 }
4119 }
4120 }
4121 else if (lde->kind()==LayoutDocEntry::GroupNamespaces && addToIndex && Config_getBool(SHOW_NAMESPACES))
4122 {
4123 for (const auto &nd : gd->getNamespaces())
4124 {
4125 if (nd->isVisible())
4126 {
4127 Doxygen::indexList->addContentsItem(FALSE,
4128 nd->displayName(),nd->getReference(),
4129 nd->getOutputFileBase(),QCString(),FALSE,Config_getBool(SHOW_NAMESPACES));
4130 }
4131 }
4132 }
4133 else if (lde->kind()==LayoutDocEntry::GroupConcepts && addToIndex)
4134 {
4135 for (const auto &cd : gd->getConcepts())
4136 {
4137 if (cd->isVisible())
4138 {
4139 Doxygen::indexList->addContentsItem(FALSE,
4140 cd->displayName(),cd->getReference(),
4141 cd->getOutputFileBase(),QCString(),FALSE,addToIndex);
4142 }
4143 }
4144 }
4145 else if (lde->kind()==LayoutDocEntry::GroupFiles && addToIndex)
4146 {
4147 for (const auto &fd : gd->getFiles())
4148 {
4149 if (fd->isVisible())
4150 {
4151 Doxygen::indexList->addContentsItem(FALSE,
4152 fd->displayName(),fd->getReference(),
4153 fd->getOutputFileBase(),QCString(),FALSE,fd->isLinkableViaGroup());
4154 }
4155 }
4156 }
4157 else if (lde->kind()==LayoutDocEntry::GroupDirs && addToIndex)
4158 {
4159 for (const auto &dd : gd->getDirs())
4160 {
4161 if (dd->isVisible())
4162 {
4163 Doxygen::indexList->addContentsItem(FALSE,
4164 dd->shortName(),dd->getReference(),
4165 dd->getOutputFileBase(),QCString(),FALSE,FALSE);
4166 }
4167 }
4168 }
4169 else if (lde->kind()==LayoutDocEntry::GroupPageDocs && addToIndex)
4170 {
4171 for (const auto &pd : gd->getPages())
4172 {
4173 const SectionInfo *si=nullptr;
4174 if (!pd->name().isEmpty()) si=SectionManager::instance().find(pd->name());
4175 hasSubPages = pd->hasSubPages();
4176 bool hasSections = pd->hasSections();
4177 Doxygen::indexList->addContentsItem(
4178 hasSubPages || hasSections,
4179 pd->title(),
4180 gd->getReference(),
4181 gd->getOutputFileBase(),
4182 si ? si->label() : QCString(),
4183 hasSubPages || hasSections,
4184 TRUE); // addToNavIndex
4185 if (hasSections || hasSubPages)
4186 {
4187 Doxygen::indexList->incContentsDepth();
4188 }
4189 if (hasSections)
4190 {
4191 pd->addSectionsToIndex();
4192 }
4193 writePages(pd,nullptr);
4194 if (hasSections || hasSubPages)
4195 {
4196 Doxygen::indexList->decContentsDepth();
4197 }
4198 }
4199 }
4200 else if (lde->kind()==LayoutDocEntry::GroupNestedGroups)
4201 {
4202 if (!gd->getSubGroups().empty())
4203 {
4204 startIndexHierarchy(ol,level+1);
4205 for (const auto &subgd : gd->getSubGroups())
4206 {
4207 writeGroupTreeNode(ol,subgd,level+1,ftv,addToIndex);
4208 }
4209 endIndexHierarchy(ol,level+1);
4210 }
4211 }
4212 }
4213
4214 ol.endIndexListItem();
4215
4216 if (addToIndex)
4217 {
4218 Doxygen::indexList->decContentsDepth();
4219 }
4220 if (ftv)
4221 {
4222 ftv->decContentsDepth();
4223 }
4224 //gd->visited=TRUE;
4225 }
4226}
virtual bool isVisible() const =0
virtual const DirList & getDirs() const =0
virtual const GroupList & getSubGroups() const =0
virtual QCString groupTitle() 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
const T * find(const std::string &key) const
Find an object given the key.
Definition linkedmap.h:47
size_t size() const
Definition linkedmap.h:375
bool empty() const
Definition linkedmap.h:374
A vector of MemberDef object.
Definition memberlist.h:34
bool empty() const noexcept
Definition memberlist.h:59
class that provide information about a section.
Definition section.h:57
QCString label() const
Definition section.h:68
static SectionManager & instance()
returns a reference to the singleton
Definition section.h:175
static void writePages(PageDef *pd, FTVHelp *ftv)
Definition index.cpp:3812

References FTVHelp::addContentsItem(), addMembersToIndex(), Config_getBool, FTVHelp::decContentsDepth(), OutputList::docify(), LinkedRefMap< T, Hash, KeyEqual, Map >::empty(), MemberVector::empty(), endIndexHierarchy(), OutputList::endIndexItem(), OutputList::endIndexListItem(), OutputList::endTypewriter(), FALSE, LinkedMap< T, Hash, KeyEqual, Map >::find(), GroupDef::getClasses(), GroupDef::getConcepts(), Definition::getDefFileName(), Definition::getDefLine(), GroupDef::getDirs(), GroupDef::getFiles(), GroupDef::getMemberList(), GroupDef::getMemberLists(), GroupDef::getNamespaces(), Definition::getOutputFileBase(), GroupDef::getPages(), Definition::getReference(), GroupDef::getSubGroups(), GroupDef::groupTitle(), FTVHelp::incContentsDepth(), Doxygen::indexList, LayoutDocManager::instance(), SectionManager::instance(), GroupDef::isASubGroup(), Definition::isReference(), Definition::isVisible(), GroupDef::isVisibleInHierarchy(), SectionInfo::label(), Definition::name(), OutputList::parseText(), qPrint(), LinkedRefMap< T, Hash, KeyEqual, Map >::size(), startIndexHierarchy(), OutputList::startIndexItem(), OutputList::startIndexListItem(), OutputList::startTypewriter(), TRUE, LayoutDocEntryMemberDef::type, warn, writeGroupTreeNode(), and writePages().

Referenced by writeGroupHierarchy(), and writeGroupTreeNode().

◆ writeHierarchicalExceptionIndex()

static void writeHierarchicalExceptionIndex ( OutputList & ol)
static

Definition at line 1327 of file index.cpp.

1328{
1329 if (Index::instance().numHierarchyExceptions()==0) return;
1330 ol.pushGeneratorState();
1331 //1.{
1333
1334 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ExceptionHierarchy);
1335 QCString title = lne ? lne->title() : theTranslator->trExceptionHierarchy();
1336 bool addToIndex = lne==nullptr || lne->visible();
1337
1338 startFile(ol,"exceptionhierarchy",QCString(), title, HighlightedItem::ExceptionHierarchy);
1339 startTitle(ol,QCString());
1340 ol.parseText(title);
1341 endTitle(ol,QCString(),QCString());
1342 ol.startContents();
1343 ol.startTextBlock();
1344
1345 if (Config_getBool(HAVE_DOT) && Config_getBool(GRAPHICAL_HIERARCHY))
1346 {
1349 ol.startParagraph();
1350 ol.startTextLink("exceptioninherits",QCString());
1351 ol.parseText(theTranslator->trGotoGraphicalHierarchy());
1352 ol.endTextLink();
1353 ol.endParagraph();
1356 }
1357 ol.parseText(lne ? lne->intro() : theTranslator->trExceptionHierarchyDescription());
1358 ol.endTextBlock();
1359
1360 // ---------------
1361 // Static exception hierarchy for Latex/RTF
1362 // ---------------
1363 ol.pushGeneratorState();
1364 //2.{
1366 Doxygen::indexList->disable();
1367
1368 writeClassHierarchy(ol,nullptr,addToIndex,ClassDef::Exception);
1369
1370 Doxygen::indexList->enable();
1371 ol.popGeneratorState();
1372 //2.}
1373
1374 // ---------------
1375 // Dynamic exception hierarchical index for HTML
1376 // ---------------
1377 ol.pushGeneratorState();
1378 //2.{
1380
1381 {
1382 if (addToIndex)
1383 {
1384 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),"exceptionhierarchy",QCString(),TRUE,TRUE);
1385 }
1386 FTVHelp ftv(false);
1387 writeClassHierarchy(ol,&ftv,addToIndex,ClassDef::Exception);
1388 TextStream t;
1389 ftv.generateTreeViewInline(t);
1390 ol.pushGeneratorState();
1392 ol.writeString(t.str().c_str());
1393 ol.popGeneratorState();
1394 }
1395 ol.popGeneratorState();
1396 //2.}
1397 // ------
1398
1399 endFile(ol);
1400 ol.popGeneratorState();
1401 //1.}
1402}
void enable(OutputType o)
static void writeClassHierarchy(OutputList &ol, FTVHelp *ftv, bool addToIndex, ClassDef::CompoundType ct)
Definition index.cpp:1054

References Config_getBool, OutputList::disable(), OutputList::disableAllBut(), OutputList::enable(), endFile(), OutputList::endParagraph(), OutputList::endTextBlock(), OutputList::endTextLink(), endTitle(), ClassDef::Exception, ExceptionHierarchy, LayoutNavEntry::find(), FTVHelp::generateTreeViewInline(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), Latex, Man, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), RTF, OutputList::startContents(), startFile(), OutputList::startParagraph(), OutputList::startTextBlock(), OutputList::startTextLink(), startTitle(), TextStream::str(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), writeClassHierarchy(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writeHierarchicalIndex()

static void writeHierarchicalIndex ( OutputList & ol)
static

Definition at line 1115 of file index.cpp.

1116{
1117 if (Index::instance().numHierarchyClasses()==0) return;
1118 ol.pushGeneratorState();
1119 //1.{
1122
1123 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ClassHierarchy);
1124 QCString title = lne ? lne->title() : theTranslator->trClassHierarchy();
1125 bool addToIndex = lne==nullptr || lne->visible();
1126
1127 startFile(ol,"hierarchy",QCString(), title, HighlightedItem::ClassHierarchy);
1128 startTitle(ol,QCString());
1129 ol.parseText(title);
1130 endTitle(ol,QCString(),QCString());
1131 ol.startContents();
1132 ol.startTextBlock();
1133
1134 if (Config_getBool(HAVE_DOT) && Config_getBool(GRAPHICAL_HIERARCHY))
1135 {
1136 ol.pushGeneratorState();
1140 ol.startParagraph();
1141 ol.startTextLink("inherits",QCString());
1142 ol.parseText(theTranslator->trGotoGraphicalHierarchy());
1143 ol.endTextLink();
1144 ol.endParagraph();
1145 ol.popGeneratorState();
1146 }
1147 ol.parseText(lne ? lne->intro() : theTranslator->trClassHierarchyDescription());
1148 ol.endTextBlock();
1149
1150 // ---------------
1151 // Static class hierarchy for Latex/RTF
1152 // ---------------
1153 ol.pushGeneratorState();
1154 //2.{
1156 Doxygen::indexList->disable();
1157
1158 writeClassHierarchy(ol,nullptr,addToIndex,ClassDef::Class);
1159
1160 Doxygen::indexList->enable();
1161 ol.popGeneratorState();
1162 //2.}
1163
1164 // ---------------
1165 // Dynamic class hierarchical index for HTML
1166 // ---------------
1167 ol.pushGeneratorState();
1168 //2.{
1170
1171 {
1172 if (addToIndex)
1173 {
1174 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),"hierarchy",QCString(),TRUE,TRUE);
1175 }
1176 FTVHelp ftv(false);
1177 writeClassHierarchy(ol,&ftv,addToIndex,ClassDef::Class);
1178 TextStream t;
1179 ftv.generateTreeViewInline(t);
1180 ol.pushGeneratorState();
1182 ol.writeString(t.str().c_str());
1183 ol.popGeneratorState();
1184 }
1185 ol.popGeneratorState();
1186 //2.}
1187 // ------
1188
1189 endFile(ol);
1190 ol.popGeneratorState();
1191 //1.}
1192}

References ClassDef::Class, ClassHierarchy, Config_getBool, OutputList::disable(), OutputList::disableAllBut(), Docbook, endFile(), OutputList::endParagraph(), OutputList::endTextBlock(), OutputList::endTextLink(), endTitle(), LayoutNavEntry::find(), FTVHelp::generateTreeViewInline(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), Latex, Man, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), RTF, OutputList::startContents(), startFile(), OutputList::startParagraph(), OutputList::startTextBlock(), OutputList::startTextLink(), startTitle(), TextStream::str(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), writeClassHierarchy(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writeHierarchicalInterfaceIndex()

static void writeHierarchicalInterfaceIndex ( OutputList & ol)
static

Definition at line 1222 of file index.cpp.

1223{
1224 if (Index::instance().numHierarchyInterfaces()==0) return;
1225 ol.pushGeneratorState();
1226 //1.{
1228
1229 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::InterfaceHierarchy);
1230 QCString title = lne ? lne->title() : theTranslator->trInterfaceHierarchy();
1231 bool addToIndex = lne==nullptr || lne->visible();
1232
1233 startFile(ol,"interfacehierarchy",QCString(), title, HighlightedItem::InterfaceHierarchy);
1234 startTitle(ol,QCString());
1235 ol.parseText(title);
1236 endTitle(ol,QCString(),QCString());
1237 ol.startContents();
1238 ol.startTextBlock();
1239
1240 if (Config_getBool(HAVE_DOT) && Config_getBool(GRAPHICAL_HIERARCHY))
1241 {
1244 ol.startParagraph();
1245 ol.startTextLink("interfaceinherits",QCString());
1246 ol.parseText(theTranslator->trGotoGraphicalHierarchy());
1247 ol.endTextLink();
1248 ol.endParagraph();
1251 }
1252 ol.parseText(lne ? lne->intro() : theTranslator->trInterfaceHierarchyDescription());
1253 ol.endTextBlock();
1254
1255 // ---------------
1256 // Static interface hierarchy for Latex/RTF
1257 // ---------------
1258 ol.pushGeneratorState();
1259 //2.{
1261 Doxygen::indexList->disable();
1262
1263 writeClassHierarchy(ol,nullptr,addToIndex,ClassDef::Interface);
1264
1265 Doxygen::indexList->enable();
1266 ol.popGeneratorState();
1267 //2.}
1268
1269 // ---------------
1270 // Dynamic interface hierarchical index for HTML
1271 // ---------------
1272 ol.pushGeneratorState();
1273 //2.{
1275
1276 {
1277 if (addToIndex)
1278 {
1279 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),"interfacehierarchy",QCString(),TRUE,TRUE);
1280 }
1281 FTVHelp ftv(false);
1282 writeClassHierarchy(ol,&ftv,addToIndex,ClassDef::Interface);
1283 TextStream t;
1284 ftv.generateTreeViewInline(t);
1285 ol.pushGeneratorState();
1287 ol.writeString(t.str().c_str());
1288 ol.popGeneratorState();
1289 }
1290 ol.popGeneratorState();
1291 //2.}
1292 // ------
1293
1294 endFile(ol);
1295 ol.popGeneratorState();
1296 //1.}
1297}

References Config_getBool, OutputList::disable(), OutputList::disableAllBut(), OutputList::enable(), endFile(), OutputList::endParagraph(), OutputList::endTextBlock(), OutputList::endTextLink(), endTitle(), LayoutNavEntry::find(), FTVHelp::generateTreeViewInline(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), ClassDef::Interface, InterfaceHierarchy, LayoutNavEntry::intro(), Latex, Man, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), RTF, OutputList::startContents(), startFile(), OutputList::startParagraph(), OutputList::startTextBlock(), OutputList::startTextLink(), startTitle(), TextStream::str(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), writeClassHierarchy(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writeIndex()

static void writeIndex ( OutputList & ol)
static

Definition at line 4709 of file index.cpp.

4710{
4711 bool fortranOpt = Config_getBool(OPTIMIZE_FOR_FORTRAN);
4712 bool vhdlOpt = Config_getBool(OPTIMIZE_OUTPUT_VHDL);
4713 QCString projectName = Config_getString(PROJECT_NAME);
4714 // save old generator state
4715 ol.pushGeneratorState();
4716
4717 QCString projPrefix;
4718 if (!projectName.isEmpty())
4719 {
4720 projPrefix=projectName+" ";
4721 }
4722
4723 //--------------------------------------------------------------------
4724 // write HTML index
4725 //--------------------------------------------------------------------
4727
4728 QCString defFileName =
4729 Doxygen::mainPage ? Doxygen::mainPage->docFile() : QCString("[generated]");
4730 int defLine =
4731 Doxygen::mainPage ? Doxygen::mainPage->docLine() : -1;
4732
4733 QCString title;
4734 if (!mainPageHasTitle())
4735 {
4736 title = theTranslator->trMainPage();
4737 }
4738 else if (Doxygen::mainPage)
4739 {
4740 title = filterTitle(Doxygen::mainPage->title());
4741 }
4742
4743 QCString indexName="index";
4744 ol.startFile(indexName,QCString(),title);
4745
4747 {
4748 bool hasSubs = Doxygen::mainPage->hasSubPages() || Doxygen::mainPage->hasSections();
4749 bool hasTitle = !projectName.isEmpty() && mainPageHasTitle() && qstricmp(title,projectName)!=0;
4750 //printf("** mainPage title=%s hasTitle=%d hasSubs=%d\n",qPrint(title),hasTitle,hasSubs);
4751 if (hasTitle) // to avoid duplicate entries in the treeview
4752 {
4753 Doxygen::indexList->addContentsItem(hasSubs,
4754 title,
4755 QCString(),
4756 indexName,
4757 QCString(),
4758 hasSubs,
4759 TRUE);
4760 }
4761 if (hasSubs)
4762 {
4763 writePages(Doxygen::mainPage.get(),nullptr);
4764 }
4765 }
4766
4767 ol.startQuickIndices();
4768 if (!Config_getBool(DISABLE_INDEX))
4769 {
4771 }
4772 ol.endQuickIndices();
4773 ol.writeSplitBar(indexName);
4774 ol.writeSearchInfo();
4775 bool headerWritten=FALSE;
4777 {
4778 if (!Doxygen::mainPage->title().isEmpty())
4779 {
4780 if (Doxygen::mainPage->title().lower() != "notitle")
4781 ol.startPageDoc(Doxygen::mainPage->title());
4782 else
4783 ol.startPageDoc("");
4784 }
4785 else
4786 ol.startPageDoc(projectName);
4787 }
4788 if (Doxygen::mainPage && !Doxygen::mainPage->title().isEmpty())
4789 {
4790 if (Doxygen::mainPage->title().lower()!="notitle")
4791 {
4792 ol.startHeaderSection();
4794 ol.generateDoc(Doxygen::mainPage->docFile(),Doxygen::mainPage->getStartBodyLine(),
4795 Doxygen::mainPage.get(),nullptr,Doxygen::mainPage->title(),false,false,
4796 QCString(),true,false,Config_getBool(MARKDOWN_SUPPORT));
4797 headerWritten = TRUE;
4798 }
4799 }
4800 else
4801 {
4802 if (!projectName.isEmpty())
4803 {
4804 ol.startHeaderSection();
4806 ol.parseText(theTranslator->trDocumentation(projectName));
4807 headerWritten = TRUE;
4808 }
4809 }
4810 if (headerWritten)
4811 {
4813 ol.endHeaderSection();
4814 }
4815
4816 ol.startContents();
4817 if (Config_getBool(DISABLE_INDEX) && Doxygen::mainPage==nullptr)
4818 {
4820 }
4821
4823 {
4824 if (Doxygen::mainPage->localToc().isHtmlEnabled() && Doxygen::mainPage->hasSections())
4825 {
4826 Doxygen::mainPage->writeToc(ol,Doxygen::mainPage->localToc());
4827 }
4828
4829 ol.startTextBlock();
4830 ol.generateDoc(defFileName,defLine,Doxygen::mainPage.get(),nullptr,
4831 Doxygen::mainPage->documentation(),true,false,
4832 QCString(),false,false,Config_getBool(MARKDOWN_SUPPORT));
4833 ol.endTextBlock();
4834 ol.endPageDoc();
4835 }
4836
4839 ol.writeString("<a href=\"" + fn + "\"></a>\n");
4840 Doxygen::indexList->addIndexFile(fn);
4841
4842 endFile(ol);
4843
4845
4846 //--------------------------------------------------------------------
4847 // write LaTeX/RTF index
4848 //--------------------------------------------------------------------
4852
4854 {
4855 msg("Generating main page...\n");
4856 Doxygen::mainPage->writeDocumentation(ol);
4857 }
4858
4859 ol.startFile("refman",QCString(),QCString());
4863
4864 if (projPrefix.isEmpty())
4865 {
4866 ol.parseText(theTranslator->trReferenceManual());
4867 }
4868 else
4869 {
4870 ol.parseText(projPrefix);
4871 }
4872
4873 if (!Config_getString(PROJECT_NUMBER).isEmpty())
4874 {
4875 ol.startProjectNumber();
4876 ol.generateDoc(defFileName,defLine,Doxygen::mainPage.get(),nullptr,Config_getString(PROJECT_NUMBER),false,false,
4877 QCString(),false,false,Config_getBool(MARKDOWN_SUPPORT));
4878 ol.endProjectNumber();
4879 }
4882 ol.parseText(theTranslator->trGeneratedBy());
4886
4887 ol.lastIndexPage();
4889 {
4892 }
4893 const auto &index = Index::instance();
4894 if (index.numDocumentedPages()>0)
4895 {
4898 }
4899
4901 if (!Config_getBool(LATEX_HIDE_INDICES))
4902 {
4903 //if (indexedPages>0)
4904 //{
4905 // ol.startIndexSection(isPageIndex);
4906 // ol.parseText(/*projPrefix+*/ theTranslator->trPageIndex());
4907 // ol.endIndexSection(isPageIndex);
4908 //}
4909 if (index.numDocumentedModules()>0)
4910 {
4912 ol.parseText(/*projPrefix+*/ theTranslator->trModuleIndex());
4914 }
4915 if (index.numDocumentedGroups()>0)
4916 {
4918 ol.parseText(/*projPrefix+*/ theTranslator->trTopicIndex());
4920 }
4921 if (Config_getBool(SHOW_NAMESPACES) && (index.numDocumentedNamespaces()>0))
4922 {
4923 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Namespaces);
4924 if (lne)
4925 {
4927 ol.parseText(/*projPrefix+*/(fortranOpt?theTranslator->trModulesIndex():theTranslator->trNamespaceIndex()));
4929 }
4930 }
4931 if (index.numDocumentedConcepts()>0)
4932 {
4934 ol.parseText(/*projPrefix+*/theTranslator->trConceptIndex());
4936 }
4937 if (index.numHierarchyInterfaces()>0)
4938 {
4940 ol.parseText(/*projPrefix+*/theTranslator->trHierarchicalIndex());
4942 }
4943 if (index.numHierarchyClasses()>0)
4944 {
4945 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ClassHierarchy);
4946 if (lne)
4947 {
4949 ol.parseText(/*projPrefix+*/
4950 (fortranOpt ? theTranslator->trCompoundIndexFortran() :
4951 vhdlOpt ? theTranslator->trHierarchicalIndex() :
4952 theTranslator->trHierarchicalIndex()
4953 ));
4955 }
4956 }
4957 if (index.numHierarchyExceptions()>0)
4958 {
4960 ol.parseText(/*projPrefix+*/theTranslator->trHierarchicalIndex());
4962 }
4963 if (index.numAnnotatedInterfacesPrinted()>0)
4964 {
4966 ol.parseText(/*projPrefix+*/theTranslator->trInterfaceIndex());
4968 }
4969 if (index.numAnnotatedClassesPrinted()>0)
4970 {
4972 ol.parseText(/*projPrefix+*/
4973 (fortranOpt ? theTranslator->trCompoundIndexFortran() :
4974 vhdlOpt ? theTranslator->trDesignUnitIndex() :
4975 theTranslator->trCompoundIndex()
4976 ));
4978 }
4979 if (index.numAnnotatedStructsPrinted()>0)
4980 {
4982 ol.parseText(/*projPrefix+*/theTranslator->trStructIndex());
4984 }
4985 if (index.numAnnotatedExceptionsPrinted()>0)
4986 {
4988 ol.parseText(/*projPrefix+*/theTranslator->trExceptionIndex());
4990 }
4991 if (Config_getBool(SHOW_FILES) && index.numDocumentedFiles()>0)
4992 {
4994 ol.parseText(/*projPrefix+*/theTranslator->trFileIndex());
4996 }
4997 }
4999
5000 if (index.numDocumentedModules()>0)
5001 {
5003 ol.parseText(/*projPrefix+*/theTranslator->trModuleDocumentation());
5005 }
5006 if (index.numDocumentedGroups()>0)
5007 {
5009 ol.parseText(/*projPrefix+*/theTranslator->trTopicDocumentation());
5011 }
5012 if (index.numDocumentedNamespaces()>0)
5013 {
5015 ol.parseText(/*projPrefix+*/(fortranOpt?theTranslator->trModuleDocumentation():theTranslator->trNamespaceDocumentation()));
5017 }
5018 if (index.numDocumentedConcepts()>0)
5019 {
5021 ol.parseText(/*projPrefix+*/theTranslator->trConceptDocumentation());
5023 }
5024 if (index.numAnnotatedInterfacesPrinted()>0)
5025 {
5027 ol.parseText(/*projPrefix+*/theTranslator->trInterfaceDocumentation());
5029 }
5030 if (index.numAnnotatedClassesPrinted()>0)
5031 {
5033 ol.parseText(/*projPrefix+*/(fortranOpt?theTranslator->trTypeDocumentation():theTranslator->trClassDocumentation()));
5035 }
5036 if (index.numAnnotatedStructsPrinted()>0)
5037 {
5039 ol.parseText(/*projPrefix+*/theTranslator->trStructDocumentation());
5041 }
5042 if (index.numAnnotatedExceptionsPrinted()>0)
5043 {
5045 ol.parseText(/*projPrefix+*/theTranslator->trExceptionDocumentation());
5047 }
5048 if (Config_getBool(SHOW_FILES) && index.numDocumentedFiles()>0)
5049 {
5051 ol.parseText(/*projPrefix+*/theTranslator->trFileDocumentation());
5053 }
5054 if (!Doxygen::exampleLinkedMap->empty())
5055 {
5057 ol.parseText(/*projPrefix+*/theTranslator->trExamples());
5059 }
5061 endFile(ol);
5062
5063 ol.popGeneratorState();
5064}
static const QCString crawlFileName
Definition sitemap.h:75
void endPageDoc()
Definition outputlist.h:623
void endIndexSection(IndexSection is)
Definition outputlist.h:388
void startProjectNumber()
Definition outputlist.h:392
void lastIndexPage()
Definition outputlist.h:673
void startPageDoc(const QCString &pageTitle)
Definition outputlist.h:621
void endProjectNumber()
Definition outputlist.h:394
void startIndexSection(IndexSection is)
Definition outputlist.h:386
@ isMainPage
Definition index.h:35
@ isTitlePageAuthor
Definition index.h:34
@ isFileIndex
Definition index.h:43
@ isFileDocumentation
Definition index.h:51
@ isPageDocumentation
Definition index.h:53
@ isModuleDocumentation
Definition index.h:45
@ isClassHierarchyIndex
Definition index.h:41
@ isModuleIndex
Definition index.h:36
@ isTopicIndex
Definition index.h:37
@ isConceptIndex
Definition index.h:40
@ isExampleDocumentation
Definition index.h:52
@ isClassDocumentation
Definition index.h:49
@ isCompoundIndex
Definition index.h:42
@ isEndIndex
Definition index.h:55
@ isConceptDocumentation
Definition index.h:50
@ isNamespaceIndex
Definition index.h:39
@ isNamespaceDocumentation
Definition index.h:48
@ isTitlePageStart
Definition index.h:33
@ isTopicDocumentation
Definition index.h:46
void msg(const char *fmt,...)
Definition message.cpp:98
void addHtmlExtensionIfMissing(QCString &fName)
Definition util.cpp:5243

References addHtmlExtensionIfMissing(), Config_getBool, Config_getString, Crawlmap::crawlFileName, OutputList::disable(), OutputList::disableAllBut(), Docbook, OutputList::enable(), endFile(), OutputList::endHeaderSection(), OutputList::endIndexSection(), OutputList::endPageDoc(), OutputList::endProjectNumber(), OutputList::endQuickIndices(), OutputList::endTextBlock(), OutputList::endTitleHead(), Doxygen::exampleLinkedMap, FALSE, filterTitle(), LayoutNavEntry::find(), OutputList::generateDoc(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), isClassDocumentation, isClassHierarchyIndex, isCompoundIndex, isConceptDocumentation, isConceptIndex, QCString::isEmpty(), isEndIndex, isExampleDocumentation, isFileDocumentation, isFileIndex, isMainPage, isModuleDocumentation, isModuleIndex, isNamespaceDocumentation, isNamespaceIndex, isPageDocumentation, isTitlePageAuthor, isTitlePageStart, isTopicDocumentation, isTopicIndex, OutputList::lastIndexPage(), Latex, Main, Doxygen::mainPage, mainPageHasTitle(), msg(), OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), qstricmp(), LayoutDocManager::rootNavEntry(), RTF, OutputList::startContents(), OutputList::startFile(), OutputList::startHeaderSection(), OutputList::startIndexSection(), OutputList::startPageDoc(), OutputList::startProjectNumber(), OutputList::startQuickIndices(), OutputList::startTextBlock(), OutputList::startTitleHead(), theTranslator, TRUE, writePages(), OutputList::writeQuickLinks(), OutputList::writeSearchInfo(), OutputList::writeSplitBar(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writeIndexHierarchy()

void writeIndexHierarchy ( OutputList & ol)

Definition at line 5587 of file index.cpp.

5588{
5589 writeMenuData();
5591 if (lne)
5592 {
5594 }
5595}
static void writeIndexHierarchyEntries(OutputList &ol, const LayoutNavEntryList &entries)
Definition index.cpp:5068
static void writeMenuData()
Definition index.cpp:5571

References LayoutNavEntry::children(), LayoutDocManager::instance(), LayoutDocManager::rootNavEntry(), writeIndexHierarchyEntries(), and writeMenuData().

Referenced by generateOutput().

◆ writeIndexHierarchyEntries()

static void writeIndexHierarchyEntries ( OutputList & ol,
const LayoutNavEntryList & entries )
static

Definition at line 5068 of file index.cpp.

5069{
5070 auto isRef = [](const QCString &s)
5071 {
5072 return s.startsWith("@ref") || s.startsWith("\\ref");
5073 };
5074 bool sliceOpt = Config_getBool(OPTIMIZE_OUTPUT_SLICE);
5075 const auto &index = Index::instance();
5076 for (const auto &lne : entries)
5077 {
5078 LayoutNavEntry::Kind kind = lne->kind();
5079 size_t idx = static_cast<size_t>(kind);
5080 if (idx>=indexWritten.size())
5081 {
5082 size_t oldSize = indexWritten.size();
5083 size_t newSize = idx+1;
5084 indexWritten.resize(newSize);
5085 for (size_t i=oldSize; i<newSize; i++) indexWritten.at(i)=FALSE;
5086 }
5087 //printf("starting %s kind=%d\n",qPrint(lne->title()),lne->kind());
5088 bool addToIndex=lne->visible();
5089 bool needsClosing=FALSE;
5090 if (!indexWritten.at(idx))
5091 {
5092 switch(kind)
5093 {
5094 case LayoutNavEntry::MainPage:
5095 msg("Generating index page...\n");
5096 writeIndex(ol);
5097 break;
5098 case LayoutNavEntry::Pages:
5099 msg("Generating page index...\n");
5100 writePageIndex(ol);
5101 break;
5102 case LayoutNavEntry::Topics:
5103 msg("Generating topic index...\n");
5104 writeTopicIndex(ol);
5105 break;
5106 case LayoutNavEntry::Modules:
5107 {
5108 if (index.numDocumentedModules()>0 && addToIndex)
5109 {
5110 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),lne->baseFile(),QCString());
5111 Doxygen::indexList->incContentsDepth();
5112 needsClosing=TRUE;
5113 }
5114 }
5115 break;
5116 case LayoutNavEntry::ModuleList:
5117 msg("Generating module index...\n");
5118 writeModuleIndex(ol);
5119 break;
5120 case LayoutNavEntry::ModuleMembers:
5121 msg("Generating module member index...\n");
5123 break;
5124 case LayoutNavEntry::Namespaces:
5125 {
5126 bool showNamespaces = Config_getBool(SHOW_NAMESPACES);
5127 if (showNamespaces)
5128 {
5129 if (index.numDocumentedNamespaces()>0 && addToIndex)
5130 {
5131 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),lne->baseFile(),QCString());
5132 Doxygen::indexList->incContentsDepth();
5133 needsClosing=TRUE;
5134 }
5135 if (LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Namespaces)!=lne.get()) // for backward compatibility with old layout file
5136 {
5137 msg("Generating namespace index...\n");
5139 }
5140 }
5141 }
5142 break;
5143 case LayoutNavEntry::NamespaceList:
5144 {
5145 bool showNamespaces = Config_getBool(SHOW_NAMESPACES);
5146 if (showNamespaces)
5147 {
5148 msg("Generating namespace index...\n");
5150 }
5151 }
5152 break;
5153 case LayoutNavEntry::NamespaceMembers:
5154 msg("Generating namespace member index...\n");
5156 break;
5157 case LayoutNavEntry::Classes:
5158 if (index.numAnnotatedClasses()>0 && addToIndex)
5159 {
5160 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),lne->baseFile(),QCString());
5161 Doxygen::indexList->incContentsDepth();
5162 needsClosing=TRUE;
5163 }
5164 if (LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Classes)!=lne.get()) // for backward compatibility with old layout file
5165 {
5166 msg("Generating annotated compound index...\n");
5168 }
5169 break;
5170 case LayoutNavEntry::Concepts:
5171 msg("Generating concept index...\n");
5173 break;
5174 case LayoutNavEntry::ClassList:
5175 msg("Generating annotated compound index...\n");
5177 break;
5178 case LayoutNavEntry::ClassIndex:
5179 msg("Generating alphabetical compound index...\n");
5181 break;
5182 case LayoutNavEntry::ClassHierarchy:
5183 msg("Generating hierarchical class index...\n");
5185 if (Config_getBool(HAVE_DOT) && Config_getBool(GRAPHICAL_HIERARCHY))
5186 {
5187 msg("Generating graphical class hierarchy...\n");
5189 }
5190 break;
5191 case LayoutNavEntry::ClassMembers:
5192 if (!sliceOpt)
5193 {
5194 msg("Generating member index...\n");
5196 }
5197 break;
5198 case LayoutNavEntry::Interfaces:
5199 if (sliceOpt && index.numAnnotatedInterfaces()>0 && addToIndex)
5200 {
5201 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),lne->baseFile(),QCString());
5202 Doxygen::indexList->incContentsDepth();
5203 needsClosing=TRUE;
5204 }
5205 break;
5206 case LayoutNavEntry::InterfaceList:
5207 if (sliceOpt)
5208 {
5209 msg("Generating annotated interface index...\n");
5211 }
5212 break;
5213 case LayoutNavEntry::InterfaceIndex:
5214 if (sliceOpt)
5215 {
5216 msg("Generating alphabetical interface index...\n");
5218 }
5219 break;
5220 case LayoutNavEntry::InterfaceHierarchy:
5221 if (sliceOpt)
5222 {
5223 msg("Generating hierarchical interface index...\n");
5225 if (Config_getBool(HAVE_DOT) && Config_getBool(GRAPHICAL_HIERARCHY))
5226 {
5227 msg("Generating graphical interface hierarchy...\n");
5229 }
5230 }
5231 break;
5232 case LayoutNavEntry::Structs:
5233 if (sliceOpt && index.numAnnotatedStructs()>0 && addToIndex)
5234 {
5235 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),lne->baseFile(),QCString());
5236 Doxygen::indexList->incContentsDepth();
5237 needsClosing=TRUE;
5238 }
5239 break;
5240 case LayoutNavEntry::StructList:
5241 if (sliceOpt)
5242 {
5243 msg("Generating annotated struct index...\n");
5245 }
5246 break;
5247 case LayoutNavEntry::StructIndex:
5248 if (sliceOpt)
5249 {
5250 msg("Generating alphabetical struct index...\n");
5252 }
5253 break;
5254 case LayoutNavEntry::Exceptions:
5255 if (sliceOpt && index.numAnnotatedExceptions()>0 && addToIndex)
5256 {
5257 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),lne->baseFile(),QCString());
5258 Doxygen::indexList->incContentsDepth();
5259 needsClosing=TRUE;
5260 }
5261 break;
5262 case LayoutNavEntry::ExceptionList:
5263 if (sliceOpt)
5264 {
5265 msg("Generating annotated exception index...\n");
5267 }
5268 break;
5269 case LayoutNavEntry::ExceptionIndex:
5270 if (sliceOpt)
5271 {
5272 msg("Generating alphabetical exception index...\n");
5274 }
5275 break;
5276 case LayoutNavEntry::ExceptionHierarchy:
5277 if (sliceOpt)
5278 {
5279 msg("Generating hierarchical exception index...\n");
5281 if (Config_getBool(HAVE_DOT) && Config_getBool(GRAPHICAL_HIERARCHY))
5282 {
5283 msg("Generating graphical exception hierarchy...\n");
5285 }
5286 }
5287 break;
5288 case LayoutNavEntry::Files:
5289 {
5290 if (Config_getBool(SHOW_FILES) && index.numDocumentedFiles()>0 && addToIndex)
5291 {
5292 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),lne->baseFile(),QCString());
5293 Doxygen::indexList->incContentsDepth();
5294 needsClosing=TRUE;
5295 }
5296 if (LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Files)!=lne.get()) // for backward compatibility with old layout file
5297 {
5298 msg("Generating file index...\n");
5299 writeFileIndex(ol);
5300 }
5301 }
5302 break;
5303 case LayoutNavEntry::FileList:
5304 msg("Generating file index...\n");
5305 writeFileIndex(ol);
5306 break;
5307 case LayoutNavEntry::FileGlobals:
5308 msg("Generating file member index...\n");
5310 break;
5311 case LayoutNavEntry::Examples:
5312 msg("Generating example index...\n");
5314 break;
5315 case LayoutNavEntry::User:
5316 if (addToIndex)
5317 {
5318 // prepend a ! or ^ marker to the URL to avoid tampering with it
5319 QCString url = correctURL(lne->url(),"!"); // add ! to relative URL
5320 bool isRelative=url.at(0)=='!';
5321 if (!url.isEmpty() && !isRelative) // absolute URL
5322 {
5323 url.prepend("^"); // prepend ^ to absolute URL
5324 }
5325 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),
5326 url,QCString(),FALSE,isRef(lne->baseFile()) || isRelative);
5327 }
5328 break;
5329 case LayoutNavEntry::UserGroup:
5330 if (addToIndex)
5331 {
5332 QCString url = correctURL(lne->url(),"!"); // add ! to relative URL
5333 if (!url.isEmpty())
5334 {
5335 if (url=="!") // result of a "[none]" url
5336 {
5337 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),QCString(),QCString(),FALSE,FALSE);
5338 }
5339 else
5340 {
5341 bool isRelative=url.at(0)=='!';
5342 if (!isRelative) // absolute URL
5343 {
5344 url.prepend("^"); // prepend ^ to absolute URL
5345 }
5346 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),
5347 url,QCString(),FALSE,isRef(lne->baseFile()) || isRelative);
5348 }
5349 }
5350 else
5351 {
5352 Doxygen::indexList->addContentsItem(TRUE,lne->title(),QCString(),lne->baseFile(),QCString(),TRUE,TRUE);
5353 }
5354 Doxygen::indexList->incContentsDepth();
5355 needsClosing=TRUE;
5356 }
5357 writeUserGroupStubPage(ol,lne.get());
5358 break;
5359 case LayoutNavEntry::None:
5360 assert(kind != LayoutNavEntry::None); // should never happen, means not properly initialized
5361 break;
5362 }
5363 if (kind!=LayoutNavEntry::User && kind!=LayoutNavEntry::UserGroup) // User entry may appear multiple times
5364 {
5365 indexWritten.at(idx)=TRUE;
5366 }
5367 }
5368 writeIndexHierarchyEntries(ol,lne->children());
5369 if (needsClosing)
5370 {
5371 switch(kind)
5372 {
5373 case LayoutNavEntry::Modules:
5374 case LayoutNavEntry::Namespaces:
5375 case LayoutNavEntry::Classes:
5376 case LayoutNavEntry::Files:
5377 case LayoutNavEntry::UserGroup:
5378 Doxygen::indexList->decContentsDepth();
5379 break;
5380 default:
5381 break;
5382 }
5383 }
5384 //printf("ending %s kind=%d\n",qPrint(lne->title()),lne->kind());
5385 }
5386}
QCString & prepend(const char *s)
Definition qcstring.h:407
char & at(size_t i)
Returns a reference to the character at index i.
Definition qcstring.h:567
static void writeGraphicalClassHierarchy(OutputList &ol)
Definition index.cpp:1196
static void writeAnnotatedStructIndex(OutputList &ol)
Definition index.cpp:2646
static void writeAlphabeticalExceptionIndex(OutputList &ol)
Definition index.cpp:2489
static void writeClassMemberIndex(OutputList &ol)
Definition index.cpp:3206
static std::vector< bool > indexWritten
Definition index.cpp:5066
static void writeAnnotatedIndex(OutputList &ol)
Definition index.cpp:2618
static void writeFileIndex(OutputList &ol)
Definition index.cpp:1534
static void writeGraphicalInterfaceHierarchy(OutputList &ol)
Definition index.cpp:1301
static void writeAlphabeticalIndex(OutputList &ol)
Definition index.cpp:2402
static void writeAnnotatedInterfaceIndex(OutputList &ol)
Definition index.cpp:2632
static void writePageIndex(OutputList &ol)
Definition index.cpp:3872
static void writeNamespaceIndex(OutputList &ol)
Definition index.cpp:1987
static void writeAnnotatedExceptionIndex(OutputList &ol)
Definition index.cpp:2660
static void writeHierarchicalInterfaceIndex(OutputList &ol)
Definition index.cpp:1222
static void writeUserGroupStubPage(OutputList &ol, LayoutNavEntry *lne)
Definition index.cpp:4672
static void writeTopicIndex(OutputList &ol)
Definition index.cpp:4252
static void writeModuleMemberIndex(OutputList &ol)
Definition index.cpp:3693
static void writeGraphicalExceptionHierarchy(OutputList &ol)
Definition index.cpp:1406
static void writeExampleIndex(OutputList &ol)
Definition index.cpp:3718
static void writeAlphabeticalInterfaceIndex(OutputList &ol)
Definition index.cpp:2431
static void writeAlphabeticalStructIndex(OutputList &ol)
Definition index.cpp:2460
static void writeConceptIndex(OutputList &ol)
Definition index.cpp:4566
static void writeModuleIndex(OutputList &ol)
Definition index.cpp:4392
static void writeIndex(OutputList &ol)
Definition index.cpp:4709
static void writeHierarchicalExceptionIndex(OutputList &ol)
Definition index.cpp:1327
static void writeNamespaceMemberIndex(OutputList &ol)
Definition index.cpp:3533
static void writeHierarchicalIndex(OutputList &ol)
Definition index.cpp:1115
static void writeFileMemberIndex(OutputList &ol)
Definition index.cpp:3369
Kind
Definition layout.h:177
QCString correctURL(const QCString &url, const QCString &relPath)
Corrects URL url according to the relative path relPath.
Definition util.cpp:6257

References QCString::at(), Config_getBool, correctURL(), FALSE, Doxygen::indexList, indexWritten, Index::instance(), LayoutDocManager::instance(), QCString::isEmpty(), msg(), QCString::prepend(), TRUE, writeAlphabeticalExceptionIndex(), writeAlphabeticalIndex(), writeAlphabeticalInterfaceIndex(), writeAlphabeticalStructIndex(), writeAnnotatedExceptionIndex(), writeAnnotatedIndex(), writeAnnotatedInterfaceIndex(), writeAnnotatedStructIndex(), writeClassMemberIndex(), writeConceptIndex(), writeExampleIndex(), writeFileIndex(), writeFileMemberIndex(), writeGraphicalClassHierarchy(), writeGraphicalExceptionHierarchy(), writeGraphicalInterfaceHierarchy(), writeHierarchicalExceptionIndex(), writeHierarchicalIndex(), writeHierarchicalInterfaceIndex(), writeIndex(), writeIndexHierarchyEntries(), writeModuleIndex(), writeModuleMemberIndex(), writeNamespaceIndex(), writeNamespaceMemberIndex(), writePageIndex(), writeTopicIndex(), and writeUserGroupStubPage().

Referenced by writeIndexHierarchy(), and writeIndexHierarchyEntries().

◆ writeMemberList()

static void writeMemberList ( OutputList & ol,
bool useSections,
const std::string & page,
const Index::MemberIndexMap & memberIndexMap,
Definition::DefType type )
static

Definition at line 2727 of file index.cpp.

2730{
2731 int index = static_cast<int>(type);
2732 const int numIndices = 4;
2733 ASSERT(index<numIndices);
2734
2735 typedef void (*writeLinkForMember_t)(OutputList &ol,const MemberDef *md,const QCString &separator,
2736 QCString &prevNamespaceName);
2737
2738 // each index tab has its own write function
2739 static writeLinkForMember_t writeLinkForMemberMap[numIndices] =
2740 {
2745 };
2746 QCString prevName;
2747 QCString prevDefName;
2748 bool first=TRUE;
2749 bool firstSection=TRUE;
2750 bool firstItem=TRUE;
2751 const Index::MemberIndexList *mil = nullptr;
2752 std::string letter;
2753 for (const auto &kv : memberIndexMap)
2754 {
2755 if (!page.empty()) // specific page mode
2756 {
2757 auto it = memberIndexMap.find(page);
2758 if (it != memberIndexMap.end())
2759 {
2760 mil = &it->second;
2761 letter = page;
2762 }
2763 }
2764 else // do all pages
2765 {
2766 mil = &kv.second;
2767 letter = kv.first;
2768 }
2769 if (mil==nullptr || mil->empty()) continue;
2770 for (const auto &md : *mil)
2771 {
2772 const char *sep = nullptr;
2773 bool isFunc=!md->isObjCMethod() &&
2774 (md->isFunction() || md->isSlot() || md->isSignal());
2775 QCString name=type==Definition::TypeModule ? md->qualifiedName() : md->name();
2776 int startIndex = getPrefixIndex(name);
2777 if (name.data()+startIndex!=prevName) // new entry
2778 {
2779 if ((prevName.isEmpty() ||
2780 tolower(name.at(startIndex))!=tolower(prevName.at(0))) &&
2781 useSections) // new section
2782 {
2783 if (!firstItem) ol.endItemListItem();
2784 if (!firstSection) ol.endItemList();
2785 QCString cs = letterToLabel(letter.c_str());
2786 QCString anchor=QCString("index_")+convertToId(cs);
2787 QCString title=QCString("- ")+letter.c_str()+" -";
2788 ol.startSection(anchor,title,SectionType::Subsection);
2789 ol.docify(title);
2790 ol.endSection(anchor,SectionType::Subsection);
2791 ol.startItemList();
2792 firstSection=FALSE;
2793 firstItem=TRUE;
2794 }
2795 else if (!useSections && first)
2796 {
2797 ol.startItemList();
2798 first=FALSE;
2799 }
2800
2801 // member name
2802 if (!firstItem) ol.endItemListItem();
2803 ol.startItemListItem();
2804 firstItem=FALSE;
2805 ol.docify(name);
2806 if (isFunc) ol.docify("()");
2807 //ol.writeString("\n");
2808
2809 // link to class
2810 prevDefName="";
2811 sep = "&#160;:&#160;";
2812 prevName = name.data()+startIndex;
2813 }
2814 else // same entry
2815 {
2816 sep = ", ";
2817 // link to class for other members with the same name
2818 }
2819 if (index<numIndices)
2820 {
2821 // write the link for the specific list type
2822 writeLinkForMemberMap[index](ol,md,sep,prevDefName);
2823 }
2824 }
2825 if (!page.empty())
2826 {
2827 break;
2828 }
2829 }
2830 if (!firstItem) ol.endItemListItem();
2831 ol.endItemList();
2832}
std::vector< const MemberDef * > MemberIndexList
Definition index.h:167
A model of a class/file/namespace member symbol.
Definition memberdef.h:48
Class representing a list of output generators that are written to in parallel.
Definition outputlist.h:314
static constexpr int Subsection
Definition section.h:34
static void writeFileLinkForMember(OutputList &ol, const MemberDef *md, const QCString &separator, QCString &prevFileName)
Definition index.cpp:2686
static void writeNamespaceLinkForMember(OutputList &ol, const MemberDef *md, const QCString &separator, QCString &prevNamespaceName)
Definition index.cpp:2699
static void writeClassLinkForMember(OutputList &ol, const MemberDef *md, const QCString &separator, QCString &prevClassName)
Definition index.cpp:2673
static void writeModuleLinkForMember(OutputList &ol, const MemberDef *md, const QCString &separator, QCString &prevModuleName)
Definition index.cpp:2712
#define ASSERT(x)
Definition qcstring.h:39

References ASSERT, QCString::at(), convertToId(), QCString::data(), OutputList::docify(), OutputList::endItemList(), OutputList::endItemListItem(), OutputList::endSection(), FALSE, getPrefixIndex(), QCString::isEmpty(), letterToLabel(), OutputList::startItemList(), OutputList::startItemListItem(), OutputList::startSection(), SectionType::Subsection, TRUE, Definition::TypeModule, writeClassLinkForMember(), writeFileLinkForMember(), writeModuleLinkForMember(), and writeNamespaceLinkForMember().

Referenced by writeClassMemberIndexFiltered(), writeFileMemberIndexFiltered(), writeModuleMemberIndexFiltered(), and writeNamespaceMemberIndexFiltered().

◆ writeMemberToIndex()

static void writeMemberToIndex ( const Definition * def,
const MemberDef * md,
bool addToIndex )
static

Definition at line 458 of file index.cpp.

459{
460 bool isAnonymous = md->isAnonymous();
461 bool hideUndocMembers = Config_getBool(HIDE_UNDOC_MEMBERS);
462 const MemberVector &enumList = md->enumFieldList();
463 bool isDir = !enumList.empty() && md->isEnumerate();
464 auto defType = def->definitionType();
465 bool namespaceMemberInFileDocs = md->getNamespaceDef() && defType==Definition::TypeFile;
466 bool lAddToIndex = addToIndex && !namespaceMemberInFileDocs;
467 QCString name = namespaceMemberInFileDocs || defType==Definition::TypeModule ?
468 md->qualifiedName() : md->name();
469 if (md->getOuterScope()==def ||
470 (md->getNamespaceDef()!=nullptr && defType==Definition::TypeFile) ||
472 {
473 Doxygen::indexList->addContentsItem(isDir,
474 name,md->getReference(),md->getOutputFileBase(),md->anchor(),FALSE,lAddToIndex && md->getGroupDef()==nullptr);
475 }
476 else // inherited member
477 {
478 Doxygen::indexList->addContentsItem(isDir,
479 name,def->getReference(),def->getOutputFileBase(),md->anchor(),FALSE,lAddToIndex && md->getGroupDef()==nullptr);
480 }
481 if (isDir)
482 {
483 if (!isAnonymous)
484 {
485 Doxygen::indexList->incContentsDepth();
486 }
487 for (const auto &emd : enumList)
488 {
489 if (!hideUndocMembers || emd->hasDocumentation())
490 {
491 namespaceMemberInFileDocs = emd->getNamespaceDef() && defType==Definition::TypeFile;
492 lAddToIndex = addToIndex && !namespaceMemberInFileDocs;
493 QCString ename = namespaceMemberInFileDocs || defType==Definition::TypeModule ?
494 emd->qualifiedName() : emd->name();
495 if (emd->getOuterScope()==def ||
496 (emd->getNamespaceDef()!=nullptr && defType==Definition::TypeFile) ||
497 emd->getOuterScope()==Doxygen::globalScope)
498 {
499 Doxygen::indexList->addContentsItem(FALSE,
500 ename,emd->getReference(),emd->getOutputFileBase(),emd->anchor(),FALSE,lAddToIndex && emd->getGroupDef()==nullptr);
501 }
502 else // inherited member
503 {
504 Doxygen::indexList->addContentsItem(FALSE,
505 ename,def->getReference(),def->getOutputFileBase(),emd->anchor(),FALSE,lAddToIndex && emd->getGroupDef()==nullptr);
506 }
507 }
508 }
509 if (!isAnonymous)
510 {
511 Doxygen::indexList->decContentsDepth();
512 }
513 }
514}
virtual QCString qualifiedName() const =0
virtual GroupDef * getGroupDef()=0
virtual const MemberVector & enumFieldList() const =0
virtual const NamespaceDef * getNamespaceDef() const =0
virtual bool isEnumerate() const =0

References Definition::anchor(), Config_getBool, Definition::definitionType(), MemberVector::empty(), MemberDef::enumFieldList(), FALSE, MemberDef::getGroupDef(), MemberDef::getNamespaceDef(), Definition::getOuterScope(), Definition::getOutputFileBase(), Definition::getReference(), Doxygen::globalScope, Doxygen::indexList, Definition::isAnonymous(), MemberDef::isEnumerate(), Definition::name(), Definition::qualifiedName(), Definition::TypeFile, and Definition::TypeModule.

Referenced by addMembersToIndex(), writeModuleMembers(), and writeNamespaceMembers().

◆ writeMenuData()

static void writeMenuData ( )
static

Definition at line 5571 of file index.cpp.

5572{
5573 if (!Config_getBool(GENERATE_HTML) || Config_getBool(DISABLE_INDEX)) return;
5574 QCString outputDir = Config_getBool(HTML_OUTPUT);
5576 std::ofstream t = Portable::openOutputStream(outputDir+"/menudata.js");
5577 if (t.is_open())
5578 {
5580 t << "var menudata={";
5581 bool hasChildren = renderQuickLinksAsJs(t,root,TRUE);
5582 if (hasChildren) t << "]";
5583 t << "}\n";
5584 }
5585}
constexpr auto JAVASCRIPT_LICENSE_TEXT
Definition ftvhelp.h:72
std::ofstream openOutputStream(const QCString &name, bool append=false)
Definition portable.cpp:665

References Config_getBool, LayoutDocManager::instance(), JAVASCRIPT_LICENSE_TEXT, Portable::openOutputStream(), renderQuickLinksAsJs(), LayoutDocManager::rootNavEntry(), and TRUE.

Referenced by writeIndexHierarchy().

◆ writeModuleIndex()

static void writeModuleIndex ( OutputList & ol)
static

Definition at line 4392 of file index.cpp.

4393{
4394 if (ModuleManager::instance().numDocumentedModules()==0) return;
4395 ol.pushGeneratorState();
4396 // 1.{
4397
4400 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ModuleList);
4401 if (lne==nullptr) lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Modules); // fall back
4402 QCString title = lne ? lne->title() : theTranslator->trModules();
4403 bool addToIndex = lne==nullptr || lne->visible();
4404
4405 startFile(ol,"modules",QCString(),title,HighlightedItem::Modules);
4406 startTitle(ol,QCString());
4407 ol.parseText(title);
4408 endTitle(ol,QCString(),QCString());
4409 ol.startContents();
4410 ol.startTextBlock();
4411 ol.parseText(lne ? lne->intro() : theTranslator->trModulesListDescription(Config_getBool(EXTRACT_ALL)));
4412 ol.endTextBlock();
4413
4414 // ---------------
4415 // Normal group index for Latex/RTF
4416 // ---------------
4417 // 2.{
4418 ol.pushGeneratorState();
4420 Doxygen::indexList->disable();
4421
4422 writeModuleList(ol,nullptr,FALSE);
4423
4424 Doxygen::indexList->enable();
4425 ol.popGeneratorState();
4426 // 2.}
4427
4428 // ---------------
4429 // interactive group index for HTML
4430 // ---------------
4431 // 2.{
4432 ol.pushGeneratorState();
4434
4435 {
4436 if (addToIndex)
4437 {
4438 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),"modules",QCString(),TRUE,TRUE);
4439 Doxygen::indexList->incContentsDepth();
4440 }
4441 FTVHelp ftv(false);
4442 writeModuleList(ol,&ftv,addToIndex);
4443 TextStream t;
4444 ftv.generateTreeViewInline(t);
4445 ol.writeString(t.str().c_str());
4446 if (addToIndex)
4447 {
4448 Doxygen::indexList->decContentsDepth();
4449 }
4450 }
4451 ol.popGeneratorState();
4452 // 2.}
4453 endFile(ol);
4454 ol.popGeneratorState();
4455 // 1.}
4456}
static ModuleManager & instance()
static void writeModuleList(OutputList &ol, FTVHelp *ftv, bool addToIndex)
Definition index.cpp:4368

References Config_getBool, OutputList::disable(), OutputList::disableAllBut(), Docbook, endFile(), OutputList::endTextBlock(), endTitle(), FALSE, LayoutNavEntry::find(), FTVHelp::generateTreeViewInline(), Html, Doxygen::indexList, LayoutDocManager::instance(), ModuleManager::instance(), LayoutNavEntry::intro(), Man, Modules, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startTextBlock(), startTitle(), TextStream::str(), theTranslator, LayoutNavEntry::title(), TRUE, LayoutNavEntry::visible(), writeModuleList(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writeModuleLinkForMember()

static void writeModuleLinkForMember ( OutputList & ol,
const MemberDef * md,
const QCString & separator,
QCString & prevModuleName )
static

Definition at line 2712 of file index.cpp.

2714{
2715 const ModuleDef *mod=md->getModuleDef();
2716 if (mod && prevModuleName!=mod->displayName())
2717 {
2718 ol.writeString(separator);
2719 // link to the member declaration in the module page
2720 ol.writeObjectLink(mod->getReference(),mod->getOutputFileBase(),"r_"+md->anchor(),
2721 mod->displayName());
2722 prevModuleName = mod->displayName();
2723 }
2724}
virtual const ModuleDef * getModuleDef() const =0

References Definition::anchor(), Definition::displayName(), MemberDef::getModuleDef(), Definition::getOutputFileBase(), Definition::getReference(), OutputList::writeObjectLink(), and OutputList::writeString().

Referenced by writeMemberList().

◆ writeModuleList()

static void writeModuleList ( OutputList & ol,
FTVHelp * ftv,
bool addToIndex )
static

Definition at line 4368 of file index.cpp.

4369{
4370 if (ftv)
4371 {
4372 ol.pushGeneratorState();
4374 }
4375 startIndexHierarchy(ol,0);
4376 for (const auto &mod : ModuleManager::instance().modules())
4377 {
4378 if (mod->isPrimaryInterface())
4379 {
4380 writeModuleTreeNode(ol,mod.get(),ftv,addToIndex);
4381 }
4382 }
4383 endIndexHierarchy(ol,0);
4384 if (ftv)
4385 {
4386 ol.popGeneratorState();
4387 }
4388}
static void writeModuleTreeNode(OutputList &ol, const ModuleDef *mod, FTVHelp *ftv, bool addToIndex)
Definition index.cpp:4321

References OutputList::disable(), endIndexHierarchy(), Html, ModuleManager::instance(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), startIndexHierarchy(), and writeModuleTreeNode().

Referenced by writeModuleIndex().

◆ writeModuleMemberIndex()

static void writeModuleMemberIndex ( OutputList & ol)
static

Definition at line 3693 of file index.cpp.

3694{
3695 const auto &index = Index::instance();
3696 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ModuleMembers);
3697 bool addToIndex = lne==nullptr || lne->visible();
3698 if (index.numDocumentedModuleMembers(ModuleMemberHighlight::All)>0 && addToIndex)
3699 {
3700 Doxygen::indexList->addContentsItem(true,lne ? lne->title() : theTranslator->trModulesMembers(),QCString(),"modulemembers",QCString());
3701 Doxygen::indexList->incContentsDepth();
3702 }
3703 //bool fortranOpt = Config_getBool(OPTIMIZE_FOR_FORTRAN);
3710 if (index.numDocumentedModuleMembers(ModuleMemberHighlight::All)>0 && addToIndex)
3711 {
3712 Doxygen::indexList->decContentsDepth();
3713 }
3714}
static void writeModuleMemberIndexFiltered(OutputList &ol, ModuleMemberHighlight::Enum hl)
Definition index.cpp:3585

References ModuleMemberHighlight::All, ModuleMemberHighlight::Enums, ModuleMemberHighlight::EnumValues, LayoutNavEntry::find(), ModuleMemberHighlight::Functions, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutDocManager::rootNavEntry(), theTranslator, LayoutNavEntry::title(), ModuleMemberHighlight::Typedefs, ModuleMemberHighlight::Variables, LayoutNavEntry::visible(), and writeModuleMemberIndexFiltered().

Referenced by writeIndexHierarchyEntries().

◆ writeModuleMemberIndexFiltered()

static void writeModuleMemberIndexFiltered ( OutputList & ol,
ModuleMemberHighlight::Enum hl )
static

Definition at line 3585 of file index.cpp.

3587{
3588 const auto &index = Index::instance();
3589 if (index.numDocumentedModuleMembers(hl)==0) return;
3590
3591 bool disableIndex = Config_getBool(DISABLE_INDEX);
3592
3593
3594 bool multiPageIndex=FALSE;
3595 if (index.numDocumentedModuleMembers(hl)>MAX_ITEMS_BEFORE_MULTIPAGE_INDEX)
3596 {
3597 multiPageIndex=TRUE;
3598 }
3599
3600 ol.pushGeneratorState();
3602
3604 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::ModuleMembers);
3605 QCString title = lne ? lne->title() : theTranslator->trModulesMembers();
3606 bool addToIndex = lne==nullptr || lne->visible();
3607
3608 if (addToIndex)
3609 {
3610 Doxygen::indexList->addContentsItem(multiPageIndex,getMmhlInfo(hl)->title,QCString(),
3611 getMmhlInfo(hl)->fname,QCString(),multiPageIndex,TRUE);
3612 if (multiPageIndex) Doxygen::indexList->incContentsDepth();
3613 }
3614
3615 bool first=TRUE;
3616 for (const auto &[letter,list] : index.isModuleIndexLetterUsed(hl))
3617 {
3618 QCString fileName = getMmhlInfo(hl)->fname;
3619 if (multiPageIndex)
3620 {
3621 QCString cs(letter);
3622 if (!first)
3623 {
3624 fileName+="_"+letterToLabel(cs);
3625 }
3626 if (addToIndex)
3627 {
3628 Doxygen::indexList->addContentsItem(FALSE,cs,QCString(),fileName,QCString(),FALSE,TRUE);
3629 }
3630 }
3631 bool quickIndex = index.numDocumentedModuleMembers(hl)>maxItemsBeforeQuickIndex;
3632
3633 ol.startFile(fileName+extension,QCString(),title);
3634 ol.startQuickIndices();
3635 if (!disableIndex)
3636 {
3638 if (!Config_getBool(HTML_DYNAMIC_MENUS))
3639 {
3641
3642 // index item for all namespace member lists
3645 ol.writeString(fixSpaces(getMmhlInfo(0)->title));
3647
3648 // index items per category member lists
3649 for (int i=1;i<ModuleMemberHighlight::Total;i++)
3650 {
3651 if (index.numDocumentedModuleMembers(static_cast<ModuleMemberHighlight::Enum>(i))>0)
3652 {
3654 getMmhlInfo(i)->fname+Doxygen::htmlFileExtension,hl==i,TRUE,first);
3655 ol.writeString(fixSpaces(getMmhlInfo(i)->title));
3657 }
3658 }
3659
3661
3662 if (quickIndex)
3663 {
3664 writeQuickMemberIndex(ol,index.isModuleIndexLetterUsed(hl),letter,
3665 getMmhlInfo(hl)->fname,multiPageIndex);
3666 }
3667 }
3668 }
3669 ol.endQuickIndices();
3670 ol.writeSplitBar(fileName);
3671 ol.writeSearchInfo();
3672
3673 ol.startContents();
3674
3675 ol.startTextBlock();
3676 ol.parseText(hl == ModuleMemberHighlight::All && lne ? lne->intro() : theTranslator->trModuleMembersDescriptionTotal(hl));
3677 ol.endTextBlock();
3678
3679 writeMemberList(ol,quickIndex,
3680 multiPageIndex ? letter : std::string(),
3681 index.isModuleIndexLetterUsed(hl),
3683 endFile(ol);
3684 first=FALSE;
3685 }
3686 if (multiPageIndex && addToIndex) Doxygen::indexList->decContentsDepth();
3687 ol.popGeneratorState();
3688}
const char * fname
Definition index.cpp:3565

References ModuleMemberHighlight::All, Config_getBool, OutputList::disableAllBut(), endFile(), endQuickIndexItem(), endQuickIndexList(), OutputList::endQuickIndices(), OutputList::endTextBlock(), FALSE, LayoutNavEntry::find(), fixSpaces(), MmhlInfo::fname, getMmhlInfo(), Html, Doxygen::htmlFileExtension, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), letterToLabel(), MAX_ITEMS_BEFORE_MULTIPAGE_INDEX, maxItemsBeforeQuickIndex, ModuleMembers, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), OutputList::startFile(), startQuickIndexItem(), startQuickIndexList(), OutputList::startQuickIndices(), OutputList::startTextBlock(), theTranslator, LayoutNavEntry::title(), ModuleMemberHighlight::Total, TRUE, Definition::TypeModule, LayoutNavEntry::visible(), writeMemberList(), OutputList::writeQuickLinks(), writeQuickMemberIndex(), OutputList::writeSearchInfo(), OutputList::writeSplitBar(), and OutputList::writeString().

Referenced by writeModuleMemberIndex().

◆ writeModuleMembers()

static void writeModuleMembers ( const ModuleDef * mod,
bool addToIndex )
static

Definition at line 1779 of file index.cpp.

1780{
1781 for (const auto &lde : LayoutDocManager::instance().docEntries(LayoutDocManager::Module))
1782 {
1783 if (lde->kind()==LayoutDocEntry::MemberDecl)
1784 {
1785 const LayoutDocEntryMemberDecl *lmd = dynamic_cast<const LayoutDocEntryMemberDecl*>(lde.get());
1786 if (lmd)
1787 {
1788 MemberList *ml = mod->getMemberList(lmd->type);
1789 if (ml)
1790 {
1791 for (const auto &md : *ml)
1792 {
1793 //printf(" member %s visible=%d\n",qPrint(md->name()),md->visibleInIndex());
1794 if (md->visibleInIndex())
1795 {
1796 writeMemberToIndex(mod,md,addToIndex);
1797 }
1798 }
1799 }
1800 }
1801 }
1802 }
1803}
virtual MemberList * getMemberList(MemberListType lt) const =0
Represents of a member declaration list with configurable title and subtitle.
Definition layout.h:109
MemberListType type
Definition layout.h:115

References ModuleDef::getMemberList(), LayoutDocManager::instance(), LayoutDocEntryMemberDecl::type, and writeMemberToIndex().

Referenced by writeModuleTreeNode().

◆ writeModuleTreeNode()

static void writeModuleTreeNode ( OutputList & ol,
const ModuleDef * mod,
FTVHelp * ftv,
bool addToIndex )
static

Definition at line 4321 of file index.cpp.

4323{
4324 int visibleMembers = mod->countVisibleMembers();
4325 bool isDir=visibleMembers>0;
4326 if (addToIndex)
4327 {
4328 Doxygen::indexList->addContentsItem(isDir,mod->name(),
4329 mod->getReference(),mod->getOutputFileBase(),QCString(),isDir,TRUE);
4330 }
4331 if (ftv)
4332 {
4333 ftv->addContentsItem(false,mod->name(),
4334 mod->getReference(),mod->getOutputFileBase(),QCString(),
4335 false,false,mod);
4336 }
4337 ol.startIndexListItem();
4339 ol.parseText(mod->qualifiedName());
4341 if (mod->isReference())
4342 {
4343 ol.startTypewriter();
4344 ol.docify(" [external]");
4345 ol.endTypewriter();
4346 }
4347 if (addToIndex && isDir)
4348 {
4349 Doxygen::indexList->incContentsDepth();
4350 }
4351 if (isDir)
4352 {
4353 //ftv->incContentsDepth();
4354 writeClassTree(mod->getClasses(),nullptr,addToIndex,FALSE,ClassDef::Class);
4355 writeConceptList(mod->getConcepts(),nullptr,addToIndex);
4356 writeModuleMembers(mod,addToIndex);
4357 //ftv->decContentsDepth();
4358 }
4359 if (addToIndex && isDir)
4360 {
4361 Doxygen::indexList->decContentsDepth();
4362 }
4363 ol.endIndexListItem();
4364}
virtual int countVisibleMembers() const =0
virtual const ConceptLinkedRefMap & getConcepts() const =0
virtual const ClassLinkedRefMap & getClasses() const =0
static void writeModuleMembers(const ModuleDef *mod, bool addToIndex)
Definition index.cpp:1779

References FTVHelp::addContentsItem(), ClassDef::Class, ModuleDef::countVisibleMembers(), OutputList::docify(), OutputList::endIndexItem(), OutputList::endIndexListItem(), OutputList::endTypewriter(), FALSE, ModuleDef::getClasses(), ModuleDef::getConcepts(), Definition::getOutputFileBase(), Definition::getReference(), Doxygen::indexList, Definition::isReference(), Definition::name(), OutputList::parseText(), Definition::qualifiedName(), OutputList::startIndexItem(), OutputList::startIndexListItem(), OutputList::startTypewriter(), TRUE, writeClassTree(), writeConceptList(), and writeModuleMembers().

Referenced by writeModuleList().

◆ writeNamespaceIndex()

static void writeNamespaceIndex ( OutputList & ol)
static

Definition at line 1987 of file index.cpp.

1988{
1989 if (Index::instance().numDocumentedNamespaces()==0) return;
1990 ol.pushGeneratorState();
1993 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::NamespaceList);
1994 if (lne==nullptr) lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Namespaces); // fall back
1995 QCString title = lne ? lne->title() : theTranslator->trNamespaceList();
1996 bool addToIndex = lne==nullptr || lne->visible();
1997 startFile(ol,"namespaces",QCString(),title,HighlightedItem::Namespaces);
1998 startTitle(ol,QCString());
1999 ol.parseText(title);
2000 endTitle(ol,QCString(),QCString());
2001 ol.startContents();
2002 ol.startTextBlock();
2003 ol.parseText(lne ? lne->intro() : theTranslator->trNamespaceListDescription(Config_getBool(EXTRACT_ALL)));
2004 ol.endTextBlock();
2005
2006 bool first=TRUE;
2007
2008 // ---------------
2009 // Linear namespace index for Latex/RTF
2010 // ---------------
2011 ol.pushGeneratorState();
2013
2014 for (const auto &nd : *Doxygen::namespaceLinkedMap)
2015 {
2016 if (nd->isLinkableInProject())
2017 {
2018 if (first)
2019 {
2020 ol.startIndexList();
2021 first=FALSE;
2022 }
2023 //ol.writeStartAnnoItem("namespace",nd->getOutputFileBase(),0,nd->name());
2024 ol.startIndexKey();
2025 if (nd->getLanguage()==SrcLangExt::VHDL)
2026 {
2027 ol.writeObjectLink(QCString(), nd->getOutputFileBase().replace(0,qstrlen("namespace"),"class"),QCString(),nd->displayName());
2028 }
2029 else
2030 {
2031 ol.writeObjectLink(QCString(),nd->getOutputFileBase(),QCString(),nd->displayName());
2032 }
2033 ol.endIndexKey();
2034
2035 bool hasBrief = !nd->briefDescription().isEmpty();
2036 ol.startIndexValue(hasBrief);
2037 if (hasBrief)
2038 {
2039 //ol.docify(" (");
2040 ol.generateDoc(
2041 nd->briefFile(),nd->briefLine(),
2042 nd.get(),nullptr,
2043 nd->briefDescription(TRUE),
2044 FALSE, // index words
2045 FALSE, // isExample
2046 QCString(), // example name
2047 TRUE, // single line
2048 TRUE, // link from index
2049 Config_getBool(MARKDOWN_SUPPORT)
2050 );
2051 //ol.docify(")");
2052 }
2053 ol.endIndexValue(nd->getOutputFileBase(),hasBrief);
2054
2055 }
2056 }
2057 if (!first) ol.endIndexList();
2058
2059 ol.popGeneratorState();
2060
2061 // ---------------
2062 // Hierarchical namespace index for HTML
2063 // ---------------
2064 ol.pushGeneratorState();
2066
2067 {
2068 if (addToIndex)
2069 {
2070 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),"namespaces",QCString(),TRUE,TRUE);
2071 Doxygen::indexList->incContentsDepth();
2072 }
2073 FTVHelp ftv(false);
2075 TextStream t;
2076 ftv.generateTreeViewInline(t);
2077 ol.writeString(t.str().c_str());
2078 if (addToIndex)
2079 {
2080 Doxygen::indexList->decContentsDepth();
2081 }
2082 }
2083
2084 ol.popGeneratorState();
2085 // ------
2086
2087 endFile(ol);
2088 ol.popGeneratorState();
2089}
static void writeNamespaceTree(const NamespaceLinkedRefMap &nsLinkedMap, FTVHelp *ftv, bool rootOnly, bool addToIndex)
Definition index.cpp:1870

References Config_getBool, OutputList::disable(), OutputList::disableAllBut(), Docbook, endFile(), OutputList::endIndexKey(), OutputList::endIndexList(), OutputList::endIndexValue(), OutputList::endTextBlock(), endTitle(), FALSE, LayoutNavEntry::find(), OutputList::generateDoc(), FTVHelp::generateTreeViewInline(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), Man, Doxygen::namespaceLinkedMap, Namespaces, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), qstrlen(), QCString::replace(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startIndexKey(), OutputList::startIndexList(), OutputList::startIndexValue(), OutputList::startTextBlock(), startTitle(), TextStream::str(), theTranslator, LayoutNavEntry::title(), TRUE, VHDL, LayoutNavEntry::visible(), writeNamespaceTree(), OutputList::writeObjectLink(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writeNamespaceLinkForMember()

static void writeNamespaceLinkForMember ( OutputList & ol,
const MemberDef * md,
const QCString & separator,
QCString & prevNamespaceName )
static

Definition at line 2699 of file index.cpp.

2701{
2702 const NamespaceDef *nd=md->getNamespaceDef();
2703 if (nd && prevNamespaceName!=nd->displayName())
2704 {
2705 ol.writeString(separator);
2707 nd->displayName());
2708 prevNamespaceName = nd->displayName();
2709 }
2710}

References Definition::anchor(), Definition::displayName(), MemberDef::getNamespaceDef(), Definition::getOutputFileBase(), Definition::getReference(), OutputList::writeObjectLink(), and OutputList::writeString().

Referenced by writeMemberList().

◆ writeNamespaceMemberIndex()

static void writeNamespaceMemberIndex ( OutputList & ol)
static

Definition at line 3533 of file index.cpp.

3534{
3535 const auto &index = Index::instance();
3536 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::NamespaceMembers);
3537 bool addToIndex = lne==nullptr || lne->visible();
3538 if (index.numDocumentedNamespaceMembers(NamespaceMemberHighlight::All)>0 && addToIndex)
3539 {
3540 Doxygen::indexList->addContentsItem(true,lne ? lne->title() : theTranslator->trNamespaceMembers(),QCString(),"namespacemembers",QCString());
3541 Doxygen::indexList->incContentsDepth();
3542 }
3543 //bool fortranOpt = Config_getBool(OPTIMIZE_FOR_FORTRAN);
3552 if (index.numDocumentedNamespaceMembers(NamespaceMemberHighlight::All)>0 && addToIndex)
3553 {
3554 Doxygen::indexList->decContentsDepth();
3555 }
3556
3557}
static void writeNamespaceMemberIndexFiltered(OutputList &ol, NamespaceMemberHighlight::Enum hl)
Definition index.cpp:3428

References NamespaceMemberHighlight::All, NamespaceMemberHighlight::Dictionaries, NamespaceMemberHighlight::Enums, NamespaceMemberHighlight::EnumValues, LayoutNavEntry::find(), NamespaceMemberHighlight::Functions, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutDocManager::rootNavEntry(), NamespaceMemberHighlight::Sequences, theTranslator, LayoutNavEntry::title(), NamespaceMemberHighlight::Typedefs, NamespaceMemberHighlight::Variables, LayoutNavEntry::visible(), and writeNamespaceMemberIndexFiltered().

Referenced by writeIndexHierarchyEntries().

◆ writeNamespaceMemberIndexFiltered()

static void writeNamespaceMemberIndexFiltered ( OutputList & ol,
NamespaceMemberHighlight::Enum hl )
static

Definition at line 3428 of file index.cpp.

3430{
3431 const auto &index = Index::instance();
3432 if (index.numDocumentedNamespaceMembers(hl)==0) return;
3433
3434 bool disableIndex = Config_getBool(DISABLE_INDEX);
3435
3436
3437 bool multiPageIndex=FALSE;
3438 if (index.numDocumentedNamespaceMembers(hl)>MAX_ITEMS_BEFORE_MULTIPAGE_INDEX)
3439 {
3440 multiPageIndex=TRUE;
3441 }
3442
3443 ol.pushGeneratorState();
3445
3447 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::NamespaceMembers);
3448 QCString title = lne ? lne->title() : theTranslator->trNamespaceMembers();
3449 bool addToIndex = lne==nullptr || lne->visible();
3450
3451 if (addToIndex)
3452 {
3453 Doxygen::indexList->addContentsItem(multiPageIndex,getNmhlInfo(hl)->title,QCString(),
3454 getNmhlInfo(hl)->fname,QCString(),multiPageIndex,TRUE);
3455 if (multiPageIndex) Doxygen::indexList->incContentsDepth();
3456 }
3457
3458 bool first=TRUE;
3459 for (const auto &[letter,list] : index.isNamespaceIndexLetterUsed(hl))
3460 {
3461 QCString fileName = getNmhlInfo(hl)->fname;
3462 if (multiPageIndex)
3463 {
3464 QCString cs(letter);
3465 if (!first)
3466 {
3467 fileName+="_"+letterToLabel(cs);
3468 }
3469 if (addToIndex)
3470 {
3471 Doxygen::indexList->addContentsItem(FALSE,cs,QCString(),fileName,QCString(),FALSE,TRUE);
3472 }
3473 }
3474 bool quickIndex = index.numDocumentedNamespaceMembers(hl)>maxItemsBeforeQuickIndex;
3475
3476 ol.startFile(fileName+extension,QCString(),title);
3477 ol.startQuickIndices();
3478 if (!disableIndex)
3479 {
3481 if (!Config_getBool(HTML_DYNAMIC_MENUS))
3482 {
3484
3485 // index item for all namespace member lists
3488 ol.writeString(fixSpaces(getNmhlInfo(0)->title));
3490
3491 // index items per category member lists
3492 for (int i=1;i<NamespaceMemberHighlight::Total;i++)
3493 {
3494 if (index.numDocumentedNamespaceMembers(static_cast<NamespaceMemberHighlight::Enum>(i))>0)
3495 {
3497 getNmhlInfo(i)->fname+Doxygen::htmlFileExtension,hl==i,TRUE,first);
3498 ol.writeString(fixSpaces(getNmhlInfo(i)->title));
3500 }
3501 }
3502
3504
3505 if (quickIndex)
3506 {
3507 writeQuickMemberIndex(ol,index.isNamespaceIndexLetterUsed(hl),letter,
3508 getNmhlInfo(hl)->fname,multiPageIndex);
3509 }
3510 }
3511 }
3512 ol.endQuickIndices();
3513 ol.writeSplitBar(fileName);
3514 ol.writeSearchInfo();
3515
3516 ol.startContents();
3517
3518 ol.startTextBlock();
3519 ol.parseText(hl == NamespaceMemberHighlight::All && lne ? lne->intro() : theTranslator->trNamespaceMembersDescriptionTotal(hl));
3520 ol.endTextBlock();
3521
3522 writeMemberList(ol,quickIndex,
3523 multiPageIndex ? letter : std::string(),
3524 index.isNamespaceIndexLetterUsed(hl),
3526 endFile(ol);
3527 first=FALSE;
3528 }
3529 if (multiPageIndex && addToIndex) Doxygen::indexList->decContentsDepth();
3530 ol.popGeneratorState();
3531}
@ NamespaceMembers
Definition index.h:78
const char * fname
Definition index.cpp:3400

References NamespaceMemberHighlight::All, Config_getBool, OutputList::disableAllBut(), endFile(), endQuickIndexItem(), endQuickIndexList(), OutputList::endQuickIndices(), OutputList::endTextBlock(), FALSE, LayoutNavEntry::find(), fixSpaces(), NmhlInfo::fname, getNmhlInfo(), Html, Doxygen::htmlFileExtension, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), letterToLabel(), MAX_ITEMS_BEFORE_MULTIPAGE_INDEX, maxItemsBeforeQuickIndex, NamespaceMembers, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), OutputList::startFile(), startQuickIndexItem(), startQuickIndexList(), OutputList::startQuickIndices(), OutputList::startTextBlock(), theTranslator, LayoutNavEntry::title(), NamespaceMemberHighlight::Total, TRUE, Definition::TypeNamespace, LayoutNavEntry::visible(), writeMemberList(), OutputList::writeQuickLinks(), writeQuickMemberIndex(), OutputList::writeSearchInfo(), OutputList::writeSplitBar(), and OutputList::writeString().

Referenced by writeNamespaceMemberIndex().

◆ writeNamespaceMembers()

static void writeNamespaceMembers ( const NamespaceDef * nd,
bool addToIndex )
static

Definition at line 1753 of file index.cpp.

1754{
1755 for (const auto &lde : LayoutDocManager::instance().docEntries(LayoutDocManager::Namespace))
1756 {
1757 if (lde->kind()==LayoutDocEntry::MemberDef)
1758 {
1759 const LayoutDocEntryMemberDef *lmd = dynamic_cast<const LayoutDocEntryMemberDef*>(lde.get());
1760 if (lmd)
1761 {
1762 MemberList *ml = nd->getMemberList(lmd->type);
1763 if (ml)
1764 {
1765 for (const auto &md : *ml)
1766 {
1767 //printf(" member %s visible=%d\n",qPrint(md->name()),md->visibleInIndex());
1768 if (md->visibleInIndex())
1769 {
1770 writeMemberToIndex(nd,md,addToIndex);
1771 }
1772 }
1773 }
1774 }
1775 }
1776 }
1777}
virtual MemberList * getMemberList(MemberListType lt) const =0

References NamespaceDef::getMemberList(), LayoutDocManager::instance(), LayoutDocEntryMemberDef::type, and writeMemberToIndex().

Referenced by writeNamespaceTreeElement().

◆ writeNamespaceTree() [1/2]

static void writeNamespaceTree ( const NamespaceLinkedMap & nsLinkedMap,
FTVHelp * ftv,
bool rootOnly,
bool addToIndex )
static

Definition at line 1882 of file index.cpp.

1884{
1885 for (const auto &nd : nsLinkedMap)
1886 {
1887 if (nd->isVisibleInHierarchy())
1888 {
1889 writeNamespaceTreeElement(nd.get(),ftv,rootOnly,addToIndex);
1890 }
1891 }
1892}
static void writeNamespaceTreeElement(const NamespaceDef *nd, FTVHelp *ftv, bool rootOnly, bool addToIndex)
Definition index.cpp:1810

References writeNamespaceTreeElement().

◆ writeNamespaceTree() [2/2]

static void writeNamespaceTree ( const NamespaceLinkedRefMap & nsLinkedMap,
FTVHelp * ftv,
bool rootOnly,
bool addToIndex )
static

Definition at line 1870 of file index.cpp.

1872{
1873 for (const auto &nd : nsLinkedMap)
1874 {
1875 if (nd->isVisibleInHierarchy())
1876 {
1877 writeNamespaceTreeElement(nd,ftv,rootOnly,addToIndex);
1878 }
1879 }
1880}

References writeNamespaceTreeElement().

Referenced by writeNamespaceIndex(), and writeNamespaceTreeElement().

◆ writeNamespaceTreeElement()

static void writeNamespaceTreeElement ( const NamespaceDef * nd,
FTVHelp * ftv,
bool rootOnly,
bool addToIndex )
static

Definition at line 1810 of file index.cpp.

1812{
1813 if (!nd->isAnonymous() &&
1814 (!rootOnly || nd->getOuterScope()==Doxygen::globalScope))
1815 {
1816
1817 bool hasNestedNamespace = namespaceHasNestedNamespace(nd);
1818 bool hasChildren = hasNestedNamespace ||
1821 bool isLinkable = nd->isLinkable();
1822 int visibleMembers = nd->countVisibleMembers();
1823
1824 //printf("namespace %s hasChildren=%d visibleMembers=%d\n",qPrint(nd->name()),hasChildren,visibleMembers);
1825
1826 QCString ref;
1827 QCString file;
1828 if (isLinkable)
1829 {
1830 ref = nd->getReference();
1831 file = nd->getOutputFileBase();
1832 if (nd->getLanguage()==SrcLangExt::VHDL) // UGLY HACK
1833 {
1834 file=file.replace(0,qstrlen("namespace"),"class");
1835 }
1836 }
1837
1838 bool isDir = hasChildren || visibleMembers>0;
1839 if (isLinkable || isDir)
1840 {
1841 ftv->addContentsItem(hasNestedNamespace,nd->localName(),ref,file,QCString(),FALSE,nd->partOfGroups().empty(),nd);
1842
1843 if (addToIndex)
1844 {
1845 Doxygen::indexList->addContentsItem(isDir,nd->localName(),ref,file,QCString(),
1846 hasChildren && !file.isEmpty(),nd->partOfGroups().empty());
1847 }
1848 if (addToIndex && isDir)
1849 {
1850 Doxygen::indexList->incContentsDepth();
1851 }
1852
1853 if (isDir)
1854 {
1855 ftv->incContentsDepth();
1856 writeNamespaceTree(nd->getNamespaces(),ftv,FALSE,addToIndex);
1857 writeClassTree(nd->getClasses(),nullptr,addToIndex,FALSE,ClassDef::Class);
1858 writeConceptList(nd->getConcepts(),nullptr,addToIndex);
1859 writeNamespaceMembers(nd,addToIndex);
1860 ftv->decContentsDepth();
1861 }
1862 if (addToIndex && isDir)
1863 {
1864 Doxygen::indexList->decContentsDepth();
1865 }
1866 }
1867 }
1868}
virtual int countVisibleMembers() const =0
static void writeNamespaceMembers(const NamespaceDef *nd, bool addToIndex)
Definition index.cpp:1753
bool namespaceHasNestedNamespace(const NamespaceDef *nd)

References FTVHelp::addContentsItem(), ClassDef::Class, NamespaceDef::countVisibleMembers(), FTVHelp::decContentsDepth(), FALSE, NamespaceDef::getClasses(), NamespaceDef::getConcepts(), Definition::getLanguage(), NamespaceDef::getNamespaces(), Definition::getOuterScope(), Definition::getOutputFileBase(), Definition::getReference(), Doxygen::globalScope, FTVHelp::incContentsDepth(), Doxygen::indexList, Definition::isAnonymous(), QCString::isEmpty(), Definition::isLinkable(), Definition::localName(), namespaceHasNestedClass(), namespaceHasNestedConcept(), namespaceHasNestedNamespace(), Definition::partOfGroups(), qstrlen(), QCString::replace(), VHDL, writeClassTree(), writeConceptList(), writeNamespaceMembers(), and writeNamespaceTree().

Referenced by writeNamespaceTree(), and writeNamespaceTree().

◆ writePageIndex()

static void writePageIndex ( OutputList & ol)
static

Definition at line 3872 of file index.cpp.

3873{
3874 if (Index::instance().numIndexedPages()==0) return;
3875 ol.pushGeneratorState();
3877 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Pages);
3878 QCString title = lne ? lne->title() : theTranslator->trRelatedPages();
3879 startFile(ol,"pages",QCString(),title,HighlightedItem::Pages);
3880 startTitle(ol,QCString());
3881 ol.parseText(title);
3882 endTitle(ol,QCString(),QCString());
3883 ol.startContents();
3884 ol.startTextBlock();
3885 ol.parseText(lne ? lne->intro() : theTranslator->trRelatedPagesDescription());
3886 ol.endTextBlock();
3887
3888 {
3889 FTVHelp ftv(false);
3890 for (const auto &pd : *Doxygen::pageLinkedMap)
3891 {
3892 if ((pd->getOuterScope()==nullptr ||
3893 pd->getOuterScope()->definitionType()!=Definition::TypePage) && // not a sub page
3894 pd->visibleInIndex()
3895 )
3896 {
3897 writePages(pd.get(),&ftv);
3898 }
3899 }
3900 TextStream t;
3901 ftv.generateTreeViewInline(t);
3902 ol.writeString(t.str().c_str());
3903 }
3904
3905// ol.popGeneratorState();
3906 // ------
3907
3908 endFile(ol);
3909 ol.popGeneratorState();
3910}

References OutputList::disableAllBut(), endFile(), OutputList::endTextBlock(), endTitle(), LayoutNavEntry::find(), FTVHelp::generateTreeViewInline(), Html, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), Doxygen::pageLinkedMap, Pages, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startTextBlock(), startTitle(), TextStream::str(), theTranslator, LayoutNavEntry::title(), Definition::TypePage, writePages(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writePages()

static void writePages ( PageDef * pd,
FTVHelp * ftv )
static

Definition at line 3812 of file index.cpp.

3813{
3814 //printf("writePages()=%s pd=%p mainpage=%p\n",qPrint(pd->name()),(void*)pd,(void*)Doxygen::mainPage.get());
3815 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Pages);
3816 bool addToIndex = lne==nullptr || lne->visible();
3817 if (!addToIndex) return;
3818
3819 bool hasSubPages = pd->hasSubPages();
3820 bool hasSections = pd->hasSections();
3821
3822 if (pd->visibleInIndex())
3823 {
3824 QCString pageTitle;
3825
3826 if (pd->title().isEmpty())
3827 pageTitle=pd->name();
3828 else
3829 pageTitle=filterTitle(pd->title());
3830
3831 if (ftv)
3832 {
3833 //printf("*** adding %s hasSubPages=%d hasSections=%d\n",qPrint(pageTitle),hasSubPages,hasSections);
3834 ftv->addContentsItem(
3835 hasSubPages,pageTitle,
3836 pd->getReference(),pd->getOutputFileBase(),
3837 QCString(),hasSubPages,TRUE,pd);
3838 }
3839 if (addToIndex && pd!=Doxygen::mainPage.get())
3840 {
3841 Doxygen::indexList->addContentsItem(
3842 hasSubPages || hasSections,pageTitle,
3843 pd->getReference(),pd->getOutputFileBase(),
3844 QCString(),hasSubPages,TRUE,pd);
3845 }
3846 }
3847 if (hasSubPages && ftv) ftv->incContentsDepth();
3848 bool doIndent = (hasSections || hasSubPages) &&
3849 (pd!=Doxygen::mainPage.get() || mainPageHasOwnTitle());
3850 if (doIndent)
3851 {
3852 Doxygen::indexList->incContentsDepth();
3853 }
3854 if (hasSections)
3855 {
3856 pd->addSectionsToIndex();
3857 }
3858 for (const auto &subPage : pd->getSubPages())
3859 {
3860 writePages(subPage,ftv);
3861 }
3862 if (hasSubPages && ftv) ftv->decContentsDepth();
3863 if (doIndent)
3864 {
3865 Doxygen::indexList->decContentsDepth();
3866 }
3867 //printf("end writePages()=%s\n",qPrint(pd->title()));
3868}
virtual bool hasSections() const =0
virtual void addSectionsToIndex()=0
virtual bool visibleInIndex() const =0
virtual const PageLinkedRefMap & getSubPages() const =0
virtual bool hasSubPages() const =0
virtual QCString title() const =0
static bool mainPageHasOwnTitle()
Definition index.cpp:3801

References FTVHelp::addContentsItem(), PageDef::addSectionsToIndex(), FTVHelp::decContentsDepth(), filterTitle(), LayoutNavEntry::find(), Definition::getOutputFileBase(), Definition::getReference(), PageDef::getSubPages(), Definition::hasSections(), PageDef::hasSubPages(), FTVHelp::incContentsDepth(), Doxygen::indexList, LayoutDocManager::instance(), QCString::isEmpty(), Doxygen::mainPage, mainPageHasOwnTitle(), Definition::name(), LayoutDocManager::rootNavEntry(), PageDef::title(), TRUE, LayoutNavEntry::visible(), PageDef::visibleInIndex(), and writePages().

Referenced by writeGroupTreeNode(), writeIndex(), writePageIndex(), and writePages().

◆ writeQuickMemberIndex()

static void writeQuickMemberIndex ( OutputList & ol,
const Index::MemberIndexMap & map,
const std::string & page,
QCString fullName,
bool multiPage )
static

Definition at line 3040 of file index.cpp.

3043{
3044 bool first=TRUE;
3046 for (const auto &[letter,list] : map)
3047 {
3048 QCString ci(letter);
3049 QCString is = letterToLabel(ci);
3050 QCString anchor;
3052 if (!multiPage)
3053 anchor="#index_";
3054 else if (first)
3055 anchor=fullName+extension+"#index_";
3056 else
3057 anchor=fullName+"_"+is+extension+"#index_";
3058 startQuickIndexItem(ol,anchor+convertToId(is),letter==page,TRUE,first);
3059 ol.writeString(ci);
3061 first=FALSE;
3062 }
3064}

References convertToId(), endQuickIndexItem(), endQuickIndexList(), FALSE, Doxygen::htmlFileExtension, letterToLabel(), startQuickIndexItem(), startQuickIndexList(), TRUE, and OutputList::writeString().

Referenced by writeClassMemberIndexFiltered(), writeFileMemberIndexFiltered(), writeModuleMemberIndexFiltered(), and writeNamespaceMemberIndexFiltered().

◆ writeSingleFileIndex()

static void writeSingleFileIndex ( OutputList & ol,
const FileDef * fd )
static

Definition at line 1454 of file index.cpp.

1455{
1456 //printf("Found filedef %s\n",qPrint(fd->name()));
1457 bool doc = fd->isLinkableInProject();
1458 bool src = fd->generateSourceFile();
1459 bool nameOk = !fd->isDocumentationFile();
1460 if (nameOk && (doc || src) && !fd->isReference())
1461 {
1462 QCString path;
1463 if (Config_getBool(FULL_PATH_NAMES))
1464 {
1465 path=stripFromPath(fd->getPath());
1466 }
1467 QCString fullName=fd->name();
1468 if (!path.isEmpty())
1469 {
1470 if (path.at(path.length()-1)!='/') fullName.prepend("/");
1471 fullName.prepend(path);
1472 }
1473
1474 ol.startIndexKey();
1475 ol.docify(path);
1476 if (doc)
1477 {
1479 //if (addToIndex)
1480 //{
1481 // addMembersToIndex(fd,LayoutDocManager::File,fullName,QCString());
1482 //}
1483 }
1484 else if (src)
1485 {
1487 }
1488 if (doc && src)
1489 {
1490 ol.pushGeneratorState();
1492 ol.docify(" ");
1494 ol.docify("[");
1495 ol.parseText(theTranslator->trCode());
1496 ol.docify("]");
1497 ol.endTextLink();
1498 ol.popGeneratorState();
1499 }
1500 ol.endIndexKey();
1501 bool hasBrief = !fd->briefDescription().isEmpty();
1502 ol.startIndexValue(hasBrief);
1503 if (hasBrief)
1504 {
1505 //ol.docify(" (");
1506 ol.generateDoc(
1507 fd->briefFile(),fd->briefLine(),
1508 fd,nullptr,
1510 FALSE, // index words
1511 FALSE, // isExample
1512 QCString(), // example name
1513 TRUE, // single line
1514 TRUE, // link from index
1515 Config_getBool(MARKDOWN_SUPPORT)
1516 );
1517 //ol.docify(")");
1518 }
1519 if (doc)
1520 {
1521 ol.endIndexValue(fd->getOutputFileBase(),hasBrief);
1522 }
1523 else // src
1524 {
1525 ol.endIndexValue(fd->getSourceFileBase(),hasBrief);
1526 }
1527 //ol.popGeneratorState();
1528 // --------------------------------------------------------
1529 }
1530}
virtual int briefLine() const =0
virtual QCString briefDescription(bool abbreviate=FALSE) const =0
virtual QCString getSourceFileBase() const =0
virtual QCString briefFile() const =0
virtual QCString includeName() const =0
virtual QCString getPath() const =0
virtual bool generateSourceFile() const =0
virtual bool isDocumentationFile() const =0
size_t length() const
Returns the length of the string, not counting the 0-terminator.
Definition qcstring.h:153
static QCString stripFromPath(const QCString &p, const StringVector &l)
Definition util.cpp:309

References QCString::at(), Definition::briefDescription(), Definition::briefFile(), Definition::briefLine(), Config_getBool, OutputList::disableAllBut(), OutputList::docify(), OutputList::endIndexKey(), OutputList::endIndexValue(), OutputList::endTextLink(), FALSE, OutputList::generateDoc(), FileDef::generateSourceFile(), Definition::getOutputFileBase(), FileDef::getPath(), Definition::getSourceFileBase(), Html, FileDef::includeName(), FileDef::isDocumentationFile(), QCString::isEmpty(), Definition::isLinkableInProject(), Definition::isReference(), QCString::length(), Definition::name(), OutputList::parseText(), OutputList::popGeneratorState(), QCString::prepend(), OutputList::pushGeneratorState(), OutputList::startIndexKey(), OutputList::startIndexValue(), OutputList::startTextLink(), stripFromPath(), theTranslator, TRUE, and OutputList::writeObjectLink().

Referenced by writeFileIndex().

◆ writeTopicIndex()

static void writeTopicIndex ( OutputList & ol)
static

Definition at line 4252 of file index.cpp.

4253{
4254 if (Index::instance().numDocumentedGroups()==0) return;
4255 ol.pushGeneratorState();
4256 // 1.{
4259 LayoutNavEntry *lne = LayoutDocManager::instance().rootNavEntry()->find(LayoutNavEntry::Topics);
4260 QCString title = lne ? lne->title() : theTranslator->trTopics();
4261 bool addToIndex = lne==nullptr || lne->visible();
4262
4263 startFile(ol,"topics",QCString(),title,HighlightedItem::Topics);
4264 startTitle(ol,QCString());
4265 ol.parseText(title);
4266 endTitle(ol,QCString(),QCString());
4267 ol.startContents();
4268 ol.startTextBlock();
4269 ol.parseText(lne ? lne->intro() : theTranslator->trTopicListDescription());
4270 ol.endTextBlock();
4271
4272 // ---------------
4273 // Normal group index for Latex/RTF
4274 // ---------------
4275 // 2.{
4276 ol.pushGeneratorState();
4278 Doxygen::indexList->disable();
4279
4280 writeGroupHierarchy(ol,nullptr,FALSE);
4281
4282 Doxygen::indexList->enable();
4283 ol.popGeneratorState();
4284 // 2.}
4285
4286 // ---------------
4287 // interactive group index for HTML
4288 // ---------------
4289 // 2.{
4290 ol.pushGeneratorState();
4292
4293 {
4294 if (addToIndex)
4295 {
4296 Doxygen::indexList->addContentsItem(TRUE,title,QCString(),"topics",QCString(),TRUE,TRUE);
4297 Doxygen::indexList->incContentsDepth();
4298 }
4299 FTVHelp ftv(false);
4300 writeGroupHierarchy(ol,&ftv,addToIndex);
4301 TextStream t;
4302 ftv.generateTreeViewInline(t);
4304 ol.writeString(t.str().c_str());
4305 if (addToIndex)
4306 {
4307 Doxygen::indexList->decContentsDepth();
4308 }
4309 }
4310 ol.popGeneratorState();
4311 // 2.}
4312
4313 endFile(ol);
4314 ol.popGeneratorState();
4315 // 1.}
4316}
static void writeGroupHierarchy(OutputList &ol, FTVHelp *ftv, bool addToIndex)
Definition index.cpp:4228

References OutputList::disable(), OutputList::disableAllBut(), Docbook, endFile(), OutputList::endTextBlock(), endTitle(), FALSE, LayoutNavEntry::find(), FTVHelp::generateTreeViewInline(), Html, Doxygen::indexList, Index::instance(), LayoutDocManager::instance(), LayoutNavEntry::intro(), Man, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), LayoutDocManager::rootNavEntry(), OutputList::startContents(), startFile(), OutputList::startTextBlock(), startTitle(), TextStream::str(), theTranslator, LayoutNavEntry::title(), Topics, TRUE, LayoutNavEntry::visible(), writeGroupHierarchy(), and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

◆ writeUserGroupStubPage()

static void writeUserGroupStubPage ( OutputList & ol,
LayoutNavEntry * lne )
static

Definition at line 4672 of file index.cpp.

4673{
4674 if (lne->baseFile().startsWith("usergroup"))
4675 {
4676 ol.pushGeneratorState();
4679 startTitle(ol,QCString());
4680 ol.parseText(lne->title());
4681 endTitle(ol,QCString(),QCString());
4682 ol.startContents();
4683 int count=0;
4684 for (const auto &entry: lne->children())
4685 {
4686 if (entry->visible()) count++;
4687 }
4688 if (count>0)
4689 {
4690 ol.writeString("<ul>\n");
4691 for (const auto &entry: lne->children())
4692 {
4693 if (entry->visible())
4694 {
4695 ol.writeString("<li><a href=\""+entry->url()+"\"><span>"+
4696 fixSpaces(entry->title())+"</span></a></li>\n");
4697 }
4698 }
4699 ol.writeString("</ul>\n");
4700 }
4701 endFile(ol);
4702 ol.popGeneratorState();
4703 }
4704}
bool startsWith(const char *s) const
Definition qcstring.h:492
QCString baseFile() const
Definition layout.h:198

References LayoutNavEntry::baseFile(), LayoutNavEntry::children(), OutputList::disableAllBut(), endFile(), endTitle(), fixSpaces(), Html, OutputList::parseText(), OutputList::popGeneratorState(), OutputList::pushGeneratorState(), OutputList::startContents(), startFile(), QCString::startsWith(), startTitle(), LayoutNavEntry::title(), UserGroup, and OutputList::writeString().

Referenced by writeIndexHierarchyEntries().

Variable Documentation

◆ indexWritten

std::vector<bool> indexWritten
static

Definition at line 5066 of file index.cpp.

Referenced by writeIndexHierarchyEntries().

◆ maxItemsBeforeQuickIndex