pub enum SpinnerPreset {
Dots,
Line,
Moon,
Bounce,
Circle,
Points,
Arc,
Toggle,
Arrow,
}Expand description
Named throbber preset for SpinnerState.
Each variant maps to a fixed frame sequence (parity with the common
cli-spinners / ratatui-throbber sets). Construct a spinner from a preset
with SpinnerState::preset, or use the matching named constructor such as
SpinnerState::moon.
§Example
let s = SpinnerState::preset(SpinnerPreset::Arrow);
assert_eq!(s, SpinnerState::arrow());Available since 0.21.1.
Variants§
Dots
Braille dots: ⠋ ⠙ ⠹ ⠸ ⠼ ⠴ ⠦ ⠧ ⠇ ⠏.
Line
ASCII line: | / - \.
Moon
Moon phases: 🌑 🌒 🌓 🌔 🌕 🌖 🌗 🌘.
Bounce
Bouncing bar between brackets: (● ) … ( ●) and back.
Circle
Quarter-circle arc: ◜ ◠ ◝ ◞ ◡ ◟.
Points
Travelling braille dot: ⠁ ⠂ ⠄ ⡀ ⢀ ⠠ ⠐ ⠈.
Arc
Half-circle arc: ◜ ◠ ◝ ◞ ◡ ◟.
Toggle
Toggle pulse: ⊶ ⊷.
Arrow
Clockwise arrow: ← ↖ ↑ ↗ → ↘ ↓ ↙.
Trait Implementations§
Source§impl Clone for SpinnerPreset
impl Clone for SpinnerPreset
Source§fn clone(&self) -> SpinnerPreset
fn clone(&self) -> SpinnerPreset
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for SpinnerPreset
Source§impl Debug for SpinnerPreset
impl Debug for SpinnerPreset
impl Eq for SpinnerPreset
Source§impl Hash for SpinnerPreset
impl Hash for SpinnerPreset
Source§impl PartialEq for SpinnerPreset
impl PartialEq for SpinnerPreset
Source§fn eq(&self, other: &SpinnerPreset) -> bool
fn eq(&self, other: &SpinnerPreset) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for SpinnerPreset
Auto Trait Implementations§
impl Freeze for SpinnerPreset
impl RefUnwindSafe for SpinnerPreset
impl Send for SpinnerPreset
impl Sync for SpinnerPreset
impl Unpin for SpinnerPreset
impl UnsafeUnpin for SpinnerPreset
impl UnwindSafe for SpinnerPreset
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§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.