HP 9000 Series 300 Tutorials Manual page 235

Device i/o and user interfacing hp-ux concepts and tutorials
Hide thumbs Also See for HP 9000 Series 300:
Table of Contents

Advertisement

• erasechar () returns the terminal erase character that has been chosen
by the user. This character is used to cancel the last previous character.
Interactive programs should include cancellation capabilities so users
can correct typographical errors during keyboard inputs.
• killchar () is similar to the erase character, but cancels the entire line
where the character appears.
• flushinp
0
discards any typeahead characters when an interrupt
character is detected. This enables users to interrupt a series of
commands or other activities that have accumulated in the typeahead
buffer and terminate the current process without waiting for the
typeahead queue to empty. Normally used for aborts, this function
and the related program structure must be handled carefully to ensure
proper termination of program processes before the program exits.
Delay Functions
Delay functions are not highly portable, but are frequently needed by programs
that use curses, especially real-time interactive response programs. Use of
these functions should be avoided where possible:
• draino
(ms)
is used to reduce the amount of data being held in
the output queue. The main purpose of this function is to keep the
program (and keyboard) from getting ahead of the screen. With careful
program design, use of this function should be unnecessary in most
cases.
• napms
(ms)
suspends program operation for a specified time. It
is similar to sleep, but offers higher resolution (resolution varies,
depending on system resources). napms uses a call to select for its
time base reference.
Using Curses and Terminfo
1-37

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Hp 9000 series 800

Table of Contents