Marks the receiver’s entire bounds rectangle as needing to be redrawn.
- iOS 2.0+
- Mac Catalyst 13.0+
- tvOS 9.0+
You can use this method or the
set to notify the system that your view’s contents need to be redrawn. This method makes a note of the request and returns immediately. The view is not actually redrawn until the next drawing cycle, at which point all invalidated views are updated.
You should use this method to request that a view be redrawn only when the content or appearance of the view change. If you simply change the geometry of the view, the view is typically not redrawn. Instead, its existing content is adjusted based on the value in the view’s
content property. Redisplaying the existing content improves performance by avoiding the need to redraw content that has not changed.