![使用 bmargin 删除空格](https://linux22.com/image/391768/%E4%BD%BF%E7%94%A8%20bmargin%20%E5%88%A0%E9%99%A4%E7%A9%BA%E6%A0%BC.png)
我解释这告诉我这bmargin
就是删除文档底部和底部图形之间的空白的原因。但是,如果您运行代码,您会看到空白仍然存在,我做错了什么?
编辑:我刚刚注意到第二页已正确显示bmargin=0
。如何让第一页也能显示该信息?
EDIT2(回答评论):我使用那个特定的原因voffset
只是为了使它看起来更居中一点,理想情况下,我想控制精确的,voffset
并且bmargin
在第一页上,似乎我可以在其他每一页上做到这一点,但不能在第一页上做到这一点。
\documentclass{article}
\usepackage{graphicx}
\usepackage{subcaption}
\usepackage[margin=0pt, paperheight=830pt, voffset=60pt, bmargin=0pt]{geometry}
\pagestyle{empty}
\begin{document}
\begin{figure}[h]
\centering
\includegraphics[width=0.6\linewidth]{example-image-a}
\label{fig:my_label}
\end{figure}
\begin{figure}[h]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image-a}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image-b}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}
\begin{figure}[h]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image-a}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image-b}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}
\end{document}
编辑3:此代码是我在评论中的回答
\documentclass{article}
\usepackage{graphicx}
\usepackage{subcaption}
\usepackage[margin=0pt, paperheight=830pt, voffset=20pt, bmargin=50pt]{geometry}
\pagestyle{empty}
\begin{document}
\begin{figure}[h]
\centering
\includegraphics[width=0.5\linewidth]{example-image}
\label{fig:my_label}
\end{figure}
\begin{figure}[h]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}
\vspace*{\fill}
\begin{figure}[h]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}
\begin{figure}[h]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}
\begin{figure}[h]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}\begin{figure}[h]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}
\begin{figure}[h]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}
\end{document}
答案1
尝试这个:
\documentclass{article}
\usepackage{graphicx}
\usepackage{subcaption}
\usepackage[paperheight=830pt, margin=0pt, noheadfoot]{geometry}
\pagestyle{empty}
\makeatletter
\@fptop=0pt% distance from top of text area to first [p] figure
\@fpbot=0pt% distance from bottom of text area to last [p] figure.
\makeatother
\begin{document}
\begin{figure}[p]
\centering
\includegraphics[width=0.6\linewidth]{example-image-a}
\label{fig:my_label}
\end{figure}
\begin{figure}[p]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image-a}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image-b}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}
\begin{figure}[p]
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image-a}
\label{fig:numberthree}
\end{subfigure}
\begin{subfigure}{.5\textwidth}
\centering
\includegraphics[width=0.7\linewidth]{example-image-b}
\label{fig:numberfour}
\end{subfigure}
\label{fig:pics2}
\end{figure}
\end{document}