JavaScript is disabled on your browser.
JavaScript is disabled on your browser.
Detail:
Field |
Constr |
Method
Method Detail
install
void install(JTextComponent c)
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.
Parameters:
c
- the JTextComponent editor
paint
void paint(Graphics g)
Renders the highlights.
Parameters:
g
- the graphics context.
addHighlight
Object addHighlight(int p0,
int p1,
Highlighter.HighlightPainter p)
throws BadLocationException
Adds a highlight to the view. Returns a tag that can be used
to refer to the highlight.
Parameters:
p0
- the beginning of the range >= 0
p1
- the end of the range >= p0
p
- the painter to use for the actual highlighting
Returns:
an object that refers to the highlight
Throws:
BadLocationException
- for an invalid range specification
changeHighlight
void changeHighlight(Object tag,
int p0,
int p1)
throws BadLocationException
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.
Parameters:
tag
- which highlight to change
p0
- the beginning of the range >= 0
p1
- the end of the range >= p0
Throws:
BadLocationException
- for an invalid range specification
JavaScript is disabled on your browser.
Detail:
Field |
Constr |
Method
Report a bug or suggest an enhancement For further API reference and developer documentation see the Java SE Documentation , which contains more detailed, developer-targeted descriptions with conceptual overviews, definitions of terms, workarounds, and working code examples. Java is a trademark or registered trademark of Oracle and/or its affiliates in the US and other countries. Copyright © 1993, 2018, Oracle and/or its affiliates, 500 Oracle Parkway, Redwood Shores, CA 94065 USA. All rights reserved. Use is subject to license terms and the documentation redistribution policy .
Scripting on this page tracks web page traffic, but does not change the content in any way.