答案1
我知道您要的是 LaTeX。但是您的问题中没有提供任何起始 LaTeX 代码,而且我不喜欢 LaTeX。所以我向您展示了可直接由 OpTeX 处理的代码,而不是 LaTeX。但主要思想在这里清楚地显示出来,它仅基于 TeX 基元:、、、、和\baselineskip
。它们可以在您的 LaTeX 中以相同的方式使用。您可以从此代码中获得启发并将\par
其重写为 LaTeX。\vbox
\setbox
\hsize
\kern
\def
\def\shadowpar#1{\par
\bgroup
\baselineskip=20pt
\setbox0=\vbox{\hsize=15cm #1}
\setbox1=\vbox{\hsize=16cm \Red #1}
\vbox to0pt{\box0\vss}\kern5pt \box1
\egroup
}
\shadowpar{%
When a battery is supplying power, its positive terminal is the cathode
and its negative terminal is the anode.
When a battery is supplying power, its positive terminal is the cathode
and its negative terminal is the anode.
When a battery is supplying power, its positive terminal is the cathode
and its negative terminal is the anode.
When a battery is supplying power, its positive terminal is the cathode
and its negative terminal is the anode.
}
\bye