latex longtable caption长度提前换行解决方案

1 默认的情况下是这样的,longtable生成的表格caption会按默认的长度换行。

% An illustration of longtable
\begin{longtable}{|c|c|r|r|r|r|r|r|r|l|}
\caption{True friendship and true love do sustain the tests of distance and time.真正的友谊和爱情能经受得起距离和时间的考验。Never let the demands of tomorrow interfere with the pleasures and excitement of today.永远别让明天的期待,影响你享受今天的时光。}
\label{table:label} \\ % add \\ command to tell LaTeX to start a new line
\hline
line1 & line2 & $t_1$ & $t_{12}$ & $t_2$ & $r$(\%)& $D$(GB)& $D_{nc}(GB)$&$G_t$(\%)&Station\\
\hline
% data begins here
10 & 2 & 0:22:00 & 9:46:00 & 2:00:00 & 80.49 & 159.18 & 302.25 & 89.88 & Cours Dillon \\
204 & 205 & 2:01:00 & 2:57:00 & 1:11:00 & 47.97 & 95.21 & 138.43 & 45.38 & Ayguevives Collège \\
% more data here
\hline
\end{longtable}

 

可是我们并不希望提前换行,解决方案是在导言区加

\setlength{\LTcapwidth}{\textwidth}

 

©️2020 CSDN 皮肤主题: 书香水墨 设计师:CSDN官方博客 返回首页