pub struct Border { /* private fields */ }
Expand description
Border represents a border of a Cell.
let table = Table::new(&data)
.with(Style::ascii())
.with(Modify::new(Rows::single(0)).with(Border::default().top('x')));
Implementations§
Source§impl Border
impl Border
Sourcepub fn full(
top: char,
bottom: char,
left: char,
right: char,
top_left: char,
top_right: char,
bottom_left: char,
bottom_right: char,
) -> Self
pub fn full( top: char, bottom: char, left: char, right: char, top_left: char, top_right: char, bottom_left: char, bottom_right: char, ) -> Self
This function constructs a cell borders with all sides set.
Sourcepub fn filled(c: char) -> Self
pub fn filled(c: char) -> Self
This function constructs a cell borders with all sides’s char set to a given character.
It behaives like Border::full
with the same character set to each side.
Sourcepub fn top_left_corner(self, c: char) -> Self
pub fn top_left_corner(self, c: char) -> Self
Set a top left intersection character.
Sourcepub fn top_right_corner(self, c: char) -> Self
pub fn top_right_corner(self, c: char) -> Self
Set a top right intersection character.
Sourcepub fn bottom_left_corner(self, c: char) -> Self
pub fn bottom_left_corner(self, c: char) -> Self
Set a bottom left intersection character.
Sourcepub fn bottom_right_corner(self, c: char) -> Self
pub fn bottom_right_corner(self, c: char) -> Self
Set a bottom right intersection character.
Trait Implementations§
Source§impl<R> CellOption<R> for Borderwhere
R: Records,
impl<R> CellOption<R> for Borderwhere
R: Records,
Source§fn change_cell(&mut self, table: &mut Table<R>, entity: Entity)
fn change_cell(&mut self, table: &mut Table<R>, entity: Entity)
Modification function of a single cell.
impl Eq for Border
impl StructuralPartialEq for Border
Auto Trait Implementations§
impl Freeze for Border
impl RefUnwindSafe for Border
impl Send for Border
impl Sync for Border
impl Unpin for Border
impl UnwindSafe for Border
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