Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Aug 2004 12:17:29 +0930
From:      Malcolm Kay <malcolm.kay@internode.on.net>
To:        Giorgos Keramidas <keramida@ceid.upatras.gr>, Mark Ovens <marko@freebsd.org>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: backspace and delete keys behavior
Message-ID:  <200408011217.29531.malcolm.kay@internode.on.net>
In-Reply-To: <20040731182129.GA63332@gothmog.gr>
References:  <200407301304.i6UD4F97022469@northgate.starhub.net.sg> <410BDA5F.30907@freebsd.org> <20040731182129.GA63332@gothmog.gr>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sunday 01 August 2004 03:51, Giorgos Keramidas wrote:
> On 2004-07-31 18:43, Mark Ovens <marko@freebsd.org> wrote:
> >Ion-Mihai Tetcu wrote:
> >>On Fri, 30 Jul 2004 14:30:59 +0100 Mark Ovens <marko@freebsd.org> wrote:
> >>> To implement this in a running X session type this in an xterm
> >>>
> >>> xmodmap -e "keysym Delete = 0x04"
> >>>

The default code produced by the Delete key and interpretation by X is fine.
Xterm produces the standard ANSI sequence "^[[3~" as it should and this is 
encoded in termcap for xterm as delete character. And this will work as 
expected for many applications working within an xterm window. The problem 
comes about that the shell does not honour this termcap entry.

Don't fool with xmodmap; it will work against you in applications -- just 
bind the key sequence in your shell (tcsh?)
$  bindkey "^[[3~" delete-char

I guess it would not be too difficult to extract the correct string from
termcap so that it worked for all (most) terminals but most now use the 
standard ANSI sequences so it is probably not worth the effort.

Malcolm





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200408011217.29531.malcolm.kay>