home *** CD-ROM | disk | FTP | other *** search
/ ARM Club 3 / TheARMClub_PDCD3.iso / hensa / programming / gnat_2 / !gcc / gnat / examples / ads / screen < prev    next >
Encoding:
Text File  |  1995-11-29  |  746 b   |  34 lines

  1. --::::::::::
  2. --screen.ads
  3. --::::::::::
  4. package Screen is
  5.  
  6.   -- simple ANSI terminal emulator
  7.   -- Michael Feldman, The George Washington University
  8.   -- July, 1995
  9.  
  10.   ScreenHeight : constant Integer := 24;
  11.   ScreenWidth : constant Integer := 80;
  12.  
  13.   subtype Height is Integer range 1..ScreenHeight;
  14.   subtype Width  is Integer range 1..ScreenWidth;
  15.  
  16.   type Position is record
  17.     Row   : Height := 1;
  18.     Column: Width := 1;
  19.   end record;
  20.  
  21.   procedure Beep; 
  22.   -- Pre:  none
  23.   -- Post: the terminal beeps once
  24.   
  25.   procedure ClearScreen; 
  26.   -- Pre:  none
  27.   -- Post: the terminal screen is cleared
  28.   
  29.   procedure MoveCursor (To: in Position);
  30.   -- Pre:  To is defined
  31.   -- Post: the terminal cursor is moved to the given position
  32.   
  33. end Screen;   
  34.