Fix PathEffect rendering on some backends#5217
Conversation
The special sub-GC that is created by the PathEffectRenderer was of GraphicsContextBase, rather than the backend-specific GC. Fix matplotlib#5049, Fix matplotlib#4024
|
|
|
The docstring of |
|
@jkseppan: That's a good point. It does seem the Agg backend uses the |
|
can we hold off on that bit of refactoring until 2.1? Worried about (possibly vaporware) external backends which also rely on this. |
|
@tacaswell: Sure. That makes sense. It's not really a requirement that a renderer needs a custom GraphicsContext subclass to get things done, so it's quite possible some third-party ones don't and removing the base method would certainly break that. |
|
I agree, this PR is a minimal bugfix and changing the method in the base class is an API change. |
|
Added a test. |
There was a problem hiding this comment.
This line does not appease pep8
Fix: PathEffect rendering on some backends
Fix: PathEffect rendering on some backends
|
back-ported as ff2e4b9 |
The special sub-GC that is created by the PathEffectRenderer was of
GraphicsContextBase, rather than the backend-specific GC.
Fix #5049, Fix #4024
Note that while this fixes the crashes in #5049, it does not mean that the sketch effect behind xkcd actually works in all backends -- that's more of a feature enhancement than a bugfix, because it never worked on all backends.