Mouse

[Handler(Mouse.IHandler)] public static class Mouse
Static methods to get the current mouse state

Properties

Buttons

#
public static MouseButtons Buttons { get; }
Gets the current state of the mouse buttons

IsSupported

#
public static bool IsSupported { get; }
Gets a value indicating whether the current platform supports mouse functions in this class

Position

#
public static PointF Position { get; set; }
Gets or sets the current mouse position in screen coordinates

Methods

IsAnyButtonPressed

#
public static bool IsAnyButtonPressed(MouseButtons buttons)
Returns true if any of the specified mouse buttons is pressed.

SetCursor

#
public static void SetCursor(Cursor cursor)
Temporarily sets the current mouse pointer to the specified cursor.
Remarks: Some platforms may or may not support this in some cases, and usually the cursor gets reset when it is moved. Usually you would set the cursor using the Control.Cursor property instead.
cursor (Cursor)Cursor to set the mouse pointer to temprarily