public void redoLastAction(){
  try {
    if (undoManager.canRedo())     undoManager.redo();
  }
 catch (  CannotRedoException cre) {
    cre.printStackTrace();
  }
}

public void redoLastAction ( ) { try { if ( undoManager . canRedo ( ) ) undoManager . redo ( ) ; } catch ( CannotRedoException cre ) { cre . printStackTrace ( ) ; } }
attempt to redo the last action .
