Provide a custom highlighter for hovered point. If not provided, a default hover highlight provider will be used that shows the tooltip text with series label, x and y coordinates of the point ([`PlotWidgetBuilder::default_hover_highlight_provider`]).
(mut self, provider: F)
| 122 | /// If not provided, a default hover highlight provider will be used that shows the tooltip text with |
| 123 | /// series label, x and y coordinates of the point ([`PlotWidgetBuilder::default_hover_highlight_provider`]). |
| 124 | pub fn with_hover_highlight_provider<F>(mut self, provider: F) -> Self |
| 125 | where |
| 126 | F: Fn(TooltipContext<'_>, &mut HighlightPoint) -> Option<String> + Send + Sync + 'static, |
| 127 | { |
| 128 | self.hover_highlight_provider = Some(Arc::new(provider)); |
| 129 | self |
| 130 | } |
| 131 | |
| 132 | /// Enable or disable the small cursor position overlay shown in the |
| 133 | /// lower-left corner of the plot. By default it's disabled when not set. |