Skip to content

Prevent dropping data when drawing legend #4574

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 2 commits into from
Aug 4, 2021

Conversation

teunbrand
Copy link
Collaborator

There is a very niche bug in the legend drawing code that only affects plotting when the extracted layer data contains a single column. I ran into this bug when I was experimenting with a geom that has a fill aesthetic but not an alpha aesthetic.

@clauswilke
Copy link
Member

Thanks! It's so frustrating that drop = FALSE isn't the default.

@clauswilke clauswilke merged commit cabb746 into tidyverse:master Aug 4, 2021
@teunbrand
Copy link
Collaborator Author

Agreed! If/when ggplot2 switches to {vctrs}, the vec_slice() function would be great here.

@teunbrand teunbrand deleted the drop_legend_key branch August 6, 2021 08:59
thomasp85 added a commit that referenced this pull request Apr 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants