From cd419918f43e8b7206d42a5299d3a3d6461a6f8a Mon Sep 17 00:00:00 2001 From: Yihui Xie Date: Thu, 21 Sep 2023 15:29:28 -0500 Subject: [PATCH] Unicode error typically means xelatex/lualatex instead of pdflatex should be used https://github.com/yihui/yihui.org/discussions/1089#discussioncomment-7074297 --- DESCRIPTION | 2 +- R/latex.R | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 8ae3dd41e..8eab2005f 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Package: tinytex Type: Package Title: Helper Functions to Install and Maintain TeX Live, and Compile LaTeX Documents -Version: 0.46.1 +Version: 0.46.2 Authors@R: c( person("Yihui", "Xie", role = c("aut", "cre", "cph"), email = "xie@yihui.name", comment = c(ORCID = "0000-0003-0645-5666")), person(given = "Posit Software, PBC", role = c("cph", "fnd")), diff --git a/R/latex.R b/R/latex.R index e26388c2a..f2269fe44 100644 --- a/R/latex.R +++ b/R/latex.R @@ -376,7 +376,7 @@ check_inline_math = function(x, f) { } check_unicode = function(x) { - if (length(grep('! Package inputenc Error: Unicode character', x))) message( + if (length(grep('! (Package inputenc|LaTeX) Error: Unicode character', x))) message( 'Try other LaTeX engines instead (e.g., xelatex) if you are using pdflatex.', if ('rmarkdown' %in% loadedNamespaces()) ' See https://bookdown.org/yihui/rmarkdown-cookbook/latex-unicode.html'