unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* Problem with interpretation of <-Backspace key in version 21.2.1
@ 2002-04-06 15:55 Rabbe Fogelholm
  2002-04-06 17:24 ` Eli Zaretskii
  0 siblings, 1 reply; 3+ messages in thread
From: Rabbe Fogelholm @ 2002-04-06 15:55 UTC (permalink / raw)


When using Emacs (and other programs) from a PC keyboard I am used to
thinking of the "<-Backspace" key as the key that erases the character
to the left of the cursor.

(To avoid any confusion: I mean the rightmost key in the 0123 row,
typically placed just above the Enter key).

In Emacs 20.7.1 the <-Backspace key does the right thing. In Emacs
21.2.1 this has changed--the character to the right of the cursor is
deleted. By doing M-X describe-key I get the following:

    20.7.1 says "DEL runs the command backward-delete-char-untabify"
    21.2.1 says "C-d runs the command delete-char"

My setup might be important. The PC runs Red Hat Linux 7.1 and KDE. In
that environment I run an xterm (version XFree86 4.0.3(156)). From the
xterm session I do an ssh login to a Solaris/SPARC machine that starts a
login shell which is 6.10.00 (Astron). From the tcsh prompt I start
Emacs with the -nw option.

(If I leave out the -nw option Emacs will run in its own window on the
KDE desktop, and in that case Emacs does the right thing with the
"<-Backspace" key regardless of whether it is Emacs 20.7.1.or 21.2.1, so
the problem seems to be confined to the emacs -nw invocation.)

--Rabbe Fogelholm, Stockholm, Sweden

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Problem with interpretation of <-Backspace key in version 21.2.1
  2002-04-06 15:55 Problem with interpretation of <-Backspace key in version 21.2.1 Rabbe Fogelholm
@ 2002-04-06 17:24 ` Eli Zaretskii
  2002-04-06 21:47   ` Rabbe Fogelholm
  0 siblings, 1 reply; 3+ messages in thread
From: Eli Zaretskii @ 2002-04-06 17:24 UTC (permalink / raw)
  Cc: bug-gnu-emacs

> From: Rabbe Fogelholm <Rabbe.Fogelholm@era-t.ericsson.se>
> Newsgroups: gnu.emacs.bug
> Date: Sat, 06 Apr 2002 17:55:46 +0200
> 
> My setup might be important. The PC runs Red Hat Linux 7.1 and KDE. In
> that environment I run an xterm (version XFree86 4.0.3(156)). From the
> xterm session I do an ssh login to a Solaris/SPARC machine that starts a
> login shell which is 6.10.00 (Astron). From the tcsh prompt I start
> Emacs with the -nw option.

It sounds like this is not a bug, but an intended change in behavior,
which somehow clashes with your xterm/Emacs customizations which were
optimized for the pre-v21 behavior.

My guess is that your xterm and/or your shell startup files on the
Solaris side set up the Backspace key to produce the [deletechar]
escape sequence.  Try using "C-h l" (that's a letter ell, not a digit
one) to see what does Emacs receive when you press that key.

Also, the new function normal-erase-is-backspace-mode might help you
set this straight.  The description of the related issues in the
manual, in the sections "Deletion" and "If <DEL> Fails to Delete",
should also prove useful.

If all of the above does not help to resolve the problem, or at least
understand why exactly the behavior changed since Emacs 20.7, please
report the details that you discovered here.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Problem with interpretation of <-Backspace key in version 21.2.1
  2002-04-06 17:24 ` Eli Zaretskii
@ 2002-04-06 21:47   ` Rabbe Fogelholm
  0 siblings, 0 replies; 3+ messages in thread
From: Rabbe Fogelholm @ 2002-04-06 21:47 UTC (permalink / raw)


Eli Zaretskii wrote:
> 
> > From: Rabbe Fogelholm <Rabbe.Fogelholm@era-t.ericsson.se>
> > Newsgroups: gnu.emacs.bug
> > Date: Sat, 06 Apr 2002 17:55:46 +0200
> >
> > My setup might be important. The PC runs Red Hat Linux 7.1 and KDE. In
> > that environment I run an xterm (version XFree86 4.0.3(156)). From the
> > xterm session I do an ssh login to a Solaris/SPARC machine that starts a
> > login shell which is 6.10.00 (Astron). From the tcsh prompt I start
> > Emacs with the -nw option.
> 
> It sounds like this is not a bug, but an intended change in behavior,
> which somehow clashes with your xterm/Emacs customizations which were
> optimized for the pre-v21 behavior.
>
> My guess is that your xterm and/or your shell startup files on the
> Solaris side set up the Backspace key to produce the [deletechar]
> escape sequence.  Try using "C-h l" (that's a letter ell, not a digit
> one) to see what does Emacs receive when you press that key.

I don't have any customizations that should affect this. My .emacs file
contained just one thing which was (font-lock-mode 1), and my .Xdefaults
file contained nothing relevant.

> Also, the new function normal-erase-is-backspace-mode might help you
> set this straight.  The description of the related issues in the
> manual, in the sections "Deletion" and "If <DEL> Fails to Delete",
> should also prove useful.
> 
> If all of the above does not help to resolve the problem, or at least
> understand why exactly the behavior changed since Emacs 20.7, please
> report the details that you discovered here.

It turned out that a usable workaround for me is to add this to the
.emacs file:

(if (functionp 'normal-erase-is-backspace-mode)
  (apply 'normal-erase-is-backspace-mode '(0))
)

The code has no effect with older versions of emacs, and sets things
"right" for me with the -nw option in version 21.2.1.

I now realize that this is an intended change in 21.2 (see
<http://www.gnu.org/software/emacs/NEWS.21.2> and search for
normal-erase-is-backspace). Perhaps it makes life easier for some users,
but given my particular setup it caused me a bit of confusion.

--Rabbe Fogelholm

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2002-04-06 21:47 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-06 15:55 Problem with interpretation of <-Backspace key in version 21.2.1 Rabbe Fogelholm
2002-04-06 17:24 ` Eli Zaretskii
2002-04-06 21:47   ` Rabbe Fogelholm

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).