Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
SDDM login screen: US keyboard layout always used [Solved]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Fitzcarraldo
Veteran
Veteran


Joined: 30 Aug 2008
Posts: 1631
Location: United Kingdom

PostPosted: Tue Oct 27, 2015 12:42 pm    Post subject: SDDM login screen: US keyboard layout always used [Solved] Reply with quote

Just in case any Gentoo users want to change the keyboard layout used by the SDDM login screen ...

This was something annoying me on my Compal laptop with a British English keyboard running Plasma 5. The SDDM login screen always used the US keyboard layout (the bar at the top of the SDDM login screen showed 'Layout: us' with the US flag, and no other keyboard layout could be selected). According to the Arch Wiki, SDDM loads the keyboard layout specified in /etc/X11/xorg.conf.d/00-keyboard.conf. That file didn't exist, so I created it with the following contents:

Code:
Section "InputClass"
    Identifier "keyboard"
    MatchIsKeyboard "yes"
    Option "XkbLayout" "gb,br,es"
    Option "XkbVariant" ""
    Option "XkbOptions" "grp:alt_shift_toggle"
EndSection

but that didn't change what SDDM did.

Then I found the file /usr/share/sddm/scripts/Xsetup contained only the following:

Code:
#!/bin/sh
# Xsetup - run as root before the login dialog appears

so I changed it to be:
Code:
#!/bin/sh
# Xsetup - run as root before the login dialog appears
setxkbmap gb

Now the SDDM login screen displays 'Layout: gb' with the British flag instead of 'Layout: us' with the US flag.
_________________
Clevo W230SS: amd64 OpenRC elogind nvidia-drivers & xf86-video-intel.
Compal NBLB2: ~amd64 OpenRC elogind xf86-video-ati. Dual boot Win 7 Pro 64-bit.
KDE on both.

Fitzcarraldo's blog
Back to top
View user's profile Send private message
toralf
Developer
Developer


Joined: 01 Feb 2004
Posts: 3647
Location: Hamburg

PostPosted: Tue Oct 27, 2015 1:17 pm    Post subject: Reply with quote

What's this (more generic, not only sddm) :
Code:
cat /etc/X11/xorg.conf.d/00-keyboard.conf
Section "InputClass"
  Identifier "system-keyboard"
  Option "XkbLayout" "de"
  Option "XkbOptions" "nodeadkeys"
EndSection
?
Back to top
View user's profile Send private message
Fitzcarraldo
Veteran
Veteran


Joined: 30 Aug 2008
Posts: 1631
Location: United Kingdom

PostPosted: Tue Oct 27, 2015 1:27 pm    Post subject: Reply with quote

toralf wrote:
What's this (more generic, not only sddm) :
Code:
cat /etc/X11/xorg.conf.d/00-keyboard.conf
Section "InputClass"
  Identifier "system-keyboard"
  Option "XkbLayout" "de"
  Option "XkbOptions" "nodeadkeys"
EndSection
?

I don't understand your question. Do you mean that the 00-keyboard.conf you quoted works with SDDM for you? I.e. do you mean that it displays 'Layout: de' with the German flag on the SDDM login screen on your machine?
_________________
Clevo W230SS: amd64 OpenRC elogind nvidia-drivers & xf86-video-intel.
Compal NBLB2: ~amd64 OpenRC elogind xf86-video-ati. Dual boot Win 7 Pro 64-bit.
KDE on both.

Fitzcarraldo's blog
Back to top
View user's profile Send private message
Fitzcarraldo
Veteran
Veteran


Joined: 30 Aug 2008
Posts: 1631
Location: United Kingdom

PostPosted: Tue Oct 27, 2015 1:42 pm    Post subject: Reply with quote

On my Compal laptop, the following causes the SDDM login screen to display a pull-down menu of the four specified keyboard layouts:

Code:
$ cat /usr/share/sddm/scripts/Xsetup
#!/bin/sh
# Xsetup - run as root before the login dialog appears
setxkbmap gb,us,br,es

_________________
Clevo W230SS: amd64 OpenRC elogind nvidia-drivers & xf86-video-intel.
Compal NBLB2: ~amd64 OpenRC elogind xf86-video-ati. Dual boot Win 7 Pro 64-bit.
KDE on both.

Fitzcarraldo's blog
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum