diff options
author | Ralph Amissah <ralph.amissah@gmail.com> | 2020-04-23 17:50:36 -0400 |
---|---|---|
committer | Ralph Amissah <ralph.amissah@gmail.com> | 2020-05-20 11:27:26 -0400 |
commit | 24ec5a15463df0be6e740c6102d69dabf2fec7e2 (patch) | |
tree | b1580c39594aec0b4c7d174128294da1e7dc0cb1 /src | |
parent | backmatter, 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
Diffstat (limited to 'src')
-rw-r--r-- | src/doc_reform/meta/metadoc_from_src.d | 54 |
1 files changed, 32 insertions, 22 deletions
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; |