Child pages
  • Developing Custom Language Plugins for IntelliJ IDEA
Skip to end of metadata
Go to start of metadata

 

Redirect: http://www.jetbrains.org/intellij/sdk/docs/reference_guide/custom_language_support.html

6 Comments

  1. JW

    In the paragraph about "Syntax Highlighting and Error Highlighting" ...Third level of highlighting.....it is mentioned that a registered Annotator class is only called incrementally, i.e. only for processing the changed part of a file (custom language sourcecode).

    From my own testing, I'm not sure if this is true in any case.

    Maybe a short explanation of what changes in the edited document(?) trigger what calls to method annotator() with changed(?) PsiElement as first parameter helps here.

  2. If you wish your plugin to work on IntelliJ IDEA 11, please be aware that your SyntaxHighlighter may need to forgo the new TextAttributesKey.createTextAttributesKey(String, TextAttributesKey) method (introduced around 2012-10-31 for 130.744) and use an older form instead.   So rather than:

    .. you should probably use ..

  3. What will happen if there are 2 plugins registering the same file type? Which documentation provider will take over?

    1. The user will need to choose only one of the plugins; otherwise, all kinds of conflicts will happen.

  4. Is there an easy way to update existing inspections and References and Resolve.

    I have a spring configuration file that has following configuration:

    <import resource="@{com.amq.configuration}"/>

    Obviously, IDEA does not recognize @{com.amq.configuration} as valid value. This value get replaced by gradle later at compilation time into real value from appropriate file for particular environment: 
    <import resource="myFiltreredConfig.xml"/>

    Now, ideally I would like to have ability to intercept/override Intellij spring integration inspection for resource resolving and replace value @{com.amq.configuration} to the value that it will be replaced to in my local environment. I would not really like to write the whole language plugin for doing that, I'd rather extend||override||intercept and override the @{.*} values.

    Please let me know what is the easiest way for doing it?

    Thanks!