Method: IsoDoc::WordFunction::Postprocess#word_cover

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

#word_cover(docxml) ⇒ Object



8
9
10
11
12
13
14
# File 'lib/isodoc/word_function/postprocess_cover.rb', line 8

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