如何创建缩写列表

如何创建缩写列表

我怎样才能创建像这样的缩写列表

在此处输入图片描述

    \documentclass{article}
    \usepackage{tabularx}
    \usepackage{amsmath}
    \usepackage[table]{xcolor}
    \usepackage{tabularx, multirow, makecell, rotating} %
    \usepackage{enumitem}

        \begin{document}
        \begin{center}
    \bfseries
\settowidth\rotheadsize{List of Abbreviation/accronym}
\begin{tabularx}{\linewidth}{|c|>{\centering\arraybackslash}X|}
    %\hline
%\multicolumn{3}{|>{\centering\arraybackslash}%
                 %p{\dimexpr\linewidth-2\tabcolsep-2\arrayrulewidth\relax}|}{\cellcolor{gray!30}
    %Les sujets (traduits)}    \\
    \hline
\cellcolor{gray!30} Abbreviation & \cellcolor{gray!30} Explanation     \\
    \hline
\multirow[b]{2}{*}{USA}   
            & \cellcolor{blue !30}  United state of america
 \rule[-1em]{0pt}{2.5em} \\
    \cline{2-2}
   & 
   \rule[-1em]{0pt}{2.5em} \\
    \cline{2-2}
    &    \rule[-1em]{0pt}{2.5em} \\
    \hline
        \multirow[b]{2}{*}{NY}   
            &  \cellcolor{blue !30} New york 
 \rule[-1em]{0pt}{2.5em} \\
    \cline{2-2}
   & 
   \rule[-1em]{0pt}{2.5em} \\
    \cline{2-2}
    &     \rule[-1em]{0pt}{2.5em} \\
    \hline
\end{tabularx}
    \end{center}
        \end{document}

答案1

我刚刚评论了 6 行输入

    \documentclass{article}
    \usepackage{tabularx}
    \usepackage{amsmath}
    \usepackage[table]{xcolor}
    \usepackage{tabularx, multirow, makecell, rotating} %
    \usepackage{enumitem}

        \begin{document}
        \begin{center}
    \bfseries
\settowidth\rotheadsize{List of Abbreviation/accronym}
\begin{tabularx}{\linewidth}{|c|>{\centering\arraybackslash}X|}
    \hline
\cellcolor{gray!30} Abbreviation & \cellcolor{gray!30} Explanation     \\
    \hline
\multirow[b]{2}{*}{USA}   
            & \cellcolor{blue!30}  United state of america
 \rule[-1em]{0pt}{2.5em} \\
    \cline{2-2}
%   & 
%   \rule[-1em]{0pt}{2.5em} \\
%    \cline{2-2}
    &    \rule[-1em]{0pt}{2.5em} \\
    \hline
        \multirow[b]{2}{*}{NY}   
            &  \cellcolor{blue!30} New york 
 \rule[-1em]{0pt}{2.5em} \\
    \cline{2-2}
%   & 
%   \rule[-1em]{0pt}{2.5em} \\
%    \cline{2-2}
    &     \rule[-1em]{0pt}{2.5em} \\
    \hline
\end{tabularx}
    \end{center}
    \end{document}

在此处输入图片描述

相关内容