如何让这张桌子更漂亮

如何让这张桌子更漂亮

我现在的桌子不太好看。空间太小了。如何让这张桌子变得更好看?

\documentclass{article}
\usepackage{comment}
\usepackage{mathtools} % for \smashoperator macro
\newcommand\tbc{{\textstyle\bigcup}} % handy shortcut macro
%\usepackage[table]{xcolor}

\usepackage{nicematrix}


\begin{document}

\begin{table}[!ht]
\centering
\caption{Semantic models of the OCCR model}
\scriptsize
\begin{tabular}{|m{2.5cm}<{\centering}|m{1.6cm}<{\centering}|m{8cm}<{\centering}|}
\hline
\textbf{Models}& \textbf{Symbol} & \textbf{Description}  
\\
\hline 
Reconfiguration& AS & Asset information in the manufacturing domain, such as hardware (equipment and tooling), software, the human workforce, and enabling technologies for achieving reconfiguration. 

\\ 
\hline Capacity model& CM &   A structured representation of manufacturing KPIs that monitor the performance state on the shop floor focusing on the reconfiguration. 
\\ 
\hline

\end{tabular}
\label{table:semantic models of OCCR model}
\end{table}

\end{document}

在此处输入图片描述

答案1

你问如何让桌子更漂亮。所以

  1. 删除所有没用的垂直规则;
  2. 使用顶部对齐,不需要垂直居中条目;
  3. 用垂直空间代替中间的规则;
  4. 使用tabularx来填充文本宽度,而不必担心计算宽度。
\documentclass{article}
\usepackage{caption}
\usepackage{booktabs,tabularx}

\begin{document}

\begin{table}[!htp]
\centering

\caption{Semantic models of the OCCR model}
\label{table:semantic models of OCCR model}

%\scriptsize

\begin{tabularx}{\textwidth}{@{} l c X @{}}
\toprule
Models & Symbol & Description \\
\midrule
Assets & AS &
  Asset information in the manufacturing domain, such as hardware
  (equipment and tooling), software, the human workforce, and enabling
  technologies for achieving reconfiguration. 
\\
\addlinespace
Capacity model & CM &
  A structured representation of manufacturing KPIs that monitor the
  performance state on the shop floor focusing on the reconfiguration. 
\\ 
\bottomrule
\end{tabularx}

\end{table}

\end{document}

为什么caption?因为它使顶部标题与表格很好地分开(标准类别设置为底部字幕)。

最好\label将 放置在相关的 旁边\caption

在此处输入图片描述

您可以进行垂直居中,但我不推荐这样做。

\documentclass{article}
\usepackage{caption}
\usepackage{booktabs,tabularx}

\begin{document}

\begin{table}[!htp]
\centering

\caption{Semantic models of the OCCR model}
\label{table:semantic models of OCCR model}

%\scriptsize
\renewcommand{\tabularxcolumn}{m}

\begin{tabularx}{\textwidth}{@{} l c X @{}}
\toprule
Models & Symbol & Description \\
\midrule
Assets & AS &
  Asset information in the manufacturing domain, such as hardware
  (equipment and tooling), software, the human workforce, and enabling
  technologies for achieving reconfiguration. 
\\
\addlinespace
Capacity model & CM &
  A structured representation of manufacturing KPIs that monitor the
  performance state on the shop floor focusing on the reconfiguration. 
\\ 
\bottomrule
\end{tabularx}

\end{table}

\end{document}

在此处输入图片描述

顺便说一下,你的\tbc命令应该是

\newcommand{\tbc}{\mathop{\textstyle\bigcup}}

或者该符号不具有数学运算符关于间距的属性。

答案2

前两列的空间太小了。如果缩小两列,就可以有更多的空间来写长描述,甚至可以使用更大的字体,这样读起来会更舒服:

\documentclass{article}
\usepackage{comment}
\usepackage{mathtools} % for \smashoperator macro
\newcommand\tbc{{\textstyle\bigcup}} % handy shortcut macro
%\usepackage[table]{xcolor}

\usepackage{nicematrix}

\usepackage{caption}
\usepackage{tabularray}


\begin{document}

\begin{table}[!ht]
\centering
\caption{Semantic models of the OCCR model}
\small
\begin{tblr}{
  colspec={|Q[c,1.4cm]|c|X[c]|},
  row{1}={font=\bfseries},
  cells={valign=m}
}
\hline
Models& Symbol & Description\\
\hline 
Re\-con\-fig\-uration& AS & Asset information in the manufacturing domain, such as hardware (equipment and tooling), software, the human workforce, and enabling technologies for achieving reconfiguration.\\ 
\hline Capacity model& CM &   A structured representation of manufacturing KPIs that monitor the performance state on the shop floor focusing on the reconfiguration.\\ 
\hline
\end{tblr}
\label{table:semantic models of OCCR model}
\end{table}

\end{document}

在此处输入图片描述

答案3

\documentclass{article}
\usepackage{tabularray}
\begin{document}
\begin{table}
\centering
\caption{Semantic models of the OCCR model}
\label{table:semantic models of OCCR model}
\begin{tblr}
{
colspec    = {Q[c,m]Q[c,m]X[l,m]},
hlines,vlines,
rows       = {font=\small},
row{1}     = {font=\bfseries},
cell{1}{Z} = {}{halign=c}
}
Models          & Symbol & Description                                                                                                                                                                      \\
Reconfiguration & AS     & Asset information in the manufacturing domain, such as hardware (equipment and tooling), software, the human workforce, and enabling technologies for achieving reconfiguration. \\
Capacity model  & CM     & A structured representation of manufacturing KPIs that monitor the performance state on the shop floor focusing on the reconfiguration.                                          \\
\end{tblr}
\end{table}
\end{document}

在此处输入图片描述

相关内容