MCPcopy Create free account
hub / github.com/donkeyteethUX/iced_plot / view_plot_area

Method view_plot_area

src/plot_widget.rs:714–744  ·  view source on GitHub ↗
(
        &'a self,
        shapes_bottom: impl Iterator<Item = Element<'a, Message>>,
        shapes_top: impl Iterator<Item = Element<'a, Message>>,
        map_plot: MapPlot,
    )

Source from the content-addressed store, hash-verified

712 };
713 let has_legend = legend.is_some();
714
715 let mut layers = Vec::new();
716 layers.push(inner_container);
717 layers.push(self.view_top_right_overlay(has_legend).map(map_plot));
718
719 if let Some(tick_labels) = self.view_tick_labels() {
720 layers.push(tick_labels.map(map_plot));
721 }
722
723 if let Some(legend) = legend {
724 layers.push(legend.map(map_plot));
725 }
726
727 let elements: Element<'a, Message> = stack(layers)
728 .width(Length::Fill)
729 .height(Length::Fill)
730 .into();
731
732 container(axes_labels::stack_with_labels(
733 elements,
734 &self.x_axis_label,
735 &self.y_axis_label,
736 self.axis_label_size,
737 style.axis_label_color,
738 ))
739 .padding(3.0)
740 .style(|theme: &Theme| self.update_style(theme).frame)
741 .into()
742 }
743
744 fn view_plot_area<'a, Message, MapPlot>(
745 &'a self,
746 shapes_bottom: impl Iterator<Item = Element<'a, Message>>,
747 shapes_top: impl Iterator<Item = Element<'a, Message>>,

Callers 1

Calls 2

mapMethod · 0.80
update_styleMethod · 0.80

Tested by

no test coverage detected