aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorRalph Amissah <ralph.amissah@gmail.com>2020-04-23 17:50:36 -0400
committerRalph Amissah <ralph.amissah@gmail.com>2020-05-20 11:27:26 -0400
commit24ec5a15463df0be6e740c6102d69dabf2fec7e2 (patch)
treeb1580c39594aec0b4c7d174128294da1e7dc0cb1
parentbackmatter, special sections, multiple fixes (diff)
backmatter, special sections, heading ocn fix
- special section heading object numbering: - level B title numbered - level 1 title not numbered
-rw-r--r--org/metaverse.org54
-rw-r--r--src/doc_reform/meta/metadoc_from_src.d54
2 files changed, 64 insertions, 44 deletions
diff --git a/org/metaverse.org b/org/metaverse.org
index 290ba97..c822210 100644
--- a/org/metaverse.org
+++ b/org/metaverse.org
@@ -805,7 +805,7 @@ if there is a glossary section you need to:
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_glossary";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -944,7 +944,7 @@ if there is a blurb section you need to:
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_blurb";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -1633,7 +1633,7 @@ if (biblio_ordered.length > 0) {
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_bibliography";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -2580,9 +2580,11 @@ if (the_endnotes_section.length > 1) {
debug(dom) {
writeln(obj.text);
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
if (obj.metainfo.heading_lev_markup == 4) {
@@ -2619,9 +2621,11 @@ if (the_glossary_section.length > 1) {
debug(dom) {
writeln(obj.text);
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
if (obj.metainfo.heading_lev_markup == 4) {
@@ -2662,9 +2666,11 @@ if (the_bibliography_section.length > 1) {
debug(dom) {
writeln(obj.text);
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
if (obj.metainfo.heading_lev_markup == 4) {
@@ -2712,9 +2718,11 @@ if (the_bookindex_section.length > 1) { /
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
if (obj.metainfo.heading_lev_markup == 4) {
obj.tags.segname_prev = segnames["html"][obj.ptr.html_segnames - 1];
@@ -2758,9 +2766,11 @@ if (the_blurb_section.length > 1) {
debug(dom) {
writeln(obj.text);
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
if (obj.metainfo.heading_lev_markup == 4) {
@@ -6644,7 +6654,7 @@ struct BookIndexReportSection {
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_book_index";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -6914,7 +6924,7 @@ struct NotesSection {
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_endnotes";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -6982,8 +6992,8 @@ struct NotesSection {
comp_obj_endnote_.metainfo.ocn = 0;
comp_obj_endnote_.metainfo.identifier = "";
// comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true; // check
- comp_obj_heading_.metainfo.object_number_type = 0; // check
+ comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_endnote_.attrib.indent_hang = 0;
comp_obj_endnote_.attrib.indent_base = 0;
comp_obj_endnote_.attrib.bullet = false;
diff --git a/src/doc_reform/meta/metadoc_from_src.d b/src/doc_reform/meta/metadoc_from_src.d
index a714941..1be5e0a 100644
--- a/src/doc_reform/meta/metadoc_from_src.d
+++ b/src/doc_reform/meta/metadoc_from_src.d
@@ -581,7 +581,7 @@ template docAbstraction() {
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_glossary";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -707,7 +707,7 @@ template docAbstraction() {
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_blurb";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -1254,7 +1254,7 @@ template docAbstraction() {
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_bibliography";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -1977,9 +1977,11 @@ template docAbstraction() {
debug(dom) {
writeln(obj.text);
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
if (obj.metainfo.heading_lev_markup == 4) {
@@ -2008,9 +2010,11 @@ template docAbstraction() {
debug(dom) {
writeln(obj.text);
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
if (obj.metainfo.heading_lev_markup == 4) {
@@ -2043,9 +2047,11 @@ template docAbstraction() {
debug(dom) {
writeln(obj.text);
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
if (obj.metainfo.heading_lev_markup == 4) {
@@ -2085,9 +2091,11 @@ template docAbstraction() {
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
if (obj.metainfo.heading_lev_markup == 4) {
obj.tags.segname_prev = segnames["html"][obj.ptr.html_segnames - 1];
@@ -2125,9 +2133,11 @@ template docAbstraction() {
debug(dom) {
writeln(obj.text);
}
- obj_cite_digits = ocn_emit(OCNstatus.on);
- obj.metainfo.ocn = obj_cite_digits.object_number;
- obj.metainfo.identifier = obj_cite_digits.identifier;
+ if (obj.metainfo.heading_lev_markup == 1) {
+ obj_cite_digits = ocn_emit(OCNstatus.on);
+ obj.metainfo.ocn = obj_cite_digits.object_number;
+ obj.metainfo.identifier = obj_cite_digits.identifier;
+ }
if (obj.metainfo.heading_lev_markup <= 4) {
segnames_0_to_4 ~= obj.tags.segment_anchor_tag_epub;
if (obj.metainfo.heading_lev_markup == 4) {
@@ -5304,7 +5314,7 @@ template docAbstraction() {
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_book_index";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -5545,7 +5555,7 @@ template docAbstraction() {
comp_obj_heading_.metainfo.ocn = 0;
comp_obj_heading_.metainfo.identifier = "";
comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_off = false;
comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_heading_.tags.segment_anchor_tag_epub = "_part_endnotes";
comp_obj_heading_.tags.anchor_tag_html = comp_obj_heading_.tags.segment_anchor_tag_epub;
@@ -5613,8 +5623,8 @@ template docAbstraction() {
comp_obj_endnote_.metainfo.ocn = 0;
comp_obj_endnote_.metainfo.identifier = "";
// comp_obj_heading_.metainfo.dummy_heading = false;
- comp_obj_heading_.metainfo.object_number_off = true; // check
- comp_obj_heading_.metainfo.object_number_type = 0; // check
+ comp_obj_heading_.metainfo.object_number_off = true;
+ comp_obj_heading_.metainfo.object_number_type = 0;
comp_obj_endnote_.attrib.indent_hang = 0;
comp_obj_endnote_.attrib.indent_base = 0;
comp_obj_endnote_.attrib.bullet = false;