pub fn parse_bg(
ctx: &str,
name: &str,
value: &str,
) -> Result<BgSpec, ParseError>Expand description
Parse a bg= value: a hex color, a gradient function, or an image named
with url(...). Gradient stops accept the CSS forms <color>
(auto-distributed) or <color> <offset%> (explicit). Parsed stops are
sorted by offset ascending so the renderer can hand them straight to
peniko.