Class: Malt::Format::Textile

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

Instance Attribute Summary

Attributes inherited from Abstract

#options

Instance Method Summary collapse

Methods inherited from Abstract

#default, #engine, engine, extensions, #extensions, #file, file_extension, #file_read, #file_type, #parse_type_from_data, #refile, register, #render, #render_into, #rendering_parameters, #scope_vs_data, #subtype, #text, #to, #to_default, #to_s, #type, #with, #with!

Instance Method Details

#html(*data, &content) ⇒ Object



27
28
29
# File 'lib/malt/formats/textile.rb', line 27

def html(*data, &content)
  render_into(:html, *data, &content)
end

#textileObject Also known as: tt



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

def textile(*)
  text
end

#to_htmlObject



32
33
34
35
# File 'lib/malt/formats/textile.rb', line 32

def to_html(*)
  opts = options.merge(:text=>html, :file=>refile(:html), :type=>:html)
  HTML.new(opts)
end

#to_textileObject Also known as: to_tt



20
21
22
# File 'lib/malt/formats/textile.rb', line 20

def to_textile(*)
  self
end