IInkAnalyzer::AddStrokesForLanguage method

Adds stroke data for multiple strokes to the IInkAnalyzer and assigns the specified culture identifier to the strokes.

Syntax

HRESULT AddStrokesForLanguage(
  [in]  ULONG        ulStrokeIdsCount,
  [in]  LONG         *plIdofStrokesToAdd,
  [in]  LONG         lStrokesLCID,
  [in]  ULONG        ulStrokePacketDescriptionCount,
  [in]  GUID         *pStrokePacketDescriptionGuids,
  [in]  ULONG        *pulPacketDataCountPerStroke,
  [in]  LONG         *plStrokePacketData,
  [out] IContextNode **ppContextNodeStrokeAddedTo
);

Parameters

ulStrokeIdsCount [in]

The number of strokes to add.

plIdofStrokesToAdd [in]

An array containing the stroke identifiers.

lStrokesLCID [in]

A value that represents the culture identifier to assign to the strokes.

ulStrokePacketDescriptionCount [in]

The number of properties in each packet.

pStrokePacketDescriptionGuids [in]

An array containing the packet property identifiers.

pulPacketDataCountPerStroke [in]

An array containing the number of packets in each stroke.

plStrokePacketData [in]

An array containing the packet data for the strokes.

ppContextNodeStrokeAddedTo [out]

The IContextNode to which the ink analyzer added the strokes.

Return value

For a description of the return values, see Classes and Interfaces - Ink Analysis.

Remarks

Caution

To avoid a memory leak, call IUnknown::Release on ppContextNodeStrokeAddedTo when you no longer need to use the object.

When ppContextNodeStrokeAddedTo is NULL, it indicates that the caller is not interested in the return value from the method.

The IInkAnalyzer adds the strokes to an IContextNode of type UnclassifiedInk (see Context Node Types). This node is in the root node's subnode collection (see IInkAnalyzer::GetRootNode Method and IContextNode::GetSubNodes methods).

The IInkAnalyzer assigns the lStrokeLCID culture identifier to the strokes and adds the strokes to the first UnclassifiedInk context node under the ink analyzer's root node that contains strokes with the same culture identifier. If the ink analyzer does not have a node with the same culture identifier, it creates a new UnclassifiedInk context node under its root node and adds the strokes to the new UnclassifiedInk context node.

plStrokePacketData contains packet data for all of the strokes. pStrokePacketDescriptionGuids contains the globally unique identifiers (GUIDs) that describe the types of packet data included for each point in each stroke. For a complete list of available packet properties, see PacketPropertyGuids Constants.

Note

Only strokes with the same packet descriptions can be added in a single call to IInkAnalyzer::AddStrokes Method.

This method expands the dirty region to the union of the region's current value and the bounding box of the added strokes.

If the IInkAnalyzer already contains a stroke with the same identifier as one of the strokes to be added, the IInkAnalyzer returns an HRESULT of E_INVALIDARG.

Requirements

Requirement Value
Minimum supported client
Windows XP Tablet PC Edition [desktop apps only]
Minimum supported server
None supported
Header
IACom.h (also requires IACom_i.c)
DLL
IACom.dll

See also

IInkAnalyzer

IInkAnalyzer::AddStroke Method

IInkAnalyzer::AddStrokeForLanguage Method

IInkAnalyzer::AddStrokes Method

IInkAnalyzer::RemoveStroke Method

IInkAnalyzer::RemoveStrokes Method

Ink Analysis Reference