From 732005456e2b28150943a5a4e11bca6e1566f309 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Thu, 7 Sep 2017 22:16:23 -0700 Subject: LaTeX template: load polyglossia after header-includes. It needs to be loaded as late as possible. Closes #3898. --- data/templates/default.latex | 18 +++++++++--------- test/writers-lang-and-dir.latex | 12 ++++++------ 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/data/templates/default.latex b/data/templates/default.latex index 357549d98..d100fd4d7 100644 --- a/data/templates/default.latex +++ b/data/templates/default.latex @@ -192,6 +192,15 @@ $else$ \renewcommand{\subparagraph}[1]{\oldsubparagraph{#1}\mbox{}} \fi $endif$ + +% set default figure placement to htbp +\makeatletter +\def\fps@figure{htbp} +\makeatother + +$for(header-includes)$ +$header-includes$ +$endfor$ $if(lang)$ \ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex \usepackage[shorthands=off,$for(babel-otherlangs)$$babel-otherlangs$,$endfor$main=$babel-lang$]{babel} @@ -225,15 +234,6 @@ $if(dir)$ \fi $endif$ -% set default figure placement to htbp -\makeatletter -\def\fps@figure{htbp} -\makeatother - -$for(header-includes)$ -$header-includes$ -$endfor$ - $if(title)$ \title{$title$$if(thanks)$\thanks{$thanks$}$endif$} $endif$ diff --git a/test/writers-lang-and-dir.latex b/test/writers-lang-and-dir.latex index b8481c879..ae29cd1bb 100644 --- a/test/writers-lang-and-dir.latex +++ b/test/writers-lang-and-dir.latex @@ -44,6 +44,12 @@ \let\oldsubparagraph\subparagraph \renewcommand{\subparagraph}[1]{\oldsubparagraph{#1}\mbox{}} \fi + +% set default figure placement to htbp +\makeatletter +\def\fps@figure{htbp} +\makeatother + \ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex \usepackage[shorthands=off,ngerman,british,nswissgerman,spanish,french,main=english]{babel} \newcommand{\textgerman}[2][]{\foreignlanguage{ngerman}{#2}} @@ -77,12 +83,6 @@ \newenvironment{LTR}{\beginL}{\endL} \fi -% set default figure placement to htbp -\makeatletter -\def\fps@figure{htbp} -\makeatother - - \date{} \begin{document} -- cgit v1.2.3