RectangleF.Contains Method
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Determines if the specified point is contained within this RectangleF structure.
Contains(PointF) |
Determines if the specified point is contained within this RectangleF structure. |
Contains(RectangleF) |
Determines if the rectangular region represented by |
Contains(Single, Single) |
Determines if the specified point is contained within this RectangleF structure. |
- Source:
- RectangleF.cs
- Source:
- RectangleF.cs
- Source:
- RectangleF.cs
Determines if the specified point is contained within this RectangleF structure.
public:
bool Contains(System::Drawing::PointF pt);
public readonly bool Contains (System.Drawing.PointF pt);
public bool Contains (System.Drawing.PointF pt);
member this.Contains : System.Drawing.PointF -> bool
Public Function Contains (pt As PointF) As Boolean
Parameters
Returns
true
if the point represented by the pt
parameter is contained within this RectangleF structure; otherwise, false
.
Applies to
.NET 9 and other versions
Product | Versions |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9 |
.NET Framework | 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0, 2.1 |
- Source:
- RectangleF.cs
- Source:
- RectangleF.cs
- Source:
- RectangleF.cs
Determines if the rectangular region represented by rect
is entirely contained within this RectangleF structure.
public:
bool Contains(System::Drawing::RectangleF rect);
public readonly bool Contains (System.Drawing.RectangleF rect);
public bool Contains (System.Drawing.RectangleF rect);
member this.Contains : System.Drawing.RectangleF -> bool
Public Function Contains (rect As RectangleF) As Boolean
Parameters
- rect
- RectangleF
The RectangleF to test.
Returns
true
if the rectangular region represented by rect
is entirely contained within the rectangular region represented by this RectangleF; otherwise, false
.
Applies to
.NET 9 and other versions
Product | Versions |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9 |
.NET Framework | 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0, 2.1 |
- Source:
- RectangleF.cs
- Source:
- RectangleF.cs
- Source:
- RectangleF.cs
Determines if the specified point is contained within this RectangleF structure.
public:
bool Contains(float x, float y);
public readonly bool Contains (float x, float y);
public bool Contains (float x, float y);
member this.Contains : single * single -> bool
Public Function Contains (x As Single, y As Single) As Boolean
Parameters
- x
- Single
The x-coordinate of the point to test.
- y
- Single
The y-coordinate of the point to test.
Returns
true
if the point defined by x
and y
is contained within this RectangleF structure; otherwise, false
.
Applies to
.NET 9 and other versions
Product | Versions |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9 |
.NET Framework | 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0, 2.1 |
.NET feedback
.NET is an open source project. Select a link to provide feedback: