I have been trying to develop a Hunspell dictionary for my mother tongue, Persian. As you may know, there is no prebuilt Hunspell dictionary in Adobe Indesign for the Persian language. I have done the dictionary and affixes files for it and my glossary is almost complete. Here is my problem: the Hunspell dictionary in Indesign behaves a little bit differently in Indesign in comparison with other environments that support Hunspell e.g. Firefox and Chrome browsers. In Persian, many words have Zero Width Non-Joiner (ZWNJ). Although the words in my dictionary do have the ZWNJ, the Indesign is not able to detect them and acts as if there is no such character. How can I overcome this problem?
I know that this answer isn't the technical answer you are looking for, but when I used this other Persian Hunspell dictionary, I didn't encounter your problem. I suspect that the encodings of the raw text files that you use to make your .dic file may be the cause, but I can't tell you for sure unless I look at yours, and theirs, and do a bunch of Really Fast Learning about how Hunspell dictionaries are made.
If pointing you towards the lilak project isn't enough to answer your questions, I guess I should ask you to tell us what version and platform of ID you are using, and whether or not your personal Hunspell Persian dictionary is available for us to download and try to install ourselved to see if we can recreate your ZWNJ issue.
I am familiar with that dictionary you mentioned, but unfortunately, when I tested I still have the same problem. Maybe the Hunspell inside Indesign has been updated in the recent versions and my problem is related to the version of my Indesign. I have Indesign 2020 v15.1.3 and it is the latest version that my machine with Windows 7 can run. Please let me know if I can update the Hunspell of my Indesign to the latest version. Let me say it in detail. For example for the Persian word
because it exists in the .dic file, the Hunspell correctly does not detect it as a wrong word. But when I add a ZWNJ in the between, e.g.
Hunspell does not consider them as wrong words, and obviously they are wrong. I can provide you with my dictionary and my text if it is needed.