Struct graphics::circle_arc::CircleArc [] [src]

pub struct CircleArc {
    pub color: Color,
    pub radius: Radius,
    pub start: Scalar,
    pub end: Scalar,
    pub resolution: Resolution,
}

A curved line

Fields

color: Color

The arcs color

radius: Radius

The radius of the arc (Thickness of the drawing, not the radius of the circle)

start: Scalar

The start of the arc in radians

end: Scalar

The end of the arc in radians

resolution: Resolution

The resolution for the arc.

Methods

impl CircleArc
[src]

fn new(color: Color, radius: Radius, start: Scalar, end: Scalar) -> CircleArc

Creates a new arc

fn color(self, value: Color) -> Self

Sets the arcs color.

fn radius(self, value: Radius) -> Self

Sets the radius of the arc (Thickness of the arc, not the radius of the circle it wraps)

fn start(self, value: Scalar) -> Self

Sets the start of the arc (in radians).

fn end(self, value: Scalar) -> Self

Sets the end of the arc (in radians).

fn resolution(self, value: Resolution) -> Self

Sets the resolution of the arcs smoothness.

fn draw<R: Into<Rectangle>, G>(&self, rectangle: R, draw_state: &DrawState, transform: Matrix2d, g: &mut G) where G: Graphics

Draws circle arc using default method.

fn draw_tri<R: Into<Rectangle>, G>(&self, rectangle: R, draw_state: &DrawState, transform: Matrix2d, g: &mut G) where G: Graphics

Draws circle arc using triangulation.

Trait Implementations

impl Clone for CircleArc
[src]

fn clone(&self) -> CircleArc

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)
1.0.0

Performs copy-assignment from source. Read more

impl Copy for CircleArc
[src]