boolean (@NotNull Document document, @NotNull Project project, int startOffset, int endOffset, @NotNull Processor<? super HighlightInfo> processor) { LOG.assertTrue(ApplicationManager.getApplication().isReadAccessAllowed()); MarkupModelEx model = (MarkupModelEx)DocumentMarkupModel.forDocument(document, project, true); return model.processRangeHighlightersOutside(startOffset, endOffset, marker -> { HighlightInfo info = HighlightInfo.fromRangeHighlighter(marker); return info == null || info.getHighlighter() == null || processor.process(info); }); }