Method: IsoDoc::PresentationXMLConvert#toc_title_insert_pt
- Defined in:
- lib/isodoc/presentation_function/title.rb
#toc_title_insert_pt(docxml) ⇒ Object
98 99 100 101 102 103 104 105 |
# File 'lib/isodoc/presentation_function/title.rb', line 98 def toc_title_insert_pt(docxml) ins = docxml.at(ns("//preface")) || docxml.at(ns("//sections | //annex | //bibliography")) &.before("<preface> </preface>") &.previous_element or return nil ins.children.empty? and ins << " " ins.children.first end |