Sha256: 3a5c799894ef006dccfd0844309b8e5c9838127b46d6f21f1b9a8655e6ad3bda

Contents?: true

Size: 415 Bytes

Versions: 20

Compression:

Stored size: 415 Bytes

Contents

# If RedCloth is installed, then configure the textile filter
if try_require('redcloth', 'RedCloth')

  Webby::Filters.register :textile do |input|
    RedCloth.new(input, %w(no_span_caps)).to_html
  end

# Otherwise raise an error if the user tries to use textile
else
  Webby::Filters.register :textile do |input|
    raise Webby::Error, "'RedCloth' must be installed to use the textile filter"
  end
end

# EOF

Version data entries

20 entries across 20 versions & 9 rubygems

Version Path
Shazburg-webby-0.9.0 lib/webby/filters/textile.rb
TwP-webby-0.9.0 lib/webby/filters/textile.rb
TwP-webby-0.9.1 lib/webby/filters/textile.rb
TwP-webby-0.9.2 lib/webby/filters/textile.rb
TwP-webby-0.9.3 lib/webby/filters/textile.rb
TwP-webby-0.9.4.1 lib/webby/filters/textile.rb
TwP-webby-0.9.4 lib/webby/filters/textile.rb
blowmage-webby-0.9.4.1 lib/webby/filters/textile.rb
dysinger-webby-0.9.4 lib/webby/filters/textile.rb
francois-webby-0.9.4.1 lib/webby/filters/textile.rb
giraffesoft-webby-0.9.5 lib/webby/filters/textile.rb
mikker-webby-0.9.4 lib/webby/filters/textile.rb
jamesgolick-webby-0.9.5 lib/webby/filters/textile.rb
webby-0.9.1 lib/webby/filters/textile.rb
webby-0.9.3 lib/webby/filters/textile.rb
webby-0.9.3-x86-mswin32 lib/webby/filters/textile.rb
webby-0.9.2 lib/webby/filters/textile.rb
webby-0.9.0 lib/webby/filters/textile.rb
webby-0.9.4 lib/webby/filters/textile.rb
webby-0.9.4-x86-mswin32 lib/webby/filters/textile.rb