diff options
author | Ralph Amissah <ralph.amissah@gmail.com> | 2019-11-15 20:38:38 -0500 |
---|---|---|
committer | Ralph Amissah <ralph.amissah@gmail.com> | 2019-11-19 16:55:31 -0500 |
commit | 8b04ed5fd9118f0defb2f4cd1f80bafce49650b4 (patch) | |
tree | bdbd5247e50cea077e5d600e9c6ae8580f6ec1f4 /org/output_odt.org | |
parent | 0.9.0 spine (doc-reform renamed) (diff) |
org renaming
Diffstat (limited to 'org/output_odt.org')
-rw-r--r-- | org/output_odt.org | 2517 |
1 files changed, 0 insertions, 2517 deletions
diff --git a/org/output_odt.org b/org/output_odt.org deleted file mode 100644 index 0a7f93d..0000000 --- a/org/output_odt.org +++ /dev/null @@ -1,2517 +0,0 @@ --*- mode: org -*- -#+TITLE: doc_reform output odt -#+DESCRIPTION: documents - structuring, publishing in multiple formats & search -#+FILETAGS: :spine:output:xml:odt: -#+AUTHOR: Ralph Amissah -#+EMAIL: [[mailto:ralph.amissah@gmail.com][ralph.amissah@gmail.com]] -#+COPYRIGHT: Copyright (C) 2015 - 2019 Ralph Amissah -#+LANGUAGE: en -#+STARTUP: indent content hideblocks hidestars -#+OPTIONS: H:3 num:nil toc:t \n:nil @:t ::t |:t ^:nil _:nil -:t f:t *:t <:t -#+OPTIONS: TeX:t LaTeX:t skip:nil d:nil todo:t pri:nil tags:not-in-toc -#+OPTIONS: author:nil email:nil creator:nil timestamp:nil -#+PROPERTY: header-args :results silent :padline no :exports code :cache no :noweb yes -#+EXPORT_SELECT_TAGS: export - -- [[./spine.org][spine]] [[./][org/]] -- [[./output_hub.org][output_hub]] - -* odt :odt: - -- cover object types -- zip contents -- xml closures? unnecessary, this is sax rather than dom no? - -|---------------------------------+-----------------------+-------------------+------------------------+------------------| -| function | filename | module | variable | output_odt | -|---------------------------------+-----------------------+-------------------+------------------------+------------------| -| identify doc filetype | mimetype | odt_mimetypes | mimetypes | output_odt_fixed | -|---------------------------------+-----------------------+-------------------+------------------------+------------------| -| doc manifest | manifest.rdf | | | output_odt_fixed | -|---------------------------------+-----------------------+-------------------+------------------------+------------------| -| settings | settings.xml | outputODTsettings | | output_odt_fixed | -|---------------------------------+-----------------------+-------------------+------------------------+------------------| -| doc xml styles | styles.xml | outputODTstyles | | output_odt_fixed | -|---------------------------------+-----------------------+-------------------+------------------------+------------------| -| identify doc root * (imagelist) | META-INF/manifest.xml | odt_container_xml | meta_inf_container_xml | | -|---------------------------------+-----------------------+-------------------+------------------------+------------------| -| doc content * | content.xml | odt_content | content_odt | | -|---------------------------------+-----------------------+-------------------+------------------------+------------------| -| images * | Pictures/ | | | copy_odt_images | -|---------------------------------+-----------------------+-------------------+------------------------+------------------| -| doc meta * (timestamp) | meta.xml | odt_metadata | | | -|---------------------------------+-----------------------+-------------------+------------------------+------------------| - -** _module template_ :odf:odt:module: - -#+BEGIN_SRC d :tangle "../src/doc_reform/output/odt.d" :noweb yes -module doc_reform.output.odt; -template formatODT() { - <<output_imports>> - mixin DocReformOutputRgxInit; - struct formatODT { - static auto rgx = Rgx(); - <<odt_format_objects>> - } -} -template outputODT() { - <<output_imports>> - mixin InternalMarkup; - mixin DocReformOutputRgxInit; - auto rgx = Rgx(); - // mixin outputXmlODT; - <<output_odt_variable_content_xml>> - <<output_odt_variable_manifest_xml>> - <<output_odt_variable_copy_odt_images>> - <<output_odt_variable_meta_xml>> - <<output_odt_fixed_dirtree>> - <<output_odt_fixed_mimetype>> - <<output_odt_fixed_manifest_rdf>> - <<output_odt_fixed_settings_xml>> - <<output_odt_fixed_styles_xml>> - <<output_odt_write>> - <<output_odt>> -} -#+END_SRC - -** odt format objects -*** detail -**** odf structure - -- unless code - - images - - links - - internal / relative - - external - -**** object attrib -***** tags - -#+name: odt_format_objects -#+BEGIN_SRC d -string _tags(O)(const O obj){ - string _tags = ""; - if (obj.tags.anchor_tags.length > 0) { - foreach (tag_; obj.tags.anchor_tags) { - if (tag_.length > 0) { - _tags ~= format(q"┃<text:span text:style-name="Span_subscript"> - <text:bookmark-start text:name="%s"/> - <text:bookmark-end text:name="%s"/> - </text:span> -┃", - _special_characters(tag_, obj), - _special_characters(tag_, obj), - ); - } - } - } - return _tags; -} -#+END_SRC - -****** anchor tags - -#+name: odt_format_objects -#+BEGIN_SRC d -string _xhtml_anchor_tags(O)(O obj) { - const(string[]) anchor_tags = obj.tags.anchor_tags; - string tags=""; - if (anchor_tags.length > 0) { - foreach (tag; anchor_tags) { - if (!(tag.empty)) { - tags ~= "<a name=\"" ~ tag ~ "\"></a>"; - } - } - } - return tags; -} -#+END_SRC - -***** ocn object number display - -#+name: odt_format_objects -#+BEGIN_SRC d -string obj_num(O)(const O obj){ // TODO - string _on; - _on = (obj.metainfo.object_number.empty) - ? "" - : (format(q"┃ - <text:span text:style-name="Span_subscript">「%s」</text:span>┃", - obj.metainfo.object_number, - )); - return _on; -} -#+END_SRC - -***** footnotes - -#+name: odt_format_objects -#+begin_src d -string _footnotes()(string _txt){ - static auto rgx = Rgx(); - _txt = _txt.replaceAll( - rgx.inline_notes_al_regular_number_note, - format(q"┃<text:note text:id="ftn%s" text:note-class="footnote"> - <text:note-citation> - %s - </text:note-citation> - <text:note-body> - <text:p text:style-name="Footnote"> - %s - </text:p> - </text:note-body> -</text:note>┃", - "$1", "$1", "$2", - ) - ); - return _txt; -} -#+end_src - -***** bullet - -#+name: odt_format_objects -#+BEGIN_SRC d -string _bullet(O)(const O obj){ - string _b = ""; - if (obj.attrib.bullet) { - _b = format(q"┃● ┃",); - } - return _b; -} -#+END_SRC - -***** para (with bullet, indent levels, footnotes extracted) - -#+name: odt_format_objects -#+BEGIN_SRC d -string _indent(O)(string _txt, const O obj) { // TODO - // if (obj.attrib.indent_base > 0 || - // obj.attrib.indent_hang > 0 - // ) { - if (obj.metainfo.is_a == "toc") { - _txt = format(q"┃ -%s<text:h text:style-name="H_%s" text:outline-level="%s"> - %s%s%s -</text:h>┃", - (obj.attrib.indent_base < 4) - ? "<text:p text:style-name=\"Standard\"/>\n " : "", - obj.attrib.indent_base, - obj.attrib.indent_base, - _tags(obj), - _txt, - obj_num(obj), - ); - } else if (!empty(obj.metainfo.object_number)) { - if (obj.attrib.indent_base == 0 && obj.attrib.indent_hang == 0) { - _txt = format(q"┃ -<text:p text:style-name="P_normal">%s - <text:span text:style-name="Span_subscript"> - <text:bookmark-start text:name="%s"/> - <text:bookmark-end text:name="%s"/> - </text:span> - %s%s%s -</text:p>┃", - _bullet(obj), - obj.metainfo.object_number, - obj.metainfo.object_number, - _tags(obj), - _txt, - obj_num(obj), - ); - } else if (obj.attrib.indent_base == obj.attrib.indent_hang) { - _txt = format(q"┃ -<text:p text:style-name="P_indent_%s">%s - <text:span text:style-name="Span_subscript"> - <text:bookmark-start text:name="%s"/> - <text:bookmark-end text:name="%s"/> - </text:span> - %s%s%s -</text:p>┃", - obj.attrib.indent_base, - _bullet(obj), - obj.metainfo.object_number, - obj.metainfo.object_number, - _tags(obj), - _txt, - obj_num(obj), - ); - } else { - _txt = format(q"┃ -<text:p text:style-name="P_h%s_i%s">%s - <text:span text:style-name="Span_subscript"> - <text:bookmark-start text:name="%s"/> - <text:bookmark-end text:name="%s"/> - </text:span> - %s%s%s -</text:p>┃", - obj.attrib.indent_base, - obj.attrib.indent_hang, - _bullet(obj), - obj.metainfo.object_number, - obj.metainfo.object_number, - _tags(obj), - _txt, - obj_num(obj), - ); - } - } else { - if (obj.attrib.indent_base == 0 && obj.attrib.indent_hang == 0) { /+ can omit and would explicitly set indent base and hang as 0 each below +/ - _txt = format(q"┃ -<text:p text:style-name="P_normal">%s - %s%s%s -</text:p>┃", - _bullet(obj), - _tags(obj), - _txt, - obj_num(obj), - ); - } else if (obj.attrib.indent_base == obj.attrib.indent_hang) { - _txt = format(q"┃ -<text:p text:style-name="P_indent_%s">%s - %s%s%s -</text:p>┃", - obj.attrib.indent_base, - _bullet(obj), - _tags(obj), - _txt, - obj_num(obj), - ); - } else { - _txt = format(q"┃ -<text:p text:style-name="P_h%s_i%s">%s - %s%s%s -</text:p>┃", - _bullet(obj), - obj.attrib.indent_base, - obj.attrib.indent_hang, - _tags(obj), - _txt, - obj_num(obj), - ); - } - } - return _txt; -} -#+END_SRC - -***** block type - -#+name: odt_format_objects -#+BEGIN_SRC d -string _block_type_delimiters(O)(string[] _block_lines, const O obj) { // TODO - string _block = ""; - foreach (i, _line; _block_lines) { - _line = _footnotes(_line); - if (i == 0) { - _block ~= format(q"┃ -<text:p text:style-name="P_group">%s - <text:span text:style-name="Span_subscript"> - <text:bookmark-start text:name="%s"/> - <text:bookmark-end text:name="%s"/> - </text:span> - %s -</text:p>┃", - _bullet(obj), - obj.metainfo.object_number, - obj.metainfo.object_number, - // _tags(obj), - _line, - ); - } else { - _block ~= format(q"┃ -<text:p text:style-name="P_group">%s</text:p>┃", - _line); - } - } - _block ~= format(q"┃ -<text:p text:style-name="P_group"> - <text:span text:style-name="Span_subscript">「%s」</text:span> -</text:p> -<text:p text:style-name="Standard"/>┃", - obj_num(obj)); - return _block; -} -#+END_SRC - -**** object inline - -***** special characters - -#+name: odt_format_objects -#+BEGIN_SRC d -string _special_characters(O)(string _txt, const O obj) { - _txt = _txt - .replaceAll(rgx.xhtml_ampersand, "&") - .replaceAll(rgx.xhtml_quotation, """) - .replaceAll(rgx.xhtml_less_than, "<") - .replaceAll(rgx.xhtml_greater_than, ">") - .replaceAll(rgx.nbsp_char, " "); - return _txt; -} -#+END_SRC - -***** preserve white space - -#+name: odt_format_objects -#+BEGIN_SRC d -string _preserve_white_spaces(O)(string _txt, const O obj) { - if (obj.metainfo.is_a == "code" || obj.metainfo.is_a == "verse" || obj.metainfo.is_a == "block") { - _txt = _txt - .replaceAll(rgx.space, " "); - } - return _txt; -} -#+END_SRC - -***** font_face - -#+name: odt_format_objects -#+BEGIN_SRC d -string _font_face(string _txt){ - _txt = _txt - .replaceAll(rgx.inline_strike, "<del>$1</del>") - .replaceAll(rgx.inline_insert, "<ins>$1</ins>") - .replaceAll(rgx.inline_cite, "<cite>$1</cite>") - .replaceAll(rgx.inline_emphasis, format(q"┃<text:span text:style-name="Span_bold">%s</text:span>┃","$1")) - .replaceAll(rgx.inline_bold, format(q"┃<text:span text:style-name="Span_bold">%s</text:span>┃","$1")) - .replaceAll(rgx.inline_italics, format(q"┃<text:span text:style-name="Span_italic">%s</text:span>┃","$1")) - .replaceAll(rgx.inline_underscore, format(q"┃<text:span text:style-name="Span_underscore">%s</text:span>┃","$1")) - .replaceAll(rgx.inline_superscript, format(q"┃<text:span text:style-name="Span_superscript">%s</text:span>┃","$1")) - .replaceAll(rgx.inline_subscript, format(q"┃<text:span text:style-name="Span_subscript">%s</text:span>┃","$1")) - .replaceAll(rgx.inline_mono, format(q"┃<text:span text:style-name="Span_monospace">%s</text:span>┃","$1")); - return _txt; -} -#+END_SRC - -***** object number - -#+name: odt_format_objects -#+BEGIN_SRC d -auto _obj_num(O)(O obj) { // NOT USED YET - struct objNum { - string reference() { - return format(q"┃<text:span text:style-name="Span_subscript"> - <text:bookmark-start text:name="%s"/> - <text:bookmark-end text:name="%s"/> - </text:span>┃", - obj.object_number, - obj.object_number, - ); - } - string display() { - return format(q"┃<text:span text:style-name="Span_subscript"> - %s%s%s - </text:span>┃", - on_o, - obj.object_number, - on_c, - ); - } - } - return objNum(); -} -#+END_SRC - -***** break page - -#+name: odt_format_objects -#+BEGIN_SRC d -string _break_page()() { - return format(q"┃ -<text:p text:style-name="P_normal_page_new"/> -┃", - ); -} -#+END_SRC - -#+BEGIN_SRC d -string _break_page()() { - return format(q"┃ -<text:p text:style-name="P_page_break"> </text:p> -<text:p text:style-name="P_normal_page_new"/>┃", - ); -} -#+END_SRC - -***** empty lines break - -#+name: odt_format_objects -#+BEGIN_SRC d -string _empty_line_break(O)(string _txt, const O obj) { - if (obj.metainfo.is_a == "code" || obj.metainfo.is_a == "verse" || obj.metainfo.is_a == "block") { - _txt = _txt - .replaceAll(rgx.br_empty_line, "<br />"); - } - return _txt; -} -#+END_SRC - -***** links: url, mail - -#+name: odt_format_objects -#+BEGIN_SRC d -string _links(O)(string _txt, const O obj) { - if (obj.metainfo.is_a != "code") { - if (obj.metainfo.is_a == "toc") { - _txt = replaceAll!(m => - m[1] ~ "┤" - ~ (replaceAll!(n => - n["type"] ~ n["path"] ~ (n["file"].encodeComponent) - )((obj.stow.link[m["num"].to!ulong]).to!string, rgx.uri_identify_components)) - ~ "├" - )(_txt, rgx.inline_link_number_only) - .replaceAll(rgx.inline_link, - format(q"┃<text:bookmark-ref text:reference-format="text" text:ref-name="%s">%s</text:bookmark-ref>┃", - _special_characters("$3", obj), - _special_characters("$1", obj) - )); - } else { - _txt = replaceAll!(m => - m[1] ~ "┤" - ~ (replaceAll!(n => - n["type"] ~ n["path"] ~ (n["file"].encodeComponent) - )((obj.stow.link[m["num"].to!ulong]).to!string, rgx.uri_identify_components)) - ~ "├" - )(_txt, rgx.inline_link_number_only) - .replaceAll(rgx.inline_link, - format(q"┃<text:a xl:type="simple" xl:href="%s">%s</text:a>┃", - _special_characters("$2", obj), - _special_characters("$1", obj) - )); - } - } - debug(links) { - if (obj.text.match(rgx.inline_link_number) - && _txt.match(rgx.inline_link_number_only) - ) { - writeln(">> ", _txt); - writeln("is_a: ", obj.metainfo.is_a); - } - } - return _txt; -} -#+END_SRC - -***** image - -#+name: odt_format_objects -#+BEGIN_SRC d -string _images(O)(string _txt, const O obj) { - if (_txt.match(rgx.inline_image)) { - _txt = _txt - .replaceAll(rgx.inline_image, - ("$1<draw:frame draw:style-name=\"fr1\" draw:name=\"graphics12\" text:anchor-type=\"as-char\" svg:width=\"$4px\" svg:height=\"$5px\" draw:z-index=\"2\"><draw:image xl:href=\"Pictures/$3\" xl:type=\"simple\" xl:show=\"embed\" xl:actuate=\"onLoad\"/></draw:frame> $6")) - .replaceAll( - rgx.inline_link_empty, - ("$1")); - } - return _txt; -} -#+END_SRC - -**** markup hub (including font face) - -#+name: odt_format_objects -#+BEGIN_SRC d -string markup(O)(const O obj) { - /+ markup TODO +/ - string _txt = obj.text; - _txt = _special_characters(_txt, obj); // TODO & why both obj & obj.text, consider also in output_xmls.org - if (obj.metainfo.is_a == "code" || obj.metainfo.is_a == "verse" || obj.metainfo.is_a == "block") { - _txt = replaceAll!(m => _preserve_white_spaces(m[1], obj))(_txt, rgx.spaces_keep); - } // check that this does what you want, keep: leading spaces (indent) & more than single spaces within text - // _txt = _preserve_white_spaces(_txt, obj); // (obj.metainfo.is_a == "code" || obj.metainfo.is_a == "verse" || obj.metainfo.is_a == "block") - _txt = _font_face(_txt); - _txt = _images(_txt, obj); // (obj.metainfo.is_a != "code") - _txt = _links(_txt, obj); // (obj.metainfo.is_a != "code") - _txt = _empty_line_break(_txt, obj); // (obj.metainfo.is_a == "code" || obj.metainfo.is_a == "verse" || obj.metainfo.is_a == "block") - return _txt; -} -#+END_SRC - -*** objects -**** para type -***** heading - -#+name: odt_format_objects -#+BEGIN_SRC d -string heading(O,M)( - const O obj, - const M doc_matters, -) { - assert(obj.metainfo.is_of_part == "body" || "frontmatter" || "backmatter"); - assert(obj.metainfo.is_of_section == "body" || "toc" || "endnotes" || "glossary" || "bibliography" || "bookindex" || "blurb"); - assert(obj.metainfo.is_of_type == "para"); - assert(obj.metainfo.is_a == "heading"); - string _o_txt_odt = markup(obj); - if (obj.metainfo.dummy_heading - && (obj.metainfo.is_a == "toc" || obj.metainfo.is_a == "heading")) { - _o_txt_odt = ""; - } else if (obj.metainfo.is_a == "toc") { - _o_txt_odt = format(q"┃%s<text:h text:style-name="H_%s" text:outline-level="%s"> - %s%s%s -</text:h>┃", - _break_page, - obj.metainfo.heading_lev_markup, - obj.metainfo.heading_lev_markup, - _tags(obj), - _o_txt_odt, - obj_num(obj), - ); - } else { - _o_txt_odt = _footnotes(_o_txt_odt); - _o_txt_odt = format(q"┃%s<text:h text:style-name="H_%s" text:outline-level="%s"> - <text:span text:style-name="Span_subscript"> - <text:bookmark-start text:name="%s"/> - <text:bookmark-end text:name="%s"/> - </text:span> - %s%s%s -</text:h>┃", - _break_page, - obj.metainfo.heading_lev_markup, - obj.metainfo.heading_lev_markup, - obj.metainfo.object_number, - obj.metainfo.object_number, - _tags(obj), - _o_txt_odt, - obj_num(obj), - ); - } - return _o_txt_odt; -} -#+END_SRC - -***** para - -#+name: odt_format_objects -#+BEGIN_SRC d -string para(O,M)( - const O obj, - const M doc_matters, -) { - assert(obj.metainfo.is_of_part == "body" || "frontmatter" || "backmatter"); - assert(obj.metainfo.is_of_section == "body" || "toc" || "endnotes" || "glossary" || "bibliography" || "bookindex" || "blurb"); - assert(obj.metainfo.is_of_type == "para"); - assert(obj.metainfo.is_a == "para" || "toc" || "endnotes" || "glossary" || "bibliography" || "bookindex" || "blurb"); - string _o_txt_odt; - if (obj.metainfo.dummy_heading - && (obj.metainfo.is_a == "toc" || obj.metainfo.is_a == "heading")) { - _o_txt_odt = ""; - } else { - _o_txt_odt = markup(obj); - _o_txt_odt = _footnotes(_o_txt_odt); - _o_txt_odt = _indent(_o_txt_odt, obj); // final setting? - } - return _o_txt_odt; -} -#+END_SRC - -**** block type -***** quote - -#+name: odt_format_objects -#+BEGIN_SRC d -string quote(O,M)( - const O obj, - const M doc_matters, -) { - assert(obj.metainfo.is_of_part == "body"); - assert(obj.metainfo.is_of_section == "body" || "glossary" || "bibliography" || "bookindex" || "blurb"); - assert(obj.metainfo.is_of_type == "block"); - assert(obj.metainfo.is_a == "quote"); - string _o_txt_odt = markup(obj); - _o_txt_odt = _footnotes(_o_txt_odt); // decide - return _o_txt_odt; -} -#+END_SRC - -***** group -- group delimiter - - preserves double newlines (paragraph delimiter) -- the "group" delimiter is different from the "block" delimiter in that groups do not preserve whitespace, the "block" mark does - -#+name: odt_format_objects -#+BEGIN_SRC d -string group(O,M)( - const O obj, - const M doc_matters, -) { - assert(obj.metainfo.is_of_part == "body"); - assert(obj.metainfo.is_of_section == "body" || "glossary" || "bibliography" || "bookindex" || "blurb"); - assert(obj.metainfo.is_of_type == "block"); - assert(obj.metainfo.is_a == "group"); - string _o_txt_odt = markup(obj); - /+ TODO - - split lines - - only double newlines (paragraph delimiter), (not line breaks, single new lines) - - no hard space indentation - +/ - string[] _block_lines = (_o_txt_odt).split(rgx.br_newlines_linebreaks); - _o_txt_odt = _block_type_delimiters(_block_lines, obj); - return _o_txt_odt; -} -#+END_SRC - -***** block -- block delimiter - - preserves spaces - - preserves newlines -- the "block" delimiter is different from the "group" delimiter, in that blocks preserve whitespace, the "group" mark does not - -- - - split lines - - each line including empty lines - - hard space indentation - - "^[ ]"   - - count number only at beginning of line and replace each - -#+name: odt_format_objects -#+BEGIN_SRC d -string block(O,M)( - const O obj, - const M doc_matters, -) { - assert(obj.metainfo.is_of_part == "body"); - assert(obj.metainfo.is_of_section == "body" || "glossary" || "bibliography" || "bookindex" || "blurb"); - assert(obj.metainfo.is_of_type == "block"); - assert(obj.metainfo.is_a == "block"); - string _o_txt_odt = markup(obj); - string[] _block_lines = (_o_txt_odt).split(rgx.br_newlines_linebreaks); - _o_txt_odt = _block_type_delimiters(_block_lines, obj); - return _o_txt_odt; -} -#+END_SRC - -***** verse -- poem delimiters - - creates verses where double newlines occur (paragraph delimiter) - - preserves spaces - - preserves newlines - -#+name: odt_format_objects -#+BEGIN_SRC d -string verse(O,M)( - const O obj, - const M doc_matters, -) { - assert(obj.metainfo.is_of_part == "body"); - assert(obj.metainfo.is_of_section == "body" || "glossary" || "bibliography" || "bookindex" || "blurb"); - assert(obj.metainfo.is_of_type == "block"); - assert(obj.metainfo.is_a == "verse"); - string _o_txt_odt = markup(obj); - string[] _block_lines = (_o_txt_odt).split(rgx.br_newlines_linebreaks); - _o_txt_odt = _block_type_delimiters(_block_lines, obj); - return _o_txt_odt; -} -#+END_SRC - -***** code - -#+name: odt_format_objects -#+BEGIN_SRC d -string code(O,M)( - const O obj, - const M doc_matters, -) { - assert(obj.metainfo.is_of_part == "body"); - assert(obj.metainfo.is_of_section == "body"); - assert(obj.metainfo.is_of_type == "block"); - assert(obj.metainfo.is_a == "code"); - string _o_txt_odt = markup(obj); - /+ TODO - - split lines - - each line including empty lines - - hard space indentation - - "^[ ]"   - - count number only at beginning of line and replace each - +/ - string[] _block_lines = (_o_txt_odt).split(rgx.br_newlines_linebreaks); - string _block = ""; - foreach (i, _line; _block_lines) { - if (i == 1) { - _block ~= format(q"┃ -<text:p text:style-name="P_code"> -<text:span text:style-name="Span_subscript"> - <text:bookmark-start text:name="%s"/> - <text:bookmark-end text:name="%s"/> -</text:span> -%s -</text:p>┃", - obj.metainfo.object_number, - obj.metainfo.object_number, - _line, - ); - } else { - _block ~= format(q"┃ -<text:p text:style-name="P_code">%s</text:p>┃", - _line); - } - } - _block ~= format(q"┃ -<text:p text:style-name="P_group"> - <text:span text:style-name="Span_subscript">「%s」</text:span> -</text:p> -<text:p text:style-name="Standard"/>┃", - obj_num(obj)); - _o_txt_odt = _block; - return _o_txt_odt; -} -#+END_SRC - -***** table -****** tablarize - -#+name: odt_format_objects -#+BEGIN_SRC d -auto tablarize(O)( - const O obj, - string _txt, -) { - string[] _table_rows = (_txt).split(rgx.table_delimiter_row); - string[] _table_cols; - string _table; - string _tablenote; - foreach(row_idx, row; _table_rows) { - _table_cols = row.split(rgx.table_delimiter_col); - _table ~= "<table:table-row>"; - foreach(col_idx, cell; _table_cols) { - if ((_table_cols.length == 1) - && (_table_rows.length <= row_idx+2)) { // check row_idx+2 (rather than == ++row_idx) - _tablenote ~= cell; - } else { - _table ~= format(q"┃<table:table-cell office:value-type="string"> -<text:p text:style-name="%s"> -%s -</text:p> -</table:table-cell>┃", - (row_idx == 0 && obj.table.heading) ? "Table_Heading" : "P_table_cell", - cell, - ); - } - } - _table ~= "</table:table-row>"; - } - auto t = tuple( - _table, - _tablenote, - ); - return t; -} -#+END_SRC - -****** table - -#+name: odt_format_objects -#+BEGIN_SRC d -int _table_number = 0; -string table(O,M)( - const O obj, - const M doc_matters, -) { - assert(obj.metainfo.is_of_part == "body"); - assert(obj.metainfo.is_of_section == "body"); - assert(obj.metainfo.is_of_type == "block"); - assert(obj.metainfo.is_a == "table"); - string _o_txt_odt = markup(obj); - auto t = tablarize(obj, _o_txt_odt); - string _note = t[1]; - _o_txt_odt = format(q"┃ -<table:table table:name="Table%s" table:style-name="Table1"> - <text:span text:style-name="Span_subscript"> - <text:bookmark-start text:name="%s"/> - <text:bookmark-end text:name="%s"/> - </text:span> - <table:table-column table:style-name="Table1.D" table:number-columns-repeated="%s"/> - %s - </table:table> - <text:p text:style-name="P_group"> - <text:span text:style-name="Span_subscript">「%s」</text:span> -</text:p>┃", - _table_number++, - obj.metainfo.object_number, - obj.metainfo.object_number, - obj.table.number_of_columns, - t[0], - obj.metainfo.object_number, - // _note, - ); - return _o_txt_odt; -} -#+END_SRC - -** write odt output :odf:odt:out: - -#+name: output_odt -#+BEGIN_SRC d -void writeOutputODT(W,I)( - const W odt_content, - I doc_matters, -) { - auto pth_odt = DocReformPathsODT!()(doc_matters); - auto fn_odt = pth_odt.odt_file; - auto zip = new ZipArchive(); // ZipArchive zip = new ZipArchive(); - void ODTzip()(string contents, string fn) { - auto zip_arc_member_file = new ArchiveMember(); - zip_arc_member_file.name = fn; - auto zip_data = new OutBuffer(); - (doc_matters.opt.action.debug_do) - ? zip_data.write(contents.dup) - : zip_data.write(contents.dup - .replaceAll(rgx.spaces_line_start, "") - .replaceAll(rgx.newline, "") - .strip - ); - zip_arc_member_file.expandedData = zip_data.toBytes(); - zip.addMember(zip_arc_member_file); - createZipFile!()(fn_odt, zip.build()); - } - try { - if (!exists(pth_odt.base_pth)) { // check - pth_odt.base_pth.mkdirRecurse; - } - string fn; - File f; - { fn = pth_odt.mimetype("zip"); - ODTzip(odt_content.mimetype, fn); - } - { fn = pth_odt.manifest_rdf("zip"); - ODTzip(odt_content.manifest_rdf, fn); - } - { fn = pth_odt.settings_xml("zip"); - ODTzip(odt_content.settings_xml, fn); - } - { fn = pth_odt.styles_xml("zip"); - ODTzip(odt_content.styles_xml, fn); - } - { fn = pth_odt.content_xml("zip"); - ODTzip(odt_content.content_xml, fn); - } - { fn = pth_odt.manifest_xml("zip"); - ODTzip(odt_content.manifest_xml, fn); - } - { fn = pth_odt.meta_xml("zip"); - ODTzip(odt_content.meta_xml, fn); - } - { /+ (images) +/ - foreach (image; doc_matters.srcs.image_list) { - auto fn_src = doc_matters.src.image_dir_path ~ "/" ~ image; - auto fn_out = pth_odt.image_dir("zip") ~ "/" ~ image; - if (exists(fn_src)) { - { - auto zip_arc_member_file = new ArchiveMember(); - zip_arc_member_file.name = fn_out; - auto zip_data = new OutBuffer(); - zip_data.write(cast(char[]) ((fn_src).read)); - zip_arc_member_file.expandedData = zip_data.toBytes(); - zip.addMember(zip_arc_member_file); - createZipFile!()(fn_odt, zip.build()); - } - } - } - } - if (!(doc_matters.opt.action.quiet)) { - writeln(" ", pth_odt.odt_file); - } - } catch (ErrnoException ex) { - // Handle error - } - if (doc_matters.opt.action.debug_do) { - pth_odt.mimetype("fs"); /+ (mimetype) +/ - pth_odt.manifest_rdf("fs"); /+ (manifest.rdf) +/ - pth_odt.settings_xml("fs"); /+ (settings.xml) +/ - pth_odt.styles_xml("fs"); /+ (styles_xml) +/ - - pth_odt.content_xml("fs"); - pth_odt.manifest_xml("fs"); - pth_odt.meta_xml("fs"); - } -} -#+END_SRC - -** odt output hub [#A] :odf:odt:out: - -#+name: output_odt -#+BEGIN_SRC d -void outputODT(D,I)( - const D doc_abstraction, - I doc_matters, -) { - struct ODT { - /+ fixed output +/ - string mimetype; - string manifest_rdf; - string settings_xml; - string styles_xml; - /+ variable output +/ - string content_xml; // substantive content - string manifest_xml; // image list changes - string meta_xml; // time stamp - } - // auto pth_odt = DocReformPathsODT!()(doc_matters); - auto odt = ODT(); - odt.mimetype = mimetype; - odt.manifest_rdf = manifest_rdf; - odt.settings_xml = settings_xml; - odt.styles_xml = styles_xml; - odt.content_xml = content_xml(doc_abstraction, doc_matters); - odt.manifest_xml = manifest_xml(doc_matters); - odt.meta_xml = meta_xml(doc_matters); - odt.writeOutputODT(doc_matters); - dirtree(doc_matters); - images_cp(doc_matters); // copy images -} -#+END_SRC - -* stuff -** shared -*** output imports - -#+name: output_imports -#+BEGIN_SRC d -import doc_reform.output; -import - std.digest.sha, - std.file, - std.outbuffer, - std.uri, - std.zip, - std.conv : to; -import - doc_reform.output.create_zip_file, - doc_reform.output.xmls, - doc_reform.output.xmls_css; -#+END_SRC - -*** make directory tree - -#+name: output_odt_fixed_dirtree -#+BEGIN_SRC d -void dirtree(I)( - I doc_matters, -) { - auto pth_odt = DocReformPathsODT!()(doc_matters); - if (doc_matters.opt.action.debug_do) { /+ (dir tree) +/ - if (!exists(pth_odt.meta_inf_dir("fs"))) { - pth_odt.meta_inf_dir("fs").mkdirRecurse; - } - if (!exists(pth_odt.image_dir("fs"))) { - pth_odt.image_dir("fs").mkdirRecurse; - } - } - if (!exists(pth_odt.base_pth)) { - pth_odt.base_pth.mkdirRecurse; - } - // return 0; -} -#+END_SRC - -** fixed items -*** mimetype :mimetype: - -#+name: output_odt_fixed_mimetype -#+BEGIN_SRC d -string mimetype() { - string mimetype_ = format(q"┃application/vnd.oasis.opendocument.text┃"); - return mimetype_; -} -#+END_SRC - -*** manifest.rdf :manifest_rdf: - -#+name: output_odt_fixed_manifest_rdf -#+BEGIN_SRC d -string manifest_rdf() { - string _manifest_rdf = format(q"┃<?xml version="1.0" encoding="utf-8"?> -#+END_SRC - -#+name: output_odt_fixed_manifest_rdf -#+BEGIN_SRC xml -<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"> - <rdf:Description rdf:about="styles.xml"> - <rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#StylesFile"/> - </rdf:Description> - <rdf:Description rdf:about=""> - <ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="styles.xml"/> - </rdf:Description> - <rdf:Description rdf:about="content.xml"> - <rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/odf#ContentFile"/> - </rdf:Description> - <rdf:Description rdf:about=""> - <ns0:hasPart xmlns:ns0="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#" rdf:resource="content.xml"/> - </rdf:Description> - <rdf:Description rdf:about=""> - <rdf:type rdf:resource="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#Document"/> - </rdf:Description> -</rdf:RDF> -#+END_SRC - -#+name: output_odt_fixed_manifest_rdf -#+BEGIN_SRC d -┃"); - return _manifest_rdf; -} -#+END_SRC - -*** settings.xml :settings: - -#+name: output_odt_fixed_settings_xml -#+BEGIN_SRC d -string settings_xml() { - string _settings_xml = format(q"┃<?xml version="1.0" encoding="UTF-8"?> -#+END_SRC - -#+name: output_odt_fixed_settings_xml -#+BEGIN_SRC xml -<office:document-settings xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:xl="http://www.w3.org/1999/xlink" xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0" xmlns:ooo="http://openoffice.org/2004/office" office:version="1.2"> - <office:settings> - <config:config-item-set config:name="ooo:view-settings"> - <config:config-item config:name="ViewAreaTop" config:type="int">0</config:config-item> - <config:config-item config:name="ViewAreaLeft" config:type="int">0</config:config-item> - <config:config-item config:name="ViewAreaWidth" config:type="int">0</config:config-item> - <config:config-item config:name="ViewAreaHeight" config:type="int">0</config:config-item> - <config:config-item config:name="ShowRedlineChanges" config:type="boolean">true</config:config-item> - <config:config-item config:name="InBrowseMode" config:type="boolean">false</config:config-item> - <config:config-item-map-indexed config:name="Views"> - <config:config-item-map-entry> - <config:config-item config:name="ViewId" config:type="string">view2</config:config-item> - <config:config-item config:name="ViewLeft" config:type="int">0</config:config-item> - <config:config-item config:name="ViewTop" config:type="int">0</config:config-item> - <config:config-item config:name="VisibleLeft" config:type="int">0</config:config-item> - <config:config-item config:name="VisibleTop" config:type="int">0</config:config-item> - <config:config-item config:name="VisibleRight" config:type="int">0</config:config-item> - <config:config-item config:name="VisibleBottom" config:type="int">0</config:config-item> - <config:config-item config:name="ZoomType" config:type="short">0</config:config-item> - <config:config-item config:name="ViewLayoutColumns" config:type="short">2</config:config-item> - <config:config-item config:name="ViewLayoutBookMode" config:type="boolean">true</config:config-item> - <config:config-item config:name="ZoomFactor" config:type="short">100</config:config-item> - <config:config-item config:name="IsSelectedFrame" config:type="boolean">false</config:config-item> - </config:config-item-map-entry> - </config:config-item-map-indexed> - </config:config-item-set> - <config:config-item-set config:name="ooo:configuration-settings"> - <config:config-item config:name="ChartAutoUpdate" config:type="boolean">true</config:config-item> - <config:config-item config:name="IsLabelDocument" config:type="boolean">false</config:config-item> - <config:config-item config:name="MathBaselineAlignment" config:type="boolean">false</config:config-item> - <config:config-item config:name="OutlineLevelYieldsNumbering" config:type="boolean">true</config:config-item> - <config:config-item config:name="PrintLeftPages" config:type="boolean">true</config:config-item> - <config:config-item config:name="DoNotJustifyLinesWithManualBreak" config:type="boolean">false</config:config-item> - <config:config-item config:name="AlignTabStopPosition" config:type="boolean">true</config:config-item> - <config:config-item config:name="PrintTextPlaceholder" config:type="boolean">false</config:config-item> - <config:config-item config:name="UseOldNumbering" config:type="boolean">false</config:config-item> - <config:config-item config:name="CurrentDatabaseCommand" config:type="string"/> - <config:config-item config:name="ProtectForm" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrintBlackFonts" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrintProspectRTL" config:type="boolean">false</config:config-item> - <config:config-item config:name="SmallCapsPercentage66" config:type="boolean">true</config:config-item> - <config:config-item config:name="PrintControls" config:type="boolean">true</config:config-item> - <config:config-item config:name="CharacterCompressionType" config:type="short">0</config:config-item> - <config:config-item config:name="PrintHiddenText" config:type="boolean">false</config:config-item> - <config:config-item config:name="UseFormerTextWrapping" config:type="boolean">false</config:config-item> - <config:config-item config:name="IsKernAsianPunctuation" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrintProspect" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrintEmptyPages" config:type="boolean">true</config:config-item> - <config:config-item config:name="UseFormerObjectPositioning" config:type="boolean">false</config:config-item> - <config:config-item config:name="ConsiderTextWrapOnObjPos" config:type="boolean">false</config:config-item> - <config:config-item config:name="TableRowKeep" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrintReversed" config:type="boolean">false</config:config-item> - <config:config-item config:name="TabsRelativeToIndent" config:type="boolean">true</config:config-item> - <config:config-item config:name="PrintRightPages" config:type="boolean">true</config:config-item> - <config:config-item config:name="PrintPaperFromSetup" config:type="boolean">false</config:config-item> - <config:config-item config:name="AddFrameOffsets" config:type="boolean">false</config:config-item> - <config:config-item config:name="AddParaSpacingToTableCells" config:type="boolean">true</config:config-item> - <config:config-item config:name="UpdateFromTemplate" config:type="boolean">false</config:config-item> - <config:config-item config:name="AddExternalLeading" config:type="boolean">true</config:config-item> - <config:config-item config:name="PrintSingleJobs" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrinterIndependentLayout" config:type="string">high-resolution</config:config-item> - <config:config-item config:name="LinkUpdateMode" config:type="short">1</config:config-item> - <config:config-item config:name="PrintAnnotationMode" config:type="short">0</config:config-item> - <config:config-item config:name="UseOldPrinterMetrics" config:type="boolean">true</config:config-item> - <config:config-item config:name="RedlineProtectionKey" config:type="base64Binary"/> - <config:config-item config:name="PrinterSetup" config:type="base64Binary"/> - <config:config-item config:name="IgnoreFirstLineIndentInNumbering" config:type="boolean">false</config:config-item> - <config:config-item config:name="CollapseEmptyCellPara" config:type="boolean">true</config:config-item> - <config:config-item config:name="PrinterName" config:type="string"/> - <config:config-item config:name="InvertBorderSpacing" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrintPageBackground" config:type="boolean">true</config:config-item> - <config:config-item config:name="DoNotCaptureDrawObjsOnPage" config:type="boolean">false</config:config-item> - <config:config-item config:name="ApplyUserData" config:type="boolean">true</config:config-item> - <config:config-item config:name="TabAtLeftIndentForParagraphsInList" config:type="boolean">false</config:config-item> - <config:config-item config:name="UnxForceZeroExtLeading" config:type="boolean">true</config:config-item> - <config:config-item config:name="SaveVersionOnClose" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrintFaxName" config:type="string"/> - <config:config-item config:name="AddParaTableSpacing" config:type="boolean">true</config:config-item> - <config:config-item config:name="PrintDrawings" config:type="boolean">true</config:config-item> - <config:config-item config:name="LoadReadonly" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrintGraphics" config:type="boolean">true</config:config-item> - <config:config-item config:name="FieldAutoUpdate" config:type="boolean">true</config:config-item> - <config:config-item config:name="AllowPrintJobCancel" config:type="boolean">true</config:config-item> - <config:config-item config:name="UseFormerLineSpacing" config:type="boolean">false</config:config-item> - <config:config-item config:name="SaveGlobalDocumentLinks" config:type="boolean">false</config:config-item> - <config:config-item config:name="CurrentDatabaseDataSource" config:type="string"/> - <config:config-item config:name="IgnoreTabsAndBlanksForLineCalculation" config:type="boolean">false</config:config-item> - <config:config-item config:name="CurrentDatabaseCommandType" config:type="int">0</config:config-item> - <config:config-item config:name="DoNotResetParaAttrsForNumFont" config:type="boolean">false</config:config-item> - <config:config-item config:name="ClipAsCharacterAnchoredWriterFlyFrames" config:type="boolean">false</config:config-item> - <config:config-item config:name="PrintTables" config:type="boolean">true</config:config-item> - <config:config-item config:name="AddParaTableSpacingAtStart" config:type="boolean">true</config:config-item> - </config:config-item-set> - </office:settings> -</office:document-settings> -#+END_SRC - -#+name: output_odt_fixed_settings_xml -#+BEGIN_SRC d -┃"); - return _settings_xml; -} -#+END_SRC - -*** styles.xml :styles_xml: - -#+name: output_odt_fixed_styles_xml -#+BEGIN_SRC d -string styles_xml() { - string _styles_xml = format(q"┃<?xml version="1.0" encoding="UTF-8"?> -#+END_SRC - -#+name: output_odt_fixed_styles_xml -#+BEGIN_SRC xml -<office:document-styles xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xl="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" xmlns:rpt="http://openoffice.org/2005/report" xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:grddl="http://www.w3.org/2003/g/data-view#" xmlns:tableooo="http://openoffice.org/2009/table" xmlns:css3t="http://www.w3.org/TR/css3-text/" office:version="1.2"> - <office:font-face-decls> - <style:font-face style:name="DejaVu Sans Mono" svg:font-family="'DejaVu Sans Mono'" style:font-adornments="Book" style:font-family-generic="modern" style:font-pitch="fixed"/> - <style:font-face style:name="Nimbus Sans L" svg:font-family="'Nimbus Sans L'" style:font-pitch="variable"/> - <style:font-face style:name="Tahoma" svg:font-family="Tahoma, Lucidasans, 'Lucida Sans', 'Arial Unicode MS'" style:font-pitch="variable"/> - <style:font-face style:name="Nimbus Roman No9 L" svg:font-family="'Nimbus Roman No9 L'" style:font-family-generic="roman" style:font-pitch="variable"/> - <style:font-face style:name="Bitstream Vera Sans" svg:font-family="'Bitstream Vera Sans'" style:font-family-generic="swiss" style:font-pitch="variable"/> - </office:font-face-decls> - <office:styles> - <style:default-style style:family="graphic"> - <style:graphic-properties fo:wrap-option="wrap" draw:shadow-offset-x="0.3cm" draw:shadow-offset-y="0.3cm" draw:start-line-spacing-horizontal="0.283cm" draw:start-line-spacing-vertical="0.283cm" draw:end-line-spacing-horizontal="0.283cm" draw:end-line-spacing-vertical="0.283cm" style:flow-with-text="false"/> - <style:paragraph-properties style:text-autospace="ideograph-alpha" style:line-break="strict" style:writing-mode="lr-tb" style:font-independent-line-spacing="false"> - <style:tab-stops/> - </style:paragraph-properties> - <style:text-properties style:use-window-font-color="true" fo:font-size="12pt" fo:language="en" fo:country="US" style:font-size-asian="12pt" style:language-asian="zxx" style:country-asian="none" style:font-size-complex="12pt" style:language-complex="zxx" style:country-complex="none"/> - </style:default-style> - <style:default-style style:family="paragraph"> - <style:paragraph-properties fo:hyphenation-ladder-count="no-limit" style:text-autospace="ideograph-alpha" style:punctuation-wrap="hanging" style:line-break="strict" style:tab-stop-distance="1.251cm" style:writing-mode="page"/> - <style:text-properties style:use-window-font-color="true" style:font-name="Nimbus Roman No9 L" fo:font-size="12pt" fo:language="en" fo:country="US" style:font-name-asian="Nimbus Sans L" style:font-size-asian="12pt" style:language-asian="zxx" style:country-asian="none" style:font-name-complex="Nimbus Sans L" style:font-size-complex="12pt" style:language-complex="zxx" style:country-complex="none" fo:hyphenate="false" fo:hyphenation-remain-char-count="2" fo:hyphenation-push-char-count="2"/> - </style:default-style> - <style:default-style style:family="table"> - <style:table-properties table:border-model="collapsing"/> - </style:default-style> - <style:default-style style:family="table-row"> - <style:table-row-properties fo:keep-together="auto"/> - </style:default-style> - <style:style style:name="Standard" style:family="paragraph" style:class="text"/> - <style:style style:name="Text_body" style:display-name="Text body" style:family="paragraph" style:class="text"> - <style:paragraph-properties fo:margin-top="0cm" fo:margin-bottom="0.212cm"/> - </style:style> - <style:style style:name="P_page_break" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:break-before="page"/> - </style:style> - <style:style style:name="P_normal" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:text-align="justify" style:justify-single-word="false"/> - </style:style> - <style:style style:name="P_normal_page_new" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:break-after="page"/> - </style:style> - <style:style style:name="P_indent_0" style:display-name="Paragraph indent 0" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:text-align="justify" style:justify-single-word="false"/> - </style:style> - <style:style style:name="P_indent_1" style:display-name="Paragraph indent 1" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:margin-left="1cm" fo:margin-right="0cm" fo:text-align="justify" style:justify-single-word="false" fo:text-indent="0cm" style:auto-text-indent="false"/> - </style:style> - <style:style style:name="P_indent_2" style:display-name="Paragraph indent 2" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:margin-left="2cm" fo:margin-right="0cm" fo:text-align="justify" style:justify-single-word="false" fo:text-indent="0cm" style:auto-text-indent="false"/> - </style:style> - <style:style style:name="P_indent_3" style:display-name="Paragraph indent 3" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:margin-left="3cm" fo:margin-right="0cm" fo:text-align="justify" style:justify-single-word="false" fo:text-indent="0cm" style:auto-text-indent="false"/> - </style:style> - <style:style style:name="P_indent_4" style:display-name="Paragraph indent 4" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:margin-left="4cm" fo:margin-right="0cm" fo:text-align="justify" style:justify-single-word="false" fo:text-indent="0cm" style:auto-text-indent="false"/> - </style:style> - <style:style style:name="P_indent_5" style:display-name="Paragraph indent 5" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:margin-left="5cm" fo:margin-right="0cm" fo:text-align="justify" style:justify-single-word="false" fo:text-indent="0cm" style:auto-text-indent="false"/> - </style:style> - <style:style style:name="P_indent_6" style:display-name="Paragraph indent 6" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:margin-left="6cm" fo:margin-right="0cm" fo:text-align="justify" style:justify-single-word="false" fo:text-indent="0cm" style:auto-text-indent="false"/> - </style:style> - <style:style style:name="P_indent_7" style:display-name="Paragraph indent 7" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:margin-left="7cm" fo:margin-right="0cm" fo:text-align="justify" style:justify-single-word="false" fo:text-indent="0cm" style:auto-text-indent="false"/> - </style:style> - <style:style style:name="P_indent_8" style:display-name="Paragraph indent 8" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:margin-left="8cm" fo:margin-right="0cm" fo:text-align="justify" style:justify-single-word="false" fo:text-indent="0cm" style:auto-text-indent="false"/> - </style:style> - <style:style style:name="P_indent_9" style:display-name="Paragraph indent 9" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0.199cm" fo:margin-bottom="0.199cm" fo:line-height="150%%" fo:margin-left="9cm" fo:margin-right="0cm" fo:text-align="justify" style:justify-single-word="false" fo:text-indent="0cm" style:auto-text-indent="false"/> - </style:style> - <style:style style:name="P_h0_i0" style:display-name="Hang 0 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h0_i1" style:display-name="Hang 0 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="-1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h0_i2" style:display-name="Hang 0 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="-2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h0_i3" style:display-name="Hang 0 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="-3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h0_i4" style:display-name="Hang 0 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="-4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h0_i5" style:display-name="Hang 0 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="-5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h0_i6" style:display-name="Hang 0 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="-6cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h0_i7" style:display-name="Hang 0 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="-7cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h0_i8" style:display-name="Hang 0 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="-8cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h0_i9" style:display-name="Hang 0 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="-9cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i0" style:display-name="Hang 1 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i1" style:display-name="Hang 1 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i2" style:display-name="Hang 1 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="-1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i3" style:display-name="Hang 1 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="-2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i4" style:display-name="Hang 1 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="-3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i5" style:display-name="Hang 1 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="-4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i6" style:display-name="Hang 1 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="-5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i7" style:display-name="Hang 1 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="-6cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i8" style:display-name="Hang 1 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="-7cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h1_i9" style:display-name="Hang 1 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="-8cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i0" style:display-name="Hang 2 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i1" style:display-name="Hang 2 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i2" style:display-name="Hang 2 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i3" style:display-name="Hang 2 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="-1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i4" style:display-name="Hang 2 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="-2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i5" style:display-name="Hang 2 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="-3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i6" style:display-name="Hang 2 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="-4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i7" style:display-name="Hang 2 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="-5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i8" style:display-name="Hang 2 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="-6cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h2_i9" style:display-name="Hang 2 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="-7cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i0" style:display-name="Hang 3 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i1" style:display-name="Hang 3 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i2" style:display-name="Hang 3 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i3" style:display-name="Hang 3 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i4" style:display-name="Hang 3 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="-1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i5" style:display-name="Hang 3 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="-2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i6" style:display-name="Hang 3 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="-3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i7" style:display-name="Hang 3 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="-4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i8" style:display-name="Hang 3 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="-5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h3_i9" style:display-name="Hang 3 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="-6cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i0" style:display-name="Hang 4 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i1" style:display-name="Hang 4 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i2" style:display-name="Hang 4 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i3" style:display-name="Hang 4 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i4" style:display-name="Hang 4 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i5" style:display-name="Hang 4 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="-1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i6" style:display-name="Hang 4 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="-2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i7" style:display-name="Hang 4 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="-3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i8" style:display-name="Hang 4 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="-4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h4_i9" style:display-name="Hang 4 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="-5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i0" style:display-name="Hang 5 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i1" style:display-name="Hang 5 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i2" style:display-name="Hang 5 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i3" style:display-name="Hang 5 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i4" style:display-name="Hang 5 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i5" style:display-name="Hang 5 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i6" style:display-name="Hang 5 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="-1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i7" style:display-name="Hang 5 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="-2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i8" style:display-name="Hang 5 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="-3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h5_i9" style:display-name="Hang 5 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="-4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i0" style:display-name="Hang 6 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="6cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i1" style:display-name="Hang 6 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i2" style:display-name="Hang 6 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i3" style:display-name="Hang 6 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i4" style:display-name="Hang 6 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i5" style:display-name="Hang 6 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i6" style:display-name="Hang 6 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i7" style:display-name="Hang 6 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="-1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i8" style:display-name="Hang 6 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="-2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h6_i9" style:display-name="Hang 6 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="-3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i0" style:display-name="Hang 7 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="7cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i1" style:display-name="Hang 7 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="6cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i2" style:display-name="Hang 7 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i3" style:display-name="Hang 7 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i4" style:display-name="Hang 7 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i5" style:display-name="Hang 7 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i6" style:display-name="Hang 7 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i7" style:display-name="Hang 7 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i8" style:display-name="Hang 7 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="-1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h7_i9" style:display-name="Hang 7 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="-2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i0" style:display-name="Hang 8 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="8cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i1" style:display-name="Hang 8 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="7cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i2" style:display-name="Hang 8 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="6cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i3" style:display-name="Hang 8 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i4" style:display-name="Hang 8 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i5" style:display-name="Hang 8 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i6" style:display-name="Hang 8 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i7" style:display-name="Hang 8 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i8" style:display-name="Hang 8 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h8_i9" style:display-name="Hang 8 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="-1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i0" style:display-name="Hang 9 Indent 0" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="9cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i1" style:display-name="Hang 9 Indent 1" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="8cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i2" style:display-name="Hang 9 Indent 2" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="2cm" fo:margin-right="0cm" fo:text-indent="7cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i3" style:display-name="Hang 9 Indent 3" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="3cm" fo:margin-right="0cm" fo:text-indent="6cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i4" style:display-name="Hang 9 Indent 4" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="4cm" fo:margin-right="0cm" fo:text-indent="5cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i5" style:display-name="Hang 9 Indent 5" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="5cm" fo:margin-right="0cm" fo:text-indent="4cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i6" style:display-name="Hang 9 Indent 6" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="6cm" fo:margin-right="0cm" fo:text-indent="3cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i7" style:display-name="Hang 9 Indent 7" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="7cm" fo:margin-right="0cm" fo:text-indent="2cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i8" style:display-name="Hang 9 Indent 8" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="8cm" fo:margin-right="0cm" fo:text-indent="1cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="P_h9_i9" style:display-name="Hang 9 Indent 9" style:family="paragraph" style:parent-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-left="9cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"> - <style:tab-stops> - <style:tab-stop style:position="0cm"/> - </style:tab-stops> - </style:paragraph-properties> - </style:style> - <style:style style:name="Span_bold" style:family="text"> - <style:text-properties fo:font-weight="bold" style:font-weight-asian="bold" style:font-weight-complex="bold"/> - </style:style> - <style:style style:name="Span_italic" style:family="text"> - <style:text-properties fo:font-style="italic" style:font-style-asian="italic" style:font-style-complex="italic"/> - </style:style> - <style:style style:name="Span_underscore" style:family="text"> - <style:text-properties style:text-underline-style="solid" style:text-underline-width="auto" style:text-underline-color="font-color"/> - </style:style> - <style:style style:name="Span_superscript" style:family="text"> - <style:text-properties style:text-position="super 58%%"/> - </style:style> - <style:style style:name="Span_subscript" style:family="text"> - <style:text-properties style:text-position="sub 58%%"/> - </style:style> - <style:style style:name="Span_monospace" style:family="text"> - <style:text-properties style:font-name="DejaVu Sans Mono" fo:font-size="10pt" fo:font-weight="normal" fo:background-color="#e6e6e6"/> - </style:style> - <style:style style:name="Heading" style:family="paragraph" style:next-style-name="Text_body" style:class="text"> - <style:paragraph-properties fo:margin-top="0.423cm" fo:margin-bottom="0.212cm" fo:keep-with-next="always"/> - <style:text-properties style:font-name="Bitstream Vera Sans" fo:font-size="14pt" style:font-size-asian="14pt" style:font-name-complex="Tahoma" style:font-size-complex="14pt"/> - </style:style> - <style:style style:name="H_1" style:display-name="Heading 1" style:family="paragraph" style:next-style-name="Text_body" style:default-outline-level="1" style:class="text"> - <style:text-properties fo:font-size="120%%" fo:font-weight="bold" style:font-size-asian="120%%" style:font-weight-asian="bold" style:font-size-complex="115%%" style:font-weight-complex="bold"/> - </style:style> - <style:style style:name="H_2" style:display-name="Heading 2" style:family="paragraph" style:next-style-name="Text_body" style:default-outline-level="2" style:class="text"> - <style:text-properties fo:font-size="115%%" fo:font-weight="bold" style:font-size-asian="115%%" style:font-weight-asian="bold" style:font-size-complex="115%%" style:font-weight-complex="bold"/> - </style:style> - <style:style style:name="H_3" style:display-name="Heading 3" style:family="paragraph" style:next-style-name="Text_body" style:default-outline-level="3" style:class="text"> - <style:text-properties fo:font-size="110%%" fo:font-weight="bold" style:font-size-asian="110%%" style:font-weight-asian="bold" style:font-size-complex="115%%" style:font-weight-complex="bold"/> - </style:style> - <style:style style:name="H_4" style:display-name="Heading 4" style:family="paragraph" style:next-style-name="Text_body" style:default-outline-level="4" style:class="text"> - <style:text-properties fo:font-size="12pt" fo:font-style="italic" fo:font-weight="bold" style:font-size-asian="12pt" style:font-style-asian="italic" style:font-weight-asian="bold" style:font-size-complex="12pt" style:font-style-complex="italic" style:font-weight-complex="bold"/> - </style:style> - <style:style style:name="H_5" style:display-name="Heading 5" style:family="paragraph" style:next-style-name="Text_body" style:default-outline-level="5" style:class="text"> - <style:text-properties fo:font-size="90%%" fo:font-style="italic" fo:font-weight="bold" style:font-size-asian="90%%" style:font-style-asian="italic" style:font-weight-asian="bold" style:font-size-complex="90%%" style:font-style-complex="italic" style:font-weight-complex="bold"/> - </style:style> - <style:style style:name="H_6" style:display-name="Heading 6" style:family="paragraph" style:next-style-name="Text_body" style:default-outline-level="6" style:class="text"> - <style:text-properties fo:font-size="80%%" fo:font-style="italic" fo:font-weight="bold" style:font-size-asian="80%%" style:font-style-asian="italic" style:font-weight-asian="bold" style:font-size-complex="80%%" style:font-style-complex="italic" style:font-weight-complex="bold"/> - </style:style> - <style:style style:name="P_group" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0cm" fo:margin-bottom="0cm" fo:line-height="100%%" fo:text-align="justify" style:justify-single-word="false"/> - </style:style> - <style:style style:name="P_code" style:family="paragraph" style:parent-style-name="Standard"> - <style:paragraph-properties fo:margin-top="0cm" fo:margin-bottom="0cm" fo:line-height="100%%" fo:text-align="start" style:justify-single-word="false"/> - <style:text-properties style:font-name="DejaVu Sans Mono" fo:font-size="9pt" fo:font-weight="normal" fo:background-color="#e6e6e6"/> - </style:style> - <style:style style:name="Footnote" style:family="paragraph" style:class="extra"> - <style:paragraph-properties fo:margin-left="0.499cm" fo:margin-right="0cm" fo:text-indent="-0.499cm" style:auto-text-indent="false" text:number-lines="false" text:line-number="0"/> - <style:text-properties fo:font-size="10pt" style:font-size-asian="10pt" style:font-size-complex="10pt"/> - </style:style> - <style:style style:name="Table_Contents" style:display-name="Table Contents" style:family="paragraph" style:parent-style-name="Standard" style:class="extra"> - <style:paragraph-properties text:number-lines="false" text:line-number="0"/> - </style:style> - <style:style style:name="Footnote_symbol" style:display-name="Footnote Symbol" style:family="text"/> - <style:style style:name="Footnote_anchor" style:display-name="Footnote Anchor" style:family="text"> - <style:text-properties style:text-position="super 58%%"/> - </style:style> - <style:style style:name="Internet_link" style:display-name="Internet link" style:family="text"> - <style:text-properties fo:color="#000080" fo:language="zxx" fo:country="none" style:text-underline-style="solid" style:text-underline-width="auto" style:text-underline-color="font-color" style:language-asian="zxx" style:country-asian="none" style:language-complex="zxx" style:country-complex="none"/> - </style:style> - <style:style style:name="Graphics" style:family="graphic"> - <style:graphic-properties text:anchor-type="paragraph" svg:x="0cm" svg:y="0cm" style:wrap="dynamic" style:number-wrapped-paragraphs="no-limit" style:wrap-contour="false" style:vertical-pos="top" style:vertical-rel="paragraph" style:horizontal-pos="center" style:horizontal-rel="paragraph"/> - </style:style> - <text:outline-style style:name="Outline"> - <text:outline-level-style text:level="1" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - <text:outline-level-style text:level="2" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - <text:outline-level-style text:level="3" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - <text:outline-level-style text:level="4" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - <text:outline-level-style text:level="5" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - <text:outline-level-style text:level="6" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - <text:outline-level-style text:level="7" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - <text:outline-level-style text:level="8" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - <text:outline-level-style text:level="9" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - <text:outline-level-style text:level="10" style:num-format=""> - <style:list-level-properties text:min-label-distance="0.381cm"/> - </text:outline-level-style> - </text:outline-style> - <text:notes-configuration text:note-class="footnote" text:citation-style-name="Footnote_symbol" text:citation-body-style-name="Footnote_anchor" style:num-format="1" text:start-value="0" text:footnotes-position="page" text:start-numbering-at="document"/> - <text:notes-configuration text:note-class="endnote" style:num-format="i" text:start-value="0"/> - <text:linenumbering-configuration text:number-lines="false" text:offset="0.499cm" style:num-format="1" text:number-position="left" text:increment="5"/> - <style:style style:name="fr1" style:family="graphic" style:parent-style-name="Graphics"> - <style:graphic-properties style:wrap="none" style:horizontal-pos="left" style:horizontal-rel="paragraph" style:mirror="none" fo:clip="rect(0cm 0cm 0cm 0cm)" draw:luminance="0%%" draw:contrast="0%%" draw:red="0%%" draw:green="0%%" draw:blue="0%%" draw:gamma="100%%" draw:color-inversion="false" draw:image-opacity="100%%" draw:color-mode="standard"/> - </style:style> - <style:style style:name="gr1" style:family="graphic"> - <style:graphic-properties draw:stroke="none" draw:fill="none" draw:textarea-horizontal-align="center" draw:textarea-vertical-align="middle" draw:color-mode="standard" draw:luminance="0%%" draw:contrast="0%%" draw:gamma="100%%" draw:red="0%%" draw:green="0%%" draw:blue="0%%" fo:clip="rect(0cm 0cm 0cm 0cm)" draw:image-opacity="100%%" style:mirror="none" style:run-through="background" style:wrap="none" style:vertical-pos="top" style:vertical-rel="baseline" style:horizontal-pos="left" style:horizontal-rel="paragraph" draw:wrap-influence-on-position="once-concurrent" style:flow-with-text="false"/> - </style:style> - <style:style style:name="gr2" style:family="graphic"> - <style:graphic-properties draw:stroke="none" draw:fill="none" draw:textarea-horizontal-align="center" draw:textarea-vertical-align="middle" draw:color-mode="standard" draw:luminance="0%%" draw:contrast="0%%" draw:gamma="100%%" draw:red="0%%" draw:green="0%%" draw:blue="0%%" fo:clip="rect(0cm 0cm 0cm 0cm)" draw:image-opacity="100%%" style:mirror="none" style:run-through="background" style:wrap="none" style:vertical-pos="middle" style:vertical-rel="baseline" style:horizontal-pos="left" style:horizontal-rel="paragraph" draw:wrap-influence-on-position="once-concurrent" style:flow-with-text="false"/> - </style:style> - </office:styles> - <office:automatic-styles> - <style:page-layout style:name="Mpm1"> - <style:page-layout-properties fo:page-width="20.999cm" fo:page-height="29.699cm" style:num-format="1" style:print-orientation="portrait" fo:margin-top="2cm" fo:margin-bottom="2cm" fo:margin-left="2cm" fo:margin-right="2cm" style:writing-mode="lr-tb" style:footnote-max-height="0cm"> - <style:footnote-sep style:width="0.018cm" style:distance-before-sep="0.101cm" style:distance-after-sep="0.101cm" style:line-style="none" style:adjustment="left" style:rel-width="25%%" style:color="#000000"/> - </style:page-layout-properties> - <style:header-style/> - <style:footer-style/> - </style:page-layout> - </office:automatic-styles> - <office:master-styles> - <style:master-page style:name="Standard" style:page-layout-name="Mpm1"/> - </office:master-styles> -</office:document-styles> -#+END_SRC - -#+name: output_odt_fixed_styles_xml -#+BEGIN_SRC d -┃"); - return _styles_xml; -} -#+END_SRC - -** moving parts -*** ↻ content.xml TODO :content_xml: -**** content head -***** head open - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d -string odt_head(I)(I doc_matters) { - string _has_tables = format(q"┃ -#+END_SRC - -***** if table include within head - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC xml - <style:style style:name="Table1" style:family="table"> - <style:table-properties style:width="16.999cm" table:align="margins"/> - </style:style> - <style:style style:name="Table1.A" style:family="table-column"> - <style:table-column-properties style:column-width="16.999cm" style:rel-column-width="65535*"/> - </style:style> - <style:style style:name="Table1.B" style:family="table-column"> - <style:table-column-properties style:column-width="8.499cm" style:rel-column-width="32767*"/> - </style:style> - <style:style style:name="Table1.C" style:family="table-column"> - <style:table-column-properties style:column-width="5.666cm" style:rel-column-width="21845*"/> - </style:style> - <style:style style:name="Table1.D" style:family="table-column"> - <style:table-column-properties style:column-width="4.349cm" style:rel-column-width="16383*"/> - </style:style> - <style:style style:name="Table1.E" style:family="table-column"> - <style:table-column-properties style:column-width="3.399cm" style:rel-column-width="13107*"/> - </style:style> - <style:style style:name="Table1.F" style:family="table-column"> - <style:table-column-properties style:column-width="2.833cm" style:rel-column-width="10922*"/> - </style:style> - <style:style style:name="Table1.G" style:family="table-column"> - <style:table-column-properties style:column-width="2.428cm" style:rel-column-width="9362*"/> - </style:style> - <style:style style:name="Table1.H" style:family="table-column"> - <style:table-column-properties style:column-width="2.124cm" style:rel-column-width="8191*"/> - </style:style> - <style:style style:name="Table2" style:family="table"> - <style:table-properties style:width="16.999cm" table:align="margins"/> - </style:style> - <style:style style:name="Table2.A" style:family="table-column"> - <style:table-column-properties style:column-width="16.999cm" style:rel-column-width="65535*"/> - </style:style> - <style:style style:name="Table2.B" style:family="table-column"> - <style:table-column-properties style:column-width="8.499cm" style:rel-column-width="32767*"/> - </style:style> - <style:style style:name="Table2.C" style:family="table-column"> - <style:table-column-properties style:column-width="5.666cm" style:rel-column-width="21845*"/> - </style:style> - <style:style style:name="Table2.D" style:family="table-column"> - <style:table-column-properties style:column-width="4.349cm" style:rel-column-width="16383*"/> - </style:style> - <style:style style:name="Table2.E" style:family="table-column"> - <style:table-column-properties style:column-width="3.999cm" style:rel-column-width="13107*"/> - </style:style> - <style:style style:name="Table2.F" style:family="table-column"> - <style:table-column-properties style:column-width="2.833cm" style:rel-column-width="10922*"/> - </style:style> - <style:style style:name="Table2.G" style:family="table-column"> - <style:table-column-properties style:column-width="2.428cm" style:rel-column-width="9362*"/> - </style:style> - <style:style style:name="Table2.H" style:family="table-column"> - <style:table-column-properties style:column-width="2.124cm" style:rel-column-width="8191*"/> - </style:style> - <style:style style:name="Table2.I" style:family="table-column"> - <style:table-column-properties style:column-width="1.8887cm" style:rel-column-width="7281*"/> - </style:style> - <style:style style:name="Table2.J" style:family="table-column"> - <style:table-column-properties style:column-width="1.6999cm" style:rel-column-width="6553*"/> - </style:style> - <style:style style:name="Table2.K" style:family="table-column"> - <style:table-column-properties style:column-width="1.5453cm" style:rel-column-width="5957*"/> - </style:style> - <style:style style:name="Table2.L" style:family="table-column"> - <style:table-column-properties style:column-width="1.416cm" style:rel-column-width="5461*"/> - </style:style> - <style:style style:name="Table2.M" style:family="table-column"> - <style:table-column-properties style:column-width="1.307" style:rel-column-width="5041*"/> - </style:style> - <style:style style:name="Table2.N" style:family="table-column"> - <style:table-column-properties style:column-width="1.214cm" style:rel-column-width="4681*"/> - </style:style> -#+END_SRC - -***** head - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d -┃",); - string _odt_head = format(q"┃<?xml version="1.0" encoding="UTF-8"?> -#+END_SRC - -***** head xml - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC xml -<office:document-content xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xl="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rpt="http://openoffice.org/2005/report" xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:grddl="http://www.w3.org/2003/g/data-view#" xmlns:tableooo="http://openoffice.org/2009/table" xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0" xmlns:css3t="http://www.w3.org/TR/css3-text/" office:version="1.2"> -<office:scripts/> -<office:font-face-decls> -<style:font-face style:name="DejaVu Sans Mono" svg:font-family="'DejaVu Sans Mono'" style:font-adornments="Book" style:font-family-generic="modern" style:font-pitch="fixed"/> -<style:font-face style:name="Inconsolata" svg:font-family="Inconsolata" style:font-adornments="Regular" style:font-pitch="fixed"/> -<style:font-face style:name="Liberation Mono" svg:font-family="'Liberation Mono'" style:font-adornments="Regular" style:font-family-generic="modern" style:font-pitch="fixed"/> -<style:font-face style:name="DejaVu Sans" svg:font-family="'DejaVu Sans'" style:font-adornments="ExtraLight" style:font-family-generic="swiss" style:font-pitch="variable"/> -<style:font-face style:name="Nimbus Sans L" svg:font-family="'Nimbus Sans L'" style:font-pitch="variable"/> -<style:font-face style:name="Tahoma" svg:font-family="Tahoma, Lucidasans, 'Lucida Sans', 'Arial Unicode MS'" style:font-pitch="variable"/> -<style:font-face style:name="Nimbus Roman No9 L" svg:font-family="'Nimbus Roman No9 L'" style:font-family-generic="roman" style:font-pitch="variable"/> -<style:font-face style:name="Bitstream Vera Sans" svg:font-family="'Bitstream Vera Sans'" style:font-family-generic="swiss" style:font-pitch="variable"/> -</office:font-face-decls> -<office:automatic-styles> - %s - <style:style style:name="P_table_cell" style:family="paragraph" style:parent-style-name="Table_Contents"> - <style:paragraph-properties fo:text-align="justify" style:justify-single-word="false"/> - </style:style> -</office:automatic-styles> -<office:body> - <office:text text:use-soft-page-breaks="true"> - <office:forms form:automatic-focus="false" form:apply-design-mode="false"/> - <text:sequence-decls> - <text:sequence-decl text:display-outline-level="0" text:name="Illustration"/> - <text:sequence-decl text:display-outline-level="0" text:name="Table"/> - <text:sequence-decl text:display-outline-level="0" text:name="Text"/> - <text:sequence-decl text:display-outline-level="0" text:name="Drawing"/> - </text:sequence-decls> -#+END_SRC - -***** head close - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d -┃", - (doc_matters.has.tables > 0) ? _has_tables : "", -); - return _odt_head; -} -#+END_SRC - -**** ↻ content body -***** body open - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d -string odt_body(D,I)( - const D doc_abstraction, - I doc_matters, -) { - mixin formatODT; - auto odt_format = formatODT(); - string delimit = ""; - string doc_odt = ""; - string _txt = ""; -#+END_SRC - -***** ↻ the loop & outer switch (sections & objects) format output - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d - foreach (part; doc_matters.has.keys_seq.scroll) { - foreach (obj; doc_abstraction[part]) { - switch (obj.metainfo.is_of_part) { -#+END_SRC - -****** frontmatter - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d - case "frontmatter": assert(part == "head" || "toc"); - switch (obj.metainfo.is_of_type) { - case "para": - switch (obj.metainfo.is_a) { - case "heading": - _txt = delimit ~ odt_format.heading(obj, doc_matters); - goto default; - case "toc": - _txt = odt_format.para(obj, doc_matters); - goto default; - default: - doc_odt ~= _txt; - _txt = ""; - break; - } - break; - default: break; - } - break; -#+END_SRC - -****** body - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d - case "body": assert(part == "body" || "head"); // surprise - switch (obj.metainfo.is_of_type) { - case "para": - switch (obj.metainfo.is_a) { - case "heading": - _txt = delimit ~ odt_format.heading(obj, doc_matters); - goto default; - case "para": - _txt = odt_format.para(obj, doc_matters); - goto default; - default: - doc_odt ~= _txt; - _txt = ""; - break; - } - break; - case "block": - switch (obj.metainfo.is_a) { - case "quote": - _txt = odt_format.quote(obj, doc_matters); - goto default; - case "group": - _txt = odt_format.group(obj, doc_matters); - goto default; - case "block": - _txt = odt_format.block(obj, doc_matters); - goto default; - case "verse": - _txt = odt_format.verse(obj, doc_matters); - goto default; - case "code": - _txt = odt_format.code(obj, doc_matters); - goto default; - case "table": - _txt = odt_format.table(obj, doc_matters); - goto default; - default: - doc_odt ~= _txt; - _txt = ""; - break; - } - break; - default: break; - } - break; -#+END_SRC - -****** backmatter - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d - case "backmatter": - assert(part == "endnotes" || "glossary" || "bibliography" || "bookindex" || "blurb" || "tail"); - switch (obj.metainfo.is_of_type) { - case "para": - switch (obj.metainfo.is_a) { - case "heading": - _txt = delimit ~ odt_format.heading(obj, doc_matters); - goto default; - case "endnote": assert(part == "endnotes"); - _txt = odt_format.para(obj, doc_matters); - goto default; - case "glossary": assert(part == "glossary"); - _txt = odt_format.para(obj, doc_matters); - goto default; - case "bibliography": assert(part == "bibliography"); - _txt = odt_format.para(obj, doc_matters); - goto default; - case "bookindex": assert(part == "bookindex"); - _txt = odt_format.para(obj, doc_matters); - goto default; - case "blurb": assert(part == "blurb"); - _txt = odt_format.para(obj, doc_matters); - goto default; - default: - doc_odt ~= _txt; - _txt = ""; - break; - } - break; - default: break; - } - break; - case "comment": - break; - default: - { /+ debug +/ - if (doc_matters.opt.action.debug_do - && doc_matters.opt.action.verbose) { - writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_part); - writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a); - writeln(__FILE__, ":", __LINE__, ": ", obj.text); - } - } - break; -#+END_SRC - -***** closings & post loop - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d - } - } - } - return doc_odt; -} -#+END_SRC - -**** content book index? - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d -#+END_SRC - -**** content tail - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d -string odt_tail() { - string _odt_tail = format(q"┃<text:p text:style-name="P_normal">DocReform: <<text:a xl:type="simple" xl:href="http://www.doc_reform.org">www.doc_reform.org</text:a>> and <<text:a xl:type="simple" xl:href="http://www.sisudoc.org">www.sisudoc.org</text:a>></text:p> -</office:text></office:body></office:document-content>┃",); - return _odt_tail; -} -#+END_SRC - -**** hub - -#+name: output_odt_variable_content_xml -#+BEGIN_SRC d -string content_xml(D,I)( - const D doc_abstraction, - I doc_matters, -) { - string _content_xml; - string break_line = (doc_matters.opt.action.debug_do) ? "\n" : ""; - string odt_break_page = format(q"┃<text:p text:style-name="P_normal_page_new"/>┃",); - string br_pg = format(q"┃<text:p text:style-name="P_normal_page_new"/>┃",); - _content_xml ~= odt_head(doc_matters); - _content_xml ~= odt_body(doc_abstraction, doc_matters); - _content_xml ~= odt_tail; - return _content_xml; -} -#+END_SRC - -*** manifest.xml (images list changes) :manifest_xml: - - META-INF/manifest.xml - - image list changes - -#+name: output_odt_variable_manifest_xml -#+BEGIN_SRC d -string manifest_xml(M)( - auto ref M doc_matters, -) { - string _bullet = format(q"┃<manifest:file-entry manifest:media-type="" manifest:full-path="Pictures/bullet_09.png"/>┃"); - string[] _images = [ _bullet ]; - foreach (image; doc_matters.srcs.image_list) { - _images ~= format(q"┃ <manifest:file-entry manifest:media-type="" manifest:full-path="Pictures/%s"/>┃", image); - } - string _manifest_xml = format(q"┃<?xml version="1.0" encoding="UTF-8"?> -#+END_SRC - -#+name: output_odt_variable_manifest_xml -#+BEGIN_SRC xml -<manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0" manifest:version="1.2"> - <manifest:file-entry manifest:media-type="application/vnd.oasis.opendocument.text" manifest:version="1.2" manifest:full-path="/"/> - <manifest:file-entry manifest:media-type="text/xml" manifest:full-path="styles.xml"/> - <manifest:file-entry manifest:media-type="text/xml" manifest:full-path="content.xml"/> - %s - <manifest:file-entry manifest:media-type="text/xml" manifest:full-path="meta.xml"/> - <manifest:file-entry manifest:media-type="application/rdf+xml" manifest:full-path="manifest.rdf"/> - <manifest:file-entry manifest:media-type="application/binary" manifest:full-path="layout-cache"/> - <manifest:file-entry manifest:media-type="text/xml" manifest:full-path="settings.xml"/> -</manifest:manifest> -#+END_SRC - -#+name: output_odt_variable_manifest_xml -#+BEGIN_SRC d -┃", -_images.join("\n"), -); - return _manifest_xml; -} -#+END_SRC - -*** meta.xml (time stamp) :meta_xml: - -#+name: output_odt_variable_meta_xml -#+BEGIN_SRC d -string meta_xml(M)( - auto ref M doc_matters, -) { - /+ (meta_xml includes output time-stamp) +/ - string _meta_xml = format(q"┃<?xml version="1.0" encoding="UTF-8"?> -#+END_SRC - -#+name: output_odt_variable_meta_xml -#+BEGIN_SRC xml -<office:document-meta xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:xl="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:grddl="http://www.w3.org/2003/g/data-view#" office:version="1.2"> - <office:meta> - <meta:generator>%s</meta:generator> - <meta:creation-date>%s</meta:creation-date> - <dc:date>%s</dc:date> - <dc:language>en-US</dc:language> - </office:meta> -</office:document-meta> -#+END_SRC - -#+name: output_odt_variable_meta_xml -#+BEGIN_SRC d -┃", -doc_matters.generator_program.name_and_version, -doc_matters.generated_time, -doc_matters.generated_time, -); - return _meta_xml; -} -#+END_SRC - -*** copy images :images: - -#+name: output_odt_variable_copy_odt_images -#+BEGIN_SRC d -void images_cp(M)( - auto ref M doc_matters, -) { - { /+ (copy odt images) +/ - auto pth_odt = DocReformPathsODT!()(doc_matters); - foreach (image; doc_matters.srcs.image_list) { - auto fn_src_in = doc_matters.src.image_dir_path ~ "/" ~ image; - auto fn_src_out_file = pth_odt.image_dir("fs") ~ "/" ~ image; - auto fn_src_out_zip = pth_odt.image_dir("zip") ~ "/" ~ image; - if (exists(fn_src_in)) { - if (doc_matters.opt.action.debug_do) { - if (doc_matters.opt.action.debug_do) { - fn_src_in.copy(fn_src_out_file); - } - } - } - } - } - // return 0; -} -#+END_SRC |