Szerkesztés

Megosztás a következőn keresztül:


CGRect.Union(CGRect, CGRect) Method

Definition

Gets a CGRect structure that contains the union of two CGRect structures.

public static CoreGraphics.CGRect Union (CoreGraphics.CGRect a, CoreGraphics.CGRect b);
static member Union : CoreGraphics.CGRect * CoreGraphics.CGRect -> CoreGraphics.CGRect

Parameters

a
CGRect

A rectangle to union.

b
CGRect

A rectangle to union.

Returns

A CGRect structure that bounds the union of the two CGRect structures.

Remarks

When one of the two rectangles is empty, meaning all of its values are zero, the Union(CGRect, CGRect) method returns a rectangle with a starting point of (0, 0), and the height and width of the non-empty rectangle. For example, if you have two rectangles: A = (0, 0; 0, 0) and B = (1, 1; 2, 2), then the union of A and B is (0, 0; 2, 2).

Applies to