pub enum ModuleShape {
Square,
RoundedSquare {
radius: f32,
},
Circle,
Diamond,
}Expand description
Shape of individual data modules (the small squares/dots).
Used in QrStyle::module_shape. The default is
ModuleShape::RoundedSquare with radius: 0.3.
Variants§
Square
Classic sharp-edged square.
RoundedSquare
Square with rounded corners. radius is a fraction of module
size in the range 0.0..=0.5; values outside this range are
clamped at render time.
Fields
Circle
Circular dot.
Diamond
45-degree rotated square (diamond).
Trait Implementations§
Source§impl Clone for ModuleShape
impl Clone for ModuleShape
Source§fn clone(&self) -> ModuleShape
fn clone(&self) -> ModuleShape
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 moreSource§impl Debug for ModuleShape
impl Debug for ModuleShape
Source§impl PartialEq for ModuleShape
impl PartialEq for ModuleShape
impl StructuralPartialEq for ModuleShape
Auto Trait Implementations§
impl Freeze for ModuleShape
impl RefUnwindSafe for ModuleShape
impl Send for ModuleShape
impl Sync for ModuleShape
impl Unpin for ModuleShape
impl UnsafeUnpin for ModuleShape
impl UnwindSafe for ModuleShape
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