InkDisp Class

InkDisp Class

Represents the collected strokes of ink within an ink space.


InkBoundingBoxModeDefines values that specify which characteristics of a stroke, such as drawing attributes, are used to calculate the bounding box of the ink.
InkClipboardFormatsDefines values that specify the format of ink that is stored on the Clipboard.
InkClipboardModesDefines values that specify the copy options of the Clipboard.
InkExtractFlagsDefines values that determine what part of a stroke to remove from an InkDisp object.
CompressionModeDefines values for the compression modes that are used to save the InkDisp object to a serialized format.
InkPersistenceFormatDefines values that specify how ink is persisted.

InkAddedOccurs when a stroke is added to the InkDisp object.
InkDeletedOccurs when a stroke is deleted from the InkDisp object.

AddStrokesAtRectangleInserts a stroke collection into the InkDisp object at the specified rectangle.
CanPasteIndicates whether data (either on the Clipboard Leave Site, or as an IDataObject Leave Site) can be converted to an InkDisp object.
ClipRemoves portions of a stroke or collection of strokes that are outside a rectangle.
ClipboardCopyCopies InkDisp or InkStrokes to the Clipboard Leave Site.
ClipboardCopyWithRectangleCopies InkStrokes that are contained in the specified rectangle to the Clipboard Leave Site.
ClipboardPastePastes an IDataObject Leave Site, either specified or from the Clipboard Leave Site, to this InkDisp object.
CloneCreates a duplicate InkDisp object.
CreateStrokeCreates a stroke from points or packet data.
CreateStrokesCreates an InkStrokes collection for this InkDisp object.
DeleteStrokeDeletes a stroke from the InkDisp object.
DeleteStrokesDeletes strokes from the InkDisp object.
ExtractStrokes()Extracts strokes from the InkDisp object and returns a new InkDisp object containing the extracted strokes.
ExtractStrokes(Rectangle)Extracts strokes from the InkDisp object within the specified rectangle and returns a new InkDisp object containing the extracted strokes.
GetBoundingBoxRetrieves the bounding box of all of the strokes in the InkDisp object.
HitTest(Point, Single)Retrieves the collection of strokes that are either completely inside or intersected by a known circle.
HitTest(Point[], Single)Retrieves the strokes that are contained within a polyline selection area.
HitTest(Rectangle, Single)Retrieves the strokes that are contained within a known rectangle.
LoadPopulates a new InkDisp object with known binary data.
NearestPointRetrieves the IInkStrokeDisp within the InkDisp object that is nearest to a known point, optionally providing additional information.
SaveConverts the ink to a specified format and returns the binary data.

CustomStrokesGets the IInkCustomStrokes collection to be persisted with the ink.
DirtyGets or sets the value that indicates whether an InkDisp object has been modified since the last time the ink was saved.
ExtendedPropertiesGets the collection of application-defined data.
StrokesGets the InkStrokes collection contained in the InkDisp object.


This object can be instantiated by calling the CoCreateInstance method in C++ or by using the New keyword in Microsoft® Visual Basic® 6.0.

An InkDisp object is a container of stroke (point) data. The stroke data, or the points collected by the pen, are put into an InkDisp object. The Strokes property contains the data for all strokes within the InkDisp object.

The InkCollector object, InkOverlay object, and InkPicture control collects points from the input device and puts them into an InkDisp object. These objects essentially act as the source that distributes ink into one or many different InkDisp objects, which act as containers that hold the distributed ink.

The ink space is a virtual coordinate space to which the coordinates of the tablet context are mapped. This space is fixed to a HIMETRIC coordinate system. In ink space coordinates, a move from 0 to 1 equals 1 HIMETRIC unit. This mapping makes it easy to relate multiple InkDisp objects.

The InkRenderer object manages the mappings between ink and the display window.

COM Implementation

This object implements the IInkDisp COM interface.

Related Topics