aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/doc_reform/io_out/xmls.d
diff options
context:
space:
mode:
authorRalph Amissah <ralph.amissah@gmail.com>2022-02-09 14:18:45 -0500
committerRalph Amissah <ralph.amissah@gmail.com>2022-02-09 14:31:07 -0500
commite9ff8330d44330ed87bb2cce562f132a9a005f3d (patch)
treefbf2ea5031afeb04a8655348fbd8c3eeb4201eab /src/doc_reform/io_out/xmls.d
parentquote block, footnotes, markup? (diff)
xmls, copyright and license display
Diffstat (limited to 'src/doc_reform/io_out/xmls.d')
-rw-r--r--src/doc_reform/io_out/xmls.d108
1 files changed, 74 insertions, 34 deletions
diff --git a/src/doc_reform/io_out/xmls.d b/src/doc_reform/io_out/xmls.d
index fd9305a..871332d 100644
--- a/src/doc_reform/io_out/xmls.d
+++ b/src/doc_reform/io_out/xmls.d
@@ -417,13 +417,36 @@ template outputXHTMLs() {
o = format(q"┃</div>┃");
return o;
}
-@safe string tail() {
+@safe string tail(M)(M doc_matters) {
string o;
- o = format(q"┃
+ o = format(q"┃<hr />
+ <div class="rights">
+ <p class="small" id="copyright"><a name="copyright"></a>
+ <b>Copyright:</b> %s
+ </p>
+ </div>
+ %s
+ <div class="rights">
+ <p class="small" id="rights"><a name="rights"></a>
+ %s
+ </p>
+ </div>
+ <hr />
+ <div class="generator">
+ <p class="small_center" id="sisu_spine"><a name="sisu_spine"></a>
+ <a href="https://sisudoc.org">SiSU Spine</a> (object numbering &amp; search)
+ </p>
+ </div>
<a name="bottom" id="bottom"></a>
<a name="end" id="end"></a>
</body>
-</html>┃");
+</html>
+┃",
+ special_characters_text(doc_matters.conf_make_meta.meta.rights_copyright),
+ ((doc_matters.conf_make_meta.meta.rights_license).empty) ? "" : "<br />",
+ ((doc_matters.conf_make_meta.meta.rights_license).empty) ? ""
+ : "<b>License:</b> " ~ special_characters_text(doc_matters.conf_make_meta.meta.rights_license)
+ );
return o;
}
@safe string inline_images(O,M)(
@@ -798,48 +821,65 @@ template outputXHTMLs() {
┃",
_horizontal_rule,
);
- } else if (!(obj.metainfo.identifier.empty)) {
- o = format(q"┃%s
+ } else {
+ o = "";
+ if (obj.metainfo.is_of_section == "toc") {
+ o ~= format(q"┃
+ <div class="substance">
+ <p class="small" id="copyright"><a name="copyright"></a>
+ Copyright: %s
+ </p>
+ <!-- <p class="small" id="rights"><a name="rights"></a>
+ %s
+ </p> -->
+ </div>┃",
+ special_characters_text(doc_matters.conf_make_meta.meta.rights_copyright),
+ special_characters_text(doc_matters.conf_make_meta.meta.rights_license)
+ );
+ }
+ }
+ if (!(obj.metainfo.identifier.empty)) {
+ o ~= format(q"┃%s
<div class="substance">
<label class="ocn"><a href="#%s" class="lnkocn">%s</a></label>
<h%s class="%s" id="%s"><a name="%s"></a>%s%s
%s
</h%s>
</div>┃",
- _horizontal_rule,
- obj.metainfo.identifier,
- (doc_matters.opt.action.ocn_off)
- ? "" : ((obj.metainfo.object_number.empty)
- ? "" : obj.metainfo.identifier),
- ((_xml_type == "epub" && obj.metainfo.heading_lev_markup == 0) ? 1
- : obj.metainfo.heading_lev_markup),
- obj.metainfo.is_a,
- obj.metainfo.identifier,
- obj.metainfo.identifier,
- tags,
- heading_lev_anchor_tag,
- _txt,
- ((_xml_type == "epub" && obj.metainfo.heading_lev_markup == 0) ? 1
- : obj.metainfo.heading_lev_markup),
- );
- } else {
- o = format(q"┃%s
+ _horizontal_rule,
+ obj.metainfo.identifier,
+ (doc_matters.opt.action.ocn_off)
+ ? "" : ((obj.metainfo.object_number.empty)
+ ? "" : obj.metainfo.identifier),
+ ((_xml_type == "epub" && obj.metainfo.heading_lev_markup == 0) ? 1
+ : obj.metainfo.heading_lev_markup),
+ obj.metainfo.is_a,
+ obj.metainfo.identifier,
+ obj.metainfo.identifier,
+ tags,
+ heading_lev_anchor_tag,
+ _txt,
+ ((_xml_type == "epub" && obj.metainfo.heading_lev_markup == 0) ? 1
+ : obj.metainfo.heading_lev_markup),
+ );
+ } else {
+ o ~= format(q"┃%s
<div class="substance">
<h%s class="%s">%s%s
%s
</h%s>
</div>┃",
- _horizontal_rule,
- ((_xml_type == "epub" && obj.metainfo.heading_lev_markup == 0) ? 1
- : obj.metainfo.heading_lev_markup),
- obj.metainfo.is_a,
- tags,
- heading_lev_anchor_tag,
- _txt,
- ((_xml_type == "epub" && obj.metainfo.heading_lev_markup == 0) ? 1
- : obj.metainfo.heading_lev_markup),
- );
- }
+ _horizontal_rule,
+ ((_xml_type == "epub" && obj.metainfo.heading_lev_markup == 0) ? 1
+ : obj.metainfo.heading_lev_markup),
+ obj.metainfo.is_a,
+ tags,
+ heading_lev_anchor_tag,
+ _txt,
+ ((_xml_type == "epub" && obj.metainfo.heading_lev_markup == 0) ? 1
+ : obj.metainfo.heading_lev_markup),
+ );
+ }
return o;
}
@safe string heading_scroll(O,M)(