Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save GithubUser5462/d5258d34b720ee07e878a0635d77b1a4 to your computer and use it in GitHub Desktop.

Select an option

Save GithubUser5462/d5258d34b720ee07e878a0635d77b1a4 to your computer and use it in GitHub Desktop.
Disable the “Hold Key for Alternate Characters” Popup in KDE Plasma Login Manager

Disable the “Hold Key for Alternate Characters” Popup in KDE Plasma Login Manager

KDE Plasma can show a popup with accented or alternate characters when a key is held down.

Disabling it in your normal Plasma session does not necessarily disable it on the login screen, because Plasma Login Manager runs under its own system user and has its own configuration directory.

This guide applies to Plasma Login Manager (plasmalogin), not SDDM.

1. Disable the popup in your Plasma session

Open:

System Settings → Keyboard → On-Screen Keyboard

Disable:

Show popup when holding a key

This creates or updates:

~/.config/plasmakeyboardrc

The relevant contents are:

[General]
diacriticsHoldThresholdMs=600
diacriticsPopupEnabled=false

Verify:

cat ~/.config/plasmakeyboardrc

2. Find the Plasma Login Manager home directory

Do not assume that it is always /var/lib/plasmalogin.

Check the plasmalogin system account:

getent passwd plasmalogin

Print only its home directory:

getent passwd plasmalogin | cut -d: -f6

For example, on one Arch Linux installation this returned:

/usr/var/lib/plasmalogin

Therefore, the login manager configuration directory was:

/usr/var/lib/plasmalogin/.config/

3. Copy the keyboard configuration to Plasma Login Manager

The following command automatically uses the home directory configured for the plasmalogin account:

plasmalogin_home="$(getent passwd plasmalogin | cut -d: -f6)"

sudo install \
    -D \
    -o plasmalogin \
    -g plasmalogin \
    -m 600 \
    ~/.config/plasmakeyboardrc \
    "$plasmalogin_home/.config/plasmakeyboardrc"

This is preferable to hard-coding /var/lib/plasmalogin or /usr/var/lib/plasmalogin.

4. Verify the copied configuration

plasmalogin_home="$(getent passwd plasmalogin | cut -d: -f6)"

sudo -u plasmalogin cat \
    "$plasmalogin_home/.config/plasmakeyboardrc"

Expected output:

[General]
diacriticsHoldThresholdMs=600
diacriticsPopupEnabled=false

You can also verify the ownership and permissions:

ls -l "$plasmalogin_home/.config/plasmakeyboardrc"

It should be owned by plasmalogin.

5. Restart

Reboot the system:

systemctl reboot

After rebooting, holding a key on the Plasma Login Manager screen should no longer display the alternate-character popup.

Notes

  • The correct filename is plasmakeyboardrc, without a hyphen.
  • This procedure is for Plasma Login Manager.
  • SDDM configuration such as /etc/sddm.conf.d/ does not apply when Plasma Login Manager is being used.
  • The plasmalogin home directory can vary between distributions or package versions. Always confirm it with getent passwd plasmalogin.
  • Copying the complete plasmakeyboardrc file may also copy other keyboard-related settings stored in that file.

Comments are disabled for this gist.