InflateS(Size: IGxSizeF);
Size - size, by which it is necessary to increase.
The InflateS method increases the real rectangle by the size passed by the Size parameter.
Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
Obj: ITabObject;
RectF: IGxRectF;
SizeF: IGxSizeF;
Begin
RectF:=New GxRectF.Create(0,0,Math.RandBetween(0,60.6),Math.RandBetween(0,60.36));
SizeF:=New GxSizeF.Create(Math.RandBetween(0,14),Math.RandBetween(0,14));
Obj:=UiTabSheet1.TabSheet.Objects.Add("PrxPicture", RectF);
(Obj As IPrxPicture).Image:=GxImage.FromFile("c:\1.bmp");
RectF.InflateS(SizeF);
Obj.Rectangle:=RectF;
End Sub Button1OnClick;
After executing the example clicking the button creates an image in the regular report. The image source is the 1.bmp file. The image is created with the random size and is increased by a random size.
See also: