在我的文档中,我进行了修改,\parskip
以便在段落之间留出一个很好的间隔。但这意味着\wrapfigure
计算行数时出错,并给自己留出比所需大得多的边距。
我该如何修复这个问题?我希望文本能够流入 的正下方\wrapfigure
,就像我移除调整后的效果一样\parskip
。
梅威瑟:
\documentclass{article}
\usepackage{wrapfig}
\usepackage{lipsum}
\setlength{\parskip}{1em}
\begin{document}
\lipsum[1]
\begin{wrapfigure}{r}{0.5\textwidth}
\lipsum[2]
\end{wrapfigure}
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
\lipsum[3]
\end{document}
答案1
您可以指定应该较短的行的倍数:
\documentclass{article}
\usepackage{wrapfig}
\usepackage{lipsum}
\setlength{\parskip}{1em}
\begin{document}
\lipsum[1]
\begin{wrapfigure}[9]{r}{0.5\textwidth}
\lipsum[2]
\end{wrapfigure}
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
Short paragraph
\lipsum[3]
\end{document}