| 321 | |
| 322 | |
| 323 | class AnyObjectHandler: |
| 324 | def legend_artist(self, legend, orig_handle, fontsize, handlebox): |
| 325 | x0, y0 = handlebox.xdescent, handlebox.ydescent |
| 326 | width, height = handlebox.width, handlebox.height |
| 327 | patch = mpatches.Rectangle([x0, y0], width, height, facecolor='red', |
| 328 | edgecolor='black', hatch='xx', lw=3, |
| 329 | transform=handlebox.get_transform()) |
| 330 | handlebox.add_artist(patch) |
| 331 | return patch |
| 332 | |
| 333 | fig, ax = plt.subplots() |
| 334 |
no outgoing calls
no test coverage detected
searching dependent graphs…