Doxygen
Loading...
Searching...
No Matches
HtmlGenerator Class Referencefinal

Generator for HTML output. More...

#include <src/htmlgen.h>

Inheritance diagram for HtmlGenerator:
Collaboration diagram for HtmlGenerator:

Classes

struct  TocState

Public Member Functions

 HtmlGenerator ()
 HtmlGenerator (const HtmlGenerator &)
HtmlGeneratoroperator= (const HtmlGenerator &)
 HtmlGenerator (HtmlGenerator &&)=delete
HtmlGeneratoroperator= (HtmlGenerator &&)=delete
 ~HtmlGenerator ()
void clearBuffer ()
OutputType type () const override
std::unique_ptr< OutputGenIntfclone () override
void addCodeGen (OutputCodeList &list) override
void cleanup () override
void writeDoc (const IDocNodeAST *node, const Definition *, const MemberDef *, int id, int sectionLevel) override
void startFile (const DString &name, bool isSource, const DString &manName, const DString &title, int id, int hierarchyLevel) override
void endFile () override
void writeFooter (const DString &navPath) override
void writeSearchInfo () override
void startIndexSection (IndexSection) override
void endIndexSection (IndexSection) override
void writePageLink (const DString &, bool) override
void startProjectNumber () override
void endProjectNumber () override
void writeStyleInfo (int part) override
void startTitleHead (const DString &) override
void endTitleHead (const DString &, const DString &) override
void startParagraph (const DString &classDef) override
void endParagraph () override
void writeString (const DString &text) override
void startIndexListItem () override
void endIndexListItem () override
void startIndexList () override
void endIndexList () override
void startIndexKey () override
void endIndexKey () override
void startIndexValue (bool) override
void endIndexValue (const DString &, bool) override
void startItemList () override
void endItemList () override
void startIndexItem (const DString &ref, const DString &file) override
void endIndexItem (const DString &ref, const DString &file) override
void docify (const DString &text) override
void writeObjectLink (const DString &ref, const DString &file, const DString &anchor, const DString &name) override
void startTextLink (const DString &file, const DString &anchor) override
void endTextLink () override
void startTypewriter () override
void endTypewriter () override
void startGroupHeader (const DString &, int) override
void endGroupHeader (int) override
void startItemListItem () override
void endItemListItem () override
void startMemberSections () override
void endMemberSections () override
void startHeaderSection () override
void endHeaderSection () override
void startMemberHeader (const DString &, int) override
void endMemberHeader () override
void startMemberSubtitle () override
void endMemberSubtitle () override
void startMemberDocList () override
void endMemberDocList () override
void startMemberList () override
void endMemberList () override
void startInlineHeader () override
void endInlineHeader () override
void startAnonTypeScope (int) override
void endAnonTypeScope (int) override
void startMemberItem (const DString &anchor, MemberItemType, const DString &inheritId) override
void endMemberItem (MemberItemType) override
void startMemberTemplateParams () override
void endMemberTemplateParams (const DString &anchor, const DString &inheritId) override
void startCompoundTemplateParams () override
void endCompoundTemplateParams () override
void startMemberGroupHeader (const DString &, bool) override
void endMemberGroupHeader (bool) override
void startMemberGroupDocs () override
void endMemberGroupDocs () override
void startMemberGroup () override
void endMemberGroup (bool) override
void insertMemberAlign (bool) override
void insertMemberAlignLeft (MemberItemType, bool) override
void startMemberDescription (const DString &anchor, const DString &inheritId, bool typ) override
void endMemberDescription () override
void startMemberDeclaration () override
void endMemberDeclaration (const DString &anchor, const DString &inheritId) override
void writeInheritedSectionTitle (const DString &id, const DString &ref, const DString &file, const DString &anchor, const DString &title, const DString &name) override
void writeRuler () override
void writeAnchor (const DString &, const DString &name) override
void startEmphasis () override
void endEmphasis () override
void startBold () override
void endBold () override
void startDescForItem () override
void endDescForItem () override
void lineBreak (const DString &style) override
void writeChar (char c) override
void startMemberDoc (const DString &clName, const DString &memName, const DString &anchor, const DString &title, int memCount, int memTotal, bool showInline) override
void endMemberDoc (bool) override
void startDoxyAnchor (const DString &fName, const DString &manName, const DString &anchor, const DString &name, const DString &args) override
void endDoxyAnchor (const DString &fName, const DString &anchor) override
void addLabel (const DString &, const DString &) override
void writeLatexSpacing () override
void writeStartAnnoItem (const DString &type, const DString &file, const DString &path, const DString &name) override
void startCenter () override
void endCenter () override
void startSmall () override
void endSmall () override
void startExamples () override
void endExamples () override
void startSection (const DString &, const DString &, SectionType) override
void endSection (const DString &, SectionType) override
void addIndexItem (const DString &, const DString &) override
void startIndent () override
void endIndent () override
void writeSynopsis () override
void startClassDiagram () override
void endClassDiagram (const ClassDiagram &, const DString &, const DString &) override
void startPageRef () override
void endPageRef (const DString &, const DString &) override
void startQuickIndices () override
void endQuickIndices () override
void writeSplitBar (const DString &name, const DString &allMembersFile) override
void writeNavigationPath (const DString &s) override
void writeLogo () override
void writeQuickLinks (HighlightedItem hli, const DString &file, bool extraTabs) override
void writeSummaryLink (const DString &file, const DString &anchor, const DString &title, bool first) override
void writePageOutline () override
void startContents () override
void endContents () override
void startPageDoc (const DString &pageTitle) override
void endPageDoc () override
void writeNonBreakableSpace (int) override
void startDescTable (const DString &title, const bool hasInits) override
void endDescTable () override
void startDescTableRow () override
void endDescTableRow () override
void startDescTableTitle () override
void endDescTableTitle () override
void startDescTableInit () override
void endDescTableInit () override
void startDescTableData () override
void endDescTableData () override
void startDotGraph () override
void endDotGraph (DotClassGraph &g) override
void startInclDepGraph () override
void endInclDepGraph (DotInclDepGraph &g) override
void startGroupCollaboration () override
void endGroupCollaboration (DotGroupCollaboration &g) override
void startCallGraph () override
void endCallGraph (DotCallGraph &g) override
void startDirDepGraph () override
void endDirDepGraph (DotDirDeps &g) override
void writeGraphicalHierarchy (DotGfxHierarchyTable &g) override
void startTextBlock (bool) override
void endTextBlock (bool) override
void lastIndexPage () override
void startMemberDocPrefixItem () override
void endMemberDocPrefixItem () override
void startMemberDocName (bool) override
void endMemberDocName () override
void startParameterType (bool first, const DString &key) override
void endParameterType () override
void startParameterName (bool) override
void endParameterName () override
void startParameterExtra () override
void endParameterExtra (bool last, bool emptyList, bool closeBracket) override
void startParameterDefVal (const char *sep) override
void endParameterDefVal () override
void startParameterList (bool) override
void endParameterList () override
void exceptionEntry (const DString &, bool) override
void startConstraintList (const DString &) override
void startConstraintParam () override
void endConstraintParam () override
void startConstraintType () override
void endConstraintType () override
void startConstraintDocs () override
void endConstraintDocs () override
void endConstraintList () override
void startMemberDocSimple (bool) override
void endMemberDocSimple (bool) override
void startInlineMemberType () override
void endInlineMemberType () override
void startInlineMemberName () override
void endInlineMemberName () override
void startInlineMemberDoc () override
void endInlineMemberDoc () override
void startLabels () override
void writeLabel (const DString &l, bool isLast) override
void endLabels () override
void startLocalToc (int level) override
void endLocalToc () override
void startTocEntry (const SectionInfo *si) override
void endTocEntry (const SectionInfo *si) override
void startPlainFile (const DString &name) override
void endPlainFile () override
void startEmbeddedDoc (size_t) override
void endEmbeddedDoc () override
Public Member Functions inherited from OutputGenerator
 OutputGenerator ()
 OutputGenerator (const DString &dir)
virtual ~OutputGenerator ()=default
DString dir () const
DString fileName () const
void startPlainFile (const DString &name)
void endPlainFile ()

Static Public Member Functions

static void init ()
static void writeStyleSheetFile (TextStream &t)
static void writeHeaderFile (TextStream &t, const DString &cssname)
static void writeFooterFile (TextStream &t)
static void writeTabData ()
 Additional initialization after indices have been created.
static void writeSearchInfoStatic (TextStream &t, const DString &relPath)
static void writeSearchData (const DString &dir)
static void writeSearchPage ()
static void writeExternalSearchPage ()
static DString writeLogoAsString (const DString &path)
static DString writeSplitBarAsString (const DString &name, const DString &relpath, const DString &allMembersFile)
static DString getNavTreeCss ()
static DString fixSpaces (const DString &s)

Private Member Functions

void startTitle ()
void endTitle ()
void docify_ (const DString &text, bool inHtmlComment)

Static Private Member Functions

static void writePageFooter (TextStream &t, const DString &, const DString &, const DString &)

Private Attributes

DString m_lastTitle
DString m_lastFile
DString m_relPath
int m_sectionCount = 0
bool m_emptySection = false
std::unique_ptr< OutputCodeListm_codeList
HtmlCodeGeneratorm_codeGen = nullptr
int m_pageOutlineIndent = 0
TocState m_tocState

Additional Inherited Members

Public Types inherited from OutputGenerator
enum class  ParamListTypes { Param , RetVal , Exception }
enum class  MemberItemType { Normal , AnonymousStart , AnonymousEnd , Templated }
Protected Attributes inherited from OutputGenerator
TextStream m_t
DString m_dir

Detailed Description

Generator for HTML output.

Definition at line 92 of file htmlgen.h.

Constructor & Destructor Documentation

◆ HtmlGenerator() [1/3]

HtmlGenerator::HtmlGenerator ( )

Definition at line 1227 of file htmlgen.cpp.

1228 : OutputGenerator(Config_getString(HTML_OUTPUT))
1229 , m_codeList(std::make_unique<OutputCodeList>())
1230{
1231 //printf("%p:HtmlGenerator()\n",(void*)this);
1232 m_codeGen = m_codeList->add<HtmlCodeGenerator>(&m_t);
1233}
HtmlCodeGenerator * m_codeGen
Definition htmlgen.h:349
std::unique_ptr< OutputCodeList > m_codeList
Definition htmlgen.h:348
TextStream m_t
Definition outputgen.h:113
#define Config_getString(name)
Definition config.h:32

References Config_getString, m_codeGen, m_codeList, OutputGenerator::m_t, and OutputGenerator::OutputGenerator().

Referenced by HtmlGenerator(), HtmlGenerator(), operator=(), and operator=().

◆ HtmlGenerator() [2/3]

HtmlGenerator::HtmlGenerator ( const HtmlGenerator & og)

Definition at line 1235 of file htmlgen.cpp.

1235 : OutputGenerator(og.m_dir), OutputGenIntf()
1236{
1237 //printf("%p:HtmlGenerator(copy %p)\n",(void*)this,(void*)&og);
1238 m_codeList = std::make_unique<OutputCodeList>(*og.m_codeList);
1239 m_codeGen = m_codeList->get<HtmlCodeGenerator>(OutputType::Html);
1243 m_relPath = og.m_relPath;
1246}
void setTextStream(TextStream *t)
Definition htmlgen.h:28
int m_sectionCount
Definition htmlgen.h:346
DString m_lastTitle
Definition htmlgen.h:343
DString m_lastFile
Definition htmlgen.h:344
DString m_relPath
Definition htmlgen.h:345
bool m_emptySection
Definition htmlgen.h:347

References Html, HtmlGenerator(), m_codeGen, m_codeList, OutputGenerator::m_dir, m_emptySection, m_lastFile, m_lastTitle, m_relPath, m_sectionCount, OutputGenerator::m_t, OutputGenerator::OutputGenerator(), and HtmlCodeGenerator::setTextStream().

◆ HtmlGenerator() [3/3]

HtmlGenerator::HtmlGenerator ( HtmlGenerator && )
delete

References HtmlGenerator().

◆ ~HtmlGenerator()

Member Function Documentation

◆ addCodeGen()

void HtmlGenerator::addCodeGen ( OutputCodeList & list)
overridevirtual

Implements OutputGenIntf.

Definition at line 1268 of file htmlgen.cpp.

1269{
1271}
void add(OutputCodeIntfPtr &&p)
Definition outputlist.h:192
OutputCodeDefer< HtmlCodeGenerator > HtmlCodeGeneratorDefer
Definition outputlist.h:99

References OutputCodeList::add(), and m_codeGen.

◆ addIndexItem()

void HtmlGenerator::addIndexItem ( const DString & ,
const DString &  )
overridevirtual

Implements OutputGenIntf.

Definition at line 2754 of file htmlgen.cpp.

2755{
2756}

◆ addLabel()

void HtmlGenerator::addLabel ( const DString & ,
const DString &  )
overridevirtual

Implements OutputGenIntf.

Definition at line 1858 of file htmlgen.cpp.

1859{
1860}

◆ cleanup()

void HtmlGenerator::cleanup ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1438 of file htmlgen.cpp.

1439{
1440 DString dname = Config_getString(HTML_OUTPUT);
1441 Dir d(dname.str());
1442 clearSubDirs(d);
1443}
const std::string & str() const
Definition dstring.h:649
void clearSubDirs(const Dir &d)
Definition util.cpp:2998

References clearSubDirs(), Config_getString, and DString::str().

◆ clearBuffer()

void HtmlGenerator::clearBuffer ( )

◆ clone()

std::unique_ptr< OutputGenIntf > HtmlGenerator::clone ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 120 of file htmlgen.h.

120{ return std::make_unique<HtmlGenerator>(*this); }

◆ docify()

void HtmlGenerator::docify ( const DString & text)
overridevirtual

Implements OutputGenIntf.

Definition at line 2054 of file htmlgen.cpp.

2055{
2056 docify_(str,false);
2057}
void docify_(const DString &text, bool inHtmlComment)
Definition htmlgen.cpp:2059

References docify_().

Referenced by startExamples(), startMemberDoc(), startParameterDefVal(), writeChar(), writeObjectLink(), and writeStartAnnoItem().

◆ docify_()

void HtmlGenerator::docify_ ( const DString & text,
bool inHtmlComment )
private

Definition at line 2059 of file htmlgen.cpp.

2060{
2061 if (!str.empty())
2062 {
2063 const char *p=str.data();
2064 while (*p)
2065 {
2066 char c=*p++;
2067 switch(c)
2068 {
2069 case '<': m_t << "&lt;"; break;
2070 case '>': m_t << "&gt;"; break;
2071 case '&': m_t << "&amp;"; break;
2072 case '"': m_t << "&quot;"; break;
2073 case '-': if (inHtmlComment) m_t << "&#45;"; else m_t << "-"; break;
2074 case '\\':
2075 if (*p=='<')
2076 { m_t << "&lt;"; p++; }
2077 else if (*p=='>')
2078 { m_t << "&gt;"; p++; }
2079 else if (*p=='[')
2080 { m_t << "\\&zwj;["; p++; }
2081 else if (*p==']')
2082 { m_t << "\\&zwj;]"; p++; }
2083 else if (*p=='(')
2084 { m_t << "\\&zwj;("; p++; }
2085 else if (*p==')')
2086 { m_t << "\\&zwj;)"; p++; }
2087 else
2088 m_t << "\\";
2089 break;
2090 default: m_t << c;
2091 }
2092 }
2093 }
2094}

References DString::data(), DString::empty(), and OutputGenerator::m_t.

Referenced by docify().

◆ endAnonTypeScope()

void HtmlGenerator::endAnonTypeScope ( int )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 183 of file htmlgen.h.

183{}

◆ endBold()

void HtmlGenerator::endBold ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 214 of file htmlgen.h.

214{ m_t << "</b>"; }

References OutputGenerator::m_t.

◆ endCallGraph()

void HtmlGenerator::endCallGraph ( DotCallGraph & g)
overridevirtual

Implements OutputGenIntf.

Definition at line 2677 of file htmlgen.cpp.

2678{
2683
2685
2688}
DString writeGraph(TextStream &t, GraphOutputFormat gf, EmbeddedOutputFormat ef, const DString &path, const DString &fileName, const DString &relPath, bool writeImageMap=true, int graphId=-1)
DString dir() const
Definition outputgen.cpp:50
DString fileName() const
Definition outputgen.cpp:55
static void startSectionContent(TextStream &t, int sectionCount)
Definition htmlgen.cpp:2150
static void startSectionSummary(TextStream &t, int sectionCount)
Definition htmlgen.cpp:2129
static void endSectionContent(TextStream &t)
Definition htmlgen.cpp:2165
static void endSectionHeader(TextStream &t)
Definition htmlgen.cpp:2123
static void endSectionSummary(TextStream &t)
Definition htmlgen.cpp:2140

References BITMAP, OutputGenerator::dir(), endSectionContent(), endSectionHeader(), endSectionSummary(), OutputGenerator::fileName(), Html, m_relPath, m_sectionCount, OutputGenerator::m_t, startSectionContent(), startSectionSummary(), and DotCallGraph::writeGraph().

◆ endCenter()

void HtmlGenerator::endCenter ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 232 of file htmlgen.h.

232{ m_t << "</center>\n"; }

References OutputGenerator::m_t.

◆ endClassDiagram()

void HtmlGenerator::endClassDiagram ( const ClassDiagram & d,
const DString & fileName,
const DString & name )
overridevirtual

Implements OutputGenIntf.

Definition at line 2178 of file htmlgen.cpp.

2180{
2185 TextStream tt;
2186 d.writeImage(tt,dir(),m_relPath,fileName,true,true);
2187 if (!tt.empty())
2188 {
2189 m_t << " <div class=\"center\">\n";
2190 m_t << " <img src=\"";
2191 m_t << m_relPath << fileName << ".png\" usemap=\"#" << convertToId(name);
2192 m_t << "_map\" alt=\"\"/>\n";
2193 m_t << " <map id=\"" << convertToId(name);
2194 m_t << "_map\" name=\"" << convertToId(name);
2195 m_t << "_map\">\n";
2196 m_t << tt.str();
2197 m_t << " </map>\n";
2198 m_t << "</div>";
2199 }
2200 else
2201 {
2202 m_t << " <div class=\"center\">\n";
2203 m_t << " <img src=\"";
2204 m_t << m_relPath << fileName << ".png\" alt=\"\"/>\n";
2205 m_t << " </div>";
2206 }
2209}
void writeImage(TextStream &t, const DString &path, const DString &relPath, const DString &file, bool generateMap, bool toIndex) const
Definition diagram.cpp:1361
bool empty() const
Returns true iff the buffer is empty.
Definition textstream.h:256
std::string str() const
Return the contents of the buffer as a std::string object.
Definition textstream.h:232
DString convertToId(const DString &s)
Definition util.cpp:3204

References convertToId(), OutputGenerator::dir(), TextStream::empty(), endSectionContent(), endSectionHeader(), endSectionSummary(), OutputGenerator::fileName(), m_relPath, m_sectionCount, OutputGenerator::m_t, startSectionContent(), startSectionSummary(), TextStream::str(), and ClassDiagram::writeImage().

◆ endCompoundTemplateParams()

void HtmlGenerator::endCompoundTemplateParams ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2281 of file htmlgen.cpp.

2282{
2283 m_t << "</div>";
2284}

References OutputGenerator::m_t.

◆ endConstraintDocs()

void HtmlGenerator::endConstraintDocs ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3515 of file htmlgen.cpp.

3516{
3517 m_t << "</td></tr>\n";
3518}

References OutputGenerator::m_t.

◆ endConstraintList()

void HtmlGenerator::endConstraintList ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3520 of file htmlgen.cpp.

3521{
3522 m_t << "</table>\n";
3523 m_t << "</dd>\n";
3524 m_t << "</dl>\n";
3525 m_t << "</div>\n";
3526}

References OutputGenerator::m_t.

◆ endConstraintParam()

void HtmlGenerator::endConstraintParam ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3495 of file htmlgen.cpp.

3496{
3497 m_t << "</em></td>";
3498}

References OutputGenerator::m_t.

◆ endConstraintType()

void HtmlGenerator::endConstraintType ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3505 of file htmlgen.cpp.

3506{
3507 m_t << "</em></td>";
3508}

References OutputGenerator::m_t.

◆ endContents()

void HtmlGenerator::endContents ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3258 of file htmlgen.cpp.

3259{
3260 m_t << "</div><!-- contents -->\n";
3261}

References OutputGenerator::m_t.

◆ endDescForItem()

void HtmlGenerator::endDescForItem ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 216 of file htmlgen.h.

216{ m_t << "</dd>\n"; }

References OutputGenerator::m_t.

◆ endDescTable()

void HtmlGenerator::endDescTable ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2771 of file htmlgen.cpp.

2772{
2773 m_t << "</table>\n";
2774}

References OutputGenerator::m_t.

◆ endDescTableData()

void HtmlGenerator::endDescTableData ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2811 of file htmlgen.cpp.

2812{
2813 m_t << "</td>";
2814}

References OutputGenerator::m_t.

◆ endDescTableInit()

void HtmlGenerator::endDescTableInit ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2801 of file htmlgen.cpp.

2802{
2803 m_t << "&#160;</td>";
2804}

References OutputGenerator::m_t.

◆ endDescTableRow()

void HtmlGenerator::endDescTableRow ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2781 of file htmlgen.cpp.

2782{
2783 m_t << "</tr>\n";
2784}

References OutputGenerator::m_t.

◆ endDescTableTitle()

void HtmlGenerator::endDescTableTitle ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2791 of file htmlgen.cpp.

2792{
2793 m_t << "&#160;</td>";
2794}

References OutputGenerator::m_t.

◆ endDirDepGraph()

void HtmlGenerator::endDirDepGraph ( DotDirDeps & g)
overridevirtual

Implements OutputGenIntf.

Definition at line 2695 of file htmlgen.cpp.

2696{
2701
2703
2706}
DString writeGraph(TextStream &out, GraphOutputFormat gf, EmbeddedOutputFormat ef, const DString &path, const DString &fileName, const DString &relPath, bool writeImageMap=true, int graphId=-1, bool linkRelations=true)

References BITMAP, OutputGenerator::dir(), endSectionContent(), endSectionHeader(), endSectionSummary(), OutputGenerator::fileName(), Html, m_relPath, m_sectionCount, OutputGenerator::m_t, startSectionContent(), startSectionSummary(), and DotDirDeps::writeGraph().

◆ endDotGraph()

void HtmlGenerator::endDotGraph ( DotClassGraph & g)
overridevirtual

Implements OutputGenIntf.

Definition at line 2607 of file htmlgen.cpp.

2608{
2609 bool generateLegend = Config_getBool(GENERATE_LEGEND);
2610 bool umlLook = Config_getBool(UML_LOOK);
2615
2617 if (generateLegend && !umlLook)
2618 {
2619 DString url = m_relPath+"graph_legend"+Doxygen::htmlFileExtension;
2620 m_t << "<center><span class=\"legend\">[";
2621 bool generateTreeView = Config_getBool(GENERATE_TREEVIEW);
2622 m_t << "<a ";
2623 if (generateTreeView) m_t << "target=\"top\" ";
2624 m_t << "href=\"";
2625 if (!url.empty()) m_t << url;
2626 m_t << "\">";
2628 m_t << "</a>";
2629 m_t << "]</span></center>";
2630 }
2631
2634}
bool empty() const
Returns true iff the string is empty (std::string compatible alias for isEmpty()).
Definition dstring.h:152
DString writeGraph(TextStream &t, GraphOutputFormat gf, EmbeddedOutputFormat ef, const DString &path, const DString &fileName, const DString &relPath, bool TBRank=true, bool imageMap=true, int graphId=-1)
static DString htmlFileExtension
Definition doxygen.h:115
virtual DString trLegend()=0
#define Config_getBool(name)
Definition config.h:33
Translator * theTranslator
Definition language.cpp:71

References BITMAP, Config_getBool, OutputGenerator::dir(), DString::empty(), endSectionContent(), endSectionHeader(), endSectionSummary(), OutputGenerator::fileName(), Html, Doxygen::htmlFileExtension, m_relPath, m_sectionCount, OutputGenerator::m_t, startSectionContent(), startSectionSummary(), theTranslator, Translator::trLegend(), and DotClassGraph::writeGraph().

◆ endDoxyAnchor()

void HtmlGenerator::endDoxyAnchor ( const DString & fName,
const DString & anchor )
overridevirtual

Implements OutputGenIntf.

Definition at line 1854 of file htmlgen.cpp.

1855{
1856}

◆ endEmbeddedDoc()

void HtmlGenerator::endEmbeddedDoc ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3634 of file htmlgen.cpp.

3635{
3636 DBG_HTML(m_t << "<!-- endEmbeddedDoc -->\n";)
3637 m_t << "</div>";
3638}
#define DBG_HTML(x)
Definition htmlgen.cpp:62

References DBG_HTML, and OutputGenerator::m_t.

◆ endEmphasis()

void HtmlGenerator::endEmphasis ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 212 of file htmlgen.h.

212{ m_t << "</em>"; }

References OutputGenerator::m_t.

◆ endExamples()

void HtmlGenerator::endExamples ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2823 of file htmlgen.cpp.

2824{
2825 m_t << "</dl>\n";
2826}

References OutputGenerator::m_t.

◆ endFile()

void HtmlGenerator::endFile ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1754 of file htmlgen.cpp.

1755{
1756 endPlainFile();
1757}
void endPlainFile() override
Definition htmlgen.h:332

References endPlainFile().

◆ endGroupCollaboration()

void HtmlGenerator::endGroupCollaboration ( DotGroupCollaboration & g)
overridevirtual

Implements OutputGenIntf.

Definition at line 2659 of file htmlgen.cpp.

2660{
2665
2667
2670}
DString writeGraph(TextStream &t, GraphOutputFormat gf, EmbeddedOutputFormat ef, const DString &path, const DString &fileName, const DString &relPath, bool writeImageMap=true, int graphId=-1)

References BITMAP, OutputGenerator::dir(), endSectionContent(), endSectionHeader(), endSectionSummary(), OutputGenerator::fileName(), Html, m_relPath, m_sectionCount, OutputGenerator::m_t, startSectionContent(), startSectionSummary(), and DotGroupCollaboration::writeGraph().

◆ endGroupHeader()

void HtmlGenerator::endGroupHeader ( int extraIndentLevel)
overridevirtual

Implements OutputGenIntf.

Definition at line 2007 of file htmlgen.cpp.

2008{
2009 if (extraIndentLevel==2)
2010 {
2011 m_t << "</h4>\n";
2012 }
2013 else if (extraIndentLevel==1)
2014 {
2015 m_t << "</h3>\n";
2016 }
2017 else
2018 {
2019 m_t << "</h2>\n";
2020 }
2021}

References OutputGenerator::m_t.

◆ endHeaderSection()

void HtmlGenerator::endHeaderSection ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3557 of file htmlgen.cpp.

3558{
3559 m_t << "</div><!--header-->\n";
3560}

References OutputGenerator::m_t.

◆ endInclDepGraph()

void HtmlGenerator::endInclDepGraph ( DotInclDepGraph & g)
overridevirtual

Implements OutputGenIntf.

Definition at line 2641 of file htmlgen.cpp.

2642{
2647
2649
2652}
DString writeGraph(TextStream &t, GraphOutputFormat gf, EmbeddedOutputFormat ef, const DString &path, const DString &fileName, const DString &relPath, bool writeImageMap=true, int graphId=-1)

References BITMAP, OutputGenerator::dir(), endSectionContent(), endSectionHeader(), endSectionSummary(), OutputGenerator::fileName(), Html, m_relPath, m_sectionCount, OutputGenerator::m_t, startSectionContent(), startSectionSummary(), and DotInclDepGraph::writeGraph().

◆ endIndent()

void HtmlGenerator::endIndent ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2748 of file htmlgen.cpp.

2749{
2750 DBG_HTML(m_t << "<!-- endIndent -->\n";)
2751 m_t << "\n</div>\n" << "</div>\n";
2752}

References DBG_HTML, and OutputGenerator::m_t.

◆ endIndexItem()

void HtmlGenerator::endIndexItem ( const DString & ref,
const DString & file )
overridevirtual

Implements OutputGenIntf.

Definition at line 1920 of file htmlgen.cpp.

1921{
1922 //printf("HtmlGenerator::endIndexItem(%s,%s,%s)\n",ref,f,name);
1923 if (!ref.empty() || !f.empty())
1924 {
1925 m_t << "</a>";
1926 }
1927 else
1928 {
1929 m_t << "</b>";
1930 }
1931}

References DString::empty(), and OutputGenerator::m_t.

◆ endIndexKey()

void HtmlGenerator::endIndexKey ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2411 of file htmlgen.cpp.

2412{
2413 //m_t << "</td>";
2414}

◆ endIndexList()

void HtmlGenerator::endIndexList ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2401 of file htmlgen.cpp.

2402{
2403 m_t << "</table>\n";
2404}

References OutputGenerator::m_t.

◆ endIndexListItem()

void HtmlGenerator::endIndexListItem ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1885 of file htmlgen.cpp.

1886{
1887 m_t << "</li>\n";
1888}

References OutputGenerator::m_t.

◆ endIndexSection()

void HtmlGenerator::endIndexSection ( IndexSection )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 131 of file htmlgen.h.

131{}

◆ endIndexValue()

void HtmlGenerator::endIndexValue ( const DString & ,
bool  )
overridevirtual

Implements OutputGenIntf.

Definition at line 2421 of file htmlgen.cpp.

2422{
2423 //m_t << "</td></tr>\n";
2424}

◆ endInlineHeader()

void HtmlGenerator::endInlineHeader ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3572 of file htmlgen.cpp.

3573{
3574 m_t << "</h3></th></tr>\n";
3575}

References OutputGenerator::m_t.

◆ endInlineMemberDoc()

void HtmlGenerator::endInlineMemberDoc ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3622 of file htmlgen.cpp.

3623{
3624 DBG_HTML(m_t << "<!-- endInlineMemberDoc -->\n";)
3625 m_t << "</td></tr>\n";
3626}

References DBG_HTML, and OutputGenerator::m_t.

◆ endInlineMemberName()

void HtmlGenerator::endInlineMemberName ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3610 of file htmlgen.cpp.

3611{
3612 DBG_HTML(m_t << "<!-- endInlineMemberName -->\n";)
3613 m_t << "</td>\n";
3614}

References DBG_HTML, and OutputGenerator::m_t.

◆ endInlineMemberType()

void HtmlGenerator::endInlineMemberType ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3598 of file htmlgen.cpp.

3599{
3600 DBG_HTML(m_t << "<!-- endInlineMemberType -->\n";)
3601 m_t << "</td>\n";
3602}

References DBG_HTML, and OutputGenerator::m_t.

◆ endItemList()

void HtmlGenerator::endItemList ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 151 of file htmlgen.h.

151{ m_t << "</ul>\n"; }

References OutputGenerator::m_t.

◆ endItemListItem()

void HtmlGenerator::endItemListItem ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 166 of file htmlgen.h.

166{ m_t << "</li>\n"; }

References OutputGenerator::m_t.

◆ endLabels()

void HtmlGenerator::endLabels ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3686 of file htmlgen.cpp.

3687{
3688 DBG_HTML(m_t << "<!-- endLabels -->\n";)
3689 m_t << "</span>";
3690}

References DBG_HTML, and OutputGenerator::m_t.

◆ endLocalToc()

void HtmlGenerator::endLocalToc ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3794 of file htmlgen.cpp.

3795{
3797 while (m_tocState.level>0)
3798 {
3799 m_tocState.decIndent(m_t,"</li>");
3800 m_tocState.decIndent(m_t,"</ul>");
3801 m_tocState.level--;
3802 }
3803 m_t << "</div>\n";
3804}
TocState m_tocState
Definition htmlgen.h:362
void decIndent(TextStream &t, const DString &text)
Definition htmlgen.h:360

References HtmlGenerator::TocState::decIndent(), HtmlGenerator::TocState::level, OutputGenerator::m_t, m_tocState, and HtmlGenerator::TocState::maxLevel.

◆ endMemberDeclaration()

void HtmlGenerator::endMemberDeclaration ( const DString & anchor,
const DString & inheritId )
overridevirtual

Implements OutputGenIntf.

Definition at line 3769 of file htmlgen.cpp.

3770{
3771}

◆ endMemberDescription()

void HtmlGenerator::endMemberDescription ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2325 of file htmlgen.cpp.

2326{
2327 DBG_HTML(m_t << "<!-- endMemberDescription -->\n")
2328 m_t << "<br /></td></tr>\n";
2329}

References DBG_HTML, and OutputGenerator::m_t.

◆ endMemberDoc()

void HtmlGenerator::endMemberDoc ( bool hasArgs)
overridevirtual

Implements OutputGenIntf.

Definition at line 2591 of file htmlgen.cpp.

2592{
2593 DBG_HTML(m_t << "<!-- endMemberDoc -->\n";)
2594 if (!hasArgs)
2595 {
2596 m_t << " </tr>\n";
2597 }
2598 m_t << " </table>\n";
2599 // m_t << "</div>\n";
2600}

References DBG_HTML, and OutputGenerator::m_t.

◆ endMemberDocList()

void HtmlGenerator::endMemberDocList ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2431 of file htmlgen.cpp.

2432{
2433 DBG_HTML(m_t << "<!-- endMemberDocList -->\n";)
2434}

References DBG_HTML, and OutputGenerator::m_t.

◆ endMemberDocName()

void HtmlGenerator::endMemberDocName ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2475 of file htmlgen.cpp.

2476{
2477 DBG_HTML(m_t << "<!-- endMemberDocName -->\n";)
2478 m_t << "</td>\n";
2479}

References DBG_HTML, and OutputGenerator::m_t.

◆ endMemberDocPrefixItem()

void HtmlGenerator::endMemberDocPrefixItem ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2459 of file htmlgen.cpp.

2460{
2461 DBG_HTML(m_t << "<!-- endMemberDocPrefixItem -->\n";)
2462 m_t << "</div>\n";
2463}

References DBG_HTML, and OutputGenerator::m_t.

◆ endMemberDocSimple()

void HtmlGenerator::endMemberDocSimple ( bool )
overridevirtual

Implements OutputGenIntf.

Definition at line 3586 of file htmlgen.cpp.

3587{
3588 DBG_HTML(m_t << "<!-- endMemberDocSimple -->\n";)
3589 m_t << "</table>\n";
3590}

References DBG_HTML, and OutputGenerator::m_t.

◆ endMemberGroup()

void HtmlGenerator::endMemberGroup ( bool )
overridevirtual

Implements OutputGenIntf.

Definition at line 2737 of file htmlgen.cpp.

2738{
2739}

◆ endMemberGroupDocs()

void HtmlGenerator::endMemberGroupDocs ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2728 of file htmlgen.cpp.

2729{
2730 m_t << "</div></td></tr>\n";
2731}

References OutputGenerator::m_t.

◆ endMemberGroupHeader()

void HtmlGenerator::endMemberGroupHeader ( bool )
overridevirtual

Implements OutputGenIntf.

Definition at line 2718 of file htmlgen.cpp.

2719{
2720 m_t << "</div></td></tr>\n";
2721}

References OutputGenerator::m_t.

◆ endMemberHeader()

void HtmlGenerator::endMemberHeader ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2373 of file htmlgen.cpp.

2374{
2375 DBG_HTML(m_t << "<!-- endMemberHeader -->\n")
2376 m_t << "</h2></td></tr>\n";
2377}

References DBG_HTML, and OutputGenerator::m_t.

◆ endMemberItem()

void HtmlGenerator::endMemberItem ( MemberItemType type)
overridevirtual

Implements OutputGenIntf.

Definition at line 2250 of file htmlgen.cpp.

2251{
2253 {
2254 insertMemberAlign(false);
2255 }
2256 m_t << "</td></tr>\n";
2257}
OutputType type() const override
Definition htmlgen.h:119
void insertMemberAlign(bool) override
Definition htmlgen.cpp:2286

References OutputGenerator::AnonymousStart, insertMemberAlign(), OutputGenerator::m_t, and type().

◆ endMemberList()

void HtmlGenerator::endMemberList ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2217 of file htmlgen.cpp.

2218{
2219 DBG_HTML(m_t << "<!-- endMemberList -->\n")
2220}

References DBG_HTML, and OutputGenerator::m_t.

◆ endMemberSections()

void HtmlGenerator::endMemberSections ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2339 of file htmlgen.cpp.

2340{
2341 DBG_HTML(m_t << "<!-- endMemberSections -->\n")
2342 if (!m_emptySection)
2343 {
2344 m_t << "</table>\n";
2345 }
2346}

References DBG_HTML, m_emptySection, and OutputGenerator::m_t.

◆ endMemberSubtitle()

void HtmlGenerator::endMemberSubtitle ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2390 of file htmlgen.cpp.

2391{
2392 DBG_HTML(m_t << "<!-- endMemberSubtitle -->\n")
2393 m_t << "</td></tr>\n";
2394}

References DBG_HTML, and OutputGenerator::m_t.

◆ endMemberTemplateParams()

void HtmlGenerator::endMemberTemplateParams ( const DString & anchor,
const DString & inheritId )
overridevirtual

Implements OutputGenIntf.

Definition at line 2263 of file htmlgen.cpp.

2264{
2265 bool dynamicSections = Config_getBool(HTML_DYNAMIC_SECTIONS);
2266 m_t << "</td></tr>\n";
2267 m_t << "<tr class=\"memitem:" << convertToId(anchor);
2268 if (!inheritId.empty())
2269 {
2270 if (dynamicSections) m_t << " inherit";
2271 m_t << " " << inheritId;
2272 }
2273 m_t << " template\"><td class=\"memItemLeft\">";
2274}

References Config_getBool, convertToId(), DString::empty(), and OutputGenerator::m_t.

◆ endPageDoc()

void HtmlGenerator::endPageDoc ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3268 of file htmlgen.cpp.

3269{
3270 m_t << "</div><!-- PageDoc -->\n";
3271}

References OutputGenerator::m_t.

◆ endPageRef()

void HtmlGenerator::endPageRef ( const DString & ,
const DString &  )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 246 of file htmlgen.h.

246{}

◆ endParagraph()

void HtmlGenerator::endParagraph ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1870 of file htmlgen.cpp.

1871{
1872 m_t << "</p>\n";
1873}

References OutputGenerator::m_t.

◆ endParameterDefVal()

void HtmlGenerator::endParameterDefVal ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2560 of file htmlgen.cpp.

2561{
2562 m_t << "</span>";
2563}

References OutputGenerator::m_t.

◆ endParameterExtra()

void HtmlGenerator::endParameterExtra ( bool last,
bool emptyList,
bool closeBracket )
overridevirtual

Implements OutputGenIntf.

Definition at line 2529 of file htmlgen.cpp.

2530{
2531 DBG_HTML(m_t << "<!-- endParameterExtra -->\n";)
2532 if (last)
2533 {
2534 if (emptyList)
2535 {
2536 if (closeBracket) m_t << "</td><td>)";
2537 m_t << "</td>\n";
2538 m_t << " <td>";
2539 }
2540 else
2541 {
2542 m_t << "&#160;";
2543 if (closeBracket) m_t << ")";
2544 }
2545 }
2546 else
2547 {
2548 m_t << "</td>\n";
2549 m_t << " </tr>\n";
2550 }
2551}

References DBG_HTML, and OutputGenerator::m_t.

◆ endParameterList()

void HtmlGenerator::endParameterList ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2565 of file htmlgen.cpp.

2566{
2567 DBG_HTML(m_t << "<!-- endParameterList -->\n";)
2568 m_t << "</td>\n";
2569 m_t << " </tr>\n";
2570}

References DBG_HTML, and OutputGenerator::m_t.

◆ endParameterName()

void HtmlGenerator::endParameterName ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2518 of file htmlgen.cpp.

2519{
2520 DBG_HTML(m_t << "<!-- endParameterName -->\n";)
2521 m_t << "</em></span>";
2522}

References DBG_HTML, and OutputGenerator::m_t.

◆ endParameterType()

void HtmlGenerator::endParameterType ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2506 of file htmlgen.cpp.

2507{
2508 DBG_HTML(m_t << "<!-- endParameterType -->\n";)
2509 m_t << "</td>";
2510}

References DBG_HTML, and OutputGenerator::m_t.

◆ endPlainFile()

void HtmlGenerator::endPlainFile ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 332 of file htmlgen.h.

References OutputGenerator::endPlainFile().

Referenced by endFile(), and writeStyleInfo().

◆ endProjectNumber()

void HtmlGenerator::endProjectNumber ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1764 of file htmlgen.cpp.

1765{
1766 m_t << "</h3>";
1767}

References OutputGenerator::m_t.

◆ endQuickIndices()

void HtmlGenerator::endQuickIndices ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3199 of file htmlgen.cpp.

3200{
3201 bool generateTreeView = Config_getBool(GENERATE_TREEVIEW);
3202 m_t << "</div><!-- top -->\n";
3203 if (!generateTreeView)
3204 {
3205 m_t << "<div id=\"doc-content\">\n";
3206 }
3207}

References Config_getBool, and OutputGenerator::m_t.

◆ endSection()

void HtmlGenerator::endSection ( const DString & ,
SectionType type )
overridevirtual

Implements OutputGenIntf.

Definition at line 2039 of file htmlgen.cpp.

2040{
2041 switch(type.level())
2042 {
2043 case SectionType::Page: m_t << "</h1>"; break;
2044 case SectionType::Section: m_t << "</h2>"; break;
2045 case SectionType::Subsection: m_t << "</h3>"; break;
2046 case SectionType::Subsubsection: m_t << "</h4>"; break;
2047 case SectionType::Paragraph: m_t << "</h5>"; break;
2048 case SectionType::Subparagraph: m_t << "</h6>"; break;
2049 case SectionType::Subsubparagraph: m_t << "</h6>"; break;
2050 default: ASSERT(0); break;
2051 }
2052}
static constexpr int Section
Definition section.h:33
static constexpr int Subsection
Definition section.h:34
static constexpr int Subsubsection
Definition section.h:35
constexpr int level() const
Definition section.h:46
static constexpr int Page
Definition section.h:31
static constexpr int Paragraph
Definition section.h:36
static constexpr int Subsubparagraph
Definition section.h:38
static constexpr int Subparagraph
Definition section.h:37
#define ASSERT(x)
Definition dstring.h:28

References ASSERT, SectionType::level(), OutputGenerator::m_t, SectionType::Page, SectionType::Paragraph, SectionType::Section, SectionType::Subparagraph, SectionType::Subsection, SectionType::Subsubparagraph, SectionType::Subsubsection, and type().

◆ endSmall()

void HtmlGenerator::endSmall ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 234 of file htmlgen.h.

234{ m_t << "</small>\n"; }

References OutputGenerator::m_t.

◆ endTextBlock()

void HtmlGenerator::endTextBlock ( bool )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 285 of file htmlgen.h.

285{ m_t << "</div>"; }

References OutputGenerator::m_t.

◆ endTextLink()

void HtmlGenerator::endTextLink ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1981 of file htmlgen.cpp.

1982{
1983 m_t << "</a>";
1984}

References OutputGenerator::m_t.

◆ endTitle()

void HtmlGenerator::endTitle ( )
inlineprivate

Definition at line 339 of file htmlgen.h.

339{ m_t << "</div>"; }

References OutputGenerator::m_t.

Referenced by endTitleHead().

◆ endTitleHead()

void HtmlGenerator::endTitleHead ( const DString & ,
const DString &  )
overridevirtual

Implements OutputGenIntf.

Definition at line 3551 of file htmlgen.cpp.

3552{
3553 endTitle();
3554 m_t << "</div>\n";
3555}
void endTitle()
Definition htmlgen.h:339

References endTitle(), and OutputGenerator::m_t.

◆ endTocEntry()

void HtmlGenerator::endTocEntry ( const SectionInfo * si)
overridevirtual

Implements OutputGenIntf.

Definition at line 3850 of file htmlgen.cpp.

3851{
3852 SectionType type = si->type();
3853 int nextLevel = type.level();
3854 if (type.isSection() && nextLevel<=m_tocState.maxLevel)
3855 {
3856 m_t << "</a>\n";
3857 m_tocState.inLi[nextLevel]=true;
3858 m_tocState.level = nextLevel;
3859 }
3860}
SectionType type() const
Definition section.h:71
constexpr bool isSection() const
Definition section.h:47

References HtmlGenerator::TocState::inLi, SectionType::isSection(), HtmlGenerator::TocState::level, SectionType::level(), OutputGenerator::m_t, m_tocState, HtmlGenerator::TocState::maxLevel, type(), and SectionInfo::type().

◆ endTypewriter()

void HtmlGenerator::endTypewriter ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 162 of file htmlgen.h.

162{ m_t << "</code>"; }

References OutputGenerator::m_t.

◆ exceptionEntry()

void HtmlGenerator::exceptionEntry ( const DString & prefix,
bool closeBracket )
overridevirtual

Implements OutputGenIntf.

Definition at line 2572 of file htmlgen.cpp.

2573{
2574 DBG_HTML(m_t << "<!-- exceptionEntry -->\n";)
2575 if (!closeBracket)
2576 {
2577 m_t << "</td>\n";
2578 m_t << " </tr>\n";
2579 m_t << " <tr>\n";
2580 m_t << " <td align=\"right\">";
2581 }
2582 // colspan 2 so it gets both parameter type and parameter name columns
2583 if (!prefix.empty())
2584 m_t << prefix << "</td><td>(</td><td colspan=\"2\">";
2585 else if (closeBracket)
2586 m_t << "&#160;)</td><td></td><td></td><td>";
2587 else
2588 m_t << "</td><td></td><td colspan=\"2\">";
2589}
constexpr auto prefix
Definition anchor.cpp:44

References DBG_HTML, OutputGenerator::m_t, and prefix.

◆ fixSpaces()

DString HtmlGenerator::fixSpaces ( const DString & s)
static

Definition at line 3779 of file htmlgen.cpp.

3780{
3781 return substitute(s," ","&#160;");
3782}
DString substitute(const DString &s, const DString &src, const DString &dst)
substitute all occurrences of src in s by dst
Definition dstring.cpp:481

References substitute().

Referenced by renderQuickLinksAsTabs(), renderQuickLinksAsTree(), and ~HtmlGenerator().

◆ getNavTreeCss()

DString HtmlGenerator::getNavTreeCss ( )
static

Definition at line 3773 of file htmlgen.cpp.

3774{
3775 ResourceMgr &mgr = ResourceMgr::instance();
3776 return replaceVariables(mgr.getAsString("navtree.css"));
3777}
static ResourceMgr & instance()
Returns the one and only instance of this class.
DString getAsString(const DString &name) const
Gets the resource data as a C string.
static DString replaceVariables(const DString &input)
Definition htmlgen.cpp:785

References ResourceMgr::getAsString(), ResourceMgr::instance(), and replaceVariables().

Referenced by init(), and ~HtmlGenerator().

◆ init()

void HtmlGenerator::init ( )
static

Definition at line 1282 of file htmlgen.cpp.

1283{
1284 DString dname = Config_getString(HTML_OUTPUT);
1285 Dir d(dname.str());
1286 if (!d.exists() && !d.mkdir(dname.str()))
1287 {
1288 term("Could not create output directory {}\n",dname);
1289 }
1290 //writeLogo(dname);
1291 if (!Config_getString(HTML_HEADER).empty())
1292 {
1293 g_header_file=Config_getString(HTML_HEADER);
1296 //printf("g_header='%s'\n",qPrint(g_header));
1298 checkBlocks(result,Config_getString(HTML_HEADER),htmlMarkerInfo);
1299 }
1300 else
1301 {
1302 g_header_file="header.html";
1306 checkBlocks(result,"<default header.html>",htmlMarkerInfo);
1307 }
1308
1309 if (!Config_getString(HTML_FOOTER).empty())
1310 {
1311 g_footer_file=Config_getString(HTML_FOOTER);
1314 //printf("g_footer='%s'\n",qPrint(g_footer));
1316 checkBlocks(result,Config_getString(HTML_FOOTER),htmlMarkerInfo);
1317 }
1318 else
1319 {
1320 g_footer_file = "footer.html";
1324 checkBlocks(result,"<default footer.html>",htmlMarkerInfo);
1325 }
1326
1327 if (Config_getBool(USE_MATHJAX))
1328 {
1329 if (!Config_getString(MATHJAX_CODEFILE).empty())
1330 {
1331 g_mathjax_code=fileToString(Config_getString(MATHJAX_CODEFILE));
1332 //printf("g_mathjax_code='%s'\n",qPrint(g_mathjax_code));
1333 }
1335 //printf("converted g_latex_macro='%s'\n",qPrint(g_latex_macro));
1336 }
1337 createSubDirs(d);
1338
1340
1341 ResourceMgr &mgr = ResourceMgr::instance();
1342
1343 {
1344 DString tabsCss;
1345 if (Config_getBool(HTML_DYNAMIC_MENUS))
1346 {
1347 tabsCss = mgr.getAsString("tabs.css");
1348 }
1349 else // stylesheet for the 'old' static tabs
1350 {
1351 tabsCss = mgr.getAsString("fixed_tabs.css");
1352 }
1353
1354 std::ofstream f = Portable::openOutputStream(dname+"/tabs.css");
1355 if (f.is_open())
1356 {
1357 TextStream t(&f);
1358 t << replaceVariables(tabsCss);
1359 }
1360 }
1361
1362
1363 if (Config_getBool(INTERACTIVE_SVG))
1364 {
1365 mgr.copyResource("svg.min.js",dname);
1366 }
1367
1368 if (!Config_getBool(DISABLE_INDEX) && Config_getBool(HTML_DYNAMIC_MENUS))
1369 {
1370 mgr.copyResource("menu.js",dname);
1371 }
1372
1373 // copy navtree.css
1374 {
1375 std::ofstream f = Portable::openOutputStream(dname+"/navtree.css");
1376 if (f.is_open())
1377 {
1378 TextStream t(&f);
1379 t << getNavTreeCss();
1380 }
1381 }
1382
1383 if (Config_getBool(HTML_COPY_CLIPBOARD))
1384 {
1385 std::ofstream f = Portable::openOutputStream(dname+"/clipboard.js");
1386 if (f.is_open())
1387 {
1388 TextStream t(&f);
1389 t << substitute(mgr.getAsString("clipboard.js"),"$copy_to_clipboard_text",theTranslator->trCopyToClipboard());
1390 }
1391 }
1392
1393 bool hasCookie = Config_getBool(GENERATE_TREEVIEW) || Config_getBool(SEARCHENGINE) || Config_getEnum(HTML_COLORSTYLE)==HTML_COLORSTYLE_t::TOGGLE;
1394 if (hasCookie)
1395 {
1396 mgr.copyResource("cookie.js",dname);
1397 }
1398
1399 if (Config_getBool(HTML_COLORSTYLE)==HTML_COLORSTYLE_t::TOGGLE)
1400 {
1401 std::ofstream f = Portable::openOutputStream(dname+"/darkmode_toggle.js");
1402 if (f.is_open())
1403 {
1404 TextStream t(&f);
1405 t << substitute(replaceColorMarkers(mgr.getAsString("darkmode_toggle.js")),
1406 "$PROJECTID",getProjectId());
1407 }
1408 }
1409
1410 if (Config_getBool(HTML_DYNAMIC_SECTIONS) ||
1411 (Config_getBool(SOURCE_BROWSER) && Config_getBool(SOURCE_TOOLTIPS)))
1412 {
1413 std::ofstream f = Portable::openOutputStream(dname+"/dynsections.js");
1414 if (f.is_open())
1415 {
1416 TextStream t(&f);
1417 if (Config_getBool(HTML_DYNAMIC_SECTIONS))
1418 {
1419 t << replaceVariables(mgr.getAsString("dynsections.js"));
1420 }
1421 if (Config_getBool(SOURCE_BROWSER) && Config_getBool(SOURCE_TOOLTIPS))
1422 {
1423 t << replaceVariables(mgr.getAsString("dynsections_tooltips.js"));
1424 }
1425 }
1426 }
1427 if (Config_getBool(HTML_CODE_FOLDING))
1428 {
1429 std::ofstream f = Portable::openOutputStream(dname+"/codefolding.js");
1430 if (f.is_open())
1431 {
1432 TextStream t(&f);
1433 t << replaceVariables(mgr.getAsString("codefolding.js"));
1434 }
1435 }
1436}
DString()=default
static DString getNavTreeCss()
Definition htmlgen.cpp:3773
bool copyResource(const DString &name, const DString &targetDir) const
Copies a registered resource to a given target directory.
virtual DString trCopyToClipboard()=0
#define Config_getEnum(name)
Definition config.h:35
static bool g_build_date
Definition htmlgen.cpp:70
static bool hasDateReplacement(const DString &str)
Definition htmlgen.cpp:1273
static DString substituteHtmlKeywords(const DString &file, const DString &str, const DString &title, const DString &relPath, const DString &navPath=DString(), bool isSource=false)
Definition htmlgen.cpp:308
static const SelectionMarkerInfo htmlMarkerInfo
Definition htmlgen.cpp:73
static DString g_footer
Definition htmlgen.cpp:67
static DString g_latex_macro
Definition htmlgen.cpp:69
static void fillColorStyleMaps()
Definition htmlgen.cpp:771
static DString g_header_file
Definition htmlgen.cpp:65
static DString getConvertLatexMacro()
Convert a set of LaTeX commands \‍(re)newcommand to a form readable by MathJax LaTeX syntax:
Definition htmlgen.cpp:143
static DString g_mathjax_code
Definition htmlgen.cpp:68
static DString g_header
Definition htmlgen.cpp:64
static DString g_footer_file
Definition htmlgen.cpp:66
#define term(fmt,...)
Definition message.h:137
std::ofstream openOutputStream(const DString &name, bool append=false)
Definition portable.cpp:665
DString replaceColorMarkers(const DString &str)
Replaces any markers of the form ##AA in input string str by new markers of the form #AABBCC,...
Definition util.cpp:4570
DString getProjectId()
Definition util.cpp:5272
void createSubDirs(const Dir &d)
Definition util.cpp:2971
void checkBlocks(const DString &s, const DString fileName, const SelectionMarkerInfo &markerInfo)
Definition util.cpp:5116
DString fileToString(const DString &name, bool filter, bool isSourceCode)
Definition util.cpp:1055

References checkBlocks(), Config_getBool, Config_getEnum, Config_getString, ResourceMgr::copyResource(), createSubDirs(), DString::DString(), Dir::exists(), fileToString(), fillColorStyleMaps(), g_build_date, g_footer, g_footer_file, g_header, g_header_file, g_latex_macro, g_mathjax_code, ResourceMgr::getAsString(), getConvertLatexMacro(), getNavTreeCss(), getProjectId(), hasDateReplacement(), htmlMarkerInfo, ResourceMgr::instance(), Dir::mkdir(), Portable::openOutputStream(), replaceColorMarkers(), replaceVariables(), DString::str(), substitute(), substituteHtmlKeywords(), term, theTranslator, and Translator::trCopyToClipboard().

Referenced by generateOutput(), and ~HtmlGenerator().

◆ insertMemberAlign()

void HtmlGenerator::insertMemberAlign ( bool )
overridevirtual

Implements OutputGenIntf.

Definition at line 2286 of file htmlgen.cpp.

2287{
2288 DBG_HTML(m_t << "<!-- insertMemberAlign -->\n")
2289 m_t << "&#160;</td><td class=\"memItemRight\">";
2290}

References DBG_HTML, and OutputGenerator::m_t.

Referenced by endMemberItem().

◆ insertMemberAlignLeft()

void HtmlGenerator::insertMemberAlignLeft ( MemberItemType type,
bool initTag )
overridevirtual

Implements OutputGenIntf.

Definition at line 2292 of file htmlgen.cpp.

2293{
2294 if (!initTag) m_t << "&#160;</td>";
2295 switch (type)
2296 {
2297 case MemberItemType::Normal: m_t << "<td class=\"memItemLeft\">"; break;
2298 case MemberItemType::AnonymousStart: m_t << "<td class=\"memItemLeft anon\">"; break;
2299 case MemberItemType::AnonymousEnd: m_t << "<td class=\"memItemLeft anonEnd\">"; break;
2300 case MemberItemType::Templated: m_t << "<td class=\"memTemplParams\" colspan=\"2\">"; break;
2301 }
2302}

References OutputGenerator::AnonymousEnd, OutputGenerator::AnonymousStart, OutputGenerator::m_t, OutputGenerator::Normal, OutputGenerator::Templated, and type().

Referenced by startMemberItem().

◆ lastIndexPage()

void HtmlGenerator::lastIndexPage ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 286 of file htmlgen.h.

286{}

◆ lineBreak()

void HtmlGenerator::lineBreak ( const DString & style)
overridevirtual

Implements OutputGenIntf.

Definition at line 3528 of file htmlgen.cpp.

3529{
3530 if (!style.empty())
3531 {
3532 m_t << "<br class=\"" << style << "\" />\n";
3533 }
3534 else
3535 {
3536 m_t << "<br />\n";
3537 }
3538}

References DString::empty(), and OutputGenerator::m_t.

◆ operator=() [1/2]

HtmlGenerator & HtmlGenerator::operator= ( const HtmlGenerator & og)

Definition at line 1248 of file htmlgen.cpp.

1249{
1250 //printf("%p:HtmlGenerator(copy assign %p)\n",(void*)this,(void*)&og);
1251 if (this!=&og)
1252 {
1253 m_dir = og.m_dir;
1254 m_codeList = std::make_unique<OutputCodeList>(*og.m_codeList);
1255 m_codeGen = m_codeList->get<HtmlCodeGenerator>(OutputType::Html);
1259 m_relPath = og.m_relPath;
1262 }
1263 return *this;
1264}

References Html, HtmlGenerator(), m_codeGen, m_codeList, OutputGenerator::m_dir, m_emptySection, m_lastFile, m_lastTitle, m_relPath, m_sectionCount, OutputGenerator::m_t, and HtmlCodeGenerator::setTextStream().

◆ operator=() [2/2]

HtmlGenerator & HtmlGenerator::operator= ( HtmlGenerator && )
delete

References HtmlGenerator().

◆ startAnonTypeScope()

void HtmlGenerator::startAnonTypeScope ( int )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 182 of file htmlgen.h.

182{}

◆ startBold()

void HtmlGenerator::startBold ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 213 of file htmlgen.h.

213{ m_t << "<b>"; }

References OutputGenerator::m_t.

◆ startCallGraph()

void HtmlGenerator::startCallGraph ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2672 of file htmlgen.cpp.

2673{
2675}
static void startSectionHeader(TextStream &t, const DString &relPath, int sectionCount)
Definition htmlgen.cpp:2106

References m_relPath, m_sectionCount, OutputGenerator::m_t, and startSectionHeader().

◆ startCenter()

void HtmlGenerator::startCenter ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 231 of file htmlgen.h.

231{ m_t << "<center>\n"; }

References OutputGenerator::m_t.

◆ startClassDiagram()

void HtmlGenerator::startClassDiagram ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2173 of file htmlgen.cpp.

References m_relPath, m_sectionCount, OutputGenerator::m_t, and startSectionHeader().

◆ startCompoundTemplateParams()

void HtmlGenerator::startCompoundTemplateParams ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2276 of file htmlgen.cpp.

2277{
2278 m_t << "<div class=\"compoundTemplParams\">";
2279}

References OutputGenerator::m_t.

◆ startConstraintDocs()

void HtmlGenerator::startConstraintDocs ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3510 of file htmlgen.cpp.

3511{
3512 m_t << "<td>&#160;";
3513}

References OutputGenerator::m_t.

◆ startConstraintList()

void HtmlGenerator::startConstraintList ( const DString & header)
overridevirtual

Implements OutputGenIntf.

Definition at line 3483 of file htmlgen.cpp.

3484{
3485 m_t << "<div class=\"typeconstraint\">\n";
3486 m_t << "<dl><dt><b>" << header << "</b></dt><dd>\n";
3487 m_t << "<table border=\"0\" cellspacing=\"2\" cellpadding=\"0\">\n";
3488}

References OutputGenerator::m_t.

◆ startConstraintParam()

void HtmlGenerator::startConstraintParam ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3490 of file htmlgen.cpp.

3491{
3492 m_t << "<tr><td valign=\"top\"><em>";
3493}

References OutputGenerator::m_t.

◆ startConstraintType()

void HtmlGenerator::startConstraintType ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3500 of file htmlgen.cpp.

3501{
3502 m_t << "<td>&#160;:</td><td valign=\"top\"><em>";
3503}

References OutputGenerator::m_t.

◆ startContents()

void HtmlGenerator::startContents ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3253 of file htmlgen.cpp.

3254{
3255 m_t << "<div class=\"contents\">\n";
3256}

References OutputGenerator::m_t.

◆ startDescForItem()

void HtmlGenerator::startDescForItem ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 215 of file htmlgen.h.

215{ m_t << "<dd>"; }

References OutputGenerator::m_t.

◆ startDescTable()

void HtmlGenerator::startDescTable ( const DString & title,
const bool hasInits )
overridevirtual

Implements OutputGenIntf.

Definition at line 2766 of file htmlgen.cpp.

2767{
2768 m_t << "<table class=\"fieldtable\">\n"
2769 << "<tr><th colspan=\"" << (hasInits?3:2) << "\">" << title << "</th></tr>";
2770}

References OutputGenerator::m_t.

◆ startDescTableData()

void HtmlGenerator::startDescTableData ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2806 of file htmlgen.cpp.

2807{
2808 m_t << "<td class=\"fielddoc\">";
2809}

References OutputGenerator::m_t.

◆ startDescTableInit()

void HtmlGenerator::startDescTableInit ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2796 of file htmlgen.cpp.

2797{
2798 m_t << "<td class=\"fieldinit\">";
2799}

References OutputGenerator::m_t.

◆ startDescTableRow()

void HtmlGenerator::startDescTableRow ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2776 of file htmlgen.cpp.

2777{
2778 m_t << "<tr>";
2779}

References OutputGenerator::m_t.

◆ startDescTableTitle()

void HtmlGenerator::startDescTableTitle ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2786 of file htmlgen.cpp.

2787{
2788 m_t << "<td class=\"fieldname\">";
2789}

References OutputGenerator::m_t.

◆ startDirDepGraph()

void HtmlGenerator::startDirDepGraph ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2690 of file htmlgen.cpp.

References m_relPath, m_sectionCount, OutputGenerator::m_t, and startSectionHeader().

◆ startDotGraph()

void HtmlGenerator::startDotGraph ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2602 of file htmlgen.cpp.

References m_relPath, m_sectionCount, OutputGenerator::m_t, and startSectionHeader().

◆ startDoxyAnchor()

void HtmlGenerator::startDoxyAnchor ( const DString & fName,
const DString & manName,
const DString & anchor,
const DString & name,
const DString & args )
overridevirtual

Implements OutputGenIntf.

Definition at line 1847 of file htmlgen.cpp.

1850{
1851 m_t << "<a id=\"" << anchor << "\" name=\"" << anchor << "\"></a>";
1852}

References OutputGenerator::m_t.

◆ startEmbeddedDoc()

void HtmlGenerator::startEmbeddedDoc ( size_t indent)
overridevirtual

Implements OutputGenIntf.

Definition at line 3628 of file htmlgen.cpp.

3629{
3630 DBG_HTML(m_t << "<!-- startEmbeddedDoc -->\n";)
3631 m_t << "<div class=\"embeddoc indent-" << indent << "\">";
3632}

References DBG_HTML, and OutputGenerator::m_t.

◆ startEmphasis()

void HtmlGenerator::startEmphasis ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 211 of file htmlgen.h.

211{ m_t << "<em>"; }

References OutputGenerator::m_t.

◆ startExamples()

void HtmlGenerator::startExamples ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2816 of file htmlgen.cpp.

2817{
2818 m_t << "<dl class=\"section examples\"><dt>";
2820 m_t << "</dt>";
2821}
void docify(const DString &text) override
Definition htmlgen.cpp:2054
virtual DString trExamples()=0

References docify(), OutputGenerator::m_t, theTranslator, and Translator::trExamples().

◆ startFile()

void HtmlGenerator::startFile ( const DString & name,
bool isSource,
const DString & manName,
const DString & title,
int id,
int hierarchyLevel )
overridevirtual

Implements OutputGenIntf.

Definition at line 1644 of file htmlgen.cpp.

1646{
1647 //printf("HtmlGenerator::startFile(%s)\n",qPrint(name));
1649 DString fileName = name;
1651 m_lastTitle=title;
1652
1656 {
1657 std::lock_guard<std::mutex> lock(g_indexLock);
1659 }
1660
1663
1664 m_t << "<!-- " << theTranslator->trGeneratedBy() << " Doxygen "
1665 << getDoxygenVersion() << " -->\n";
1666 bool searchEngine = Config_getBool(SEARCHENGINE);
1667 if (searchEngine /*&& !generateTreeView*/)
1668 {
1669 m_t << "<script type=\"text/javascript\">\n";
1670 m_t << "let searchBox = new SearchBox(\"searchBox\", \""
1671 << m_relPath<< "search/\",'" << Doxygen::htmlFileExtension << "');\n";
1672 m_t << "</script>\n";
1673 }
1674 if (Config_getBool(HTML_CODE_FOLDING))
1675 {
1676 m_t << "<script type=\"text/javascript\">\n";
1677 m_t << "document.addEventListener('DOMContentLoaded', codefold.init);\n";
1678 m_t << "</script>\n";
1679 }
1681}
static IndexList * indexList
Definition doxygen.h:125
void setFileName(const DString fileName)
Definition htmlgen.h:29
void setRelativePath(const DString &path)
Definition htmlgen.cpp:844
void startPlainFile(const DString &name) override
Definition htmlgen.h:331
void addIndexFile(const DString &name)
Definition indexlist.h:121
virtual DString trGeneratedBy()=0
static std::mutex g_indexLock
Definition htmlgen.cpp:1642
DString filterTitle(const DString &title)
Definition util.cpp:4456
DString convertToHtml(const DString &s, bool keepEntities)
Definition util.cpp:3293
void addHtmlExtensionIfMissing(DString &fName)
Definition util.cpp:3933
DString relativePathToRoot(const DString &name)
Definition util.cpp:2914

References addHtmlExtensionIfMissing(), IndexList::addIndexFile(), Config_getBool, convertToHtml(), DString::DString(), OutputGenerator::fileName(), filterTitle(), g_header, g_header_file, g_indexLock, Doxygen::htmlFileExtension, Doxygen::indexList, m_codeGen, m_lastFile, m_lastTitle, m_relPath, m_sectionCount, OutputGenerator::m_t, relativePathToRoot(), HtmlCodeGenerator::setFileName(), HtmlCodeGenerator::setRelativePath(), startPlainFile(), substituteHtmlKeywords(), theTranslator, and Translator::trGeneratedBy().

◆ startGroupCollaboration()

void HtmlGenerator::startGroupCollaboration ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2654 of file htmlgen.cpp.

References m_relPath, m_sectionCount, OutputGenerator::m_t, and startSectionHeader().

◆ startGroupHeader()

void HtmlGenerator::startGroupHeader ( const DString & id,
int extraIndentLevel )
overridevirtual

Implements OutputGenIntf.

Definition at line 1986 of file htmlgen.cpp.

1987{
1988 if (extraIndentLevel==2)
1989 {
1990 m_t << "<h4";
1991 }
1992 else if (extraIndentLevel==1)
1993 {
1994 m_t << "<h3";
1995 }
1996 else // extraIndentLevel==0
1997 {
1998 m_t << "<h2";
1999 }
2000 if (!id.empty())
2001 {
2002 m_t <<" id=\"header-"+convertToId(id)+"\"";
2003 }
2004 m_t << " class=\"groupheader\">";
2005}

References convertToId(), and OutputGenerator::m_t.

◆ startHeaderSection()

void HtmlGenerator::startHeaderSection ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3540 of file htmlgen.cpp.

3541{
3542 m_t << "<div class=\"header\">\n";
3543}

References OutputGenerator::m_t.

◆ startInclDepGraph()

void HtmlGenerator::startInclDepGraph ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2636 of file htmlgen.cpp.

References m_relPath, m_sectionCount, OutputGenerator::m_t, and startSectionHeader().

◆ startIndent()

void HtmlGenerator::startIndent ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2741 of file htmlgen.cpp.

2742{
2743 DBG_HTML(m_t << "<!-- startIndent -->\n";)
2744
2745 m_t << "<div class=\"memdoc\">\n";
2746}

References DBG_HTML, and OutputGenerator::m_t.

◆ startIndexItem()

void HtmlGenerator::startIndexItem ( const DString & ref,
const DString & file )
overridevirtual

Implements OutputGenIntf.

Definition at line 1890 of file htmlgen.cpp.

1891{
1892 //printf("HtmlGenerator::startIndexItem(%s,%s)\n",ref,f);
1893 if (!ref.empty() || !f.empty())
1894 {
1895 if (!ref.empty())
1896 {
1897 m_t << "<a class=\"elRef\" ";
1899 }
1900 else
1901 {
1902 m_t << "<a class=\"el\" ";
1903 }
1904 m_t << "href=\"";
1905 m_t << externalRef(m_relPath,ref);
1906 if (!f.empty())
1907 {
1908 DString fn=f;
1910 m_t << fn;
1911 }
1912 m_t << "\">";
1913 }
1914 else
1915 {
1916 m_t << "<b>";
1917 }
1918}
DString externalLinkTarget(const bool parent)
Definition util.cpp:4493
DString externalRef(const DString &relPath, const DString &ref)
Definition util.cpp:4540

References addHtmlExtensionIfMissing(), DString::empty(), externalLinkTarget(), externalRef(), m_relPath, and OutputGenerator::m_t.

◆ startIndexKey()

void HtmlGenerator::startIndexKey ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2406 of file htmlgen.cpp.

2407{
2408 //m_t << " <tr><td class=\"indexkey\">";
2409}

◆ startIndexList()

void HtmlGenerator::startIndexList ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2396 of file htmlgen.cpp.

2397{
2398 m_t << "<table>\n";
2399}

References OutputGenerator::m_t.

◆ startIndexListItem()

void HtmlGenerator::startIndexListItem ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1880 of file htmlgen.cpp.

1881{
1882 m_t << "<li>";
1883}

References OutputGenerator::m_t.

◆ startIndexSection()

void HtmlGenerator::startIndexSection ( IndexSection )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 130 of file htmlgen.h.

130{}

◆ startIndexValue()

void HtmlGenerator::startIndexValue ( bool )
overridevirtual

Implements OutputGenIntf.

Definition at line 2416 of file htmlgen.cpp.

2417{
2418 //m_t << "<td class=\"indexvalue\">";
2419}

◆ startInlineHeader()

void HtmlGenerator::startInlineHeader ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3562 of file htmlgen.cpp.

3563{
3564 if (m_emptySection)
3565 {
3566 m_t << "<table class=\"memberdecls memberdecls-inline\">\n";
3567 m_emptySection=false;
3568 }
3569 m_t << "<tr><th colspan=\"2\"><h3>";
3570}

References m_emptySection, and OutputGenerator::m_t.

◆ startInlineMemberDoc()

void HtmlGenerator::startInlineMemberDoc ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3616 of file htmlgen.cpp.

3617{
3618 DBG_HTML(m_t << "<!-- startInlineMemberDoc -->\n";)
3619 m_t << "<td class=\"fielddoc\">\n";
3620}

References DBG_HTML, and OutputGenerator::m_t.

◆ startInlineMemberName()

void HtmlGenerator::startInlineMemberName ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3604 of file htmlgen.cpp.

3605{
3606 DBG_HTML(m_t << "<!-- startInlineMemberName -->\n";)
3607 m_t << "<td class=\"fieldname\">\n";
3608}

References DBG_HTML, and OutputGenerator::m_t.

◆ startInlineMemberType()

void HtmlGenerator::startInlineMemberType ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3592 of file htmlgen.cpp.

3593{
3594 DBG_HTML(m_t << "<!-- startInlineMemberType -->\n";)
3595 m_t << "<tr><td class=\"fieldtype\">\n";
3596}

References DBG_HTML, and OutputGenerator::m_t.

◆ startItemList()

void HtmlGenerator::startItemList ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 150 of file htmlgen.h.

150{ m_t << "<ul>\n"; }

References OutputGenerator::m_t.

◆ startItemListItem()

void HtmlGenerator::startItemListItem ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 165 of file htmlgen.h.

165{ m_t << "<li>"; }

References OutputGenerator::m_t.

◆ startLabels()

void HtmlGenerator::startLabels ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3640 of file htmlgen.cpp.

3641{
3642 DBG_HTML(m_t << "<!-- startLabels -->\n";)
3643 m_t << "<span class=\"mlabels\">";
3644}

References DBG_HTML, and OutputGenerator::m_t.

◆ startLocalToc()

void HtmlGenerator::startLocalToc ( int level)
overridevirtual

Implements OutputGenIntf.

Definition at line 3784 of file htmlgen.cpp.

3785{
3786 m_tocState.level=0;
3788 m_tocState.maxLevel=level;
3789 m_tocState.inLi = BoolVector(level+1,false);
3790 m_t << "<div class=\"toc\">";
3791 m_t << "<h3>" << theTranslator->trRTFTableOfContents() << "</h3>\n";
3792}
virtual DString trRTFTableOfContents()=0
std::vector< bool > BoolVector
Definition containers.h:36

References HtmlGenerator::TocState::indent, HtmlGenerator::TocState::inLi, HtmlGenerator::TocState::level, OutputGenerator::m_t, m_tocState, HtmlGenerator::TocState::maxLevel, theTranslator, and Translator::trRTFTableOfContents().

◆ startMemberDeclaration()

void HtmlGenerator::startMemberDeclaration ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 202 of file htmlgen.h.

202{}

◆ startMemberDescription()

void HtmlGenerator::startMemberDescription ( const DString & anchor,
const DString & inheritId,
bool typ )
overridevirtual

Implements OutputGenIntf.

Definition at line 2304 of file htmlgen.cpp.

2305{
2306 DBG_HTML(m_t << "<!-- startMemberDescription -->\n")
2307 bool dynamicSections = Config_getBool(HTML_DYNAMIC_SECTIONS);
2308 if (m_emptySection)
2309 {
2310 m_t << "<table class=\"memberdecls\">\n";
2311 m_emptySection=false;
2312 }
2313 m_t << "<tr class=\"memdesc:" << anchor;
2314 if (!inheritId.empty())
2315 {
2316 if (dynamicSections) m_t << " inherit";
2317 m_t << " " << inheritId;
2318 }
2319 m_t << "\">";
2320 m_t << "<td class=\"mdescLeft\">&#160;</td>";
2321 if (typ) m_t << "<td class=\"mdescLeft\">&#160;</td>";
2322 m_t << "<td class=\"mdescRight\">";
2323}

References Config_getBool, DBG_HTML, DString::empty(), m_emptySection, and OutputGenerator::m_t.

◆ startMemberDoc()

void HtmlGenerator::startMemberDoc ( const DString & clName,
const DString & memName,
const DString & anchor,
const DString & title,
int memCount,
int memTotal,
bool showInline )
overridevirtual

Implements OutputGenIntf.

Definition at line 2436 of file htmlgen.cpp.

2439{
2440 DBG_HTML(m_t << "<!-- startMemberDoc -->\n";)
2441 m_t << "\n<h2 class=\"memtitle\">"
2442 << "<span class=\"permalink\"><a href=\"#" << anchor << "\">&#9670;&#160;</a></span>";
2443 docify(title);
2444 if (memTotal>1)
2445 {
2446 m_t << " <span class=\"overload\">[" << memCount << "/" << memTotal <<"]</span>";
2447 }
2448 m_t << "</h2>\n";
2449 m_t << "\n<div class=\"memitem\">\n";
2450 m_t << "<div class=\"memproto\">\n";
2451}

References DBG_HTML, docify(), and OutputGenerator::m_t.

◆ startMemberDocList()

void HtmlGenerator::startMemberDocList ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2426 of file htmlgen.cpp.

2427{
2428 DBG_HTML(m_t << "<!-- startMemberDocList -->\n";)
2429}

References DBG_HTML, and OutputGenerator::m_t.

◆ startMemberDocName()

void HtmlGenerator::startMemberDocName ( bool )
overridevirtual

Implements OutputGenIntf.

Definition at line 2465 of file htmlgen.cpp.

2466{
2467 DBG_HTML(m_t << "<!-- startMemberDocName -->\n";)
2468
2469 m_t << " <table class=\"memname\">\n";
2470
2471 m_t << " <tr>\n";
2472 m_t << " <td class=\"memname\">";
2473}

References DBG_HTML, and OutputGenerator::m_t.

◆ startMemberDocPrefixItem()

void HtmlGenerator::startMemberDocPrefixItem ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2453 of file htmlgen.cpp.

2454{
2455 DBG_HTML(m_t << "<!-- startMemberDocPrefixItem -->\n";)
2456 m_t << "<div class=\"memtemplate\">\n";
2457}

References DBG_HTML, and OutputGenerator::m_t.

◆ startMemberDocSimple()

void HtmlGenerator::startMemberDocSimple ( bool isEnum)
overridevirtual

Implements OutputGenIntf.

Definition at line 3577 of file htmlgen.cpp.

3578{
3579 DBG_HTML(m_t << "<!-- startMemberDocSimple -->\n";)
3580 m_t << "<table class=\"fieldtable\">\n";
3581 m_t << "<tr><th colspan=\"" << (isEnum?"2":"3") << "\">";
3582 m_t << (isEnum? theTranslator->trEnumerationValues() :
3583 theTranslator->trCompoundMembers()) << "</th></tr>\n";
3584}
virtual DString trCompoundMembers()=0
virtual DString trEnumerationValues()=0

References DBG_HTML, OutputGenerator::m_t, theTranslator, Translator::trCompoundMembers(), and Translator::trEnumerationValues().

◆ startMemberGroup()

void HtmlGenerator::startMemberGroup ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2733 of file htmlgen.cpp.

2734{
2735}

◆ startMemberGroupDocs()

void HtmlGenerator::startMemberGroupDocs ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2723 of file htmlgen.cpp.

2724{
2725 m_t << "<tr><td colspan=\"2\" class=\"ititle\"><div class=\"groupText\">";
2726}

References OutputGenerator::m_t.

◆ startMemberGroupHeader()

void HtmlGenerator::startMemberGroupHeader ( const DString & id,
bool  )
overridevirtual

Implements OutputGenIntf.

Definition at line 2713 of file htmlgen.cpp.

2714{
2715 m_t << "<tr id=\"" << id << "\" class=\"groupHeader\"><td colspan=\"2\"><div class=\"groupHeader\">";
2716}

References OutputGenerator::m_t.

◆ startMemberHeader()

void HtmlGenerator::startMemberHeader ( const DString & anchor,
int typ )
overridevirtual

Implements OutputGenIntf.

Definition at line 2348 of file htmlgen.cpp.

2349{
2350 DBG_HTML(m_t << "<!-- startMemberHeader -->\n")
2351 if (!m_emptySection)
2352 {
2353 m_t << "</table>";
2354 m_emptySection=true;
2355 }
2356 if (m_emptySection)
2357 {
2358 m_t << "<table class=\"memberdecls\">\n";
2359 m_emptySection=false;
2360 }
2361 m_t << "<tr class=\"heading\"><td colspan=\"" << typ << "\"><h2";
2362 if (!anchor.empty())
2363 {
2364 m_t << " id=\"header-" << anchor << "\"";
2365 }
2366 m_t << " class=\"groupheader\">";
2367 if (!anchor.empty())
2368 {
2369 m_t << "<a id=\"" << anchor << "\" name=\"" << anchor << "\"></a>\n";
2370 }
2371}

References DBG_HTML, DString::empty(), m_emptySection, and OutputGenerator::m_t.

◆ startMemberItem()

void HtmlGenerator::startMemberItem ( const DString & anchor,
MemberItemType type,
const DString & inheritId )
overridevirtual

Implements OutputGenIntf.

Definition at line 2226 of file htmlgen.cpp.

2227{
2228 DBG_HTML(m_t << "<!-- startMemberItem() -->\n")
2229 bool dynamicSections = Config_getBool(HTML_DYNAMIC_SECTIONS);
2230 if (m_emptySection)
2231 {
2232 m_t << "<table class=\"memberdecls\">\n";
2233 m_emptySection=false;
2234 }
2235 m_t << "<tr class=\"memitem:" << convertToId(anchor);
2236 if (!inheritId.empty())
2237 {
2238 if (dynamicSections) m_t << " inherit";
2239 m_t << " " << inheritId;
2240 }
2241 m_t << "\"";
2242 if (!anchor.empty())
2243 {
2244 m_t << " id=\"r_" << convertToId(anchor) << "\"";
2245 }
2246 m_t << ">";
2248}
void insertMemberAlignLeft(MemberItemType, bool) override
Definition htmlgen.cpp:2292

References Config_getBool, convertToId(), DBG_HTML, DString::empty(), insertMemberAlignLeft(), m_emptySection, OutputGenerator::m_t, and type().

◆ startMemberList()

void HtmlGenerator::startMemberList ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2212 of file htmlgen.cpp.

2213{
2214 DBG_HTML(m_t << "<!-- startMemberList -->\n")
2215}

References DBG_HTML, and OutputGenerator::m_t.

◆ startMemberSections()

void HtmlGenerator::startMemberSections ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2331 of file htmlgen.cpp.

2332{
2333 DBG_HTML(m_t << "<!-- startMemberSections -->\n")
2334 m_emptySection=true; // we postpone writing <table> until we actually
2335 // write a row to prevent empty tables, which
2336 // are not valid XHTML!
2337}

References DBG_HTML, m_emptySection, and OutputGenerator::m_t.

◆ startMemberSubtitle()

void HtmlGenerator::startMemberSubtitle ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2379 of file htmlgen.cpp.

2380{
2381 DBG_HTML(m_t << "<!-- startMemberSubtitle -->\n")
2382 if (m_emptySection)
2383 {
2384 m_t << "<table class=\"memberdecls\">\n";
2385 m_emptySection=false;
2386 }
2387 m_t << "<tr><td class=\"ititle\" colspan=\"2\">";
2388}

References DBG_HTML, m_emptySection, and OutputGenerator::m_t.

◆ startMemberTemplateParams()

void HtmlGenerator::startMemberTemplateParams ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2259 of file htmlgen.cpp.

2260{
2261}

◆ startPageDoc()

void HtmlGenerator::startPageDoc ( const DString & pageTitle)
overridevirtual

Implements OutputGenIntf.

Definition at line 3263 of file htmlgen.cpp.

3264{
3265 m_t << "<div>";
3266}

References OutputGenerator::m_t.

◆ startPageRef()

void HtmlGenerator::startPageRef ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 245 of file htmlgen.h.

245{}

◆ startParagraph()

void HtmlGenerator::startParagraph ( const DString & classDef)
overridevirtual

Implements OutputGenIntf.

Definition at line 1862 of file htmlgen.cpp.

1863{
1864 if (!classDef.empty())
1865 m_t << "\n<p class=\"" << classDef << "\">";
1866 else
1867 m_t << "\n<p>";
1868}

References DString::empty(), and OutputGenerator::m_t.

◆ startParameterDefVal()

void HtmlGenerator::startParameterDefVal ( const char * sep)
overridevirtual

Implements OutputGenIntf.

Definition at line 2553 of file htmlgen.cpp.

2554{
2555 m_t << "<span class=\"paramdefsep\">";
2556 docify(s);
2557 m_t << "</span><span class=\"paramdefval\">";
2558}

References docify(), and OutputGenerator::m_t.

◆ startParameterExtra()

void HtmlGenerator::startParameterExtra ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 2524 of file htmlgen.cpp.

2525{
2526 DBG_HTML(m_t << "<!-- startParameterExtra -->\n";)
2527}

References DBG_HTML, and OutputGenerator::m_t.

◆ startParameterList()

void HtmlGenerator::startParameterList ( bool openBracket)
overridevirtual

Implements OutputGenIntf.

Definition at line 2481 of file htmlgen.cpp.

2482{
2483 DBG_HTML(m_t << "<!-- startParameterList -->\n";)
2484 m_t << " <td>";
2485 if (openBracket) m_t << "(";
2486 m_t << "</td>\n";
2487}

References DBG_HTML, and OutputGenerator::m_t.

◆ startParameterName()

void HtmlGenerator::startParameterName ( bool )
overridevirtual

Implements OutputGenIntf.

Definition at line 2512 of file htmlgen.cpp.

2513{
2514 DBG_HTML(m_t << "<!-- startParameterName -->\n";)
2515 m_t << " <td class=\"paramname\"><span class=\"paramname\"><em>";
2516}

References DBG_HTML, and OutputGenerator::m_t.

◆ startParameterType()

void HtmlGenerator::startParameterType ( bool first,
const DString & key )
overridevirtual

Implements OutputGenIntf.

Definition at line 2489 of file htmlgen.cpp.

2490{
2491 if (first)
2492 {
2493 DBG_HTML(m_t << "<!-- startFirstParameterType -->\n";)
2494 m_t << " <td class=\"paramtype\">";
2495 }
2496 else
2497 {
2498 DBG_HTML(m_t << "<!-- startParameterType -->\n";)
2499 m_t << " <tr>\n";
2500 m_t << " <td class=\"paramkey\">" << key << "</td>\n";
2501 m_t << " <td></td>\n";
2502 m_t << " <td class=\"paramtype\">";
2503 }
2504}

References DBG_HTML, and OutputGenerator::m_t.

◆ startPlainFile()

void HtmlGenerator::startPlainFile ( const DString & name)
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 331 of file htmlgen.h.

void startPlainFile(const DString &name)
Definition outputgen.cpp:30

References OutputGenerator::startPlainFile().

Referenced by startFile(), and writeStyleInfo().

◆ startProjectNumber()

void HtmlGenerator::startProjectNumber ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1759 of file htmlgen.cpp.

1760{
1761 m_t << "<h3 class=\"version\">";
1762}

References OutputGenerator::m_t.

◆ startQuickIndices()

void HtmlGenerator::startQuickIndices ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 247 of file htmlgen.h.

247{}

◆ startSection()

void HtmlGenerator::startSection ( const DString & lab,
const DString & ,
SectionType type )
overridevirtual

Implements OutputGenIntf.

Definition at line 2023 of file htmlgen.cpp.

2024{
2025 switch(type.level())
2026 {
2027 case SectionType::Page: m_t << "\n\n<h1 class=\"doxsection\">"; break;
2028 case SectionType::Section: m_t << "\n\n<h2 class=\"doxsection\">"; break;
2029 case SectionType::Subsection: m_t << "\n\n<h3 class=\"doxsection\">"; break;
2030 case SectionType::Subsubsection: m_t << "\n\n<h4 class=\"doxsection\">"; break;
2031 case SectionType::Paragraph: m_t << "\n\n<h5 class=\"doxsection\">"; break;
2032 case SectionType::Subparagraph: m_t << "\n\n<h6 class=\"doxsection\">"; break;
2033 case SectionType::Subsubparagraph: m_t << "\n\n<h6 class=\"doxsection\">"; break;
2034 default: ASSERT(0); break;
2035 }
2036 m_t << "<a id=\"" << lab << "\" name=\"" << lab << "\"></a>";
2037}

References ASSERT, SectionType::level(), OutputGenerator::m_t, SectionType::Page, SectionType::Paragraph, SectionType::Section, SectionType::Subparagraph, SectionType::Subsection, SectionType::Subsubparagraph, SectionType::Subsubsection, and type().

◆ startSmall()

void HtmlGenerator::startSmall ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 233 of file htmlgen.h.

233{ m_t << "<small>\n"; }

References OutputGenerator::m_t.

◆ startTextBlock()

void HtmlGenerator::startTextBlock ( bool )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 284 of file htmlgen.h.

284{ m_t << "<div class=\"textblock\">"; }

References OutputGenerator::m_t.

◆ startTextLink()

void HtmlGenerator::startTextLink ( const DString & file,
const DString & anchor )
overridevirtual

Implements OutputGenIntf.

Definition at line 1969 of file htmlgen.cpp.

1970{
1971 m_t << "<a href=\"";
1972 DString fn = f;
1975 fileName() == Config_getString(HTML_OUTPUT)+"/"+fn,
1976 fn,
1977 anchor);
1978 m_t << "\">";
1979}
DString createHtmlUrl(const DString &relPath, const DString &ref, bool isLocalFile, const DString &targetFileName, const DString &anchor)
Definition util.cpp:4504

References addHtmlExtensionIfMissing(), Config_getString, createHtmlUrl(), OutputGenerator::fileName(), m_relPath, and OutputGenerator::m_t.

◆ startTitle()

void HtmlGenerator::startTitle ( )
inlineprivate

Definition at line 338 of file htmlgen.h.

338{ m_t << "<div class=\"title\">"; }

References OutputGenerator::m_t.

Referenced by startTitleHead().

◆ startTitleHead()

void HtmlGenerator::startTitleHead ( const DString & )
overridevirtual

Implements OutputGenIntf.

Definition at line 3545 of file htmlgen.cpp.

3546{
3547 m_t << " <div class=\"headertitle\">";
3548 startTitle();
3549}
void startTitle()
Definition htmlgen.h:338

References OutputGenerator::m_t, and startTitle().

◆ startTocEntry()

void HtmlGenerator::startTocEntry ( const SectionInfo * si)
overridevirtual

Implements OutputGenIntf.

Definition at line 3806 of file htmlgen.cpp.

3807{
3808 SectionType type = si->type();
3809 if (type.isSection())
3810 {
3811 //printf(" level=%d title=%s maxLevel=%d\n",level,qPrint(si->title()),maxLevel);
3812 int nextLevel = type.level();
3813 if (nextLevel>m_tocState.level)
3814 {
3815 for (int l=m_tocState.level;l<nextLevel;l++)
3816 {
3817 if (l < m_tocState.maxLevel)
3818 {
3819 m_tocState.incIndent(m_t,"<ul>");
3820 char cs[2] = { static_cast<char>('0'+l+1), 0 };
3821 const char *empty = (l!=nextLevel-1) ? " empty" : "";
3822 m_tocState.incIndent(m_t,"<li class=\"level" + DString(cs) + empty + "\">");
3823 }
3824 }
3825 }
3826 else if (nextLevel<m_tocState.level)
3827 {
3828 for (int l=m_tocState.level;l>nextLevel;l--)
3829 {
3830 if (l <= m_tocState.maxLevel) m_tocState.decIndent(m_t,"</li>");
3831 m_tocState.inLi[l] = false;
3832 if (l <= m_tocState.maxLevel) m_tocState.decIndent(m_t,"</ul>");
3833 }
3834 }
3835 if (nextLevel <= m_tocState.maxLevel)
3836 {
3837 if (m_tocState.inLi[nextLevel] || m_tocState.level>nextLevel)
3838 {
3839 m_tocState.decIndent(m_t,"</li>");
3840 char cs[2] = { static_cast<char>('0'+nextLevel), 0 };
3841 m_tocState.incIndent(m_t,"<li class=\"level" + DString(cs) + "\">");
3842 }
3843 DString label = si->label();
3845 m_t << "<a href=\"#"+label+"\">";
3846 }
3847 }
3848}
DString label() const
Definition section.h:69
void writeIndent(TextStream &t)
Definition htmlgen.h:358
void incIndent(TextStream &t, const DString &text)
Definition htmlgen.h:359

References HtmlGenerator::TocState::decIndent(), DString::DString(), HtmlGenerator::TocState::incIndent(), HtmlGenerator::TocState::inLi, SectionType::isSection(), SectionInfo::label(), HtmlGenerator::TocState::level, SectionType::level(), OutputGenerator::m_t, m_tocState, HtmlGenerator::TocState::maxLevel, type(), SectionInfo::type(), and HtmlGenerator::TocState::writeIndent().

◆ startTypewriter()

void HtmlGenerator::startTypewriter ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 161 of file htmlgen.h.

161{ m_t << "<code>"; }

References OutputGenerator::m_t.

◆ type()

OutputType HtmlGenerator::type ( ) const
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 119 of file htmlgen.h.

119{ return OutputType::Html; }

References Html.

Referenced by endMemberItem(), endSection(), endTocEntry(), insertMemberAlignLeft(), startMemberItem(), startSection(), and startTocEntry().

◆ writeAnchor()

void HtmlGenerator::writeAnchor ( const DString & ,
const DString & name )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 209 of file htmlgen.h.

210 { m_t << "<a name=\"" << name <<"\" id=\"" << name << "\"></a>"; }

References OutputGenerator::m_t.

◆ writeChar()

void HtmlGenerator::writeChar ( char c)
overridevirtual

Implements OutputGenIntf.

Definition at line 2096 of file htmlgen.cpp.

2097{
2098 char cs[2];
2099 cs[0]=c;
2100 cs[1]=0;
2101 docify(cs);
2102}

References docify().

◆ writeDoc()

void HtmlGenerator::writeDoc ( const IDocNodeAST * node,
const Definition * ctx,
const MemberDef * ,
int id,
int sectionLevel )
overridevirtual

Implements OutputGenIntf.

Definition at line 2828 of file htmlgen.cpp.

2829{
2830 const DocNodeAST *astImpl = dynamic_cast<const DocNodeAST*>(ast);
2831 if (astImpl && sectionLevel<=m_tocState.maxLevel)
2832 {
2833 m_codeList->setId(id);
2834 HtmlDocVisitor visitor(m_t,*m_codeList,ctx,fileName());
2835 std::visit(visitor,astImpl->root);
2836 }
2837}
DocNodeVariant root
Definition docnode.h:1496

References OutputGenerator::fileName(), m_codeList, OutputGenerator::m_t, m_tocState, HtmlGenerator::TocState::maxLevel, and DocNodeAST::root.

◆ writeExternalSearchPage()

void HtmlGenerator::writeExternalSearchPage ( )
static

Definition at line 3378 of file htmlgen.cpp.

3379{
3380 bool disableIndex = Config_getBool(DISABLE_INDEX);
3381 bool generateTreeView = Config_getBool(GENERATE_TREEVIEW);
3382 bool fullSidebar = Config_getBool(FULL_SIDEBAR);
3383 bool quickLinksAfterSplitbar = !disableIndex && generateTreeView && fullSidebar;
3384 DString dname = Config_getString(HTML_OUTPUT);
3385 DString fileName = dname+"/search"+Doxygen::htmlFileExtension;
3386 std::ofstream f = Portable::openOutputStream(fileName);
3387 if (f.is_open())
3388 {
3389 TextStream t(&f);
3391
3392 t << "<!-- " << theTranslator->trGeneratedBy() << " Doxygen "
3393 << getDoxygenVersion() << " -->\n";
3394 t << "<script type=\"text/javascript\">\n";
3395 t << "let searchBox = new SearchBox(\"searchBox\", \""
3396 << "search/\",'" << Doxygen::htmlFileExtension << "');\n";
3397 t << "</script>\n";
3398
3399 if (!disableIndex && !quickLinksAfterSplitbar)
3400 {
3402 }
3403 if (generateTreeView)
3404 {
3405 t << "</div><!-- top -->\n";
3406 }
3407 t << writeSplitBarAsString("search.php",DString(),DString());
3408 if (quickLinksAfterSplitbar)
3409 {
3411 }
3412
3413 t << "<div class=\"header\">\n";
3414 t << " <div class=\"headertitle\">\n";
3415 t << " <div class=\"title\">" << theTranslator->trSearchResultsTitle() << "</div>\n";
3416 t << " </div>\n";
3417 t << "</div>\n";
3418 t << "<div class=\"contents\">\n";
3419
3420 t << "<div id=\"searchresults\"></div>\n";
3421 t << "</div>\n";
3422
3423 if (generateTreeView)
3424 {
3425 t << "</div><!-- doc-content -->\n";
3426 t << "</div><!-- container -->\n";
3427 }
3428
3429 writePageFooter(t,"Search","","");
3430
3431 }
3432 f.close();
3433
3434 DString scriptName = dname+"/search/search.js";
3435 f = Portable::openOutputStream(scriptName);
3436 if (f.is_open())
3437 {
3438 TextStream t(&f);
3439 t << "const searchResultsText=["
3440 << "\"" << theTranslator->trSearchResults(0) << "\","
3441 << "\"" << theTranslator->trSearchResults(1) << "\","
3442 << "\"" << theTranslator->trSearchResults(2) << "\"];\n";
3443 t << "const serverUrl=\"" << Config_getString(SEARCHENGINE_URL) << "\";\n";
3444 t << "const tagMap = {\n";
3445 bool first=true;
3446 // add search mappings
3447 StringVector extraSearchMappings = Config_getList(EXTRA_SEARCH_MAPPINGS);
3448 for (const auto &ml : extraSearchMappings)
3449 {
3450 DString mapLine(ml);
3451 if (size_t eqPos = mapLine.find('='); eqPos!=DString::npos) // tag command contains a destination
3452 {
3453 DString tagName = mapLine.left(eqPos).stripWhiteSpace();
3454 DString destName = mapLine.mid(eqPos+1).stripWhiteSpace();
3455 if (!tagName.empty())
3456 {
3457 if (!first) t << ",\n";
3458 t << " \"" << tagName << "\": \"" << destName << "\"";
3459 first=false;
3460 }
3461 }
3462 }
3463 if (!first) t << "\n";
3464 t << "};\n\n";
3465 t << ResourceMgr::instance().getAsString("extsearch.js");
3466 t << "\n";
3467 t << "document.addEventListener('DOMContentLoaded',() => {\n";
3468 t << " const query = trim(getURLParameter('query'));\n";
3469 t << " if (query) {\n";
3470 t << " searchFor(query,0,20);\n";
3471 t << " } else {\n";
3472 t << " const results = document.getElementById('searchresults');\n";
3473 t << " results.innerHTML = '<p>" << theTranslator->trSearchResults(0) << "</p>';\n";
3474 t << " }\n";
3475 t << "});\n";
3476 }
3477 else
3478 {
3479 err("Failed to open file '{}' for writing...\n",scriptName);
3480 }
3481}
static constexpr size_t npos
value used to indicate 'not found' or 'to the end of the string', matching std::string::npos
Definition dstring.h:182
static void writePageFooter(TextStream &t, const DString &, const DString &, const DString &)
Definition htmlgen.cpp:1743
static DString writeSplitBarAsString(const DString &name, const DString &relpath, const DString &allMembersFile)
Definition htmlgen.cpp:3209
virtual DString trSearchResults(int numDocuments)=0
virtual DString trSearchResultsTitle()=0
#define Config_getList(name)
Definition config.h:38
std::vector< std::string > StringVector
Definition containers.h:33
static void writeDefaultQuickLinks(TextStream &t, HighlightedItem hli, const DString &file, const DString &relPath, bool extraTabs)
Definition htmlgen.cpp:3050
#define err(fmt,...)
Definition message.h:127

References Config_getBool, Config_getList, Config_getString, DString::DString(), DString::empty(), err, OutputGenerator::fileName(), DString::find(), g_header, g_header_file, ResourceMgr::getAsString(), Doxygen::htmlFileExtension, ResourceMgr::instance(), DString::left(), DString::mid(), DString::npos, Portable::openOutputStream(), Search, DString::stripWhiteSpace(), substituteHtmlKeywords(), theTranslator, Translator::trGeneratedBy(), Translator::trSearchResults(), Translator::trSearchResultsTitle(), writeDefaultQuickLinks(), writePageFooter(), and writeSplitBarAsString().

Referenced by generateOutput(), and ~HtmlGenerator().

◆ writeFooter()

void HtmlGenerator::writeFooter ( const DString & navPath)
overridevirtual

Implements OutputGenIntf.

Definition at line 1749 of file htmlgen.cpp.

1750{
1752}

References m_lastTitle, m_relPath, OutputGenerator::m_t, and writePageFooter().

◆ writeFooterFile()

void HtmlGenerator::writeFooterFile ( TextStream & t)
static

Definition at line 1636 of file htmlgen.cpp.

1637{
1638 t << "<!-- HTML footer for doxygen " << getDoxygenVersion() << "-->\n";
1639 t << ResourceMgr::instance().getAsString("footer.html");
1640}

References ResourceMgr::getAsString(), and ResourceMgr::instance().

Referenced by readConfiguration(), and ~HtmlGenerator().

◆ writeGraphicalHierarchy()

void HtmlGenerator::writeGraphicalHierarchy ( DotGfxHierarchyTable & g)
overridevirtual

Implements OutputGenIntf.

Definition at line 2708 of file htmlgen.cpp.

2709{
2710 g.writeGraph(m_t,dir(),fileName());
2711}
void writeGraph(TextStream &t, const DString &path, const DString &fileName)

References OutputGenerator::dir(), OutputGenerator::fileName(), OutputGenerator::m_t, and DotGfxHierarchyTable::writeGraph().

◆ writeHeaderFile()

void HtmlGenerator::writeHeaderFile ( TextStream & t,
const DString & cssname )
static

Definition at line 1630 of file htmlgen.cpp.

1631{
1632 t << "<!-- HTML header for doxygen " << getDoxygenVersion() << "-->\n";
1633 t << ResourceMgr::instance().getAsString("header.html");
1634}

References ResourceMgr::getAsString(), and ResourceMgr::instance().

Referenced by readConfiguration(), and ~HtmlGenerator().

◆ writeInheritedSectionTitle()

void HtmlGenerator::writeInheritedSectionTitle ( const DString & id,
const DString & ref,
const DString & file,
const DString & anchor,
const DString & title,
const DString & name )
overridevirtual

Implements OutputGenIntf.

Definition at line 3692 of file htmlgen.cpp.

3696{
3697 DBG_HTML(m_t << "<!-- writeInheritedSectionTitle -->\n";)
3698 bool dynamicSections = Config_getBool(HTML_DYNAMIC_SECTIONS);
3699 DString a = anchor;
3700 if (!a.empty()) a.prepend("#");
3701 DString classLink = DString("<a class=\"el\" ");
3702 if (!ref.empty())
3703 {
3704 classLink+= externalLinkTarget();
3705 classLink += " href=\"";
3706 classLink+= externalRef(m_relPath,ref);
3707 }
3708 else
3709 {
3710 classLink += "href=\"";
3711 classLink+=m_relPath;
3712 }
3713 DString fn = file;
3715 classLink=classLink+fn+a;
3716 classLink+=DString("\">")+convertToHtml(name,false)+"</a>";
3717 m_t << "<tr class=\"inherit_header " << id << "\">";
3718 if (dynamicSections)
3719 {
3720 m_t << "<td colspan=\"2\" class=\"dyn-inherit\">";
3721 m_t << "<span class=\"dynarrow\"><span class=\"arrowhead closed\"></span></span>";
3722 }
3723 else
3724 {
3725 m_t << "<td colspan=\"2\">";
3726 }
3727 m_t << theTranslator->trInheritedFrom(convertToHtml(title,false),classLink)
3728 << "</td></tr>\n";
3729}
DString & prepend(const char *s)
Definition dstring.h:519
virtual DString trInheritedFrom(const DString &members, const DString &what)=0

References addHtmlExtensionIfMissing(), Config_getBool, convertToHtml(), DBG_HTML, DString::DString(), DString::empty(), externalLinkTarget(), externalRef(), m_relPath, OutputGenerator::m_t, DString::prepend(), theTranslator, and Translator::trInheritedFrom().

◆ writeLabel()

void HtmlGenerator::writeLabel ( const DString & l,
bool isLast )
overridevirtual

Implements OutputGenIntf.

Definition at line 3646 of file htmlgen.cpp.

3647{
3648 DBG_HTML(m_t << "<!-- writeLabel(" << label << ") -->\n";)
3649
3650 auto convertLabelToClass = [](const std::string &lab) {
3651 DString input = convertUTF8ToLower(lab);
3652 DString result;
3653 size_t l=input.length();
3654 result.reserve(l);
3655
3656 // Create valid class selector, see 10.2 here https://www.w3.org/TR/selectors-3/#w3cselgrammar
3657 // ident [-]?{nmstart}{nmchar}*
3658 // nmstart [_a-z]|{nonascii}
3659 // nonascii [^\0-\177]
3660 // nmchar [_a-z0-9-]|{nonascii}
3661
3662 bool nmstart=false;
3663 for (size_t i=0; i<l; i++)
3664 {
3665 char c = input.at(i);
3666 if (c<0 || (c>='a' && c<='z') || c=='_') // nmstart pattern
3667 {
3668 nmstart=true;
3669 result+=c;
3670 }
3671 else if (nmstart && (c<0 || (c>='a' && c<='z') || (c>='0' && c<='9') || c=='_')) // nmchar pattern
3672 {
3673 result+=c;
3674 }
3675 else if (nmstart && (c==' ' || c=='-')) // show whitespace as -
3676 {
3677 result+='-';
3678 }
3679 }
3680 return result;
3681 };
3682
3683 m_t << "<span class=\"mlabel " << convertLabelToClass(label.stripWhiteSpace().str()) << "\">" << label << "</span>";
3684}
char & at(size_t i)
Returns a reference to the character at index i.
Definition dstring.h:690
void reserve(size_t size)
Reserve space for size bytes without changing the string contents.
Definition dstring.h:221
size_t length() const
Returns the length of the string, not counting the 0-terminator.
Definition dstring.h:155
std::string convertUTF8ToLower(const std::string &input)
Converts the input string into a lower case version, also taking into account non-ASCII characters th...
Definition utf8.cpp:188

References DString::at(), convertUTF8ToLower(), DBG_HTML, DString::length(), OutputGenerator::m_t, DString::reserve(), DString::str(), and DString::stripWhiteSpace().

◆ writeLatexSpacing()

void HtmlGenerator::writeLatexSpacing ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 228 of file htmlgen.h.

228{}

◆ writeLogo()

void HtmlGenerator::writeLogo ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1738 of file htmlgen.cpp.

1739{
1741}
static DString writeLogoAsString(const DString &path)
Definition htmlgen.cpp:1716

References m_relPath, OutputGenerator::m_t, and writeLogoAsString().

◆ writeLogoAsString()

DString HtmlGenerator::writeLogoAsString ( const DString & path)
static

Definition at line 1716 of file htmlgen.cpp.

1717{
1718 DString result;
1719 switch (Config_getEnum(TIMESTAMP))
1720 {
1721 case TIMESTAMP_t::NO:
1722 result = theTranslator->trGeneratedBy();
1723 break;
1724 default:
1725 result = theTranslator->trGeneratedAt("<span class=\"timestamp\"></span>",
1726 convertToHtml(Config_getString(PROJECT_NAME)));
1727 break;
1728 }
1729 result += "&#160;\n<a href=\"https://www.doxygen.org/index.html\">\n"
1730 "<img class=\"footer\" src=\"";
1731 result += path;
1732 result += "doxygen.svg\" width=\"104\" height=\"31\" alt=\"doxygen\"/></a> ";
1733 result += getDoxygenVersion();
1734 result += " ";
1735 return result;
1736}
virtual DString trGeneratedAt(const DString &date, const DString &projName)=0

References Config_getEnum, Config_getString, convertToHtml(), theTranslator, Translator::trGeneratedAt(), and Translator::trGeneratedBy().

Referenced by writeLogo(), writeSearchPage(), and ~HtmlGenerator().

◆ writeNavigationPath()

void HtmlGenerator::writeNavigationPath ( const DString & s)
overridevirtual

Implements OutputGenIntf.

Definition at line 3248 of file htmlgen.cpp.

3249{
3250 m_t << substitute(s,"$relpath^",m_relPath);
3251}

References m_relPath, OutputGenerator::m_t, and substitute().

◆ writeNonBreakableSpace()

void HtmlGenerator::writeNonBreakableSpace ( int n)
overridevirtual

Implements OutputGenIntf.

Definition at line 2758 of file htmlgen.cpp.

2759{
2760 for (int i=0; i<n; i++)
2761 {
2762 m_t << "&#160;";
2763 }
2764}

References OutputGenerator::m_t.

◆ writeObjectLink()

void HtmlGenerator::writeObjectLink ( const DString & ref,
const DString & file,
const DString & anchor,
const DString & name )
overridevirtual

Implements OutputGenIntf.

Definition at line 1945 of file htmlgen.cpp.

1947{
1948 if (!ref.empty())
1949 {
1950 m_t << "<a class=\"elRef\" ";
1952 }
1953 else
1954 {
1955 m_t << "<a class=\"el\" ";
1956 }
1957 m_t << "href=\"";
1958 DString fn = f;
1961 fileName() == Config_getString(HTML_OUTPUT)+"/"+fn,
1962 fn,
1963 anchor);
1964 m_t << "\">";
1965 docify(name);
1966 m_t << "</a>";
1967}

References addHtmlExtensionIfMissing(), Config_getString, createHtmlUrl(), docify(), DString::empty(), externalLinkTarget(), OutputGenerator::fileName(), m_relPath, and OutputGenerator::m_t.

◆ writePageFooter()

void HtmlGenerator::writePageFooter ( TextStream & t,
const DString & lastTitle,
const DString & relPath,
const DString & navPath )
staticprivate

Definition at line 1743 of file htmlgen.cpp.

1745{
1746 t << substituteHtmlKeywords(g_footer_file,g_footer,convertToHtml(lastTitle),relPath,navPath);
1747}

References convertToHtml(), g_footer, g_footer_file, and substituteHtmlKeywords().

Referenced by writeExternalSearchPage(), writeFooter(), and writeSearchPage().

◆ writePageLink()

void HtmlGenerator::writePageLink ( const DString & ,
bool  )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 132 of file htmlgen.h.

132{}

◆ writePageOutline()

void HtmlGenerator::writePageOutline ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 3758 of file htmlgen.cpp.

3759{
3760 m_t << "<div id=\"page-nav\" class=\"page-nav-panel\">\n";
3761 m_t << "<div id=\"page-nav-resize-handle\"></div>\n";
3762 m_t << "<div id=\"page-nav-tree\">\n";
3763 m_t << "<div id=\"page-nav-contents\">\n";
3764 m_t << "</div><!-- page-nav-contents -->\n";
3765 m_t << "</div><!-- page-nav-tree -->\n";
3766 m_t << "</div><!-- page-nav -->\n";
3767}

References OutputGenerator::m_t.

◆ writeQuickLinks()

void HtmlGenerator::writeQuickLinks ( HighlightedItem hli,
const DString & file,
bool extraTabs )
overridevirtual

Implements OutputGenIntf.

Definition at line 3273 of file htmlgen.cpp.

3274{
3275 writeDefaultQuickLinks(m_t,hli,file,m_relPath,extraTabs);
3276}

References m_relPath, OutputGenerator::m_t, and writeDefaultQuickLinks().

◆ writeRuler()

void HtmlGenerator::writeRuler ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 208 of file htmlgen.h.

208{ m_t << "<hr/>"; }

References OutputGenerator::m_t.

◆ writeSearchData()

void HtmlGenerator::writeSearchData ( const DString & dir)
static

Definition at line 1462 of file htmlgen.cpp.

1463{
1464 //bool serverBasedSearch = Config_getBool(SERVER_BASED_SEARCH);
1465 //writeImgData(dname,serverBasedSearch ? search_server_data : search_client_data);
1466 ResourceMgr &mgr = ResourceMgr::instance();
1467
1468 DString searchDirName = dname;
1469 std::ofstream f = Portable::openOutputStream(searchDirName+"/search.css");
1470 if (f.is_open())
1471 {
1472 TextStream t(&f);
1473 DString searchCss;
1474 // the position of the search box depends on a number of settings.
1475 // Insert the right piece of CSS code depending on which options are selected
1476 if (Config_getBool(GENERATE_TREEVIEW) && Config_getBool(FULL_SIDEBAR))
1477 {
1478 searchCss = mgr.getAsString("search_sidebar.css"); // we have a full height side bar
1479 }
1480 else if (Config_getBool(DISABLE_INDEX))
1481 {
1482 if (Config_getBool(HTML_COLORSTYLE)==HTML_COLORSTYLE_t::TOGGLE)
1483 {
1484 searchCss = mgr.getAsString("search_nomenu_toggle.css"); // we have no tabs but do have a darkmode button
1485 }
1486 else
1487 {
1488 searchCss = mgr.getAsString("search_nomenu.css"); // we have no tabs and no darkmode button
1489 }
1490 }
1491 else if (!Config_getBool(HTML_DYNAMIC_MENUS))
1492 {
1493 searchCss = mgr.getAsString("search_fixedtabs.css"); // we have tabs, but they are static
1494 }
1495 else
1496 {
1497 searchCss = mgr.getAsString("search.css"); // default case with a dynamic menu bar
1498 }
1499 // and then add the option independent part of the styling
1500 searchCss += mgr.getAsString("search_common.css");
1501 searchCss = substitute(searchCss,"$doxygenversion",getDoxygenVersion());
1502 t << replaceVariables(searchCss);
1503 Doxygen::indexList->addStyleSheetFile("search/search.css");
1504 }
1505}
void addStyleSheetFile(const DString &name)
Definition indexlist.h:127

References IndexList::addStyleSheetFile(), Config_getBool, ResourceMgr::getAsString(), Doxygen::indexList, ResourceMgr::instance(), Portable::openOutputStream(), replaceVariables(), and substitute().

Referenced by generateOutput(), and ~HtmlGenerator().

◆ writeSearchInfo()

void HtmlGenerator::writeSearchInfo ( )
overridevirtual

Implements OutputGenIntf.

Definition at line 1710 of file htmlgen.cpp.

1711{
1713}
static void writeSearchInfoStatic(TextStream &t, const DString &relPath)
Definition htmlgen.cpp:1683

References m_relPath, OutputGenerator::m_t, and writeSearchInfoStatic().

◆ writeSearchInfoStatic()

void HtmlGenerator::writeSearchInfoStatic ( TextStream & t,
const DString & relPath )
static

Definition at line 1683 of file htmlgen.cpp.

1684{
1685 bool searchEngine = Config_getBool(SEARCHENGINE);
1686 bool serverBasedSearch = Config_getBool(SERVER_BASED_SEARCH);
1687 if (searchEngine && !serverBasedSearch)
1688 {
1689 t << "<!-- window showing the filter options -->\n";
1690 t << "<div id=\"MSearchSelectWindow\">\n";
1691 t << "</div>\n";
1692 t << "\n";
1693 t << "<!-- iframe showing the search results (closed by default) -->\n";
1694 t << "<div id=\"MSearchResultsWindow\">\n";
1695 t << "<div id=\"MSearchResults\">\n";
1696 t << "<div class=\"SRPage\">\n";
1697 t << "<div id=\"SRIndex\">\n";
1698 t << "<div id=\"SRResults\"></div>\n"; // here the results will be inserted
1699 t << "<div class=\"SRStatus\" id=\"Loading\">" << theTranslator->trLoading() << "</div>\n";
1700 t << "<div class=\"SRStatus\" id=\"Searching\">" << theTranslator->trSearching() << "</div>\n";
1701 t << "<div class=\"SRStatus\" id=\"NoMatches\">" << theTranslator->trNoMatches() << "</div>\n";
1702 t << "</div>\n"; // SRIndex
1703 t << "</div>\n"; // SRPage
1704 t << "</div>\n"; // MSearchResults
1705 t << "</div>\n"; // MSearchResultsWindow
1706 t << "\n";
1707 }
1708}
virtual DString trSearching()=0
virtual DString trNoMatches()=0
virtual DString trLoading()=0

References Config_getBool, theTranslator, Translator::trLoading(), Translator::trNoMatches(), and Translator::trSearching().

Referenced by writeSearchInfo(), and ~HtmlGenerator().

◆ writeSearchPage()

void HtmlGenerator::writeSearchPage ( )
static

Definition at line 3279 of file htmlgen.cpp.

3280{
3281 bool disableIndex = Config_getBool(DISABLE_INDEX);
3282 bool generateTreeView = Config_getBool(GENERATE_TREEVIEW);
3283 bool fullSidebar = Config_getBool(FULL_SIDEBAR);
3284 bool quickLinksAfterSplitbar = !disableIndex && generateTreeView && fullSidebar;
3285 DString projectName = Config_getString(PROJECT_NAME);
3286 DString htmlOutput = Config_getString(HTML_OUTPUT);
3287
3288 // OPENSEARCH_PROVIDER {
3289 DString configFileName = htmlOutput+"/search_config.php";
3290 std::ofstream f = Portable::openOutputStream(configFileName);
3291 if (f.is_open())
3292 {
3293 TextStream t(&f);
3294 t << "<?php\n\n";
3295 t << "$config = array(\n";
3296 t << " 'PROJECT_NAME' => \"" << convertToHtml(projectName) << "\",\n";
3297 t << " 'GENERATE_TREEVIEW' => " << (generateTreeView?"true":"false") << ",\n";
3298 t << " 'DISABLE_INDEX' => " << (disableIndex?"true":"false") << ",\n";
3299 t << " 'FULL_SIDEBAR' => " << (fullSidebar?"true":"false") << ",\n";
3300 t << ");\n\n";
3301 t << "$translator = array(\n";
3302 t << " 'search_results_title' => \"" << theTranslator->trSearchResultsTitle() << "\",\n";
3303 t << " 'search_results' => array(\n";
3304 t << " 0 => \"" << theTranslator->trSearchResults(0) << "\",\n";
3305 t << " 1 => \"" << theTranslator->trSearchResults(1) << "\",\n";
3306 t << " 2 => \"" << substitute(theTranslator->trSearchResults(2), "$", "\\$") << "\",\n";
3307 t << " ),\n";
3308 t << " 'search_matches' => \"" << theTranslator->trSearchMatches() << "\",\n";
3309 t << " 'search' => \"" << theTranslator->trSearch() << "\",\n";
3310 t << " 'logo' => \"" << substitute(substitute(writeLogoAsString(""), "\"","\\\""), "\n","\\n") << "\",\n";
3311 t << ");\n\n";
3312 t << "?>\n";
3313 }
3314 f.close();
3315
3316 ResourceMgr::instance().copyResource("search_functions.php",htmlOutput);
3317 ResourceMgr::instance().copyResource("search_opensearch.php",htmlOutput);
3318 // OPENSEARCH_PROVIDER }
3319
3320 DString fileName = htmlOutput+"/search.php";
3322 if (f.is_open())
3323 {
3324 TextStream t(&f);
3326
3327 t << "<!-- " << theTranslator->trGeneratedBy() << " Doxygen "
3328 << getDoxygenVersion() << " -->\n";
3329 t << "<script type=\"text/javascript\">\n";
3330 t << "let searchBox = new SearchBox(\"searchBox\", \""
3331 << "search/\",'" << Doxygen::htmlFileExtension << "');\n";
3332 t << "</script>\n";
3333
3334 if (!disableIndex && !quickLinksAfterSplitbar)
3335 {
3337 }
3338 if (generateTreeView)
3339 {
3340 t << "</div><!-- top -->\n";
3341 }
3342 t << writeSplitBarAsString("search.php",DString(),DString());
3343 if (quickLinksAfterSplitbar)
3344 {
3346 }
3347 t << "<!-- generated -->\n";
3348
3349 t << "<?php\n";
3350 t << "require_once \"search_functions.php\";\n";
3351 t << "main();\n";
3352 t << "?>\n";
3353
3354 // Write empty navigation path, to make footer connect properly
3355 if (generateTreeView)
3356 {
3357 t << "</div><!-- doc-content -->\n";
3358 t << "</div><!-- container -->\n";
3359 }
3360
3361 writePageFooter(t,"Search","","");
3362 }
3363 f.close();
3364
3365 DString scriptName = htmlOutput+"/search/search.js";
3366 f = Portable::openOutputStream(scriptName);
3367 if (f.is_open())
3368 {
3369 TextStream t(&f);
3370 t << ResourceMgr::instance().getAsString("extsearch.js");
3371 }
3372 else
3373 {
3374 err("Failed to open file '{}' for writing...\n",scriptName);
3375 }
3376}
virtual DString trSearchMatches()=0
virtual DString trSearch()=0

References Config_getBool, Config_getString, convertToHtml(), ResourceMgr::copyResource(), DString::DString(), err, OutputGenerator::fileName(), g_header, g_header_file, ResourceMgr::getAsString(), Doxygen::htmlFileExtension, ResourceMgr::instance(), Portable::openOutputStream(), Search, substitute(), substituteHtmlKeywords(), theTranslator, Translator::trGeneratedBy(), Translator::trSearch(), Translator::trSearchMatches(), Translator::trSearchResults(), Translator::trSearchResultsTitle(), writeDefaultQuickLinks(), writeLogoAsString(), writePageFooter(), and writeSplitBarAsString().

Referenced by generateOutput(), and ~HtmlGenerator().

◆ writeSplitBar()

void HtmlGenerator::writeSplitBar ( const DString & name,
const DString & allMembersFile )
overridevirtual

Implements OutputGenIntf.

Definition at line 3243 of file htmlgen.cpp.

3244{
3245 m_t << writeSplitBarAsString(name,m_relPath,allMembersFile);
3246}

References m_relPath, OutputGenerator::m_t, and writeSplitBarAsString().

◆ writeSplitBarAsString()

DString HtmlGenerator::writeSplitBarAsString ( const DString & name,
const DString & relpath,
const DString & allMembersFile )
static

Definition at line 3209 of file htmlgen.cpp.

3210{
3211 bool generateTreeView = Config_getBool(GENERATE_TREEVIEW);
3212 DString result;
3213 // write split bar
3214 if (generateTreeView)
3215 {
3216 DString fn = name;
3218 if (!Config_getBool(FULL_SIDEBAR))
3219 {
3220 result += DString(
3221 "<div id=\"side-nav\" class=\"ui-resizable side-nav-resizable\">\n");
3222 }
3223 result+=
3224 " <div id=\"nav-tree\">\n"
3225 " <div id=\"nav-tree-contents\">\n"
3226 " <div id=\"nav-sync\" class=\"sync\"></div>\n"
3227 " </div>\n"
3228 " </div>\n"
3229 " <div id=\"splitbar\" class=\"ui-resizable-handle\">\n"
3230 " </div>\n"
3231 "</div>\n"
3232 "<script type=\"text/javascript\">\n"
3233 "document.addEventListener('DOMContentLoaded',() => { initNavTree('" + fn + "','" + relpath + "','" + allMembersFile + "'); });\n"
3234 "</script>\n";
3235 if (Config_getBool(DISABLE_INDEX) || !Config_getBool(FULL_SIDEBAR))
3236 {
3237 result+="<div id=\"container\">\n<div id=\"doc-content\">\n";
3238 }
3239 }
3240 return result;
3241}

References addHtmlExtensionIfMissing(), Config_getBool, and DString::DString().

Referenced by writeExternalSearchPage(), writeSearchPage(), writeSplitBar(), and ~HtmlGenerator().

◆ writeStartAnnoItem()

void HtmlGenerator::writeStartAnnoItem ( const DString & type,
const DString & file,
const DString & path,
const DString & name )
overridevirtual

Implements OutputGenIntf.

Definition at line 1933 of file htmlgen.cpp.

1935{
1936 m_t << "<li>";
1937 if (!path.empty()) docify(path);
1938 DString fn = f;
1940 m_t << "<a class=\"el\" href=\"" << fn << "\">";
1941 docify(name);
1942 m_t << "</a> ";
1943}

References addHtmlExtensionIfMissing(), docify(), DString::empty(), and OutputGenerator::m_t.

◆ writeString()

void HtmlGenerator::writeString ( const DString & text)
overridevirtual

Implements OutputGenIntf.

Definition at line 1875 of file htmlgen.cpp.

1876{
1877 m_t << text;
1878}

References OutputGenerator::m_t.

◆ writeStyleInfo()

void HtmlGenerator::writeStyleInfo ( int part)
overridevirtual

Implements OutputGenIntf.

Definition at line 1769 of file htmlgen.cpp.

1770{
1771 //printf("writeStyleInfo(%d)\n",part);
1772 if (part==0)
1773 {
1774 if (Config_getString(HTML_STYLESHEET).empty()) // write default style sheet
1775 {
1776 //printf("write doxygen.css\n");
1777 startPlainFile("doxygen.css");
1779 endPlainFile();
1780 Doxygen::indexList->addStyleSheetFile("doxygen.css");
1781 }
1782 else // write user defined style sheet
1783 {
1784 DString cssName=Config_getString(HTML_STYLESHEET);
1785 if (!cssName.startsWith("http:") && !cssName.startsWith("https:"))
1786 {
1787 FileInfo cssfi(cssName.str());
1788 if (!cssfi.exists() || !cssfi.isFile() || !cssfi.isReadable())
1789 {
1790 err("style sheet {} does not exist or is not readable!\n", Config_getString(HTML_STYLESHEET));
1791 }
1792 else
1793 {
1794 // convert style sheet to string
1795 DString fileStr = fileToString(cssName);
1796 // write the string into the output dir
1797 startPlainFile(cssfi.fileName());
1798 m_t << fileStr;
1799 endPlainFile();
1800 }
1801 Doxygen::indexList->addStyleSheetFile(cssfi.fileName());
1802 }
1803 }
1804 StringVector extraCssFiles = Config_getList(HTML_EXTRA_STYLESHEET);
1805 for (const auto &fileName : extraCssFiles)
1806 {
1807 if (!fileName.empty())
1808 {
1809 FileInfo fi(fileName);
1810 if (fi.exists())
1811 {
1812 Doxygen::indexList->addStyleSheetFile(fi.fileName());
1813 }
1814 }
1815 }
1816
1817 Doxygen::indexList->addStyleSheetFile("navtree.css");
1818
1819 if (Config_getBool(HTML_DYNAMIC_SECTIONS) ||
1820 (Config_getBool(SOURCE_BROWSER) && Config_getBool(SOURCE_TOOLTIPS)))
1821 {
1822 Doxygen::indexList->addStyleSheetFile("dynsections.js");
1823 }
1824 if (Config_getBool(HTML_CODE_FOLDING))
1825 {
1826 Doxygen::indexList->addStyleSheetFile("codefolding.js");
1827 }
1828
1829 if (Config_getEnum(HTML_COLORSTYLE)==HTML_COLORSTYLE_t::TOGGLE)
1830 {
1831 Doxygen::indexList->addStyleSheetFile("darkmode_toggle.js");
1832 }
1833
1834 if (Config_getBool(INTERACTIVE_SVG))
1835 {
1837 }
1838
1839 if (!Config_getBool(DISABLE_INDEX) && Config_getBool(HTML_DYNAMIC_MENUS))
1840 {
1842 Doxygen::indexList->addStyleSheetFile("menudata.js");
1843 }
1844 }
1845}
bool startsWith(const char *s) const
Definition dstring.h:604
static void writeDefaultStyleSheet(TextStream &t)
Definition htmlgen.cpp:1507

References IndexList::addStyleSheetFile(), Config_getBool, Config_getEnum, Config_getList, Config_getString, DString::empty(), endPlainFile(), err, FileInfo::exists(), FileInfo::fileName(), OutputGenerator::fileName(), fileToString(), Doxygen::indexList, FileInfo::isFile(), FileInfo::isReadable(), OutputGenerator::m_t, startPlainFile(), DString::startsWith(), DString::str(), and writeDefaultStyleSheet().

◆ writeStyleSheetFile()

void HtmlGenerator::writeStyleSheetFile ( TextStream & t)
static

Definition at line 1624 of file htmlgen.cpp.

1625{
1628}

References fillColorStyleMaps(), and writeDefaultStyleSheet().

Referenced by readConfiguration(), and ~HtmlGenerator().

◆ writeSummaryLink()

void HtmlGenerator::writeSummaryLink ( const DString & file,
const DString & anchor,
const DString & title,
bool first )
overridevirtual

Implements OutputGenIntf.

Definition at line 3731 of file htmlgen.cpp.

3732{
3733 if (first)
3734 {
3735 m_t << " <div class=\"summary\">\n";
3736 }
3737 else
3738 {
3739 m_t << " &#124;\n";
3740 }
3741 m_t << "<a href=\"";
3742 if (!file.empty())
3743 {
3744 DString fn = file;
3746 m_t << m_relPath << fn;
3747 }
3748 else if (!anchor.empty())
3749 {
3750 m_t << "#";
3751 m_t << anchor;
3752 }
3753 m_t << "\">";
3754 m_t << title;
3755 m_t << "</a>";
3756}

References addHtmlExtensionIfMissing(), DString::empty(), m_relPath, and OutputGenerator::m_t.

◆ writeSynopsis()

void HtmlGenerator::writeSynopsis ( )
inlineoverridevirtual

Implements OutputGenIntf.

Definition at line 242 of file htmlgen.h.

242{}

◆ writeTabData()

void HtmlGenerator::writeTabData ( )
static

Additional initialization after indices have been created.

Definition at line 1446 of file htmlgen.cpp.

1447{
1449 DString dname=Config_getString(HTML_OUTPUT);
1450 ResourceMgr &mgr = ResourceMgr::instance();
1451 mgr.copyResource("doxygen.svg",dname);
1452 Doxygen::indexList->addImageFile("doxygen.svg");
1453 if (Config_getBool(SEARCHENGINE) && Config_getBool(SERVER_BASED_SEARCH))
1454 {
1455 mgr.copyResource("MaterialSymbolsOutlined.min.woff2",dname);
1456 Doxygen::indexList->addImageFile("MaterialSymbolsOutlined.min.woff2");
1457 mgr.copyResource("MaterialSymbolsOutlined_LICENSE.txt",dname);
1458 Doxygen::indexList->addImageFile("MaterialSymbolsOutlined_LICENSE.txt");
1459 }
1460}
void addImageFile(const DString &name)
Definition indexlist.h:124

References IndexList::addImageFile(), IndexList::addStyleSheetFile(), Config_getBool, Config_getString, ResourceMgr::copyResource(), Doxygen::indexList, and ResourceMgr::instance().

Referenced by generateOutput(), and ~HtmlGenerator().

Member Data Documentation

◆ m_codeGen

HtmlCodeGenerator* HtmlGenerator::m_codeGen = nullptr
private

Definition at line 349 of file htmlgen.h.

Referenced by addCodeGen(), HtmlGenerator(), HtmlGenerator(), operator=(), and startFile().

◆ m_codeList

std::unique_ptr<OutputCodeList> HtmlGenerator::m_codeList
private

Definition at line 348 of file htmlgen.h.

Referenced by HtmlGenerator(), HtmlGenerator(), operator=(), and writeDoc().

◆ m_emptySection

◆ m_lastFile

DString HtmlGenerator::m_lastFile
private

Definition at line 344 of file htmlgen.h.

Referenced by HtmlGenerator(), operator=(), and startFile().

◆ m_lastTitle

DString HtmlGenerator::m_lastTitle
private

Definition at line 343 of file htmlgen.h.

Referenced by HtmlGenerator(), operator=(), startFile(), and writeFooter().

◆ m_pageOutlineIndent

int HtmlGenerator::m_pageOutlineIndent = 0
private

Definition at line 350 of file htmlgen.h.

◆ m_relPath

◆ m_sectionCount

◆ m_tocState

TocState HtmlGenerator::m_tocState
private

Definition at line 362 of file htmlgen.h.

Referenced by endLocalToc(), endTocEntry(), startLocalToc(), startTocEntry(), and writeDoc().


The documentation for this class was generated from the following files: