rstudio / thematic

Theme ggplot2, lattice, and base graphics based on a few simple settings.
https://rstudio.github.io/thematic/
Other
244 stars 10 forks source link

Suddenly cannot set device as svg and use thematic at the same time. #104

Closed py9mrg closed 3 years ago

py9mrg commented 3 years ago

Hello,

Please see this issue that I posted over on the rmarkdown repo. I'm not sure which package is the cause so linking here.

Session Info


- Session info -------------------------------------------------------------------------------------------------------------------------------------
 setting  value                       
 version  R version 4.1.0 (2021-05-18)
 os       Windows 10 x64              
 system   x86_64, mingw32             
 ui       RStudio                     
 language (EN)                        
 collate  English_United Kingdom.1252 
 ctype    English_United Kingdom.1252 
 tz       Europe/London               
 date     2021-06-03                  

- Packages -----------------------------------------------------------------------------------------------------------------------------------------
 package     * version date       lib source                            
 assertthat    0.2.1   2019-03-21 [1] CRAN (R 4.0.0)                    
 cachem        1.0.5   2021-05-15 [1] CRAN (R 4.0.5)                    
 callr         3.7.0   2021-04-20 [1] CRAN (R 4.0.5)                    
 cellranger    1.1.0   2016-07-27 [1] CRAN (R 4.0.0)                    
 cli           2.5.0   2021-04-26 [1] CRAN (R 4.0.5)                    
 crayon        1.4.1   2021-02-08 [1] CRAN (R 4.0.3)                    
 DBI           1.1.1   2021-01-15 [1] CRAN (R 4.0.3)                    
 desc          1.3.0   2021-03-05 [1] CRAN (R 4.0.4)                    
 devtools      2.4.1   2021-05-05 [1] CRAN (R 4.0.5)                    
 digest        0.6.27  2020-10-24 [1] CRAN (R 4.0.3)                    
 dplyr         1.0.6   2021-05-05 [1] CRAN (R 4.0.5)                    
 ellipsis      0.3.2   2021-04-29 [1] CRAN (R 4.0.5)                    
 evaluate      0.14    2019-05-28 [1] CRAN (R 4.0.0)                    
 fansi         0.5.0   2021-05-25 [1] CRAN (R 4.1.0)                    
 fastmap       1.1.0   2021-01-25 [1] CRAN (R 4.0.3)                    
 fs            1.5.0   2020-07-31 [1] CRAN (R 4.0.2)                    
 generics      0.1.0   2020-10-31 [1] CRAN (R 4.0.3)                    
 glue          1.4.2   2020-08-27 [1] CRAN (R 4.0.2)                    
 htmltools     0.5.1.1 2021-01-22 [1] CRAN (R 4.0.3)                    
 janitor       2.1.0   2021-01-05 [1] CRAN (R 4.0.3)                    
 knitr         1.33    2021-04-24 [1] CRAN (R 4.0.5)                    
 lifecycle     1.0.0   2021-02-15 [1] CRAN (R 4.0.3)                    
 lubridate     1.7.10  2021-02-26 [1] CRAN (R 4.0.4)                    
 magrittr      2.0.1   2020-11-17 [1] CRAN (R 4.0.3)                    
 memoise       2.0.0   2021-01-26 [1] CRAN (R 4.0.3)                    
 pillar        1.6.1   2021-05-16 [1] CRAN (R 4.0.5)                    
 pkgbuild      1.2.0   2020-12-15 [1] CRAN (R 4.0.3)                    
 pkgconfig     2.0.3   2019-09-22 [1] CRAN (R 4.0.0)                    
 pkgload       1.2.1   2021-04-06 [1] CRAN (R 4.0.5)                    
 prettyunits   1.1.1   2020-01-24 [1] CRAN (R 4.0.0)                    
 processx      3.5.2   2021-04-30 [1] CRAN (R 4.0.5)                    
 ps            1.6.0   2021-02-28 [1] CRAN (R 4.0.4)                    
 purrr         0.3.4   2020-04-17 [1] CRAN (R 4.0.0)                    
 R6            2.5.0   2020-10-28 [1] CRAN (R 4.0.3)                    
 Rcpp          1.0.6   2021-01-15 [1] CRAN (R 4.0.3)                    
 readxl        1.3.1   2019-03-13 [1] CRAN (R 4.0.0)                    
 remotes       2.4.0   2021-06-02 [1] CRAN (R 4.1.0)                    
 rlang         0.4.11  2021-04-30 [1] CRAN (R 4.0.5)                    
 rmarkdown     2.8.6   2021-06-03 [1] Github (rstudio/rmarkdown@3480e93)
 rprojroot     2.0.2   2020-11-15 [1] CRAN (R 4.0.3)                    
 rsconnect     0.8.18  2021-05-24 [1] CRAN (R 4.1.0)                    
 rstudioapi    0.13    2020-11-12 [1] CRAN (R 4.0.3)                    
 sessioninfo   1.1.1   2018-11-05 [1] CRAN (R 4.0.0)                    
 snakecase     0.11.0  2019-05-25 [1] CRAN (R 4.0.0)                    
 stringi       1.6.2   2021-05-17 [1] CRAN (R 4.0.5)                    
 stringr       1.4.0   2019-02-10 [1] CRAN (R 4.0.0)                    
 testthat      3.0.2   2021-02-14 [1] CRAN (R 4.0.3)                    
 V thematic      0.1.2   2021-06-03 [1] Github (rstudio/thematic@be612e5) 
 tibble        3.1.2   2021-05-16 [1] CRAN (R 4.0.5)                    
 tidyselect    1.1.1   2021-04-30 [1] CRAN (R 4.0.5)                    
 usethis       2.0.1   2021-02-10 [1] CRAN (R 4.0.3)                    
 utf8          1.2.1   2021-03-12 [1] CRAN (R 4.0.4)                    
 vctrs         0.3.8   2021-04-29 [1] CRAN (R 4.0.5)                    
 withr         2.4.2   2021-04-18 [1] CRAN (R 4.0.5)                    
 xfun          0.23    2021-05-15 [1] CRAN (R 4.0.5)                    
 yaml          2.2.1   2020-02-01 [1] CRAN (R 4.0.0)   

[1] C:/Users/AAA/Documents/R/win-library/4.1
[2] C:/Program Files/R/R-4.1.0/library
cpsievert commented 3 years ago

This is probably a {showtext} on Windows bug -- do you have the latest version of {showtext} from CRAN? Also, does dev = "CairoSVG" fix the issue?

py9mrg commented 3 years ago

Hello @cpsievert - did a complete reinstall of R and the packages and it seemed to fix it. I spent a couple of hours doing reinstalls, upgrades/downgrades of the explicitly called packages and some of the dependencies like bslib - but not showtext - so you could well be right that that was the cause. Thanks for your time.

cpsievert commented 3 years ago

Ah yes, for font = "auto" you need {showtext} (or {ragg})

py9mrg commented 3 years ago

Sure, yes, I did have showtext, and it was all working fine originally - but when I came to generate this month's dashboard it kept hanging. I had the latest CRAN versions of everything (including showtext) but that was the one package I hadn't thought to try reinstalling. I guess it must have got corrupted but not enough to throw an explicit error. That's all I can think, anyway.