addRects(_:transform:)
Adds a set of rectangular subpaths to the path.
Declaration
mutating func addRects(_ rects: [CGRect], transform: CGAffineTransform = .identity)Discussion
Calling this convenience method is equivalent to repeatedly calling the addRect(_:transform:) method for each rectangle in the array.
Parameter:
rects: An array of rectangles, specified in user space coordinates.
transform: An affine transform to apply to the ellipse before adding to the path. Defaults to the identity transform if not specified.
See Also
Drawing a path
move(to:)addArc(center:radius:startAngle:endAngle:clockwise:transform:)addArc(tangent1End:tangent2End:radius:transform:)addCurve(to:control1:control2:)addEllipse(in:transform:)addLine(to:)addLines(_:)addPath(_:transform:)addQuadCurve(to:control:)addRect(_:transform:)addRelativeArc(center:radius:startAngle:delta:transform:)addRoundedRect(in:cornerSize:style:transform:)closeSubpath()