DynamicRenderer Class


The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Draws ink on a surface as the user moves the tablet pen.

Namespace:   System.Windows.Input.StylusPlugIns
Assembly:  PresentationCore (in PresentationCore.dll)


type DynamicRenderer = 
        inherit StylusPlugIn


Initializes a new instance of the DynamicRenderer class.


Gets or sets the DrawingAttributes that specifies the appearance of the rendered ink.


Gets the UIElement to which the StylusPlugIn is attached. (Inherited from StylusPlugIn.)


Gets the cached bounds of the element.(Inherited from StylusPlugIn.)


Gets or sets whether the StylusPlugIn is active.(Inherited from StylusPlugIn.)


Gets whether the StylusPlugIn is able to accept input.(Inherited from StylusPlugIn.)


Gets the root visual for the DynamicRenderer.


Determines whether the specified object is equal to the current object.(Inherited from Object.)


Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.)


Returns a Dispatcher for the rendering thread.


Serves as the default hash function. (Inherited from Object.)


Gets the Type of the current instance.(Inherited from Object.)


Creates a shallow copy of the current Object.(Inherited from Object.)


Occurs when the DynamicRenderer is added to an element.(Overrides StylusPlugIn.OnAdded().)

System_CAPS_protmethodOnDraw(DrawingContext, StylusPointCollection, Geometry, Brush)

Draws the ink in real-time so it appears to "flow" from the tablet pen or other pointing device.


Occurs when the DrawingAttributes property changes.


Occurs when the Enabled property changes.(Overrides StylusPlugIn.OnEnabledChanged().)


Occurs when the IsActiveForInput property changes.(Overrides StylusPlugIn.OnIsActiveForInputChanged().)


Occurs when the StylusPlugIn is removed from an element.(Overrides StylusPlugIn.OnRemoved().)


Occurs on a thread in the pen thread pool when the tablet pen touches the digitizer.(Overrides StylusPlugIn.OnStylusDown(RawStylusInput).)

System_CAPS_protmethodOnStylusDownProcessed(Object, Boolean)

Occurs on the application UI (user interface) thread when the tablet pen touches the digitizer.(Overrides StylusPlugIn.OnStylusDownProcessed(Object, Boolean).)

System_CAPS_protmethodOnStylusEnter(RawStylusInput, Boolean)

Occurs on a pen thread when the cursor enters the bounds of an element.(Overrides StylusPlugIn.OnStylusEnter(RawStylusInput, Boolean).)

System_CAPS_protmethodOnStylusLeave(RawStylusInput, Boolean)

Occurs on a pen thread when the cursor leaves the bounds of an element.(Overrides StylusPlugIn.OnStylusLeave(RawStylusInput, Boolean).)


Occurs on a pen thread when the tablet pen moves on the digitizer.(Overrides StylusPlugIn.OnStylusMove(RawStylusInput).)

System_CAPS_protmethodOnStylusMoveProcessed(Object, Boolean)

Occurs on the application UI (user interface) thread when the tablet pen moves on the digitizer.(Inherited from StylusPlugIn.)


Occurs on a pen thread when the user lifts the tablet pen from the digitizer.(Overrides StylusPlugIn.OnStylusUp(RawStylusInput).)

System_CAPS_protmethodOnStylusUpProcessed(Object, Boolean)

Occurs on the application UI (user interface) thread when the user lifts the tablet pen from the digitizer.(Overrides StylusPlugIn.OnStylusUpProcessed(Object, Boolean).)

System_CAPS_pubmethodReset(StylusDevice, StylusPointCollection)

Clears rendering on the current stroke and redraws it.


Returns a string that represents the current object.(Inherited from Object.)

The DynamicRenderer class inherits from the StylusPlugIn class, and allows ink to be rendered to a surface as the user moves the mouse pointer with a tablet pen or other pointing device. You can use the DynamicRenderer to dynamically render ink on a custom control, or inherit from DynamicRenderer to perform custom rendering in real time on an ink-enabled element, such as the InkCanvas.

Dynamic rendering is done on a thread separate from the application's user interface thread when the user inputs ink with a tablet pen. When a mouse is used, dynamic rendering is done on the UI thread.


In order to reference this class as a XAML element, you must map the System.Windows.Input.StylusPlugIns CLR namespace to a prefix, and use that prefix to qualify the DynamicRenderer element. For details, see XAML Namespaces and Namespace Mapping for WPF XAML.

This class is not typically used in XAML.

The following example demonstrates how to attach a DynamicRenderer to an InkPresenter. To create a control that dynamically renders ink, see Creating an Ink Input Control.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 3.0

Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top