Struct piet_common::kurbo::Circle[]

pub struct Circle {
    pub center: Point,
    pub radius: f64,
}

A circle.

Fields

center: Point

The center.

radius: f64

The radius.

Implementations

impl Circle

pub fn new(center: impl Into<Point>, radius: f64) -> Circle

A new circle from center and radius.

pub fn segment(
    self,
    inner_radius: f64,
    start_angle: f64,
    sweep_angle: f64
) -> CircleSegment

Create a CircleSegment by cutting out parts of this circle.

pub fn is_finite(&self) -> bool

Is this circle finite?

pub fn is_nan(&self) -> bool

Is this circle NaN?

Trait Implementations

impl Add<Vec2> for Circle

type Output = Circle

The resulting type after applying the + operator.

impl Clone for Circle

impl Copy for Circle

impl Debug for Circle

impl Default for Circle

impl From<Circle> for Ellipse

impl Mul<Circle> for Affine

type Output = Ellipse

The resulting type after applying the * operator.

impl Mul<Circle> for TranslateScale

type Output = Circle

The resulting type after applying the * operator.

impl PartialEq<Circle> for Circle

impl Shape for Circle

type PathElementsIter = CirclePathIter

The iterator returned by the path_elements method. Read more

impl StructuralPartialEq for Circle

impl Sub<Vec2> for Circle

type Output = Circle

The resulting type after applying the - operator.

Auto Trait Implementations

impl RefUnwindSafe for Circle

impl Send for Circle

impl Sync for Circle

impl Unpin for Circle

impl UnwindSafe for Circle

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> RoundFrom<T> for T[src]

impl<T, U> RoundInto<U> for T where
    U: RoundFrom<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.