home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 17 / CD_ASCQ_17_101194.iso / bonus / tpwform / moule.pas < prev    next >
Pascal/Delphi Source File  |  1994-08-11  |  808b  |  40 lines

  1. program moule; (* Un squelette de programme minimal *)
  2.  
  3. uses wintypes,winprocs,wobjects;
  4.  
  5. const
  6.  id = 100;
  7. type
  8.   tprog = object(tapplication)
  9.     procedure initmainwindow;virtual;
  10.   end;
  11.  
  12.   pfenetre =^tfenetre;
  13.  
  14.   tfenetre = object(twindow)
  15.     constructor init(ancetre : pwindowsobject; titre: pchar);
  16.   end;
  17.  
  18. procedure tprog.initmainwindow;
  19. begin
  20.   mainwindow := new(pfenetre,init(nil,'DΘmo'));
  21. end;
  22.  
  23. constructor tfenetre.init(ancetre : pwindowsobject; titre: pchar);
  24. begin
  25.   twindow.init(ancetre,titre);
  26.   attr.x := 30;
  27.   attr.y := 30 ;
  28.   attr.h := 300 ;
  29.   attr.w := 500  ;
  30.   attr.style := ws_overlapped or ws_visible {OR ws_hscroll OR
  31.   ws_vscroll} or ws_sysmenu;
  32. end;
  33.  
  34. var prog : tprog;
  35. begin
  36.   prog.init('A_quoi_ca_sert_la_frite');
  37.   prog.run;
  38.   prog.done;
  39. end.
  40.