pub struct Metrics {
pub char_width: f32,
pub line_height: f32,
pub padding: f32,
pub min_stroke: f32,
}Expand description
How big text is, in backend units, so the layout can reserve room for labels. Labels are treated as monospaced.
Fields§
§char_width: f32Width of one character.
line_height: f32Height of one line of text.
padding: f32Gap between labels and lines.
min_stroke: f32The thinnest line or bar worth drawing (one pixel, dot or cell).
Implementations§
Trait Implementations§
impl Copy for Metrics
impl StructuralPartialEq for Metrics
Auto Trait Implementations§
impl Forget for Metrics
impl Freeze for Metrics
impl Move for Metrics
impl RefUnwindSafe for Metrics
impl Send for Metrics
impl Sync for Metrics
impl Unpin for Metrics
impl UnsafeUnpin for Metrics
impl UnwindSafe for Metrics
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