

Task

Clear the screen, output something on the display, and then restore the screen to the preserved state that it was in before the task was carried out.

There is no requirement to change the font or kerning in this task, however character decorations and attributes are expected to be preserved.   If the implementer decides to change the font or kerning during the display of the temporary screen, then these settings need to be restored prior to exit.




PROC Wait(BYTE frames)
  BYTE RTCLOK=$14
  frames==+RTCLOK
  WHILE frames#RTCLOK DO OD
RETURN
 
PROC Main()
  INT size=[960]
  BYTE ARRAY buffer(size)
  BYTE POINTER ptr
 
  Graphics(0)
  Position(2,10)
  Print("This is the original screen content.")
  Wait(200)
 
  ptr=PeekC(88)
  MoveBlock(buffer,ptr,size) ;copy screen content
 
  Put(125) ;clear screen
  Wait(50)
  Position(1,10)
  Print("This is an alternative screen content.")
 
  Wait(200)
  MoveBlock(ptr,buffer,size) ;restore screen content
RETURN