pub struct Rectangle {
pub x: f32,
pub y: f32,
pub w: f32,
pub h: f32,
pub style: Style,
pub border_radius: f32,
}
Expand description
<rect x="{x}" y="{y}" width="{w}" height="{h}" ... />
,
Fields§
§x: f32
§y: f32
§w: f32
§h: f32
§style: Style
§border_radius: f32
Implementations§
source§impl Rectangle
impl Rectangle
pub fn fill<F>(self, fill: F) -> Self
pub fn stroke<S>(self, stroke: S) -> Self
pub fn opacity(self, opacity: f32) -> Self
pub fn stroke_opacity(self, opacity: f32) -> Self
pub fn style(self, style: Style) -> Self
pub fn border_radius(self, r: f32) -> Self
pub fn offset(self, dx: f32, dy: f32) -> Self
pub fn inflate(self, dx: f32, dy: f32) -> Self
Trait Implementations§
source§impl PartialEq for Rectangle
impl PartialEq for Rectangle
impl Copy for Rectangle
impl StructuralPartialEq for Rectangle
Auto Trait Implementations§
impl RefUnwindSafe for Rectangle
impl Send for Rectangle
impl Sync for Rectangle
impl Unpin for Rectangle
impl UnwindSafe for Rectangle
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