pub struct LinearScale {
pub domain: (f64, f64),
pub range: (f64, f64),
}Expand description
Maps a value domain linearly onto an output range (pixels, dots or cells).
The range may be inverted, as a y axis usually is (range: (bottom, top)).
Fields§
§domain: (f64, f64)The input interval (from, to).
range: (f64, f64)The output interval (from, to).
Implementations§
Trait Implementations§
Source§impl Clone for LinearScale
impl Clone for LinearScale
impl Copy for LinearScale
Source§impl Debug for LinearScale
impl Debug for LinearScale
Source§impl PartialEq for LinearScale
impl PartialEq for LinearScale
impl StructuralPartialEq for LinearScale
Auto Trait Implementations§
impl Forget for LinearScale
impl Freeze for LinearScale
impl Move for LinearScale
impl RefUnwindSafe for LinearScale
impl Send for LinearScale
impl Sync for LinearScale
impl Unpin for LinearScale
impl UnsafeUnpin for LinearScale
impl UnwindSafe for LinearScale
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more