[96417] in RedHat Linux List
Parsing user input
daemon@ATHENA.MIT.EDU (Kevin A. Pieckiel)
Tue Oct 27 00:21:44 1998
Date: Mon, 26 Oct 1998 23:23:06 -0600 (CST)
From: "Kevin A. Pieckiel" <kapieckiel@Harding.edu>
To: Red Hat Mailing List <redhat-list@redhat.com>
Resent-From: redhat-list@redhat.com
Reply-To: redhat-list@redhat.com
I'm writing a program that makes use of terminfo capabilities.
In fact, this is my first attempt and thus far it's going well.
I know how to look up different capabilities with tigetstr () and
send them to the terminal via putp () and tparm ().
What is the best method of parsing user input? You see, I want
to be able to capture things like arrow keys, a DO key, and
function keys, etc., but these can be different for each
terminal. I attempted to use tigetstr () to retreive the strings
for the cuul, cudl, cubl, and cufl capabilities (cursor up, down,
left, and right), but they are not found. What is the best
method of determining when these keys are pressed? Or should I
assume my users will use a VT-100 compatible terminal? I wanted
to avoid such a limitation if I could help it....
Thanks!
Kevin
--
PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
http://www.redhat.com http://archive.redhat.com
To unsubscribe: mail redhat-list-request@redhat.com with
"unsubscribe" as the Subject.