Keyboard layout setting fails when no keyboard is attached

  • Open
  • quality assurance status badge
Details
3 participants
  • dario
  • Ludovic Courtès
  • quiliro
Owner
unassigned
Submitted by
dario
Severity
normal
D
(name . bug-guix)(address . bug-guix@gnu.org)
87o8zkqmt3.fsf@web.de
I have Guix system installed on a Laptop/Tablet hybrid that allows
detaching the keyboard. In my system configuration, I set the keyboard
layout to the German QWERTZ using

(operating-system
...
(keyboard-layout
(keyboard-layout "de" "nodeadkeys"))
(bootloader
(bootloader-configuration
(bootloader grub-efi-bootloader)
(target "/boot/efi")
(keyboard-layout keyboard-layout)))
...
(services
(append
(list ...
(set-xorg-configuration
(xorg-configuration
(keyboard-layout keyboard-layout)
...
%desktop-services))))))

When the keyboard is attached, the keyboard layout is set correctly in
the TTY and in the graphical session. However, without the keyboard
attached, even when an external USB-keyboard is attached, the keyboard
layout is only set correctly in the TTY, but in the graphical session,
the default QWERTY layout is set.

This issue is obviously very easy to work around by either attaching the
keyboard or using setxkbmap, but the behaviour seems strange enough to
warrant reporting.

Best regards,
Dario
Q
Q
quiliro wrote on 18 Sep 2019 06:52
(name . dario)(address . dario.klingenberg@web.de)(address . 37428@debbugs.gnu.org)
c9db1637d1040f42985d52f8cf271fc8.squirrel@sm.riseup.net
On Mon, September 16, 2019 10:32 am, dario wrote:
Toggle quote (23 lines)
> I have Guix system installed on a Laptop/Tablet hybrid that allows
> detaching the keyboard. In my system configuration, I set the keyboard
> layout to the German QWERTZ using
>
> (operating-system
> ...
> (keyboard-layout
> (keyboard-layout "de" "nodeadkeys"))
> (bootloader
> (bootloader-configuration
> (bootloader grub-efi-bootloader)
> (target "/boot/efi")
> (keyboard-layout keyboard-layout)))
> ...
> (services
> (append
> (list ...
> (set-xorg-configuration
> (xorg-configuration
> (keyboard-layout keyboard-layout)
> ...
> %desktop-services))))))

(keyboard-layout keyboard-layout))
Q
Q
quiliro wrote on 18 Sep 2019 06:57
(name . dario)(address . dario.klingenberg@web.de)(address . 37428@debbugs.gnu.org)
1fc38e2e5b22550263acc701cba4c8dc.squirrel@sm.riseup.net
This is my setting for that section:

(services (append (list
(service gnome-desktop-service-type)
(service xfce-desktop-service-type)
(set-xorg-configuration
(xorg-configuration ;for Xorg
(keyboard-layout keyboard-layout))))
%desktop-services))

I hope it is helpful.
D
(address . quiliro@riseup.net)(address . 37428@debbugs.gnu.org)
87ef0crffz.fsf@web.de
This looks like what I have, apart from the fact that I use exwm and
therefore have neither gnome nor xfce services.

I just noticed that I may have messed up the parens when I copy/pasted
into the mail; in my config, they are correct.


Best regards,

Dario


quiliro@riseup.net writes:

Toggle quote (11 lines)
> This is my setting for that section:
>
> (services (append (list
> (service gnome-desktop-service-type)
> (service xfce-desktop-service-type)
> (set-xorg-configuration
> (xorg-configuration ;for Xorg
> (keyboard-layout keyboard-layout))))
> %desktop-services))
>
> I hope it is helpful.
L
L
Ludovic Courtès wrote on 19 Sep 2019 23:02
(name . dario)(address . dario.klingenberg@web.de)(address . 37428@debbugs.gnu.org)
87tv98vw1y.fsf@gnu.org
Hello,

dario <dario.klingenberg@web.de> skribis:

Toggle quote (6 lines)
> When the keyboard is attached, the keyboard layout is set correctly in
> the TTY and in the graphical session. However, without the keyboard
> attached, even when an external USB-keyboard is attached, the keyboard
> layout is only set correctly in the TTY, but in the graphical session,
> the default QWERTY layout is set.

Are you using GNOME, or Xfce, or some lightweight window manager?

When the X11 keyboard layout is incorrect, are there any hints in
~/.local/share/xorg/Xorg.1.log as to why?

Thanks,
Ludo’.
D
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 37428@debbugs.gnu.org)
87sgonhrst.fsf@web.de
Hello Ludo,


Toggle quote (1 lines)
> Are you using GNOME, or Xfce, or some lightweight window manager?
I am using EXWM. Interestingly, when using GNOME, the problem does not appear.

Toggle quote (2 lines)
> When the X11 keyboard layout is incorrect, are there any hints in
> ~/.local/share/xorg/Xorg.1.log as to why?
Maybe this is relevant? As far as I can tell, this all looks fine.
[ 39.298] (II) XINPUT: Adding extended input device "Logitech K520" (type: KEYBOARD, id 10)
[ 39.298] (**) Option "xkb_rules" "evdev"
[ 39.298] (**) Option "xkb_layout" "de"
[ 39.298] (**) Option "xkb_variant" "nodeadkeys"
[ 39.298] (**) Option "xkb_options" "ctrl:nocaps"
[ 39.298] (II) evdev: Logitech K520: initialized for relative axes.
[ 39.298] (WW) evdev: Logitech K520: ignoring absolute axes.
[ 39.298] (**) Logitech K520: (accel) keeping acceleration scheme 1
[ 39.298] (**) Logitech K520: (accel) acceleration profile 0
[ 39.298] (**) Logitech K520: (accel) acceleration factor: 2.000
[ 39.298] (**) Logitech K520: (accel) acceleration threshold: 4
I also searched for errors and warnings, but did not find anything suspicious.

Also, it turns out that when attaching the tablet keyboard, the layout
is also set correctly for the external keyboard, even when the tablet
keyboard is removed again.


Best,

Dario


Ludovic Courtès <ludo@gnu.org> writes:

Toggle quote (17 lines)
> Hello,
>
> dario <dario.klingenberg@web.de> skribis:
>
>> When the keyboard is attached, the keyboard layout is set correctly in
>> the TTY and in the graphical session. However, without the keyboard
>> attached, even when an external USB-keyboard is attached, the keyboard
>> layout is only set correctly in the TTY, but in the graphical session,
>> the default QWERTY layout is set.
>
> Are you using GNOME, or Xfce, or some lightweight window manager?
>
> When the X11 keyboard layout is incorrect, are there any hints in
> ~/.local/share/xorg/Xorg.1.log as to why?
>
> Thanks,
> Ludo’.
?