javax.swing.text.Documentpublic static interface NbDocument.Annotatable
extends javax.swing.text.Document
| Modifier and Type | Method | Description |
|---|---|---|
void |
addAnnotation(javax.swing.text.Position startPos,
int length,
Annotation annotation) |
Add annotation to the document.
|
void |
removeAnnotation(Annotation annotation) |
Removal of added annotation.
|
addDocumentListener, addUndoableEditListener, createPosition, getDefaultRootElement, getEndPosition, getLength, getProperty, getRootElements, getStartPosition, getText, getText, insertString, putProperty, remove, removeDocumentListener, removeUndoableEditListener, rendervoid addAnnotation(javax.swing.text.Position startPos,
int length,
Annotation annotation)
startPos - position which represent begining
of the annotated textlength - length of the annotated text. If -1 is specified
the whole line will be annotatedannotation - annotation which is attached to this textvoid removeAnnotation(Annotation annotation)
annotation - annotation which is going to be removedBuilt on April 24 2018. | Portions Copyright 1997-2018 Oracle. All rights reserved.