Trait lyon_path_builder::SvgBuilder [] [src]

pub trait SvgBuilder: PathBuilder {
    fn relative_move_to(&mut self, to: Vec2);
    fn relative_line_to(&mut self, to: Vec2);
    fn relative_quadratic_bezier_to(&mut self, ctrl: Vec2, to: Vec2);
    fn relative_cubic_bezier_to(&mut self, ctrl1: Vec2, ctrl2: Vec2, to: Vec2);
    fn cubic_bezier_smooth_to(&mut self, ctrl2: Point, to: Point);
    fn relative_cubic_bezier_smooth_to(&mut self, ctrl2: Vec2, to: Vec2);
    fn quadratic_bezier_smooth_to(&mut self, to: Point);
    fn relative_quadratic_bezier_smooth_to(&mut self, to: Vec2);
    fn horizontal_line_to(&mut self, x: f32);
    fn relative_horizontal_line_to(&mut self, dx: f32);
    fn vertical_line_to(&mut self, y: f32);
    fn relative_vertical_line_to(&mut self, dy: f32);
    fn arc_to(&mut self, to: Point, radii: Vec2, x_rotation: f32, flags: ArcFlags);
    fn relative_arc_to(&mut self, to: Vec2, radii: Vec2, x_rotation: f32, flags: ArcFlags);

    fn svg_event(&mut self, event: SvgEvent) { ... }
}

A path building interface that tries to stay close to SVG's path specification. https://svgwg.org/specs/paths/

Required Methods

fn relative_move_to(&mut self, to: Vec2)

fn relative_line_to(&mut self, to: Vec2)

fn relative_quadratic_bezier_to(&mut self, ctrl: Vec2, to: Vec2)

fn relative_cubic_bezier_to(&mut self, ctrl1: Vec2, ctrl2: Vec2, to: Vec2)

fn cubic_bezier_smooth_to(&mut self, ctrl2: Point, to: Point)

fn relative_cubic_bezier_smooth_to(&mut self, ctrl2: Vec2, to: Vec2)

fn quadratic_bezier_smooth_to(&mut self, to: Point)

fn relative_quadratic_bezier_smooth_to(&mut self, to: Vec2)

fn horizontal_line_to(&mut self, x: f32)

fn relative_horizontal_line_to(&mut self, dx: f32)

fn vertical_line_to(&mut self, y: f32)

fn relative_vertical_line_to(&mut self, dy: f32)

fn arc_to(&mut self, to: Point, radii: Vec2, x_rotation: f32, flags: ArcFlags)

fn relative_arc_to(&mut self, to: Vec2, radii: Vec2, x_rotation: f32, flags: ArcFlags)

Provided Methods

fn svg_event(&mut self, event: SvgEvent)

Implementors