- enhancement: Show shortcut info in toolbar's tooltip.

This commit is contained in:
Roy Qu 2023-03-17 15:37:11 +08:00
parent b4b41e43a1
commit eb93d8369e
6 changed files with 779 additions and 715 deletions

View File

@ -21,6 +21,8 @@ Red Panda C++ Version 2.18
- fix: Don't show completion info when input parameters for function definitions. - fix: Don't show completion info when input parameters for function definitions.
- fix: Don't show function info tips when typing class variable definitions. - fix: Don't show function info tips when typing class variable definitions.
- enhancement: Add option in the debug settings, to limit the length of the ouput generated by gdb for arrays. - enhancement: Add option in the debug settings, to limit the length of the ouput generated by gdb for arrays.
- enhancement: Show shortcut info in toolbar's tooltip.
Red Panda C++ Version 2.17 Red Panda C++ Version 2.17

View File

@ -2166,7 +2166,7 @@
<string>Run</string> <string>Run</string>
</property> </property>
<property name="shortcut"> <property name="shortcut">
<string>F10</string> <string>F11</string>
</property> </property>
</action> </action>
<action name="actionUndo"> <action name="actionUndo">

View File

@ -126,5 +126,10 @@ void ShortcutManager::applyTo(QAction *action)
PEnvironmentShortcut item = mShortcuts.value(action->objectName(), PEnvironmentShortcut()); PEnvironmentShortcut item = mShortcuts.value(action->objectName(), PEnvironmentShortcut());
if (item && item->isAction) { if (item && item->isAction) {
action->setShortcut(QKeySequence::fromString(item->shortcut)); action->setShortcut(QKeySequence::fromString(item->shortcut));
action->setToolTip(action->text()+QString("(%1)").arg(item->shortcut));
} else if (!action->shortcut().isEmpty()){
action->setToolTip(action->text()+QString("(%1)").arg(action->shortcut().toString()));
} else {
action->setToolTip(action->text());
} }
} }

View File

@ -818,15 +818,15 @@
</message> </message>
<message> <message>
<source>Skip system header and library files when step into</source> <source>Skip system header and library files when step into</source>
<translation>Ignorar os cabeçalho de sistema e os arquivos de biblioteca ao avançar</translation> <translation type="vanished">Ignorar os cabeçalho de sistema e os arquivos de biblioteca ao avançar</translation>
</message> </message>
<message> <message>
<source>Skip project header and library files when step into</source> <source>Skip project header and library files when step into</source>
<translation>Ignorar o cabeçalho de projeto e os arquivos de biblioteca ao avançar</translation> <translation type="vanished">Ignorar o cabeçalho de projeto e os arquivos de biblioteca ao avançar</translation>
</message> </message>
<message> <message>
<source>Skip custom header and library files when step into</source> <source>Skip custom header and library files when step into</source>
<translation>Ignorar o cabeçalho personalizado e os arquivos de biblioteca ao avançar</translation> <translation type="vanished">Ignorar o cabeçalho personalizado e os arquivos de biblioteca ao avançar</translation>
</message> </message>
<message> <message>
<source>Debug Console</source> <source>Debug Console</source>
@ -850,7 +850,7 @@
</message> </message>
<message> <message>
<source>Autosave</source> <source>Autosave</source>
<translation>Salvar automaticamente</translation> <translation type="vanished">Salvar automaticamente</translation>
</message> </message>
<message> <message>
<source>Autosave breakpoints</source> <source>Autosave breakpoints</source>
@ -858,7 +858,7 @@
</message> </message>
<message> <message>
<source>Autosave watches</source> <source>Autosave watches</source>
<translation type="vanished">Salvar automaticamente as observações</translation> <translation>Salvar automaticamente as observações</translation>
</message> </message>
<message> <message>
<source>Show CPU Window when signal received</source> <source>Show CPU Window when signal received</source>
@ -890,14 +890,38 @@
</message> </message>
<message> <message>
<source>Memory View Rows</source> <source>Memory View Rows</source>
<translation>Linhas da memória</translation> <translation type="vanished">Linhas da memória</translation>
</message> </message>
<message> <message>
<source>Memory View Columns</source> <source>Memory View Columns</source>
<translation>Colunas da memória</translation> <translation type="vanished">Colunas da memória</translation>
</message> </message>
<message> <message>
<source>Autosave breakpoints and watches</source> <source>Max number of array elements displayed</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Skip header files when step into</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>System library</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Project library</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Custom library</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rows</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Columns</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context> </context>
@ -3453,7 +3477,7 @@
</message> </message>
<message> <message>
<source>F10</source> <source>F10</source>
<translation>F10</translation> <translation type="vanished">F10</translation>
</message> </message>
<message> <message>
<source>Undo</source> <source>Undo</source>
@ -3561,7 +3585,7 @@
</message> </message>
<message> <message>
<source>F11</source> <source>F11</source>
<translation type="vanished">F11</translation> <translation>F11</translation>
</message> </message>
<message> <message>
<source>Rebuild All</source> <source>Rebuild All</source>

File diff suppressed because it is too large Load Diff

View File

@ -713,18 +713,6 @@
<source>GDB Server Port</source> <source>GDB Server Port</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Skip system header and library files when step into</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Skip project header and library files when step into</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Skip custom header and library files when step into</source>
<translation type="unfinished"></translation>
</message>
<message> <message>
<source>Debug Console</source> <source>Debug Console</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@ -745,10 +733,6 @@
<source>Show detail debug logs</source> <source>Show detail debug logs</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Autosave</source>
<translation type="unfinished"></translation>
</message>
<message> <message>
<source>Show CPU Window when signal received</source> <source>Show CPU Window when signal received</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@ -778,15 +762,35 @@
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<source>Memory View Rows</source> <source>Autosave watches</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<source>Memory View Columns</source> <source>Max number of array elements displayed</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<source>Autosave breakpoints and watches</source> <source>Skip header files when step into</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>System library</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Project library</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Custom library</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rows</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Columns</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context> </context>
@ -3284,10 +3288,6 @@
<source>Run</source> <source>Run</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>F10</source>
<translation type="unfinished"></translation>
</message>
<message> <message>
<source>Undo</source> <source>Undo</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@ -4900,6 +4900,10 @@
<source>Save settings failed!</source> <source>Save settings failed!</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>F11</source>
<translation type="unfinished"></translation>
</message>
</context> </context>
<context> <context>
<name>MemoryModel</name> <name>MemoryModel</name>