MPS 2019.3 Help

Spellchecking

MPS helps you make sure that your source code, including single-line comments, Javadoc text and string literals, is spelt correctly.

Checking the spelling of a word

MPS detects and highlights words not included in any dictionary. You can either provide the correct spelling or accept the word as is. If a word is accepted, it will be added to the project level dictionary, and skipped by the spellchecker in the future.

Accept a misspelled word

  • Select the Add to dictionary action in the Context menu to add the word to the user's dictionary and skip it in the future.

Configuring the dictionaries to use

Correctness of spelling is checked against the bundled dictionaries and user-defined custom dictionaries. Since the spellchecking feature doesn't allow you to actually change the natural language itself, adding custom dictionaries will allow you to bring virtually any language support to MPS.

The dictionaries can be any of the following:

  • The built-in project-level and application-level dictionaries, which you populate by manually saving words to them.

  • Plain text files with the DIC extension, containing words separated with a new line.

  • Hunspell dictionaries, comprise two plain text files commonly sharing the same name, for example, en_GB.dic and en_GB.aff. The DIC file contains a list of words together with the applicable modification rules. The AFF file list prefixes and suffixes regulated by a specific modification rule. Hunspell dictionaries can be easily obtained online, for example, here.

Choose the dictionaries to use

  1. In the Settings/Preferences dialog Ctrl+Alt+S, choose Spelling under Editor.

  2. On the Spelling page that opens, switch to the Dictionaries tab.

    In the Custom Dictionaries area, configure your custom dictionaries to use.

    • To add a new custom dictionary to the list, click the Add button or press Alt+Insert and choose the required file in the Select Path Dialog dialog that opens. The full path to the selected file is added to the Custom Dictionaries list.

    • To edit the contents of a custom dictionary in MPS, select it and click the Edit button or pressEnter. The corresponding file will open in a new editor tab.

    • To remove a custom dictionary from the list, select it and click the Remove button or press Alt+Delete.

  3. In the Bundled Dictionaries area, configure the bundled dictionaries to use by selecting or clearing the checkboxes next to them.

Populating the built-in dictionaries

Add an accepted word

  1. In the Settings/Preferences dialog Ctrl+Alt+S, choose Spelling under Editor.

  2. On the Spelling page that opens, switch to the Accepted Words tab.

  3. Create a Word List:

    • Click the Add button to open the Add New Word dialog and specify a new entry there. CamelCase or snake_case are not supported. If you try to add a word that is already included in one of the spelling dictionaries, MPS displays an error message: The word <just typed word> is already in the dictionary.

    • To remove an item from the list, select it and click Remove button.

Last modified: 28 February 2020