Screen and VI
Jerry McAllister
jerrymc at clunix.cl.msu.edu
Tue May 27 07:00:41 PDT 2003
> > >
> > > Anyone know why, while in screen if i move the cursor (arrow key on
> > > keyboard) right i get the letter C ? (inside vi)
> >
> > Probably the arrow key sends ESC-C as its code. something eats the ESC
> > and that leaves C.
>
> > Maybe someone else will know the actuall setting information.
>
> I usually fire up screen(1) in my console ttys or xterm windows, and
> then set TERM=vt220. This is monochrome, but all the arrow keys work
> fine. I even managed to make ALL the special keys like Insert, DEL,
> Home, End, PageDown and PageUp to work 'as expected' in Emacs with the
> following bindings in my .emacs file:
Whew, You're more ambitious than I am. I just learned to
use the letter keys to do all that. See:
http://scnc.k12.mi.us/howto/edit/vi.html
for the notes we foist on our users.
////jerry
>
> ;; Key bindings.
> (global-set-key "\C-c," 'goto-line)
> (global-set-key "\C-cw" 'delete-trailing-whitespace)
> (global-set-key "\C-xrs" 'bookmark-save)
> (global-set-key "\C-s" 'isearch-forward-regexp)
> (global-set-key "\C-r" 'isearch-backward-regexp)
>
> ;; Some bindings to make using Emacs nicer on vt220 terminals.
> (global-set-key "\C-h" 'backward-delete-char)
> (global-set-key [delete] 'delete-char)
> (global-set-key [deletechar] 'backward-delete-char)
> (global-set-key "\M-\C-h" 'backward-kill-word)
> (global-set-key [home] 'beginning-of-line)
> (global-set-key [find] 'beginning-of-line)
> (global-set-key [end] 'end-of-line)
> (global-set-key [select] 'end-of-line)
>
> - Giorgos
More information about the freebsd-questions
mailing list