r-lib / marquee

Markdown Parser and Renderer for R Graphics
https://marquee.r-lib.org
Other
82 stars 1 forks source link

Text not rendering #30

Closed RoyalTS closed 3 months ago

RoyalTS commented 3 months ago

The example from the docs

library(ggplot2)
library(marquee)
p <- ggplot(mtcars) +
  geom_point(aes(mpg, disp)) +
  labs(title = "A {.red *marquee*} title\n* Look at this bullet list\n\n* great, huh?") +
  theme_gray(base_size = 6) +
  theme(title = element_marquee())

plot(p)

Results in a plot in which the title is not rendered at all:

Screenshot 2024-06-08 at 17 01 35
thomasp85 commented 3 months ago

My guess is that it is a graphics device issue. What device and version are you using?

RoyalTS commented 3 months ago

Ah, indeed. Was using the default device in Rstudio. The whole thing works if using RAG.

That does seem to be mangling my ggplot theme's font though :|

thomasp85 commented 3 months ago

Can you please open a new issue with a reprex for that?

RoyalTS commented 3 months ago

Filed an issue here – I hope that was the right place for it.