aboutsummaryrefslogtreecommitdiffhomepage
path: root/org/output_xmls.org
diff options
context:
space:
mode:
authorRalph Amissah <ralph.amissah@gmail.com>2018-09-28 17:05:34 -0400
committerRalph Amissah <ralph.amissah@gmail.com>2019-04-10 15:14:15 -0400
commit08a374929fdfd11b2546636a9151518491457f18 (patch)
tree31b97119fcd3d3e37a94cee5becdc841745ba693 /org/output_xmls.org
parentdoc_abstraction provide object with segment it occurs in (diff)
output xmls & sqlite, make doc_matter available
Diffstat (limited to 'org/output_xmls.org')
-rw-r--r--org/output_xmls.org441
1 files changed, 237 insertions, 204 deletions
diff --git a/org/output_xmls.org b/org/output_xmls.org
index 8ebee95..7a4338e 100644
--- a/org/output_xmls.org
+++ b/org/output_xmls.org
@@ -419,11 +419,12 @@ auto tail() {
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto inline_images(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "seg",
+auto inline_images(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "seg",
) {
string _img_pth;
if (_xml_type == "epub") {
@@ -445,14 +446,16 @@ auto inline_images(O)(
#+END_SRC
**** links
+***** scroll, seg, epub
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto inline_links(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "seg",
+auto inline_links(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "seg",
) {
if (obj.has.inline_links) {
if ((_txt.match(rgx.mark_internal_site_lnk))
@@ -496,12 +499,14 @@ auto inline_links(O)(
}
#+END_SRC
-**** notes scroll
+**** notes
+***** scroll
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto inline_notes_scroll(O)(
- const O obj,
+auto inline_notes_scroll(M,O)(
+ M doc_matters,
+ const O obj,
string _txt,
) {
if (obj.has.inline_notes_reg) {
@@ -525,13 +530,14 @@ auto inline_notes_scroll(O)(
}
#+END_SRC
-**** notes seg
+***** seg
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto inline_notes_seg(O)(
- const O obj,
- string _txt,
+auto inline_notes_seg(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
string[] _endnotes;
if (obj.has.inline_notes_reg) {
@@ -570,35 +576,38 @@ auto inline_notes_seg(O)(
}
#+END_SRC
-**** inline markup scroll
+**** inline markup
+***** scroll
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto inline_markup_scroll(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
+auto inline_markup_scroll(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
) {
- _txt = inline_images(obj, _txt, _suffix, "scroll");
- _txt = inline_links(obj, _txt, _suffix, "scroll");
- _txt = inline_notes_scroll(obj, _txt);
+ _txt = inline_images(doc_matters, obj, _txt, _suffix, "scroll");
+ _txt = inline_links(doc_matters, obj, _txt, _suffix, "scroll");
+ _txt = inline_notes_scroll(doc_matters, obj, _txt);
return _txt;
}
#+END_SRC
-**** inline markup seg
+***** seg
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto inline_markup_seg(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "seg",
+auto inline_markup_seg(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "seg",
) {
- _txt = inline_images(obj, _txt, _suffix, _xml_type);
- _txt = inline_links(obj, _txt, _suffix, _xml_type);
- auto t = inline_notes_seg(obj, _txt);
+ _txt = inline_images(doc_matters, obj, _txt, _suffix, _xml_type); // TODO
+ _txt = inline_links(doc_matters, obj, _txt, _suffix, _xml_type); // TODO
+ auto t = inline_notes_seg(doc_matters, obj, _txt);
return t;
}
#+END_SRC
@@ -608,8 +617,9 @@ auto inline_markup_seg(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-string lev4_heading_subtoc(O)(
- const O obj,
+string lev4_heading_subtoc(M,O)(
+ M doc_matters,
+ const O obj,
) {
char[] lev4_subtoc;
lev4_subtoc ~= " <div class=\"nav\">\n";
@@ -640,8 +650,9 @@ string lev4_heading_subtoc(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto nav_pre_next_svg(O)(
- const O obj,
+auto nav_pre_next_svg(M,O)(
+ M doc_matters,
+ const O obj,
) {
string prev, next, toc;
if (obj.tags.segment_anchor_tag == "toc") {
@@ -724,10 +735,11 @@ auto nav_pre_next_svg(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto heading(O)(
- const O obj,
- string _txt,
- string _xml_type = "html",
+auto heading(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _xml_type = "html",
) {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
string _horizontal_rule = "<hr />";
@@ -779,14 +791,15 @@ auto heading(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto heading_scroll(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
+auto heading_scroll(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
) {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
- _txt = inline_markup_scroll(obj, _txt, _suffix);
- string o = heading(obj, _txt);
+ _txt = inline_markup_scroll(doc_matters, obj, _txt, _suffix);
+ string o = heading(doc_matters, obj, _txt);
return o;
}
#+END_SRC
@@ -795,16 +808,17 @@ auto heading_scroll(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto heading_seg(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "html",
+auto heading_seg(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "html"
) {
- auto t = inline_markup_seg(obj, _txt, _suffix, _xml_type);
+ auto t = inline_markup_seg(doc_matters, obj, _txt, _suffix, _xml_type);
_txt = t[0];
string[] _endnotes = t[1];
- string o = heading(obj, _txt, _xml_type);
+ string o = heading(doc_matters, obj, _txt, _xml_type);
auto u = tuple(
o,
_endnotes,
@@ -818,9 +832,10 @@ auto heading_seg(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto para(O)(
- const O obj,
- string _txt,
+auto para(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
_txt = font_face(_txt);
@@ -863,14 +878,15 @@ auto para(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto para_scroll(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
+auto para_scroll(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
) {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
- _txt = inline_markup_scroll(obj, _txt, _suffix);
- string o = para(obj, _txt);
+ _txt = inline_markup_scroll(doc_matters, obj, _txt, _suffix);
+ string o = para(doc_matters, obj, _txt);
return o;
}
#+END_SRC
@@ -879,16 +895,17 @@ auto para_scroll(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto para_seg(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "html",
+auto para_seg(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "html",
) {
- auto t = inline_markup_seg(obj, _txt, _suffix, _xml_type);
+ auto t = inline_markup_seg(doc_matters, obj, _txt, _suffix, _xml_type);
_txt = t[0].to!string;
string[] _endnotes = t[1];
- string o = para(obj, _txt);
+ string o = para(doc_matters, obj, _txt);
auto u = tuple(
o,
_endnotes,
@@ -902,9 +919,10 @@ auto para_seg(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto quote(O)(
- const O obj,
- string _txt,
+auto quote(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
_txt = font_face(_txt);
string o;
@@ -939,14 +957,15 @@ auto quote(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto quote_scroll(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
+auto quote_scroll(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
) {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
- _txt = inline_markup_scroll(obj, _txt, _suffix);
- string o = quote(obj, _txt);
+ _txt = inline_markup_scroll(doc_matters, obj, _txt, _suffix);
+ string o = quote(doc_matters, obj, _txt);
return o;
}
#+END_SRC
@@ -955,16 +974,17 @@ auto quote_scroll(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto quote_seg(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "html",
+auto quote_seg(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "html",
) {
- auto t = inline_markup_seg(obj, _txt, _suffix, _xml_type);
+ auto t = inline_markup_seg(doc_matters, obj, _txt, _suffix, _xml_type);
_txt = t[0].to!string;
string[] _endnotes = t[1];
- string o = quote(obj, _txt);
+ string o = quote(doc_matters, obj, _txt);
auto u = tuple(
o,
_endnotes,
@@ -978,9 +998,10 @@ auto quote_seg(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto group(O)(
- const O obj,
- string _txt,
+auto group(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
_txt = font_face(_txt);
string o;
@@ -1015,15 +1036,16 @@ auto group(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto group_scroll(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "html",
+auto group_scroll(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "html",
) {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
- _txt = inline_markup_scroll(obj, _txt, _suffix);
- string o = group(obj, _txt);
+ _txt = inline_markup_scroll(doc_matters, obj, _txt, _suffix);
+ string o = group(doc_matters, obj, _txt);
return o;
}
#+END_SRC
@@ -1032,16 +1054,17 @@ auto group_scroll(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto group_seg(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "html",
+auto group_seg(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "html",
) {
- auto t = inline_markup_seg(obj, _txt, _suffix, _xml_type);
+ auto t = inline_markup_seg(doc_matters, obj, _txt, _suffix, _xml_type);
_txt = t[0].to!string;
string[] _endnotes = t[1];
- string o = group(obj, _txt);
+ string o = group(doc_matters, obj, _txt);
auto u = tuple(
o,
_endnotes,
@@ -1055,9 +1078,10 @@ auto group_seg(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto block(O)(
- const O obj,
- string _txt,
+auto block(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
_txt = font_face(_txt);
string o;
@@ -1088,15 +1112,16 @@ auto block(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto block_scroll(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "html",
+auto block_scroll(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "html",
) {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
- _txt = inline_markup_scroll(obj, _txt, _suffix);
- string o = block(obj, _txt);
+ _txt = inline_markup_scroll(doc_matters, obj, _txt, _suffix);
+ string o = block(doc_matters, obj, _txt);
return o;
}
#+END_SRC
@@ -1105,16 +1130,17 @@ auto block_scroll(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto block_seg(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "html",
+auto block_seg(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "html",
) {
- auto t = inline_markup_seg(obj, _txt, _suffix, _xml_type);
+ auto t = inline_markup_seg(doc_matters, obj, _txt, _suffix, _xml_type);
_txt = t[0].to!string;
string[] _endnotes = t[1];
- string o = block(obj, _txt);
+ string o = block(doc_matters, obj, _txt);
auto u = tuple(
o,
_endnotes,
@@ -1128,9 +1154,10 @@ auto block_seg(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto verse(O)(
- const O obj,
- string _txt,
+auto verse(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
_txt = font_face(_txt);
string o;
@@ -1161,15 +1188,16 @@ auto verse(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto verse_scroll(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "html",
+auto verse_scroll(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "html",
) {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
- _txt = inline_markup_scroll(obj, _txt, _suffix);
- string o = verse(obj, _txt);
+ _txt = inline_markup_scroll(doc_matters, obj, _txt, _suffix);
+ string o = verse(doc_matters, obj, _txt);
return o;
}
#+END_SRC
@@ -1178,16 +1206,17 @@ auto verse_scroll(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto verse_seg(O)(
- const O obj,
- string _txt,
- string _suffix = ".html",
- string _xml_type = "html",
+auto verse_seg(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
+ string _suffix = ".html",
+ string _xml_type = "html",
) {
- auto t = inline_markup_seg(obj, _txt, _suffix, _xml_type);
+ auto t = inline_markup_seg(doc_matters, obj, _txt, _suffix, _xml_type);
_txt = t[0].to!string;
string[] _endnotes = t[1];
- string o = verse(obj, _txt);
+ string o = verse(doc_matters, obj, _txt);
auto u = tuple(
o,
_endnotes,
@@ -1200,9 +1229,10 @@ auto verse_seg(O)(
#+name: xhtml_format_objects_code
#+BEGIN_SRC d
-auto code(O)(
- const O obj,
- string _txt,
+auto code(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
string o;
if (obj.metainfo.object_number.empty) {
@@ -1241,9 +1271,10 @@ align="left|right|center"
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto tablarize(O)(
- const O obj,
- string _txt,
+auto tablarize(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
string[] _table_rows = (_txt).split(rgx.table_delimiter_row);
string[] _table_cols;
@@ -1280,13 +1311,14 @@ auto tablarize(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto table(O)(
- const O obj,
- string _txt,
+auto table(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
_txt = font_face(_txt);
- auto t = tablarize(obj, _txt);
+ auto t = tablarize(doc_matters, obj, _txt);
_txt = t[0];
string _note = t[1];
string o;
@@ -1315,9 +1347,10 @@ auto table(O)(
#+name: xhtml_format_objects
#+BEGIN_SRC d
-auto endnote(O)(
- const O obj,
- string _txt,
+auto endnote(M,O)(
+ M doc_matters,
+ const O obj,
+ string _txt,
) {
string o;
o = format(q"ΒΆ <p class="%s" indent="h%si%s">
@@ -1352,9 +1385,9 @@ template outputHTML() {
#+name: output_html_scroll
#+BEGIN_SRC d
-void scroll(D,I)(
- const D doc_abstraction,
- I doc_matters,
+void scroll(D,M)(
+ const D doc_abstraction,
+ M doc_matters,
) {
mixin DocReformOutputRgxInit;
auto xhtml_format = outputXHTMLs();
@@ -1374,10 +1407,10 @@ void scroll(D,I)(
case "para":
switch (obj.metainfo.is_a) {
case "heading":
- doc_html ~= delimit ~ xhtml_format.heading_scroll(obj, _txt, suffix);
+ doc_html ~= delimit ~ xhtml_format.heading_scroll(doc_matters, obj, _txt, suffix);
break;
case "toc":
- doc_html ~= xhtml_format.para_scroll(obj, _txt, suffix);
+ doc_html ~= xhtml_format.para_scroll(doc_matters, obj, _txt, suffix);
break;
default:
if ((doc_matters.opt.action.debug_do)) {
@@ -1398,10 +1431,10 @@ void scroll(D,I)(
case "para":
switch (obj.metainfo.is_a) {
case "heading":
- doc_html ~= delimit ~ xhtml_format.heading_scroll(obj, _txt, suffix);
+ doc_html ~= delimit ~ xhtml_format.heading_scroll(doc_matters, obj, _txt, suffix);
break;
case "para":
- doc_html ~= xhtml_format.para_scroll(obj, _txt, suffix);
+ doc_html ~= xhtml_format.para_scroll(doc_matters, obj, _txt, suffix);
break;
default:
if ((doc_matters.opt.action.debug_do)) {
@@ -1413,24 +1446,24 @@ void scroll(D,I)(
case "block":
switch (obj.metainfo.is_a) {
case "quote":
- doc_html ~= xhtml_format.quote_scroll(obj, _txt);
+ doc_html ~= xhtml_format.quote_scroll(doc_matters, obj, _txt);
break;
case "group":
- doc_html ~= xhtml_format.group_scroll(obj, _txt);
+ doc_html ~= xhtml_format.group_scroll(doc_matters, obj, _txt);
break;
case "block":
- doc_html ~= xhtml_format.block_scroll(obj, _txt);
+ doc_html ~= xhtml_format.block_scroll(doc_matters, obj, _txt);
break;
case "poem":
break;
case "verse":
- doc_html ~= xhtml_format.verse_scroll(obj, _txt, suffix);
+ doc_html ~= xhtml_format.verse_scroll(doc_matters, obj, _txt, suffix);
break;
case "code":
- doc_html ~= xhtml_format.code(obj, _txt);
+ doc_html ~= xhtml_format.code(doc_matters, obj, _txt);
break;
case "table":
- doc_html ~= xhtml_format.table(obj, _txt);
+ doc_html ~= xhtml_format.table(doc_matters, obj, _txt);
break;
default:
if ((doc_matters.opt.action.debug_do)) {
@@ -1452,22 +1485,22 @@ void scroll(D,I)(
case "para":
switch (obj.metainfo.is_a) {
case "heading":
- doc_html ~= delimit ~ xhtml_format.heading_scroll(obj, _txt, suffix);
+ doc_html ~= delimit ~ xhtml_format.heading_scroll(doc_matters, obj, _txt, suffix);
break;
case "endnote": assert(part == "endnotes");
- doc_html ~= xhtml_format.para_scroll(obj, _txt, suffix);
+ doc_html ~= xhtml_format.para_scroll(doc_matters, obj, _txt, suffix);
break;
case "glossary": assert(part == "glossary");
- doc_html ~= xhtml_format.para_scroll(obj, _txt, suffix);
+ doc_html ~= xhtml_format.para_scroll(doc_matters, obj, _txt, suffix);
break;
case "bibliography": assert(part == "bibliography");
- doc_html ~= xhtml_format.para_scroll(obj, _txt, suffix);
+ doc_html ~= xhtml_format.para_scroll(doc_matters, obj, _txt, suffix);
break;
case "bookindex": assert(part == "bookindex_scroll");
- doc_html ~= xhtml_format.para_scroll(obj, _txt, suffix);
+ doc_html ~= xhtml_format.para_scroll(doc_matters, obj, _txt, suffix);
break;
case "blurb": assert(part == "blurb");
- doc_html ~= xhtml_format.para_scroll(obj, _txt, suffix);
+ doc_html ~= xhtml_format.para_scroll(doc_matters, obj, _txt, suffix);
break;
default:
if ((doc_matters.opt.action.debug_do)) {
@@ -1579,7 +1612,7 @@ void seg(D,M)(
top_level_headings[3] = "";
goto default;
default:
- auto t = xhtml_format.heading_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.heading_seg(doc_matters, obj, _txt, suffix, "seg");
top_level_headings[obj.metainfo.heading_lev_markup] = t[0];
break;
}
@@ -1587,19 +1620,19 @@ void seg(D,M)(
case 4:
segment_filename = obj.tags.segment_anchor_tag;
doc_html[segment_filename] ~= xhtml_format.html_head(doc_matters, "seg");
- auto navigation_bar = xhtml_format.nav_pre_next_svg(obj);
+ auto navigation_bar = xhtml_format.nav_pre_next_svg(doc_matters, obj);
doc_html[segment_filename] ~= navigation_bar.toc_pre_next;
previous_seg_filename = segment_filename;
foreach (top_level_heading; top_level_headings) {
doc_html[segment_filename] ~= top_level_heading;
}
- auto t = xhtml_format.heading_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.heading_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
- doc_html[segment_filename] ~= xhtml_format.lev4_heading_subtoc(obj);
+ doc_html[segment_filename] ~= xhtml_format.lev4_heading_subtoc(doc_matters, obj);
doc_html_endnotes[segment_filename] ~= t[1];
break;
case 5: .. case 7:
- auto t = xhtml_format.heading_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.heading_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
doc_html_endnotes[segment_filename] ~= t[1];
break;
@@ -1623,7 +1656,7 @@ void seg(D,M)(
case "para":
switch (obj.metainfo.is_a) {
case "toc":
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
break;
default:
@@ -1645,7 +1678,7 @@ void seg(D,M)(
case "para":
switch (obj.metainfo.is_a) {
case "para":
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
doc_html_endnotes[segment_filename] ~= t[1];
break;
@@ -1659,32 +1692,32 @@ void seg(D,M)(
case "block":
switch (obj.metainfo.is_a) {
case "quote":
- auto t = xhtml_format.quote_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.quote_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
doc_html_endnotes[segment_filename] ~= t[1];
break;
case "group":
- auto t = xhtml_format.group_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.group_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
doc_html_endnotes[segment_filename] ~= t[1];
break;
case "block":
- auto t = xhtml_format.block_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.block_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
doc_html_endnotes[segment_filename] ~= t[1];
break;
case "poem":
break;
case "verse":
- auto t = xhtml_format.verse_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.verse_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
doc_html_endnotes[segment_filename] ~= t[1];
break;
case "code":
- doc_html[segment_filename] ~= xhtml_format.code(obj, _txt);
+ doc_html[segment_filename] ~= xhtml_format.code(doc_matters, obj, _txt);
break;
case "table":
- doc_html[segment_filename] ~= xhtml_format.table(obj, _txt);
+ doc_html[segment_filename] ~= xhtml_format.table(doc_matters, obj, _txt);
doc_html_endnotes[segment_filename] ~= "";
break;
default:
@@ -1707,26 +1740,26 @@ void seg(D,M)(
case "para":
switch (obj.metainfo.is_a) {
case "endnote": assert(part == "endnotes");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0];
break;
case "glossary": assert(part == "glossary");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0];
doc_html_endnotes[segment_filename] ~= t[1];
break;
case "bibliography": assert(part == "bibliography");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0];
doc_html_endnotes[segment_filename] ~= t[1];
break;
case "bookindex": assert(part == "bookindex_seg");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0];
doc_html_endnotes[segment_filename] ~= t[1];
break;
case "blurb": assert(part == "blurb");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0];
doc_html_endnotes[segment_filename] ~= t[1];
break;
@@ -2259,7 +2292,7 @@ void outputEPub3(D,I)(
default:
doc_parts_ ~= obj.tags.segment_anchor_tag;
doc_epub3[obj.tags.segment_anchor_tag] ~= xhtml_format.epub3_seg_head(doc_matters);
- auto t = xhtml_format.heading_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.heading_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[obj.tags.segment_anchor_tag] ~= t[0];
doc_epub3_endnotes[obj.tags.segment_anchor_tag] ~= t[1];
break;
@@ -2268,12 +2301,12 @@ void outputEPub3(D,I)(
case 4:
segment_filename = obj.tags.segment_anchor_tag;
doc_epub3[segment_filename] ~= xhtml_format.epub3_seg_head(doc_matters);
- auto t = xhtml_format.heading_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.heading_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case 5: .. case 7:
- auto t = xhtml_format.heading_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.heading_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
@@ -2297,7 +2330,7 @@ void outputEPub3(D,I)(
case "para":
switch (obj.metainfo.is_a) {
case "toc":
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
@@ -2320,7 +2353,7 @@ void outputEPub3(D,I)(
case "para":
switch (obj.metainfo.is_a) {
case "para":
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
@@ -2334,32 +2367,32 @@ void outputEPub3(D,I)(
case "block":
switch (obj.metainfo.is_a) {
case "quote":
- auto t = xhtml_format.quote_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.quote_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0].to!string;
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "group":
- auto t = xhtml_format.group_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.group_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0].to!string;
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "block":
- auto t = xhtml_format.block_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.block_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0].to!string;
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "poem":
break;
case "verse":
- auto t = xhtml_format.verse_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.verse_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0].to!string;
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "code":
- doc_epub3[segment_filename] ~= xhtml_format.code(obj, _txt);
+ doc_epub3[segment_filename] ~= xhtml_format.code(doc_matters, obj, _txt);
break;
case "table":
- doc_epub3[segment_filename] ~= xhtml_format.table(obj, _txt);
+ doc_epub3[segment_filename] ~= xhtml_format.table(doc_matters, obj, _txt);
doc_epub3_endnotes[segment_filename] ~= "";
break;
default:
@@ -2382,26 +2415,26 @@ void outputEPub3(D,I)(
case "para":
switch (obj.metainfo.is_a) {
case "endnote": assert(part == "endnotes");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
break;
case "glossary": assert(part == "glossary");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "bibliography": assert(part == "bibliography");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "bookindex": assert(part == "bookindex_seg");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "blurb": assert(part == "blurb");
- auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
+ auto t = xhtml_format.para_seg(doc_matters, obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;