Function

NSMaxX(_:)

Returns the largest x coordinate of a given rectangle.

Declaration

func NSMaxX(_ aRect: NSRect) -> CGFloat

Return Value

The largest x coordinate value within aRect.

See Also

Managing Rectangles

func NSContainsRect(NSRect, NSRect) -> Bool

Returns a Boolean value that indicates whether one rectangle completely encloses another.

func NSEqualRects(NSRect, NSRect) -> Bool

Returns a Boolean value that indicates whether the two rectangles are equal.

func NSIsEmptyRect(NSRect) -> Bool

Returns a Boolean value that indicates whether a given rectangle is empty.

func NSHeight(NSRect) -> CGFloat

Returns the height of a given rectangle.

func NSInsetRect(NSRect, CGFloat, CGFloat) -> NSRect

Insets a rectangle by a specified amount.

func NSIntegralRect(NSRect) -> NSRect

Adjusts the sides of a rectangle to integer values.

func NSIntegralRectWithOptions(NSRect, AlignmentOptions) -> NSRect

Adjusts the sides of a rectangle to integral values using the specified options.

func NSIntersectionRect(NSRect, NSRect) -> NSRect

Calculates the intersection of two rectangles.

func NSIntersectsRect(NSRect, NSRect) -> Bool

Returns a Boolean value that indicates whether two rectangles intersect.

func NSMakeRect(CGFloat, CGFloat, CGFloat, CGFloat) -> NSRect

Creates a new NSRect from the specified values.

func NSMaxY(NSRect) -> CGFloat

Returns the largest y coordinate of a given rectangle.

func NSMidX(NSRect) -> CGFloat

Returns the x coordinate of a given rectangle’s midpoint.

func NSMidY(NSRect) -> CGFloat

Returns the y coordinate of a given rectangle’s midpoint.

func NSMinX(NSRect) -> CGFloat

Returns the smallest x coordinate of a given rectangle.

func NSMinY(NSRect) -> CGFloat

Returns the smallest y coordinate of a given rectangle.

func NSMouseInRect(NSPoint, NSRect, Bool) -> Bool

Returns a Boolean value that indicates whether the point is in the specified rectangle.

func NSOffsetRect(NSRect, CGFloat, CGFloat) -> NSRect

Offsets the rectangle by the specified amount.

func NSPointInRect(NSPoint, NSRect) -> Bool

Returns a Boolean value that indicates whether a given point is in a given rectangle.

func NSRectFromString(String) -> NSRect

Returns a rectangle from a text-based representation.

func NSStringFromRect(NSRect) -> String

Returns a string representation of a rectangle.

func NSRectFromCGRect(CGRect) -> NSRect

Returns an NSRect typecast from a CGRect.

func NSRectToCGRect(NSRect) -> CGRect

Returns a CGRect typecast from an NSRect.

func NSUnionRect(NSRect, NSRect) -> NSRect

Calculates the union of two rectangles.

func NSWidth(NSRect) -> CGFloat

Returns the width of the specified rectangle.