Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 32928 - emacs help broken if emacs runs in an xterm
Summary: emacs help broken if emacs runs in an xterm
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Seemant Kulleen (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-11-06 20:26 UTC by Reporter
Modified: 2005-04-15 04:19 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Reporter 2003-11-06 20:26:27 UTC
Reproducible: Always
Steps to Reproduce:
1. ssh from one gentoo-box to another gentoo-box from an xterm
2. try to C-H
3. repeat step 1+2 in oter distros

Actual Results:  
C-H is like backspace
works as expected in other distros


Expected Results:  
C-H works
Comment 1 Reporter 2003-11-06 20:27:45 UTC
forgot step 1.5

1.5 start emacs
Comment 2 Mamoru KOMACHI (RETIRED) gentoo-dev 2003-11-06 21:44:31 UTC
I don't think it's an emacs side bug or misconfiguration in Gentoo...
at least it does show help on my Gentoo boxes.
What does your `stty -a` say? If you have erase = ^H
it will be an expected result (C-H deletes one character
before your cursor).
If you didn't touch anything, it might be a problem in
shell or whatever. (I use emacs-21.3-r1, zsh-4.1.1-r2,
and xfree4.3.0-r3) Does using rxvt or some other terminal
emulator change the situation? Or, is it only happen you
use the shell you are using at the moment? 
Comment 3 Reporter 2003-11-07 21:15:00 UTC
I also think it has nothing to do with emacs itself.

erase *is* ^H in xterm, independent of shell; and that is 
exactly the problem. In rxvt I get erase=^?, but rxvt sets
TERM=xterm, so a lot of keys do not work in other programs.
Also, rxvt does not write utmp records and shows some other
breakage wrt ncurses apps. (because of the xterm thing)

Debian's xterm has erase=^?

Comment 4 Jeremy Maitin-Shepard 2003-11-08 09:49:35 UTC
Adding the following to your .Xresources file might fix this problem you
are having:

XTerm*backarrowKey: false
*ttyModes: erase ^?
Comment 5 Reporter 2003-11-09 17:54:19 UTC
(ignore that)
I think I'm gonna screem.
AHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH!!!
Sorry, has nothing to do with emacs, but gentoo''s xfree is seriously
broken.

(do not ignore that)
Does not work. X started from xdm, does not care about .Xresources.
(known problem, but unfortunately low priority and apparently not gonna 
be fixed soon, see #26354)
It does work from startx, but I don't want to use it because it leaves
device files in a very insecure state (see bug #26648) Also, xterm 
wouldn't match it's own termcap/terminfo any more.

Better fix is to fix xterm itself; CCing xfree.



Comment 6 Seemant Kulleen (RETIRED) gentoo-dev 2003-11-09 18:19:27 UTC
listen, can you emerge x11-terms/xterm and see if it makes a difference,
please?
Comment 7 Reporter 2003-11-13 15:36:20 UTC
Nope, still erase=^H

suggested workaround in comment #4 still works with startx but not with xdm





Comment 8 Reporter 2003-12-06 07:33:14 UTC
testing x11-terms/xterm for almost a month now, still same problem.
(Did I mention it works on Debian; or when I log into gentoo from a 
Debian xterm?)
Comment 9 roma1390 2004-12-06 12:09:48 UTC
Yes, i can say that this probles is pain in the ass. 
You can reproduce easy: use less in xterm try to search some text, and
then try to delete using backspace in search input.

This is bug of xterm, or term=xterm definition.

It's dummy solution, that every user on every host must to setup backspace key.
on xfree-x11 xterm has this setings: stty erase = ^H; and this works ok.
I will try to look what erase has xorg.
Comment 10 Seemant Kulleen (RETIRED) gentoo-dev 2005-04-14 11:45:43 UTC
Reporter, roma:

is this still an issue xterms 199 and/or 200?  We've changed some thing in the termcap/termlib handling since then (was handled upstream at our request).
Comment 11 roma1390 2005-04-14 14:06:01 UTC
<skip>
Oh... ho i like this fell... This likes like You can fly,
Rock which was on you ages ar gone away. Ech.... 
</skip>

Ok. Now unix backspace saga has now one more entry in his history, and this entry has end.

Now (with xterm-200) works backspace. But who knows what now doesn't work.....

Status: WORKSFORME
Comment 12 Seemant Kulleen (RETIRED) gentoo-dev 2005-04-15 04:19:54 UTC
Closing this then. Please reopen if this problem returns.