pub struct LogicalRange {
pub left: f32,
pub right: f32,
}Expand description
A floating-point range of bar indices on the horizontal axis.
left and right may extend beyond [0, bar_count) when the chart is
scrolled past the data edges. Use to_strict_range
to clamp to valid array indices.
Fields§
§left: f32Leftmost visible bar index (may be negative when scrolled past the start).
right: f32Rightmost visible bar index (may exceed bar_count when scrolled into the future).
Implementations§
Source§impl LogicalRange
impl LogicalRange
Trait Implementations§
Source§impl Clone for LogicalRange
impl Clone for LogicalRange
Source§fn clone(&self) -> LogicalRange
fn clone(&self) -> LogicalRange
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for LogicalRange
Source§impl Debug for LogicalRange
impl Debug for LogicalRange
Source§impl PartialEq for LogicalRange
impl PartialEq for LogicalRange
impl StructuralPartialEq for LogicalRange
Auto Trait Implementations§
impl Freeze for LogicalRange
impl RefUnwindSafe for LogicalRange
impl Send for LogicalRange
impl Sync for LogicalRange
impl Unpin for LogicalRange
impl UnsafeUnpin for LogicalRange
impl UnwindSafe for LogicalRange
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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