Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Ink.NearestPoint Method |
Returns the Stroke object within the Ink object that is nearest to a specified Point , given in ink space coordinates.
Definition
Visual Basic .NET Public Function NearestPoint( _
ByVal point As Point _
) As StrokeC# public Stroke NearestPoint(
Point point
);Managed C++ public: Stroke* NearestPoint(
Point *point
);
Parameters
point System.Drawing.Point. The specified point within the Ink object, given in ink space coordinates.
Return Value
Microsoft.Ink.Stroke. Returns the Stroke that contains a Point
that is closest to the specified point in the Ink object. If more than one stroke contains a Point
that is the same distance from the known Point
, the value of this result is arbitrary.
Exceptions
ObjectDisposedException
: The Ink object is disposed.
Examples
[C#]
This C# example returns the nearest Stroke object, theNearestStroke, to a known Point
, ptInk, which is given in ink space coordinates.
Stroke theNearestStroke = theInkCollector.Ink.NearestPoint(ptInk);
[Visual Basic .NET]
This Microsoft® Visual Basic® .NET example returns the nearest Stroke object, theNearestStroke, to a known Point
, ptInk, which is given in ink space coordinates.
Dim theNearestStroke As Stroke = theInkCollector.Ink.NearestPoint(ptInk)
See Also