HP 9000 Series 300 Tutorials Manual page 271

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

Advertisement

when setting up and initializing other windows, as appropriate. When keypad
is enabled, keypad character sequences are passed to the program by getch,
but they are converted to special character values starting at 0401 octal
(keypad character codes are listed in the keypad discussion early in this
tutorial). Keypad codes are 16-bit values, and must not be stored in a char
type variable because the upper bits must be preserved.
When keypad keys are used in a program, avoid using the escape key for
program control because most keypad sequences begin with escape. If escape
is used for program control, an ambiguity results that is not easily dealt with,
and, at best, results in sluggish program response to all escape sequences as
well as significant potential for incorrect program operation.
Scrolling Regions
Each window has a programmer-accessible scrolling region that is normally set
to include the entire window. curses contains a routine that can be used to
change the scrolling region to any location in the window by specifying the top
and bottom margin lines. The routines are called by
setscrreg(top,bottom)
for the stdscr window, or
wsetscrreg(win ,top ,bottom)
for other windows. When the cursor advances beyond the bottom line in
the region, all lines in the region are moved up one line (destroying the top
line in the process) and a new line at the bottom of the region becomes the
new cursor line. If scrolling has been enabled by a call to scrollok for that
window, scrolling takes place, but only within the window boundary (if
scrollok is not enabled, the cursor stays on the bottom line and no scrolling
can occur). The scrolling region is a software feature only, and only causes a
given window data structure to scroll. It mayor may not translate to use of
the hardware scrolling region that is featured on some terminals or hardware
insert/delete line capabilities on the terminal.
Program Operation
3-7

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Hp 9000 series 800

Table of Contents