Method: IsoDoc::PresentationXMLConvert#svg_to_emf
- Defined in:
- lib/isodoc/presentation_function/image.rb
#svg_to_emf(node) ⇒ Object
174 175 176 177 178 179 180 181 182 |
# File 'lib/isodoc/presentation_function/image.rb', line 174 def svg_to_emf(node) @output_formats[:doc] or return svg_impose_height_attr(node) node.elements&.first&.name == "svg" || %r{^data:}.match?(node["src"]) and return svg_to_emf_from_node(node) target_path = imgfile_suffix(node["src"], "emf") File.exist?(target_path) and return target_path svg_to_emf_from_node(node, target_path) end |