Sublime Forum

Can't install new dictionaries

#1

This question is pretty much identical to an old one. I want to install the Swedish dictionary from tito’s https://github.com/titoBouzout/Dictionaries, but I have trouble getting it to work.

I have downloaded all three versions from the github repo (.aff, .dic, .txt) and saved them in the Packages/User folder. The dictionary then appears in the View menu under Dictionary / User. But if I select it all words are underlined red, misspelled or not.

Am I doing something wrong? (The same thing happens when I try the German dictionary.)

0 Likes

#2

I got it working. Here’s what you need to do:

Download the titoBouzout/Dictionaries master zip - https://github.com/titoBouzout/Dictionaries/archive/master.zip - and then extract it.

Then create a new directory in your ST3 Packages directory called Language - Swedish.

i.e. ST3_CONFIG_LOCATION/Packages/Language - Swedish/

Then copy the Swedish.aff and Swedish.dic files from the extracted zip files into the Language - Swedish/ directory. [I did not copy the `Swedish.txt` copyright file.]

Finally use Menu --> Dictionary --> Language - Swedish --> Swedish to switch languages to Swedish.

I tested the above by finding some Swedish text on the web, pasting it into a new buffer, adding an English language sentence, hitting F6 to turn spell checking on, and the only words that were underlined in red where those of the English sentence. None of the Swedish words were underlined.

EDIT: Thinking about it… I suspect where you might have gone wrong was by right-clicking on, and then saving, the Swedish.aff and Swedish.dic filenames shown on the titoBouzout/Dictionaries GitHub page. If you did that then you would not have actually saved the files you wanted, instead you would have saved the GitHub web pages belonging to those files; BUT you would have ended up with 2 files called Swedish.aff and Swedish.dic on your computer both containing HTML instead of the dictionary data, and consequently they would not work as a ST dictionary.

Hope this helps.

2 Likes

#3

Thanks! You were correct in your suspicion. Rookie mistake, I guess. In my defense, I was surprised when Chrome suggested that I save the files as Swedish.aff etc but thought that maybe Github did some JS magic to distinguish between save and click. I should have looked at the actual files though #facepalm

0 Likes

#4

Even if the dictionaries package is not in package control you can still install it instead of downloading each language:

  1. Open the command palette (C-shift-p) and select the entry Package Control: Add Repository
  2. Paste the url: https://github.com/titoBouzout/Dictionaries and press enter
  3. Now you can install it as any other package: First select Package Control: Install Package in the command panel and afterwards select Dictionaries to install it

(from https://latextools.readthedocs.io/en/latest/features/#spell-checking)

2 Likes

#5

When considering whether to do this users should bear in mind that the titoBouzout/Dictionaries zip is, at 38 MB, unusually large for a ST package. I currently have 35 packages installed, their total size is 5 MB.

A poor decision would be to download the whole titoBouzout/Dictionaries file and unzip it into a new directory created in the Packages config directory in order to install it - the package is 185 MB when uncompressed.

However I am fairly sure that ST will only load the currently used dictionary into memory - can someone confirm that?

0 Likes