plushie/widget/svg

SVG display widget builder.

Types

pub opaque type Svg

Values

pub fn a11y(s: Svg, a: a11y.A11y) -> Svg

Set accessibility properties for this widget.

pub fn alt(s: Svg, a: String) -> Svg

Set the alt text for accessibility.

pub fn build(s: Svg) -> node.Node

Build the svg into a renderable Node.

pub fn color(s: Svg, c: color.Color) -> Svg

Set the color.

pub fn content_fit(s: Svg, cf: content_fit.ContentFit) -> Svg

Set how content is fitted within the widget bounds.

pub fn decorative(s: Svg, d: Bool) -> Svg

Mark as decorative (ignored by screen readers).

pub fn description(s: Svg, d: String) -> Svg

Set the description text for accessibility.

pub fn height(s: Svg, h: length.Length) -> Svg

Set the height.

pub fn new(id: String, source: String) -> Svg

Create a new svg builder.

pub fn opacity(s: Svg, o: Float) -> Svg

Set the opacity (0.0 to 1.0).

pub fn rotation(s: Svg, r: Float) -> Svg

Set the rotation angle in radians.

pub fn width(s: Svg, w: length.Length) -> Svg

Set the width.

Search Document