19#ifndef PRINTDOCVISITOR_H
20#define PRINTDOCVISITOR_H
79 printf(
"print: non supported emoji found: %s\n",
qPrint(s.
name()));
103 if (s.
enable()) printf(
"<bold>");
else printf(
"</bold>");
106 if (s.
enable()) printf(
"<s>");
else printf(
"</s>");
109 if (s.
enable()) printf(
"<strike>");
else printf(
"</strike>");
112 if (s.
enable()) printf(
"<del>");
else printf(
"</del>");
115 if (s.
enable()) printf(
"<underline>");
else printf(
"</underline>");
118 if (s.
enable()) printf(
"<ins>");
else printf(
"</ins>");
121 if (s.
enable()) printf(
"<italic>");
else printf(
"</italic>");
124 if (s.
enable()) printf(
"<kbd>");
else printf(
"</kbd>");
127 if (s.
enable()) printf(
"<code>");
else printf(
"</code>");
130 if (s.
enable()) printf(
"<sub>");
else printf(
"</sub>");
133 if (s.
enable()) printf(
"<sup>");
else printf(
"</sup>");
136 if (s.
enable()) printf(
"<center>");
else printf(
"</center>");
139 if (s.
enable()) printf(
"<small>");
else printf(
"</small>");
142 if (s.
enable()) printf(
"<cite>");
else printf(
"</cite>");
145 if (s.
enable()) printf(
"<pre>");
else printf(
"</pre>");
148 if (s.
enable()) printf(
"<div>");
else printf(
"</div>");
151 if (s.
enable()) printf(
"<span>");
else printf(
"</span>");
200 printf(
"<include file=\"%s\" type=\"",
qPrint(inc.
file()));
208 printf(
"htmlinclude");
209 if (inc.
isBlock()) printf(
" block=\"yes\"");
225 printf(
"<incoperator pattern=\"%s\" type=\"",
qPrint(op.
pattern()));
243 printf(
"<indexentry>%s</indexentry\n",
qPrint(i.
entry()));
248 printf(
"<simplesectsep/>");
253 printf(
"<cite ref=\"%s\" file=\"%s\" "
254 "anchor=\"%s\" text=\"%s\""
269 for (
const auto &child : t.children())
271 std::visit(*
this, child);
303 printf(
"<li class=\"unchecked\">\n");
307 printf(
"<li class=\"checked\">\n");
336 printf(
"<simplesect type=");
362 std::visit(*
this, *s.
title());
366 printf(
"</simplesect>\n");
374 printf(
"</title>\n");
398 printf(
"<sect%d>\n",s.
level());
401 std::visit(*
this, *s.
title());
405 printf(
"</sect%d>\n",s.
level());
413 for (
const auto &opt : s.
attribs())
415 printf(
" %s=\"%s\"",
qPrint(opt.name),
qPrint(opt.value));
438 for (
const auto &opt : li.
attribs())
440 printf(
" %s=\"%s\"",
qPrint(opt.name),
qPrint(opt.value));
474 printf(
"<table rows=\"%zu\" cols=\"%zu\">\n",
479 std::visit(*
this, *t.
caption());
482 printf(
"</table>\n");
498 printf(
"</t%c>\n",c.
isHeading()?
'h':
'd');
503 printf(
"<caption>\n");
506 printf(
"</caption>\n");
511 printf(
"<internal>\n");
514 printf(
"</internal>\n");
519 printf(
"<a url=\"%s\">\n",
qPrint(href.
url()));
528 for (
const auto &opt : summary.
attribs())
530 printf(
" %s=\"%s\"",
qPrint(opt.name),
qPrint(opt.value));
535 printf(
"</summary>\n");
541 for (
const auto &opt :
details.attribs())
543 printf(
" %s=\"%s\"",
qPrint(opt.name),
qPrint(opt.value));
546 auto summary =
details.summary();
549 std::visit(*
this,*summary);
553 printf(
"</details>\n");
558 printf(
"<h%d>\n",header.
level());
561 printf(
"</h%d>\n",header.
level());
566 printf(
"<image src=\"%s\" type=\"",
qPrint(img.
name()));
578 printf(
"</image>\n");
583 printf(
"<dotfile src=\"%s\">\n",
qPrint(df.
name()));
586 printf(
"</dotfile>\n");
591 printf(
"<mscfile src=\"%s\">\n",
qPrint(df.
name()));
594 printf(
"</mscfile>\n");
599 printf(
"<diafile src=\"%s\">\n",
qPrint(df.
name()));
602 printf(
"</diafile>\n");
607 printf(
"<plantumlfile src=\"%s\">\n",
qPrint(df.
name()));
610 printf(
"</plantumlfile>\n");
615 printf(
"<link ref=\"%s\" file=\"%s\" anchor=\"%s\">\n",
624 printf(
"<ref ref=\"%s\" file=\"%s\" "
625 "anchor=\"%s\" targetTitle=\"%s\""
626 " hasLinkText=\"%s\" refToAnchor=\"%s\" refToSection=\"%s\" refToTable=\"%s\">\n",
638 printf(
"<secrefitem target=\"%s\">\n",
qPrint(ref.
target()));
641 printf(
"</secrefitem>\n");
646 printf(
"<secreflist>\n");
649 printf(
"</secreflist>\n");
654 printf(
"<parameters>");
660 std::visit(*
this,param);
666 printf(
"</parameters>\n");
671 printf(
"<paramsect type=");
683 printf(
"</paramsect>\n");
688 printf(
"<xrefitem file=\"%s\" anchor=\"%s\" title=\"%s\">\n",
692 printf(
"</xrefitem>\n");
700 printf(
"</internalref>\n");
713 printf(
"<blockquote>\n");
716 printf(
"</blockquote>\n");
721 printf(
"<vhdlflow>\n");
724 printf(
"</vhdlflow>\n");
729 printf(
"<parblock>\n");
732 printf(
"</parblock>\n");
740 for (
int i=0;i<
m_indent;i++) printf(
".");
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.
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.
Node representing a HTML description data.
Node representing a Html description list.
Node representing a Html description item.
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.
const HtmlAttribList & attribs() const
Node representing a HTML table.
size_t numColumns() const
const DocNodeVariant * caption() const
Node representing an image.
bool isInlineImage() const
Node representing a include/dontinclude operator block.
Node representing an included text block from file.
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 msc file.
Node representing an block of paragraphs.
Node representing a paragraph in the documentation tree.
Node representing a parameter list.
const DocNodeList & parameters() const
Node representing a parameter section.
Node representing a uml file.
Node representing a reference to some item.
QCString targetTitle() const
bool refToSection() 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.
Node representing a VHDL flow chart.
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.
bool empty() const
checks whether the container is empty
static HtmlEntityMapper & instance()
Returns the one and only instance of the HTML entity mapper.
const char * utf8(SymType symb, bool useInPrintf=FALSE) const
Access routine to the UTF8 code of the HTML entity.
void operator()(const DocSeparator &)
void operator()(const DocWord &w)
void operator()(const DocSimpleSect &s)
void operator()(const DocAnchor &a)
void operator()(const DocSymbol &s)
void operator()(const DocInclude &inc)
void operator()(const DocHRef &href)
void operator()(const DocHtmlCaption &c)
void operator()(const DocLinkedWord &w)
void operator()(const DocVerbatim &s)
void operator()(const DocHtmlBlockQuote &q)
void operator()(const DocParamList &pl)
void operator()(const DocDiaFile &df)
void operator()(const DocStyleChange &s)
void operator()(const DocTitle &t)
void operator()(const DocText &t)
void operator()(const DocIndexEntry &i)
void operator()(const DocSimpleSectSep &)
void operator()(const DocSimpleList &l)
void operator()(const DocInternal &i)
void operator()(const DocLink &lnk)
void visitChildren(const T &t)
void operator()(const DocHtmlHeader &header)
void operator()(const DocParamSect &ps)
void operator()(const DocInternalRef &r)
void operator()(const DocHtmlDescData &dd)
void operator()(const DocVhdlFlow &vf)
void operator()(const DocURL &u)
void operator()(const DocHtmlTable &t)
void operator()(const DocIncOperator &op)
void operator()(const DocPlantUmlFile &df)
void operator()(const DocXRefItem &x)
void operator()(const DocSecRefItem &ref)
void operator()(const DocEmoji &s)
void operator()(const DocMscFile &df)
void operator()(const DocSecRefList &rl)
void operator()(const DocRoot &r)
void operator()(const DocHtmlList &s)
void operator()(const DocHorRuler &)
void operator()(const DocHtmlDescTitle &dt)
void operator()(const DocHtmlSummary &summary)
void operator()(const DocDotFile &df)
void operator()(const DocLineBreak &)
void operator()(const DocAutoListItem &li)
void operator()(const DocSection &s)
void operator()(const DocHtmlCell &c)
void operator()(const DocAutoList &l)
void operator()(const DocPara &p)
void operator()(const DocRef &ref)
void operator()(const DocHtmlDetails &details)
void operator()(const DocImage &img)
void operator()(const DocFormula &f)
void operator()(const DocHtmlDescList &l)
void operator()(const DocHtmlRow &tr)
void operator()(const DocWhiteSpace &w)
void operator()(const DocParBlock &pb)
void operator()(const DocSimpleListItem &li)
void operator()(const DocHtmlListItem &li)
void operator()(const DocCite &cite)
const char * qPrint(const char *s)