undo

abstract fun undo()

Undoes the last edit or throws an exception if an undo operation is not possible. It's recommended that you check whether an undo operation is available using (canUndo) before calling this method. Undoing may be unavailable if there are no edits on the undo stack or if the latest edit on the undo stack cannot be undone. When undoing an edit, the edit is moved to the internal redo stack.

Throws

Thrown if an undo operation was unsuccessful, if the undo stack was empty, or if the last edit is not undoable.