Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to enable spellchecking for custom language plugins in IDEA?

IntelliJ spellchecking appears to be disabled for certain custom language plugins such as Markdown (extension ".md") and the Non-Dairy Soy Plugin (extension ".soy") even with the Spelling | Typo inspection options enabled:

  • Process Code
  • Process literals
  • Process comments

Is it possible to enable spellchecking for custom language plugins?


Update: I have added spellchecking support for the IntelliJ plugin Non-Dairy-Soy-Plugin. See pull request and the forked copy on Github under branch spellchecker.

like image 831
Christopher Peisert Avatar asked Sep 16 '12 07:09

Christopher Peisert


1 Answers

End users can't force the spellchecker for the file types that are provided by the third-party plug-ins. Plugin maintainer needs to support it explicitly.

For example, Java plug-in defines this in the plugin.xml descriptor:

<spellchecker.support language="JAVA" implementationClass="com.intellij.spellchecker.JavaSpellcheckingStrategy"/>

Plugins can also provide their own dictionaries:

  <extensions defaultExtensionNs="com.intellij.spellchecker">
    <support language="Python" implementationClass="com.jetbrains.python.spellchecker.PythonSpellcheckerStrategy"/>
    <bundledDictionaryProvider implementation="com.jetbrains.python.spellchecker.PythonBundledDictionaryProvider"/>
  </extensions>

SpellcheckingStrategy class specifies how the words in the file type are tokenized and supplied to the spellchecker.

For open source plug-ins like Markdown, you can try to support it yourself and then send pull request or patch to the maintainer, or just kindly ask the maintainer to add spellchecker support in the future updates.

like image 104
CrazyCoder Avatar answered Sep 29 '22 17:09

CrazyCoder