Package org.languagetool.gui
Class UndoRedoSupport
- java.lang.Object
-
- org.languagetool.gui.UndoRedoSupport
-
class UndoRedoSupport extends java.lang.Object
Provides Undo/Redo support and actions for JTextComponent
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) class
UndoRedoSupport.RedoAction
(package private) class
UndoRedoSupport.UndoAction
-
Field Summary
Fields Modifier and Type Field Description private javax.swing.undo.CompoundEdit
ce
private boolean
compoundMode
private java.util.ResourceBundle
messages
(package private) UndoRedoSupport.RedoAction
redoAction
(package private) UndoRedoSupport.UndoAction
undoAction
private javax.swing.undo.UndoManager
undoManager
-
Constructor Summary
Constructors Constructor Description UndoRedoSupport(javax.swing.text.JTextComponent textComponent, java.util.ResourceBundle messages)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) void
endCompoundEdit()
Notify manager to stop merging undoable edits.(package private) void
startCompoundEdit()
Notify manager to start merging undoable edits.
-
-
-
Field Detail
-
undoAction
final UndoRedoSupport.UndoAction undoAction
-
redoAction
final UndoRedoSupport.RedoAction redoAction
-
undoManager
private final javax.swing.undo.UndoManager undoManager
-
messages
private final java.util.ResourceBundle messages
-
compoundMode
private boolean compoundMode
-
ce
private javax.swing.undo.CompoundEdit ce
-
-
Method Detail
-
startCompoundEdit
void startCompoundEdit()
Notify manager to start merging undoable edits. Calling startCompoundEdit when already in compound mode is an error and will throw a RuntimeException.- Since:
- 2.7
-
endCompoundEdit
void endCompoundEdit()
Notify manager to stop merging undoable edits. Calling endCompoundEdit when not in compound mode is an error and will throw a RuntimeException.- Since:
- 2.7
-
-