[Visual Basic] Sub Resize(w As Double, h As Double)
Sub Resize(w As Double, h As Double, corner as Corner)
Params
Name
Description
w
The new width.
h
The new height.
corner
The corner to pin.
Notes
Changes the width and height of the rectangle while maintaining
the position.
When you change the width or height of a rectangle one corner of
the rectangle is pinned to maintain position. The corner which is
pinned is indicated by the Pin property but you can override
this default by specifying a corner when calling this function.
Example
The following code.
var rc = new XRect();
rc.String = "20 20 220 120";
Response.Write($"Rect = {rc}");
Response.Write("<br>");
rc.Resize(50, 150);
Response.Write($"Pos. = {rc}");
Dim rc As New XRect()
rc.String = "20 20 220 120"
Response.Write($"Rect = {rc}")
Response.Write("<br>")
rc.Resize(50, 150)
Response.Write($"Pos. = {rc}")