Alternative to LivePreviewController for displaying SearchResults
Answered
I have a class that uses LivePreviewController to periodically find queries in a document. However, I would like to be able to control which search results are painted to the screen, and when they are painted. Unfortunately, neither LivePreview, nor LivePreviewController exposes a good way to do this. In the past, we just painted a simple rectangle to the screen, but I would like to do this through the IntelliJ Platform API. At a minimum, I just need to exclude certain search results from the LivePreview. Is there a better way to highlight search results in the editor?
Please sign in to leave a comment.
LivePreview uses HighlightManager internally. You can also do that, or add RangeHighlighter-s directly to editor's MarkupModel.
HighlightManager is exactly what we need, thanks Dmitry!