---
title: "mouseExited(with:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nscursor/mouseexited(with:)"
---

# mouseExited(with:)

Automatically sent to the receiver when the cursor exits a cursor rectangle owned by the receiver.

## Declaration

```swift
func mouseExited(with event: NSEvent)
```

## Parameters

- `event`: The event generated when the cursor exits the cursor rectangle.

## Discussion

Discussion Like mouseEntered(with:), this message is part of the class interface only so you can override it. For more information, see addTrackingRect(_:owner:userData:assumeInside:).

## See Also

### Deprecated

- [init(image:foregroundColorHint:backgroundColorHint:hotSpot:)](appkit/nscursor/init(image:foregroundcolorhint:backgroundcolorhint:hotspot:).md)
- [mouseEntered(with:)](appkit/nscursor/mouseentered(with:).md)
- [setOnMouseEntered(_:)](appkit/nscursor/setonmouseentered(_:).md)
- [isSetOnMouseEntered](appkit/nscursor/issetonmouseentered.md)
- [setOnMouseExited(_:)](appkit/nscursor/setonmouseexited(_:).md)
- [isSetOnMouseExited](appkit/nscursor/issetonmouseexited.md)
