<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSView/resetCursorRects()",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSView(im)resetCursorRects"
  },
  "title" : "resetCursorRects()"
}
-->

# resetCursorRects()

Overridden by subclasses to define their default cursor rectangles.

```
func resetCursorRects()
```

## Discussion

A subclass’s implementation must invoke [`addCursorRect(_:cursor:)`](/documentation/AppKit/NSView/addCursorRect(_:cursor:)) for each cursor rectangle it wants to establish. The default implementation does nothing.

Application code should never invoke this method directly; it’s invoked automatically as described in “[Responding to User Events and Actions](https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/CocoaViewsGuide/SubclassingNSView/SubclassingNSView.html#//apple_ref/doc/uid/TP40002978-CH7-SW26).” Use the [`invalidateCursorRects(for:)`](/documentation/AppKit/NSWindow/invalidateCursorRects(for:)) method instead to explicitly rebuild cursor rectangles.

## See Also

[`visibleRect`](/documentation/AppKit/NSView/visibleRect)

The portion of the view that isn’t clipped by its superviews.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)