减少顶部边距

减少顶部边距

是否可以只减少一页的上边距?我尝试使用

\vspace{-1.5em}

但它不起作用\hspace{}。有人能帮我解决这个问题吗?

答案1

我假设您的前面有一个空白行,align如以下示例所示:

在此处输入图片描述

\documentclass{article}

\usepackage{amsmath,lipsum}

\begin{document}

\lipsum[1-4]

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris sit amet rutrum 
velit, ac fermentum risus. Aliquam erat volutpat. Suspendisse tristique tempus 
turpis vitae sollicitudin. Etiam mattis quis turpis eget feugiat. Praesent at 
turpis sed nibh sodales facilisis. In fermentum scelerisque pulvinar. Quisque 
vitae ultricies tortor. Aliquam a elit ante. Donec sagittis tincidunt eros, 
eget eleifend ligula lobortis sit amet. Mauris vestibulum justo et volutpat 
tempus. Aenean luctus turpis massa, id suscipit purus blandit non.

\begin{align}% Space between paragraph and align
  f(x) &= ax^2 + bx + c \\
  ix^2 + jx + k &= g(x) \\
  f(x) &= ax^2 + bx + c \\
  ix^2 + jx + k &= g(x)
\end{align}

\lipsum[5-7]

\clearpage

\lipsum[1-4]

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris sit amet rutrum 
velit, ac fermentum risus. Aliquam erat volutpat. Suspendisse tristique tempus 
turpis vitae sollicitudin. Etiam mattis quis turpis eget feugiat. Praesent at 
turpis sed nibh sodales facilisis. In fermentum scelerisque pulvinar. Quisque 
vitae ultricies tortor. Aliquam a elit ante. Donec sagittis tincidunt eros, 
eget eleifend ligula lobortis sit amet. Mauris vestibulum justo et volutpat 
tempus. Aenean luctus turpis massa, id suscipit purus blandit non.
\begin{align}% No space between paragraph and align
  f(x) &= ax^2 + bx + c \\
  ix^2 + jx + k &= g(x) \\
  f(x) &= ax^2 + bx + c \\
  ix^2 + jx + k &= g(x)
\end{align}

\lipsum[5-7]

\end{document}

从上面的例子可以看出,如果不留空行,前面段落的最后一行就与 相关联align

如果你确实需要使用负垂直间距,请确保你处于垂直模式。如果你在页面顶部,请使用带星号的版本\vspace*

相关内容