home *** CD-ROM | disk | FTP | other *** search
/ PC Format Collection 48 / SENT14D.ISO / tech / delphi / disk14 / doc.pak / WINCRT.INT < prev    next >
Encoding:
Text File  |  1995-08-24  |  1.9 KB  |  59 lines

  1.  
  2. {*******************************************************}
  3. {                                                       }
  4. {       Delphi Runtime Library                          }
  5. {       Windows CRT Interface Unit                      }
  6. {                                                       }
  7. {       Copyright (c) 1991,95 Borland International     }
  8. {                                                       }
  9. {*******************************************************}
  10.  
  11. unit WinCrt;
  12.  
  13. {$S-}
  14.  
  15. interface
  16.  
  17. uses SysUtils, WinTypes, WinProcs, Messages;
  18.  
  19. const
  20.   WindowOrg: TPoint =                       { CRT window origin }
  21.     (X: cw_UseDefault; Y: cw_UseDefault);
  22.   WindowSize: TPoint =                      { CRT window size }
  23.     (X: cw_UseDefault; Y: cw_UseDefault);
  24.   ScreenSize: TPoint = (X: 80; Y: 25);      { Screen buffer dimensions }
  25.   Cursor: TPoint = (X: 0; Y: 0);            { Cursor location }
  26.   Origin: TPoint = (X: 0; Y: 0);            { Client area origin }
  27.   InactiveTitle: PChar = '(Inactive %s)';   { Inactive window title }
  28.   AutoTracking: Boolean = True;             { Track cursor on Write? }
  29.   CheckEOF: Boolean = False;                { Allow Ctrl-Z for EOF? }
  30.   CheckBreak: Boolean = True;               { Allow Ctrl-C for break? }
  31.   CrtWindow: HWnd = 0;                      { CRT window handle }
  32.  
  33. var
  34.   WindowTitle: array[0..79] of Char;        { CRT window title }
  35.  
  36. procedure InitWinCrt;
  37. procedure DoneWinCrt;
  38.  
  39. procedure WriteBuf(Buffer: PChar; Count: Word);
  40. procedure WriteChar(Ch: Char);
  41.  
  42. function KeyPressed: Boolean;
  43. function ReadKey: Char;
  44. function ReadBuf(Buffer: PChar; Count: Word): Word;
  45.  
  46. procedure GotoXY(X, Y: Integer);
  47. function WhereX: Integer;
  48. function WhereY: Integer;
  49. procedure ClrScr;
  50. procedure ClrEol;
  51.  
  52. procedure CursorTo(X, Y: Integer);
  53. procedure ScrollTo(X, Y: Integer);
  54. procedure TrackCursor;
  55.  
  56. procedure AssignCrt(var F: Text);
  57.  
  58. implementation
  59.