Expand description
Paint attributes: PaintStyle, the look of a box.
layout says where a box is; this says what it looks like.
It is a field of ItemStyle, so every element
takes it through the one style prop it already has, and rsx! spells it
with the shorthands bg border radius shadow custom_shadow
opacity.
Nothing here draws. The engine knows the rect of a node only after the
layout is solved, so it claims a shape slot in draw order and fills it with
what these helpers return once the frame’s layout is final. That is why the
helpers take a rect and hand back a [Shape]: the same three shapes serve
the taffy path and the lite path.
Structs§
- Paint
Style - How a box looks: background, border, corner radius, shadow and opacity.