On Sun, May 26, 2002 at 02:23:58PM +0800, Huter.Liu wrote:
> hi,Vidiot!
>       I know the arrow key and the letter key can move cursor quite
> well,but I'm wondering why not just use arrow key?so I think there's
> now arrow key in the old keyboard and the old vi have *NO* choice but
> use letter key to move cursor?who can give me a picture of the oldest
> keyboard??

No, not at all.  Vi was developed using 'curses', which even then allowed
for terminals with many, many variants of keyboards.  These are all described
in the single file /etc/termcap; do 'man termcap'.

However, various limitations in the algorithm--not the least of which
being the growing size of the flat termcap file--led to the development
of a replacement for curses called 'terminfo'.   Terminal descriptions are
pseudo-compiled and stored in individual files in a directory tree structure;
do 'man terminfo'.  You will notice a bewildering array of options and
capabilities.

Vi and terminfo are very mature programs at this point in their
lifecycyle.  I very much doubt, if your arrow keys don't work, that
it's because they're not supported by terminfo.  It's much more likely
that your terminal is misdescribed--check the TERM environment variable.
Check out 'tput'.

Cheers,
-- 
        Dave Ihnat
        [EMAIL PROTECTED]



_______________________________________________
Redhat-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-list

Reply via email to