summaryrefslogtreecommitdiff
path: root/lib/coderay
diff options
context:
space:
mode:
authorKornelius Kalnbach <murphy@rubychan.de>2013-10-22 03:00:46 +0200
committerKornelius Kalnbach <murphy@rubychan.de>2013-10-22 03:00:46 +0200
commitd21348f85036273fd8f370a6a850e1c0440c6b02 (patch)
tree70df2af6dc78faae7075d6550248dea0533574ab /lib/coderay
parentb09e97b08c3c073e79159ff09f6a7e0779fcfd2e (diff)
downloadcoderay-d21348f85036273fd8f370a6a850e1c0440c6b02.tar.gz
tweaks
Diffstat (limited to 'lib/coderay')
-rw-r--r--lib/coderay/encoders/html.rb2
-rw-r--r--lib/coderay/scanners.rb4
-rw-r--r--lib/coderay/styles.rb4
-rw-r--r--lib/coderay/tokens.rb2
4 files changed, 10 insertions, 2 deletions
diff --git a/lib/coderay/encoders/html.rb b/lib/coderay/encoders/html.rb
index 093df08..d2ebb5a 100644
--- a/lib/coderay/encoders/html.rb
+++ b/lib/coderay/encoders/html.rb
@@ -289,7 +289,7 @@ module Encoders
Hash.new do |h, kinds|
begin
css_class = css_class_for_kinds(kinds)
- title = Html.token_path_to_hint hint, kinds if hint
+ title = HTML.token_path_to_hint hint, kinds if hint
if css_class || title
if method == :style
diff --git a/lib/coderay/scanners.rb b/lib/coderay/scanners.rb
index f824f50..8d8156f 100644
--- a/lib/coderay/scanners.rb
+++ b/lib/coderay/scanners.rb
@@ -16,8 +16,12 @@ module CodeRay
#
# See PluginHost.
module Scanners
+
extend PluginHost
plugin_path File.dirname(__FILE__), 'scanners'
+
+ autoload :Encoder, CodeRay.coderay_path('scanners', 'scanner')
+
end
end
diff --git a/lib/coderay/styles.rb b/lib/coderay/styles.rb
index a7c43e4..d8fa8aa 100644
--- a/lib/coderay/styles.rb
+++ b/lib/coderay/styles.rb
@@ -4,8 +4,12 @@ module CodeRay
#
# See Plugin.
module Styles
+
extend PluginHost
plugin_path File.dirname(__FILE__), 'styles'
+
+ autoload :Style, CodeRay.coderay_path('styles', 'style')
+
end
end
diff --git a/lib/coderay/tokens.rb b/lib/coderay/tokens.rb
index aeb3b79..e7bffce 100644
--- a/lib/coderay/tokens.rb
+++ b/lib/coderay/tokens.rb
@@ -67,7 +67,7 @@ module CodeRay
def method_missing meth, options = {}
encode meth, options
rescue PluginHost::PluginNotFound
- raise
+ super
end
# Split the tokens into parts of the given +sizes+.