Ubuntu 12.04: keyboard layout does not change languages

Bug #995401 reported by Orestis Gorgas on 2012-05-06
This bug affects 34 people
Affects Status Importance Assigned to Milestone
gnome-control-center (Ubuntu)

Bug Description

Probably this problem is reported but the ubuntu-bug system cannot trace it.

I have upgraded to 12.04 from 11.10 which was a clean install. My keyboard language-settings (in the login screen as well) were norwegian and greek. However when I installed the 12.04 version my keyboard-layout was changed to english but the keyboard layout manager was showing norwegian.

On the keyboard-layout settings I put the english(US) layout and I removed greek and norwegian. Typed a bit and then put norwegian and greek and I removed the english (US) again and chose the Alt-Shift combination for changing layouts. What I get is an unchangable english(US) layout.

Important note: My keyboard is US-keyboard. I mean the hardware.

P.S. The ubuntu-bug system has a serious bug. When I was looking about the bug on Google I could find the launchpad relevant subject. I wanted to use the ubuntu-bug system in order to report my system's details. Then I could not find the subject again through the launchpad search engine and I was forced to report it as a new problem

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: gnome-control-center 1:3.4.1-0ubuntu1
ProcVersionSignature: Ubuntu 3.2.0-24.37-generic 3.2.14
Uname: Linux 3.2.0-24-generic x86_64
NonfreeKernelModules: nvidia
ApportVersion: 2.0.1-0ubuntu7
Architecture: amd64
Date: Sun May 6 11:20:53 2012
InstallationMedia: Ubuntu 11.10 "Oneiric Ocelot" - Release amd64 (20111011)
SourcePackage: gnome-control-center
UpgradeStatus: Upgraded to precise on 2012-05-05 (0 days ago)
 activity-log-manager-control-center 0.9.4-0ubuntu3
 gnome-bluetooth 3.2.2-0ubuntu5
 indicator-datetime 0.3.94-0ubuntu2

Orestis Gorgas (orestis-gorgas) wrote :
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in gnome-control-center (Ubuntu):
status: New → Confirmed
Arve Seljebu (arve-seljebu) wrote :

I have the same problem with a norwegian keyboard, Logitech K360(wireless, USB).

When on install medium/live:
The same bug exists - top layout in "gnome-control-center region" is chosen, but not effective. Though, it does work when changing the layout from top menu(two layouts must be added for this menu to show). First change to eng, then back to no, and the layout is correct. This is not possible when 12.04 is installed.

I should also note that keyboard layout works in terminal tty1-6, and when plugging in another USB keyboard(also norwegian layout).

Orestis Gorgas (orestis-gorgas) wrote :

The whole keyboard layout is quite buggy. Now if I remove norwegian and keep only the greek lanugage and then put the norwegian back in it works but the indicator on the top shows always the wrong language (norwegian for greek and greek for norwegian).

billjoie (joie-bill) wrote :

Same problems on a Dell laptop and an HP tower after upgrading from 11.10. Have Canadian and Norwegian keyboards installed. alt+shift changes the language on the indicator, but the layout is not effectively changed. Same problem if I use the mouse to change the layout on the keyboard-indicator. Related to the following discussion: http://ubuntuforums.org/showthread.php?t=1968980. There is a temporary workaround posted: running 'sudo setxkbmap -option grp:alt_shift_toggle no,ca' after login.

Kirill Elagin (kirelagin) wrote :

Same here after upgrading from 11.10 with ru+en layouts.

Kirill Elagin (kirelagin) wrote :

One more thing: when I click this little keyboard icon in layout settings (I guess it is layout preview) I always see english layout. Preview while adding a new layout works fine.

Also the layout indicator on top is missing (in unity, not during login).

Kirill Elagin (kirelagin) wrote :

Oh, that might be important: when I realised I can't switch layouts and tried to add russian layout (in layout settings) for the first time, the settings application just crashed.

Have the same difficulty with a Spanish (HW) keyboard on an ASUS U33J laptop, switching between EN, ES and NO.

Alexandre Pouliquen (sacha8uk) wrote :

The same here with a Korean keyboard on a Samsung N150 on a clean install, between a French (bépo) and a Korean keyboards.

It suddenly got even worse; accents don't work any more. Can this error be related to the errors above?

I am not sure whether quick-fixes should be added here, but there is a a way of changing between keyboards that works:

To change to - for example - a Norwegian keyboard, type "sudo setxkbmap no" in the terminal. Just replace the "no" for the keyboard layout that you want.

To Do (entodoays) wrote :

How would I change the layout in terminal for French (alternative) or French (alternative, latin-9 only) ?

To Do (entodoays) wrote :

I was using a customised version of the french layout file with two different layouts. Now the first one, French (alternative) if I click "show layout chart" shows the layout as it should but when I type the modified characters don't work but revert to the non-modified versions of the characters.

The second layout, French (alternative, latin-9 only) The modified characters don't work and don't show in the layout chart either.

To Do (entodoays) wrote :

In reporse to my own post #13 I found that the temporary solution is to use

sudo setxkbmap "fr(oss)","fr(oss_latin9)"

Both layouts seem to work as they should.

I'm also affected. System had only one keyboard layout (fi). Hardware keyboard is fi. After upgrading to the 12.04, layout is english, but every configs (and /etc/default/keyboard) claims it is fi (and doesn't even show english layout) . Tty1-6 works as fi-layout.

Workaround for current session works: setxkbmap fi
(setxkbmap doesn't need sudo)

Leonid Shvechikov (shvechikov) wrote :

I'm affected too.

Torstein Bø (haarek) wrote :

I had this problem. My setup was no + en (us), then I removed the Norwegian layout and added it again. After this I only get the problem that the icon is out of sync #1000941.

Torstein Bø (haarek) wrote :

Sorry for the spam, but my workaround did only last until i rebooted.

Ingo Saxer (isaxer) wrote :

I had the same problem on a de keyboard layout and the workarround works fine.
To avoid having to redo this after every reboot, just add the it to your profile ;)

In case one doesn't know where to find it:

- go to your users home directory using "cd" without arguments
- then do "vi .profile" (or use the editor of your choice)
- add "setxkbmap de" at the bottom (change "de" for your locale)
- save and reboot

now the workarround should be persisted

Hope this may help until the bug is fixed

Simos Xenitellis  (simosx) wrote :

I have Ubuntu 12.04 (upgraded from Ubuntu 12.04 Alpha1) and I exhibit this issue.
Here is my understanding of the problem and I would like your help to verify.

When you first install Ubuntu, you can select keyboard layout settings or accept the default provided by the installer.
These settings become the default, and can be found at /etc/default/keyboard
For example, if you installed Ubuntu by selecting the US English installation option, then you get the layout for US English.

If you later change your layout settings in the graphical user interface, the file /etc/default/keyboard will remain as it is, and the GUI will be informed that the user has a custom (different layout) that should be enabled.
I believe that bug is with the GUI not detecting that we have changed the default layout, and that we now have custom settings.
This explains how in the keyboard settings you can see your new layout settings, but they are not active.
You can force to re-apply for the current session your custom layout settings simply by (for example) changing the order of the layouts and then changing them back to the original order. In this way you can avoid opening the terminal to run setxkbmap.

Thus, if you are affected by this bug, please check /etc/default/keyboard and see whether your default layout is the one described in that file.
If my theory is correct, then a proper workaround would be to edit for now your /etc/default/keyboard so that it matches your desired layout settings.

Ingo Saxer (isaxer) wrote :

in my case the /etc/default/keyboard file already states "XKBLAYOUT="de"" and as I drove back it did not really make a change

Sebastien Bacher (seb128) wrote :

the issue seems a bit similar to bug #985065

Changed in gnome-control-center (Ubuntu):
importance: Undecided → Low
Pille (pilletiai) wrote :

I'm having the same problem. The command 'setxkbmap de' temporarily solves the problem but after rebooting the system the layout is gone again. The file /etc/default/keyboard seems to be ok. I just have one keyboard layout configured selected in the UI which is 'German'.

A temporary work-around that I have found is running the following command that enables alt+shift switching after each login.

The command bellow aplyies to English+Greek keybord switching. Replace with your settings

sudo setxkbmap -option grp:alt_shift_toggle us,gr

billjoie (joie-bill) wrote :

Does it not seem like an euphemism to assign a "low" priority to this bug? People of all nations upgrade and then cannot switch keyboard language without opening a terminal? I would push for a "medium" priority.

you can add the following command at the end your .bashrc file in your home directory.

setxkbmap -option grp:alt_shift_toggle us,gr

where you can change us,gr with any languages you want. You can shift lanugages with alt-shift.

There is no need to run the command with root privileges (sudo).

Sebastien Bacher (seb128) wrote :

the bug there is confusing, is it different from bug #985065? if so could you explain your exact config, desktop environment and what you do to trigger the issue?

I think the bug is the same with the bug you are reffering to. I have tried two configurations so far:

1) Upgrade from Ubuntu 11.10 where I had two keyboard layouts norwegian (no) and greek (gr) and I could add and remove any language.
After the upgrade the US layout was added to the two previous ones and was set as default. The layouts could *not* be changed either with a keybord combination or through the option on the top panel. In order to set the norwegian as default I had to remove the us and the no layout and add again the no.

2) I did a clean install with Ubuntu 12.04 and I chose during the installation as default layout the norwegian. Therefore the *only* layout was the norwegian one and it is actually the norwegian one and not the US. However I still have the problem that if I add more layouts through the settings, I cannot select one of the other options either with a keyboard sortcut or though the top panel.

saiah (abdelhadi-essayih) wrote :

French is my default layout language, I have Arabic .. it worked for a while but now it wouldn't change, it's stuck with the default language. Using the mose I can change the icon 'fr' to 'ar' and back but the language doesn't change. I had a clean install of 12.04 upgrading from 11.10.

Yossi Gil (yossi-gil) wrote :

Confirmed for Hebrew/English combination.

Further, even if I remove the English (US) keyboard in the system settings, the actual keyboard layout remains that of English. This point may be a clue to localizing the bug. Seems as if the system settings values are not propagated properly to the actual setup.

Ole Jon Bjørkum (oj88) wrote :

Same problem here with norwegian layout. Fresh install of Ubuntu 12.04 64-bit. If I choose english it uses norwegian, and if I choose norwegian it uses english. Layout is set to "no" in /etc/default/keyboard.

Dirk Porezag (dirk-porezag) wrote :

I think some of the people here - in particular if they are using Logitech Unifying Receivers - may be experiencing the bug more clearly described in bug report #995715. I have included a lengthy discussion of this problem there.

Chascon (chascone) wrote :

Has anyone tried manually deleting additional layouts, leaving the default original, then pressing the default button in gnome preference's Layout pane?

See my bug report and fix: https://bugs.launchpad.net/ubuntu/+source/gnome-control-center/+bug/986322

Alexey Stulov (kinos-pro) wrote :

Same problem. Ubuntu 12.04, lenovo thinkpad t530.

Last update crashed down at first start. Then it updated the system and after reboot i have same problem.

I've tried to remove my native keyboard layout and after adding it back i see in preview screen english letters instead of my native letters. Then i tried to add any other languages(not my native and english) - same reaction. Every time it was english layout.

So i went to system language menu and saw a warning "not all language packs were installed". After Ok and installation process bar i saw the same as always the list with my native and english languages at the top of the list. Everything seems to be alright. But keyboard layout never switches.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers