tex tab example

\documentclass[12pt]{book}
\usepackage{xeCJK}
\usepackage{fontspec}
\newfontfamily\sourcehansans{Source Han Sans CN}
\newfontfamily\sourcehanserif{Source Han Serif CN}
\setCJKmainfont{Source Han Serif CN}
\setCJKsansfont{Source Han Sans CN}
\usepackage{geometry}
\geometry {  paperheight=297mm,paperwidth=210mm,left=9mm, right=9mm, top=7mm, bottom=7mm}
\usepackage[table]{xcolor}
\usepackage{supertabular}
\usepackage{tabularx}
\usepackage{booktabs}
\newcolumntype{L}[2]{>{\sf \columncolor{#1} \raggedright \arraybackslash} m{#2}}
  
\begin{document}

\begin{center}
    \tablefirsthead{
        \hline
        \multicolumn{1}{|c}{Item} &
        \multicolumn{1}{|c}{1} &
        \multicolumn{1}{|c}{2} &
        \multicolumn{1}{|c}{3} \\
        \hline
    }

    \tablehead{
        \hline
        \multicolumn{4}{|l|}{\small\sl continued from previous page}\\
        \hline
        \multicolumn{1}{|c}{Item} &
        \multicolumn{1}{|c}{1} &
        \multicolumn{1}{|c}{2} &
        \multicolumn{1}{|c}{3} \\
        \hline
    }

    \tabletail{
        \hline
        \multicolumn{4}{|r|}{\small\sl continued on next page}\\
        \hline
    }

    \tablelasttail{\hline}

    \bottomcaption{short summary}

    \renewcommand\arraystretch{2}

    \begin{supertabular}{L{white!30}{1.5cm}| L{gray!20}{5cm}| L{blue!20}{5cm}| L{red!20}{5cm}}
      1 & 1 & 2  & 3 \\
    \end{supertabular}
\end{center}
  
\end{document}

 

posted @ 2018-07-22 14:02  fndefbwefsowpvqfx  阅读(229)  评论(0编辑  收藏  举报