Zoom an icon

Posted in Graphics

You can't use StretchDraw function for this, because this function will return icon with original size. But you may solve this problem by using DrawIconEx function.

procedure TForm1.Button1Click(Sender: TObject);
begin
  DrawIconEx(
    Canvas.Handle,
    5,
    5,
    Application.Icon.Handle,
    50,
    50,
    1,
    0,
    DI_NORMAL);
end;