pub struct RoleStroke {
pub width: WorldPx,
pub role: Role,
}Expand description
A stroke described by a world-space width plus a Role — the app-side,
role-based counterpart to the canvas’s
PaletteStroke. The Style
adapter resolves the role to a Swatch (and hands the width through) when
forwarding to the palette-based renderer. Construct from a (width, role)
tuple, which wraps the literal width as a WorldPx; use
RoleStroke::NONE for no stroke.
Fields§
§width: WorldPx§role: RoleImplementations§
Source§impl RoleStroke
impl RoleStroke
Sourcepub const NONE: RoleStroke
pub const NONE: RoleStroke
A zero-width, transparent stroke (draws nothing).
Trait Implementations§
Source§impl Clone for RoleStroke
impl Clone for RoleStroke
Source§fn clone(&self) -> RoleStroke
fn clone(&self) -> RoleStroke
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for RoleStroke
Auto Trait Implementations§
impl Freeze for RoleStroke
impl RefUnwindSafe for RoleStroke
impl Send for RoleStroke
impl Sync for RoleStroke
impl Unpin for RoleStroke
impl UnsafeUnpin for RoleStroke
impl UnwindSafe for RoleStroke
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