From ef60325fc646625ace71030b7ed2b55ff911a9f0 Mon Sep 17 00:00:00 2001 From: Giuseppe Bilotta Date: Tue, 18 Sep 2007 13:24:55 +0000 Subject: extends: String#ircify_html now has an option to obey non-breakable spaces or turn them into normal spaces This option is used e.g. by the dict plugin to reduce the excessive whitespace in oxford entries. --- data/rbot/plugins/dict.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'data/rbot') diff --git a/data/rbot/plugins/dict.rb b/data/rbot/plugins/dict.rb index 6d35bd65..ca5f2588 100644 --- a/data/rbot/plugins/dict.rb +++ b/data/rbot/plugins/dict.rb @@ -115,7 +115,7 @@ class DictPlugin < Plugin if h and h.match(%r!

#{word}(?:1)?

!) m.reply("#{word} : #{url}") unless justcheck defn = $' - m.reply("#{Bold}%s#{Bold}: %s" % [word, defn.ircify_html], :overlong => :truncate) + m.reply("#{Bold}%s#{Bold}: %s" % [word, defn.ircify_html(:nbsp => :space)], :overlong => :truncate) return true end } -- cgit v1.2.3