void (HighlightableComponent renderer) { renderer.setText(myBuffer.toString()); for (HighlightedRegion info : myHighlightedRegions) { renderer.addHighlighter(info.startOffset, info.endOffset, info.textAttributes); } }