ksuperkey

Various Plasma 5 Improvements

Source (link to git-repo or to original if based on someone elses unmodified work): https://github.com/hanschen/ksuperkey

16
Score 85.8%
Description:

ksuperkey allows you to open the application launcher in KDE Plasma < 5.8 using the Super key (also known as the 'Windows key'). Unlike other solutions, it will not affect your current keyboard shortcuts, as the Super key will still act as a modifier when held down.

Note that ksuperkey does not depend on any specific desktop environment and should work fine on KDE Plasma 4, Plasma 5, GNOME Shell, Unity, Xfce, LXDE, etc.

Also note that this feature is available by default starting from Plasma 5.8.

ksuperkey is a fork of xcape (https://github.com/alols/xcape), most of the work was done by the original author Albin Olsson.


Installation

Distribution-specific instructions

Below is a list of distribution-specific ways to install ksuperkey.

Note that some packages are provided by a third party and that I do not take any responsibility for their contents.

Arch Linux: Available from the official repo ([community])

Chakra: Installed by default, available from the official repo

Debian: https://launchpad.net/~mehanik/+archive/ubuntu/ksuperkey

Fedora: https://copr.fedoraproject.org/coprs/vanoudt/KSuperkey/

Gentoo: emerge ksuperkey

Kubuntu: https://launchpad.net/~mehanik/+archive/ubuntu/ksuperkey

Mint: https://launchpad.net/~mehanik/+archive/ubuntu/ksuperkey

Netrunner: Installed by default, available from the official repo

openSUSE: https://software.opensuse.org/package/ksuperkey

PCLinuxOS: Available from the official repo

Ubuntu: https://launchpad.net/~mehanik/+archive/ubuntu/ksuperkey

Did I miss your favorite distribution? Please add a comment below with instructions on how to install it in your distro!


Compiling from source

If there is no package for ksuperkey for your distribution, you can compile the program from source following these instructions:

1. Install dependencies. On Ubuntu:

sudo apt-get install gcc make libx11-dev libxtst-dev pkg-config

On some system you'll also have to install the build-essential package.

2. Download ksuperkey-0.4 (Source) from this page and extract the tar.gz file (using e.g. Ark).

3. Go to the newly extracted directory called ksuperkey, open a terminal (press F4 in Dolphin), and run:

make

3b. Optionally, if you want to install ksuperkey to the standard PATH for all users:

sudo make install

4. Launch ksuperkey:

./ksuperkey

or by clicking on its icon. ksuperkey will run in the background. (If you did step 3b, you can just type "ksuperkey" from anywhere to launch it.)

5. Try to press the left Super key. If the application launcher does not show up, make sure that its shortcut is set to Alt+F1:
right click on the application launcher icon -> Application Launcher Settings -> Keyboard Shortcut.

6. (Optional) Make ksuperkey autostart in System Settings -> Startup and Shutdown -> Autostart -> Add Program... -> Browse button -> select the ksuperkey application.

Change mapping

If you do not like the default mapping (Super_L to Alt+F1), you can tell ksuperkey to use another mapping. The syntax is as follows:

ksuperkey -e 'ModKey=Key[|otherkey][;nextexpression]'

Looks complicated? Do not worry, it really is not. Let us look at some examples:

Make Super key open KRunner (Alt+F2)

ksuperkey -e 'Super_L=Alt_L|F2'

We have more modifier keys on our keyboard, why not use them?

ksuperkey -e 'Control_L=Alt_L|F1;Super_L=Alt_L|F2;Shift_L=Control_L|S'

This makes the left Ctrl key generate Alt+F1 (application launcher), left Super generate Alt+F2 (KRunner), and left Shift generate Ctrl+S (save the current document) when pressed and released on their own.

Autostart

If you want to add your custom mapping to Autostart:

1. Follow the instructions in 4. under Installation.
2. When you see the dialog with the tabs (General, Permissions, Application, etc.), click on the Application tab.
3. Add the -e option to the Command field. It could look something like this:

/home/myname/ksuperkey/ksuperkey -e 'Super_L=Alt_L|F2'

Troubleshooting

1. ksuperkey does not work.

Make sure that ksuperkey is running (use e.g. the system monitor, Ctrl+Escape) and that it is running only once.

Also check that the keyboard shortcut for the application launcher is set to Alt+F1, see 4. under Installation.

Finally, make sure you do not remap the Super (Win) key, for example in System Settings -> Input Devices -> Keyboard -> Advanced or by using xmodmap.

2. When I try to change the mapping, I get 'command not found: ksuperkey'

When following the installation instructions above, kusperkey will not be installed to $PATH. This means that your shell does not know where to find ksuperkey. Therefore you have to specify the full path to the executable, e.g.

~/ksuperkey/ksuperkey -e 'Super_L=Alt_L|F2'

3. I remap my keys (e.g. using xmodmap) and ksuperkey does not behave as I want it to.

Try to restart ksuperkey every time after doing the remapping. Also make sure that the key you send has a defined keycode.

4. When I type 'make' I get "xcape.c:22:20: fatal error: stdlib.h: No such file or directory"

You need to install the build-essential package, e.g.

sudo apt-get install build-essential

Tips

You no longer have to bind Alt+F1 to the thing you want ksuperkey to trigger, since you can easily change the mapping! (See "Change mapping" section above.)

For more options, see included README.md or the Github page: https://github.com/hanschen/ksuperkey

Contact

Please post issues to Github:
https://github.com/hanschen/ksuperkey/issues

I will try to answer questions here.
Last changelog:

3 years ago

0.4
- Allow keycodes in map expressions. [upstream]
- Fix Makefile to make it easier to package.

0.3
- XKeycodeToKeysym has been deprecated, use XkbKeycodeToKeysym instead. [upstream]

0.2
- It is now possible to define your own mappings (e.g. Super_L to Alt+F2) without editing the source code. [upstream]

0.1
- Initial release

Longstreet

5 years ago

Running Mint 15 w/KDE, and this worked great. Thanks!

Report

C

Mogger

5 years ago

Cool, thanks for packaging it.

Report

Qwerty9362

6 years ago

This is the only way that I've found to map the meta key to the KMenu without disallowing the use of meta as a modifier, and it works great on Kubuntu 13.04. :)

Report

C

Mogger

5 years ago

Glad to hear that it works well for you!

Report

Gyges

6 years ago

Thank you so much for your effort! Especially for doing it without using it yourself, you're my Foss hero of the day!
Compiles and works great on Sabayon, just had to install pkg-config before.

Report

C

Mogger

6 years ago

Thanks for your kind comment!

Report

yvanb

6 years ago

Great app. Simple and efficient. Does exactly what it says, easy to compile, easy to install, then you forget it, and simply use the extra Superkey feature like with other desktops or OS.

This lack of the superkey feature was the only "uncool" thing with KDE. Now it makes KDE far supperior to any other !

Thanks !

Report

C

Mogger

6 years ago

You're welcome, and thanks for the nice comment!

Report

scra5071

6 years ago

I'm having trouble installing. When i get to the make line I receive the following:

george@George-Linux-Mint-14 ~/ksuperkey $ make
cc -Wall `pkg-config --cflags xtst x11` -o ksuperkey xcape.c `pkg-config --libs xtst x11` -pthread
xcape.c:22:20: fatal error: stdlib.h: No such file or directory
compilation terminated.
make: *** [ksuperkey] Error 1

Any help would be appreciated.

Report

C

Mogger

6 years ago

Already answered on my blog, but putting the answer here as well for people with the same problem:

You probably need to install the build-essential package,

sudo apt-get install build-essential

I've added a comment about it in the install instructions.

Report

jospoortvliet_double

6 years ago

I'm guessing this would be best as a daemon part of KDED... Then there wouldn't be an extra binary needed, saving memory and all that. Maybe a nice suggestion for the future ;-)

Report

C

Mogger

6 years ago

Thanks Jos! Someone else suggested turning it into a kded module (I think it was d_ed). My answer is the same as back then - I would welcome anyone to give it a try, but I personally don't have the motivation since I don't use ksuperkey myself.

(Besides, the ksuperkey process takes about 0.001 % RAM on my system, so performance-wise I don't think it'll make a big difference. ;)

Report

Murz

6 years ago

Many thanks for this app! It will very useful, but don't want work on my Kubuntu 12.10 - it starts normally, but when I press Win - Alt-F1 action is not executed. Is this app have any debug mode for checking where can be the problem?

Report

Murz

6 years ago

Oh, sorry for the noise, the problem is with .Xmodmap file in which I remap this button to F13, removing this file solves the problem!

So now all works well!
Many thanks for this app!

Report

C

Mogger

6 years ago

Great that you found the problem, and thanks for posting the solution. For future reference, there's the -d option you can use to get more information (ksuperkey -d). xev is also a useful tool.

Report

KZKG-Gaara

6 years ago

Thanks for this tip!!
I publish a post about this: http://blog.desdelinux.net/abrir-y-cerrar-el-menu-de-inicio-de-kde-al-presionar-la-tecla-win-o-tecla-super/

Again... thanks for all :)
Greetings

PS: Sorry for my english, it's not my primary language

Report

pacorayban

6 years ago

You are a Genius !
Thank you for this great addon !
And thanks for the aur package !

Report

C

Mogger

6 years ago

Glad you like it, thank you for your comment. :)

Report

C

Mogger

6 years ago

Wonderful, thank you for spreading the word!

I saw some comments expressing concern that their Super+<something> shortcuts would stop working. The great news is that ksuperkey still allows you to use the Super key with shortcuts. Here's how it works:

- If you press and release Super, ksuperkey will send Alt+F1.
- However, if you hold down Super, it'll still act as a modifier key.

In other words, ksuperkey shouldn't mess with any existing shortcuts.

Report

KZKG-Gaara

6 years ago

My pleasure ^-^

Yes, several users asked but finally between all of us clarify, in effect, does not interrupt other key combinations.

Thanks again... and, again, sorry for my english ;)

Report

C

Mogger

6 years ago

Added K/Ubuntu DEB package, created by greatperson from the KDE forums: http://forum.kde.org/viewtopic.php?f=83&t=39073&p=251929&#p251929

It adds ksuperkey to autostart automatically.

Report

C

Mogger

6 years ago

Added link to AUR for Arch Linux users.

Report

svah4cky0

6 years ago

Thanks man

Report

FraMari

6 years ago

Hi!
I uploaded this package to the CCR (Chakra Community Repository).http://chakra-linux.org/ccr/packages.php?ID=4464
Thanks a lot!

Report

C

Mogger

6 years ago

Nice, thanks for adding it to CCR! I've updated the page with a link to your package.

Report

3 years ago

0.4
- Allow keycodes in map expressions. [upstream]
- Fix Makefile to make it easier to package.

0.3
- XKeycodeToKeysym has been deprecated, use XkbKeycodeToKeysym instead. [upstream]

0.2
- It is now possible to define your own mappings (e.g. Super_L to Alt+F2) without editing the source code. [upstream]

0.1
- Initial release

12345678910
34
product-maker psyoma Oct 05 2016 9 excellent
product-maker x-varlesh-x Aug 17 2016 9 excellent
product-maker hacklov Oct 18 2015 9 excellent
product-maker PulsarSuse Sep 06 2015 9 excellent
product-maker roctheme Aug 30 2015 9 excellent
product-maker janet Aug 25 2015 9 excellent
product-maker RingOV Aug 23 2015 9 excellent
product-maker OlafLostViking Aug 17 2015 9 excellent
product-maker jerik Aug 15 2015 9 excellent
product-maker miabraha Jun 24 2015 9 excellent
product-maker macik Mar 11 2015 9 excellent
product-maker jota Apr 29 2014 9 excellent
product-maker amr2205 Feb 15 2014 9 excellent
product-maker balur Jan 30 2014 9 excellent
product-maker jeggy Dec 19 2013 9 excellent
product-maker brdn25 Oct 31 2013 9 excellent
product-maker ChrisAshton84 Sep 18 2013 9 excellent
product-maker yvanb May 01 2013 9 excellent
product-maker ZaWertun Mar 09 2013 9 excellent
product-maker antonisk Feb 25 2013 9 excellent
product-maker augegr Feb 04 2013 9 excellent
product-maker dmnmsc Jan 26 2013 9 excellent
product-maker Murz Jan 09 2013 9 excellent
product-maker pacorayban Nov 27 2012 9 excellent
product-maker alpvonkri Nov 11 2012 9 excellent
product-maker sxe Nov 10 2012 9 excellent
product-maker swiftscythe Nov 09 2012 9 excellent
product-maker cjann Oct 19 2012 9 excellent
product-maker svah4cky0 Oct 09 2012 9 excellent
product-maker vitoubien Oct 08 2012 9 excellent
product-maker cgonzalez Oct 08 2012 9 excellent
product-maker Contrast Oct 08 2012 9 excellent
product-maker damianatorrpm Oct 08 2012 9 excellent
product-maker greatperson Oct 08 2012 9 excellent
product-maker Count: 4 Rating: 5.0
File (click to download) Version Description Downloads Date Filesize DL OCS-Install
Pling
*Needs ocs-url or ocs-store to install things
Details
license
version
0.4
updated Sep 10 2017
added Oct 08 2012
downloads today
1
page views today 27