unit TrScaling;

interface

uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
	StdCtrls, FormUtils, GraphicComponents;

type
	TTrScalingForm = class(TExForm)
		XLabel: TLabel;
		YLabel: TLabel;
		Ok: TButton;
		Cancel: TButton;
		X: TFloatEdit;
		Y: TFloatEdit;
	end;

function DoEditScaling(anOwner: TComponent; var X, Y: Double): Boolean;

implementation

{$R *.DFM}

function DoEditScaling(anOwner: TComponent; var X, Y: Double): Boolean;
var
	aForm: TTrScalingForm;
begin
	aForm := TTrScalingForm.Create(anOwner);
	try
		aForm.X.Value := X;
		aForm.Y.Value := Y;
		Result := aForm.ShowModal = mrOk;
		if Result then begin
			X := aForm.X.Value;
			Y := aForm.Y.Value;
		end;
	finally
		aForm.Free;
	end;
end;


end.
