Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
No alt /alt-gr mappings in xfree-4.2.1-r2
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
zoyd_wheeler
n00b
n00b


Joined: 22 Mar 2003
Posts: 40

PostPosted: Tue Mar 25, 2003 9:48 pm    Post subject: No alt /alt-gr mappings in xfree-4.2.1-r2 Reply with quote

While running X, I can not use any keys from f.ex AltGr+2 AltGr+3 etc, but end up with 2,3 instead of at or poundsign.
In otherwords, I do not get any characters corresponding to the alt-keys.
Running xmodmap -pk shows that there is no "third column" of keysyms, at all.
What I set in XF86Config does not change this, ie if I have
Option "XkbLayout" "us"
or
Option "XkbLayout" "se" (since my keyboard is Swedish)
or
Option "XkbLayout" "sick_of_this"
the result is still the same.

XFree86.0.log looks like this:
...
(==) Using config file: "/etc/X11/XF86Config"
(==) ServerLayout "XFree86 Configured"
(**) |-->Screen "Screen0" (0)
(**) | |-->Monitor "Fujitsu"
(**) | |-->Device "Nvidia"
(**) |-->Input Device "Mouse0"
(**) |-->Input Device "Keyboard0"
(**) Option "XkbRules" "xfree86"
(**) XKB: rules: "xfree86"
(**) Option "XkbModel" "pc102"
(**) XKB: model: "pc102"
(**) Option "XkbLayout" "us"
(**) XKB: layout: "us"
(**) Option "XkbVariant" "nodeadkeys"
(**) XKB: variant: "nodeadkeys"
(==) Keyboard: CustomKeycode disabled
...
- no errors or warnings.

I kinda at a loss to what the problem is. Saw this thread about the same issue
https://forums.gentoo.org/viewtopic.php?t=2356&highlight=keymap
but it never seemed to be solved...

And, ofcourse, everything works fine as long as I not running X ( I have KEYMAP=se-latin1 set in rc.conf)
Have tried two different keyboards, this one being a HP 102 Key PC keyboard, but the problem seems to be all about the keymap being... one column short...

Any ideas what could be wrong?
Back to top
View user's profile Send private message
mr_neutron
Tux's lil' helper
Tux's lil' helper


Joined: 05 Jan 2003
Posts: 124
Location: Germany

PostPosted: Tue Mar 25, 2003 10:51 pm    Post subject: Reply with quote

If you cannot solve it otherwise, you can remap virtually any key on you keyboard with xmodmap.
put this in ~/.Xmodmap:
Code:
keycode 113  = Mode_switch

(mode_switch means AltGr) and this in ~/.xinitrc:
Code:
xmodmap ~/.Xmodmap

But if you AltGr doesn't work, then the AltGr+* keymappings probably aren't defined either, so you would have to add them manually in .Xmodmap, e.g.:
Code:
keycode 24 = q Q at
keycode 58 = m M mu
keycode 26 = e E EuroSign

(this is for german keyboard, don't know about swedish one)
Back to top
View user's profile Send private message
zoyd_wheeler
n00b
n00b


Joined: 22 Mar 2003
Posts: 40

PostPosted: Wed Mar 26, 2003 7:55 pm    Post subject: Reply with quote

Remappng the way u suggested solved the problem. Ended up doing a xmodmap -pke on my portable computor running RH, writing that to ~/.Xmodmap, and with a few changes I got a working map.
Thanx!
(Il leave fixing whatever actually is wrong to the future)
Back to top
View user's profile Send private message
mr_neutron
Tux's lil' helper
Tux's lil' helper


Joined: 05 Jan 2003
Posts: 124
Location: Germany

PostPosted: Thu Mar 27, 2003 11:42 pm    Post subject: Reply with quote

Quote:
xmodmap -pke

Ahhh, and I have searched endlessly to find the 'correct' names of all the funny symbols (asciitilde, asciicircum)...
Now this is easy. Thanks, man! :D
(Note to self: pay attention when reading man pages!)
Back to top
View user's profile Send private message
mjoswig
Tux's lil' helper
Tux's lil' helper


Joined: 05 Feb 2003
Posts: 122
Location: Hamburg, Germany

PostPosted: Fri Mar 28, 2003 9:28 am    Post subject: Reply with quote

An easier way could be setxkbmap -rules xfree86 -model pc104 -layout se -variant nodeadkeys
BTW: Why are you using the pc102 shouldn't it be pc104?
Back to top
View user's profile Send private message
zoyd_wheeler
n00b
n00b


Joined: 22 Mar 2003
Posts: 40

PostPosted: Fri Mar 28, 2003 5:26 pm    Post subject: Reply with quote

Hmm... The setxkbmap worx... But I don´t understand why.
Whats the diff from that cmd, and the XF86Config file? (They seem to set the same thing, although the configfile appears to be ignored.)
Reason for using pc102 is that my keyboard has 102 keys, atlhough perhaps not very pc (I took it from a HP 9000 series server).
(Everytime I switch to a new keyboard I seem to end up actually counting the keys... If anyone has a better idea I´m all ears )
Back to top
View user's profile Send private message
mjoswig
Tux's lil' helper
Tux's lil' helper


Joined: 05 Feb 2003
Posts: 122
Location: Hamburg, Germany

PostPosted: Fri Mar 28, 2003 5:58 pm    Post subject: Reply with quote

I'm using the pc104 even on my Laptop which doesn't have that many keys, have you tried it?
And your main question: Are you sure you only have Keyboard0 defined in /etc/X11/XF86Config?
Back to top
View user's profile Send private message
c07
Veteran
Veteran


Joined: 25 Oct 2002
Posts: 1091

PostPosted: Fri Mar 28, 2003 9:01 pm    Post subject: Reply with quote

zoyd_wheeler wrote:
(==) Using config file: "/etc/X11/XF86Config"
[...]
(**) Option "XkbLayout" "us"

Are you sure you had not |Option "XkbLayout" "us"| somewhere in /etc/X11/XF86Config at the time the log was created? That would really be strange.

zoyd_wheeler wrote:
(Everytime I switch to a new keyboard I seem to end up actually counting the keys... If anyone has a better idea I´m all ears )

You could emerge xkeycaps and use that, but a rule of thumb for PC keyboars is this:
  • pc101: US (left shift wider than caps lock)
  • pc102: International (left shift thinner than caps lock)
  • pc104: pc101 + Windows keys
  • pc105: pc102 + Windows keys

BTW, you can use xev to get keycodes/keysyms and test the keyboard on a low level (sometimes apps mangle keys).
Back to top
View user's profile Send private message
zoyd_wheeler
n00b
n00b


Joined: 22 Mar 2003
Posts: 40

PostPosted: Sat Mar 29, 2003 10:42 am    Post subject: Reply with quote

Quote:

Are you sure you had not |Option "XkbLayout" "us"| somewhere in /etc/X11/XF86Con
fig at the time the log was created?

I did try a bunch of different settings, and, yes, at the time of the log I enclosed I had "XkbLayout" "us" set. It made no difference if I had that, or "se", or something else (except then, that the logfile showed msgs corresponing to the different settings).
This is the way it looks, and should look n work (as far as I can tell) without
add-on fixes in ~/.xinitrc

Section "InputDevice"
Identifier "Keyboard0"
Driver "keyboard"
Option "XkbRules" "xfree86"
Option "XkbModel" "pc102"
Option "XkbVariant" "nodeadkeys"
Option "XkbLayout" "se"
EndSection

BTW, thanks for the "rule of thumb for pc keyboards" - seems accurate as far as
I can tell. No more counting
:)

Quote:

Are you sure you only have Keyboard0 defined in /etc/X11/XF86Config?

I did a "find /etc /usr -exec grep Keyboard0 {} \;" coming up with only XF86config and the XFree86 binary.
As for the pc104, I have tried it (in XF86Config) but it does not make a difference.
When I just run X "raw", using the XF86Config above I get this msg to st.err:

The XKEYBOARD keymap compiler (xkbcomp) reports:
> Error: No Symbols named "nodeadkeys" in the include file "us"
> Exiting
> Abandoning symbols file "default"
Errors from xkbcomp are not fatal to the X server

which, to me, indicates that for some reason XFree86 starts with a us keyboard no matter what I specify in the config. If uncommenting the blabla "nodeadkeys" line, no error msg is shown, but the keyproblem prevails, and xmodmap -pk still shows no "third column".

Probably Im overlooking something very basic.
Back to top
View user's profile Send private message
c07
Veteran
Veteran


Joined: 25 Oct 2002
Posts: 1091

PostPosted: Sat Mar 29, 2003 1:51 pm    Post subject: Reply with quote

zoyd_wheeler wrote:
> Error: No Symbols named "nodeadkeys" in the include file "us"

Seems there's something wrong with your /etc/X11/xkb/rules/xfree86 file ( /etc/X11/xkb is a symlink to /usr/X11R6/lib/X11/xkb in Gentoo).

There should be something like

Code:
! model      variant      =   symbols
  pc102      nodeadkeys   =   en_US(pc102%_v)+%l%(v)

telling xkbcomp to use symbols from section pc102_nodeadkeys of /etc/X11/xkb/symbols/en_US and add symbols from section nodeadkeys of /etc/X11/xkb/symbols/se. These should include us(pc102) resp. se(basic), but not us(nodeadkeys).

When you have variant nodeadkeys in conjunction with us layout, the error is normal, however.
Back to top
View user's profile Send private message
fbreuer
n00b
n00b


Joined: 04 Oct 2002
Posts: 47
Location: Berlin, Germany

PostPosted: Sat Apr 19, 2003 1:20 pm    Post subject: Reply with quote

Hello *,

Since I updated my system to XFree86 4.3.0-r1 I have a similar problem: all AltGr+* keys are dead, ie. pressing AltGr+<something> does not produce any result. However, this happens only when I run Gnome. Inside GDM I can use AltGr+* key combinations just fine, but after Gnome is launched this stops working. So my guess is, that in my case this is not a X server problem...

I have not tried the tips in this thread because: there is no program xmodmap or setxkbmap on my system... what package are they in?

PS:
1) I run Gnome with Metacity as WM.
2) Inside a Fluxbox-session I do not have this problem.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum