Rect.Contains(Point) 方法

定義

指出 Rect 所描述矩形是否包含指定的點。

public:
 bool Contains(Windows::Foundation::Point point);
public bool Contains (Windows.Foundation.Point point);
member this.Contains : Windows.Foundation.Point -> bool
Public Function Contains (point As Point) As Boolean

參數

point
Point

要檢查的點。

傳回

如果 Rect 描述的矩形包含指定的點,則為 true;否則為 false

備註

此結構代表 Windows 執行階段 (WinRT) Rect 結構的 .NET 投影。 如需詳細資訊,請參閱 UWP API 參考中的 Rect

如需此成員的詳細資訊和範例,請參閱 < .NET Framework API 參考中的 System.Windows.Rect.Contains%2A?displayProperty=nameWithType > 。 (範例顯示 WPF 使用方式,可能不會直接轉譯為 UWP XAML.)

適用於