Different background when using TextAttrribtes.ERASE_MARKER PHPStorm


I want to additionally highlight DocBlock with an Annotator. When I use TextAttributes.ERASE_MARKER to reset the highlighting then also the background is reset (specific for the PHPStorm Plugin). The problem is, when I also annotate the text attributes of PhpHighlightingData.PHP_SCRIPTING it works quite well, except when it comes to the caret line text attributes. Then the background of the annotatet stuff doesn't change to the caret row attributes.


Thanks for your help!

EDIT: Does someone know, if you could register multiple syntax highlighters for a language?

1 comment

Trying to "overlay" multiple TextAttributes via Annotator is unfortunately a bit tricky. Multiple annotators can be run in arbitrary order, and then resulting TextAttributes are "merged". Please try using custom com.intellij.codeHighlighting.TextEditorHighlightingPass instead.


Please sign in to leave a comment.