please?
This commit is contained in:
parent
af2382aea5
commit
033dd8af12
1 changed files with 4 additions and 2 deletions
|
@ -1,5 +1,7 @@
|
||||||
import enchant
|
|
||||||
from util import hook
|
from util import hook
|
||||||
|
from enchant.checker import SpellChecker
|
||||||
|
|
||||||
|
import enchant
|
||||||
|
|
||||||
locale = "en_US"
|
locale = "en_US"
|
||||||
|
|
||||||
|
@ -12,7 +14,7 @@ def spell(inp):
|
||||||
return "Could not find dictionary: {}".format(locale)
|
return "Could not find dictionary: {}".format(locale)
|
||||||
|
|
||||||
if len(inp.split(" ")) > 1:
|
if len(inp.split(" ")) > 1:
|
||||||
chkr = enchant.checker.SpellChecker(locale)
|
chkr = SpellChecker(locale)
|
||||||
chkr.set_text(inp)
|
chkr.set_text(inp)
|
||||||
|
|
||||||
for err in chkr:
|
for err in chkr:
|
||||||
|
|
Reference in a new issue