pub enum BorderType {
Square,
Ascii,
Rounded,
Double,
Heavy,
Dashed,
HeavyDashed,
Custom(BorderSet),
}Expand description
Border style presets.
Eight variants: seven named glyph sets — Square (default), Ascii,
Rounded, Double, Heavy, Dashed, HeavyDashed — plus Custom, which
accepts any BorderSet, so arbitrary corner/edge/junction glyphs are
supported without a new variant. This doc comment is the source of truth for
the “border styles” count cited in the README.
Variants§
Square
No border (but space reserved if Borders::ALL is set).
Ascii
ASCII fallback border.
Rounded
Single line border with rounded corners.
Double
Double line border.
Heavy
Heavy line border.
Dashed
Single line border with dashed edges (┄, ┆).
HeavyDashed
Heavy line border with dashed edges (┅, ┇).
Custom(BorderSet)
Custom border character set.
Implementations§
Source§impl BorderType
impl BorderType
Sourcepub const NAMED_STYLE_COUNT: usize = 7
pub const NAMED_STYLE_COUNT: usize = 7
The number of built-in named border styles (every variant except the
open-ended Custom). Cited by the README and the
border_type_variant_count_matches_readme test.
Sourcepub fn to_border_set(&self) -> BorderSet
pub fn to_border_set(&self) -> BorderSet
Convert this border type to its corresponding border character set.
Trait Implementations§
Source§impl Clone for BorderType
impl Clone for BorderType
Source§fn clone(&self) -> BorderType
fn clone(&self) -> BorderType
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for BorderType
Source§impl Debug for BorderType
impl Debug for BorderType
Source§impl Default for BorderType
impl Default for BorderType
Source§fn default() -> BorderType
fn default() -> BorderType
impl Eq for BorderType
Source§impl PartialEq for BorderType
impl PartialEq for BorderType
impl StructuralPartialEq for BorderType
Auto Trait Implementations§
impl Freeze for BorderType
impl RefUnwindSafe for BorderType
impl Send for BorderType
impl Sync for BorderType
impl Unpin for BorderType
impl UnsafeUnpin for BorderType
impl UnwindSafe for BorderType
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.