Method: IsoDoc::HtmlFunction::Html#resize_images
- Defined in:
- lib/isodoc/html_function/postprocess.rb
#resize_images(docxml) ⇒ Object
83 84 85 86 87 88 89 90 91 |
# File 'lib/isodoc/html_function/postprocess.rb', line 83 def resize_images(docxml) docxml.xpath("//*[local-name() = 'img' or local-name() = 'svg']") .each do |i| loc = image_localfile(i) or next i["width"], i["height"] = Vectory::ImageResize.new .call(i, loc, @maxheight, @maxwidth) end docxml end |