pub struct BoxPad {
pub top: usize,
pub down: usize,
pub left: usize,
pub right: usize,
}Expand description
Padding Struct for the TextBox
Fields§
§top: usize§down: usize§left: usize§right: usizeImplementations§
Source§impl BoxPad
impl BoxPad
pub fn new() -> Self
Sourcepub fn from_tldr(top: usize, left: usize, down: usize, right: usize) -> Self
pub fn from_tldr(top: usize, left: usize, down: usize, right: usize) -> Self
Creates a new BoxPad Struct with the given padding values in order: top, left, down, right (tldr)
Sourcepub fn uniform(pad: usize) -> Self
pub fn uniform(pad: usize) -> Self
Creates a new BoxPad Struct with uniform padding values on all sides
Trait Implementations§
Auto Trait Implementations§
impl Freeze for BoxPad
impl RefUnwindSafe for BoxPad
impl Send for BoxPad
impl Sync for BoxPad
impl Unpin for BoxPad
impl UnwindSafe for BoxPad
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