pub struct RichTextLayout {
pub lines: Vec<RichTextLine>,
pub max_width: f32,
pub line_height: f32,
pub max_ascent: f32,
}Expand description
Word-wrapped layout for a RichText, shared by
crate::intrinsic::RichTextIntrinsic and the painter so the box taffy
reserves always matches what gets drawn.
Fields§
§lines: Vec<RichTextLine>§max_width: f32§line_height: f32§max_ascent: f32Auto Trait Implementations§
impl Freeze for RichTextLayout
impl RefUnwindSafe for RichTextLayout
impl Send for RichTextLayout
impl Sync for RichTextLayout
impl Unpin for RichTextLayout
impl UnsafeUnpin for RichTextLayout
impl UnwindSafe for RichTextLayout
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> 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