| javax.swing.text.Highlighter |
Known Indirect Subclasses
|
An interface for an object that allows one to mark up the background with colored areas.
| Nested Classes | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Highlighter.Highlight | |||||||||||
| Highlighter.HighlightPainter | Highlight renderer. | ||||||||||
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Adds a highlight to the view.
| |||||||||||
Changes the given highlight to span a different portion of
the document.
| |||||||||||
Called when the UI is being removed from the
interface of a JTextComponent.
| |||||||||||
Fetches the current list of highlights.
| |||||||||||
Called when the UI is being installed into the
interface of a JTextComponent.
| |||||||||||
Renders the highlights.
| |||||||||||
Removes all highlights this highlighter is responsible for.
| |||||||||||
Removes a highlight from the view.
| |||||||||||
Adds a highlight to the view. Returns a tag that can be used to refer to the highlight.
| p0 | the beginning of the range >= 0 |
|---|---|
| p1 | the end of the range >= p0 |
| p | the painter to use for the actual highlighting |
| BadLocationException | for an invalid range specification |
|---|
Changes the given highlight to span a different portion of the document. This may be more efficient than a remove/add when a selection is expanding/shrinking (such as a sweep with a mouse) by damaging only what changed.
| tag | which highlight to change |
|---|---|
| p0 | the beginning of the range >= 0 |
| p1 | the end of the range >= p0 |
| BadLocationException | for an invalid range specification |
|---|
Called when the UI is being removed from the interface of a JTextComponent. This is used to unregister any listeners that were attached.
| c | the JTextComponent editor |
|---|
Fetches the current list of highlights.
Called when the UI is being installed into the interface of a JTextComponent. This can be used to gain access to the model that is being navigated by the implementation of this interface.
| c | the JTextComponent editor |
|---|
Removes all highlights this highlighter is responsible for.
Removes a highlight from the view.
| tag | which highlight to remove |
|---|