Spell check for text fields
Bob Sneidar
bobs at twft.com
Sun Feb 12 14:46:59 EST 2012
This is a long shot, but I wonder if you can communicate with Apple's system wide spell checker via Applescript? I have no idea what yo could use for Windows or Linux. You would have to create a rawKeyUp handler in a field, card or stack script (or even a frontScript) which would check to see if a space was entered and then act on the last word typed, or cycle through the words of the text entered and run them against the spell checker via Applescript.
This is a handler I have that filters the data in a datagrid based upon what is typed in a Find field:
on rawKeyUp
if the text of me is not empty then
wait .75 seconds with messages -- set the delay to what you want
-- do what you need to do here
else
-- reset whatever you did
exit to top
end if
pass rawKeyUp
end rawKeyUp
You can modify it to do what you want. Instead of working with the text of me, you could change that to the text of the target, and use the handler in the card, stack or frontScript. The idea is that the script will not do anything until the delay you set is exceeded. This makes it a bit more responsive. Your process will not run every time you type a key.
I have not poked into Applescript to see if you can access the dictionary with it, but if you are working on an Apple, it's easy to do. If not then the point is moot.
Bob
On Feb 11, 2012, at 12:15 PM, Michael Chean wrote:
> Is there any addon that checks the spelling of words as they are entered
> into a text field?
>
> Mike
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
More information about the use-livecode
mailing list