Spell check for text fields
bobs at twft.com
Sun Feb 12 13:46:59 CST 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:
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
-- reset whatever you did
exit to top
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.
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?
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
More information about the use-livecode