Windows.UI.Input.Inking Windows.UI.Input.Inking Windows.UI.Input.Inking Windows.UI.Input.Inking Namespace

Provides input, processing, and management support for Windows Ink apps. This includes:

  • Drawing ink strokes.
  • Capturing strokes.
  • Rendering strokes.
  • Selecting strokes.
  • Deleting strokes.
  • Saving and loading strokes.
  • Converting strokes to text through handwriting recognition.
  • Copying and pasting strokes from the clipboard.
  • Hit testing (or stroke targeting).

Classes

Provides properties associated with the drawing of an InkStroke.

Provides a set of static InkDrawingAttributes properties for rendering a pencil stroke on an InkCanvas.

Get an instance of this class by calling CreateForPencil() and accessing PencilProperties.

Provides properties for managing the input behavior (standard or modified) of the InkPresenter object.

Standard ink input is not modified with a secondary affordance, such as a pen barrel button, right mouse button, or similar.

By default, modified input is processed as standard input and rendered as an InkStroke. You must set RightDragAction to InkInputRightDragAction to pass the input through as UnprocessedInput for custom processing by your app.

Note

For Universal Windows app using Extensible Application Markup Language (XAML), we recommend using InkPresenter and the InkCanvas control instead of InkManager.

Provides properties and methods to manage the input, manipulation, and processing (including handwriting recognition) of one or more InkStroke objects.

Note

For Universal Windows app using Extensible Application Markup Language (XAML), we recommend using InkPresenter and the InkCanvas control instead of InkManager.

Provides properties, methods, and events for managing the input, processing, and rendering of ink input (standard and modified) for an InkCanvas control.

Note

Standard ink input (pen tip or eraser tip/button) is not modified with a secondary affordance, such as a pen barrel button, right mouse button, or similar (see RightDragAction ).

By default, both standard and modified ink input is managed entirely by the InkPresenter and rendered to the InkCanvas as either an ink stroke or an erase stroke, based on Mode.

Modified input can be passed through to your app for processing by setting RightDragAction to InkInputRightDragAction.

All input can be passed through to your app for processing by setting Mode to InkInputProcessingMode.

Leaving input unprocessed by the InkPresenter lets you support a customized ink experience and extended functionality such as selection.

For complete control of ink input and to render it to the Direct2D device context of your Universal Windows app, instead of the default InkCanvas control, call ActivateCustomDrying() prior to loading the InkCanvas. This requires an IInkD2DRenderer object to manage the ink input (see the Complex ink sample).

Represents a visual stencil, displayed as an semi-transparent overlay on an InkCanvas.

The stencil transforms how an ink stroke is rendered:

  • It snaps the ink stroke to the stencil edge if the pen tip is within a distance threshold (gutter).
  • It acts as a mask and prevents the drawing of an ink stroke within the area obscured by the stencil.

The InkPresenterRuler can be manipulated both programmatically and by the user. It also scales and translates with the InkCanvas.

Provides properties and methods to manage InkStroke handwriting recognition data.

Recognition results are produced for each word detected by an InkRecognizer.

Manages all aspects of handwriting recognition.

Provides properties and methods to manage one or more InkRecognizer objects used for handwriting recognition.

InkRecognizerContainer is null if a recognition engine is not available on the system.

A single ink stroke, including the Bézier curve parameters used for final rendering of the stroke.

Builds strokes from raw pointer input.

Note

For Universal Windows app using Extensible Application Markup Language (XAML), we recommend using InkPresenter and the InkCanvas control instead of InkManager.

Use CreateStrokeFromInkPoints(Windows.Foundation.Collections.IIterable{Windows.UI.Input.Inking.InkPoint},Windows.Foundation.Numerics.Matrix3x2) and SetDefaultDrawingAttributes(Windows.UI.Input.Inking.InkDrawingAttributes) to programmatically build strokes for an InkPresenter.

Provides properties and methods to store and manage the collection of InkStroke objects rendered by the InkPresenter.

Modifications made to any of the ink strokes in the stroke container are immediately rendered to the drawing surface associated with the InkPresenter.

Provides properties and events for StrokeInput associated with an InkPresenter object.

A single segment of a complete ink stroke.

A single segment consists of a starting point, an ending point, and two Bezier control points. However, for a series of segments that make up a stroke, the last point of the previous segment is the first point of the current segment. This means that only the ending point for each segment is required to represent a complete stroke.

Each stroke is a vector of InkStrokeRenderingSegment objects with the first segment identified by a single starting point and all remaining segments identified by an ending point and two Bezier control points.

Contains event data for the StrokesCollected event of the InkPresenter associated with an InkCanvas control.

By default, an ink stroke is processed on a low-latency background thread and rendered wet as it is drawn. When the stroke is completed (pen or finger lifted, or mouse button released), the stroke is processed on the UI thread and rendered dry to the InkCanvas layer (above the application content). If the UI thread is busy, more than one ink stroke might be processed (collected) when the thread becomes available.

This behavior can be overridden by calling the ActivateCustomDrying() method prior to loading the InkCanvas.

Contains event data for the StrokesErased event of the InkPresenter associated with an InkCanvas control.

By default, ink stroke data and rendering is managed entirely by the InkCanvas control. However, this behavior can be overridden by calling the ActivateCustomDrying() method prior to loading the InkCanvas.

Manages the synchronization of ink input and provides methods for rendering it to the Direct2D device context of your Universal Windows app, instead of the default InkCanvas control. This requires an IInkD2DRenderer object to manage the ink input (see the Complex ink sample).

By default, ink input is processed on a low-latency background thread and rendered "wet" as it is drawn. When the stroke is completed (pen or finger lifted, or mouse button released), the stroke is processed on the UI thread and rendered "dry" to the InkCanvas layer (above the application content and replacing the wet ink).

By calling ActivateCustomDrying() (before the InkCanvas is loaded), an app creates an InkSynchronizer object to customize how an ink stroke is rendered dry to a SurfaceImageSource or VirtualSurfaceImageSource. For example, an ink stroke could be rasterized and integrated into application content instead of as a separate InkCanvas layer.

Provides properties and events for custom processing of ink data from an InkCanvas control. The data is not processed by the InkPresenter.

Use InkInputProcessingConfiguration to identify the data to pass through as UnprocessedInput.

Interfaces

Defines the implementation for a type that generates @Windows.UI.Input.Inking.InkPoint.#ctor(Windows.Foundation.Point,System.Single) objects used in the construction of an InkStroke.

Defines the implementation for a type that generates InkPresenterRuler objects used in the construction of an InkPresenter.

Represents a visual stencil, displayed as an semi-transparent overlay on an InkCanvas.

The stencil transforms how an ink stroke is rendered:

  • It snaps the ink stroke to the stencil edge if the pen tip is within a distance threshold (gutter).
  • It acts as a mask and prevents the drawing of an ink stroke within the area obscured by the stencil.

The InkPresenterRuler can be manipulated both programmatically and by the user. It also scales and translates with the InkCanvas.

Represents one or more InkRecognizer objects.

Represents a manager for the collection of InkStroke objects rendered by the InkPresenter.

Modifications made to any of the ink strokes in the stroke container are immediately rendered to the drawing surface associated with the InkPresenter.

Enums

Specifies the type of InkDrawingAttributes associated with the InkStroke.

Specifies how the InkPresenter object handles input (standard and modified) from the associated InkCanvas control.

Note

Standard input is not modified with a secondary affordance, such as a pen barrel button, right mouse button, or similar.

Input can be handled as standard ink or erase strokes, or it can be passed as UnprocessedInput through to your app for custom processing.

Specifies how the InkPresenter object handles input (standard and modified) from the associated InkCanvas control, when the input is modified with a secondary affordance, such as a pen barrel button, right mouse button, or similar.

By default, modified input is processed as standard input and rendered as an InkStroke (see remarks).

Identifies the ink input mode.

Specifies the inking behavior of one or more contact points. Used with SetPredefinedConfiguration(Windows.UI.Input.Inking.InkPresenterPredefinedConfiguration).

Specifies the type of stencil exposed by an InkPresenterRuler object.

Indicates which strokes you want to include in handwriting recognition.

Identifies the shape of the PenTip.