class TinymceSpellcheck::Engines::Raspell
Public Class Methods
new(options = {})
click to toggle source
# File lib/tinymce_spellcheck/engines/raspell.rb, line 6 def initialize(options = {}) end
Public Instance Methods
check_words(lang, words)
click to toggle source
# File lib/tinymce_spellcheck/engines/raspell.rb, line 9 def check_words(lang, words) @speller = Aspell.new(lang) @speller.suggestion_mode = Aspell::NORMAL misspelled = [] words.each do |word| misspelled << word unless @speller.check(word) end misspelled end
get_suggestions(lang, word)
click to toggle source
# File lib/tinymce_spellcheck/engines/raspell.rb, line 20 def get_suggestions(lang, word) @speller = Aspell.new(lang) @speller.suggestion_mode = Aspell::NORMAL @speller.suggest(word) end