@Override
    public void actionPerformed(@NotNull ActionEvent e) {
      Object source = e.getSource();
      UndoManager manager = ClientProperty.get(source instanceof Component ? (Component)source : null, UNDO_MANAGER);
      if (manager != null && manager.canRedo()) {
        manager.redo();
      }
    }
@Override
    public void actionPerformed(@NotNull ActionEvent e)