public void redoAction() { try { if (undoMgr.canRedo()) { redoAction.actionPerformed(new ActionEvent(this, ActionEvent.ACTION_PERFORMED, "Redo")); setRedoItem(); } else { java.awt.Toolkit.getDefaultToolkit().beep(); } } catch (CannotUndoException ex) { ex.printStackTrace(); } }
public void selectLine() { Action selectLine = getAction(DefaultEditorKit.selectLineAction); if (selectLine != null) { selectLine.actionPerformed(null); } }