Return this Axis' grid lines as a list of `.Line2D`. .. warning:: Ticks and their constituent parts, including grid lines, are not persistent. Various operations can create, delete, and modify the tick instances; see :ref:`axes-tick-objects`.
(self)
| 1492 | self.stale = False |
| 1493 | |
| 1494 | def get_gridlines(self): |
| 1495 | """ |
| 1496 | Return this Axis' grid lines as a list of `.Line2D`. |
| 1497 | |
| 1498 | .. warning:: |
| 1499 | |
| 1500 | Ticks and their constituent parts, including grid lines, are not |
| 1501 | persistent. Various operations can create, delete, and modify the tick |
| 1502 | instances; see :ref:`axes-tick-objects`. |
| 1503 | |
| 1504 | You should generally use `.Axis.set_tick_params` / `.Axis.get_tick_params` |
| 1505 | to define and query grid styling; see :ref:`axes-ticks-styling`. |
| 1506 | """ |
| 1507 | ticks = self.get_major_ticks() |
| 1508 | return cbook.silent_list('Line2D gridline', |
| 1509 | [tick.gridline for tick in ticks]) |
| 1510 | |
| 1511 | def set_label(self, s): |
| 1512 | """Assigning legend labels is not supported. Raises RuntimeError.""" |
no test coverage detected