public class RSyntaxTextAreaHighlighter extends BasicTextUI.BasicHighlighter
RSyntaxTextAreas. It knows to
always paint "marked occurrences" highlights below selection highlights,
and squiggle underline highlights above all other highlights.Most of this code is copied from javax.swing.text.DefaultHighlighter; unfortunately, we cannot re-use much of it since it is package private.
DefaultHighlighter.DefaultHighlightPainterLayeredHighlighter.LayerPainterHighlighter.Highlight, Highlighter.HighlightPainterDefaultPainter| Constructor and Description |
|---|
RSyntaxTextAreaHighlighter()
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
deinstall(JTextComponent c) |
void |
install(JTextComponent c) |
void |
paint(Graphics g)
Renders the highlights.
|
void |
paintLayeredHighlights(Graphics g,
int p0,
int p1,
Shape viewBounds,
JTextComponent editor,
View view)
When leaf Views (such as LabelView) are rendering they should
call into this method.
|
addHighlight, changeHighlight, getDrawsLayeredHighlights, getHighlights, removeAllHighlights, removeHighlight, setDrawsLayeredHighlightspublic void deinstall(JTextComponent c)
deinstall in interface Highlighterdeinstall in class DefaultHighlighterpublic void install(JTextComponent c)
install in interface Highlighterinstall in class DefaultHighlighterpublic void paint(Graphics g)
paint in interface Highlighterpaint in class DefaultHighlighterg - the graphics contextpublic void paintLayeredHighlights(Graphics g, int p0, int p1, Shape viewBounds, JTextComponent editor, View view)
paintLayeredHighlights in class DefaultHighlighterg - Graphics used to drawp0 - starting offset of viewp1 - ending offset of viewviewBounds - Bounds of Vieweditor - JTextComponentview - View instance being renderedCopyright © 2009-2013 jtstand.com. All Rights Reserved.