Code Monkey home page Code Monkey logo

firatheme's Introduction

GitHub license GitHub license GitHub commits

Erik-Jan van Kesteren - blog -

To view the blog, go to the website.

How I made it

In the near future I will probably create a blogpost about how I made this website. Until then, have fun looking around on this repo! I generated all the files simply in RStudio using the rmarkdown functionality that is built into it.

firatheme's People

Contributors

johannesne avatar vankesteren avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

firatheme's Issues

Scanning ttf files warnings

Is there a way to suppress the warnings everytime we use theme_fira in ggplot?
It looks like these have to do with the fonts but the plot renders fine.

library(ggplot2)
#> Warning: package 'ggplot2' was built under R version 4.1.3
library(firatheme)
ggplot(mtcars, aes(x = mpg*0.43, y = wt*0.4535924, colour = factor(cyl))) +
  geom_point(size = 2) + geom_smooth(se = FALSE) +
  labs(title = "Car weight vs efficiency",
       x = "Efficiency (km/l)",
       y = "Weight (1000 kg)",
       colour = "Cylinders") +
  theme_fira() 
#> Scanning ttf files in C:/Users/cygei/R/win-library/4.1/firatheme/font ...
#> Extracting .afm files from .ttf files...
#> C:\Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-Bold.ttf
#> Warning in system2(enc2native(ttf2pt1), c(args, shQuote(ttfiles[i]),
#> shQuote(tmpfiles[i])), : running command '"C:/Users/cygei/
#> R/win-library/4.1/Rttf2pt1/exec/ttf2pt1.exe" -a -G fAe "C:
#> \Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-Bold.ttf" "C:
#> \Users\cygei\AppData\Local\Temp\RtmpaUAXf9/fonts/FiraSans-Bold"' had status 5
#>  : No FontName. Skipping.
#> C:\Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-BoldItalic.ttf
#> Warning in system2(enc2native(ttf2pt1), c(args, shQuote(ttfiles[i]),
#> shQuote(tmpfiles[i])), : running command '"C:/Users/cygei/R/win-
#> library/4.1/Rttf2pt1/exec/ttf2pt1.exe" -a -G fAe "C:\Users\cygei\R\win-
#> library\4.1\firatheme\font\FiraSans-BoldItalic.ttf" "C:
#> \Users\cygei\AppData\Local\Temp\RtmpaUAXf9/fonts/FiraSans-BoldItalic"' had
#> status 5
#>  : No FontName. Skipping.
#> C:\Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-Italic.ttf
#> Warning in system2(enc2native(ttf2pt1), c(args, shQuote(ttfiles[i]),
#> shQuote(tmpfiles[i])), : running command '"C:/Users/cygei/
#> R/win-library/4.1/Rttf2pt1/exec/ttf2pt1.exe" -a -G fAe "C:
#> \Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-Italic.ttf" "C:
#> \Users\cygei\AppData\Local\Temp\RtmpaUAXf9/fonts/FiraSans-Italic"' had status 5
#>  : No FontName. Skipping.
#> C:\Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-Medium.ttf
#> Warning in system2(enc2native(ttf2pt1), c(args, shQuote(ttfiles[i]),
#> shQuote(tmpfiles[i])), : running command '"C:/Users/cygei/
#> R/win-library/4.1/Rttf2pt1/exec/ttf2pt1.exe" -a -G fAe "C:
#> \Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-Medium.ttf" "C:
#> \Users\cygei\AppData\Local\Temp\RtmpaUAXf9/fonts/FiraSans-Medium"' had status 5
#>  : No FontName. Skipping.
#> C:\Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-MediumItalic.ttf
#> Warning in system2(enc2native(ttf2pt1), c(args, shQuote(ttfiles[i]),
#> shQuote(tmpfiles[i])), : running command '"C:/Users/cygei/R/win-
#> library/4.1/Rttf2pt1/exec/ttf2pt1.exe" -a -G fAe "C:\Users\cygei\R\win-
#> library\4.1\firatheme\font\FiraSans-MediumItalic.ttf" "C:
#> \Users\cygei\AppData\Local\Temp\RtmpaUAXf9/fonts/FiraSans-MediumItalic"' had
#> status 5
#>  : No FontName. Skipping.
#> C:\Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-Regular.ttf
#> Warning in system2(enc2native(ttf2pt1), c(args, shQuote(ttfiles[i]),
#> shQuote(tmpfiles[i])), : running command '"C:/Users/cygei/
#> R/win-library/4.1/Rttf2pt1/exec/ttf2pt1.exe" -a -G fAe "C:
#> \Users\cygei\R\win-library\4.1\firatheme\font\FiraSans-Regular.ttf" "C:
#> \Users\cygei\AppData\Local\Temp\RtmpaUAXf9/fonts/FiraSans-Regular"' had status 5
#>  : No FontName. Skipping.
#> Found FontName for 0 fonts.
#> Scanning afm files in C:/Users/cygei/R/win-library/4.1/extrafontdb/metrics
#> `geom_smooth()` using method = 'loess' and formula 'y ~ x'
#> Warning in grid.Call(C_stringMetric, as.graphicsAnnot(x$label)): font family not
#> found in Windows font database
#> Warning in grid.Call(C_stringMetric, as.graphicsAnnot(x$label)): font family not
#> found in Windows font database

#> Warning in grid.Call(C_stringMetric, as.graphicsAnnot(x$label)): font family not
#> found in Windows font database
#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database
#> Warning in grid.Call(C_stringMetric, as.graphicsAnnot(x$label)): font family not
#> found in Windows font database
#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database
#> Warning in grid.Call.graphics(C_text, as.graphicsAnnot(x$label), x$x, x$y, :
#> font family not found in Windows font database
#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

#> Warning in grid.Call(C_textBounds, as.graphicsAnnot(x$label), x$x, x$y, : font
#> family not found in Windows font database

Created on 2022-06-27 by the reprex package (v2.0.1)

Session info
sessioninfo::session_info()
#> - Session info ---------------------------------------------------------------
#>  setting  value
#>  version  R version 4.1.0 (2021-05-18)
#>  os       Windows 10 x64 (build 22000)
#>  system   x86_64, mingw32
#>  ui       RTerm
#>  language (EN)
#>  collate  English_United Kingdom.1252
#>  ctype    English_United Kingdom.1252
#>  tz       Europe/London
#>  date     2022-06-27
#>  pandoc   2.17.1.1 @ C:/Program Files/RStudio/bin/quarto/bin/ (via rmarkdown)
#> 
#> - Packages -------------------------------------------------------------------
#>  package     * version date (UTC) lib source
#>  assertthat    0.2.1   2019-03-21 [1] CRAN (R 4.1.1)
#>  cli           3.3.0   2022-04-25 [1] CRAN (R 4.1.3)
#>  colorspace    2.0-3   2022-02-21 [1] CRAN (R 4.1.3)
#>  crayon        1.5.1   2022-03-26 [1] CRAN (R 4.1.3)
#>  curl          4.3.2   2021-06-23 [1] CRAN (R 4.1.1)
#>  DBI           1.1.2   2021-12-20 [1] CRAN (R 4.1.3)
#>  digest        0.6.29  2021-12-01 [1] CRAN (R 4.1.3)
#>  dplyr         1.0.8   2022-02-08 [1] CRAN (R 4.1.3)
#>  ellipsis      0.3.2   2021-04-29 [1] CRAN (R 4.1.1)
#>  evaluate      0.15    2022-02-18 [1] CRAN (R 4.1.3)
#>  extrafont     0.18    2022-04-12 [1] CRAN (R 4.1.3)
#>  extrafontdb   1.0     2012-06-11 [1] CRAN (R 4.1.1)
#>  fansi         1.0.3   2022-03-24 [1] CRAN (R 4.1.3)
#>  farver        2.1.0   2021-02-28 [1] CRAN (R 4.1.1)
#>  fastmap       1.1.0   2021-01-25 [1] CRAN (R 4.1.1)
#>  firatheme   * 0.2.4   2022-06-27 [1] Github (vankesteren/firatheme@006d4d0)
#>  fs            1.5.2   2021-12-08 [1] CRAN (R 4.1.3)
#>  generics      0.1.2   2022-01-31 [1] CRAN (R 4.1.3)
#>  ggplot2     * 3.3.6   2022-05-03 [1] CRAN (R 4.1.3)
#>  glue          1.6.2   2022-02-24 [1] CRAN (R 4.1.3)
#>  gtable        0.3.0   2019-03-25 [1] CRAN (R 4.1.1)
#>  highr         0.9     2021-04-16 [1] CRAN (R 4.1.1)
#>  htmltools     0.5.2   2021-08-25 [1] CRAN (R 4.1.1)
#>  httr          1.4.2   2020-07-20 [1] CRAN (R 4.1.1)
#>  knitr         1.38    2022-03-25 [1] CRAN (R 4.1.3)
#>  labeling      0.4.2   2020-10-20 [1] CRAN (R 4.1.1)
#>  lattice       0.20-44 2021-05-02 [2] CRAN (R 4.1.0)
#>  lifecycle     1.0.1   2021-09-24 [1] CRAN (R 4.1.1)
#>  magrittr      2.0.3   2022-03-30 [1] CRAN (R 4.1.3)
#>  Matrix        1.3-3   2021-05-04 [2] CRAN (R 4.1.0)
#>  mgcv          1.8-35  2021-04-18 [2] CRAN (R 4.1.0)
#>  mime          0.12    2021-09-28 [1] CRAN (R 4.1.1)
#>  munsell       0.5.0   2018-06-12 [1] CRAN (R 4.1.1)
#>  nlme          3.1-152 2021-02-04 [2] CRAN (R 4.1.0)
#>  pillar        1.7.0   2022-02-01 [1] CRAN (R 4.1.3)
#>  pkgconfig     2.0.3   2019-09-22 [1] CRAN (R 4.1.1)
#>  purrr         0.3.4   2020-04-17 [1] CRAN (R 4.1.1)
#>  R.cache       0.15.0  2021-04-30 [1] CRAN (R 4.1.2)
#>  R.methodsS3   1.8.1   2020-08-26 [1] CRAN (R 4.1.1)
#>  R.oo          1.24.0  2020-08-26 [1] CRAN (R 4.1.1)
#>  R.utils       2.11.0  2021-09-26 [1] CRAN (R 4.1.2)
#>  R6            2.5.1   2021-08-19 [1] CRAN (R 4.1.1)
#>  reprex        2.0.1   2021-08-05 [1] CRAN (R 4.1.1)
#>  rlang         1.0.2   2022-03-04 [1] CRAN (R 4.1.3)
#>  rmarkdown     2.13    2022-03-10 [1] CRAN (R 4.1.3)
#>  rstudioapi    0.13    2020-11-12 [1] CRAN (R 4.1.1)
#>  Rttf2pt1      1.3.10  2022-02-07 [1] CRAN (R 4.1.2)
#>  scales        1.2.0   2022-04-13 [1] CRAN (R 4.1.3)
#>  sessioninfo   1.2.2   2021-12-06 [1] CRAN (R 4.1.3)
#>  stringi       1.7.6   2021-11-29 [1] CRAN (R 4.1.2)
#>  stringr       1.4.0   2019-02-10 [1] CRAN (R 4.1.1)
#>  styler        1.7.0   2022-03-13 [1] CRAN (R 4.1.3)
#>  tibble        3.1.7   2022-05-03 [1] CRAN (R 4.1.3)
#>  tidyselect    1.1.2   2022-02-21 [1] CRAN (R 4.1.3)
#>  utf8          1.2.2   2021-07-24 [1] CRAN (R 4.1.1)
#>  vctrs         0.4.1   2022-04-13 [1] CRAN (R 4.1.3)
#>  withr         2.5.0   2022-03-03 [1] CRAN (R 4.1.3)
#>  xfun          0.30    2022-03-02 [1] CRAN (R 4.1.3)
#>  xml2          1.3.3   2021-11-30 [1] CRAN (R 4.1.3)
#>  yaml          2.3.5   2022-02-21 [1] CRAN (R 4.1.2)
#> 
#>  [1] C:/Users/cygei/R/win-library/4.1
#>  [2] C:/Program Files/R/R-4.1.0/library
#> 
#> ------------------------------------------------------------------------------

Fira Sans font not loading

I've been receiving some notifications that firatheme does not work as intended for some users. This seems to be mainly on windows. Upon first use, the firatheme package shows the following error when loading the Fira Sans font:

Extracting .afm files from .ttf files...
C:\path\to\fonts\FiraSans-Bold.ttf : No FontName. Skipping.
C:\path\to\fonts\FiraSans-BoldItalic.ttf : No FontName. Skipping.
C:\path\to\fonts\FiraSans-Italic.ttf : No FontName. Skipping.
...
Found FontName for 0 fonts.

This is a known issue with a dependency of the extrafont package used to import the fonts. A workaround is installing a previous version of this package using the remotes package with the following code:

remotes::install_version("Rttf2pt1", version = "1.3.8")

See also the following issues:

I can't really do anything about this right now, let's hope that the dependency gets fixed at some point!

Update to R 4.x

Hi, when trying to install firatheme with a version > 4.0.0 (tried with 4.0.2 and 4.0.3) I receive the following message:

Warning in install.packages :
package ‘firatheme’ is not available for this version of R

Could you update firatheme and make it available for R >= 4.0.0?

Thank you in advance!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.