pub struct Layout { /* private fields */ }
Implementations§
Source§impl Layout
impl Layout
pub fn new() -> Layout
pub fn title(self, title: Title) -> Layout
pub fn show_legend(self, show_legend: bool) -> Layout
pub fn legend(self, legend: Legend) -> Layout
pub fn margin(self, margin: Margin) -> Layout
pub fn auto_size(self, auto_size: bool) -> Layout
pub fn width(self, width: usize) -> Layout
pub fn height(self, height: usize) -> Layout
pub fn font(self, font: Font) -> Layout
pub fn uniform_text(self, uniform_text: UniformText) -> Layout
pub fn separators(self, separators: &str) -> Layout
pub fn paper_background_color<C: Color>( self, paper_background_color: C, ) -> Layout
pub fn plot_background_color<C: Color>(self, plot_background_color: C) -> Layout
pub fn color_scale(self, color_scale: LayoutColorScale) -> Layout
pub fn colorway<C: Color>(self, colorway: Vec<C>) -> Layout
pub fn color_axis(self, color_axis: ColorAxis) -> Layout
pub fn mode_bar(self, mode_bar: ModeBar) -> Layout
Sourcepub fn hover_mode(self, hover_mode: HoverMode) -> Layout
pub fn hover_mode(self, hover_mode: HoverMode) -> Layout
Determines the mode of hover interactions. If “closest”, a single hoverlabel will appear for the “closest”
point within the hoverdistance
. If “x” (or “y”), multiple hoverlabels will appear for multiple points at
the “closest” x- (or y-) coordinate within the hoverdistance
, with the caveat that no more than one hoverlabel
will appear per trace. If “x unified” (or “y unified”), a single hoverlabel will appear multiple points at
the closest x- (or y-) coordinate within the hoverdistance
with the caveat that no more than one hoverlabel
will appear per trace. In this mode, spikelines are enabled by default perpendicular to the specified axis.
If false, hover interactions are disabled. If clickmode
includes the “select” flag, hovermode
defaults to
“closest”. If clickmode
lacks the “select” flag, it defaults to “x” or “y”
(depending on the trace’s orientation
value) for plots based on cartesian coordinates. For anything
else the default value is “closest”.