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

Can't change activity-related key bindings

Tags: None
(comma "," separated)
petrbren
Registered Member
Posts
8
Karma
0
Hello everybody

I have a problem trying to change activity-related key bindings in Plasma 5.

In older versions (KDE 4.x) this can be set up using System Settings > Shortcuts and Gestures > Global Keyboard Shortcuts > KDE Component: KDE Activity Manager - Add custom shortcuts.

However, in Plasma 5 there is no Activty Manager in the KDE component menu, despite the fact that the package kde-plasma-activitymanager is installed and kactivitymanagerd is running.

In particular I need to get rid of Alt+A as that is used for "go to beginning of sentence" in Emacs.

My system is Fedora 23, KDE 5.5.5, Qt 5.5.1.

Thank you very much
petrbren
Registered Member
Posts
8
Karma
0
I have to correct my previous assertion about the problem being new with KDE Plasma 5.

I just checked KDE4 in Debian 8 and CentOS 7 and the Alt+A is indeed impossible to change there as well.

Searching for Alt+A in KDE's config files doesn't return anything except Ctrl+Alt+A which is for something different.

The Alt+A seems to be hard-coded in KDE. Disappointing for Emacs users. Any chance of that changing in the future?
wolfi323
Registered Member
Posts
1129
Karma
11
OS
petrbren wrote:The Alt+A seems to be hard-coded in KDE. Disappointing for Emacs users. Any chance of that changing in the future?

I don't think so.
Alt+A has absolutely no effect here.

What exactly does it do on your system?
If it opens the activity manager, right-click on the icon and choose "ActivityManager Settings" to change the keyboard shortcut.

The shortcuts for switching activities can be changed in systemsettings5->Shortcuts->Global Keyboard Shortcuts like you wrote.
There should be a component "Activity switching" and "kactivitymanagerd" there.
petrbren
Registered Member
Posts
8
Karma
0
I'm pretty sure the Alt+A is supposed to do something. See the screenshot at https://screencloud.net/v/tv8P - it's a menu that appears when I right-click a desktop background in folder view. It looks very similar on all KDE4 and Plasma 5 desktops I tested (Redhat-based and Debian-based distros).

And when I search for the Alt+A string in KDE's config files, all I find is the unrelated Ctrl+Alt+A. This is what makes me think that the Alt+A is hardcoded.

Code: Select all
$ grep -R Alt+A .kde/ .config/
.kde/share/config/kglobalshortcutsrc:Activate Window Demanding Attention=Ctrl+Alt+A,Ctrl+Alt+A,Activate Window Demanding Attention
.config/kglobalshortcutsrc:Activate Window Demanding Attention=Ctrl+Alt+A,Ctrl+Alt+A,Aktivovat okno vyžadující pozornost
wolfi323
Registered Member
Posts
1129
Karma
11
OS
petrbren wrote:I'm pretty sure the Alt+A is supposed to do something. See the screenshot at https://screencloud.net/v/tv8P - it's a menu that appears when I right-click a desktop background in folder view.

No.
That context menu only contains Alt+D, Alt+A (i.e. press Alt-D and then Alt+A) to open the activity manager.
This indeed seems to be hardcoded, but it only works when no window is active.
petrbren
Registered Member
Posts
8
Karma
0
wolfi323 wrote:That context menu only contains Alt+D, Alt+A (i.e. press Alt-D and then Alt+A) to open the activity manager.
This indeed seems to be hardcoded, but it only works when no window is active.

If that's the case, why is it impossible to use Alt+A in an application which uses it for its own purposes when the application is running under KDE while it is possible to use it in the same application on the same system under a different DE?

(I'm not criticizing KDE. I've been using it since 1999 and only came across this thing while learning Emacs.)
User avatar
einar
Administrator
Posts
3402
Karma
7
OS
The default shortcut to bring up the activity manager, IIRC, is Meta-Q. To change activity-related key bindings, there should be a global component called "KDE Activity Daemon" or something of the sort in the global configuration dialog.


"Violence is the last refuge of the incompetent."
Image
Plasma FAQ maintainer - Plasma programming with Python
wolfi323
Registered Member
Posts
1129
Karma
11
OS
petrbren wrote:If that's the case, why is it impossible to use Alt+A in an application which uses it for its own purposes when the application is running under KDE while it is possible to use it in the same application on the same system under a different DE?

I don't know.
Alt+A works fine here in Emacs, inside KDE4 and Plasma5 (I just tried). So Alt+A is definitely not "hard-coded in KDE"...

You still didn't answer what Alt+A actually does on your system. Is there no reaction at all?

Do you see the same problem with a fresh user account? It might be some user-specific problem.

Maybe it's bound to something else on your system for whatever reason. (it should show up in the config files then, but maybe some non-KDE application grabs it?)
If you assign Alt+A to some other action in systemsettings5, does it work then?

einar wrote:The default shortcut to bring up the activity manager, IIRC, is Meta-Q.

Actually it is Super (i.e. the Windows key on most PC keyboards) + Q...
petrbren
Registered Member
Posts
8
Karma
0
It's happening under a new user account as well.
I tried changing the keyboard layout, but no luck. I tried to launch KDE from a different display manager, still no luck.

When I press Alt+A in Emacs it doesn't do anything, When I hold the combination for some time, the cursor is blinking but nothing else happens.
When I assing Alt+A to a different action in KDE systemsettings, nothing changes in terms of Emacs's behavior.

The behavior is the same in KDE4 in Debian 8 and CentOS 7 and in Plasma 5 in Fedora. I will test it in openSUSE from a live USB to see what's different and let you know the results.
wolfi323
Registered Member
Posts
1129
Karma
11
OS
petrbren wrote:It's happening under a new user account as well.
I tried changing the keyboard layout, but no luck. I tried to launch KDE from a different display manager, still no luck.

The display manager should not make a difference.

But what if you run Emacs in a different desktop?
Does it work then? If not it's clearly an Emacs problem (e.g. its settings) or something system-wide, not KDE related.

When I press Alt+A in Emacs it doesn't do anything, When I hold the combination for some time, the cursor is blinking but nothing else happens.

If the key combination was grabbed by KDE, the emacs cursor should not blink either, I suppose.

Though I have to say that here the cursor in Emacs blinks all the time. If I hold down Alt+A for a while, it actually *stops* blinking...

When I assing Alt+A to a different action in KDE systemsettings, nothing changes in terms of Emacs's behavior.

It was not supposed to change anything in Emacs.
My question was whether you get an error message that the combination is already assigned to some action, or whether the newly assigned action works as expected if you press the key combination.
petrbren
Registered Member
Posts
8
Karma
0
In my case the cursor is blinking in Emacs normally as well, but when I hold Alt+A for a few seconds the cursor starts blinking very fast.

Update: when I assign Alt+A to 'New Activity' in systemsettings, it is grabbed by KDE and new activity is activated when I press Alt+A, even when I do that in an Emacs window.

Edit: yes, when I run Emacs under another DE on the same system, the problem disappears and Emacs acts as it should.
dvzubarev
Registered Member
Posts
2
Karma
0
Hi, I have a similar problem.
I have recently installed kubuntu 16.04 (kded5 5.18.0, plasmashell 5.5.5) and
alt-d does not work in Konsole or Emacs.
I debugged globally grabbed keys by running

Code: Select all
xdotool key "XF86LogGrabInfo"

Then I got the deciphered description by using this https://gist.github.com/CyberShadow/6412d11aea64144f8905cc0b8196f38e.
Code: Select all
 rdmd xorg-show-grabs.d --xorg-log=./Xorg.0.log

It showed among the others following globally grabbed shortcuts:
13992 /usr/bin/kglobalaccel5:
Mod1(Alt) + d
Mod1(Alt) + g
Mod1(Alt) + grave
Mod1(Alt) + h
Mod1(Alt) + r
Mod1(Alt) + s

But I did not find any of this in Global Keyboard Shortcuts manager in system settings.
Creating a new user did not help either.

It is interesting enough that when I run /usr/bin/kglobalaccel instead of /usr/bin/kglobalaccel5,
Alt+d works fine for me.

So I switched to /usr/bin/kglobalaccel as a temporary solution.
petrbren
Registered Member
Posts
8
Karma
0
So I switched to /usr/bin/kglobalaccel as a temporary solution.

Silly question, but how do I do that in Fedora 23? I have no kglobalaccel configuration in my home directory and the repository only has one version of it. Do I need to get a package from an older version of the distribution?
petrbren
Registered Member
Posts
8
Karma
0
I also found that this affects Alt+H (History) in Firefox on all my KDE installations (Alt+H does nothing in Firefox under KDE). That's quite important!

I didn't have an opportunity to test how this is handled in openSUSE yet, as the iso images seem to be UEFI-only while my test box is BIOS-only. Can you recommend me a version of openSUSE that I can boot on a BIOS-only system?
wolfi323
Registered Member
Posts
1129
Karma
11
OS
petrbren wrote:I didn't have an opportunity to test how this is handled in openSUSE yet, as the iso images seem to be UEFI-only while my test box is BIOS-only. Can you recommend me a version of openSUSE that I can boot on a BIOS-only system?

All of them should boot fine on a BIOS-only system.

FYI, I don't have UEFI at all.


Bookmarks



Who is online

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