-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Only one legend entry is rendered for items with the same label and color #10056
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
Comments
attn @jklymak Looks like more issues with the de-duplication logic. |
OK, I see what has happened finally. Sorry to be so slow. The de-duplication logic was only in The old What I did in #9324 was make the parsing logic the same. So the de-duplciation logic ended up in I propose we get rid of the de-duplciation logic for both versions of legend. That is a breaking API change for |
Closed #10064. Thanks for the bug report! |
I experience the same bug, or so I think with Matplotlib 3.4.3. However, it should be fixed, right? |
@HappyMeeple the original report example works fine for me, so if you have a similar error, please open a new issue with a self-contained minimal example. Thanks! |
Only one legend entry is rendered for items with the same label and color
In Matplotlib 2.1.1, items that have the same label and color result in a single legend entry. This happens even if some other properties of the items are different (eg. marker or linewidth).
This behaviour is surprising because the style of the first item is used for the handle, regardless of the style of the following items.
I would expect either the behaviour from Matplotlib 2.1.0, or the labels being merged only if the label and all style properties are equal.
Code for reproduction
Actual outcome (Matplotlib 2.1.1)
Expected outcome (Matplotlib 2.1.0)
Matplotlib version
community/python-matplotlib
.The text was updated successfully, but these errors were encountered: