Class RectangleF
Inheritance
Namespace: Syncfusion.Drawing
Assembly: Syncfusion.Compression.NET.dll
Syntax
public sealed class RectangleF : ValueType
Constructors
RectangleF(PointF, SizeF)
Initializes a new instance of the RectangleF class.
Declaration
public RectangleF(PointF location, SizeF size)
Parameters
Type | Name | Description |
---|---|---|
PointF | location | The location. |
SizeF | size | The size. |
RectangleF(Single, Single, Single, Single)
Initializes a new instance of the RectangleF class.
Declaration
public RectangleF(float x, float y, float width, float height)
Parameters
Type | Name | Description |
---|---|---|
System.Single | x | The horizontal location to get the starting point |
System.Single | y | The vertical location to get the starting point |
System.Single | width | The width. |
System.Single | height | The height. |
Fields
Empty
Declaration
public static readonly RectangleF Empty
Field Value
Type |
---|
RectangleF |
Properties
Bottom
Gets the bottom.
Declaration
public float Bottom { get; }
Property Value
Type | Description |
---|---|
System.Single | The bottom. |
Height
Gets or sets the height.
Declaration
public float Height { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The height. |
Left
Gets the left.
Declaration
public float Left { get; }
Property Value
Type | Description |
---|---|
System.Single | The left. |
Location
Gets or sets the location.
Declaration
public PointF Location { get; set; }
Property Value
Type | Description |
---|---|
PointF | The location. |
Right
Gets the right.
Declaration
public float Right { get; }
Property Value
Type | Description |
---|---|
System.Single | The right. |
Size
Gets or sets the size.
Declaration
public SizeF Size { get; set; }
Property Value
Type | Description |
---|---|
SizeF | The size. |
Top
Gets the top.
Declaration
public float Top { get; }
Property Value
Type | Description |
---|---|
System.Single | The top. |
Width
Gets or sets the width.
Declaration
public float Width { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The width. |
X
Gets or sets the X.
Declaration
public float X { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The X. |
Y
Gets or sets the Y.
Declaration
public float Y { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The Y. |
Methods
Equals(Object)
Determines whether the specified System.Object is equal to the current System.Object.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | The System.Object to compare with the current System.Object. |
Returns
Type | Description |
---|---|
System.Boolean | true if the specified System.Object is equal to the current System.Object; otherwise, false. |
Exceptions
Type | Condition |
---|---|
System.NullReferenceException | The |
FromLTRB(Single, Single, Single, Single)
Froms the LTRB.
Declaration
public static RectangleF FromLTRB(float left, float top, float right, float bottom)
Parameters
Type | Name | Description |
---|---|---|
System.Single | left | The left. |
System.Single | top | The top. |
System.Single | right | The right. |
System.Single | bottom | The bottom. |
Returns
Type |
---|
RectangleF |
GetHashCode()
Serves as a hash function for a particular type.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
System.Int32 | A hash code for the current System.Object. |
Inflate(SizeF)
Declaration
public void Inflate(SizeF size)
Parameters
Type | Name | Description |
---|---|---|
SizeF | size |
Inflate(Single, Single)
Declaration
public void Inflate(float x, float y)
Parameters
Type | Name | Description |
---|---|---|
System.Single | x | |
System.Single | y |
ToString()
Returns a System.String that represents the current System.Object.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | A System.String that represents the current System.Object. |
Operators
Equality(RectangleF, RectangleF)
Declaration
public static bool operator ==(RectangleF rectangle1, RectangleF rectangle2)
Parameters
Type | Name | Description |
---|---|---|
RectangleF | rectangle1 | |
RectangleF | rectangle2 |
Returns
Type |
---|
System.Boolean |
Implicit(Rectangle to RectangleF)
Declaration
public static implicit operator RectangleF(Rectangle rect)
Parameters
Type | Name | Description |
---|---|---|
Rectangle | rect |
Returns
Type |
---|
RectangleF |
Inequality(RectangleF, RectangleF)
Declaration
public static bool operator !=(RectangleF rectangle1, RectangleF rectangle2)
Parameters
Type | Name | Description |
---|---|---|
RectangleF | rectangle1 | |
RectangleF | rectangle2 |
Returns
Type |
---|
System.Boolean |