(&self, ui: &mut egui::Ui)
| 20 | |
| 21 | impl BorrowPointsExample { |
| 22 | pub fn show_plot(&self, ui: &mut egui::Ui) -> Response { |
| 23 | Plot::new("My Plot") |
| 24 | .legend(Legend::default()) |
| 25 | .show(ui, |plot_ui| { |
| 26 | plot_ui.line(Line::new("curve", PlotPoints::Borrowed(&self.points)).name("curve")); |
| 27 | }) |
| 28 | .response |
| 29 | } |
| 30 | |
| 31 | #[expect(clippy::unused_self, reason = "required by the example template")] |
| 32 | pub fn show_controls(&self, ui: &mut egui::Ui) -> Response { |