|
org.netbeans.modules.editor.lib2/1 1.43.1 10 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.netbeans.spi.editor.typinghooks.TypedTextInterceptor.Context
public static class TypedTextInterceptor.Context
The context class providing information about the edited document, its editor pane, insertion offset and text.
Method Summary | |
---|---|
JTextComponent |
getComponent()
Gets the editor component where the currently processed key typed event occurred. |
Document |
getDocument()
Gets the edited document. |
int |
getOffset()
Gets the insertion offset. |
String |
getText()
Gets the insertion text. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public JTextComponent getComponent()
Document
.public Document getDocument()
public int getOffset()
KeyEvent
happened). This is also the offset where the insertion text will end up.
public String getText()
It is guaranteed that the text will have length equal to 1 for contexts
that are passed to beforeInsert
and insert
methods. In these methods getText
returns exactly what
a user typed in the editor.
In the afterInsert
method the text returned from getText
method can have any length and will correspond to either the originally typed
text or to text supplied by one of the interceptors participating in
the key typed event processing.
|
org.netbeans.modules.editor.lib2/1 1.43.1 10 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |