aboutsummaryrefslogtreecommitdiff
path: root/data/templates
diff options
context:
space:
mode:
authorAndrew Dunning <adunning@users.noreply.github.com>2021-02-03 16:54:11 +0000
committerGitHub <noreply@github.com>2021-02-03 08:54:11 -0800
commit4de9edb8e82d14a0bd8f1e8b77e9019944c1440e (patch)
treed497a355b319d91824d4fb2bdd47fa70cd5cea47 /data/templates
parente6c7fcc59856893a4947925f0dddc3a44b74a48a (diff)
downloadpandoc-4de9edb8e82d14a0bd8f1e8b77e9019944c1440e.tar.gz
LaTeX template: Update to iftex package (#7073)
Load the iftex package directly rather than via the ifxetex and ifluatex compatibility wrappers, which have been merged into a single package that is part of the LaTeX core. The capitalization of the commands has been changed for compatibility with older versions of TeX Live that have the version of iftex by the Persian TeX Group. This had been removed in <https://github.com/jgm/pandoc/commit/2845794c0c31b2ef1f3e6a73bb5b109da4c74f37> for compatibility with BasicTeX, but that is no longer an issue.
Diffstat (limited to 'data/templates')
-rw-r--r--data/templates/default.latex22
1 files changed, 11 insertions, 11 deletions
diff --git a/data/templates/default.latex b/data/templates/default.latex
index c567278e3..c98f53bb6 100644
--- a/data/templates/default.latex
+++ b/data/templates/default.latex
@@ -98,14 +98,14 @@ $endif$
$if(linestretch)$
\usepackage{setspace}
$endif$
-\usepackage{ifxetex,ifluatex}
-\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
+\usepackage{iftex}
+\ifPDFTeX
\usepackage[$if(fontenc)$$fontenc$$else$T1$endif$]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{textcomp} % provide euro and other symbols
\else % if luatex or xetex
$if(mathspec)$
- \ifxetex
+ \ifXeTeX
\usepackage{mathspec}
\else
\usepackage{unicode-math}
@@ -129,7 +129,7 @@ $for(fontfamilies)$
$endfor$
$if(mathfont)$
$if(mathspec)$
- \ifxetex
+ \ifXeTeX
\setmathfont(Digits,Latin,Greek)[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
\else
\setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
@@ -139,18 +139,18 @@ $else$
$endif$
$endif$
$if(CJKmainfont)$
- \ifxetex
+ \ifXeTeX
\usepackage{xeCJK}
\setCJKmainfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
\fi
$endif$
$if(luatexjapresetoptions)$
- \ifluatex
+ \ifLuaTeX
\usepackage[$for(luatexjapresetoptions)$$luatexjapresetoptions$$sep$,$endfor$]{luatexja-preset}
\fi
$endif$
$if(CJKmainfont)$
- \ifluatex
+ \ifLuaTeX
\usepackage[$for(luatexjafontspecoptions)$$luatexjafontspecoptions$$sep$,$endfor$]{luatexja-fontspec}
\setmainjfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
\fi
@@ -329,7 +329,7 @@ $for(header-includes)$
$header-includes$
$endfor$
$if(lang)$
-\ifxetex
+\ifXeTeX
% Load polyglossia as late as possible: uses bidi with RTL langages (e.g. Hebrew, Arabic)
\usepackage{polyglossia}
\setmainlanguage[$for(polyglossia-lang.options)$$polyglossia-lang.options$$sep$,$endfor$]{$polyglossia-lang.name$}
@@ -346,15 +346,15 @@ $if(babel-newcommands)$
$endif$
\fi
$endif$
-\ifluatex
+\ifLuaTeX
\usepackage{selnolig} % disable illegal ligatures
\fi
$if(dir)$
-\ifxetex
+\ifXeTeX
% Load bidi as late as possible as it modifies e.g. graphicx
\usepackage{bidi}
\fi
-\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
+\ifPDFTeX
\TeXXeTstate=1
\newcommand{\RL}[1]{\beginR #1\endR}
\newcommand{\LR}[1]{\beginL #1\endL}