[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#951387: [PATCH] Misleading XKBLAYOUT is set when choosing Lithuanian in dpkg-reconfigure keyboard-configuration



Package: console-setup
Version: 1.194

Dear console-setup maintainer,

If user chooses Lithuanian keyboard layout during installation or
dpkg-reconfigure keyboard-configuration then misleading layout
configuration is set in /etc/default/keyboard :

XKBLAYOUT="lt,lt"
XKBVARIANT=",us"

This configuration is not intuitive, because people think, that
sometimes Lithuanian keyboard works (when lt1 is selected in GNOME
shell or other DE) and sometimes doesn't work (when LT2 is selected,
because LT2 is really English US layout where lithuanian letters can
be entered only when AltGr is pressed) - most of desktop users doesn't
even notice small number 1 or 2 after LT)

So, majority of Lithuanian users are force to removed second lt(us)
layout and add English (US) altgr-intl layout.

Correct, intuitive for all users, /etc/default/keyboard should be:

XKBMODEL="pc105"
XKBLAYOUT="lt,us"
XKBVARIANT=",altgr-intl"
XKBOPTIONS="grp_led:scroll"
BACKSPACE="guess"

I'm attaching a patch to debian/keyboard-configuration.config file
which fixes this issue - patch replaces not intuitive secondary lt(us)
layout with us(altgr-intl), which is used by the majority of
Lithuanian users as second layout.
this improvement works fine also with Ubuntu installer, I've tested my
patch with Ubuntu 19.10, look at this bugreport
https://launchpad.net/ubuntu/+source/console-setup/+bug/1863001

Btw, this issue is very old, exists even in console-setup 1.47
(released in 2009) and older, old Debian and Ubuntu users already got
used to this bug, they know, that first step after installation is to
remove lt(us) layout and add us(altgr-intl) or other us/en layout :)

Thanks for maintaining free software :)
Mantas Kriaučiūnas

-- 
Prekyba kompiuteriais su Linux OS - http://tinklas.eu/prekyba
Naudokite laisvą Linux operacinę sistemą savo kompiuteryje - http://baltix.eu
Use Ubuntu and Debian GNU/Linux OS !
--- /tmp/console-setup-1.194/debian/keyboard-configuration.config	2019-12-05 14:09:52.000000000 +0000
+++ keyboard-configuration.config	2020-02-13 15:17:18.000000000 +0000
@@ -1103,7 +1103,7 @@
 # on values of $XKBLAYOUT and $XKBVARIANT.
 if [ "$XKBLAYOUT" ]; then
     case "$XKBLAYOUT" in
-	lt,lt)
+	lt,us)
 	    debconf_layout="${XKBLAYOUT%,*}"
 	    debconf_variant="${XKBVARIANT%,*}"
 	    unsupported_layout=no
@@ -1497,7 +1497,7 @@
 			esac
 			;;
 		    lt)
-			XKBLAYOUT=lt,lt
+			XKBLAYOUT=lt,us
 			;;
 		    me)
 			case "$debconf_variant" in
@@ -1527,12 +1527,12 @@
                                 XKBVARIANT="latin,$debconf_variant" ;;
 		        esac
                         ;;
-                    lt,lt)
+                    lt,us)
 		        case "$debconf_variant" in
 		            us)
                                 XKBVARIANT="us," ;;
 		            *)
-                                XKBVARIANT="$debconf_variant,us" ;;
+                                XKBVARIANT="$debconf_variant,altgr-intl" ;;
 		        esac
                         ;;
 		    *,*)

Reply to: