Struct RectangleF
Describes a rectanlge using float units.
Inherited Members
Namespace: Telerik.Windows.Documents.Model
Assembly: Telerik.Windows.Documents.dll
Syntax
public struct RectangleF
Constructors
RectangleF(Single, Single, Single, Single)
Initializes a new instance of the RectangleF struct.
Declaration
public RectangleF(float x, float y, float width, float height)
Parameters
System.Single
x
The x position. |
System.Single
y
The y position. |
System.Single
width
The width. |
System.Single
height
The height. |
RectangleF(PointF, SizeF)
Initializes a new instance of the RectangleF struct.
Declaration
public RectangleF(PointF location, SizeF size)
Parameters
PointF
location
The location. |
SizeF
size
The size. |
Fields
Empty
Properties
Bottom
Gets the bottom.
Declaration
public float Bottom { get; }
Property Value
System.Single
The bottom. |
Center
Height
Gets or sets the height.
Declaration
public float Height { get; set; }
Property Value
System.Single
The height. |
IsEmpty
Gets a value indicating whether this instance is empty.
Declaration
public bool IsEmpty { get; }
Property Value
System.Boolean
|
Left
Gets the left.
Declaration
public float Left { get; }
Property Value
System.Single
The left. |
Location
Gets or sets the location.
Declaration
public PointF Location { get; set; }
Property Value
PointF
The location. |
Right
Gets the right.
Declaration
public float Right { get; }
Property Value
System.Single
The right. |
Size
Top
Gets the top.
Declaration
public float Top { get; }
Property Value
System.Single
The top. |
Width
Gets or sets the width.
Declaration
public float Width { get; set; }
Property Value
System.Single
The width. |
X
Gets or sets the x position.
Declaration
public float X { get; set; }
Property Value
System.Single
The x position. |
Y
Gets or sets the y position.
Declaration
public float Y { get; set; }
Property Value
System.Single
The y position. |
Methods
Contains(Single, Single)
Determines whether this instance contains a point.
Declaration
public bool Contains(float x, float y)
Parameters
System.Single
x
The x-coordinate of the point. |
System.Single
y
The y-coordinate of the point. |
Returns
System.Boolean
|
Contains(PointF)
Determines whether this instance contains a point.
Declaration
public bool Contains(PointF point)
Parameters
PointF
point
The point. |
Returns
System.Boolean
|
Contains(RectangleF)
Determines whether this instance contains the object.
Declaration
public bool Contains(RectangleF rect)
Parameters
RectangleF
rect
The rect. |
Returns
System.Boolean
|
Equals(Object)
Determines whether the specified System.Object, is equal to this instance.
Declaration
public override bool Equals(object obj)
Parameters
System.Object
obj
The System.Object to compare with this instance. |
Returns
System.Boolean
|
Overrides
FromLtrb(Double, Double, Double, Double)
Froms the LTRB.
Declaration
public static RectangleF FromLtrb(double left, double top, double right, double bottom)
Parameters
System.Double
left
The left. |
System.Double
top
The top. |
System.Double
right
The right. |
System.Double
bottom
The bottom. |
Returns
RectangleF
|
GetHashCode()
Returns a hash code for this instance.
Declaration
public override int GetHashCode()
Returns
System.Int32
A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. |
Overrides
GetRoundedCopy(Int32)
Declaration
public RectangleF GetRoundedCopy(int decimals)
Parameters
System.Int32
decimals
|
Returns
RectangleF
|
Inflate(Single, Single)
Inflates the specified x and y coordinates.
Declaration
public void Inflate(float x, float y)
Parameters
System.Single
x
The x. |
System.Single
y
The y. |
Inflate(RectangleF, Single, Single)
Inflates the specified rect.
Declaration
public static RectangleF Inflate(RectangleF rect, float x, float y)
Parameters
RectangleF
rect
The rect. |
System.Single
x
The x. |
System.Single
y
The y. |
Returns
RectangleF
|
Inflate(SizeF)
Inflates the specified size.
Declaration
public void Inflate(SizeF size)
Parameters
SizeF
size
The size. |
Intersect(RectangleF)
Intersects the specified rect.
Declaration
public void Intersect(RectangleF rect)
Parameters
RectangleF
rect
The rect. |
Intersect(RectangleF, RectangleF)
Declaration
public static RectangleF Intersect(RectangleF rectangle1, RectangleF rectangle2)
Parameters
RectangleF
rectangle1
|
RectangleF
rectangle2
|
Returns
RectangleF
|
IntersectsWith(RectangleF)
Determines whether this instance intersects with another rectangle.
Declaration
public bool IntersectsWith(RectangleF rect)
Parameters
RectangleF
rect
The rect. |
Returns
System.Boolean
|
Offset(Single, Single)
Declaration
public void Offset(float x, float y)
Parameters
System.Single
x
|
System.Single
y
|
Offset(PointF)
ToString()
Declaration
public override string ToString()
Returns
System.String
|
Overrides
Union(RectangleF, RectangleF)
Declaration
public static RectangleF Union(RectangleF rectangle1, RectangleF rectangle2)
Parameters
RectangleF
rectangle1
|
RectangleF
rectangle2
|
Returns
RectangleF
|
Operators
Equality(RectangleF, RectangleF)
Implements the operator ==.
Declaration
public static bool operator ==(RectangleF left, RectangleF right)
Parameters
RectangleF
left
The left. |
RectangleF
right
The right. |
Returns
System.Boolean
The result of the operator. |
Implicit(Rect to RectangleF)
Declaration
public static implicit operator RectangleF(Rect rect)
Parameters
System.Windows.Rect
rect
|
Returns
RectangleF
|
Inequality(RectangleF, RectangleF)
Implements the operator !=.
Declaration
public static bool operator !=(RectangleF left, RectangleF right)
Parameters
RectangleF
left
The left. |
RectangleF
right
The right. |
Returns
System.Boolean
The result of the operator. |