Interface

ShadowScope

Scope that can be used to define properties to render either a drop shadow or inner shadow.

Source set: Common
@JvmDefaultWithCompatibility
interface ShadowScope : Density

Scope that can be used to define properties to render either a drop shadow or inner shadow. This includes the radius, spread, color, brush, alpha, blendMode, and offset parameters.

Properties

radius

Source set: Common
var radius: Float

Blur radius of the shadow, in pixels. Defaults to 0.

spread

Source set: Common
var spread: Float

Spread parameter that adds to the size of the shadow, in pixels. Defaults to 0.

color

Source set: Common
var color: Color

Color of the shadow, Defaults to Color.Black. Attempts to provide Color.Unspecified will fallback to rendering with Color.Black. This parameter is consumed if brush is null.

brush

Source set: Common
var brush: Brush?

The brush to use for the shadow. If null, the color parameter is consumed instead

alpha

Source set: Common
var alpha: Float

Opacity of the shadow. Defaults to 1f indicating a fully opaque shadow

blendMode

Source set: Common
var blendMode: BlendMode

Blending algorithm used by the shadow. Defaults to BlendMode.SrcOver

offset

Source set: Common
var offset: Offset

Offset of the shadow. Defaults to Offset.Zero.

Last updated: