从TIMAGE继承下来一个TDblImage
TDblImage=class(TImage)
protected
procedure Loaded; override;
public
constructor Create(AOwner:TComponent); overried;
destructor Destroy; override;
procedure BuildDblImage;
published
OrgImage : TPicture;
AddImage : TPicture;
HMargin : Integer;
VMargin : Integer;
constructor Create(AOwner : TComponent);
begin
inherited;
OrgImage := TPicture.Create;
AddImage := TPicture.Create;
end;
destructor Destroy;
begin
OrgImage.Free;
AddImage.Free;
inherited;
end;
procedure Loaded;
begin
inherited;
BuildDblImage;
end;
procedure BuildDblImage;
var Bitmap : TBitmap;
begin
Bitmap := TBitmap.Create;
Bitmap.Assign(OrgImage);
Bitmap.Canvas.Draw(HMargin, VMargin, AddImage.Graphic);
Picture.Assign(Bitmap);
Bitmap.Free;
end;
网吧没有DELPHI,我写个大概,你在自己调一下