#[non_exhaustive]pub struct Edges {
pub left: f32,
pub top: f32,
pub right: f32,
pub bottom: f32,
}Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.left: f32§top: f32§right: f32§bottom: f32Implementations§
Source§impl Edges
impl Edges
pub const ZERO: Self
pub const fn uniform(v: f32) -> Self
pub const fn horizontal(v: f32) -> Self
pub const fn vertical(v: f32) -> Self
pub const fn all(v: f32) -> Self
pub const fn symmetric(horizontal: f32, vertical: f32) -> Self
pub const fn xy(x: f32, y: f32) -> Self
pub const fn only(left: f32, top: f32, right: f32, bottom: f32) -> Self
pub const fn left(v: f32) -> Self
pub const fn top(v: f32) -> Self
pub const fn right(v: f32) -> Self
pub const fn bottom(v: f32) -> Self
pub fn with_left(self, v: f32) -> Self
pub fn with_top(self, v: f32) -> Self
pub fn with_right(self, v: f32) -> Self
pub fn with_bottom(self, v: f32) -> Self
pub fn with_horizontal(self, v: f32) -> Self
pub fn with_vertical(self, v: f32) -> Self
pub fn is_zero(self) -> bool
pub fn horizontal_sum(self) -> f32
pub fn vertical_sum(self) -> f32
Trait Implementations§
impl Copy for Edges
impl StructuralPartialEq for Edges
Auto Trait Implementations§
impl Freeze for Edges
impl RefUnwindSafe for Edges
impl Send for Edges
impl Sync for Edges
impl Unpin for Edges
impl UnsafeUnpin for Edges
impl UnwindSafe for Edges
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