void (VisualLineFragmentsIterator.Fragment fragment, int start, int end, TextAttributes attributes, float xStart, float xEnd, int y) { if (dryRun) return; FoldRegion foldRegion = fragment.getCurrentFoldRegion(); TextAttributes foldRegionInnerAttributes = foldRegion == null || !Registry.is("editor.highlight.foldings") ? null : getInnerHighlighterAttributes(foldRegion); if (foldRegionInnerAttributes == null || !paintFoldingBackground(foldRegionInnerAttributes, xStart, y, xEnd - xStart, foldRegion)) { paintBackground(attributes, xStart, y, xEnd - xStart); } Inlay inlay = fragment.getCurrentInlay(); if (inlay != null) { TextAttributes attrs = attributes.clone(); myTextDrawingTasks.add(g -> { inlay.getRenderer().paint(inlay, g, new Rectangle2D.Double(xStart, y, xEnd - xStart, myLineHeight), attrs); }); } else { if (foldRegionInnerAttributes != null) { attributes = TextAttributes.merge(attributes, foldRegionInnerAttributes); } if (attributes != null) { attributes.forEachEffect((type, color) -> myTextDrawingTasks.add( g -> paintTextEffect(xStart, xEnd, y + myAscent, color, type, foldRegion != null) )); } if (attributes != null) { Color color = attributes.getForegroundColor(); if (color != null) { myTextDrawingTasks.add(g -> g.setColor(color)); myTextDrawingTasks.add(fragment.draw(xStart, y + myAscent, start, end)); } } } if (foldRegion == null) { int logicalLine = fragment.getStartLogicalLine(); if (logicalLine != currentLogicalLine[0]) { whitespacePaintingStrategy.update(myText, myDocument.getLineStartOffset(logicalLine), myDocument.getLineEndOffset(logicalLine)); currentLogicalLine[0] = logicalLine; } paintWhitespace(xStart, y + myAscent, start, end, whitespacePaintingStrategy, fragment, whiteSpaceStroke, whiteSpaceScale); } }