WPCubed Product Support

spell as go dialog

Hello;

I allways used to do spell check with my own spell checker; under WPTools 7 I also added spell as go by using OnSpellCheckWord event. My question is how to know if a clicked word is marked as wrong so I can open a set of options for fixing it, in same way WPSpell does, as we can see here:

Thank you!

#1 ♥ 0
6.1k Views 2 users read 2 min
support

There is an event for this:

OnRightClickWord which also lets you replace the word which was clicked - this is what WPSpell uses.

Julian

#2 ♥ 0

Hi Julian;

Thank you. You didn't answer exactly what I asked (I know this event, but I was searching for how to know if the word is misspelled or not). Anyway I have found how, so thank you anyway.

Now I am searching for how to refresh all the spelling after doing changes in the whole text, and I found this:

procedure TWPCustomRtfEdit.Refresh(SpellCheck: Boolean = FALSE); ....

Please note that the parameter "SpellCheck" is not used. How can I refresh the spelling in the whole text?

Thank you!

#3 ♥ 0

BTW ... It seems the event OnRightClickWord does no exist in your code.

#4 ♥ 0
support

Yes, a little mixed up.

{:: This event is used for context menuse. It is triggered usually when the ContextMenu key was pressed,
or the right mouse button. You can set the flag wpDontTriggerPopupInContextEvent in EditOptionsEx, then this
event will be always triggered in the MouseDown event. }
property OnMouseDownWord: TWPMouseDownRightEvent read FOnMouseDownWord
write FOnMouseDownWord;

Use
Refresh(true)

to for the spellcheck "as you go" for the complete text. This of course only works with the events beeing used like WPSpell does it.

#5 ♥ 0
This category is archived. No new posts are possible.