public void Undo()
 {
     UndoManager.Undo();
     AdjustView();
     Dirty = true;
     equationRoot.AdjustCarets();
 }