prefresh(3cur)
Name
prefresh, pnoutrefresh − refresh pad
Syntax
#include <cursesX.h>
int prefresh(pad, pminrow, pmincol, sminrow, smincol, smaxrow, smaxcol)
WINDOW ∗pad;
int pminrow, pmincol, sminrow, smincol, smaxrow, smaxcol;
int pnoutrefresh(pad, pminrow, pmincol, sminrow, smincol, smaxrow, smaxcol)
WINDOW ∗pad;
int pminrow, pmincol, sminrow, smincol, smaxrow, smaxcol;
Description
The prefresh routine copies the specified pad to the physical terminal screen. It takes account of what is already displayed on the screen to optimize cursor movement.
The pnoutrefresh routine copies the named pad to the virtual screen. It then compares the virtual screen with the physical screen and performs the actual update.
These routines are analogous to the routines wrefresh and wnoutrefresh except that pads, instead of windows, are involved. Additional parameters are also needed to indicate what part of the pad and screen are involved. The upper left corner of the part of the pad to be displayed is specified by pminrow and pmincol. The co-ordinates sminrow, smincol, smaxrow, and smaxcol specify the edges of the screen rectangle that will contain the selected part of the pad.
The lower right corner of the pad rectangle to be displayed is calculated from the screen co-ordinates. This ensures that the screen rectangle and the pad rectangle are the same size.
Both rectangles must be entirely contained within their respective structures.
Return Values
The prefresh and pnoutrefresh functions return OK on success and ERR on error.