Commit 3adaf02
committed
Change string representation of AxesImage
- The current implementation was unhelpful / incorrect: It returned
the axes bounding box: Fixes matplotlib#20294
- The string should contain helpful information. I argue that the
figure coordinates of the image are not helpful most of the time.
Instead, giving the number of pixels seems more useful. Note that
__str__ does not need to be unique.
- Also move the definition to the base class and make it
type-agnostic so that it works correctly for all derived classes.1 parent c2f39dd commit 3adaf02
File tree
2 files changed
+12
-2
lines changed- doc/api/next_api_changes/behavior
- lib/matplotlib
2 files changed
+12
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
275 | 275 | | |
276 | 276 | | |
277 | 277 | | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
278 | 285 | | |
279 | 286 | | |
280 | 287 | | |
| |||
896 | 903 | | |
897 | 904 | | |
898 | 905 | | |
899 | | - | |
900 | | - | |
901 | 906 | | |
902 | 907 | | |
903 | 908 | | |
| |||
0 commit comments