MarkupModel - navigate highlighted elements
Hi
I use the MarkupModel to highlight some (Psi) elements. Everything works fine so far, but now I'm stuck on a) how to remove the highlighting once the user preses ESC and b) moving to the next highlighted element after pressing F3 (analogous to the IDEA default behavior).
Could anybody give me some hints on how I can achieve this? Or is there a higher-level API than the MarkupModel to get the described behavior "for free"?
Thanks in advance for any help!
etienne
Please sign in to leave a comment.
If I understand you correctly, I would use something like this:
Bas
Hi Bas
Beautiful! As always with your replies, it's exactly what I was looking for (using the MarkupModel was too low-level, I guess).
Thanks very much for the quick help.
etienne
P.S. If I ever get to meet you, I'll buy you a beer, or actually no - a case of beer would be more appropriate ;)
You know how to ask the right questions. Exactly the kind I have answers
for. I'm looking forward to that beer already:-)
Bas
Looks like the code example has disappeared in the mists of time. Does anyone have a current example?
This is linked in the dev guide FAQ. It seems to be a 13 year old thread though. I would also love to see this code example.
com.intellij.codeInsight.highlighting.HighlightUsagesHandlerBase