使用禁忌隐藏列标题的行颜色

使用禁忌隐藏列标题的行颜色

需要使用包单独隐藏列头的行颜色tabu,列头之后的表体第一行应以“青色”开始,有什么选择吗?

hiderowcolors并且showrowcolors选项在禁忌中不起作用?

\documentclass{book}
\usepackage{tabu}
\usepackage[table]{xcolor}
\begin{document}

\def\tabuprocesstable#1#2#3{
\taburowcolors[1]1{cyan .. white}\fontsize{8bp}{10bp}\selectfont%
#1\par%
#2\par%
#3%
}

\def\colhead{\bfseries\sffamily}

\tabuprocesstable{}{\begin{tabu}{p{100pt}p{100pt}}
\tabucline{-}
\colhead{Column head 1}&\colhead{Column head 2}\\
Total non-current&Employee benefits\vphantom{yg}\\
Total non-current&Employee benefits\\
Total non-current&Employee benefits\\
Total non-current&Employee benefits\\
\tabucline{-}
\end{tabu}}{}

\bigskip\bigskip
\tabuprocesstable{}{\begin{tabu}{p{100pt}p{100pt}}
\tabucline{-}
%\hiderowcolors
\colhead{Column head 1}&\colhead{Column head 2}\\
\colhead{Column head 3}&\colhead{Column head 4}\\
%\showrowcolors
Total non-current&Employee benefits\vphantom{yg}\\
Total non-current&Employee benefits\\
Total non-current&Employee benefits\\
Total non-current&Employee benefits\\
\tabucline{-}
\end{tabu}}{}
\end{document} 

相关内容