pub struct Line<'a, B: Brush> { /* private fields */ }Expand description
Line in a text layout.
Implementations§
Source§impl<'a, B: Brush> Line<'a, B>
impl<'a, B: Brush> Line<'a, B>
Sourcepub fn metrics(&self) -> &LineMetrics
pub fn metrics(&self) -> &LineMetrics
Returns the metrics for the line.
pub fn break_reason(&self) -> BreakReason
Sourcepub fn text_range(&self) -> Range<usize>
pub fn text_range(&self) -> Range<usize>
Returns the range of text for the line.
Sourcepub fn runs(&self) -> impl Iterator<Item = Run<'a, B>> + 'a + Clone
pub fn runs(&self) -> impl Iterator<Item = Run<'a, B>> + 'a + Clone
Returns an iterator over the runs for the line.
Sourcepub fn items(
&self,
) -> impl Iterator<Item = PositionedLayoutItem<'a, B>> + 'a + Clone
pub fn items( &self, ) -> impl Iterator<Item = PositionedLayoutItem<'a, B>> + 'a + Clone
Returns an iterator over the glyph runs for the line.
Trait Implementations§
impl<'a, B: Copy + Brush> Copy for Line<'a, B>
Auto Trait Implementations§
impl<'a, B> Freeze for Line<'a, B>
impl<'a, B> !RefUnwindSafe for Line<'a, B>
impl<'a, B> Send for Line<'a, B>where
B: Sync,
impl<'a, B> Sync for Line<'a, B>where
B: Sync,
impl<'a, B> Unpin for Line<'a, B>
impl<'a, B> UnsafeUnpin for Line<'a, B>
impl<'a, B> !UnwindSafe for Line<'a, B>
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