ztable icon indicating copy to clipboard operation
ztable copied to clipboard

ztable changes font family in Rmarkdown

Open tspeidel opened this issue 6 years ago • 0 comments

I've noticed that as soon as soon as the ztable package is loaded all the tables in my markdown documents change font from sans serif to serif. This is reproducible:

`

title: "Ztable Test" author: "some author" date: "October 18, 2017" output: html_document

knitr::opts_chunk$set(echo = TRUE)

Kable (from knitr) in markdown

cars <- cars
knitr::kable(head(cars))

` The above renders with sans serif font. Now if I load ztable:

`

title: "Ztable Test" author: "some author" date: "October 18, 2017" output: html_document

knitr::opts_chunk$set(echo = TRUE)

Kable (from knitr) in markdown

cars <- cars
knitr::kable(head(cars))

Using ztable

library(moonBook)
library(ztable)

options(ztable.type="html")
options(ztable.zebra=1)
options(ztable.zebra.color="platinum")
options(ztable.colnames.bold=TRUE)
ztable(head(cars))

`

All tables use serif fonts. How can I override this behavior? I want my fonts to remain sans serif.

tspeidel avatar Oct 18 '17 21:10 tspeidel