我之前问过一个问题关于列中文本上方突出的分隔线。解决方案如下:
\setlength\topskip{7pt}
效果很好,但前提是该列是文档中的第一个项目。所有后续列仍然有突出的分隔线,如下例所示
\documentclass{book}
\usepackage{paracol}
\begin{document}
\setlength{\columnsep}{1em}
\setlength{\columnseprule}{0.4pt}
\setlength\topskip{7pt}
\begin{paracol}{2}
No problem here...
\switchcolumn
Kein Problem hier...
\end{paracol}
But if it's preceeding by text
\setlength{\columnsep}{1em}
\setlength{\columnseprule}{0.4pt}
\setlength\topskip{7pt}
\begin{paracol}{2}
The divider sticks up
\switchcolumn
Dann ragt der Teiler nach oben
\end{paracol}
\vspace{1cm}
\setlength{\columnsep}{1em}
\setlength{\columnseprule}{0.4pt}
\setlength\topskip{7pt}
\begin{paracol}{2}
Same with just space
\switchcolumn
Das Gleiche gilt für den leeren Raum
\end{paracol}
\end{document}
答案1
使用 John Kormylo 的代码,创建一个调整命令(似乎是您所期望的),我们得到
\adjustment
:2pt
代码
\documentclass{book}
\usepackage{paracol}
\usepackage{tikzpagenodes}
\usetikzlibrary{tikzmark,calc}
\usepackage{blindtext}
\begin{document}
\newlength{\ajustement}
\setlength{\ajustement}{2pt}
\setlength{\columnsep}{2em}
\begin{paracol}{2}
\noindent\tikzmark{top}\indent
\blindtext[1]
\switchcolumn
\blindtext[2]
\end{paracol}
\noindent\begin{tikzpicture}[overlay,remember picture]
\draw[line width=0.4pt] ($(pic cs:top)+(0.5\textwidth, \ht\strutbox-\ajustement)$) -+
(0.5\textwidth, \ht\strutbox+\ajustement);
\end{tikzpicture}
\end{document}