xterm, screen and the "Home" and "End" keys
Thomas Dickey
dickey at his.com
Wed Sep 3 20:55:17 UTC 2014
On Wed, Sep 03, 2014 at 09:48:36PM +0700, Victor Sudakov wrote:
> Victor Sudakov wrote:
> >
> > Could you please help me solve the problem with screen or xterm?
> >
> > From a FreeBSD 9.3 xterm I ssh to a remote host. The "Home" key sends
> > (and the remote application receives) "0x1B 0x5B 0x48" (ESC [ H)
> > which is correct.
> >
> > However, if I start screen on the remote host, the application within
> > the screen's virtual terminal receives "0x1B 0x4F 0x48" for "Home"
> > which is "ESC O H". It results im the "Home" and key not working
> > correctly in vim etc.
> >
> > The "End" key has the same problem.
> >
>
> I think I have solved the problem by redefining what xterm is sending.
> In ~/.Xresources
>
> XTerm*VT100.translations: #override \n\
> <Key>Home: string(0x1b) string("[1~") \n \
> <Key>End: string(0x1b) string("[4~") \n
>
> Rather ugly, isn't it.
alternatively:
XTerm*VT100.keyboardType: vt220
--
Thomas E. Dickey <dickey at invisible-island.net>
http://invisible-island.net
ftp://invisible-island.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20140903/55e4c232/attachment.sig>
More information about the freebsd-questions
mailing list