$INCLUDE: 'C:\FG\INTRFACE.FOR'

      PROGRAM MAIN

      INTEGER*2 OLD_MODE
      INTEGER*2 FG_AUTOMODE, FG_GETMAXX, FG_GETMAXY, FG_GETMODE

      OLD_MODE = FG_GETMODE()
      CALL FG_SETMODE(FG_AUTOMODE())

      CALL FG_SETCOLOR(2)
      CALL FG_RECT(0,FG_GETMAXX(),0,FG_GETMAXY())
      CALL FG_WAITKEY

      CALL FG_SETCOLOR(15)
      CALL FG_FADEOUT(0)
      CALL FG_WAITKEY

      CALL FG_SETMODE(OLD_MODE)
      CALL FG_RESET

      STOP ' '
      END
