pub struct LinearGradient {
pub start: (f64, f64),
pub end: (f64, f64),
pub stops: Vec<GradientStop>,
}Expand description
A linear colour gradient.
Fields§
§start: (f64, f64)The start point, in chart coordinates.
end: (f64, f64)The end point, in chart coordinates.
stops: Vec<GradientStop>The colour stops, ordered by offset.
Implementations§
Source§impl LinearGradient
Inherent implementation of LinearGradient.
impl LinearGradient
Inherent implementation of LinearGradient.
Source§impl LinearGradient
impl LinearGradient
pub fn get_start(&self) -> &(f64, f64)
pub fn get_mut_start(&mut self) -> &mut (f64, f64)
pub fn set_start(&mut self, val: (f64, f64)) -> &mut Self
pub fn get_end(&self) -> &(f64, f64)
pub fn get_mut_end(&mut self) -> &mut (f64, f64)
pub fn set_end(&mut self, val: (f64, f64)) -> &mut Self
pub fn get_stops(&self) -> &Vec<GradientStop>
pub fn get_mut_stops(&mut self) -> &mut Vec<GradientStop>
pub fn set_stops(&mut self, val: Vec<GradientStop>) -> &mut Self
Trait Implementations§
Source§impl Clone for LinearGradient
impl Clone for LinearGradient
Source§impl Debug for LinearGradient
impl Debug for LinearGradient
Source§impl PartialEq for LinearGradient
impl PartialEq for LinearGradient
impl StructuralPartialEq for LinearGradient
Auto Trait Implementations§
impl Freeze for LinearGradient
impl RefUnwindSafe for LinearGradient
impl Send for LinearGradient
impl Sync for LinearGradient
impl Unpin for LinearGradient
impl UnsafeUnpin for LinearGradient
impl UnwindSafe for LinearGradient
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more