Global Shortcuts

Eike Hein hein at
Mon Mar 17 18:19:49 GMT 2008

Michael Jansen wrote:
>    No global shortcuts without my consent. Basta. A application is allowed to
>    advertise actions it thinks are appropriate for global shortcuts, and give
>    default values, but after starting the application the first time they
>    arent active. It's opt-in.

There are certain types of applications that have their UI
hidden by default, and rely on a global shortcut to reveal
themselves. Yakuake is one, Katapult is another, one of the
KDE Beagle frontends does it to, iirc. Without that short-
cut, the apps aren't usable. IOW, with regard to your
"those aren't apps, those are the desktop" reaction to the
kwin/Plasma features: Some apps aim for a similar "it's a
service of my environment" user experience.

Yakuake presently defaults its Open/Retract action to F12.
At first startup, it displays a first run dialog with an
info message, along with a KKeyButton that shows the glo-
bal hotkey and allows changing it, which is also where
the conflict checking takes place. After clicking Ok or
Cancel in the first run dialog, the main window rolls out.
On subsequent application startups, the main window re-
mains hidden until the global shortcut is triggered to re-
veal it (the shortcut is shown in a KPassivePopup in the
screen corner at subsequent startups, unless it is dis-
abled). The KShortcutDialog is only accessible through the
main window.

Bottom line: If global shortcuts are made opt-in, that opt-
in must be public API so that e.g. said first run routine
can register the shortcut as active, even when the user
dismisses the dialog with its default value (since the app
won't be accessible without it once the window gets closed
or during the next app session). If it's public API, how-
ever, apps authors are going to do it anyway, pretty much
screwing over the opt-in thing.

Eike Hein, hein at

More information about the kde-core-devel mailing list