pub enum Shape {
Rectangle,
Rounded {
radii: CornerRadii,
},
Percent(f32),
Circle,
Path(Arc<ShapePath>),
}Expand description
A Compose-style shape.
Variants§
Rectangle
A sharp-cornered rectangle filling the bounds.
Rounded
A rectangle with independent per-corner radii, in Dp.
Fields
§
radii: CornerRadiiPercent(f32)
A rounded shape whose radius is percent / 100 of half the rect’s
smaller side (0 = sharp rectangle, 100 = same radius as Shape::Circle).
The value is clamped to 0.0..=100.0.
Circle
A circle/ellipse inscribed in the bounds (Compose’s CircleShape).
Path(Arc<ShapePath>)
An arbitrary path in Dp-local coordinates, offset to the rect origin.
Implementations§
Trait Implementations§
impl StructuralPartialEq for Shape
Auto Trait Implementations§
impl Forget for Shape
impl Freeze for Shape
impl Move for Shape
impl RefUnwindSafe for Shape
impl Send for Shape
impl Sync for Shape
impl Unpin for Shape
impl UnsafeUnpin for Shape
impl UnwindSafe for Shape
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