This forum has been archived. All content is frozen. Please use KDE Discuss instead.

How to create "a keyboard shortcut with *any* plasmoid you want"

Tags: None
(comma "," separated)
User avatar
tkoski
Registered Member
Posts
371
Karma
3
OS
(Before I forget, all the thanks to this goes to member aseigo who shared his wisdom on another thread.)

At the moment KDE4 is missing integrated UI for this, so it needs to be done by hand:

Code: Select all
$ kquitapp plasma;
$ vim `kde4-config --localprefix`/share/config/plasma-appletsrc;


Next find the plugin and add a [Containment][#][Applet][#][Shortcuts] group with a global= entry.

And last :
Code: Select all
$ start plasma


Attitude before intelligence.
User avatar
Jucato
Registered Member
Posts
67
Karma
1
OS
Just an example to make things clearer. This one "re-maps" Alt+F1 to the K Menu (since it stopped working for me for some reason). Suppose in your plasma-appletsrc file you have an entry like this:

Code: Select all
[Containments][3][Applets][54]
geometry=0,4,36,36
immutability=1
plugin=launcher
zvalue=0


The key here is plugin=launcher, which describes what widget it is. In this case, it's the Application Launcher (K Menu). Take note of the Containment number (3) and Applet number (54). Your numbers may vary.

Now, once you've found the applet you'd like to give a shortcut to, add this to the file:

Code: Select all
[Containments][3][Applets][54][Shortcuts]
global=Alt+F1


So that it looks like this combined:

Code: Select all
[Containments][3][Applets][54]
geometry=0,4,36,36
immutability=1
plugin=launcher
zvalue=0

[Containments][3][Applets][54][Shortcuts]
global=Alt+F1


Notice that the Containment and Applet number should match. Now all you need is to start Plasma by pressing Alt+F2 and typing:

Code: Select all
plasma


Hope that helps.


Jucato, proud to be a member of KDE forums since 2008-Oct.
User avatar
widux
Registered Member
Posts
64
Karma
1
OS
Hm, does not work for me.
For example, this is an entry in my plasma-appletsrc:

Code: Select all
[Containments][136][Applets][157]
geometry=517.33234859675,0,30,30
immutability=1
plugin=icon
zvalue=0

[Containments][136][Applets][157][Configuration]
Url=file:///usr/share/applications/kde4/systemsettings.desktop


As you can see this starts systemsettings from a panel entry.
I added this:

Code: Select all
[Containments][136][Applets][157][Shortcuts]
global=Meta+C


What's wrong?I also changed "Meta" to "Alt", but nothings happened.

Could you help me?

Greez an Thanx

w.


Scholars.de
sidux "aether" KDE 4.2.4
Kernel: 2.6.30-1-686
Box: Lenovo 3000 N100
Graphics: nVidia G72M [Quadro NVS 110M/GeForce Go 7300] - NVIDIA 185.18.14
WLAN: Intel PRO/Wireless 3945ABG

widux, proud to be a member of KDE forums since 2008-Oct.
User avatar
Jucato
Registered Member
Posts
67
Karma
1
OS
Actually I tried it as well... seems like the only plasmoid that reacts to it is the Application Launcher :(


Jucato, proud to be a member of KDE forums since 2008-Oct.


Bookmarks



Who is online

Registered users: bartoloni, Bing [Bot], Google [Bot], Yahoo [Bot]