Package jsyntaxpane

Class CompoundUndoMan

All Implemented Interfaces:
Serializable, EventListener, UndoableEditListener, UndoableEdit

public class CompoundUndoMan extends UndoManager
A revised UndoManager that groups undos based on positions. If the change is relatively next to the previous change, like when continuous typing, then the undoes are grouped together. This is cutomized from the http://www.camick.com/java/source/CompoundUndoMan.java from the blog: http://tips4java.wordpress.com/2008/10/27/compound-undo-manager/
See Also:
  • Constructor Details

  • Method Details

    • undoableEditHappened

      public void undoableEditHappened(UndoableEditEvent e)
      Whenever an UndoableEdit happens the edit will either be absorbed by the current compound edit or a new compound edit will be started
      Specified by:
      undoableEditHappened in interface UndoableEditListener
      Overrides:
      undoableEditHappened in class UndoManager
    • startCombine

      public void startCombine()
      Start to combine the next operations together. Only the next operation is combined. The flag is then automatically reset.