pub struct Emoji<'a, 'b>(pub &'a str, pub &'b str);
Expand description
“Intelligent” emoji formatter.
This struct intelligently wraps an emoji so that it is rendered only on systems that want emojis and renders a fallback on others.
Example:
use console::Emoji;
println!("[3/4] {}Downloading ...", Emoji("🚚 ", ""));
println!("[4/4] {} Done!", Emoji("✨", ":-)"));
Tuple Fields§
§0: &'a str
§1: &'b str
Implementations§
Trait Implementations§
impl<'a, 'b> Copy for Emoji<'a, 'b>
Auto Trait Implementations§
impl<'a, 'b> Freeze for Emoji<'a, 'b>
impl<'a, 'b> RefUnwindSafe for Emoji<'a, 'b>
impl<'a, 'b> Send for Emoji<'a, 'b>
impl<'a, 'b> Sync for Emoji<'a, 'b>
impl<'a, 'b> Unpin for Emoji<'a, 'b>
impl<'a, 'b> UnwindSafe for Emoji<'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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)