Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Apple's X11 and international keyboards UNIX
A lot of people seem to be having problems getting Apple's X11 version to work with their international keyboards. Skimming the web, I found this to be a good way of solving it (part of it taken from some mandrake linux forum):
  1. Run XDarwin or OroborOSX and have it use your language.keymapping file.

  2. In a terminal, do the following:
     % xmodmap -pke .yourlanguage.xmodmap
  3. Quit XDarwin and run X11.app

  4. In a terminal, run:
     % xmodmap .yourlanguage.xmodmap
You should now have a working international keyboard! If this works, you can make it run every time you start X11 by adding the following line to your .xinitrc file:
 exec xmodmap .yourlanguage.xmodmap
[Editor's note: I have not tested this one...]
    •    
  • Currently 2.43 / 5
  You rated: 4 / 5 (7 votes cast)
 
[10,986 views]  

Apple's X11 and international keyboards | 11 comments | Create New Account
Click here to return to the 'Apple's X11 and international keyboards' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
I use it
Authored by: midan23 on Jan 13, '03 11:09:20AM

I use this method for my german keyboard layout and it works like a charm ...

I even modified the file to match my natural keyboard ...



[ Reply to This | # ]
I use it
Authored by: MacDog on Jan 13, '03 02:17:35PM

You can find an app at VersionTracker fixing this in an elegant way.
http://www.versiontracker.com/moreinfo.fcgi?id=17831&db=mac

As the Product Description says:
X11 Launcher may be of some use to people like me with a non-US keyboard who want to use the just released (as of 01/10/2003) Apple X11 beta. It allows selecting the desired keyboard layout for X11, as well as giving some extra command line parameters. This app should become obsolete quickly, as Apple improve its application. The source code is available.



[ Reply to This | # ]
I use it
Authored by: Eponymous on Jan 13, '03 10:17:40PM
Try the instructions at http://www.cse.ogi.edu/~dylan/dvorak/Xdvorak.html . Just don't put the keyboard layout files in /tmp but use a more permanent folder. Works great for me.

[ Reply to This | # ]
I use it
Authored by: Eponymous on Feb 06, '03 09:18:20PM

I also just noticed that /etc/X11/xinitrc (no period there) seems to be a basic .xinitrc to use. I copied it to ~ and made some modifications so that it xmodmap's my keyboard (I renamed my dvorak keyboard to .Xmodmap and it uses it by default) and didn't start the various apps listed at the end of the file. Oh, and I had it start up quartz-vm too.

Or is this file in /etc/X11 meant for something else?



[ Reply to This | # ]
Don't
Authored by: lamon on Jan 13, '03 12:08:48PM

Don't exec xmodmap. If you do, you'll never execute the rest of the file. Only the last line should be exec'ed. And if you use your own .xinitrc, you should also exec quartz-wm :

% cat .xinitrc
xmodmap .Xmodmap
exec quartz-wm

%



[ Reply to This | # ]
Not on all international keyboards
Authored by: dani++ on Jan 13, '03 03:36:07PM
Well, that particular trick does not apply to Spanish keyboards as the system-supplied Espanol.keymapping did not work on XDarwin on the first place.

I did build an xmodmap file by hand (thanks to the helpful 'xve' command that prints X11 events to STDOUT). This worked like a charm on XDarwin and I promptly forgot about the issue. The problems begin using Apple's X11 as it does not seem to recognize some char symbols ('periodcentered' for example) and specially does not recognize the 'Alt' modifier key. Issuing a 'xmodmap -xpm' prints the modifier key setup:

xmodmap: up to 2 keys per modifier, (keycodes in parentheses): shift Shift_L (0x40), Shift_R (0x44) lock Caps_Lock (0x41) control Control_L (0x43), Control_R (0x46) mod1 Alt_L (0x42), Alt_R (0x45) mod2 Meta_L (0x3f) mod3 mod4 mod5
There seems to be no special problem with it (0x42 is the keycode of the left alt key) but Apple's X11 stubbornly refuses to accept it.

dani++

[ Reply to This | # ]

Anonymous comment...
Authored by: robg on Jan 20, '03 08:52:52AM
Submitted as a hint by Anonymous:
To change the keymapping in X11 try this: Start X11 from commandline with:
/Applications/X11.app/Contents/MacOS/X11 -keymap xyz.keymapping
Set xyz to the desired language (see /System/Library/Keyboards/ for possible keymaps). Example:
/Applications/X11.app/Contents/MacOS/X11 -keymap Deutsch.keymapping
I haven't tested it, but thought it might be useful here...

-rob.

[ Reply to This | # ]
I use it
Authored by: Ken Knoblauch on Jan 29, '03 08:32:46AM

I copied francais.keymapping to ~/Library/Keyboards/USA.keymapping and it gives
me grosso modo a French keyboard. X11 Launcher seems to do the same thing
and with its extra bells and whistles, it is pretty nice. What seems to be missing
(or I'm not astute enough to have uncovered them) are various essential characters
for unix, like |, ~, {, }, and so forth. I'd be appreciative of a fix for that, while awaiting
Apple's ultimate solution. For the moment, I'm limited to opening a Darwin terminal
and copying them from there. A fairly inefficient solution but one of desperation....



[ Reply to This | # ]
Apple's X11 and international keyboards
Authored by: Silencium68 on Apr 03, '03 04:58:01AM

How do I get the various special (like @, €, ¢[]|{}, etc.), and language specific (like äöüßÄÖÜ) characters?



[ Reply to This | # ]
Apple's X11 and international keyboards
Authored by: jmaiz on Apr 22, '03 06:37:01PM

I am new to the Mac OS X world but have used unix for a long time. The problem I am finding in trying to use international characters in OroborOSX has apparently nothing to do with the keyboard. For example, if I do:

xmodmap -pke > .xmodmap.default

and I look at the output I see that:

keycode 16 = c C ccedilla Ccedilla

However, when I try to type at the command line in an xterm the key combination Alt+c what I get as an screen output is C' , not ç.

I have already included in my .Xdefaults the line:

xterm*utf8: 1

so that unicode characters should be displayed and indeed they are when I do a ls -lav of a directory with filenames such as Imágenes. However, when I use the Tab to complete the filename what I get is Ima\314\201genes instead of Imágenes.

Am I missing something or is this a real bug in OroborOSX?






[ Reply to This | # ]
XDarwin.org hosts the USA keymap file
Authored by: ubiquitin on Jun 13, '04 11:23:37PM

http://www.xdarwin.org/USA.keymapping



[ Reply to This | # ]