InkCanvas.DefaultDrawingAttributesReplaced Event

 
System_CAPS_noteNote

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

Occurs when the DefaultDrawingAttributes property is replaced.

Namespace:   System.Windows.Controls
Assembly:  PresentationFramework (in PresentationFramework.dll)

Public Event DefaultDrawingAttributesReplaced As DrawingAttributesReplacedEventHandler

The following example checks the value of the IsHighlighter property of the new DrawingAttributes object.

Private Sub inkCanvas1_DefaultDrawingAttributesReplaced(ByVal sender As Object, _
                            ByVal e As DrawingAttributesReplacedEventArgs)

    If (e.NewDrawingAttributes.IsHighlighter) Then

        Me.Title = "Now using a highlighter."

    Else

        Me.Title = "Now using a pen."

    End If

End Sub

.NET Framework
Available since 3.0
Return to top
Show: