Divides a source rectangle into two component rectangles.
Declaration Syntax
C# | Visual Basic | Visual C++ |
public static void CGRectDivide( CGRect rect, ref CGRect slice, ref CGRect remainder, float amount, CGRectEdge edge )
Public Shared Sub CGRectDivide ( _ rect As CGRect, _ ByRef slice As CGRect, _ ByRef remainder As CGRect, _ amount As Single, _ edge As CGRectEdge _ )
public: static void CGRectDivide( CGRect rect, CGRect% slice, CGRect% remainder, float amount, CGRectEdge edge )
Parameters
- rect (CGRect)
- The source rectangle.
- slice (CGRect%)
- On input, a pointer to an uninitialized rectangle. On return, a rectangle that contains the specified edge and extends the distance beyond it specified by the amount parameter.
- remainder (CGRect%)
- On input, a pointer to an uninitialized rectangle. On return, the rectangle contains the portion of the source rectangle that remains after CGRectEdge produces the �slice� rectangle.
- amount (Single)
- A distance from the rectangle�s side that is specified in the edge parameter. This distance defines the line, parallel to the specified side, that Quartz uses to divide the source rectangle.
- edge (CGRectEdge)
- A CGRectEdge value (CGRectMinXEdge, CGRectMinYEdge, CGRectMaxXEdge, or CGRectMaxYEdge) that specifies the side of the rectangle from which the distance passed in the amount parameter is measured. CGRectDivide produces a �slice� rectangle that contains the specified edge and extends amount distance beyond it.
Return Value
Returns 1 if the two specified rectangles have equal size and origin values, or are both null. Otherwise, returns 0.
Remarks
Original declaration is : void CGRectDivide ( CGRect rect, CGRect *slice, CGRect *remainder, float amount, CGRectEdge edge );
Version Information
- Available in Monobjc Bridge: 10.6 (For Mac OS X 10.6 and later), 10.5 (For Mac OS X 10.5 and later)