Solved XFCE and keyboard layout after suspend

I use XFCE on a desktop, and am mostly happy with it. But I have found one issue that I have not been able to find a solution for.
If I suspend to memory my desktop wakes up from it almost instantly when I want it to, but my native language keyboard layout is replaced with what I assume is a default American English layout. Other strange things happen also, like the up arrow makes it want to take a screenshot.
In this situation, the keyboard layout is not possible to change with the XFCE configuration settings or the XFCE keyboard layout plugin. The only way to restore it is to log out and log in again.
Googling for this issue I only find solutions that involves modifying linux distro specific configuration files, which isn't much help.
So before switching to KDE, which I know work, I wonder if anyone has found a fix/workaround for this issue?
 
Does setxkbmap <keyboard shortcup> in the terminal help? Guessing you are using a Swedish layout:
Code:
setxkbmap se

I don't see this behaviour in my Xfce installation. But over the years I have seen many strange things when awaking graphical environments from hibernation mode - in Windows, MacOS, Linux.

Hope it helps
 
You are absolutely right, thanks a lot! Now I just have to figure out how to execute it automatically at wake up.
 
I have tried with
Code:
more /usr/local/etc/X11/xorg.conf.d/00-keyboard.conf
Section "InputClass"
        Identifier "system-keyboard"
        MatchIsKeyboard "yes"
        Option "XkbLayout" "sv"
        Option "XkbModel" "pc105"
EndSection
but it doesn't have any effect. I think XFCE is involved and messes with the keyboard layout.
 
In this situation, the keyboard layout is not possible to change with the XFCE configuration settings or the XFCE keyboard layout plugin.
Is Xfce configured not to set the keyboard map itself but to follow system-wide settings? If I remember correctly this should be an option in the keyboard settings panel. If enabled, try disabling it, and vice versa.
 
Back
Top