Spellcheck dictionaries for most languages are freely available on the Internet. If you are a language pack author, you can add one to your language pack so that anyone who has installed your language pack can use that spellcheck dictionary for checking spellings in the Note Window.
Family Historian uses Hunspell for spellcheck dictionaries. There are many of these on the Internet – for example, here: https://github.com/wooorm/dictionaries. If you got to that page, click the green “Code” button and then choose “Download ZIP” to download them all. You will need to extract the files from the zip file. If you do that preserving the folder structure, you should find that a folder is created called “dictionaries-main” and within that there is a folder called “dictionaries”, and within that there are numerous sub-folders for different languages, identified by language codes. For example “de” is German, “nl” is Dutch or Flemish, “pt” is Portuguese”, “nb” is Norwegian Bokmål, “sv” is Swedish… and so on. See https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes for a list of 2-letter language codes. Let’s suppose that your language is Swedish, say. If you look in the “sv” folder it contains the following files (the file suffixes may be hidden on your PC):
- index.aff
- index.dic
- index.js
- license
- package.json
- readme.md
The files may not be an exact match, but they should be something like that. The 2 key dictionary files are the index.aff and index.dic files, but the other files are also important – especially the license file and the readme.md.
If you have created a language pack, the files for that language pack will be located on your PC in a subfolder within this folder:
- C:\ProgramData\Calico Pie\Family Historian\Lang
The folder name of your language pack will be its language pack id (the bit in brackets after the language name). So, for example, if your language pack had “SWE” as a language pack id, the folder for the language pack will be
- C:\ProgramData\Calico Pie\Family Historian\Lang\SWE
To create a spellcheck dictionary for Swedish, you just need to create a subfolder within your language pack called “spellcheck”:
- C:\ProgramData\Calico Pie\Family Historian\Lang\SWE\spellcheck
Then copy all of the above-listed files (all 6 in the example above) into that new folder.
Very Important – Check the Licence!
Before you update your language pack to the Plugin Store, it is very important that you check the licence and confirm that you are allowed to freely distribute the spellcheck files. You must carefully read the licence and check to see if there are any special conditions that must be met. Ordinarily, people are very generous in allowing free use of their work. But you must not assume that it’s OK. And if there are any special conditions, these must be met. However, the likelihood is that you can meet these requirements by simply copying all the files, including the licence files, into the spellcheck folder.
Please be aware that under the terms of the Plugin Store, you are responsible for checking that you have all necessary rights for the files you upload.
Before uploading a new version or your language pack with a spellchecker, please try it out in Family Historian, and make sure it works OK. To select a spellchecker, open the Note Window (any note in the sample project for example), click on the cog menu button on the toolbar and choose ‘Options’ from the dropdown menu. Then select your dictionary in the ‘Dictionary’ field. It should be listed there. Thereafter, whatever the language of your dictionary is, words that are misspelled in that language should be displayed in the Note Window with a squiggly red line below them.
How to Update a Language Pack in the Plugin Store
To update your language pack in the Plugin Store, first make sure to update the version number appropriately in the Plugin Header. In general we recommend updating the minor number for most changes (e.g. from 1.0 to 1.1). Then in the Language Packs Window, select your language pack and click the Export button to export it. Make a note of the file location. Then open a Web Browser, and login to the Plugin Store (https://pluginstore.family-historian.co.uk/wp-login.php). Click on “Language Packs” on the left-hand-side. You should be able to edit your own language pack. Where it says “Language Pack File”, click the ‘x’ to clear the current value. Then click the Add File button and add your new file (remember that this is always a 2-step process whereby you add it to the library and then add it to your language pack effectively). Then, change the version number field to the new value. And finally (very important) don’t forget to click the Submit for Review button.