Class Rect
A Rect describes a rectangle in 2D space. It consists of a location (Left and Bottom) and dimensions (Width and Height).
Inheritance
System.Object
Rect
Namespace: PSPDFKit.Basic
Assembly: PSPDFKit.dll
Syntax
public sealed class Rect : object
Constructors
Rect(Single, Single, Single, Single)
Construct a Rect.
Declaration
public Rect(float left, float bottom, float width, float height)
Parameters
Type | Name | Description |
---|---|---|
System.Single | left | The left position of the Rect on the horizontal axis. |
System.Single | bottom | The bottom position of the Rect on the vertical axis. |
System.Single | width | The width of the Rect. |
System.Single | height | The height of the Rect. |
Properties
Bottom
The bottom position of the Rect on the vertical axis.
Declaration
public float Bottom { get; set; }
Property Value
Type | Description |
---|---|
System.Single |
Height
The height of the Rect.
Declaration
public float Height { get; set; }
Property Value
Type | Description |
---|---|
System.Single |
Left
The left position of the Rect on the horizontal axis.
Declaration
public float Left { get; set; }
Property Value
Type | Description |
---|---|
System.Single |
Width
The width of the Rect.
Declaration
public float Width { get; set; }
Property Value
Type | Description |
---|---|
System.Single |
Methods
Clone()
Clone the Rect.
Declaration
public Rect Clone()
Returns
Type | Description |
---|---|
Rect |
Union(Rect, Rect)
Calculate the union of two Rects.
Declaration
public static Rect Union(Rect first, Rect second)
Parameters
Type | Name | Description |
---|---|---|
Rect | first | The first Rect. |
Rect | second | The second Rect. |
Returns
Type | Description |
---|---|
Rect |