From e91af0a8a32d68af4c533fdf4b7caaafade577ef Mon Sep 17 00:00:00 2001 From: Andrew Dunning Date: Sat, 23 Mar 2019 00:35:55 -0400 Subject: LaTeX template: Group graphics-related code (#5389) * LaTeX template: Group graphics-related code The default figure placement was added in ; there does not appear to have been a reason for placing it at the end of the preamble. * Update tests --- data/templates/default.latex | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'data') diff --git a/data/templates/default.latex b/data/templates/default.latex index 8cd64b866..11726c0e3 100644 --- a/data/templates/default.latex +++ b/data/templates/default.latex @@ -1,5 +1,5 @@ % Options for packages loaded elsewhere -\PassOptionsToPackage{unicode=true$for(hyperrefoptions)$,$hyperrefoptions$$endfor$}{hyperref} +\PassOptionsToPackage{unicode$for(hyperrefoptions)$,$hyperrefoptions$$endfor$}{hyperref} \PassOptionsToPackage{hyphens}{url} $if(colorlinks)$ \PassOptionsToPackage{dvipsnames,svgnames*,x11names*}{xcolor} @@ -100,7 +100,7 @@ $endif$ \usepackage[$if(fontenc)$$fontenc$$else$T1$endif$]{fontenc} \usepackage[utf8]{inputenc} \usepackage{textcomp} % provides euro and other symbols -\else % if luatex or xelatex +\else % if luatex or xetex $if(mathspec)$ \ifxetex \usepackage{mathspec} @@ -267,6 +267,10 @@ $if(graphics)$ % margins by default, and it is still possible to overwrite the defaults % using explicit options in \includegraphics[width, height, ...]{} \setkeys{Gin}{width=\maxwidth,height=\maxheight,keepaspectratio} +% Set default figure placement to htbp +\makeatletter +\def\fps@figure{htbp} +\makeatother $endif$ $if(links-as-notes)$ % Make links footnotes instead of hotlinks: @@ -304,11 +308,6 @@ $if(pagestyle)$ \pagestyle{$pagestyle$} $endif$ -% Set default figure placement to htbp -\makeatletter -\def\fps@figure{htbp} -\makeatother - $for(header-includes)$ $header-includes$ $endfor$ -- cgit v1.2.3