-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changing keyboard layout #908
Comments
You can use Emacs input methods in EXWM via This requires a little bit of setup, on the Emacs side:
and on your session level, these environment variables:
For the occasional case where I have to type something in Russian or Arabic in a Qt-window (e.g. Quassel IRC), I have shortcuts that use |
I don't fully understand the issue, possibly because I don't usually change keyboard layouts. There is some support in EXWM for updating the global keys "when the keyboard is updated" (see Please, create a minimum configuration and set of steps that allow me to reproduce the issue (see for example #924 (comment)). |
I don't completely understand the issue either, but I have had a good experience mapping my keyboards with kmonad/kmonad: An advanced keyboard manager rather than |
Well, I just spent an hour or two but couldn't get a truly minimal config working (couldn't get a minimal exwm config to work on my system for some reason). However, I was able to narrow down some cases where the problem occurs and where it doesn't, so maybe this will be enough for you to reproduce it. Potentially confounding configurationI'm not expecting you to try reproducing my configs; just thought I should mention them briefly since I wasn't able to bypass them to make a working minimal setup. Variant A - produces problemIn xinitrc:
Once exwm is loaded:
Expected result -> nothing unusual happens; chord input correctly In some terminal:
Changes the layout back to qwerty. Most keys should work as expected in any emacs buffer, or when typing in firefox (e.g. input fields, C-t for new tab, etc.)
Variant B - doesn't have problemI only found this while working on making a minimal config today. In xinitrc:
Later, in terminal: WorkaroundSince my objective was to switch to qwerty for my external keyboard (since it handles layouts itself via firmware), I found it was easier to just use kmonad and only set the layout for the internal keyboard. Then the layout works everywhere, and I don't have to switch when attaching the external. Another potential workaround based on variant B above would is just to not call setxkbmap until after emacs launches, and call setxkbmap during emacs' init after exwm instead. |
stands out to me as a possible issue. The |
I tried it; no difference. Good catch though. |
Note that kmonad isn't needed here. You can set the layout for a specific keyboard with |
What's the recommended way to change a keyboard layout during use?
I normally use the colemak layout, but i have an external keyboard that has a custom layout assuming qwerty input mappings. If I try to use setxkbmap to change the keyboard layout, it mostly works in subordinate X windows (e.g. Firefox) but not in the exwm keys that don't go to Firefox (e.g. C-x ...).
I think this is an EXWM issue, because of the way it affects those specially grabbed keys.
Any workaround ideas or things I should test?
The text was updated successfully, but these errors were encountered: