Answer the question
In order to leave comments, you need to log in
Qt: how to make an action with a non-working hotkey?
We have a QTableView.
There is a key written directly in it - for example, Ctrl + A.
I want to push this command into the local menu, with the corresponding hint key: "Select all / Ctrl + A".
But this should only be a hint: Ctrl+A should not work if another component is selected. A command given through the local menu should always work.
How to implement?
Answer the question
In order to leave comments, you need to log in
Make your own menu, and use aboutToShow() to change the menu itself depending on the state.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question