This documentation is archived and is not being maintained.

InkOverlaySelectionMovedEventHandler Delegate

Represents the method that handles the SelectionMoved event of an InkOverlay object.

Namespace:  Microsoft.Ink
Assembly:  Microsoft.Ink (in Microsoft.Ink.dll)

JScript does not support delegates.


Type: System.Object

The source InkOverlay object of this event.

Type: Microsoft.Ink.InkOverlaySelectionMovedEventArgs

The InkOverlaySelectionMovedEventArgs object that contains the event data.

The SelectionMoved event occurs when the position of the current selection has changed, such as through alterations to the user interface, cut-and-paste procedures, or the Selection property.

When you create an InkOverlaySelectionMovedEventHandler delegate, you identify the method that handles the event. To associate the event with your event handler, add an instance of the delegate to the event. The event handler is called whenever the event occurs, unless you remove the delegate. For performance reasons, the default event interest is off in managed code but is turned on automatically if you add an event handler.

To get the new bounding rectangle of the Strokes collection that has been moved, call the Strokes.GetBoundingBox method.

In this example, an SelectionMoved event handler examines a selection after it has been moved. If the selected Strokes collection is moved so that any of the selection is off the left or top side of the window, then the selection is moved back to its original position.

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

Windows 7, Windows Vista, Windows Server 2008 R2, Windows Server 2008

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.0