Click here to Skip to main content
15,905,566 members

Comments by MorningCloud (Top 13 by date)

MorningCloud 11-Sep-23 6:17am View    
Thanks, Richard, that has fixed the problem.
MorningCloud 11-Sep-23 5:19am View    
Thanks Richard. However, when I change my code to:
	if (Hunspell_add != NULL){
		Hunspell_add(dic, Word2Add);
		}


I get the error message "Type error in argument 1 to 'function'; expected 'const char *' but found 'Hunhandle (aka (incomplete) struct Hunhandle) *"

The pdf file "hunspell3.pdf" at https://sourceforge.net/projects/hunspell/files/Hunspell/Documentation/ seems to indicate that when programming in the C language the handle is not needed. It looks as thought there is quite a difference between programming in C++ and in C.
MorningCloud 10-Sep-23 11:29am View    
Thanks, Richard. I am still trying to get this to work but everything I try causes a crash and I can't see why.

I was reluctant to post the full code for my Hunspell program as it is quite large (264 lines) and so I only posted the section that was not working. However, you made me realise that it may help to resolve the problem if I post the full code that includes the part that works (ie check the spelling of a word), so I have made it available in a zip file that can be downloaded from the following link:

https://mega.nz/file/HAsiSKqb#J_wIe_xlnisNj2MXptJ1JzjlIvrWqDx6n7vc_JKrbZU

I have not been able to find out what the return value from Hunspell_add() should be. I can only assume that this is TRUE or FALSE.
MorningCloud 10-Sep-23 8:56am View    
Thanks, I'll take a look at that.
MorningCloud 9-Sep-23 13:23pm View    
Thanks for looking into this. It's very irritating that the documentation is so poor. I spent a lot of time looking in the internet for further information about Hunspell. Although it seems to be widely used there is virtually no information or examples for using it in the C language.