home *** CD-ROM | disk | FTP | other *** search
/ Shareware Overload / ShartewareOverload.cdr / progm / tot5.zip / DEMWI4.PAS < prev    next >
Pascal/Delphi Source File  |  1991-02-11  |  1KB  |  70 lines

  1. program DemoWindowFour;
  2. {DEMWI4 - a StretchWinOBJ template}
  3. {$I totflags.inc}
  4. Uses DOS,CRT,
  5.      totFAST, totINPUT, totWIN;
  6.  
  7. var
  8.   MyWindow: StretchWinOBJ;
  9.   K: word;
  10.   X,Y: byte;
  11.  
  12. procedure ScreenRefreshProc;
  13. {This procedure would refresh the screen contents}
  14. begin
  15.    Screen.WritePlain(1,1,'Fresh Screen');
  16.    {...}
  17.    MyWindow.DrawHorizBar(1,100); {the parameters should reflect}
  18.    MyWindow.DrawVertBar(1,100);  {the data position of the window}
  19. end;
  20.  
  21. procedure ScrollUpProc;
  22. begin
  23. end;
  24.  
  25. procedure ScrollDownProc;
  26. begin
  27. end;
  28.  
  29. procedure ScrollLeftProc;
  30. begin
  31. end;
  32.  
  33. procedure ScrollRightProc;
  34. begin
  35. end;
  36.  
  37. procedure ScrollJumpVertProc(X,Y:byte);
  38. begin
  39. end;
  40.  
  41. procedure ScrollJumpHorizProc(X,Y:byte);
  42. begin
  43. end;
  44.  
  45. begin
  46.    Screen.Clear(white,'░'); {paint the screen}
  47.    with MyWindow do
  48.    begin
  49.       Init;
  50.       SetTitle(' Template ');
  51.       SetBoundary(1,1,80,25);
  52.       SetScrollable(true,true);
  53.       Draw;
  54.       ScreenRefreshProc;
  55.       Repeat
  56.          WinGetKey(K,X,Y);
  57.          case K of
  58.          602: ScreenRefreshProc;
  59.          610: ScrollUpProc;
  60.          611: ScrollDownProc;
  61.          612: ScrollLeftProc;
  62.          613: ScrollRightProc;
  63.          614: ScrollJumpVertProc(X,Y);
  64.          615: ScrollJumpHorizProc(X,Y);
  65.          end;
  66.       until (K=27) or (K=600);
  67.       Done;
  68.    end;
  69. end.
  70.