non-us keyboard fix in .xinitrc doesn't workForum: User Feedback Topic: non-us keyboard fix in .xinitrc doesn't work started by: pirata Posted by pirata on May 19 2006,21:08
Using DSL 2.4, frugal install to HD, I noticed that there's a fix in /home/dsl/.xinitrc for the non-us keyboard problem with not being able to reach e.g. @ (alt-gr 2 on my Swedish keyboard)
On my system this doesn't work, though. After experimenting, I found that the line
is OK, it works by itself. So I commented out the if and fi lines:
and everything works OK here! The error must be in the
I couldn't say what that would be, though, or if it's the same on other systems... Posted by pirata on May 20 2006,20:19
OK, I'll comment this myself...The output for:
is actually "us", although I have specified at bootup a non-us keyboard (Swedish)! And the Swedish keyboard works very good, with all the åäö and @£${[]}\| in their correct places. So what's wrong? Actually I notice just now that the Spanish letter ñ, that is n with a ~ on top, comes out as ~n. (I had to get the correct letter with copy and paste). That's normally a two-key combination, alt-gr ~ followed by n. Oh no, all accents are the same, ´o instead of ó etc...... Oh well... Posted by roberts on May 20 2006,23:49
How and where may I ask are you specifying your Swedish keyboard? At boot time with boot code? Using the keyboard GUI? Using the command prompt using loadkeys? Or maybe in /opt/bootlocal.sh?
Posted by pirata on May 21 2006,12:43
It's a frugal install (DSL 2.4) to HD using LILO. The installation script asked me what keyboard I wanted so I answered "se".During startup I see these lines (among many others...) pass by:
Here's my /cdrom/boot/lilo.conf file:
and here's /opt/bootlocal.sh:
I see there is a "lang=us" early in the APPEND line and a "lang=se" near the end. (Also a lot of unnecessary "hda=scsi" etc. although I specified "noscsi" during installation.) I don't specify anything else neither before nor after booting up. Actually I chose LILO because it was easy to do these "restore=hda3 home=hda3 opt=hda3 host=tor noscsi lang=se mydsl=hda3" easily during installation, which the grub script doesn't provide. (Edit: removed irrelevant and stupid part....) Thanks for a great distro! Posted by pirata on May 21 2006,12:57
Oh, but please note that the "alt-gr" problem (for reaching characters @£${[]}\|) only applies to Firefox. In e.g. Ted, they can be typed normally. The other problem with the accents seems to be more general (´o instead of ó etc.), that is, the problem appears in all applications and with or without the xmodmap fix. Just to clarify, hopefully... Posted by pirata on May 21 2006,20:02
Well, I actually managed to edit the lilo.conf file and run Lilo to make it functional.(edit: Here's how: < Config lilo > ) I changed my APPEND line to be:
This doesn't change the keyboard thing at all, though, the reason I wrote here in the first place... --- edit --- And the output for:
is still "us"... Posted by roberts on May 21 2006,23:22
The small mod in .xinitrc, as you have already seen, will not be a cure all. But you should read and try < xkeycaps >Note that it is in the repository and you do not need to get it from via apt. As for the other issue, "se" seems not to be defined in knoppix-autoconfig, which is why it is not in KEYTABLE. Using lang=se does nothing. Then manaully setting it via the keyboard tool does not update /etc/sysconfig/keyboard. Originally only the languages as defined in the original knoppix-autoconfig would be supported. I guess you have found a knoppix undefined one that does work and therefore surfaced this issue. Simple work-around add the following line to /opt/bootlocal.sh sed -i 's/us/se' /etc/sysconfig/keyboard or as you have already done comment out the 'if' statement in your .xinitrc. But to answer your question, "se" is not defined in knoppix-autoconfig so the default "us" appears in KEYTABLE. Posted by pirata on May 22 2006,08:47
Thanks for the information.Actually, come to think of it, during first boot after installation, there are several dialogs asking me for my preferred screen resolution, mouse type, etc., and, of course, preferred keyboard. That's where I chose se-latin1! I remember I found it annoying at the moment, like: "Why do you ask again?" And then these choices are saved somewhere (that would be the "loadkeys se-latin1" line in /opt/bootlocal.sh for the keyboard, right? And the other ones?), because I never got the questions again... Fine, I'll try those xkeycaps now... Posted by roberts on May 23 2006,00:51
I have corrected the kbdconf program used during the X setup routine. So the xmodmap should work for any selectable language in the table. This will be in the next release of DSL.Still for full support, the xkeycaps will be needed. Thanks for bringing this issue to surface. Posted by pirata on May 23 2006,08:33
Great! Will this take care of the "dead" keys too? I mean the "dead_acute" etc, that shouldn't produce any output when pressed and released, but rather modify the next keypress, so that the accent key followed by e.g. o, should produce ó rather than ´o. I was playing with xkeycaps and it's really weird. It made a mess of everything, here anyway . I found it more useful to modify keys through the xmodmap command line. So, by adding lines like:
to the .xinitrc, the ó would be on AltGr o, and Ó on AltGr O etc. That's inconvenient, though, for one (unlike me) used to type away a high rates... So it would be a very good thing, indeed, to make the "dead" keys act as expected. Posted by RRRR on June 02 2006,14:46
Yes, it would have been cool to have all our different regional keyboards work more effortlessly out-of-the-box (mine are norwegian, BTW). I think this could be essential for the widespread of DSL. The first thing most expect from a system is to be able to write their documents without too much hassle. Now there's a bit of work from booting to get the keys placed right. Hmmm... I don't seem to be able to produce ó or Ó at all, and as pirata reported ò becomes `oWell, thanks! And keep up the good work. Posted by Spice_Boy on June 11 2006,22:25
I will have to have more of a play with this now too, because I struggled to get my Polish keyboard working. The closest I came was actually having the Alt-Gr and appropriate letter key print something different, but nothing like the characters it was supposed to. At least it was thinking about it :-)
|