Class: HTML::Pipeline::TextileFilter
- Inherits:
-
TextFilter
- Object
- Filter
- TextFilter
- HTML::Pipeline::TextileFilter
- Defined in:
- lib/html/pipeline/textile_filter.rb
Overview
HTML Filter that converts Textile text into HTML and converts into a DocumentFragment. This is different from most filters in that it can take a non-HTML as input. It must be used as the first filter in a pipeline.
Context options:
:autolink => false Disable autolinking URLs
This filter does not write any additional information to the context hash.
NOTE This filter is provided for really old comments only. It probably shouldn’t be used for anything new.
Instance Attribute Summary
Attributes inherited from TextFilter
Attributes inherited from Filter
Instance Method Summary collapse
-
#call ⇒ Object
Convert Textile to HTML and convert into a DocumentFragment.
Methods inherited from TextFilter
Methods inherited from Filter
#base_url, call, #current_user, #doc, #has_ancestor?, #html, #initialize, #needs, #parse_html, #repository, #search_text_nodes, to_document, to_html, #validate
Constructor Details
This class inherits a constructor from HTML::Pipeline::TextFilter
Instance Method Details
#call ⇒ Object
Convert Textile to HTML and convert into a DocumentFragment.
22 23 24 |
# File 'lib/html/pipeline/textile_filter.rb', line 22 def call RedCloth.new(@text).to_html end |