Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

wrefresh(3cur)

wnoutrefresh(3cur)

NAME

wnoutrefresh, doupdate − do efficient refresh

SYNTAX

wnoutrefresh(win)
WINDOW ∗win;

doupdate()

DESCRIPTION

The wnoutrefresh routine updates screens more efficiently than using the wrefresh routine by itself. The wnoutrefresh routine copies the named window to a data structure referred to as the virtual screen (stdscr).  The virtual screen contains what a program intends to display on the physical terminal screen.  The routine doupdate compares the virtual screen to the physical screen and then does the actual update. These two routines allow multiple updates with more efficiency than wrefresh.

The routine wrefresh works by calling wnoutrefresh, and then calling doupdate. If a programmer wants to output several windows at once, a series of calls to wrefresh will result in alternating calls to wnoutrefresh and doupdate, causing several bursts of output to the screen. If wnoutrefresh is called first for each window, doupdate only needs to be called once, resulting in only one burst of output. This usually results in fewer total characters being transmitted and less CPU time used.

SEE ALSO

wrefresh(3cur)

Subroutines

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026