private RangeHighlighterEx[] collectHighlighters(int start, int end, Comparator<RangeHighlighterEx> comparator) {
      // we have to get all highlighters in advance and sort them by affected offsets
      // since these can be different from the real offsets the highlighters are sorted by in the tree.
      // (See LINES_IN_RANGE perverts)
      var processor = new CommonProcessors.CollectProcessor<RangeHighlighterEx>() {
        @Override
        public boolean accept(RangeHighlighterEx h) {
          return acceptHighlighter(h); // TODO: refactor to skipHighlighter here
        }
      };
      myMarkupModel.processRangeHighlightersOverlappingWith(start, end, processor);
      RangeHighlighterEx[] highlights = processor.getResults().isEmpty()
                                        ? RangeHighlighterEx.EMPTY_ARRAY
                                        : processor.toArray(RangeHighlighterEx.EMPTY_ARRAY);
      Arrays.sort(highlights, comparator);
      return highlights;
    }
private RangeHighlighterEx[] collectHighlighters(int start, int end, Comparator<RangeHighlighterEx> comparator)