Contents

CGDisplayMoveCursorToPoint(_:_:)

Moves the mouse cursor to a specified point relative to the upper-left corner of the display.

Declaration

func CGDisplayMoveCursorToPoint(_ display: CGDirectDisplayID, _ point: CGPoint) -> CGError

Parameters

  • display:

    The identifier of the display to access.

  • point:

    The coordinates of a point in local display space. The origin is the upper-left corner of the specified display.

Return Value

A result code. To interpret the result code, see CGError.

Discussion

The function doesn’t generate events as a result of this move. The action clips points that lie outside the desktop to its bounds.

See Also

Functions