From f78907dd0dbcfa12698f85a6cebe77f3f5de46e9 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Wed, 13 Jun 2018 18:19:46 -0400 Subject: object_number, replaces object_cite_number in code --- org/meta_abstraction.org | 432 +++++++++++++++++++++++------------------------ 1 file changed, 216 insertions(+), 216 deletions(-) (limited to 'org/meta_abstraction.org') diff --git a/org/meta_abstraction.org b/org/meta_abstraction.org index b1c08ad..3d6f6b0 100644 --- a/org/meta_abstraction.org +++ b/org/meta_abstraction.org @@ -451,7 +451,7 @@ line_occur = [ "blurb" : 0, ]; auto obj_type_status = flags_type_init; -string[string] obj_cite_number_poem = [ +string[string] object_number_poem = [ "start" : "", "end" : "" ]; @@ -509,9 +509,9 @@ comp_obj_heading_.typeinfo.is_of = "para"; comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Table of Contents"; comp_obj_heading_.node.ocn = 0; -comp_obj_heading_.node.obj_cite_number = ""; -comp_obj_heading_.misc.obj_cite_number_off = ""; -comp_obj_heading_.misc.obj_cite_number_type = 0; +comp_obj_heading_.node.object_number = ""; +comp_obj_heading_.misc.object_number_off = ""; +comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "toc"; comp_obj_heading_.node.marked_up_level = "1"; comp_obj_heading_.node.heading_lev_markup = 4; @@ -601,7 +601,7 @@ debug(srclines) { } #+END_SRC -*** check whether obj_cite_number is on or turned off :ocn: +*** check whether object_number is on or turned off :ocn: #+name: abs_in_loop_body_00 #+BEGIN_SRC d @@ -686,9 +686,9 @@ if there is a glossary section you need to: comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Glossary"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "_part_glossary"; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; @@ -705,9 +705,9 @@ if there is a glossary section you need to: comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Glossary"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "glossary"; comp_obj_heading_.node.marked_up_level = "1"; comp_obj_heading_.node.heading_lev_markup = 4; @@ -727,9 +727,9 @@ if there is a glossary section you need to: comp_obj_para.typeinfo.is_a = "glossary"; comp_obj_para.text = line.to!string.strip; comp_obj_para.node.ocn = 0; - comp_obj_para.node.obj_cite_number = ""; - comp_obj_para.misc.obj_cite_number_off = ""; - comp_obj_para.misc.obj_cite_number_type = 0; + comp_obj_para.node.object_number = ""; + comp_obj_para.misc.object_number_off = ""; + comp_obj_para.misc.object_number_type = 0; comp_obj_para.attrib.indent_hang = indent["hang_position"]; comp_obj_para.attrib.indent_base = indent["base_position"]; comp_obj_para.attrib.bullet = bullet; @@ -810,9 +810,9 @@ if there is a blurb section you need to: comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Blurb"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "_part_blurb"; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; @@ -829,9 +829,9 @@ if there is a blurb section you need to: comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Blurb"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "blurb"; comp_obj_heading_.node.marked_up_level = "1"; comp_obj_heading_.node.heading_lev_markup = 4; @@ -851,9 +851,9 @@ if there is a blurb section you need to: comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = line.to!string; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "blurb"; comp_obj_heading_.node.marked_up_level = an_object["lev"].to!string; comp_obj_heading_.node.heading_lev_markup = an_object["lev_markup_number"].to!int; // make int, remove need to conv @@ -870,9 +870,9 @@ if there is a blurb section you need to: comp_obj_para.typeinfo.is_a = "blurb"; comp_obj_para.text = munge.url_links(line.to!string.strip).replaceFirst(rgx.para_attribs, ""); comp_obj_para.node.ocn = 0; - comp_obj_para.node.obj_cite_number = ""; - comp_obj_para.misc.obj_cite_number_off = ""; - comp_obj_para.misc.obj_cite_number_type = 0; + comp_obj_para.node.object_number = ""; + comp_obj_para.misc.object_number_off = ""; + comp_obj_para.misc.object_number_type = 0; comp_obj_para.attrib.indent_hang = indent["hang_position"]; comp_obj_para.attrib.indent_base = indent["base_position"]; comp_obj_para.has.inline_links = true; @@ -938,7 +938,7 @@ if there is a blurb section you need to: #+BEGIN_SRC d } else if (obj_type_status["poem"] == TriState.on) { /+ within block object: poem +/ - _poem_block_(line, an_object, obj_type_status, cntr, obj_cite_number_poem, conf_make_meta); + _poem_block_(line, an_object, obj_type_status, cntr, object_number_poem, conf_make_meta); continue; #+END_SRC @@ -973,9 +973,9 @@ if (line.matchFirst(rgx.block_poem_open)) { /+ poem to verse exceptions! +/ object_reset(an_object); processing.remove("verse"); - obj_cite_number_poem["start"] = obj_cite_digits.on.to!string; + object_number_poem["start"] = obj_cite_digits.on.to!string; } -_start_block_(line, obj_type_status, obj_cite_number_poem); +_start_block_(line, obj_type_status, object_number_poem); continue; #+END_SRC @@ -1135,7 +1135,7 @@ _block_flag_line_empty_( comp_obj_heading, cntr, obj_type_status, - obj_cite_number_poem, + object_number_poem, conf_make_meta, ); #+END_SRC @@ -1288,10 +1288,10 @@ if ((obj_type_status["heading"] == State.on) comp_obj_para.typeinfo.is_a = "para"; comp_obj_para.text = an_object["substantive"].to!string.strip; comp_obj_para.node.ocn = obj_cite_digits.digit; - comp_obj_para.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_para.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_para.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_para.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_para.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_para.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_para.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_para.misc.object_number_type = obj_cite_digits.type; comp_obj_para.attrib.indent_hang = indent["hang_position"]; comp_obj_para.attrib.indent_base = indent["base_position"]; comp_obj_para.attrib.bullet = bullet; @@ -1413,9 +1413,9 @@ if (an_object["glossary_nugget"].length == 0) { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "(skip) there is no Glossary section"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; comp_obj_heading_.node.heading_lev_collapsed = 1; @@ -1452,9 +1452,9 @@ if (biblio_ordered.length > 0) { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Bibliography"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "_part_bibliography"; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; @@ -1469,9 +1469,9 @@ if (biblio_ordered.length > 0) { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Bibliography"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "bibliography"; comp_obj_heading_.node.marked_up_level = "1"; comp_obj_heading_.node.heading_lev_markup = 4; @@ -1488,9 +1488,9 @@ if (biblio_ordered.length > 0) { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "(skip) there is no Bibliography"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; comp_obj_heading_.node.heading_lev_collapsed = 1; @@ -1527,9 +1527,9 @@ foreach (entry; biblio_ordered) { comp_obj_para.typeinfo.is_a = "bibliography"; comp_obj_para.text = out_.to!string.strip; comp_obj_para.node.ocn = 0; - comp_obj_para.node.obj_cite_number = ""; - comp_obj_para.misc.obj_cite_number_off = ""; - comp_obj_para.misc.obj_cite_number_type = 0; + comp_obj_para.node.object_number = ""; + comp_obj_para.misc.object_number_off = ""; + comp_obj_para.misc.object_number_type = 0; comp_obj_para.attrib.indent_hang = 0; comp_obj_para.attrib.indent_base = 1; comp_obj_para.attrib.bullet = bullet; @@ -1613,9 +1613,9 @@ if (an_object["blurb_nugget"].length == 0) { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "(skip) there is no Blurb section"; comp_obj_heading_.node.ocn = 0; - comp_obj_para.node.obj_cite_number = ""; - comp_obj_para.misc.obj_cite_number_off = ""; - comp_obj_para.misc.obj_cite_number_type = 0; + comp_obj_para.node.object_number = ""; + comp_obj_para.misc.object_number_off = ""; + comp_obj_para.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = ""; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; @@ -1645,9 +1645,9 @@ comp_obj_toc.typeinfo.of_section = "toc"; comp_obj_toc.typeinfo.is_of = "para"; comp_obj_toc.typeinfo.is_a = "toc"; comp_obj_toc.node.ocn = 0; -comp_obj_toc.node.obj_cite_number = ""; -comp_obj_toc.misc.obj_cite_number_off = ""; -comp_obj_toc.misc.obj_cite_number_type = 0; +comp_obj_toc.node.object_number = ""; +comp_obj_toc.misc.object_number_off = ""; +comp_obj_toc.misc.object_number_type = 0; comp_obj_toc.attrib.indent_hang = indent["hang_position"]; comp_obj_toc.attrib.indent_base = indent["base_position"]; comp_obj_toc.attrib.bullet = false; @@ -2002,8 +2002,8 @@ foreach (ref obj; the_document_head_section) { "Title OCN should be 1 not: " ~ obj.node.ocn.to!string); // bug introduced 0.18.1 +/ obj.node.ocn = 1; - obj.node.obj_cite_number = "1"; - obj.misc.obj_cite_number_type = OCNtype.ocn; + obj.node.object_number = "1"; + obj.misc.object_number_type = OCNtype.ocn; } /+ dom structure (marked up & collapsed) +/ if ((opt_action.html) @@ -2145,7 +2145,7 @@ if (the_endnotes_section.length > 1) { } obj_cite_digits = ocn_emit(OCNstatus.on); obj.node.ocn = obj_cite_digits.digit; - obj.node.obj_cite_number = obj_cite_digits.on.to!string; + obj.node.object_number = obj_cite_digits.on.to!string; if (obj.node.heading_lev_markup <= 4) { segnames_0_4 ~= obj.tags.segment_anchor_tag; if (obj.node.heading_lev_markup == 4) { @@ -2189,7 +2189,7 @@ if (the_glossary_section.length > 1) { } obj_cite_digits = ocn_emit(OCNstatus.on); obj.node.ocn = obj_cite_digits.digit; - obj.node.obj_cite_number = obj_cite_digits.on.to!string; + obj.node.object_number = obj_cite_digits.on.to!string; if (obj.node.heading_lev_markup <= 4) { segnames_0_4 ~= obj.tags.segment_anchor_tag; if (obj.node.heading_lev_markup == 4) { @@ -2216,7 +2216,7 @@ if (the_glossary_section.length > 1) { } else if (obj.typeinfo.is_a == "glossary") { obj_cite_digits = ocn_emit(OCNstatus.on); obj.node.ocn = obj_cite_digits.digit; - obj.node.obj_cite_number = obj_cite_digits.on.to!string; + obj.node.object_number = obj_cite_digits.on.to!string; } } } @@ -2237,7 +2237,7 @@ if (the_bibliography_section.length > 1) { } obj_cite_digits = ocn_emit(OCNstatus.on); obj.node.ocn = obj_cite_digits.digit; - obj.node.obj_cite_number = obj_cite_digits.on.to!string; // check + obj.node.object_number = obj_cite_digits.on.to!string; // check if (obj.node.heading_lev_markup <= 4) { segnames_0_4 ~= obj.tags.segment_anchor_tag; if (obj.node.heading_lev_markup == 4) { @@ -2264,7 +2264,7 @@ if (the_bibliography_section.length > 1) { } else if (obj.typeinfo.is_a == "bibliography") { obj_cite_digits = ocn_emit(OCNstatus.on); obj.node.ocn = obj_cite_digits.on; - obj.node.obj_cite_number = obj_cite_digits.on.to!string; + obj.node.object_number = obj_cite_digits.on.to!string; } } } @@ -2290,7 +2290,7 @@ if (the_bookindex_section["scroll"].length > 1) { } obj_cite_digits = ocn_emit(OCNstatus.on); obj.node.ocn = obj_cite_digits.on; - obj.node.obj_cite_number = obj_cite_digits.on.to!string; + obj.node.object_number = obj_cite_digits.on.to!string; if (obj.node.heading_lev_markup <= 4) { segnames_0_4 ~= obj.tags.segment_anchor_tag; if (obj.node.heading_lev_markup == 4) { @@ -2317,8 +2317,8 @@ if (the_bookindex_section["scroll"].length > 1) { } else if (obj.typeinfo.is_a == "bookindex") { obj_cite_digits = ocn_emit(OCNstatus.bkidx); obj.node.ocn = obj_cite_digits.digit; - obj.misc.obj_cite_number_bkidx = obj_cite_digits.bkidx.to!string; - obj.misc.obj_cite_number_type = OCNtype.bkidx; + obj.misc.object_number_bkidx = obj_cite_digits.bkidx.to!string; + obj.misc.object_number_type = OCNtype.bkidx; } } /+ seg +/ @@ -2330,7 +2330,7 @@ if (the_bookindex_section["scroll"].length > 1) { writeln(obj.text); } obj.node.ocn = ++ocn_; - obj.node.obj_cite_number = obj.node.ocn.to!string; + obj.node.object_number = obj.node.ocn.to!string; if (obj.node.heading_lev_markup <= 4) { segnames_0_4 ~= obj.tags.segment_anchor_tag; if (obj.node.heading_lev_markup == 4) { @@ -2356,8 +2356,8 @@ if (the_bookindex_section["scroll"].length > 1) { obj = obj_heading_ancestors(obj, lv_ancestors_txt); } else if (obj.typeinfo.is_a == "bookindex") { ocn_bidx_ = ++ocn_bkidx_; - obj.misc.obj_cite_number_bkidx = ocn_bidx_.to!string; // FIX need to distinguish from regular ocn - obj.misc.obj_cite_number_type = OCNtype.bkidx; + obj.misc.object_number_bkidx = ocn_bidx_.to!string; // FIX need to distinguish from regular ocn + obj.misc.object_number_type = OCNtype.bkidx; } } /+ TODO assert failure, reinstate @@ -2380,7 +2380,7 @@ if (the_blurb_section.length > 1) { } obj_cite_digits = ocn_emit(OCNstatus.on); obj.node.ocn = obj_cite_digits.on; - obj.node.obj_cite_number = obj_cite_digits.on.to!string; + obj.node.object_number = obj_cite_digits.on.to!string; if (obj.node.heading_lev_markup <= 4) { segnames_0_4 ~= obj.tags.segment_anchor_tag; if (obj.node.heading_lev_markup == 4) { @@ -2406,8 +2406,8 @@ if (the_blurb_section.length > 1) { obj = obj_heading_ancestors(obj, lv_ancestors_txt); } else if (obj.typeinfo.is_a == "blurb") { obj_cite_digits = ocn_emit(OCNstatus.off); - obj.misc.obj_cite_number_off = obj_cite_digits.off.to!string; - obj.misc.obj_cite_number_type = OCNtype.non; + obj.misc.object_number_off = obj_cite_digits.off.to!string; + obj.misc.object_number_type = OCNtype.non; } } } @@ -2429,9 +2429,9 @@ comp_obj_heading_.typeinfo.of_section = "empty"; comp_obj_heading_.typeinfo.is_of = "para"; comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.node.ocn = 0; -comp_obj_para.node.obj_cite_number = ""; -comp_obj_para.misc.obj_cite_number_off = ""; -comp_obj_para.misc.obj_cite_number_type = 0; +comp_obj_para.node.object_number = ""; +comp_obj_para.misc.object_number_off = ""; +comp_obj_para.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = ""; comp_obj_heading_.node.marked_up_level = ""; comp_obj_heading_.node.heading_lev_markup = 9; @@ -2606,7 +2606,7 @@ auto _common_reset_(L,O,T)( } #+END_SRC -*** check obj_cite_number status in document :ocn: +*** check object_number status in document :ocn: #+name: abs_functions_ocn_status #+BEGIN_SRC d @@ -2620,16 +2620,16 @@ static auto _check_ocn_status_(L,T)( } static auto rgx = Rgx(); if ((!line.empty) && (obj_type_status["ocn_status_off_for_multiple_objects"] == TriState.off)) { - /+ not multi-line object, check whether obj_cite_number is on or turned off +/ - if (line.matchFirst(rgx.obj_cite_number_block_marks)) { - /+ switch off obj_cite_number +/ - if (line.matchFirst(rgx.obj_cite_number_off_block)) { + /+ not multi-line object, check whether object_number is on or turned off +/ + if (line.matchFirst(rgx.object_number_block_marks)) { + /+ switch off object_number +/ + if (line.matchFirst(rgx.object_number_off_block)) { obj_type_status["ocn_status_off_for_multiple_objects"] = TriState.on; debug(ocnoff) { writeln(line); } } - if (line.matchFirst(rgx.obj_cite_number_off_block_dh)) { + if (line.matchFirst(rgx.object_number_off_block_dh)) { obj_type_status["ocn_status_off_for_multiple_objects"] = TriState.closing; debug(ocnoff) { writeln(line); @@ -2637,9 +2637,9 @@ static auto _check_ocn_status_(L,T)( } } else { if (obj_type_status["ocn_status_off_for_multiple_objects"] == TriState.off) { - if (line.matchFirst(rgx.obj_cite_number_off)) { + if (line.matchFirst(rgx.object_number_off)) { obj_type_status["ocn_status"] = OCNstatus.off; - } else if (line.matchFirst(rgx.obj_cite_number_off_dh)) { + } else if (line.matchFirst(rgx.object_number_off_dh)) { obj_type_status["ocn_status"] = OCNstatus.closing; } else { obj_type_status["ocn_status"] = OCNstatus.on; @@ -2650,7 +2650,7 @@ static auto _check_ocn_status_(L,T)( } } } else if ((!line.empty) && (obj_type_status["ocn_status_off_for_multiple_objects"] > TriState.off)) { - if (line.matchFirst(rgx.obj_cite_number_off_block_close)) { + if (line.matchFirst(rgx.object_number_off_block_close)) { obj_type_status["ocn_status_off_for_multiple_objects"] = TriState.off; obj_type_status["ocn_status"] = OCNstatus.on; debug(ocnoff) { @@ -2730,12 +2730,12 @@ auto _doc_header_and_make_substitutions_fontface_(L,CMM)( void _start_block_(L,T,N)( L line, return ref T obj_type_status, - return ref N obj_cite_number_poem + return ref N object_number_poem ) { debug(asserts) { static assert(is(typeof(line) == char[])); static assert(is(typeof(obj_type_status) == int[string])); - static assert(is(typeof(obj_cite_number_poem) == string[string])); + static assert(is(typeof(object_number_poem) == string[string])); } #+END_SRC @@ -2767,7 +2767,7 @@ void _start_block_(L,T,N)( line ); } - obj_cite_number_poem["start"] = obj_cite_digits.on.to!string; + object_number_poem["start"] = obj_cite_digits.on.to!string; obj_type_status["blocks"] = TriState.on; obj_type_status["verse_new"] = State.on; obj_type_status["poem"] = TriState.on; @@ -2852,7 +2852,7 @@ void _start_block_(L,T,N)( line ); } - obj_cite_number_poem["start"] = obj_cite_digits.on.to!string; + object_number_poem["start"] = obj_cite_digits.on.to!string; obj_type_status["blocks"] = TriState.on; obj_type_status["verse_new"] = State.on; obj_type_status["poem"] = TriState.on; @@ -3349,7 +3349,7 @@ void _poem_block_(L,O,T,C,N,CMM)( return ref O an_object, return ref T obj_type_status, return ref C cntr, - N obj_cite_number_poem, + N object_number_poem, CMM conf_make_meta, ) { debug(asserts) { @@ -3357,7 +3357,7 @@ void _poem_block_(L,O,T,C,N,CMM)( static assert(is(typeof(an_object) == string[string])); static assert(is(typeof(obj_type_status) == int[string])); static assert(is(typeof(cntr) == int)); - static assert(is(typeof(obj_cite_number_poem) == string[string])); + static assert(is(typeof(object_number_poem) == string[string])); } static auto rgx = Rgx(); if (obj_type_status["curly_poem"] == TriState.on) { @@ -3400,10 +3400,10 @@ void _poem_block_(L,O,T,C,N,CMM)( comp_obj_block.typeinfo.is_of = "block"; comp_obj_block.typeinfo.is_a = "verse"; comp_obj_block.node.ocn = obj_cite_digits.on; - comp_obj_block.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_block.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digits.type; comp_obj_block.text = an_object["substantive"]; comp_obj_block.has.inline_notes_reg = substantive_obj_misc_tuple[sObj.notes_reg]; comp_obj_block.has.inline_notes_star = substantive_obj_misc_tuple[sObj.notes_star]; @@ -3414,7 +3414,7 @@ void _poem_block_(L,O,T,C,N,CMM)( processing.remove("verse"); ++cntr; } - obj_cite_number_poem["end"] = obj_cite_digits.on.to!string; + object_number_poem["end"] = obj_cite_digits.on.to!string; obj_type_status["blocks"] = TriState.closing; obj_type_status["poem"] = TriState.closing; obj_type_status["curly_poem"] = TriState.off; @@ -3458,10 +3458,10 @@ void _poem_block_(L,O,T,C,N,CMM)( comp_obj_block.typeinfo.is_of = "block"; comp_obj_block.typeinfo.is_a = "verse"; comp_obj_block.node.ocn = obj_cite_digits.on; - comp_obj_block.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_block.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digits.type; comp_obj_block.text = an_object["substantive"]; comp_obj_block.has.inline_notes_reg = substantive_obj_misc_tuple[sObj.notes_reg]; comp_obj_block.has.inline_notes_star = substantive_obj_misc_tuple[sObj.notes_star]; @@ -3501,16 +3501,16 @@ void _poem_block_(L,O,T,C,N,CMM)( comp_obj_block.typeinfo.is_of = "block"; comp_obj_block.typeinfo.is_a = "verse"; comp_obj_block.node.ocn = obj_cite_digits.on; - comp_obj_block.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_block.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digits.type; comp_obj_block.text = an_object["substantive"]; comp_obj_block.has.inline_notes_reg = substantive_obj_misc_tuple[sObj.notes_reg]; comp_obj_block.has.inline_notes_star = substantive_obj_misc_tuple[sObj.notes_star]; comp_obj_block.has.inline_links = substantive_obj_misc_tuple[sObj.links]; the_document_body_section ~= comp_obj_block; - obj_cite_number_poem["end"] = obj_cite_digits.on.to!string; + object_number_poem["end"] = obj_cite_digits.on.to!string; object_reset(an_object); processing.remove("verse"); ++cntr; @@ -3559,10 +3559,10 @@ void _poem_block_(L,O,T,C,N,CMM)( comp_obj_block.typeinfo.is_of = "block"; comp_obj_block.typeinfo.is_a = "verse"; comp_obj_block.node.ocn = obj_cite_digits.on; - comp_obj_block.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_block.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digits.type; comp_obj_block.text = an_object["substantive"]; comp_obj_block.has.inline_notes_reg = substantive_obj_misc_tuple[sObj.notes_reg]; comp_obj_block.has.inline_notes_star = substantive_obj_misc_tuple[sObj.notes_star]; @@ -3698,10 +3698,10 @@ void _table_closed_make_special_notation_table_(N,CMM)( = obj_im.obj_inline_markup_and_anchor_tags_and_misc(an_object, "body_nugget", conf_make_meta); an_object["substantive"] = substantive_obj_misc_tuple[sObj.content]; comp_obj_block.node.ocn = obj_cite_digits.on; - comp_obj_block.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_block.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digits.type; comp_obj_block = table_instructions(comp_obj_block, an_object["table_head"]); comp_obj_block = table_substantive_munge_special(comp_obj_block, an_object["substantive"]); the_document_body_section ~= comp_obj_block; @@ -3727,7 +3727,7 @@ void _block_flag_line_empty_(B,N,CMM)( return ref ObjGenericComposite _comp_obj_heading, return ref int cntr, return ref int[string] obj_type_status, - string[string] obj_cite_number_poem, + string[string] object_number_poem, CMM conf_make_meta, ) { assert( @@ -3776,10 +3776,10 @@ void _block_flag_line_empty_(B,N,CMM)( comp_obj_block.typeinfo.is_of = "block"; comp_obj_block.typeinfo.is_a = "quote"; comp_obj_block.node.ocn = obj_cite_digits.on; - comp_obj_block.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digit_type; + comp_obj_block.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digit_type; comp_obj_block.text = an_object["substantive"]; comp_obj_block.has.inline_notes_reg = substantive_obj_misc_tuple[sObj.notes_reg]; comp_obj_block.has.inline_notes_star = substantive_obj_misc_tuple[sObj.notes_star]; @@ -3826,10 +3826,10 @@ void _block_flag_line_empty_(B,N,CMM)( comp_obj_block.typeinfo.is_of = "block"; comp_obj_block.typeinfo.is_a = "group"; comp_obj_block.node.ocn = obj_cite_digits.on; - comp_obj_block.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_block.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digits.type; comp_obj_block.text = an_object["substantive"]; comp_obj_block.has.inline_notes_reg = substantive_obj_misc_tuple[sObj.notes_reg]; comp_obj_block.has.inline_notes_star = substantive_obj_misc_tuple[sObj.notes_star]; @@ -3875,10 +3875,10 @@ void _block_flag_line_empty_(B,N,CMM)( comp_obj_block.typeinfo.is_of = "block"; comp_obj_block.typeinfo.is_a = "block"; comp_obj_block.node.ocn = obj_cite_digits.on; - comp_obj_block.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digit_type; + comp_obj_block.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digit_type; comp_obj_block.text = an_object["substantive"]; comp_obj_block.has.inline_notes_reg = substantive_obj_misc_tuple[sObj.notes_reg]; comp_obj_block.has.inline_notes_star = substantive_obj_misc_tuple[sObj.notes_star]; @@ -3920,10 +3920,10 @@ void _block_flag_line_empty_(B,N,CMM)( comp_obj_poem_ocn.typeinfo.is_of = "block"; comp_obj_poem_ocn.typeinfo.is_a = "poem"; comp_obj_poem_ocn.node.ocn = obj_cite_digits.on; - comp_obj_poem_ocn.node.obj_cite_number = (obj_cite_number_poem["start"] ~ "..." ~ obj_cite_number_poem["end"]); - comp_obj_poem_ocn.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; // - comp_obj_poem_ocn.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; // - comp_obj_poem_ocn.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_poem_ocn.node.object_number = (object_number_poem["start"] ~ "..." ~ object_number_poem["end"]); + comp_obj_poem_ocn.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; // + comp_obj_poem_ocn.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; // + comp_obj_poem_ocn.misc.object_number_type = obj_cite_digits.type; comp_obj_poem_ocn.text = ""; the_document_body_section ~= comp_obj_poem_ocn; obj_type_status["blocks"] = TriState.off; @@ -3966,10 +3966,10 @@ void _block_flag_line_empty_(B,N,CMM)( comp_obj_code.typeinfo.is_of = "block"; comp_obj_code.typeinfo.is_a = "code"; comp_obj_code.node.ocn = obj_cite_digits.on; - comp_obj_code.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_code.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digits.type; comp_obj_code.text = an_object["substantive"]; comp_obj_code.has.inline_notes_reg = substantive_obj_misc_tuple[sObj.notes_reg]; comp_obj_code.has.inline_notes_star = substantive_obj_misc_tuple[sObj.notes_star]; @@ -4012,10 +4012,10 @@ void _block_flag_line_empty_(B,N,CMM)( an_object["substantive"] = substantive_obj_misc_tuple[sObj.content]; comp_obj_block = comp_obj_block.init; comp_obj_block.node.ocn = obj_cite_digits.on; - comp_obj_block.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - comp_obj_block.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - comp_obj_block.misc.obj_cite_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; - comp_obj_block.misc.obj_cite_number_type = obj_cite_digits.type; + comp_obj_block.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + comp_obj_block.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + comp_obj_block.misc.object_number_bkidx = (obj_cite_digits.bkidx==0) ? "" : obj_cite_digits.bkidx.to!string; + comp_obj_block.misc.object_number_type = obj_cite_digits.type; comp_obj_block = table_instructions(comp_obj_block, an_object["table_head"]); comp_obj_block = table_substantive_munge(comp_obj_block, an_object["substantive"]); the_document_body_section ~= comp_obj_block; @@ -5075,7 +5075,7 @@ static struct ObjInlineMarkupMunge { body { obj_txt["munge"]=(obj_txt_in) .replaceFirst(rgx.heading, "") - .replaceFirst(rgx.obj_cite_number_off_all, "") + .replaceFirst(rgx.object_number_off_all, "") .strip; auto t = object_notes_and_links_(obj_txt["munge"], reset_note_numbers); debug(munge) { @@ -5109,7 +5109,7 @@ static struct ObjInlineMarkupMunge { body { obj_txt["munge"]=(obj_txt_in) .replaceFirst(rgx.para_attribs, "") - .replaceFirst(rgx.obj_cite_number_off_all, ""); + .replaceFirst(rgx.object_number_off_all, ""); auto t = object_notes_and_links_(obj_txt["munge"]); debug(munge) { writeln(__LINE__); @@ -5446,9 +5446,9 @@ static struct ObjInlineMarkup { comp_obj_toc.typeinfo.is_of = "para"; comp_obj_toc.typeinfo.is_a = "toc"; comp_obj_toc.node.ocn = 0; - comp_obj_toc.node.obj_cite_number = ""; - comp_obj_toc.misc.obj_cite_number_off = ""; - comp_obj_toc.misc.obj_cite_number_type = 0; + comp_obj_toc.node.object_number = ""; + comp_obj_toc.misc.object_number_off = ""; + comp_obj_toc.misc.object_number_type = 0; comp_obj_toc.attrib.indent_hang = indent["hang_position"]; comp_obj_toc.attrib.indent_base = indent["base_position"]; comp_obj_toc.attrib.bullet = false; @@ -5466,9 +5466,9 @@ static struct ObjInlineMarkup { comp_obj_toc.typeinfo.is_of = "para"; comp_obj_toc.typeinfo.is_a = "toc"; comp_obj_toc.node.ocn = 0; - comp_obj_toc.node.obj_cite_number = ""; - comp_obj_toc.misc.obj_cite_number_off = ""; - comp_obj_toc.misc.obj_cite_number_type = 0; + comp_obj_toc.node.object_number = ""; + comp_obj_toc.misc.object_number_off = ""; + comp_obj_toc.misc.object_number_type = 0; comp_obj_toc.attrib.indent_hang = indent["hang_position"]; comp_obj_toc.attrib.indent_base = indent["base_position"]; comp_obj_toc.attrib.bullet = false; @@ -5482,9 +5482,9 @@ static struct ObjInlineMarkup { comp_obj_toc.typeinfo.is_of = "para"; comp_obj_toc.typeinfo.is_a = "toc"; comp_obj_toc.node.ocn = 0; - comp_obj_toc.node.obj_cite_number = ""; - comp_obj_toc.misc.obj_cite_number_off = ""; - comp_obj_toc.misc.obj_cite_number_type = 0; + comp_obj_toc.node.object_number = ""; + comp_obj_toc.misc.object_number_off = ""; + comp_obj_toc.misc.object_number_type = 0; comp_obj_toc.attrib.bullet = false; comp_obj_toc.has.inline_links = true; switch (obj_["lev_markup_number"].to!int) { @@ -5855,7 +5855,7 @@ struct ObjAttributes { writeln(_obj_attrib["json"]); writeln( "is: ", oa_j["is"].str(), - "; obj_cite_number: ", oa_j["obj_cite_number"].integer() + "; object_number: ", oa_j["object_number"].integer() ); } } @@ -6108,7 +6108,7 @@ struct ObjAttributes { (oa_j.type == JSON_TYPE.OBJECT) ); if (obj_is_ == "heading") { - oa_j.object["obj_cite_number"] = _comp_obj_heading.node.ocn; + oa_j.object["object_number"] = _comp_obj_heading.node.ocn; oa_j.object["lev_markup_number"] = _comp_obj_heading.node.heading_lev_markup; oa_j.object["lev_collapsed_number"] = _comp_obj_heading.node.heading_lev_collapsed; oa_j.object["heading_ptr"] @@ -6116,7 +6116,7 @@ struct ObjAttributes { oa_j.object["doc_object_ptr"] = _comp_obj_heading.ptr.doc_object; } - oa_j.object["parent_obj_cite_number"] = _comp_obj_heading.node.parent_ocn; + oa_j.object["parent_object_number"] = _comp_obj_heading.node.parent_ocn; oa_j.object["parent_lev_markup_number"] = _comp_obj_heading.node.parent_lev_markup; _obj_attrib = oa_j.toString(); return _obj_attrib; @@ -6137,8 +6137,8 @@ struct ObjAttributes { #+BEGIN_SRC d struct BookIndexNuggetHash { string main_term, sub_term, sub_term_bits; - int obj_cite_number_offset, obj_cite_number_endpoint; - string[] obj_cite_numbers; + int object_number_offset, object_number_endpoint; + string[] object_numbers; string[][string][string] bi; string[][string][string] hash_nugget; string[] bi_main_terms_split_arr; @@ -6170,41 +6170,41 @@ struct BookIndexNuggetHash { auto bi_main_term_and_rest = bi_main_terms_content.split(rgx.bi_main_term_plus_rest_split); if (auto m = bi_main_term_and_rest[0].match( - rgx.bi_term_and_obj_cite_numbers_match) + rgx.bi_term_and_object_numbers_match) ) { main_term = m.captures[1].strip; - obj_cite_number_offset = m.captures[2].to!int; - obj_cite_number_endpoint=(obj_cite_digits.on + obj_cite_number_offset); - obj_cite_numbers ~= (obj_cite_digits.on.to!string ~ "-" ~ to!string(obj_cite_number_endpoint) + object_number_offset = m.captures[2].to!int; + object_number_endpoint=(obj_cite_digits.on + object_number_offset); + object_numbers ~= (obj_cite_digits.on.to!string ~ "-" ~ to!string(object_number_endpoint) ~ ":" ~ segment_anchor_tag); } else { main_term = bi_main_term_and_rest[0].strip; - obj_cite_numbers ~= obj_cite_digits.on.to!string + object_numbers ~= obj_cite_digits.on.to!string ~ ":" ~ segment_anchor_tag; } - bi[main_term]["_a"] ~= obj_cite_numbers; - obj_cite_numbers=null; + bi[main_term]["_a"] ~= object_numbers; + object_numbers=null; if (bi_main_term_and_rest.length > 1) { auto bi_sub_terms_split_arr = bi_main_term_and_rest[1].split( - rgx.bi_sub_terms_plus_obj_cite_number_offset_split + rgx.bi_sub_terms_plus_object_number_offset_split ); foreach (sub_terms_bits; bi_sub_terms_split_arr) { - if (auto m = sub_terms_bits.match(rgx.bi_term_and_obj_cite_numbers_match)) { + if (auto m = sub_terms_bits.match(rgx.bi_term_and_object_numbers_match)) { sub_term = m.captures[1].strip; - obj_cite_number_offset = m.captures[2].to!int; - obj_cite_number_endpoint=(obj_cite_digits.on + obj_cite_number_offset); - obj_cite_numbers ~= (obj_cite_digits.on.to!string ~ " - " ~ to!string(obj_cite_number_endpoint) + object_number_offset = m.captures[2].to!int; + object_number_endpoint=(obj_cite_digits.on + object_number_offset); + object_numbers ~= (obj_cite_digits.on.to!string ~ " - " ~ to!string(object_number_endpoint) ~ ":" ~ segment_anchor_tag); } else { sub_term = sub_terms_bits.strip; - obj_cite_numbers ~= to!string(obj_cite_digits.on) + object_numbers ~= to!string(obj_cite_digits.on) ~ ":" ~ segment_anchor_tag; } if (!empty(sub_term)) { - bi[main_term][sub_term] ~= obj_cite_numbers; + bi[main_term][sub_term] ~= object_numbers; } - obj_cite_numbers=null; + object_numbers=null; } } } @@ -6337,9 +6337,9 @@ struct BookIndexReportSection { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Book Index"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "_part_book_index"; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; @@ -6357,9 +6357,9 @@ struct BookIndexReportSection { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Index"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "bookindex"; comp_obj_heading_.node.marked_up_level = "1"; comp_obj_heading_.node.heading_lev_markup = 4; @@ -6435,9 +6435,9 @@ struct BookIndexReportSection { comp_obj_para.typeinfo.is_a = "bookindex"; comp_obj_para.text = bi_tmp_scroll.to!string.strip; comp_obj_para.node.ocn = 0; - comp_obj_para.node.obj_cite_number = ""; - comp_obj_para.misc.obj_cite_number_off = ""; - comp_obj_para.misc.obj_cite_number_type = 0; + comp_obj_para.node.object_number = ""; + comp_obj_para.misc.object_number_off = ""; + comp_obj_para.misc.object_number_type = 0; comp_obj_para.tags.anchor_tags = bi_tmp_tags; comp_obj_para.attrib.indent_hang = 0; comp_obj_para.attrib.indent_base = 1; @@ -6452,9 +6452,9 @@ struct BookIndexReportSection { comp_obj_heading_ = comp_obj_heading_.init; comp_obj_heading_.text = "(skip) there is no Book Index"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; comp_obj_heading_.node.heading_lev_collapsed = 1; @@ -6596,9 +6596,9 @@ struct NotesSection { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Endnotes"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "_part_endnotes"; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; @@ -6614,9 +6614,9 @@ struct NotesSection { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "Endnotes"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.tags.segment_anchor_tag = "endnotes"; comp_obj_heading_.node.marked_up_level = "1"; comp_obj_heading_.node.heading_lev_markup = 4; @@ -6634,9 +6634,9 @@ struct NotesSection { comp_obj_heading_.typeinfo.is_a = "heading"; comp_obj_heading_.text = "(skip) there are no Endnotes"; comp_obj_heading_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_heading_.node.marked_up_level = "B"; comp_obj_heading_.node.heading_lev_markup = 1; comp_obj_heading_.node.heading_lev_collapsed = 1; @@ -6652,9 +6652,9 @@ struct NotesSection { comp_obj_endnote_.typeinfo.is_of = "para"; comp_obj_endnote_.typeinfo.is_a = "endnote"; comp_obj_endnote_.node.ocn = 0; - comp_obj_heading_.node.obj_cite_number = ""; - comp_obj_heading_.misc.obj_cite_number_off = ""; - comp_obj_heading_.misc.obj_cite_number_type = 0; + comp_obj_heading_.node.object_number = ""; + comp_obj_heading_.misc.object_number_off = ""; + comp_obj_heading_.misc.object_number_type = 0; comp_obj_endnote_.attrib.indent_hang = 0; comp_obj_endnote_.attrib.indent_base = 0; comp_obj_endnote_.attrib.bullet = false; @@ -6857,23 +6857,23 @@ struct NodeStructureMetadata { assert(obj_cite_digits.on.to!int >= 0); // should not be necessary if (lv7 > State.off) { p_["lev_markup_number"] = DocStructMarkupHeading.h_text_4; - p_["obj_cite_number"] = lv7; + p_["object_number"] = lv7; } else if (lv6 > State.off) { p_["lev_markup_number"] = DocStructMarkupHeading.h_text_3; - p_["obj_cite_number"] = lv6; + p_["object_number"] = lv6; } else if (lv5 > State.off) { p_["lev_markup_number"] = DocStructMarkupHeading.h_text_2; - p_["obj_cite_number"] = lv5; + p_["object_number"] = lv5; } else { p_["lev_markup_number"] = DocStructMarkupHeading.h_text_1; - p_["obj_cite_number"] = lv4; + p_["object_number"] = lv4; } ObjGenericComposite comp_obj_location; comp_obj_location = comp_obj_location.init; comp_obj_location.typeinfo.is_a = is_; comp_obj_location.node.ocn = obj_cite_digits.on; comp_obj_location.tags.segment_anchor_tag = segment_anchor_tag.to!string; - comp_obj_location.node.parent_ocn = p_["obj_cite_number"]; + comp_obj_location.node.parent_ocn = p_["object_number"]; comp_obj_location.node.parent_lev_markup = p_["lev_markup_number"]; debug(node) { if (lev_markup_number.match(rgx.levels_numbered_headings)) { @@ -6951,7 +6951,7 @@ struct NodeStructureMetadata { lv0 = obj_cite_digit; lv1=0; lv2=0; lv3=0; lv4=0; lv5=0; lv6=0; lv7=0; p_["lev_markup_number"] = 0; - p_["obj_cite_number"] = 0; + p_["object_number"] = 0; break; case 1: lv = DocStructMarkupHeading.h_sect_B; @@ -6959,7 +6959,7 @@ struct NodeStructureMetadata { lv2=0; lv3=0; lv4=0; lv5=0; lv6=0; lv7=0; p_["lev_markup_number"] = DocStructMarkupHeading.h_sect_A; - p_["obj_cite_number"] = lv0; + p_["object_number"] = lv0; break; case 2: lv = DocStructMarkupHeading.h_sect_C; @@ -6967,7 +6967,7 @@ struct NodeStructureMetadata { lv3=0; lv4=0; lv5=0; lv6=0; lv7=0; p_["lev_markup_number"] = DocStructMarkupHeading.h_sect_B; - p_["obj_cite_number"] = lv1; + p_["object_number"] = lv1; break; case 3: lv = DocStructMarkupHeading.h_sect_D; @@ -6975,7 +6975,7 @@ struct NodeStructureMetadata { lv4=0; lv5=0; lv6=0; lv7=0; p_["lev_markup_number"] = DocStructMarkupHeading.h_sect_C; - p_["obj_cite_number"] = lv2; + p_["object_number"] = lv2; break; case 4: lv = DocStructMarkupHeading.h_text_1; @@ -6984,19 +6984,19 @@ struct NodeStructureMetadata { if (lv3 > State.off) { p_["lev_markup_number"] = DocStructMarkupHeading.h_sect_D; - p_["obj_cite_number"] = lv3; + p_["object_number"] = lv3; } else if (lv2 > State.off) { p_["lev_markup_number"] = DocStructMarkupHeading.h_sect_C; - p_["obj_cite_number"] = lv2; + p_["object_number"] = lv2; } else if (lv1 > State.off) { p_["lev_markup_number"] = DocStructMarkupHeading.h_sect_B; - p_["obj_cite_number"] = lv1; + p_["object_number"] = lv1; } else { p_["lev_markup_number"] = DocStructMarkupHeading.h_sect_A; - p_["obj_cite_number"] = lv0; + p_["object_number"] = lv0; } break; case 5: @@ -7005,7 +7005,7 @@ struct NodeStructureMetadata { lv6=0; lv7=0; p_["lev_markup_number"] = DocStructMarkupHeading.h_text_1; - p_["obj_cite_number"] = lv4; + p_["object_number"] = lv4; break; case 6: lv = DocStructMarkupHeading.h_text_3; @@ -7013,14 +7013,14 @@ struct NodeStructureMetadata { lv7=0; p_["lev_markup_number"] = DocStructMarkupHeading.h_text_2; - p_["obj_cite_number"] = lv5; + p_["object_number"] = lv5; break; case 7: lv = DocStructMarkupHeading.h_text_4; lv7 = obj_cite_digit; p_["lev_markup_number"] = DocStructMarkupHeading.h_text_3; - p_["obj_cite_number"] = lv6; + p_["object_number"] = lv6; break; default: break; @@ -7033,14 +7033,14 @@ struct NodeStructureMetadata { _comp_obj_heading_.typeinfo.is_a = "heading"; _comp_obj_heading_.text = _text.to!string.strip; _comp_obj_heading_.node.ocn = obj_cite_digits.on; - _comp_obj_heading_.node.obj_cite_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; - _comp_obj_heading_.misc.obj_cite_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; - _comp_obj_heading_.misc.obj_cite_number_type = obj_cite_digits.type; + _comp_obj_heading_.node.object_number = (obj_cite_digits.on==0) ? "" : obj_cite_digits.on.to!string; + _comp_obj_heading_.misc.object_number_off = (obj_cite_digits.off==0) ? "" : obj_cite_digits.off.to!string; + _comp_obj_heading_.misc.object_number_type = obj_cite_digits.type; _comp_obj_heading_.tags.segment_anchor_tag = segment_anchor_tag.to!string; _comp_obj_heading_.node.marked_up_level = lev; _comp_obj_heading_.node.heading_lev_markup = (!(lev_markup_number.empty) ? lev_markup_number.to!int : 0); _comp_obj_heading_.node.heading_lev_collapsed = (!(lev_collapsed_number.empty) ? lev_collapsed_number.to!int : 0); - _comp_obj_heading_.node.parent_ocn = p_["obj_cite_number"]; + _comp_obj_heading_.node.parent_ocn = p_["object_number"]; _comp_obj_heading_.node.parent_lev_markup = p_["lev_markup_number"]; _comp_obj_heading_.tags.heading_ancestors_text = lv_ancestors_txt; _comp_obj_heading_.ptr.doc_object = cntr_; @@ -7385,8 +7385,8 @@ struct DocObj_Has_ { } struct DocObj_Node_ { string[string][string] node; - int ocn = 0; // duplicated as string with obj_cite_number - string obj_cite_number = ""; // duplicated as int with ocn may apply additional info for backmatter (glossary, biblio etc.) + int ocn = 0; // duplicated as string with object_number + string object_number = ""; // duplicated as int with ocn may apply additional info for backmatter (glossary, biblio etc.) string marked_up_level = "9"; int heading_lev_markup = 9; int heading_lev_collapsed = 9; @@ -7421,9 +7421,9 @@ struct DocObj_Tags_ { string[] anchor_tags = []; } struct DocObj_Misc_ { - string obj_cite_number_bkidx = ""; - string obj_cite_number_off = ""; - int obj_cite_number_type = 0; // { ocn, non, bkidx } + string object_number_bkidx = ""; + string object_number_off = ""; + int object_number_type = 0; // { ocn, non, bkidx } } struct ObjGenericComposite { string text = ""; -- cgit v1.2.3