CancelFloater example for Delphi

1.

Add a command button to your main form and code the click procedure as follows:

procedure TForm1.Button1Click(Sender: TObject);
begin
   Lead1.AutoFloater := True
   Lead1.EnableFloater := True;
   Lead1.RgnMarkingMode := mmRectangle;
end;

2.

Add a second command button and code the click procedure as follows:

procedure TForm1.Button2Click(Sender: TObject);
begin
   Lead1.CancelFloater;
end;

3.

When you run the program, Click Button1 .Create a region using the mouse. Move the region with the mouse to a different location inside the bitmap.

 

 

a-

If you want to cancel the operation, click on Button2.

 

b-

If you want to paste the floater and create a new region, click on the bitmap outside the floater.