LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices

Reply
 
LinkBack Search this Thread
Old 12-14-2009, 02:08 PM   #1
makowka
LQ Newbie
 
Registered: Feb 2007
Posts: 25

Rep: Reputation: 0
German keyboard layout


Hi folks

I have a small problem switching to the german keyboard layout. Usually I use the polish layout as default, but from time to time I need to use the german keyboard. I have Debian Lenny installed. I have everything set up to work in xorg.conf, here is a snippet:

Section "InputDevice"
Identifier "Generic Keyboard"
Driver "kbd"
Option "CoreKeyboard"
Option "XkbRules" "xorg"
Option "XkbModel" "pc105"
Option "XkbLayout" "pl,de"
Option "XkbOptions" "grp:alt_shift_toggle"
EndSection



The problem is, that when I switch to german, I get all the umlauts, , etc., but when I press for example r, I get this: . With d: . That is, I get symbols instead of latin letters. What could be wrong here?

Best regards
Szymon
 
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 12-15-2009, 10:25 AM   #2
DavidMcCann
Senior Member
 
Registered: Jul 2006
Location: London
Distribution: CentOS, Salix
Posts: 2,823

Rep: Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723
What's happening is that the computer is behaving as if AltGr is held down, but it's difficult to see why!

The simplest solution may be to type German from your Polish keyboard. If you enable the Compose key (using the Windows Menu or anything convenient), then you have the sequences

Compose + a + " gives
Compose + U + " gives
Compose + s + s gives

and so on.
 
Old 12-16-2009, 03:52 AM   #3
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 12.04, Fedora 17, Mint 16, Chakra
Posts: 3,618

Rep: Reputation: Disabled
Quote:
Originally Posted by DavidMcCann View Post
...If you enable the Compose key (using the Windows Menu or anything convenient)...
What is the "compose key" (not the "any key" I trust )? And what do you mean with "Windows Menu or anything convenient" under linux .
 
Old 12-16-2009, 12:31 PM   #4
DavidMcCann
Senior Member
 
Registered: Jul 2006
Location: London
Distribution: CentOS, Salix
Posts: 2,823

Rep: Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723
The Compose Key (described in Wikipedia and on this site's wiki) is an escape key. After you press it, the input modules checks the following keystrokes in a list to see if they are a code for something else. It's the traditional Unix method for getting characters that are not on the keyboard. So, on a keyboard without "{" you can still get that character with the sequence
Compose - (

A PC keyboard obviously lacks a Compose key, but you can select another key to use as one. If you have the Gnome desktop, enter the menu under System - Preferences - Hardware - Keyboard. Or, if you have the keyboard language indicator on the panel, right-click on it and select the option Keyboard Preferences. In the window, chose the tab Layouts, then the button Layout Options. The third item is Compose key position, which offers seven choices. I think most people choose the Windows Menu key, as it's not much use in Linux.
 
3 members found this post helpful.
Old 12-17-2009, 02:50 AM   #5
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 12.04, Fedora 17, Mint 16, Chakra
Posts: 3,618

Rep: Reputation: Disabled
Thank you for this detailed answer .
 
Old 12-18-2009, 02:38 PM   #6
makowka
LQ Newbie
 
Registered: Feb 2007
Posts: 25

Original Poster
Rep: Reputation: 0
Hi all

Finally, I found a solution to my problem. I asked on another forum and was advised to type the following in the keyboard section of xorg.conf:

Option "XkbOptions" "lv3:ralt_switch"


Now the whole section looks like this:

Section "InputDevice"
Identifier "Keyboard0"
Driver "kbd"
Option "XkbRules" "xorg"
Option "XkbModel" "pc105"
Option "XkbLayout" "pl,de"
Option "XkbOptions" "grp:alt_shift_toggle"
Option "XkbOptions" "lv3:ralt_switch"
EndSection



This did the thing. Thanks everyone for help.
 
Old 12-20-2009, 01:31 PM   #7
makowka
LQ Newbie
 
Registered: Feb 2007
Posts: 25

Original Poster
Rep: Reputation: 0
The solution was working, but only temporary. After reboot everything is the old way. Could this be a bug in xorg?
 
Old 12-21-2009, 03:38 PM   #8
j1alu
Member
 
Registered: Apr 2009
Distribution: debian gnu/linux
Posts: 798

Rep: Reputation: Disabled
doing it manually does work?
setxkbmap de
sextkbmap pl
if yes xorg is wrong, if not you might be missing something else.
greetings

Last edited by j1alu; 12-21-2009 at 06:26 PM. Reason: typo
 
Old 12-22-2009, 12:25 PM   #9
makowka
LQ Newbie
 
Registered: Feb 2007
Posts: 25

Original Poster
Rep: Reputation: 0
Yes, with setxkbmap everything works fine. It really seems, that xorg is thinking, that alt-gr is pressed all the time if I switch to german. I dont't know, if this could be a clue, but I had the following error message from xorg:

Code:
The XKEYBOARD keymap compiler (xkbcomp) reports:
> Warning:           Type "ONE_LEVEL" has 1 levels, but <RALT> has 2 symbols
>                    Ignoring extra symbols
Errors from xkbcomp are not fatal to the X server
I read somewhere, that this warning has to do with the files "altwin" and "level3" in /usr/share/X11/xkb/symbols (possibly a conflict, I am not that good to say something more). Here is a link to a polish site, with explanation, how to fix this message:

http://forum.pld-linux.org/viewtopic.php?t=643

You can see some piece of code there, maybe it is a help.


I wouldn't bother, if I could switch to german with setxkbmap (I wrote a small bash script for that, see the attachment), but then I can't manage the keyboard layout independent for every window (that is, if I switch to german, all newly open programs will have the german layout, it is not possible to switch to polish again, until I issue setxkbmap in the terminal). It must be a bug in xorg, I am quite sure now (in Etch and Slackware switching languages worked like it was supposed to). Maybe this has something to do with the installed locales? I have both needed locales installed.

I know, that many people are facing now the same problem with Lenny, so it must be definitely a bug.
Attached Files
File Type: txt setlang.txt (371 Bytes, 3 views)

Last edited by makowka; 12-22-2009 at 12:28 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
German keyboard layout not working with Eterm rangalo Debian 2 12-21-2006 06:25 AM
Switching keyboard layout - Mandriva2006 - K.D.E. Windows Layout! itz2000 Mandriva 3 08-13-2006 06:43 PM
keyboard German snoozing Suse/Novell 5 01-28-2006 11:41 AM
Keyboard layout (German) medo Linux - Laptop and Netbook 1 07-18-2005 07:52 AM
German Keyboard Linunix Slackware - Installation 7 05-21-2005 11:02 AM


All times are GMT -5. The time now is 02:15 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration