You are not logged in.

#1 2020-09-27 10:11:49

rhh_01
Member
Registered: 2020-09-27
Posts: 4

Keyboard layout change only partially works

Hi, I'm having some issues setting my keyboard mapping permanently in xorg, as well as setting my keyboard in the GNOME terminal at all. I've been searching the forums for a solution, and nothing seems to work permanently. I have set the vconsole to KEYMAP=dk-latin1, as changed it for X11

The output of

 localectl status 

is

   System Locale: LANG=en_DK.UTF-8
       VC Keymap: dk-latin1
      X11 Layout: dk
       X11 Model: pc105 

But none of these configurations seem to have an actual effect. setxkbmap works temporarily, and changes the X11 layout properly, which lets me type in Danish in GNOME until restart, but nothing permanent is happening, despite me setting it permanently with localectl.
I can't set my keyboard layout for the GNOME default terminal at all, but it seems to work for the ctrl+alt+f3 terminal

I've no idea what to do, but will supply any information needed

Offline

#2 2020-09-27 11:03:21

solskog
Member
Registered: 2020-09-05
Posts: 407

Re: Keyboard layout change only partially works

Use $HOME/.xinitrc or /etc/X11/xinit/xinitrc to set permanent values.

Offline

#3 2020-09-27 11:12:11

rhh_01
Member
Registered: 2020-09-27
Posts: 4

Re: Keyboard layout change only partially works

As far as I've read, I should write

 setxkbmap -layout dk 

in ~/.xinitrc and save it. Is that correct? I've done that, and it doesn't seem to work

Offline

#4 2020-09-27 12:14:24

seth
Member
Registered: 2012-09-03
Posts: 49,986

Re: Keyboard layout change only partially works

xinitrc is interpreted if you're starting X11 using xinit, but not by eg. GDM
Also this might be a wayland session:

loginctl session-status

As for static X11 keyboard configs, please see https://wiki.archlinux.org/index.php/Xo … tion_files

Online

#5 2020-09-27 12:43:18

rhh_01
Member
Registered: 2020-09-27
Posts: 4

Re: Keyboard layout change only partially works

seth wrote:

xinitrc is interpreted if you're starting X11 using xinit, but not by eg. GDM

Ah
I'm currently using GDM, but I will look into how to use xinit instead.

seth wrote:

Also this might be a wayland session:

loginctl session-status

That appears to be the case. How does that affect the way I should configure my keyboard? I can see that it's different from X11

seth wrote:

As for static X11 keyboard configs, please see https://wiki.archlinux.org/index.php/Xo … tion_files

I have edited the 00-keyboard.conf file, and running the cat command on it leaves me with this:

Section "InputClass"
        Identifier "system-keyboard"
        MatchIsKeyboard "on"
        Option "XkbLayout" "dk"
        Option "XkbModel" "pc105"
EndSection

I am very greatful for the replies by the way

Offline

#6 2020-09-27 12:57:49

seth
Member
Registered: 2012-09-03
Posts: 49,986

Re: Keyboard layout change only partially works

That appears to be the case.

Does it say "type wayland"?

You'll then have to use GNOME's Regional & Language Settings, X11 configs are irrelevant but for xwayland clients.

Online

#7 2020-09-27 13:10:52

rhh_01
Member
Registered: 2020-09-27
Posts: 4

Re: Keyboard layout change only partially works

seth wrote:

That appears to be the case.

Does it say "type wayland"?

You'll then have to use GNOME's Regional & Language Settings, X11 configs are irrelevant but for xwayland clients.

It does say type wayland:

 Service: gdm-password; type wayland; class user 

Thank you so much, that worked!
I was very confused as to why it wouldn't work through console, so I didn't think to look in the GNOME settings
I'm sorry for wasting your time on a problem that trivial ^^; It works now, and I am very thankful for your help

Offline

#8 2020-09-27 13:25:20

seth
Member
Registered: 2012-09-03
Posts: 49,986

Re: Keyboard layout change only partially works

Awesome.
Please always remember to mark resolved threads by editing your initial posts subject - so others will know that there's no task left, but maybe a solution to find.
Thanks.

Online

Board footer

Powered by FluxBB