pub struct NewShape { /* private fields */ }Implementations§
Source§impl NewShape
impl NewShape
Sourcepub fn line(self, value: ShapeLine) -> NewShape
pub fn line(self, value: ShapeLine) -> NewShape
Sets the shape line properties (color, width, dash).
Sourcepub fn fill_color(self, value: impl Color) -> NewShape
pub fn fill_color(self, value: impl Color) -> NewShape
Sets the color filling new shapes’ interior. Please note that if using a fillcolor with alpha greater than half, drag inside the active shape starts moving the shape underneath, otherwise a new shape could be started over.
Sourcepub fn fill_rule(self, value: FillRule) -> NewShape
pub fn fill_rule(self, value: FillRule) -> NewShape
Determines the path’s interior. For more info please visit https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/fill-rule
Sourcepub fn opacity(self, value: f64) -> NewShape
pub fn opacity(self, value: f64) -> NewShape
Sets the opacity of new shapes. Number between or equal to 0 and 1.
Sourcepub fn layer(self, value: ShapeLayer) -> NewShape
pub fn layer(self, value: ShapeLayer) -> NewShape
Specifies whether new shapes are drawn below or above traces.
Sourcepub fn draw_direction(self, value: DrawDirection) -> NewShape
pub fn draw_direction(self, value: DrawDirection) -> NewShape
When dragmode is set to “drawrect”, “drawline” or “drawcircle” this
limits the drag to be horizontal, vertical or diagonal. Using
“diagonal” there is no limit e.g. in drawing lines in any direction.
“ortho” limits the draw to be either horizontal or vertical.
“horizontal” allows horizontal extend. “vertical” allows vertical
extend.