[Tex/LaTex] better spellchecker for lyx

lyxspelling

I am using LyX 2.0.5.1 and the spell checker here does not seem to have a well developed dictionary – a lot of words that are marked as wrong are actual words. Is there a way to install another spellchecker to work with LyX? I saw the documentation online but it does not provide step by step directions. Could someone do this? I am on Windows machine.

Best Answer

The support for "aspell" in LyX has been dropped. For Windows, the latest binaries of aspell are dated from Dec 2002, see here or GNU Aspell on Wikipedia. (And "ispell" is even a predecessor of "aspell".) More and more programs are switching to "hunspell". Of course, this does not say using "hunspell" is the best choice in every case.

There is another way to look at it. Often one can choose among different dictionaries in "hunspell" for the same language... There is the often cited repository of OpenOffice (and others may exist). One can download a dictionary, extract the .dic, .aff and README- files from the zip file and store them in the directory used by the operating system for hunspell dictionaries. If the filename of the .dic and .aff files do not have a pattern like xx_XX.xxx or xx.xxx, one needs to rename them. For example, "en-US.aff" should become "en_US.aff" or just "en.aff". (This information can be found here.)


Update:

For installing a Hunspell dictionary for a language and using it in LyX, one can follow these instructions (I think of particular importance is to set the path "Tools > Preferences > Paths > Hunspell" correctly. Since warnings (or errors) about the spellchecker are not shown as pop-up messages in the LyX frontend it can help to run LyX from the command prompt/shell with lyx -dbg files.

There are two ways to increase a spell check dictionary.

  1. By adding words to a personal word list in the spellchecker in LyX (or directly to the file of the personal word list;

    While spell checking (F7) there is the "Add" button to add unknown words to the personal word list. Then they will be know in the future. If the document language is set to "English", the words will be added to the file pwl_english.dict in the home directory of LyX. Search for this file and you can also edit this file with a text editor and add more words manually (just one word per line).

    If you want to removing a words from it, you can do this also in LyX. Right click on a word that should be remove and select "Remove from personal dictionary".

  2. By replacing an installed Hunspell dictionary by a dictionary created by yourself;

    It seems possible to take two or more dictionaries and merge them into one new dictionary (possibly, ".aff" files have to be merged, too). Then this new dictionary can replace the old one. Since this is only related to Hunspell, questions about this might be better asked on a different SE site. Here is at least a link with some background information about how dictionaries in Hunspell to get started.

Related Question