类型 ShadowStyle

API 文档由 Go 源码生成,内容为英文。

type ShadowStyle struct {
	OffsetX float32
	OffsetY float32
	Blur    float32
	Spread  float32
}

ShadowStyle is one soft drop-shadow layer, the arguments of a CSS box-shadow: the shadow is the casting rectangle moved by OffsetX and OffsetY, grown by Spread on every side (shrunk when negative), and blurred over a Blur-wide band either side of its edge.

方法

Extent#

func (style ShadowStyle) Extent() float32

Extent is how far the shadow reaches beyond the rectangle that casts it, in every direction.