Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want only two keyboard layouts in my system: us altgr-intl (USA International (AltGr dead keys) ) and gr (Greece), so this is what I've selected in System → Preferences → Keyboard → Layouts. However, every time I begin a new Gnome session (reboot, logout/login), the us keyboard layout is automatically inserted at the top of the list.

I created a small script called fixlang that ensures the desirable result:

layouts='[us    altgr-intl,gr]' # tab between us and altgr

active_layouts="$(gconftool -g $key)"
if [ "$active_layouts" != "$layouts" -o "$1" == -f ]
    gconftool -t l --list-type=str -s $key "$layouts"

which I run on login.

However, this is a kludge. How can I ensure that Gnome does not mess with my keyboard layout selection?

share|improve this question
up vote 2 down vote accepted

You are probably experiencing bug #688936. It hasn't been fixed yet, but you could try the workaround in comment #5:

I've finally found a solution for this:

  1. Log out.
  2. Click on your account, but don't enter the password yet.
  3. A small bar with several drop-down lists appears on the very bottom of the login screen. You probably never noticed it before - I for sure didn't ;)
  4. Select the correct keyboard layout in the second-from-left drop-down list.
  5. Login.

Fixed :)

share|improve this answer
Thank you, that did it. I repeated my googling, and this time I managed to reach the same answer as yours; hopefully 25 rep points will compensate you for my inadequacy :) – ΤΖΩΤΖΙΟΥ Mar 3 '11 at 9:27

Are you sure you're not running some script which is modifying the list of layouts on boot/login already? I've used only the "USA Dvorak International" and "Norway" layouts since 8.04, and I've never seen this. Or if you modified the GNOME settings files by hand (which looks likely, considering fixlang), this is probably detected and overridden on GNOME shutdown/startup.

share|improve this answer
Like I said, I modified the settings through the proper interface; and I don't have any other script touching the settings. I created fixlang to deal with this specific issue. Thanks for answering, anyway. – ΤΖΩΤΖΙΟΥ Mar 2 '11 at 11:06

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.