1.导言区
代码如下(示例):
\documentclass{ctexart}
%\usepackage{ctex}
%导言区: \usepackage{graphicx}
%语 法: \includegraphics[<选项(图片处理)>]{<文件名>}
%格 式: EPS,PDF,PNG,TPEG,BMP
\usepackage{graphicx}
\graphicspath{{figures/}} % 图片放在当前目录下 figures 目录
%\graphicspath{{figures/},{pics/}} % 多目录
2.正文区
代码如下(示例):
\begin{document}
\LaTeX{} 中的插图:
\includegraphics{computer background.jpg}
% 图片放缩
% 缩放因子
\includegraphics[scale=0.3]{computer background.jpg}
% 固定高度
\includegraphics[height=2cm]{computer background.jpg}
% 固定宽度
\includegraphics[width=2cm]{computer background.jpg}
% 文本高度0.1倍的图像高度
\includegraphics[height=0.1\textheight]{computer background.jpg}
% 文本宽度0.2倍的图像高度
\includegraphics[width=0.2\textwidth]{computer background.jpg}
% 同时指定多个参数
\includegraphics[angle=-45,width=0.2\textwidth]{computer background.jpg}
\end{document}
pdf展示
注:可在texdoc graphicx中查看细节