GRAPHIC REDRAW statement  

Purpose

Update buffered graphical statements, drawing them to the selected graphic target.

Syntax

GRAPHIC REDRAW

Remarks

This statement is only needed when GRAPHIC ATTACH with the REDRAW option have been chosen for faster, buffered draw operations.  Otherwise, it performs no operation.

All PowerBASIC graphical displays are persistent -- they are automatically redrawn for you after resuming from being minimized or temporarily covered by other windows.

See also

GRAPHIC ATTACH

Example

FUNCTION PBMAIN

  LOCAL hWin AS DWORD

 

  ' Draw a buffered, blue gradient fill

  GRAPHIC WINDOW "Gradient", 0, 0, 255, 255 TO hWin

  GRAPHIC ATTACH hWin, 0, REDRAW

  FOR y& = 0 TO 255

    GRAPHIC LINE (0, y&) - (255, y&), RGB(0, 0, y&)

  NEXT

  GRAPHIC REDRAW

 

  SLEEP 10000

END FUNCTION