IGxSize.ReduceS

Syntax

ReduceS(Size: IGxSize);

Parameters

Size. The size used for decreasing.

Description

The ReduceS method decreases the current size to the size passed in the Size parameter.

Comments

The size is determined with integer values.

Example

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);

Var

Size, Size1: IGxSize;

Rect: IWxRectangle;

Begin

Size:=New GxSize.Create(10,10);

Size1:=New GxSize.Create(35,27);

Rect:=UiWorkspace1.WxWorkspace.CreateRectangle;

Rect.BeginUpdate;

Size.ReduceS(Size1);

Rect.Size:=New GxSizeF.CreateFromSize(Size.ToSizeF);

Rect.EndUpdate;

End Sub Button1OnClick;

After executing the example clicking the button creates a rectangle in the workspace, and its size is decreased by the value of the Size size.

See also:

IGxSize