pub struct CornerRadii {
pub top_left: f32,
pub top_right: f32,
pub bottom_right: f32,
pub bottom_left: f32,
}Expand description
The radius of each corner of a rounded rectangle, in logical pixels.
Fields§
§top_left: f32Radius of the top-left corner, in logical pixels.
top_right: f32Radius of the top-right corner, in logical pixels.
bottom_right: f32Radius of the bottom-right corner, in logical pixels.
bottom_left: f32Radius of the bottom-left corner, in logical pixels.
Implementations§
Source§impl CornerRadii
impl CornerRadii
Sourcepub fn uniform(radius: f32) -> CornerRadii
pub fn uniform(radius: f32) -> CornerRadii
Creates radii with the same value on all four corners.
Trait Implementations§
Source§impl Clone for CornerRadii
impl Clone for CornerRadii
Source§fn clone(&self) -> CornerRadii
fn clone(&self) -> CornerRadii
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for CornerRadii
Source§impl Debug for CornerRadii
impl Debug for CornerRadii
Source§impl Default for CornerRadii
impl Default for CornerRadii
Source§fn default() -> CornerRadii
fn default() -> CornerRadii
Returns the “default value” for a type. Read more
Source§impl PartialEq for CornerRadii
impl PartialEq for CornerRadii
Source§impl RenderHash for CornerRadii
impl RenderHash for CornerRadii
Source§fn render_hash(&self) -> u64
fn render_hash(&self) -> u64
Returns a hash over exactly the values that change what is drawn. Equal values give equal
hashes.
impl StructuralPartialEq for CornerRadii
Auto Trait Implementations§
impl Freeze for CornerRadii
impl RefUnwindSafe for CornerRadii
impl Send for CornerRadii
impl Sync for CornerRadii
impl Unpin for CornerRadii
impl UnsafeUnpin for CornerRadii
impl UnwindSafe for CornerRadii
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more