class Metanorma::MPFA::Processor

Public Class Methods

new() click to toggle source
# File lib/metanorma/mpfa/processor.rb, line 7
def initialize
  @short = [:mpfd, :mpfa]
  @input_format = :asciidoc
  @asciidoctor_backend = :mpfa
end

Public Instance Methods

fonts_manifest() click to toggle source
# File lib/metanorma/mpfa/processor.rb, line 21
def fonts_manifest
  {
    "Arial" => nil,
    "Source Han Sans" => nil,
    "STIX Two Math" => nil,
  }
end
output(isodoc_node, inname, outname, format, options={}) click to toggle source
Calls superclass method
# File lib/metanorma/mpfa/processor.rb, line 33
def output(isodoc_node, inname, outname, format, options={})
  case format
  when :html
    IsoDoc::MPFA::HtmlConvert.new(options).convert(inname, isodoc_node, nil, outname)
  when :doc
    IsoDoc::MPFA::WordConvert.new(options).convert(inname, isodoc_node, nil, outname)
  when :pdf
    IsoDoc::MPFA::PdfConvert.new(options).convert(inname, isodoc_node, nil, outname)
  when :presentation
    IsoDoc::MPFA::PresentationXMLConvert.new(options).convert(inname, isodoc_node, nil, outname)
  else
    super
  end
end
output_formats() click to toggle source
Calls superclass method
# File lib/metanorma/mpfa/processor.rb, line 13
def output_formats
  super.merge(
    html: "html",
    doc: "doc",
    pdf: "pdf"
  )
end
version() click to toggle source
# File lib/metanorma/mpfa/processor.rb, line 29
def version
  "Metanorma::MPFA #{Metanorma::MPFA::VERSION}"
end