ReimuNotMoe / ydotool

Generic command-line automation tool (no X!)
GNU Affero General Public License v3.0
1.52k stars 81 forks source link

Keyboard layout setting ignored in Plasma 6.2 #254

Open stupidus89 opened 1 month ago

stupidus89 commented 1 month ago

I am using ArchLinux with ydotool-git (but the issue is the same with the version from the repos). ydotool-1:1.0.4.r33.gb0c5da3-1

I am using de nodeadkeys as a keyboard layout.

In Plasma 6.2 running ydotool type a@b-c results in a"bßc.

In sway on the same system it types the correct string.

This is what I have in my ~/.config/kxkbrc:

[Layout]
LayoutList=de
Model=pc105
Options=caps:escape,compose:rctrl
ResetOldOptions=true
Use=true
VariantList=nodeadkeys

And this in my sway config:

input 1:1:AT_Translated_Set_2_keyboard {
    xkb_layout "de"
    xkb_variant "nodeadkeys"
    xkb_options "kpdl:dot,compose:rctrl,caps:escape"
}

This might of course also be a problem with plasma, as I think that it used to work correctly with Plasma 6.1.

EDIT: I did some more investigation and I found that if I set the following environment variables, then it also gives the wrong output in sway:

export XKB_DEFAULT_LAYOUT=de
export XKB_DEFAULT_VARIANT=nodeadkeys

If I remove those variables and relog then I get the correct output in sway again. I also tried a strace on both plasma and sway, but there was no difference.