Skip to content
This repository has been archived by the owner on Jan 1, 2023. It is now read-only.

Commit

Permalink
Update preamble.tex
Browse files Browse the repository at this point in the history
修改了\setkeys{Gin},保重cover图片格式正确。
  • Loading branch information
F. Ye authored Mar 28, 2020
1 parent 08ce77d commit 21b79bc
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions preamble.tex
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,15 @@
% Cancel common factors in Math
\usepackage[makeroom]{cancel}

\usepackage[export]{adjustbox} %Needed for max width
\usepackage{etoolbox} %Needed for \pathcmd

This comment has been minimized.

Copy link
@XiangyunHuang

XiangyunHuang Mar 28, 2020

Owner

etoolbox 已经被 Pandoc's LaTeX 内建的模版加载了,我就把它去掉了

%\patchcmd{<command>}{<code to replace>}{<code>}{<success>}{<failure>}
%The following codes add max dimension option to includegraphics
%Gin@ii is from graphicx package and looks for a second optional argument
\expandafter\patchcmd\csname Gin@ii\endcsname
{\setkeys{Gin}{#1}}
{\setkeys{Gin}{max width=\textwidth, max height=.5\textwidth,keepaspectratio,#1}}
{}
{}

\frontmatter

0 comments on commit 21b79bc

Please sign in to comment.