pub struct TextInsets {
pub top: f32,
pub right: f32,
pub bottom: f32,
pub left: f32,
}Expand description
A length on each side of a text box, as fractions of the font size.
Written as one number for every side, the CSS shorthand of one to four numbers ("0.1 0.3":
top first, clockwise), or the sides object, missing sides 0. Pixels are refused.
Fields§
§top: f32Top side.
right: f32Right side.
bottom: f32Bottom side.
left: f32Left side.
Implementations§
Trait Implementations§
Source§impl Clone for TextInsets
impl Clone for TextInsets
impl Copy for TextInsets
Source§impl Debug for TextInsets
impl Debug for TextInsets
Source§impl Default for TextInsets
impl Default for TextInsets
Source§impl<'de> Deserialize<'de> for TextInsets
impl<'de> Deserialize<'de> for TextInsets
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for TextInsets
impl PartialEq for TextInsets
Source§impl Serialize for TextInsets
One number when every side is the same, else the sides object.
impl Serialize for TextInsets
One number when every side is the same, else the sides object.
impl StructuralPartialEq for TextInsets
Auto Trait Implementations§
impl Forget for TextInsets
impl Freeze for TextInsets
impl Move for TextInsets
impl RefUnwindSafe for TextInsets
impl Send for TextInsets
impl Sync for TextInsets
impl Unpin for TextInsets
impl UnsafeUnpin for TextInsets
impl UnwindSafe for TextInsets
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