图片的位置不是我想要的位置

图片的位置不是我想要的位置

这段代码,

\setlength\topmargin{0pt}
\addtolength\topmargin{-\headheight}
\addtolength\topmargin{-\headsep}
\setlength\oddsidemargin{0pt}
\setlength\textwidth{\paperwidth}
\addtolength\textwidth{-2in}
\setlength\textheight{\paperheight}
\addtolength\textheight{-2in}
\usepackage{layout}

不会干扰我的图片位置。它出现在问题上方,而不是下方。

这是我添加的代码,

\item Americans can be quite suspicious, especially when it comes to government conspiracies. On the question of whether the U.S. Air Force has withheld proof of the existence of intelligent life on other planets, the proportions of Americans with varying opinions are given in the table.\par
\begin{figure}[htp]
    \centering
    \includegraphics[width=5cm]{question13}
    %\caption{ShareLaTeX logo}
    \label{fig:question13}
\end{figure}

除了第一段代码外,我已经在另一个文档中完成了此操作。这就是发生的事情

答案1

你不需要浮点数,所以使用

\item Americans can be quite suspicious, especially when it comes to government
 conspiracies. On the question of whether the U.S. Air Force has withheld proof
of the existence of intelligent life on other planets, the proportions of Americans
with varying opinions are given in the table.
\begin{center}
    \includegraphics[width=5cm]{question13}
\end{center}

tabular尽管如果该表是图像的表示,那么使用而不是\includegraphics用 LaTeX 设置表就同样容易,并且会产生更一致的格式。

相关内容