Failure of Alt-Gr definition in X (154 Views)
Reply
Occasional Advisor
Roberto_80
Posts: 10
Registered: ‎01-04-2004
Message 1 of 12 (154 Views)

Failure of Alt-Gr definition in X

The keyboard in use to connect from a WinXP PC in the LAN doesn't transmit AltGr
key combinations. Having used xmodmap -pk I see that the 3rd definition of a key
is not defined. I can define it by hand which works fine for hpterm and xterm,
NOT for dtterm.

firstly: what should I do to get this working from the start of a users session?
secondly: what should I do to get it working in dtterm?

The system is accessed through CDE at the HP and Cygwin at the client´s side.
Honored Contributor
Mark Grant
Posts: 2,712
Registered: ‎04-01-2003
Message 2 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

dtterm is a bit rubbish isn't it!

To get the users key map set up at start you just create a standard keymap file which you call $HOME/.xmodmaprc. You then put the xmodmap command in the users .profile.

If it is a system wide problem you can put the xmodmap command in /etc/profile, put your keymap file somewhere central like /etc/xmodmaprc and use /etc/xmodmaprc as an argument to your "xmodmap" command.

I do not know how you achieve the same thing with dtterm but I think you might have to use the -xrm argument and a resource string of some kind. The only X resources I know about for dtterm are here (near the bottom of the page)

http://www.biostat.wisc.edu/cgi-bcg/man.cgi?section=all&topic=dtterm
Never preceed any demonstration with anything more predictive than "watch this"
Esteemed Contributor
Rick Beldin
Posts: 283
Registered: ‎07-31-2000
Message 3 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

dtterm might be having problems if the PC Xserver supports the XKB (KEYBOARD) extension. HP's implementation of Xlib doesn't have full XKB support, and this can cause problems with systems that support it.

Prior to running dtterm:

# export XKB_DISABLE=1

to see if this addresses the problem.

The main difference between hpterm and dtterm in this area is that hpterm is based on X11R5 which never supported XKB and dtterm is based on X11R6 which did. Setting the environment variable forces dtterm down the 'old' path and may offer some relief.

Other symptoms of the XKB failure include the inability of the shift lock to operate properly.
Necessary questions: Why? What? How? When?
Occasional Advisor
Roberto_80
Posts: 10
Registered: ‎01-04-2004
Message 4 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

the .xmodmaprc file I configured. I have put it in my home directory with the 755 protection, but it doesn't seem to execute. Please supply
more information on how to use it when logging on via X/ CDE.

I have put XKB_DISABLE in the /etc/profile file, but it doesn't make any difference to dtterm.
Honored Contributor
Mark Grant
Posts: 2,712
Registered: ‎04-01-2003
Message 5 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

Roberto, I'm a bit unclear, are you saying that you have the xmodmaprc file AND you have put "xmodmap" either in the users startup scripts somehwhere (.dtsession,.xsession or the system wide Xsession or wherever makes sense with CDE)
Never preceed any demonstration with anything more predictive than "watch this"
Occasional Advisor
Roberto_80
Posts: 10
Registered: ‎01-04-2004
Message 6 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

.xmodmaprc is just there without being called from .profile or
/etc/profile. It works if it is executed by hand.

I guess it should be executed as soon as a X-application is started.
Honored Contributor
Mark Grant
Posts: 2,712
Registered: ‎04-01-2003
Message 7 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

Roberto,

I think you need to put the "xmodmap" command in .dtprofile
Never preceed any demonstration with anything more predictive than "watch this"
Occasional Advisor
Roberto_80
Posts: 10
Registered: ‎01-04-2004
Message 8 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

Excuse me for the delay in replying you back.

I tried to put the xmodmap command in .dtprofile.

It helps to define the keys for hpterm and xterm. The altGr key is not
working for dtterm however, nor for the X-application of sas we use.

Please tell me what to do
Honored Contributor
Mark Grant
Posts: 2,712
Registered: ‎04-01-2003
Message 9 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

Roberto,

This is quite an interesting link. It would seem dtterm, being Motif handles things slightly different. It seems you might need to put an override in the Xdefaults file. If your appliaction is based on Motif, it will have the same problrm as dtterm. Anyway, have a look and let us know if you need any help with it. At least, let us know how you get on!

http://www-h.eng.cam.ac.uk/help/tpl/unix/xkeys.html
Never preceed any demonstration with anything more predictive than "watch this"
Occasional Advisor
Roberto_80
Posts: 10
Registered: ‎01-04-2004
Message 10 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

I could not find any information on the link you supplied :-(
Occasional Visitor
Wörz
Posts: 5
Registered: ‎02-09-2004
Message 11 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

Hello,

I have the same problem, ALT-GR not working, not with dtterm, but with plain xterm.
I am starting an xterm remote on an HP machine from a linux box, via ssh or rsh, it does not matter and have the display on my linux box.
Neither @ nor | works. I checked the xmodmap output and the mod3 key, that used to be the define for alt-gr is not set any more. And I cannot set it to ALT_R, because xmodmap does not know the name ALT_R.
Looking at the output of xev I found that the ALT-GR key is now ISO_Level3_Shift (Keycode 0x71). Setting mod3 to ISO_Level3_Shift did not help, nor did the additional clear of mod5, which was orginally to ISO_Level3_Shift.

Does anybody have any additional idea what else to try?

Thanks in advance

Dieter
Occasional Visitor
Paturle
Posts: 1
Registered: ‎03-05-2004
Message 12 of 12 (154 Views)

Re: Failure of Alt-Gr definition in X

I got the same problem too.
I install the xkeycaps Tool that give a graphic view of keybord; the Altgr key is right interpreted in that case. But definitively the dttem is not understanding the key.
I do a try with an other Xserver live Omni-X and the altgr key is responding.
I'am affraid that the problem comme from cygwin/xfree server.
One thing is that i got some fonts error when running dtterm with '-dt-interface' error.
does the problem could be from font setting on cygwin/xfree that are not compatible with HP request.
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.