Returns the width of a rectangle.
- iOS 2.0+
- macOS 10.0+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 2.0+
- Core Graphics
The rectangle to examine.
The width of the specified rectangle.
Regardless of whether the width is stored in the
CGRect data structure as a positive or negative number, this function returns the width as if the rectangle were standardized. That is, the result is never a negative number.