[−][src]Struct graphics::ellipse::Ellipse
An ellipse with filled color
Fields
color: Color
The ellipse color
border: Option<Border>
The ellipse border
resolution: Resolution
The resolution for the shape, 360 degrees.
Implementations
impl Ellipse
[src]
pub fn new(color: Color) -> Ellipse
[src]
Creates a new ellipse
pub fn new_border(color: Color, radius: Radius) -> Ellipse
[src]
Creates a new ellipse border
pub fn color(self, value: Color) -> Self
[src]
Sets ellipse color.
pub fn border(self, value: Border) -> Self
[src]
Sets ellipse border.
pub fn maybe_border(self, value: Option<Border>) -> Self
[src]
Sets optional ellipse border.
pub fn resolution(self, value: Resolution) -> Self
[src]
Sets resolution of the ellipse smoothness.
pub fn draw_from_to<P: Into<Vec2d>, G>(
&self,
from: P,
to: P,
draw_state: &DrawState,
transform: Matrix2d,
g: &mut G
) where
G: Graphics,
[src]
&self,
from: P,
to: P,
draw_state: &DrawState,
transform: Matrix2d,
g: &mut G
) where
G: Graphics,
Draws ellipse by corners using default method.
pub fn draw<R: Into<Rectangle>, G>(
&self,
rectangle: R,
draw_state: &DrawState,
transform: Matrix2d,
g: &mut G
) where
G: Graphics,
[src]
&self,
rectangle: R,
draw_state: &DrawState,
transform: Matrix2d,
g: &mut G
) where
G: Graphics,
Draws ellipse using default method.
pub fn draw_tri<R: Into<Rectangle>, G>(
&self,
rectangle: R,
draw_state: &DrawState,
transform: Matrix2d,
g: &mut G
) where
G: Graphics,
[src]
&self,
rectangle: R,
draw_state: &DrawState,
transform: Matrix2d,
g: &mut G
) where
G: Graphics,
Draws ellipse using triangulation.
Trait Implementations
impl Clone for Ellipse
[src]
impl Colored for Ellipse
[src]
fn mul_rgba(
self,
r: ColorComponent,
g: ColorComponent,
b: ColorComponent,
a: ColorComponent
) -> Self
[src]
self,
r: ColorComponent,
g: ColorComponent,
b: ColorComponent,
a: ColorComponent
) -> Self
fn hue_rad(self, angle: ColorComponent) -> Self
[src]
fn tint(self, f: ColorComponent) -> Self
[src]
fn shade(self, f: ColorComponent) -> Self
[src]
fn hue_deg(self, angle: ColorComponent) -> Self
[src]
impl Copy for Ellipse
[src]
Auto Trait Implementations
impl RefUnwindSafe for Ellipse
impl Send for Ellipse
impl Sync for Ellipse
impl Unpin for Ellipse
impl UnwindSafe for Ellipse
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,