Re: Special characters in a custom dictionary will break the spell check.
Stanislas Rolland <[email protected]> Sat, 07 Jul 2012 10:20:07 -0400
| Newsgroups | gmane.comp.gnu.aspell.user |
|---|---|
| Message-ID | <[email protected]> |
Hi Kevin, >>> >>>> I am encountering this same problem: trying to add a word that >>>> contains a special character into a personal dictionary gives an error >>>> like: >>>> >>>> @(#) International Ispell Version 3.1.20 (but really Aspell 0.60.3) >>>> Error: The word "erf?rt" is invalid. The character '?' (U+3F) may not >>>> appear in the middle of a word. >>>> >>>> The word is utf-8-encoded into a file that is piped to the Aspell >>>> command. The command includes the --encoding='utf-8' option. The >>>> personal dictionary file also specifies utf-8 as encoding, and if I >>>> add the word manually to this dictionary, it is correctly taken into >>>> account when spell checking is done. >>>> >>>> Apparently, Aspell ignores the option specifying the encoding of the >>>> input, and assumes that it is encoded in the same character set as >>>> the main dictionary. >>> >>> I don't think that is the issue. The issue is that the Aspell is 8-bit >>> internally and the personal dictionary needs to get mapped to the same >>> character set that the main dictionary uses. The '?' means that the >>> Unicode character was not available in the main dictionary character set >>> and it thus defaulted to a '?'. >>> >> But, if I am using a dictionary for Spanish and try to add to a >> personal dictionary a word that contains the character รณ, which is >> very common in Spanish, I get this same message. Obviously it is very >> simple to convert this character from utf-8 to iso-8859-1, the latter >> being apparently used by the Spanish dictionary... > > If that is really the case then it could be a bug. It would likely be > best to file a bug report and I will look into it when I get chance. In > the report be sure and include a sample personal dictionary that is not > working as intended and mention what dictionary you are using. > I will. > As a workaround for now, you can convert utf-8 to iso-8859-1 using > "aspell conv utf-8 iso-8859-1". This is basically what I did. But then, I have first to access the dictionary to know what encoding Aspell wants me to use. Regards, Stanislas Rolland TYPO3 Core Team Member TYPO3 .... inspiring people to share! Get involved: http://typo3.org _______________________________________________ Aspell-user mailing list [email protected] https://lists.gnu.org/mailman/listinfo/aspell-user