Method: IsoDoc::WordFunction::Postprocess#word_cover

Defined in:
lib/isodoc/word_function/postprocess_cover.rb

#word_cover(docxml) ⇒ Object



20
21
22
23
24
25
26
# File 'lib/isodoc/word_function/postprocess_cover.rb', line 20

def word_cover(docxml)
  ins = docxml.at('//div[@class="WordSection1"]') or return
  cover = File.read(@wordcoverpage, encoding: "UTF-8")
  cover = populate_template(cover, :word)
  coverxml = to_word_xhtml_fragment(cover)
  ins.add_first_child coverxml.to_xml(encoding: "US-ASCII")
end