pub struct Newshape<'a> { /* private fields */ }
Implementations§
Source§impl<'a> Newshape<'a>
impl<'a> Newshape<'a>
pub fn line(&mut self) -> &mut Line<'a>
Sourcepub fn fillcolor(&mut self, fillcolor: &'a str) -> &mut Self
pub fn fillcolor(&mut self, fillcolor: &'a str) -> &mut Self
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.
default: rgba(0,0,0,0)
Sourcepub fn fillrule(&mut self, fillrule: Fillrule) -> &mut Self
pub fn fillrule(&mut self, fillrule: Fillrule) -> &mut Self
Determines the path’s interior. For more info please visit https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/fill-rule
default: evenodd
Sourcepub fn opacity(&mut self, opacity: f64) -> &mut Self
pub fn opacity(&mut self, opacity: f64) -> &mut Self
Sets the opacity of new shapes.
default: 1
Sourcepub fn layer(&mut self, layer: Layer) -> &mut Self
pub fn layer(&mut self, layer: Layer) -> &mut Self
Specifies whether new shapes are drawn below or above traces.
default: above
Sourcepub fn drawdirection(&mut self, drawdirection: Drawdirection) -> &mut Self
pub fn drawdirection(&mut self, drawdirection: Drawdirection) -> &mut Self
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.
default: diagonal