我不知道该如何解决这个问题,希望你们中的一些人能帮助我。如所附屏幕截图所示,我横向模式下的表格与章节名称和页码(红色方块内)发生冲突。我想要的是删除表格所涵盖页面的页码/章节名称,或者移动表格,使其不与标题冲突。
谨致问候,亨利克
表格所用代码:
\begin{landscape}
\section{Rock-Eval Data}
Rock-Eval data. Any missing values in hydrogen and oxygen index is due to either negative or missing TOC values.
\begin{footnotesize}
\begin{center}
\begin{longtable}{ccccccccc}
\caption{Rock-Eval data.}\\
\toprule
\label{tab:retable}
\textbf{Level (m)} & \textbf{S$1$ (mg/g)} & \textbf{S$2$ (mg/g)} & \textbf{S$3$ (mg/g)} & \textbf{T$_{Max}$ (\degree{C})} & \textbf{PI (wt ratio)} & \textbf{Hydrogen Index (mg HC/g TOC)} & \textbf{Oxygen Index (mg HC/g TOC)} &\textbf{Powder Colour}\\
\midrule
\endfirsthead
\multicolumn{9}{c}%{\tablename\ \thetable\ -- \textit{Continued from previous page}} \\
\toprule
\textbf{Level (m)} & \textbf{S$1$ (mg/g)} & \textbf{S$2$ (mg/g)} & \textbf{S$3$ (mg/g)} & \textbf{T$_{Max}$ (\degree{C})} & \textbf{PI (wt ratio)} & \textbf{Hydrogen Index (mg HC/g TOC)} & \textbf{Oxygen Index (mg HC/g TOC)} &\textbf{Powder Colour}\\
\midrule
\endhead
\bottomrule \multicolumn{3}{r}{\textit{Continued on next page}}\\
\endfoot
\bottomrule
\endlastfoot
DATA GOES HERE
$11.75$ & $0$ & $0$ & $0.62$ & $513$ & $0$ & & & Light Grey \\
\end{longtable}
\end{center}
\end{footnotesize}
\end{landscape}
答案1
这是一个使用 的解决方案makecell
。它允许在\thead
单元格中换行并设置通用格式。注意将有助于排版单位并在表格中很好地设置数字格式。此外,据我所知,SIunitx
没有环境,只有一个开关。无论如何,您可以在 中输入表格。 footnotesize
\footnotesize
\normalsize
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{array, ltablex, caption, booktabs, makecell}
\usepackage[detect-weight]{siunitx}
\renewcommand\theadfont{\normalfont\bfseries\boldmath}
\usepackage{lscape}
\begin{document}
\begin{landscape}
\section{Rock-Eval Data}
Rock-Eval data. Any missing values in hydrogen and oxygen index is due to either negative or missing TOC values.
\begin{center}%
\begin{longtable}{ccccccccc}
\caption{Rock-Eval data.}
\label{tab:retable}\\
\toprule
\thead{Level \\(m)} & \thead{S$1$ (mg/g)} & \thead{S$2$\\ (mg/g)} & \thead{S$3$\\ (mg/g)} & \thead{$\mathbf T_\text{Max}$\\ (\si{\celsius})}
& \thead{PI\\ (wt ratio)} & \thead{Hydrogen Index\\ (mg HC/g TOC)} & \thead{Oxygen Index\\ (mg HC/g TOC)} &\thead{Powder\\ Colour}\\
\midrule
\endfirsthead
%\multicolumn{9}{c}%{\tablename\ \thetable\ -- \textit{Continued from previous page}} \\
\toprule
\thead{Level \\(m)} & \thead{S$1$ (mg/g)} & \thead{S$2$\\ (mg/g)} & \thead{S$3$\\ (mg/g)} & \thead{$T_\text{Max}$\\ (\si{\celsius})}
& \thead{PI\\ (wt ratio)} & \thead{Hydrogen Index\\ (mg HC/g TOC)} & \thead{Oxygen Index\\ (mg HC/g TOC)} &\thead{Powder\\ Colour}\\
\midrule
\endhead
\bottomrule \multicolumn{3}{r}{\textit{Continued on next page}}\\
\endfoot
\bottomrule
\endlastfoot
%%DATA GOES HERE
$11.75$ & $0$ & $0$ & $0.62$ & $513$ & $0$ & & & Light Grey \\
\end{longtable}
\end{center}
\end{landscape}
\end{document}
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{array, ltablex, caption, booktabs, makecell}
\usepackage[detect-weight]{siunitx}
\renewcommand\theadfont{\normalfont\bfseries\boldmath}
\usepackage{lscape}
\begin{document}
\begin{landscape}
\section{Rock-Eval Data}
Rock-Eval data. Any missing values in hydrogen and oxygen index is due to either negative or missing TOC values.
\begin{center}%
\begin{longtable}{ccccccccc}
\caption{Rock-Eval data.}
\label{tab:retable}\\
\toprule
\thead{Level \\(m)} & \thead{S$1$ (mg/g)} & \thead{S$2$\\ (mg/g)} & \thead{S$3$\\ (mg/g)} & \thead{$\mathbf T_\text{Max}$\\ (\si{\celsius})}
& \thead{PI\\ (wt ratio)} & \thead{Hydrogen Index\\ (mg HC/g TOC)} & \thead{Oxygen Index\\ (mg HC/g TOC)} &\thead{Powder\\ Colour}\\
\midrule
\endfirsthead
%\multicolumn{9}{c}%{\tablename\ \thetable\ -- \textit{Continued from previous page}} \\
\toprule
\thead{Level \\(m)} & \thead{S$1$ (mg/g)} & \thead{S$2$\\ (mg/g)} & \thead{S$3$\\ (mg/g)} & \thead{$T_\text{Max}$\\ (\si{\celsius})}
& \thead{PI\\ (wt ratio)} & \thead{Hydrogen Index\\ (mg HC/g TOC)} & \thead{Oxygen Index\\ (mg HC/g TOC)} &\thead{Powder\\ Colour}\\
\midrule
\endhead
\bottomrule \multicolumn{3}{r}{\textit{Continued on next page}}\\
\endfoot
\bottomrule
\endlastfoot
%%DATA GOES HERE
$11.75$ & $0$ & $0$ & $0.62$ & $513$ & $0$ & & & Light Grey \\
\end{longtable}
\end{center}
\end{landscape}
\end{document}