0

I have installed macTex (which includes TexShop).
I want the spell checker to ignore several of the latex commands.

Per this link, I have installed cocoAspelling.

In System Preferences: cocaoAspelling's Spelling menu:
I enabled the English (United States) dictionary,
(with Tex options enabled).

This created an English (United States) (Aspell) option
in System Preferences: Keyboard: Text tab.
I selected this pane
(although I would prefer an application only option.)

Per the link, I closed and reopened Texshop.
In TexShop: Edit: Show Spelling and Grammar,
the default language was set to Automatic by language
which meant there was a system problem setting the default.

Per this link,
I could manually set the spell checking language in TexShop
on a file by file basis
by using the following code:

% !TEX spellcheck = en_US

This enables me to set the dictionary I want,
but I do not know the correct input for the Aspell dictionary.

Questions:

  1. Does anyone know if such a language code exists for Aspell dictionaries?

  2. Does anyone know where any decent documentation on TexShop resides?

    • (Every question I've ever had is at least partially solved with,
      "Use this % !TEX command",
      but I can't find documentation specifying these commands.)
5
  • You should be able to set the dictionary in TeXShop's Edit->Show Spelling and Grammar (Cmd-:) Pane to English (Aspell) and it should stick. Commented Jun 5, 2017 at 12:40
  • @HerbSchulz What is your definition of stick? It doesn't open with that dictionary by default, it doesn't rescan the document when I switch to that dictionary half the time (so I have to finagle back and for between other languages), and if I close the document, I have to repeat the process. It's very twitchy at best.
    – kando
    Commented Jun 6, 2017 at 0:06
  • Try logging out and back in or even rebooting. Hopefully that will do it. Commented Jun 6, 2017 at 1:26
  • Also, what OS version are you using? The latest cocoAspell is for El Capitan and Sierra (10.11 and later) only. Commented Jun 6, 2017 at 16:36
  • Also, what OS version are you using? The latest cocoAspell is for El Capitan and Sierra (10.11 and later) only. You can also get information under the Help->TeXShop Help Panel… and take a look at other documentation under the Help menu also. For now try just checking only the 'English' item in the Spelling Pref pane; choose 'English (Aspell)' in Keyboard->Text for Spelling choice; and 'English (Aspell)' in TeXShop's Spelling and Grammar pane. Finally, are you changing that option in other apps too? Unfortunately it is global. Commented Jun 6, 2017 at 16:57

3 Answers 3

3

In general, changes in TeXShop Preferences affect all future documents, while changes through menus only affect the active document for a particular session. However, the spelling dictionary choice and the choice of smart quotes, smart dashes, etc., are special. (My fault) These items aren't mentioned in TeXShop Preferences and only available via menus. For these, the trick is to have ONLY ONE DOCUMENT OPEN when you set them. Then quit TeXShop. After that, your choices will apply to all documents opened later.

3
  • This used to work for me but no longer does. I'm using TexShop 4.22 and MacOS 10.14.2 Commented Jan 6, 2019 at 22:14
  • It simply isn't working for me either. I'm using TeXShop 4.51 under macOS 10.15.7 and the dictionary selected under Edit > Show Spelling and Grammar doesn't persist when I close TeXShop. I have to manually reset it every time. Commented Nov 26, 2020 at 18:31
  • I finally found a fix! On the Source tab of TeXShop's preferences, there's a setting there to select a dictionary, and the setting is persistent when I quit and relaunch TeXShop and is persistent in the Edit > Show Spelling and Grammar menu. Commented Nov 27, 2020 at 3:33
1

The code for using Aspell would be:

% !TEX spellcheck = English (United States) (Aspell)

(If the name of the Aspell dictionary appearing in Spelling and Grammar is different from the name shown in the code above, then use the name appearing in your dictionary list.)

Notice that this code line sometimes doesn't work if you have multiple .tex files open and some of them do not have this line in the beginning of the document.

0

You can also choose the English (Aspell) dictionary from your document by using

% !TEX spellcheck = English

near the top of your document.

1
  • Please search for "spelling" in TeXShop's Help->TeXShop Help Panel… for a full explaination of how it works, including using the cocoAspell dictionaries. Commented Jul 10, 2017 at 12:16

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .