pub struct Span {
pub text: String,
pub style: Style,
}Expand description
Fields§
§text: String§style: StyleImplementations§
Trait Implementations§
Source§impl Stylize for Span
Merge styles for chained calls like .red().bold().
impl Stylize for Span
Merge styles for chained calls like .red().bold().
fn style(self, style: Style) -> Span
fn fg(self, color: Color) -> Span
fn bg(self, color: Color) -> Span
fn bold(self) -> Span
fn italic(self) -> Span
fn underline(self) -> Span
fn red(self) -> Spanwhere
Self: Sized,
fn green(self) -> Spanwhere
Self: Sized,
fn blue(self) -> Spanwhere
Self: Sized,
fn cyan(self) -> Spanwhere
Self: Sized,
fn yellow(self) -> Spanwhere
Self: Sized,
fn magenta(self) -> Spanwhere
Self: Sized,
fn white(self) -> Spanwhere
Self: Sized,
fn gray(self) -> Spanwhere
Self: Sized,
fn black(self) -> Spanwhere
Self: Sized,
fn on_red(self) -> Spanwhere
Self: Sized,
fn on_green(self) -> Spanwhere
Self: Sized,
fn on_blue(self) -> Spanwhere
Self: Sized,
fn on_cyan(self) -> Spanwhere
Self: Sized,
fn on_yellow(self) -> Spanwhere
Self: Sized,
fn on_magenta(self) -> Spanwhere
Self: Sized,
fn on_white(self) -> Spanwhere
Self: Sized,
fn on_gray(self) -> Spanwhere
Self: Sized,
fn on_black(self) -> Spanwhere
Self: Sized,
fn rgb(self, r: u8, g: u8, b: u8) -> Spanwhere
Self: Sized,
fn on_rgb(self, r: u8, g: u8, b: u8) -> Spanwhere
Self: Sized,
fn hex(self, hex: &str) -> Spanwhere
Self: Sized,
fn on_hex(self, hex: &str) -> Spanwhere
Self: Sized,
Auto Trait Implementations§
impl Freeze for Span
impl RefUnwindSafe for Span
impl Send for Span
impl Sync for Span
impl Unpin for Span
impl UnsafeUnpin for Span
impl UnwindSafe for Span
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