
我想知道是否可以輸入一些程式碼來查找 LaTeX 在定理之前和之後留下的垂直空間(以 cm 或 pt 為單位)。
我在用著
\documentclass[12pt]{article}
和
\usepackage{amsfonts, amsthm, amsmath, amssymb}
答案1
透過重複材料得出的荒謬例子定理、定義、範例中的非斜體文本
\documentclass{article}
\usepackage{mathtools,amsthm,kantlipsum}
\newtheoremstyle{crampedthm}% <name>
{\topsep}% <Space above>
{-3pt}% <Space below>
{\itshape}% <Body font>
{3cm}% <Indent amount>
{\bfseries\itshape}% <Theorem head font>
{:}% <Punctuation after theorem head>
{.5em}% <Space after theorem headi>
{}% <Theorem head spec (can be left empty, meaning `normal')>
\theoremstyle{crampedthm}
\newtheorem{cthm}{Tight Theorem}
\begin{document}
\kant[1]
\begin{cthm}
Roses are red $\iff$ sky is blue such that it is self-evident that this
theorem is true.
\end{cthm}
\kant[1-2]
\end{document}