Skip to content

Enables hatch alpha on SVG #16890

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 24, 2020
Merged

Enables hatch alpha on SVG #16890

merged 3 commits into from
Mar 24, 2020

Conversation

mnmelo
Copy link
Contributor

@mnmelo mnmelo commented Mar 23, 2020

PR Summary

Partially addresses #16883

Adds stroke-opacity to hatch, but only if it's set to anything less than 1.

Unsure if it warrants a new figure for test comparison (svgs are small, though). Alternatively, could be tested against the PNG output, which is correct now (but may miss future simultaneous breakage).

PR Checklist

  • Has Pytest style unit tests
  • Code is Flake 8 compliant
  • New features are documented, with examples if plot related
  • Documentation is sphinx and numpydoc compliant
  • Added an entry to doc/users/next_whats_new/ if major new feature (follow instructions in README.rst there)
  • Documented in doc/api/api_changes.rst if API changed in a backward-incompatible way

mnmelo added 2 commits March 23, 2020 19:22
Partially addresses matplotlib#16883 

Adds `stroke-opacity` to hatch, but only if it's set to anything less than 1.
@mnmelo
Copy link
Contributor Author

mnmelo commented Mar 23, 2020

Turns out that the test test_artist.py::test_clipping[svg] already used an image with a hatched patch, with alpha. Updated that image, and now it checks for the case in this PR too.

@anntzer anntzer added this to the v3.3.0 milestone Mar 23, 2020
Copy link
Contributor

@anntzer anntzer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if ci passes.

Copy link
Member

@tacaswell tacaswell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be worth adding a whats new entry.

👍 that we already had a test that exercised this so we don't have to add a new test :)

@mnmelo
Copy link
Contributor Author

mnmelo commented Mar 24, 2020

Hmm, this is erroring because it runs over the Azure Pipelines 60 min limit.
What's the procedure now?

Copy link
Member

@QuLogic QuLogic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you add the what's new entry and push, then there's no need to worry about the broken build.

@mnmelo
Copy link
Contributor Author

mnmelo commented Mar 24, 2020

There. Let me know if you think the what's new should read differently (there really isn't much to say other than hatch alpha now works in SVG). Perhaps noteworthy is that SVG now seems to be the only vector output backed that can do the hatch alpha (I'm not entirely sure, though).

@QuLogic
Copy link
Member

QuLogic commented Mar 24, 2020

Thanks @mnmelo!

@QuLogic QuLogic merged commit db55918 into matplotlib:master Mar 24, 2020
@mnmelo mnmelo deleted the patch-1 branch March 24, 2020 06:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants