public class SyntaxDocument
extends javax.swing.text.PlainDocument
javax.swing.text.AbstractDocument.AbstractElement, javax.swing.text.AbstractDocument.AttributeContext, javax.swing.text.AbstractDocument.BranchElement, javax.swing.text.AbstractDocument.Content, javax.swing.text.AbstractDocument.DefaultDocumentEvent, javax.swing.text.AbstractDocument.ElementEdit, javax.swing.text.AbstractDocument.LeafElement| Constructor and Description |
|---|
SyntaxDocument() |
| Modifier and Type | Method and Description |
|---|---|
static void |
addUndoableEdit(@NotNull javax.swing.undo.UndoableEdit edit)
Adds an undoable edit to this document's undo list.
|
static void |
beginCompoundEdit()
Starts a compound edit that can be undone in one operation.
|
static void |
endCompoundEdit()
Ends a compound edit that can be undone in one operation.
|
protected void |
fireInsertUpdate(@NotNull javax.swing.event.DocumentEvent e)
We overwrite this method to update the token marker state immediately so
that any event listeners get a consistent token marker.
|
protected void |
fireRemoveUpdate(@NotNull javax.swing.event.DocumentEvent e)
We overwrite this method to update the token marker state immediately so
that any event listeners get a consistent token marker.
|
@Nullable TokenMarker |
getTokenMarker()
Returns the token marker that is to be used to split lines of this
document up into tokens.
|
void |
setTokenMarker(@Nullable TokenMarker tokenMarker)
Sets the token marker that is to be used to split lines of this document
up into tokens.
|
createDefaultRoot, getDefaultRootElement, getParagraphElement, insertString, insertUpdate, removeUpdateaddDocumentListener, addUndoableEditListener, createBranchElement, createLeafElement, createPosition, dump, fireChangedUpdate, fireUndoableEditUpdate, getAsynchronousLoadPriority, getAttributeContext, getBidiRootElement, getContent, getCurrentWriter, getDocumentFilter, getDocumentListeners, getDocumentProperties, getEndPosition, getLength, getListeners, getProperty, getRootElements, getStartPosition, getText, getText, getUndoableEditListeners, postRemoveUpdate, putProperty, readLock, readUnlock, remove, removeDocumentListener, removeUndoableEditListener, render, replace, setAsynchronousLoadPriority, setDocumentFilter, setDocumentProperties, writeLock, writeUnlock@Nullable public @Nullable TokenMarker getTokenMarker()
public void setTokenMarker(@Nullable
@Nullable TokenMarker tokenMarker)
tokenMarker - the new token markerpublic static void beginCompoundEdit()
public static void endCompoundEdit()
public static void addUndoableEdit(@NotNull
@NotNull javax.swing.undo.UndoableEdit edit)
edit - the undoable editprotected void fireInsertUpdate(@NotNull
@NotNull javax.swing.event.DocumentEvent e)
fireInsertUpdate in class javax.swing.text.AbstractDocumentprotected void fireRemoveUpdate(@NotNull
@NotNull javax.swing.event.DocumentEvent e)
fireRemoveUpdate in class javax.swing.text.AbstractDocument