AnalysisRegion.IntersectsWith 方法

确定 AnalysisRegion 的区域是否与指定的矩形相交。

命名空间:  Microsoft.Ink
程序集:  Microsoft.Ink.Analysis(在 Microsoft.Ink.Analysis.dll 中)

语法

声明
Public Function IntersectsWith ( _
    rectangle As Rectangle _
) As Boolean
用法
Dim instance As AnalysisRegion
Dim rectangle As Rectangle
Dim returnValue As Boolean

returnValue = instance.IntersectsWith(rectangle)
public bool IntersectsWith(
    Rectangle rectangle
)
public:
bool IntersectsWith(
    Rectangle rectangle
)
public boolean IntersectsWith(
    Rectangle rectangle
)
public function IntersectsWith(
    rectangle : Rectangle
) : boolean

参数

返回值

类型:System.Boolean
如果 AnalysisRegion 的区域与指定的矩形相交,则为 true;否则为 false。

备注

比较以墨迹空间坐标进行。

如果传入的矩形只与分析区域的某个矩形共享一条边框,则 IntersectsWith 返回 false。

示例

此示例测试 AnalysisRegion (theFirstAnalysisRegion) 是否与指定的矩形相交。

' Test for intersection between an AnalysisRegion and a rectangle.
If theFirstAnalysisRegion.IntersectsWith( _
    New System.Drawing.Rectangle(50, 50, 100, 100)) Then
    ' Insert code here.
End If
            // Test for intersection between an AnalysisRegion and a rectangle.
            if (theFirstAnalysisRegion.IntersectsWith(
                new System.Drawing.Rectangle(50, 50, 100, 100)))
            {
                // Insert code here.
            }

平台

Windows Vista

.NET Framework 和 .NET Compact Framework 并不是对每个平台的所有版本都提供支持。有关支持的版本的列表,请参见.NET Framework 系统要求

版本信息

.NET Framework

受以下版本支持:3.0

另请参见

参考

AnalysisRegion 类

AnalysisRegion 成员

Microsoft.Ink 命名空间