Rect
An axis-aligned rectangle of a location and a size, produced by the arrangement pass.
- Kind: Record struct
- Namespace: SkeleKit
- Implements:
IEquatable<Rect>
Constructors
Creates a rectangle from a location and a size.
Initializes a new instance of the Rect struct.
| Parameter | Summary |
|---|---|
double X | The left edge. |
double Y | The top edge. |
double Width | The horizontal extent. |
double Height | The vertical extent. |
Properties
Bottom
Type: double
Height
The vertical extent.
Type: double
Left
The left edge (X).
Type: double
Location
The top-left corner.
Type: Point
Right
Type: double
Size
The width/height of the rectangle.
Type: Size
Top
The top edge (Y).
Type: double
Width
The horizontal extent.
Type: double
X
The left edge.
Type: double
Y
The top edge.
Type: double
Methods
Deflate
Returns this rectangle inset by thickness, clamped so size never goes negative.
| Parameter | Summary |
|---|---|
Thickness thickness | The inset applied to each edge. |
Returns
Rect: The inset rectangle.
Fields
Zero
A rectangle at the origin with zero size.
Type: Rect