StylusPlugInCollection Class
Assembly: PresentationCore (in presentationcore.dll)
'Declaration Public NotInheritable Class StylusPlugInCollection Inherits Collection(Of StylusPlugIn) 'Usage Dim instance As StylusPlugInCollection
public final class StylusPlugInCollection extends Collection<StylusPlugIn>
public final class StylusPlugInCollection extends Collection<StylusPlugIn>
You cannot use this managed class in XAML.
Each UIElement has a StylusPlugIns property that is a StylusPlugInCollection. Add a StylusPlugIn to the element's StylusPlugIns property to manipulate ink on the real-time thread. The order of the StylusPlugIn objects in the StylusPlugInCollection affects the appearance of the ink when it is rendered. Suppose you have a DynamicRenderer called dynamicRenderer and a custom StylusPlugIn called translatePlugin that offsets the ink from the tablet pen. If translatePlugin is the first StylusPlugIn in the StylusPlugInCollection, and dynamicRenderer is the second, the ink that "flows" will be offset as the user moves the pen. If dynamicRenderer is first, and translatePlugin is second, the ink will seem to "flow" underneath the pen, and when the user lifts the pen, the ink will move.
The following example demonstrates how to add a DynamicRenderer to a custom control. To create a control that collects ink, see Creating an Ink Input Control.
' Create a DrawingAttributes to use for the ' DynamicRenderer. Dim inkDA As New DrawingAttributes() inkDA.Width = 5 inkDA.Height = 5 inkDA.Color = Colors.Purple ' Add a dynamic renderer plugin that ' draws ink as it "flows" from the stylus Dim dynamicRenderer1 As New DynamicRenderer() dynamicRenderer1.DrawingAttributes = inkDA Me.StylusPlugIns.Add(dynamicRenderer1) inkPresenter1.AttachVisuals(dynamicRenderer1.RootVisual, dynamicRenderer1.DrawingAttributes)
System.Collections.ObjectModel.Collection
System.Windows.Input.StylusPlugIns.StylusPlugInCollection
Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.