These functions scroll areas on
stdscr or on the specified window.
The
scrl() function scrolls
stdscr by
n lines. If
n is positive then then
stdscr is scrolled up.
n lines are lost from the top of
stdscr and
n blank lines are inserted at the bottom. If
n is negative then
stdscr is scrolled down.
n blank lines are inserted at the top of
stdscr and
n lines are lost from the bottom.
The
wscrl() function is the same as the
scrl() function, excepting that it scrolls the window specified by
win.
The
scroll() function scrolls the window
win up by one line.
The scrolling behaviour of a window can be controlled by using the
scrollok() function. If the
flag argument is
TRUE then a line wrap at the bottom of the window will cause the window to be scrolled up one line, if
flag is
FALSE then lines that would force a scroll will be truncated.
The
setscrreg() function sets up a software scrolling region on
stdscr which will define a region of the screen that will be scrolled. The scrolling of this region is also controlled by the
scrollok() function.
The
wsetscrreg() function does the same as the
setscrreg() function, except that the scrolling region is set on the window specified by
win.
If a scrolling region has been set with the
setscrreg() or
wsetscrreg() functions and the current cursor position is inside the scrolling region, then only the area inside the scrolling region is scrolled.