Add some additional shortcuts for actions

Add Cmd+Shift+- for decreasing font size on macOS.
Do not add Cmd+= for increasing size, because it conflicts with the
existing shortcut for "Replace and Find Next".

Sprinkle some Backspace shortcuts in addition to Delete for removing
items. There are (laptop) keyboards that either do not have a designated
Delete key (requiring Fn+Backspace) or where the Delete key is not
conveniently located/sized, and there is no benefit in making the
distinction in that case anyhow.

Fixes: QTCREATORBUG-706
Fixes: QTCREATORBUG-13733
Change-Id: I06274a9810b82800ec6158a883c95d2a7ae2465e
Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
Eike Ziller
2020-03-09 10:30:41 +01:00
parent 0ff5bf75e1
commit ed5e6a4999
20 changed files with 30 additions and 29 deletions

View File

@@ -1509,7 +1509,7 @@ bool BreakHandler::setData(const QModelIndex &idx, const QVariant &value, int ro
return contextMenuEvent(ev);
if (auto kev = ev.as<QKeyEvent>(QEvent::KeyPress)) {
if (kev->key() == Qt::Key_Delete) {
if (kev->key() == Qt::Key_Delete || kev->key() == Qt::Key_Backspace) {
QModelIndexList si = ev.currentOrSelectedRows();
const Breakpoints bps = findBreakpointsByIndex(si);
for (Breakpoint bp : bps) {
@@ -2547,7 +2547,7 @@ bool BreakpointManager::setData(const QModelIndex &idx, const QVariant &value, i
return contextMenuEvent(ev);
if (auto kev = ev.as<QKeyEvent>(QEvent::KeyPress)) {
if (kev->key() == Qt::Key_Delete) {
if (kev->key() == Qt::Key_Delete || kev->key() == Qt::Key_Backspace) {
QModelIndexList si = ev.currentOrSelectedRows();
const GlobalBreakpoints gbps = findBreakpointsByIndex(si);
for (GlobalBreakpoint gbp : gbps)