Skip to content

guide_coloursteps() always fits rectangles #5495

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 5 commits into from
Oct 30, 2023

Conversation

teunbrand
Copy link
Collaborator

This PR aims to fix #5481.

Briefly, when even.steps = FALSE, guide_coloursteps() used to defer to guide_colourbar()'s method of making a bar, which resulted in 300 rectangles by default. This PR gives GuideColoursteps its own build_decor() method that fits the rectangles to the breaks/limits, alleviating anti-aliasing artefacts in the case described above.

Copy link
Member

@thomasp85 thomasp85 left a comment

Choose a reason for hiding this comment

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

LGTM

@teunbrand teunbrand merged commit 0d29f25 into tidyverse:main Oct 30, 2023
@teunbrand teunbrand deleted the coloursteps_rects branch October 30, 2023 10:28
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.

Faint lines through colour steps guide segments when even.steps = FALSE
2 participants