InkAnalyzer.FindNodesOfType Method (Guid, Strokes)
Returns the ContextNode objects of the specified type that contain any of the strokes in the specified Strokes collection.
Namespace: Microsoft.Ink
Assembly: Microsoft.Ink.Analysis (in microsoft.ink.analysis.dll)
Syntax
'Declaration
Public Function FindNodesOfType ( _
type As Guid, _
strokes As Strokes _
) As ContextNodeCollection
'Usage
Dim instance As InkAnalyzer
Dim type As Guid
Dim strokes As Strokes
Dim returnValue As ContextNodeCollection
returnValue = instance.FindNodesOfType(type, strokes)
public ContextNodeCollection FindNodesOfType (
Guid type,
Strokes strokes
)
public:
ContextNodeCollection^ FindNodesOfType (
Guid type,
Strokes^ strokes
)
public ContextNodeCollection FindNodesOfType (
Guid type,
Strokes strokes
)
public function FindNodesOfType (
type : Guid,
strokes : Strokes
) : ContextNodeCollection
Not applicable.
Parameters
- type
The type of the ContextNode objects to find.
- strokes
The specified strokes.
Return Value
A ContextNodeCollection containing the ContextNode objects of the specified type that contain any of the strokes in strokes.
Remarks
If the node or one of its descendants reference a stroke in the strokes collection, this method includes that node in the return value.
Example
The following example finds all the LineNode objects that contain any of the strokes in a Strokes collection, selectedStrokes
, and marks them as red.
Dim selectedLines As ContextNodeCollection = _
theInkAnalyzer.FindNodesOfType(Microsoft.Ink.ContextNodeType.Line, selectedStrokes)
Dim line As LineNode
For Each line In selectedLines
Dim inkStroke As Stroke
For Each inkStroke In line.Strokes
inkStroke.DrawingAttributes = New DrawingAttributes(Color.Red)
Next inkStroke
Next line
ContextNodeCollection selectedLines =
theInkAnalyzer.FindNodesOfType(Microsoft.Ink.ContextNodeType.Line,
selectedStrokes);
foreach (LineNode line in selectedLines)
{
foreach (Stroke stroke in line.Strokes)
stroke.DrawingAttributes = new DrawingAttributes(Color.Red);
}
Platforms
Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.
Version Information
.NET Framework
Supported in: 3.0
See Also
Reference
InkAnalyzer Class
InkAnalyzer Members
Microsoft.Ink Namespace
Microsoft.Ink.InkAnalyzer.FindInkLeafNodes
InkAnalyzer.FindLeafNodes
InkAnalyzer.FindNode
Microsoft.Ink.InkAnalyzer.FindNodes