49static const std::array<const char *,g_maxLevels>
g_secLabels =
53 "doxysubsubsubsection",
54 "doxysubsubsubsubsection",
55 "doxysubsubsubsubsubsection",
56 "doxysubsubsubsubsubsubsection"
66 if (compactLatex) l++;
97 static const reg::Ex re(R
"((\d+)%)");
98 std::string s = dimension.str();
106 t << percent/100.0 <<
"\\text" << orientationString;
117 t <<
"\n\\begin{DoxyInlineImage}%\n";
123 t <<
"\n\\begin{DoxyImage}%\n";
127 t <<
"\n\\begin{DoxyImageNoCaption}%\n"
132 t <<
"\\includegraphics";
156 t <<
"[height=\\baselineskip,keepaspectratio=true]";
160 t <<
"[width=\\textwidth,height=\\textheight/2,keepaspectratio=true]";
168 t <<
"{" << name <<
"}";
176 t <<
"%\n\\doxyfigcaption{";
180 t <<
"%\n\\doxyfigcaptionnolink{";
196 t <<
"%\n\\end{DoxyInlineImage}\n";
203 t <<
"\\end{DoxyImage}\n";
207 t <<
"\\end{DoxyImageNoCaption}\n";
214 for (
const auto &n : children)
221 const DString &langExt,
int hierarchyLevel)
270 m_t <<
"\\texorpdfstring{$<$}{<}";
281 m_t <<
"\\texorpdfstring{$>$}{>}";
303 if (!emojiName.
empty())
339 m_t <<
"\\hspace{\\textwidth minus \\textwidth}\\mbox{}\\\\ ";
343 m_t <<
"~\\newline\n";
351 m_t <<
"\\DoxyHorRuler{1}\n";
353 m_t <<
"\\DoxyHorRuler{0}\n";
362 if (s.
enable())
m_t <<
"{\\bfseries{";
else m_t <<
"}}";
382 if (s.
enable())
m_t <<
"\\textsubscript{";
else m_t <<
"}";
385 if (s.
enable())
m_t <<
"\\textsuperscript{";
else m_t <<
"}";
388 if (s.
enable())
m_t <<
"\\begin{center}";
else m_t <<
"\\end{center} ";
391 if (s.
enable())
m_t <<
"\n\\footnotesize ";
else m_t <<
"\n\\normalsize ";
399 m_t <<
"\n\\begin{DoxyPre}";
405 m_t <<
"\\end{DoxyPre}\n";
437 m_t <<
"{\\ttfamily ";
444 m_t <<
"\\begin{DoxyCode}{0}";
446 m_t <<
"\\end{DoxyCode}\n";
450 m_t <<
"\\begin{DoxyVerb}";
452 m_t <<
"\\end{DoxyVerb}\n";
472 if (!fileName.empty())
485 "msc {"+s.
text()+
"}",
487 if (!fileName.empty())
501 for (
const auto &baseName: baseNameVector)
508 if (
Config_getBool(MERMAID_RENDER_MODE)!=MERMAID_RENDER_MODE_t::CLIENT_SIDE)
584 m_t <<
"\\begin{DoxyCode}{0}";
586 m_t <<
"\\end{DoxyCode}\n";
590 m_t <<
"\n\\begin{DoxyVerbInclude}\n";
592 m_t <<
"\\end{DoxyVerbInclude}\n";
631 std::unique_ptr<FileDef> fd;
665 const char *p = s.
data();
673 case '\'':
m_t <<
"\\textnormal{\\textquotesingle}";
break;
674 default:
m_t << c;
break;
703 if (!opt.noPar()) txt +=
"[";
705 if (!opt.noPar()) txt +=
"]";
707 m_t <<
"{\\bfseries ";
717 anchor = anchor.
mid(anchorPrefix.
length());
719 txt =
"\\DoxyCite{" + anchor +
"}";
724 else if (opt.isShortAuthor())
726 txt +=
"{shortauthor}";
728 else if (opt.isYear())
732 if (!opt.noPar()) txt +=
"{1}";
739 if (!opt.noPar()) txt +=
"[";
741 if (!opt.noPar()) txt +=
"]";
742 m_t <<
"{\\bfseries ";
759 m_t <<
"\n\\begin{DoxyEnumerate}";
765 m_t <<
"\n\\begin{DoxyItemize}";
770 m_t <<
"\n\\end{DoxyEnumerate}";
774 m_t <<
"\n\\end{DoxyItemize}";
784 m_t <<
"\n\\item[\\DoxyUnchecked] ";
788 m_t <<
"\n\\item[\\DoxyChecked] ";
805 std::get_if<DocParamSect>(p.
parent())
811 m_t <<
"~\\newline\n";
831 m_t <<
"\\begin{DoxySeeAlso}{";
835 m_t <<
"\\begin{DoxyReturn}{";
839 m_t <<
"\\begin{DoxyAuthor}{";
843 m_t <<
"\\begin{DoxyAuthor}{";
847 m_t <<
"\\begin{DoxyVersion}{";
851 m_t <<
"\\begin{DoxySince}{";
855 m_t <<
"\\begin{DoxyDate}{";
859 m_t <<
"\\begin{DoxyNote}{";
863 m_t <<
"\\begin{DoxyWarning}{";
867 m_t <<
"\\begin{DoxyPrecond}{";
871 m_t <<
"\\begin{DoxyPostcond}{";
875 m_t <<
"\\begin{DoxyCopyright}{";
879 m_t <<
"\\begin{DoxyInvariant}{";
883 m_t <<
"\\begin{DoxyRemark}{";
887 m_t <<
"\\begin{DoxyAttention}{";
891 m_t <<
"\\begin{DoxyImportant}{";
895 m_t <<
"\\begin{DoxyParagraph}{";
898 m_t <<
"\\begin{DoxyParagraph}{";
906 std::visit(*
this,*s.
title());
915 m_t <<
"\n\\end{DoxySeeAlso}\n";
918 m_t <<
"\n\\end{DoxyReturn}\n";
921 m_t <<
"\n\\end{DoxyAuthor}\n";
924 m_t <<
"\n\\end{DoxyAuthor}\n";
927 m_t <<
"\n\\end{DoxyVersion}\n";
930 m_t <<
"\n\\end{DoxySince}\n";
933 m_t <<
"\n\\end{DoxyDate}\n";
936 m_t <<
"\n\\end{DoxyNote}\n";
939 m_t <<
"\n\\end{DoxyWarning}\n";
942 m_t <<
"\n\\end{DoxyPrecond}\n";
945 m_t <<
"\n\\end{DoxyPostcond}\n";
948 m_t <<
"\n\\end{DoxyCopyright}\n";
951 m_t <<
"\n\\end{DoxyInvariant}\n";
954 m_t <<
"\n\\end{DoxyRemark}\n";
957 m_t <<
"\n\\end{DoxyAttention}\n";
960 m_t <<
"\n\\end{DoxyImportant}\n";
963 m_t <<
"\n\\end{DoxyParagraph}\n";
966 m_t <<
"\n\\end{DoxyParagraph}\n";
983 m_t <<
"\\begin{DoxyItemize}\n";
986 m_t <<
"\\end{DoxyItemize}\n";
1012 m_t <<
"\\texorpdfstring{";
1017 std::visit(*
this,*s.
title());
1026 std::visit(*
this,*s.
title());
1043 m_t <<
"\n\\begin{DoxyEnumerate}";
1044 for (
const auto &opt : s.
attribs())
1046 if (opt.name==
"type")
1050 m_t << (first ?
"[":
",");
1051 m_t <<
"label=\\arabic*";
1054 else if (opt.value==
"a")
1056 m_t << (first ?
"[":
",");
1057 m_t <<
"label=\\enumalphalphcnt*";
1060 else if (opt.value==
"A")
1062 m_t << (first ?
"[":
",");
1063 m_t <<
"label=\\enumAlphAlphcnt*";
1066 else if (opt.value==
"i")
1068 m_t << (first ?
"[":
",");
1069 m_t <<
"label=\\roman*";
1072 else if (opt.value==
"I")
1074 m_t << (first ?
"[":
",");
1075 m_t <<
"label=\\Roman*";
1079 else if (opt.name==
"start")
1081 m_t << (first ?
"[":
",");
1083 int val = opt.value.toInt(&ok);
1084 if (ok)
m_t <<
"start=" << val;
1088 if (!first)
m_t <<
"]\n";
1092 m_t <<
"\n\\begin{DoxyItemize}";
1097 m_t <<
"\n\\end{DoxyEnumerate}";
1099 m_t <<
"\n\\end{DoxyItemize}";
1107 for (
const auto &opt : l.
attribs())
1109 if (opt.name==
"value")
1112 int val = opt.value.toInt(&ok);
1130 auto it = std::find_if(attrs.begin(),attrs.end(),
1131 [](
const auto &att) { return att.name==
"class"; });
1132 if (it!=attrs.end() && it->value ==
"reflist")
return true;
1138 bool isNested=
false;
1140 while (n && !isNested)
1142 if (std::get_if<DocHtmlDescList>(n))
1157 m_t <<
"\n\\begin{DoxyRefList}";
1162 m_t <<
"\n\\begin{DoxyDescription}";
1167 m_t <<
"\n\\end{DoxyRefList}";
1171 m_t <<
"\n\\end{DoxyDescription}";
1178 m_t <<
"\n\\item[{\\parbox[t]{\\linewidth}{";
1197 while (n && !isNested)
1209 m_t <<
"\\begin{DoxyTableNested}{" << cols <<
"}";
1213 m_t <<
"\n\\begin{DoxyTable}{" << cols <<
"}";
1221 m_t <<
"\\end{DoxyTableNested}\n";
1225 m_t <<
"\\end{DoxyTable}\n";
1237 if (!c->
file().
empty() && pdfHyperLinks)
1253 std::visit(*
this, *t.
caption());
1294 if (span.rowSpan>0) span.rowSpan--;
1295 if (span.rowSpan<=0)
1299 else if (span.column>col)
1301 col = span.column+span.colSpan;
1305 col = span.column+span.colSpan;
1321 auto appendOpt = [&cellOpts](
const DString &s)
1323 if (!cellOpts.
empty()) cellOpts+=
",";
1326 auto appendSpec = [&cellSpec](
const DString &s)
1328 if (!cellSpec.
empty()) cellSpec+=
",";
1331 auto writeCell = [
this,&cellOpts,&cellSpec]()
1336 if (!cellOpts.
empty())
1338 m_t <<
"[" << cellOpts <<
"]";
1340 m_t <<
"{" << cellSpec <<
"}";
1345 for (
const auto &span :
rowSpans())
1354 for (
size_t i=0;i<span.colSpan;i++)
1380 appendOpt(
"r="+
DString().setNum(rs));
1390 appendOpt(
"c="+
DString().setNum(cs));
1394 appendSpec(
"bg=\\tableheadbgcolor");
1395 appendSpec(
"font=\\bfseries");
1413 for (
int i=0;i<cs-1;i++)
1436 m_t <<
"{\\texttt{";
1444 m_t <<
"{\\bfseries{";
1456 std::visit(*
this,*summary);
1457 m_t <<
"\\begin{adjustwidth}{1em}{0em}\n";
1462 m_t <<
"\\end{adjustwidth}\n";
1501 bool exists =
false;
1509 if (!fileName.empty())
1521 bool exists =
false;
1529 if (!fileName.empty())
1541 bool exists =
false;
1549 if (!fileName.empty())
1570 if (
Config_getBool(MERMAID_RENDER_MODE)==MERMAID_RENDER_MODE_t::CLIENT_SIDE)
return;
1616 m_t <<
"\\item \\contentsline{section}{";
1647 m_t <<
"\\footnotesize\n";
1648 m_t <<
"\\begin{multicols}{2}\n";
1649 m_t <<
"\\begin{DoxyCompactList}\n";
1653 m_t <<
"\\end{DoxyCompactList}\n";
1654 m_t <<
"\\end{multicols}\n";
1655 m_t <<
"\\normalsize\n";
1667 m_t <<
"\n\\begin{DoxyParams}";
1668 if (hasInOutSpecs && hasTypeSpecs)
m_t <<
"[2]";
1669 else if (hasInOutSpecs || hasTypeSpecs)
m_t <<
"[1]";
1674 m_t <<
"\n\\begin{DoxyRetVals}{";
1678 m_t <<
"\n\\begin{DoxyExceptions}{";
1682 m_t <<
"\n\\begin{DoxyTemplParams}{";
1695 m_t <<
"\\end{DoxyParams}\n";
1698 m_t <<
"\\end{DoxyRetVals}\n";
1701 m_t <<
"\\end{DoxyExceptions}\n";
1704 m_t <<
"\\end{DoxyTemplParams}\n";
1724 parentType = sect->
type();
1738 m_t <<
"\\doxymbox{\\texttt{";
1753 if (useTable)
m_t <<
" & ";
1759 std::visit(*
this,type);
1761 if (useTable)
m_t <<
" & ";
1767 if (!first)
m_t <<
",";
else first=
false;
1769 std::visit(*
this,param);
1783 std::visit(*
this,par);
1798 m_t <<
"\\begin{DoxyRefDesc}{";
1801 bool anonymousEnum = x.
file()==
"@";
1803 if (pdfHyperlinks && !anonymousEnum)
1809 m_t <<
"\\textbf{ ";
1814 if (pdfHyperlinks && !anonymousEnum)
1822 m_t <<
"\\end{DoxyRefDesc}\n";
1842 m_t <<
"\\begin{quote}\n";
1845 m_t <<
"\\end{quote}\n";
1873 bool refToTable,
bool refToSection)
1876 if (ref.
empty() && pdfHyperLinks)
1880 m_t <<
"\\doxytablelink{";
1882 else if (refToSection)
1896 if (!anchor.
empty())
m_t << anchor;
1901 else if (ref.
empty() && refToSection)
1903 m_t <<
"\\doxysectref{";
1905 else if (ref.
empty() && refToTable)
1907 m_t <<
"\\doxytableref{";
1909 else if (ref.
empty())
1911 m_t <<
"\\doxyref{";
1915 m_t <<
"\\textbf{ ";
1923 if (ref.
empty() && !pdfHyperLinks)
1927 m_t <<
"}{" << file;
1928 if (!file.empty() && !anchor.
empty())
m_t <<
"_";
1929 m_t << anchor <<
"}";
1932 m_t <<
"{" << sectionType.
level() <<
"}";
1935 if (ref.
empty() && pdfHyperLinks)
1949 int srcLine,
bool newFile
1970 int srcLine,
bool newFile
2003 int srcLine,
bool newFile
2047 bool useBitmap = inBuf.find(
"@startditaa") != std::string::npos;
2051 DString(),srcFile,srcLine,
false);
2053 for (
const auto &bName: baseNameVector)
2077 if (
Config_getBool(MERMAID_RENDER_MODE)==MERMAID_RENDER_MODE_t::CLIENT_SIDE)
return;
2083 if (shortName.find(
'.')==
DString::npos) shortName +=
"." + imgExt;
2098 if (
Config_getBool(MERMAID_RENDER_MODE)==MERMAID_RENDER_MODE_t::CLIENT_SIDE)
return;
2106 outDir,
DString(),inBuf,imageFormat,
2109 if (shortName.find(
'.')==
DString::npos) shortName +=
"." + imgExt;
2130 err(
"Maximum indent level ({}) exceeded while generating LaTeX output!\n",
maxIndentLevels-1);
static CitationManager & instance()
DString anchorPrefix() const
static CodeFragmentManager & instance()
void parseCodeFragment(OutputCodeList &codeOutList, const DString &fileName, const DString &blockId, const DString &scopeName, bool showLineNumbers, bool trimLeft, bool stripCodeComments)
virtual void parseCode(OutputCodeList &codeOutList, const DString &scopeName, const DString &input, SrcLangExt lang, bool stripCodeComments, const CodeParserOptions &options)=0
Parses a source file or fragment with the goal to produce highlighted and cross-referenced output.
A String class for use with Doxygen wrapping std::string and adding some additional functionality off...
DString mid(size_t index, size_t len=npos) const
bool empty() const
Returns true iff the string is empty (std::string compatible alias for isEmpty()).
static DString integerToRoman(int n, bool upper=true)
static constexpr size_t npos
value used to indicate 'not found' or 'to the end of the string', matching std::string::npos
DString & prepend(const char *s)
size_t find(char c, size_t pos=0) const
int toInt(bool *ok=nullptr, int base=10) const
DString left(size_t len) const
const std::string & str() const
const char * data() const
Returns a pointer to the contents of the string in the form of a 0-terminated C string.
bool endsWith(const char *s) const
size_t length() const
Returns the length of the string, not counting the 0-terminator.
Node representing an anchor.
Node representing an auto List.
Node representing an item of a auto list.
Node representing a citation of some bibliographic reference.
CiteInfoOption option() const
Node representing a dia file.
Node representing a dot file.
Node representing an emoji.
Node representing a Hypertext reference.
Node representing a horizontal ruler.
Node representing an HTML blockquote.
Node representing a HTML table caption.
Node representing a HTML table cell.
Valignment valignment() const
Alignment alignment() const
Node representing a HTML description data.
Node representing a Html description list.
const HtmlAttribList & attribs() const
Node representing a Html description item.
const DocNodeVariant * summary() const
Node representing a Html list.
const HtmlAttribList & attribs() const
Node representing a HTML list item.
const HtmlAttribList & attribs() const
Node representing a HTML table row.
Node representing a HTML table.
size_t numberHeaderRows() const
size_t numColumns() const
const DocNodeVariant * caption() const
Node representing an image.
bool isInlineImage() const
Node representing a include/dontinclude operator block.
bool stripCodeComments() const
DString exampleFile() const
DString includeFileName() const
Node representing an included text block from file.
bool stripCodeComments() const
DString exampleFile() const
DString extension() const
Node representing an entry in the index.
Node representing an internal section of documentation.
Node representing an internal reference to some item.
Node representing a line break.
Node representing a link to some item.
Node representing a word that can be linked to something.
Node representing a mermaid file.
Node representing a msc file.
DocNodeVariant * parent()
Node representing an block of paragraphs.
Node representing a paragraph in the documentation tree.
Node representing a parameter list.
const DocNodeList & parameters() const
const DocNodeList & paramTypes() const
DocParamSect::Direction direction() const
const DocNodeList & paragraphs() const
Node representing a parameter section.
bool hasInOutSpecifier() const
bool hasTypeSpecifier() const
Node representing a uml file.
Node representing a reference to some item.
SectionType sectionType() const
bool refToSection() const
DString targetTitle() const
Root node of documentation tree.
Node representing a reference to a section.
Node representing a list of section references.
Node representing a normal section.
const DocNodeVariant * title() const
Node representing a separator.
Node representing a simple list.
Node representing a simple list item.
const DocNodeVariant * paragraph() const
Node representing a simple section.
const DocNodeVariant * title() const
Node representing a separator between two simple sections of the same type.
Node representing a style change.
Node representing a special symbol.
HtmlEntityMapper::SymType symbol() const
Root node of a text fragment.
Node representing a simple section title.
Node representing a URL (or email address).
Node representing a verbatim, unparsed text fragment.
const DocNodeList & children() const
DString exampleFile() const
Node representing a VHDL flow chart.
void pushHidden(bool hide)
CodeParserInterface & getCodeParser(const DString &langExt)
Node representing some amount of white space.
Node representing a word.
Node representing an item of a cross-referenced list.
const char * name(int index) const
Access routine to the name of the Emoji entity.
static EmojiEntityMapper & instance()
Returns the one and only instance of the Emoji entity mapper.
Minimal replacement for QFileInfo.
std::string fileName() const
std::string dirPath(bool absPath=true) const
Class representing a list of HTML attributes.
const char * latex(SymType symb) const
Access routine to the LaTeX code of the HTML entity.
static HtmlEntityMapper & instance()
Returns the one and only instance of the HTML entity mapper.
Generator for LaTeX code fragments.
int usedTableLevel() const
bool insideTabbing() const
void startPlantUmlFile(const DString &fileName, const DString &width, const DString &height, bool hasCaption, const DString &srcFile, int srcLine)
void startMscFile(const DString &fileName, const DString &width, const DString &height, bool hasCaption, const DString &srcFile, int srcLine, bool newFile=true)
void writePlantUMLFile(const DString &fileName, const DocVerbatim &s)
void setCurrentColumn(size_t col)
static const int maxIndentLevels
void endDotFile(bool hasCaption)
void operator()(const DocWord &)
void startLink(const DString &ref, const DString &file, const DString &anchor, bool refToTable=false, bool refToSection=false)
void visitCaption(const DocNodeList &children)
void startDotFile(const DString &fileName, const DString &width, const DString &height, bool hasCaption, const DString &srcFile, int srcLine, bool newFile=true)
void addRowSpan(ActiveRowSpan &&span)
void setNumCols(size_t num)
void writeStartTableCommand(const DocNodeVariant *n, size_t cols)
void writeEndTableCommand(const DocNodeVariant *n)
size_t currentColumn() const
LatexDocVisitor(TextStream &t, OutputCodeList &ci, LatexCodeGenerator &lcg, const DString &langExt, int hierarchyLevel=0)
void startMermaidFile(const DString &fileName, const DString &width, const DString &height, bool hasCaption, const DString &srcFile, int srcLine)
void endMscFile(bool hasCaption)
bool isTableNested(const DocNodeVariant *n) const
LatexListItemInfo m_listItemInfo[maxIndentLevels]
void writeMscFile(const DString &fileName, const DocVerbatim &s, bool newFile=true)
void endDiaFile(bool hasCaption)
void endMermaidFile(bool hasCaption)
const char * getSectionName(int level) const
void writeMermaidFile(const DString &baseName, const DocVerbatim &s)
void startDiaFile(const DString &fileName, const DString &width, const DString &height, bool hasCaption, const DString &srcFile, int srcLine, bool newFile=true)
void filter(const DString &str, const bool retainNewLine=false, const bool citeEntry=false)
void endLink(const DString &ref, const DString &file, const DString &anchor, bool refToTable=false, bool refToSection=false, SectionType sectionType=SectionType::Anchor)
void endPlantUmlFile(bool hasCaption)
void visitChildren(const T &t)
LatexCodeGenerator & m_lcg
static MermaidManager & instance()
static DString imageExtension(ImageFormat imageFormat)
static ImageFormat convertToImageFormat(OutputFormat outputFormat)
void generateMermaidOutput(const DString &baseName, const DString &outDir, ImageFormat format, bool toIndex)
Register a generated Mermaid image with the index.
DString writeMermaidSource(const DString &outDirArg, const DString &fileName, const DString &content, ImageFormat format, const DString &srcFile, int srcLine)
Write a Mermaid source file and register it for CLI rendering.
Class representing a list of different code generators.
void startCodeFragment(const DString &style)
void endCodeFragment(const DString &style)
void generatePlantUMLOutput(const DString &baseName, const DString &outDir, OutputFormat format, bool toIndex)
Convert a PlantUML file to an image.
StringVector writePlantUMLSource(const DString &outDirArg, const DString &fileName, const DString &content, OutputFormat format, const DString &engine, const DString &srcFile, int srcLine, bool inlineCode)
Write a PlantUML compatible file.
static PlantumlManager & instance()
constexpr int level() const
Text streaming class that buffers data.
virtual DString trExceptions()=0
virtual DString trReturns()=0
virtual DString trParameters()=0
virtual DString trCopyright()=0
virtual DString trWarning()=0
virtual DString trSince()=0
virtual DString trNote()=0
virtual DString trAuthor(bool first_capital, bool singular)=0
virtual DString trReturnValues()=0
virtual DString trVersion()=0
virtual DString trTemplateParameters()=0
virtual DString trImportant()=0
virtual DString trPrecondition()=0
virtual DString trAttention()=0
virtual DString trPageAbbreviation()=0
virtual DString trInvariant()=0
virtual DString trRemarks()=0
virtual DString trDate()=0
virtual DString trSeeAlso()=0
virtual DString trPostcondition()=0
Class representing a regular expression.
Object representing the matching results.
#define Config_getBool(name)
#define Config_getString(name)
void writeDiaGraphFromFile(const DString &inFile, const DString &outDir, const DString &outFile, DiaOutputFormat format, const DString &srcFile, int srcLine, bool toIndex)
constexpr bool holds_one_of_alternatives(const DocNodeVariant &v)
returns true iff v holds one of types passed as template parameters
std::variant< DocWord, DocLinkedWord, DocURL, DocLineBreak, DocHorRuler, DocAnchor, DocCite, DocStyleChange, DocSymbol, DocEmoji, DocWhiteSpace, DocSeparator, DocVerbatim, DocInclude, DocIncOperator, DocFormula, DocIndexEntry, DocAutoList, DocAutoListItem, DocTitle, DocXRefItem, DocImage, DocDotFile, DocMscFile, DocDiaFile, DocVhdlFlow, DocLink, DocRef, DocInternalRef, DocHRef, DocHtmlHeader, DocHtmlDescTitle, DocHtmlDescList, DocSection, DocSecRefItem, DocSecRefList, DocInternal, DocParBlock, DocSimpleList, DocHtmlList, DocSimpleSect, DocSimpleSectSep, DocParamSect, DocPara, DocParamList, DocSimpleListItem, DocHtmlListItem, DocHtmlDescData, DocHtmlCell, DocHtmlCaption, DocHtmlRow, DocHtmlTable, DocHtmlBlockQuote, DocText, DocRoot, DocHtmlDetails, DocHtmlSummary, DocPlantUmlFile, DocMermaidFile > DocNodeVariant
constexpr DocNodeVariant * parent(DocNodeVariant *n)
returns the parent node of a given node n or nullptr if the node has no parent.
void writeDotGraphFromFile(const DString &inFile, const DString &outDir, const DString &outFile, GraphOutputFormat format, const DString &srcFile, int srcLine, bool toIndex)
std::unique_ptr< FileDef > createFileDef(const DString &p, const DString &n, const DString &ref, const DString &dn)
Translator * theTranslator
static const char * g_subparagraphLabel
static const int g_maxLevels
static void visitPreStart(TextStream &t, bool hasCaption, DString name, DString width, DString height, bool inlineImage=false)
static void insertDimension(TextStream &t, DString dimension, const char *orientationString)
static const std::array< const char *, g_maxLevels > g_secLabels
static bool listIsNested(const DocHtmlDescList &dl)
static const char * g_paragraphLabel
static bool classEqualsReflist(const DocHtmlDescList &dl)
static void visitPostEnd(TextStream &t, bool hasCaption, bool inlineImage=false)
@ TEX
called through texorpdf as TeX (first) part
@ PDF
called through texorpdf as PDF (second) part
@ NO
not called through texorpdf
DString latexFilterURL(const DString &s)
void filterLatexString(TextStream &t, const DString &str, bool insideTabbing, bool insidePre, bool insideItem, bool insideTable, bool keepSpaces, const bool retainNewline)
void latexWriteIndexItem(TextStream &m_t, const DString &s1, const DString &s2)
void writeMscGraphFromFile(const DString &inFile, const DString &outDir, const DString &outFile, MscOutputFormat format, const DString &srcFile, int srcLine, bool toIndex)
bool search(std::string_view str, Match &match, const Ex &re, size_t pos)
Search in a given string str starting at position pos for a match against regular expression re.
Portable versions of functions that are platform dependent.
Options to configure the code parser.
CodeParserOptions & setStartLine(int lineNr)
CodeParserOptions & setInlineFragment(bool enable)
CodeParserOptions & setShowLineNumbers(bool enable)
CodeParserOptions & setFileDef(const FileDef *fd)
DString writeInlineGraph(const DString &baseName, const DString &extension, const DString &content, bool &exists)
DString getFileNameExtension(const DString &fn)
bool readInputFile(const DString &fileName, std::string &contents, bool filter, bool isSourceCode)
read a file name fileName and optionally filter and transcode it
SrcLangExt getLanguageFromFileName(const DString &fileName, SrcLangExt defLang)
bool copyFile(const DString &src, const DString &dest)
Copies the contents of file with name src to the newly created file with name dest.
DString makeBaseName(const DString &name, const DString &ext)
DString stripPath(const DString &s)
SrcLangExt getLanguageFromCodeLang(DString &fileName)
Routine to handle the language attribute of the \code command.
A bunch of utility functions.