|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectsk.uniba.euromath.document.UndoManager
public final class UndoManager
Manages undoing of the modification operations. Thread-unsafe.
| Constructor Summary | |
|---|---|
UndoManager()
Constructs an empty undo manager. |
|
| Method Summary | |
|---|---|
boolean |
canRedo()
Checks if there are some undo actions that can be applied back to the document. |
boolean |
canUndo()
Checks if there are some undoable operations. |
int |
getMarkCount()
Returns the maximum number of marks. |
void |
handleEvent(Event evt)
|
boolean |
isSavePoint()
Checks if the manager is currently 'standing' on the savepoint mark. |
void |
mark()
Marks the end of previous modification operations group and the start of a new group. |
void |
mark(boolean savePoint)
Marks the end of previous modification operations group and the start of a new group. |
void |
observe(Node node)
|
void |
redo()
Redoes previously undone modification operations up to the nearest mark point. |
void |
setMarkCount(int count)
Sets new maximum count of marks - a maximum undo history length. |
void |
stopObservation(Node node)
|
void |
undo()
Rollbacks all previous modification operations up to the nearest mark point. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public UndoManager()
| Method Detail |
|---|
public void mark()
public void mark(boolean savePoint)
savePoint - if true then this mark marks a point when
the document was saved.public boolean isSavePoint()
true if last undo group is empty (it contains no
actions) and savepoint.public void undo()
Rollbacks all previous modification operations up to the nearest mark point. If no operations were performed then nothing is done.
The document must be in the modifying mode (DocumentModifier.startModify()
must have been called).
public boolean canUndo()
true if there are some undoable operations,
false otherwise.public void redo()
Redoes previously undone modification operations up to the nearest mark point. If no operations can be redone then nothing is done.
The document must be in the modifying mode (DocumentModifier.startModify()
must have been called).
public boolean canRedo()
true if there are some redoable operations,
false otherwise.public int getMarkCount()
5.
public void setMarkCount(int count)
count - the maximum marks count.public void handleEvent(Event evt)
handleEvent in interface EventListenerpublic void observe(Node node)
observe in interface sk.baka.ikslibs.INodeObserverpublic void stopObservation(Node node)
stopObservation in interface sk.baka.ikslibs.INodeObserver
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||