Class: Malt::Formats::Latex

Inherits:
Abstract show all
Defined in:
lib/malt/formats/latex.rb

Instance Attribute Summary

Attributes inherited from Abstract

#options

Instance Method Summary collapse

Methods inherited from Abstract

engine, #engine, extensions, #extensions, #file, #parse_type_and_data, #refile, register, #render, #subtype, #text, #to, #to_s, #type

Instance Method Details

#latexObject



12
13
14
# File 'lib/malt/formats/latex.rb', line 12

def latex
  text
end

#pdfObject

TODO



22
23
24
# File 'lib/malt/formats/latex.rb', line 22

def pdf
  raise "not implemented yet"
end

#to_latexObject



17
18
19
# File 'lib/malt/formats/latex.rb', line 17

def to_latex
  self
end

#to_pdfObject

TODO



27
28
29
30
31
# File 'lib/malt/formats/latex.rb', line 27

def to_pdf
  text = pdf
  opts = options.merge(:text=>text, :file=>refile(:pdf), :type=>:pdf)
  PDF.new(opts)
end