Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Ruby FFI bindings for Hunspell.
Ruby
branch: master

Merge pull request #11 from forward3d/master

Include directories with dictionaries for brew-installed hunspell by default
latest commit 0656a80e72
@postmodern authored
Failed to load latest commit information.
lib/ffi Include directories with dictionaries for brew-installed hunspell by …
spec Officially require rspec 3.x.
.gemtest Opting into `gem test`.
.gitignore Initial commit.
.rspec Upgraded to rspec 2.0.0.
.travis.yml Enable 2.0.0 and jruby-19mode.
.yardopts Initial commit.
ChangeLog.md Updated the ChangeLog for 0.3.0.
LICENSE.txt Updated the copyright date.
README.md Link to the framed documentation.
Rakefile
ffi-hunspell.gemspec Updated the gemspec.
gemspec.yml Officially require rspec 3.x.

README.md

ffi-hunspell

Build Status

Description

Ruby FFI bindings for Hunspell.

Examples

Open a dictionary:

require 'ffi/hunspell'

FFI::Hunspell.dict do |dict|
  # ...
end

FFI::Hunspell.dict('en_GB') do |dict|
  # ...
end

dict = FFI::Hunspell.dict('en_GB')
# ...
dict.close

Check if a word is valid:

dict.check?('dog')
# => true

dict.check?('d0g')
# => false

Find the stems of a word:

dict.stem('dogs')
# => ["dog"]

Suggest alternate spellings for a word:

dict.suggest('arbitrage')
# => ["arbitrage", "arbitrages", "arbitrager", "arbitraged", "arbitrate"]

Requirements

Install

$ gem install ffi-hunspell

License

Copyright (c) 2010-2013 Hal Brodigan

See {file:LICENSE.txt} for license information.

Something went wrong with that request. Please try again.