Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Keyboard layout won't stay

If none of the specific sub-forums seem right for your thread, ask here.
Message
Author
User avatar
Jerther
Posts: 6
Joined: 2009-07-26 14:42

Keyboard layout won't stay

#1 Post by Jerther »

Hi!

I'm using Debian Lenny. I've been having this problem since the installation a couple of weeks ago. Everything else is fine ;)

I use a Canadian French keyboard layout. However, when I get into GNOME, it returns to what I think is a standard US layout. I have to return to System, Prefs, Keyboard and add another Canada layout, even if there's already one.

And each time I reboot my machine, the system returns to the standard layout and I have to re-add a Canada one.

There are only Canada layouts in the list.

I've searched a bit, and found out I could use a terminal script to reload the layout at boot up using:

Code: Select all

loadkey cf
which returns:

Code: Select all

Loading /usr/share/keymaps/i386/qwerty/cf.kmap.gz
but the layout won't change.

I searched a bit more, and found out this kind of problem has been solved by many by running:

Code: Select all

dpkg-reconfigure console-data
I choose the according items, and... I end up with the following message:

Code: Select all

Looking for keymap to install:
cf
dpkg: warning: obsolete option '--print-installation-architecture', please use '--print-architecture' instead.
And the layout doesn't change.

Any clue or workaround for this?
If you need more information, please ask :)

User avatar
987687
Posts: 2110
Joined: 2007-06-11 10:58
Location: Vacation Land

Re: Keyboard layout won't stay

#2 Post by 987687 »

When you are in gnome, if you open a terminal and type

Code: Select all

setxkbmap cf
does that give you the correct keyboard map you need?
If so, you can add it to xorg.conf to have it automatically loaded when X is started.
Edit /etc/X11/xorg.conf as root, and go to the InputDevice section. There will be a line that looks like this

Code: Select all

Option      "XkbLayout" "us"
Change us to cf. Save, then restart X (CTRL+ALT+BACKSPACE)

to open a file for editing as root, press ALT+F2 to bring up the command dialog, and type

Code: Select all

gksu gedit /etc/X11/xorg.conf
Since you are using gnome this should bring up a graphical text editor as root. BE CAREFUL!!!! YOU ARE ROOT, IF YOU MESS UP YOUR SYSTEM WILL STOP WORKING!
Desktop - 3.2GHz core2 quad
Laptop - 2.4GHz core2 duo ancient macbook
Bring back the penguin!! http://tinyurl.com/d57jwv

User avatar
Jerther
Posts: 6
Joined: 2009-07-26 14:42

Re: Keyboard layout won't stay

#3 Post by Jerther »

setxkbmap cf yields:

Code: Select all

Error loading new keyboard description
and usinf us instead of cf yields nothing, so I guess this one works, but not cf...

I guess something is missing?

User avatar
987687
Posts: 2110
Joined: 2007-06-11 10:58
Location: Vacation Land

Re: Keyboard layout won't stay

#4 Post by 987687 »

try

Code: Select all

setxkbmap "ca(fr)"
It works on my system, but I'm not sure if it is the layout you are looking for or not.
Desktop - 3.2GHz core2 quad
Laptop - 2.4GHz core2 duo ancient macbook
Bring back the penguin!! http://tinyurl.com/d57jwv

User avatar
Jerther
Posts: 6
Joined: 2009-07-26 14:42

Re: Keyboard layout won't stay

#5 Post by Jerther »

yes this one works!

Here the xorg.conf section for my keyboard at the moment:

Code: Select all

Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection
I added

Code: Select all

Option "XkbLayout" "ca(fr)"
to this section and it worked!!! thanks!!

I believe this is a workaround to my problem and I'm fine with it. Otherwise, could you tell where could be the problem?

User avatar
987687
Posts: 2110
Joined: 2007-06-11 10:58
Location: Vacation Land

Re: Keyboard layout won't stay

#6 Post by 987687 »

I personally don't see it as a workaround at all. I see it as the way to set a keyboard layout. But I don't use gnome, or gdm for managing things. I use openbox with no desktop manager, so for me, this is the only way to switch X keyboard layouts on X startup.
At this time I actually have a completely custom programmed dvorak keyboard layout I load with xkbcomp...

Anyway, there is probably some little bug in gnome that's making it not work properly... wouldn't surprise me at all.
Desktop - 3.2GHz core2 quad
Laptop - 2.4GHz core2 duo ancient macbook
Bring back the penguin!! http://tinyurl.com/d57jwv

User avatar
MrFrood
Posts: 480
Joined: 2008-04-22 12:08
Location: London UK
Contact:

Re: Keyboard layout won't stay

#7 Post by MrFrood »

Jerther wrote:I believe this is a workaround to my problem and I'm fine with it. Otherwise, could you tell where could be the problem?
987687 wrote:I personally don't see it as a workaround at all. I see it as the way to set a keyboard layout.
It is a workaround because the correct keyboard layout should (IMHO) be configured during install but in the dummed down lenny installer it is not, instead it uses X's guessing abilities (which in my case got en-gb layout but missed the fact that it is a 102 key KB not a 105 KB) - until X can start guessing right the install should go back to asking some very simple questions about the keyboard.

I am aware the the expert mode install still gives the option to choose a KB layout but with X's auto detection routine not working properly I am firmly of the opinion that these questions should be reintegrated back in to the normal install.
(\__/)
(='.'=) This is Bunny. Copy and paste Bunny into your
(")_(") signature to help him gain world domination.

http://happy.sdf-eul.org/

User avatar
987687
Posts: 2110
Joined: 2007-06-11 10:58
Location: Vacation Land

Re: Keyboard layout won't stay

#8 Post by 987687 »

I have to completely disagree. For one, this is the correct way to do it if you want to switch to a different keyboard layout. And 2, I recently installed lenny on a system, and one of the first things the regular (non-expert) installer asks is what layout you want to use. It has a bunch of different options, but I chose dvorak, because that's what I use. Then later when I installed X in "knew" that I used dvorak in the installation and made it the default in X.
Desktop - 3.2GHz core2 quad
Laptop - 2.4GHz core2 duo ancient macbook
Bring back the penguin!! http://tinyurl.com/d57jwv

User avatar
MrFrood
Posts: 480
Joined: 2008-04-22 12:08
Location: London UK
Contact:

Re: Keyboard layout won't stay

#9 Post by MrFrood »

987687 wrote:I have to completely disagree. For one, this is the correct way to do it if you want to switch to a different keyboard layout.
It is as you say the correct way to switch to a different keyboard layout but in my case I just wanted the keyboard that was in use when I installed lenny to work properly and if I understood Jertherr's original post it would appear that they also were not trying to trying to install a new keyboard. As niether of us were trying to install a new keyboard it is (IMHO) a workaround as the keyboard should of been set right during the install.

987687 wrote:2, 2, I recently installed lenny on a system, and one of the first things the regular (non-expert) installer asks is what layout you want to use
I recall questions about language but nothing keyboard specific (such as how many keys).
(\__/)
(='.'=) This is Bunny. Copy and paste Bunny into your
(")_(") signature to help him gain world domination.

http://happy.sdf-eul.org/

User avatar
987687
Posts: 2110
Joined: 2007-06-11 10:58
Location: Vacation Land

Re: Keyboard layout won't stay

#10 Post by 987687 »

MrFrood wrote:
987687 wrote:2, 2, I recently installed lenny on a system, and one of the first things the regular (non-expert) installer asks is what layout you want to use
I recall questions about language but nothing keyboard specific (such as how many keys).
I believe it asks for language and keyboard layout. Nothing keyboard specific though. I have a completely custom programmed layout though, so I didn't really care...
Desktop - 3.2GHz core2 quad
Laptop - 2.4GHz core2 duo ancient macbook
Bring back the penguin!! http://tinyurl.com/d57jwv

User avatar
MrFrood
Posts: 480
Joined: 2008-04-22 12:08
Location: London UK
Contact:

Re: Keyboard layout won't stay

#11 Post by MrFrood »

987687 wrote:I believe it asks for language and keyboard layout..
I do believe you are right, but now I've have had my memory jogged I still do not remember it asking me how many keys my British layout keyboard had - it just assumed a 105 key windows British keyboard rather than the standard 102 key pc British keyboard I use.
(\__/)
(='.'=) This is Bunny. Copy and paste Bunny into your
(")_(") signature to help him gain world domination.

http://happy.sdf-eul.org/

User avatar
987687
Posts: 2110
Joined: 2007-06-11 10:58
Location: Vacation Land

Re: Keyboard layout won't stay

#12 Post by 987687 »

MrFrood wrote:
987687 wrote:I believe it asks for language and keyboard layout..
I do believe you are right, but now I've have had my memory jogged I still do not remember it asking me how many keys my British layout keyboard had - it just assumed a 105 key windows British keyboard rather than the standard 102 key pc British keyboard I use.
Yea, lenny did get rid of that. The installer used to ask if you wanted it to auto-detect your keyboard, or if you wanted to choose how many keys, etc. Same with the screen actually, I'm not sure why they got rid of that functionality.
Desktop - 3.2GHz core2 quad
Laptop - 2.4GHz core2 duo ancient macbook
Bring back the penguin!! http://tinyurl.com/d57jwv

User avatar
MrFrood
Posts: 480
Joined: 2008-04-22 12:08
Location: London UK
Contact:

Re: Keyboard layout won't stay

#13 Post by MrFrood »

987687 wrote:
MrFrood wrote:
987687 wrote:I believe it asks for language and keyboard layout..
I do believe you are right, but now I've have had my memory jogged I still do not remember it asking me how many keys my British layout keyboard had - it just assumed a 105 key windows British keyboard rather than the standard 102 key pc British keyboard I use.
Yea, lenny did get rid of that. The installer used to ask if you wanted it to auto-detect your keyboard, or if you wanted to choose how many keys, etc. Same with the screen actually, I'm not sure why they got rid of that functionality.
Because people like me who insist on using a standard PC keyboard instead of one specially designed for a well known commercial operating system are a dieing bread :?
(\__/)
(='.'=) This is Bunny. Copy and paste Bunny into your
(")_(") signature to help him gain world domination.

http://happy.sdf-eul.org/

User avatar
987687
Posts: 2110
Joined: 2007-06-11 10:58
Location: Vacation Land

Re: Keyboard layout won't stay

#14 Post by 987687 »

To be honest, I don't even know how many keys are on my keyboard... It is some 3D ergonomic one from some random no-name company. I have a completely custom layout that uses all the keys, like windows key, for different uses anyway.
Desktop - 3.2GHz core2 quad
Laptop - 2.4GHz core2 duo ancient macbook
Bring back the penguin!! http://tinyurl.com/d57jwv

User avatar
MrFrood
Posts: 480
Joined: 2008-04-22 12:08
Location: London UK
Contact:

Re: Keyboard layout won't stay

#15 Post by MrFrood »

987687 wrote:To be honest, I don't even know how many keys are on my keyboard
101/102 keys for a standard PC keyboard
104/105 for a keyboard specially designed for a popular commercial operating system (hence the aforementioned operating systems logo is normally printed on certain keys).
(\__/)
(='.'=) This is Bunny. Copy and paste Bunny into your
(")_(") signature to help him gain world domination.

http://happy.sdf-eul.org/

User avatar
Issyer
Posts: 3032
Joined: 2007-05-23 02:59
Location: Khakassia

Re: Keyboard layout won't stay

#16 Post by Issyer »

Jerther wrote:Hi!

I'm using Debian Lenny. I've been having this problem since the installation a couple of weeks ago. Everything else is fine ;)

I use a Canadian French keyboard layout. However, when I get into GNOME, it returns to what I think is a standard US layout. I have to return to System, Prefs, Keyboard and add another Canada layout, even if there's already one.

And each time I reboot my machine, the system returns to the standard layout and I have to re-add a Canada one.

There are only Canada layouts in the list.

I've searched a bit, and found out I could use a terminal script to reload the layout at boot up using:

Code: Select all

loadkey cf
which returns:

Code: Select all

Loading /usr/share/keymaps/i386/qwerty/cf.kmap.gz
but the layout won't change.

I searched a bit more, and found out this kind of problem has been solved by many by running:

Code: Select all

dpkg-reconfigure console-data
I choose the according items, and... I end up with the following message:

Code: Select all

Looking for keymap to install:
cf
dpkg: warning: obsolete option '--print-installation-architecture', please use '--print-architecture' instead.
And the layout doesn't change.

Any clue or workaround for this?
If you need more information, please ask :)

Such things are done in xorg.conf
http://wiki.archlinux.org/index.php/Xorg

User avatar
987687
Posts: 2110
Joined: 2007-06-11 10:58
Location: Vacation Land

Re: Keyboard layout won't stay

#17 Post by 987687 »

I already showed him about the xorg.conf thing..
Desktop - 3.2GHz core2 quad
Laptop - 2.4GHz core2 duo ancient macbook
Bring back the penguin!! http://tinyurl.com/d57jwv

User avatar
slowcoach
Posts: 148
Joined: 2007-05-02 17:34
Location: UK

Re: Keyboard layout won't stay

#18 Post by slowcoach »

After installation my keyboard layout was listed correctly as United Kingdom but on rebooting this would change to USA. I then added United Kingdom, making it the default, and providing USA is also in the Keyboard Layouts list everything is OK.
If I remove USA from the list then on the next reboot United Kingdom will be replaced again by USA.
World domination by stealth..... :evil:
Currently, British inventors are responsible for over half of all the new inventions in the World.

User avatar
987687
Posts: 2110
Joined: 2007-06-11 10:58
Location: Vacation Land

Re: Keyboard layout won't stay

#19 Post by 987687 »

rogerwillson wrote:I see it as the way to set a keyboard layout. But I don't use gnome, or gdm for managing things. I use openbox with no desktop manager, so for me, this is the only way to switch X keyboard layouts on X startup.
At this time I actually have a completely custom programmed dvorak keyboard layout I load with xkbcomp.
Thank you.

-Roger
WTF dude, you just copied my post from the previous page :?: :?:
Desktop - 3.2GHz core2 quad
Laptop - 2.4GHz core2 duo ancient macbook
Bring back the penguin!! http://tinyurl.com/d57jwv

User avatar
Jerther
Posts: 6
Joined: 2009-07-26 14:42

Re: Keyboard layout won't stay

#20 Post by Jerther »

987687 wrote:
rogerwillson wrote:I see it as the way to set a keyboard layout. But I don't use gnome, or gdm for managing things. I use openbox with no desktop manager, so for me, this is the only way to switch X keyboard layouts on X startup.
At this time I actually have a completely custom programmed dvorak keyboard layout I load with xkbcomp.
Thank you.

-Roger
WTF dude, you just copied my post from the previous page :?: :?:
HAHAHA!!! :)

Well, it's been a couple of weeks now and everything is still fine on my side.

However, I still believe that such configuration that are made in the GUI should work and stay. If the only and true good way to change the layout is to edit the X conf file, then the Gnome Keyboard Layout application is worthless!

Post Reply