IInkCustomStrokes Interface

IInkCustomStrokes Interface

Contains a collection of user-defined InkStrokes collections.

Members

The following tables list the members exposed by the object.

Methods

Method Description
Add Specifies the collection of strokes to add to the collection of custom strokes.
Clear Specifies that all custom strokes are cleared from the collection.
Item Specifies the collection of strokes to return at the known index within the collection of custom strokes.

This method is exposed only in the Automation library and Microsoft® Visual Basic® .NET. In C#, use the index operator to access a particular item.

Remove Specifies the collection of strokes to remove from the known collection of custom strokes.

Properties

Property Description
_NewEnum Gets either the IEnumVARIANT or IEnumUnknown enumerator interface for the collection. Use this property to retrieve each object in the collection.

The _NewEnum property is marked restricted in the Interface Definition Language (IDL) definition for the collection interfaces. It is not shown in the Visual Basic 6.0 object browser. It is automatically used internally when you use the For Each In construct in Visual Basic 6.0.

Count Returns the number of InkStrokes collections within the collection of custom strokes.

Remarks

The custom strokes are essentially named InkStrokes collections that are persisted and recalled for later use.

You use a collection of custom strokes to store strokes that have the same meaning or that are related in some way. Examples of strokes that you may want to persist include:

  • All the strokes drawn by the same cursor (pen)
  • The strokes in an InkDisp object that correspond to a word or paragraph
  • All the strokes that intersect a known region

For example, suppose you want to draw with two different cursors and keep separate the set of strokes that you draw with each cursor. You could recognize the strokes drawn with the first cursor and attach a IInkRecognitionResult object to that collection of strokes. To persist the recognition result, add the strokes to the CustomStrokes collection of the InkDisp object. You can later access the first collection of strokes by getting the persisted CustomStrokes collection from the InkDisp object.

Each IInkCustomStrokes collection is referenced by name.

IInkCustomStrokes collections are references to ink data, not the actual data itself.

For more information about collections in Automation, see Working with Collections.

COM Implementation

This collection implements the IInkCustomStrokes COM interface.