Helper to support both standard formatters (inheriting from `.mticker.Formatter`) and axisartist-specific ones; should be called instead of directly calling ``self.tick_formatter1`` and ``self.tick_formatter2``. This method should be considered as a temporary workar
(self, idx, direction, factor, levels)
| 157 | self.set_transform(transform) |
| 158 | |
| 159 | def _format_ticks(self, idx, direction, factor, levels): |
| 160 | """ |
| 161 | Helper to support both standard formatters (inheriting from |
| 162 | `.mticker.Formatter`) and axisartist-specific ones; should be called instead of |
| 163 | directly calling ``self.tick_formatter1`` and ``self.tick_formatter2``. This |
| 164 | method should be considered as a temporary workaround which will be removed in |
| 165 | the future at the same time as axisartist-specific formatters. |
| 166 | """ |
| 167 | fmt = _api.getitem_checked( |
| 168 | {1: self.tick_formatter1, 2: self.tick_formatter2}, idx=idx) |
| 169 | return (fmt.format_ticks(levels) if isinstance(fmt, mticker.Formatter) |
| 170 | else fmt(direction, factor, levels)) |
| 171 | |
| 172 | def get_grid_info(self, *args, **kwargs): |
| 173 | """ |
no test coverage detected