pub struct Text {
pub lines: Vec<Line>,
}Expand description
Multi-line styled text.
Fields§
§lines: Vec<Line>Implementations§
Source§impl Text
impl Text
pub fn new(lines: impl IntoIterator<Item = Line>) -> Self
Sourcepub fn first_text(&self) -> &str
pub fn first_text(&self) -> &str
The text of the first span of the first line, or “” if empty.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Text
impl RefUnwindSafe for Text
impl Send for Text
impl Sync for Text
impl Unpin for Text
impl UnsafeUnpin for Text
impl UnwindSafe for Text
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