void (final Graphics2D g, int firstVisibleOffset, int lastVisibleOffset, int firstVisibleLine, int lastVisibleLine) { Object hint = g.getRenderingHint(RenderingHints.KEY_ANTIALIASING); g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); try { List<RangeHighlighter> highlighters = new ArrayList<>(); processRangeHighlighters(firstVisibleOffset, lastVisibleOffset, highlighter -> { LineMarkerRenderer renderer = highlighter.getLineMarkerRenderer(); if (renderer != null) highlighters.add(highlighter); }); ContainerUtil.sort(highlighters, Comparator.comparingInt(RangeHighlighter::getLayer)); for (RangeHighlighter highlighter : highlighters) { paintLineMarkerRenderer(highlighter, g); } } finally { g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, hint); } paintIcons(firstVisibleLine, lastVisibleLine, g); }