pub struct Padding { /* private fields */ }Expand description
A renderable that adds padding around its child.
Implementations§
Source§impl Padding
impl Padding
Sourcepub fn new(
child: impl Renderable + Send + Sync + 'static,
spec: PaddingSpec,
) -> Self
pub fn new( child: impl Renderable + Send + Sync + 'static, spec: PaddingSpec, ) -> Self
Create a new padding wrapper.
Trait Implementations§
Source§impl Renderable for Padding
impl Renderable for Padding
Auto Trait Implementations§
impl Freeze for Padding
impl !RefUnwindSafe for Padding
impl Send for Padding
impl Sync for Padding
impl Unpin for Padding
impl !UnwindSafe for Padding
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> Measurable for Twhere
T: Renderable,
impl<T> Measurable for Twhere
T: Renderable,
Source§fn measure(&self, width: usize) -> Measurement
fn measure(&self, width: usize) -> Measurement
Measure this renderable at the given width.