Type Method 型メソッド

color(_:red:green:blue:opacity:)

Returns a shading instance that fills with a color in the given color space.

Declaration 宣言

static func color(_ colorSpace: Color.RGBColorSpace = .sRGB, red: Double, green: Double, blue: Double, opacity: Double = 1) -> GraphicsContext.Shading

Return Value 戻り値

A shading instance filled with a color.

Parameters パラメータ

colorSpace

The RGB color space used to define the color. The default is Color.RGBColorSpace.sRGB.

red

The red component of the color.

green

The green component of the color.

blue

The blue component of the color.

opacity

The opacity of the color. The default is 1, which means fully opaque.

See Also 参照

Colors