Back to Devexpress

DiagramControl.CustomCursor Event

windowsforms-devexpress-dot-xtradiagram-dot-diagramcontrol-855e688a.md

latest1.7 KB
Original Source

DiagramControl.CustomCursor Event

Occurs when the mouse cursor enters the diagram control.

Namespace : DevExpress.XtraDiagram

Assembly : DevExpress.XtraDiagram.v25.2.dll

NuGet Package : DevExpress.Win.Diagram

Declaration

csharp
[DiagramCategory(DiagramCategory.Behavior)]
public event EventHandler<DiagramCustomCursorEventArgs> CustomCursor
vb
<DiagramCategory(DiagramCategory.Behavior)>
Public Event CustomCursor As EventHandler(Of DiagramCustomCursorEventArgs)

Event Data

The CustomCursor event's data class is DevExpress.XtraDiagram.DiagramCustomCursorEventArgs.

Remarks

Use the CustomCursor event to display a custom mouse cursor. The following example demonstrates a CustomCursor event handler that replaces the standard cursor.

csharp
private void diagramControl_CustomCursor(object sender, DiagramCustomCursorEventArgs e) {
    e.Cursor = new Cursor("/Resources/CustomCursor.ani");
}
vb
Private Sub diagramControl_CustomCursor(ByVal sender As Object, ByVal e As DiagramCustomCursorEventArgs)
    e.Cursor = New Cursor("/Resources/CustomCursor.ani")
End Sub

See Also

DiagramControl Class

DiagramControl Members

DevExpress.XtraDiagram Namespace