Advertisement
TLama

Untitled

Aug 22nd, 2014
425
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Delphi 0.43 KB | None | 0 0
  1. type
  2.   TButton = class(Vcl.StdCtrls.TButton)
  3.   protected
  4.     procedure CreateWnd; override;
  5.   end;
  6.  
  7. implementation
  8.  
  9. { TButton }
  10.  
  11. procedure TButton.CreateWnd;
  12. begin
  13.   inherited;
  14.   // note, that the handle to the region passed to this function should be stored
  15.   // somewhere and released when is no longer needed by the DeleteObject function
  16.   SetWindowRgn(Handle, CreateEllipticRgn(0, 0, ClientWidth, ClientHeight), True);
  17. end;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement