70

I just installed Ubuntu 13.10, and really enjoy it. I am from Denmark, and use the supported Danish keyboard-layout (and chose it as default in the install), but whenever I reboot Ubuntu switches back to English keyboard-layout, though the little icon in the panel says it's in Danish. I have to click on the icon every time to change it back to Danish. I tried removing the English keyboard-layout, but it didn't help. Any suggestions?

Braiam
  • 67,791
  • 32
  • 179
  • 269

8 Answers8

31

I'm Italian and I had the same problem as you before yesterday evening. I came also in this thread but I didn't find a solution.

Default layout keyboard was selected as Italian but at every boot "switched back to English keyboard-layout, though the little icon in the panel says it was in Italian. I have to click on the icon every time to change it back to Italian. I tried removing the English keyboard-layout, but it didn't help". It was frustrasting.

I solved my problem changing Text settings from these:

enter image description here

to these, that work fine for me:

enter image description here

Now my default keyboard layout is italian and works as italian by default, not as english. Now I don't have to click on the icon every time to change it back to Italian. I hope this can help you.

Eric Carvalho
  • 54,385
  • 1
    Hi! I must add that after that clever workaround you can turn back the setting to the original value and the problem will not happen again, at least on Ubuntu Desktop 15.04 64bit. Thanks, Francesco Marmo and Dennis Rasmussen. /Angel – Angel Oct 27 '15 at 17:30
  • Do I need to reboot again? Because I did that and it does not work immediately. – João Pimentel Ferreira Sep 28 '16 at 19:46
  • 4
    Would be great to know where you found that window. What is this window, and where do I find it? – sbrattla Jun 13 '17 at 13:54
16

(Updated 2014-05-28, thanks to Bernard Decock's comment.)

In the ubuntu software center, install "dconf Editor" (dconf-editor) (if you don't already have it). Open it, then open desktop -> ibus -> general. Now enable the property "use-system-keyboard-layout". (You want it to have a checkmark next to it.)

Source: https://bugs.launchpad.net/ubuntu/+source/indicator-keyboard/+bug/1240198

Steve Byrnes
  • 2,021
  • 2
    You don't have to uninstall Ibus. Open dconf-editor and open the desktop.ibus.general folder. Make sure the "use-system-keyboard-layout" property is enabled. This will resolve the conflict between ibus and your keyboard settings. – Bernard Decock May 17 '14 at 11:19
  • 3
    Just run: dconf write /desktop/ibus/general/use-system-keyboard-layout true – Eduardo Santana Feb 06 '15 at 18:12
11

This is how I solved it (for me, at least - running 14.04):

In a terminal, type ibus-setup, the IBus Preferences window should open. Under the Advanced tab tick the use system keyboard layout option, like in the screenshot below.

enter image description here

6

I had the same problem, with Ubuntu 13.10 and after using it few weeks, my keyboard layout suddenly started to change from spanish to english every time I login.

As a workaround I created the following script and then added it to startup applications:

#!/bin/bash

setxkbmap es

I tried adding the command setxkbmap es directly to startup applications, but it didn't work, for that reason I made the script.

4

I used:

setxkbmap es

and Finally! it worked, now I'm able to use the ñ and the tildes áéíóú in the right key in the keyboard!

Braiam
  • 67,791
  • 32
  • 179
  • 269
DanielJM
  • 364
0

Workaround

This is an X.Org bug that is at least a decade old.

Symptoms are:

  1. In a Ctrl+Alt+F1 console, the layout is correctly set after booting, and
  2. The correct layout gets also suddenly set in all windows after physically disconnecting and reconnecting the keyboard.

Some more xev test results are described elsewhere.

The workaround consists in automatically running the setxkbmap command without any arguments at startup (login), as shown below for Xubuntu:

Application Autostart

Serge Stroobandt
  • 5,268
  • 1
  • 48
  • 59
0

First open Text Entry Settings, then put Danish on top of the input sources list:

Open Text Entry

Text Entry

Radu Rădeanu
  • 169,590
0

This also affected me and I own a pt-br keyboard. I actually don't know how to solve the problem, but a possible workaround (it worked for me) is to use setxkbmap until they fix it:

http://zuttobenkyou.wordpress.com/2011/05/13/xorg-switching-keyboard-layouts-consistenly-and-reliably-from-userspace/

I hope it helps.