Skip to content
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

Blurry text when executing vignette example on MacOS #21

Closed
markheckmann opened this issue May 31, 2024 · 1 comment
Closed

Blurry text when executing vignette example on MacOS #21

markheckmann opened this issue May 31, 2024 · 1 comment

Comments

@markheckmann
Copy link

markheckmann commented May 31, 2024

Thanks for this package! :)

When trying out the first example from the vignette (code below), the text in the image is quite blurry (in RStudio viewer as well as when saved as png). Also, I get the following warning.

> grid.draw(grob)
Warning message:
In drawDetails.GridGroup(x, recording = FALSE) : Group definition failed

I am on MacOS (see sessionInfo() below)

image

Executed code

library(marquee)
library(grid)

md_text <-
  "# Lorem Ipsum
Lorem ipsum dolor sit amet, *consectetur* adipiscing elit, sed do eiusmod tempor incididunt ut
labore et dolore magna **aliqua**. Ut enim ad minim veniam, quis nostrud exercitation ullamco
laboris nisi ut aliquip ex ea commodo _consequat_. Duis aute irure dolor in reprehenderit in
voluptate velit esse cillum dolore eu fugiat nulla ~pariatur~. Excepteur sint occaecat
cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."

grob <- marquee_grob(md_text, classic_style())

grid.draw(grob)

png(filename="dev_local/05_test_marquee/img.png")
grid.draw(grob)
dev.off()

Session Info

> sessionInfo()
R version 4.3.1 (2023-06-16)
Platform: aarch64-apple-darwin20 (64-bit)
Running under: macOS Sonoma 14.5

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib 
LAPACK: /Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/lib/libRlapack.dylib;  LAPACK version 3.11.0

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

time zone: Europe/Berlin
tzcode source: internal

attached base packages:
[1] grid      stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] marquee_0.1.0

loaded via a namespace (and not attached):
[1] compiler_4.3.1    cli_3.6.2         tools_4.3.1       rstudioapi_0.15.0 vctrs_0.6.5       textshaping_0.4.0 lifecycle_1.0.4   systemfonts_1.1.0
[9] rlang_1.1.3   
@thomasp85
Copy link
Member

The warning message is from RStudio and out of my control - it's a bug that will be solved eventually, but I agree it's annoying.

The blurriness is because of the resolution you are plotting to and outside of the control of marquee. Increase the dpi and you'll get a sharper image

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

No branches or pull requests

2 participants