[]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.

Methods

impl Circle

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

A new circle from center and radius.

Trait Implementations

impl Copy for Circle

impl Mul<Circle> for TranslateScale

type Output = Circle

The resulting type after applying the * operator.

impl Default for Circle

impl Debug for Circle

impl Shape for Circle

type BezPathIter = CirclePathIter

The iterator resulting from to_bez_path.

fn into_bez_path(self, tolerance: f64) -> BezPath

Convert into a Bézier path. Read more

fn as_line(&self) -> Option<Line>

If the shape is a line, make it available.

fn as_rect(&self) -> Option<Rect>

If the shape is a rectangle, make it available.

fn as_rounded_rect(&self) -> Option<RoundedRect>

If the shape is a rounded rectangle, make it available.

fn as_path_slice(&self) -> Option<&[PathEl]>

If the shape is stored as a slice of path elements, make that available. Read more

impl Clone for Circle

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

Performs copy-assignment from source. Read more

impl Add<Vec2> for Circle

type Output = Circle

The resulting type after applying the + operator.

impl Sub<Vec2> for Circle

type Output = Circle

The resulting type after applying the - operator.

Auto Trait Implementations

impl Sync for Circle

impl Send for Circle

impl Unpin for Circle

impl RefUnwindSafe for Circle

impl UnwindSafe for Circle

Blanket Implementations

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

type Owned = T

The resulting type after obtaining ownership.

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

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

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.

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

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

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

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

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