Cutter: Add Hotkeys for "Undo Seek" and "Redo Seek" menu options

Created on 16 Mar 2019  路  11Comments  路  Source: rizinorg/cutter

Is your feature request related to a problem? Please describe.

Shortcut for undo and redo seek are missing

Describe the solution you'd like

Add Hotkeys for "Undo Seek" and "Redo Seek" menu options

Enhancement UI good first issue

All 11 comments

Working on this one right now! Just wondering what keys I should bind to. I'm thinking C-z for undo and C-r for redo since that is the usual binding for most programs.

How about QKeySequence::Back and QKeySequence::Forward ?

You know, that sounds better actually, since that's essentially what these do. Thanks!

I think that ESC is already there for "undo seek"

I think that ESC is already there for "undo seek"

It is. Is there a good reason to add another hotkey for "undo seek" other than proximity on the keyboard?

@maijin

Well if undo seek is done, only remain redo seek then if not already done

  • Undo seek currently is handled in certain widgets like disassembly not globally
  • Undo seek/redo seek actions in main window are duplicated, it should be possible add single action in multiple menu.

Where would be the best place to add a hotkey for redo seek then?

Try adding something like ui->actionForward->setShortcut(QKeySequence::Forward); to mainwindow.

While on it I also recommend deduplicating the action and leaving one which has more details (actionForward/actionBack). Not sure if it can be done through GUI editor but it's straight forward by editing .ui file, because action definition and adding it to menu are two seperate tags.

That works, where is the best place in mainwindow to add this?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Maijin picture Maijin  路  5Comments

AxelPotato picture AxelPotato  路  4Comments

karliss picture karliss  路  3Comments

kidmose picture kidmose  路  5Comments

nauliajati picture nauliajati  路  3Comments