(self)
| 614 | self._update_dividers() |
| 615 | |
| 616 | def _update_dividers(self): |
| 617 | if not self.drawedges: |
| 618 | self.dividers.set_segments([]) |
| 619 | return |
| 620 | # Place all *internal* dividers. |
| 621 | if self.orientation == 'vertical': |
| 622 | lims = self.ax.get_ylim() |
| 623 | bounds = (lims[0] < self._y) & (self._y < lims[1]) |
| 624 | else: |
| 625 | lims = self.ax.get_xlim() |
| 626 | bounds = (lims[0] < self._y) & (self._y < lims[1]) |
| 627 | y = self._y[bounds] |
| 628 | # And then add outer dividers if extensions are on. |
| 629 | if self._extend_lower(): |
| 630 | y = np.insert(y, 0, lims[0]) |
| 631 | if self._extend_upper(): |
| 632 | y = np.append(y, lims[1]) |
| 633 | X, Y = np.meshgrid([0, 1], y) |
| 634 | if self.orientation == 'vertical': |
| 635 | segments = np.dstack([X, Y]) |
| 636 | else: |
| 637 | segments = np.dstack([Y, X]) |
| 638 | self.dividers.set_segments(segments) |
| 639 | |
| 640 | def _add_solids_patches(self, X, Y, C, mappable): |
| 641 | hatches = mappable.hatches * (len(C) + 1) # Have enough hatches. |
no test coverage detected