Command Prompt for Windows




screen

void screen(int flag);

Enable or disable buffered screen output. When writing to the screen the text will not appear until enough lines have been written to fill one complete screen.

Parameter Description
flag When this value is BUFFERED, then the screen will only update after each screen full. When this value is UNBUFFERED, then the screen is updated to show any lines not yet displayed.

Returns

There is no return value.

Comments

When screen() is set to BUFFERED it should be set to UNBUFFERED before the program terminates. When screen() is not used then the screen is updated as it is written to.

The values BUFFERED and UNBUFFERED are #defined in the WOIO.H file.

Example

#include "woio.h"

int main(void)
{
    int ret;

    screen(BUFFERED);   /* enable buffered output */

    ret = dofunction();

    screen(UNBUFFERED); /* flush any lines not displayed */

    return ret;   /* error level */
}