One Logo Pool Ball
SwiftUICore · IOS API REFERENCE

RadialGradient

struct · iOS 13.0+ · SDK 27.1

@frozen nonisolated struct RadialGradient

A radial gradient. The gradient applies the color function as the distance from a center point, scaled to fit within the defined start and end radii. The gradient maps the unit space center point into the bounding rectangle of each shape filled with the gradient. When using a radial gradient as a shape style, you can also use ``ShapeStyle/radialGradient(_:center:startRadius:endRadius:)``.

Members (3)

init · iOS 13.0+

init

TypeScript
static initStopsCenterStartRadiusEndRadius(stops: Array<Gradient_Stop>, center: UnitPoint, startRadius: number, endRadius: number): RadialGradient
Swift declaration
@export(implementation) nonisolated init(stops: [Gradient.Stop], center: UnitPoint, startRadius: CGFloat, endRadius: CGFloat)

Creates a radial gradient from a collection of color stops.

init · iOS 13.0+

init

TypeScript
static initColorsCenterStartRadiusEndRadius(colors: Array<Color>, center: UnitPoint, startRadius: number, endRadius: number): RadialGradient
Swift declaration
@export(implementation) nonisolated init(colors: [Color], center: UnitPoint, startRadius: CGFloat, endRadius: CGFloat)

Creates a radial gradient from a collection of colors.

init · iOS 13.0+

init

TypeScript
static initGradientCenterStartRadiusEndRadius(gradient: Gradient, center: UnitPoint, startRadius: number, endRadius: number): RadialGradient
Swift declaration
nonisolated init(gradient: Gradient, center: UnitPoint, startRadius: CGFloat, endRadius: CGFloat)

Creates a radial gradient from a base gradient.

Skipped declarations

No declarations were skipped in this snapshot.

All SwiftUICore types →