Provide a custom formatter for the cursor overlay. Called with (x, y) world coordinates and should return the formatted string.
(mut self, provider: F)
| 139 | /// Provide a custom formatter for the cursor overlay. Called with |
| 140 | /// (x, y) world coordinates and should return the formatted string. |
| 141 | pub fn with_cursor_provider<F>(mut self, provider: F) -> Self |
| 142 | where |
| 143 | F: Fn(f64, f64) -> String + Send + Sync + 'static, |
| 144 | { |
| 145 | self.cursor_provider = Some(Arc::new(provider)); |
| 146 | self |
| 147 | } |
| 148 | |
| 149 | /// Enable or disable crosshairs that follow the cursor position. |
| 150 | pub fn with_crosshairs(mut self, enabled: bool) -> Self { |