void () { myDoc.advance(); myView.advance(); boolean fileEnd = myStartOffset == myDocument.getTextLength(); for (int i = myCurrentHighlighters.size() - 1; i >= 0; i--) { RangeHighlighterEx highlighter = myCurrentHighlighters.get(i); if (myReverseIteration ? getAlignedStartOffset(highlighter) >= myStartOffset : fileEnd && highlighter.getTargetArea() == HighlighterTargetArea.LINES_IN_RANGE ? getAlignedEndOffset(highlighter) < myStartOffset : getAlignedEndOffset(highlighter) <= myStartOffset) { myCurrentHighlighters.remove(i); } } }