Commit 071868eb authored by Nate Graham's avatar Nate Graham
Browse files

[klipper] Set a default shortcut for "Open Klipper at Mouse Position"

This is a mind-blowingly amazing feature, but nobody knows about it
because it's disabled by default since it has no default shortcut, and
there is no visible UI to tell you about it except for the shortcut
configuration view buried in Klipper's settings window.

A similar feature was just recently introduced in Microsoft Windows, and
users have started to ask why no equivalent KDE feature exists, because
they are unaware that it already does! The shortcut Microsoft chose is
Meta+V, which is a completely sensible one. If we set the same shortcut
for the Klipper feature, discoverability is automatically increased
because users familiar with Windows are already becoming accustomed to the
Meta+V shortcut. This is not an argument for deliberately copying
another platform, but rather making use of the user familiarity that
they have helpfully done the hard work of creating for us. Meta+V is
unused and is an appropriate shell-level global shortcut by virtue of
using the Meta key. So let's bind it to this Klipper feature by default.
parent 75d90253
......@@ -199,7 +199,7 @@ Klipper::Klipper(QObject *parent, const KSharedConfigPtr &config, KlipperMode mo
// Action to show Klipper popup on mouse position
m_showOnMousePos = m_collection->addAction(QStringLiteral("show-on-mouse-pos"));
m_showOnMousePos->setText(i18n("Open Klipper at Mouse Position"));
KGlobalAccel::setGlobalShortcut(m_showOnMousePos, QKeySequence());
KGlobalAccel::setGlobalShortcut(m_showOnMousePos, QKeySequence(Qt::META + Qt::Key_V));
connect(m_showOnMousePos, &QAction::triggered, this, &Klipper::slotPopupMenu);
connect(history(), &History::topChanged, this, &Klipper::slotHistoryTopChanged);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment