Open z3tt opened 3 months ago
Have you tried using NPC units? The code below seems to work.
## works?
p + theme(plot.caption = element_marquee(width = unit(0.5, "npc")))
Hi @aphalo, thanks for the tip! This helps quite a lot.
However it is not spanning the full plot width by setting width = unit(1, "npc")
(also makes sense as it's referring to the panel width). So in case it's possible, I think it still would be nice if the image spans the full plot width by default as the width of the axis label and the legend are influencing the width one needs to specify.
Hey Thomas,
Thanks for another awesome package! I noticed that
element_marquee()
requires a width to be specified when passing images only, which means the value must be adjusted whenever the plot width changes.Is there any chance to modify its behavior so that the width is automatically set according to the plot aspect ratio in case the user doesn’t specify a width?