You are not logged in.
I have a minimal setup, I'm running archlinux with dwm.
Changing my keyboard layout doesn't work. Instead of a romanian keyboard I get the regular english keyboard. It does work for other languages.
I tried setting the keyboard layout like this:
setxkbmap roDoes anyone here has any idea what's going on here, am I missing some packages or something? Thanks!
Last edited by DCx86 (2020-06-15 17:07:07)
Offline
I'm not sure if it's relevant, but locale.gen is configured and locale-gen has done its job?
Offline
Yes, I double checked it now. All looks good there. Seems like it works for every other language except ro.
Offline
stat /usr/share/X11/xkb/symbols/ro
xkbcomp -I /usr/share/X11/xkb/symbols/ro
setxkbmap -print -query
setxkbmap ro
setxkbmap -print -queryOffline
Thank you seth for your help. I followed the steps but have the same result. Here is a snippet with the output.
[I] ➜ stat /usr/share/X11/xkb/symbols/ro
File: /usr/share/X11/xkb/symbols/ro
Size: 11261 Blocks: 24 IO Block: 4096 regular file
Device: fe02h/65026d Inode: 3152473 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2020-06-12 09:43:18.043730822 +0200
Modify: 2020-06-03 10:56:26.000000000 +0200
Change: 2020-06-04 11:42:15.978362671 +0200
Birth: 2020-06-04 11:42:15.978362671 +0200
~
[I] ➜ xkbcomp -I /usr/share/X11/xkb/symbols/ro
~
[I] ➜ setxkbmap -print -query
xkb_keymap {
xkb_keycodes { include "evdev+aliases(qwerty)" };
xkb_types { include "complete" };
xkb_compat { include "complete" };
xkb_symbols { include "pc+us+inet(evdev)" };
xkb_geometry { include "pc(pc105)" };
};
rules: evdev
model: pc105
layout: us
~
[I] ➜ setxkbmap ro
~
[I] ➜ setxkbmap -print -query
xkb_keymap {
xkb_keycodes { include "evdev+aliases(qwertz)" };
xkb_types { include "complete" };
xkb_compat { include "complete" };
xkb_symbols { include "pc+ro+inet(evdev)" };
xkb_geometry { include "pc(pc105)" };
};
rules: evdev
model: pc105
layout: ro
~
[I] ➜ ;;;;p[[[yyyyyyyyyyyyyyyyOffline
There's no error in the layout and you can set it w/ setxkbmap.
Looking at https://en.wikipedia.org/wiki/Romanian_keyboard_layout - which one do you expect? (it seems largely QWERTZ or QWERTY w/ some accented chars and the QWERTZ variant as some AltGr deviations.
Here're the variants
grep -A5 xkb_symbols /usr/share/X11/xkb/symbols/roOffline
Thank you so much seth! that grep helped! it was ro std that I needed.
setxkbmap ro std Offline
setxkbmap -layout us,se,'ro std' -option grp:alt_shift_toggle Now it seems that I can't set 'ro std' in this command. Having a space is ignored. I also tried, quotes, underscore, dash, parenthesis....
Offline
From what I understand looking at "man setxkbmap", you need to do it like this:
setxkbmap -layout us,se,ro -variant ,,std -option grp:alt_shift_toggleThat's supposed to be two empty variant entries for "us" and "se", and then the "std" variant for "ro".
Something else: there's a tool "localectl" that comes with systemd. It can help you write a config file for Xorg for the keyboard layout. You then don't need to run setxkbmap in your login scripts. An Xorg config file also helps with things like standby/resume problems. The keyboard will disconnect and reconnect on standby/resume and you then lose the setxkbmap settings.
Using localectl looks like this, I think:
localectl set-x11-keymap us,se,ro "" ,,std grp:alt_shift_toggleThe tool will write a file /etc/X11/xorg.conf.d/00-keyboard.conf.
Offline
Thank you very much Ropid, I was about to setxkmap in my login scripts, it's really good too know that there is a better way to do it!
Offline