-
Notifications
You must be signed in to change notification settings - Fork 2.1k
legend.key.spacing change the distance between the key and the label #6366
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
Thanks for the report! If memory serves, this was to have the margin correspond to some spacing metric of the legend. I'm not sure that there is a more natural choice than the key spacing metric, but I'll happily entertain alternatives. Note that the default margin for the legend text is In addition, for historic reasons, the |
Thanks. These functions ( In my attempts with the user-specified
|
Yeah that's right, the gap between the title and the rest of the legend is also determined by |
Suddenly I realised that the It also seems to be a result of the realisation of unity. It seems that I was misled by the |
That is not entirely how it works. The In addition, it also informs the default text margin for |
Wow, I see! |
Hi!
Currently ggplot provides identity-detailed options for adjusting the properties of each element of the legend. The following options for
legend.key.spacing{x/y}
, which adjusts the distance of each mini group, andlegend.text
both work as expected.ggplot2 3.5.0: Legends - Spacing and margins
But I have a doubt about the
legend.key.spacing
:From the result, it looks like the
key
andlabel
spacing has changed. Aslegend.text = element_text (margin = margin (l = ...))
has been changed.Should the distance between
key
andlabel
change when usinglegend.key.spacing
? I'm not quite sure if this is an intentional feature or a bug.Best wishes,
Hu
The text was updated successfully, but these errors were encountered: