Parameters ---------- fmt : str `~datetime.datetime.strftime` format string tz : str or `~datetime.tzinfo`, default: :rc:`timezone` Ticks timezone. If a string, *tz* is passed to `dateutil.tz`. usetex : bool, default: :rc:`text.usetex`
(self, fmt, tz=None, *, usetex=None)
| 569 | """ |
| 570 | |
| 571 | def __init__(self, fmt, tz=None, *, usetex=None): |
| 572 | """ |
| 573 | Parameters |
| 574 | ---------- |
| 575 | fmt : str |
| 576 | `~datetime.datetime.strftime` format string |
| 577 | tz : str or `~datetime.tzinfo`, default: :rc:`timezone` |
| 578 | Ticks timezone. If a string, *tz* is passed to `dateutil.tz`. |
| 579 | usetex : bool, default: :rc:`text.usetex` |
| 580 | To enable/disable the use of TeX's math mode for rendering the |
| 581 | results of the formatter. |
| 582 | """ |
| 583 | self.tz = _get_tzinfo(tz) |
| 584 | self.fmt = fmt |
| 585 | self._usetex = mpl._val_or_rc(usetex, 'text.usetex') |
| 586 | |
| 587 | def __call__(self, x, pos=0): |
| 588 | result = num2date(x, self.tz).strftime(self.fmt) |
nothing calls this directly
no test coverage detected