Determines whether a point is inside a shape.
Namespace: Microsoft.VisualStudio.Modeling.Diagrams
Assembly: Microsoft.VisualStudio.Modeling.Sdk.Diagrams (in Microsoft.VisualStudio.Modeling.Sdk.Diagrams.dll)
Syntax
'Declaration
Public Function DoHitTest ( _
geometryHost As IGeometryHost, _
hitPoint As PointD, _
hitTestInfo As DiagramHitTestInfo _
) As Boolean
'Usage
Dim instance As ShapeGeometry
Dim geometryHost As IGeometryHost
Dim hitPoint As PointD
Dim hitTestInfo As DiagramHitTestInfo
Dim returnValue As Boolean
returnValue = instance.DoHitTest(geometryHost, _
hitPoint, hitTestInfo)
public bool DoHitTest(
IGeometryHost geometryHost,
PointD hitPoint,
DiagramHitTestInfo hitTestInfo
)
public:
bool DoHitTest(
IGeometryHost^ geometryHost,
PointD hitPoint,
DiagramHitTestInfo^ hitTestInfo
)
public function DoHitTest(
geometryHost : IGeometryHost,
hitPoint : PointD,
hitTestInfo : DiagramHitTestInfo
) : boolean
Parameters
geometryHost
Type: Microsoft.VisualStudio.Modeling.Diagrams.IGeometryHostThe shape or link.
hitPoint
Type: Microsoft.VisualStudio.Modeling.Diagrams.PointDThe point to test, relative to the boundary of the shape.
hitTestInfo
Type: Microsoft.VisualStudio.Modeling.Diagrams.DiagramHitTestInfoThe object that will receive the results of the hit test.
Return Value
Type: System.Boolean
true if the point is inside the shape; otherwise, false.
Remarks
The geometry boundary includes the thickness of the outline pen that lies outside of the graphics path used to draw the geometry.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.