Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!uakari.primate.wisc.edu!samsung!think!snorkelwacker!bloom-beacon!THINK.COM!garyo From: garyo@THINK.COM (Gary Oberbrunner) Newsgroups: comp.windows.x Subject: R4 xterm modmap strangeness Message-ID: <9001090107.AA08552@prometheus.think.com> Date: 9 Jan 90 01:07:36 GMT Sender: daemon@athena.mit.edu (Mr Background) Organization: The Internet Lines: 54 I'm running vanilla R4 on a color Sun 4/110. The tests I describe below are with no window manager, no resource database, just straight out-of-the-box X. The major symptom is that my shell (tcsh), which runs in cbreak mode and eats 8-bit characters (hi bit == META), doesn't work properly with xmodmap and xterm. Here's the scenario: - Fire up X with vanilla xinit, nothing extra. Get an xterm. - Fire up a couple more xterms (all these are running tcsh). : At this point, all the xterms accept control and meta chars. - run xmodmap with the following map: remove lock = Caps_Lock remove mod1 = Meta_L remove mod1 = Meta_R add mod1 = Caps_Lock add mod1 = Alt_R add control = Meta_L add control = Meta_R : Now, all the existing xterms have their keys rebound to the new control and meta keys. So far just fine. - Start up a new xterm. : This new xterm doesn't accept any control keys (it just beeps, as if it weren't actually seeing the keys I'm typing but something else instead), and the meta keys do nothing - unaldulterated normal keys come out instead (M-f inserts an f). - Any new xterms started up now will have this problem. If I start up 'cat' and type at it, things seem fine (no meta chars, of course). The control chars appear fine. Ditto with vi. Emacs running in the new xterm window (the one with the trashed meta, etc.) seems to think that the caps lock has been turned off, but (strangely) my control key AND the old meta key have been turned into control-meta keys! No wonder tcsh is barfing, if indeed that's the story. It's getting all these meta chars when I think I'm typing controls. So it's as if the xmodmap worked partially or something. What gives? All this stuff worked like a charm under R3. What is different? Could it be related to the insert-eight-bit and insert-seven-bit actions? I tried various combos of those, but nothing seemed to help. And why do xterms started before the modmap get the correct mods but not the ones started after the modmap? I'd appreciate any insights or pointers before I go snorking around in the xterm sources. Thanks loads, in advance. - Gary Oberbrunner Thinking Machines Corporation 245 First St Cambridge, MA 02142 garyo@think.com p.s: is there any way to reset the default modmap if you've screwed it up beyond recognition?