# tex4ht and colortbl

The package colortbl steals my beloved horizontal rules in the longtable. When I run tex4ht.

% run: htlatex main.tex

\documentclass{article}
\usepackage{longtable}
%\usepackage{colortbl}

\begin{document}

\begin{longtable}{c|c}
fooo & baaar \\\hline
baz &  morebaz\\\hline
\end{longtable}

\end{document}


The file above gives a beautiful html, but when I load the package colortbl, it eats my \hline.

Question: how to get the horizontal rules and use the package colortbl?

-

Not sure of the official tex4ht customisation but the hrules end up as empty table rows with distinctive ids so you can add css rules such as

 #TBL-1-2-{ border-style: solid; border-bottom: 1pt; border-color: black;}
#TBL-1-19-{ border-style: solid; border-bottom: 1pt; border-color: black;}


and the lines come back.

-
The id is not stable. If I add lines to the table, the ids will move.... –  topskip Sep 21 '12 at 17:43
yes I know, They are I think the table and row number, but its best I could do in the time available tonight. If someone posts a proper tex4ht customisation I'll delete this. –  David Carlisle Sep 21 '12 at 19:26
colortbl.4ht needs thorough rework. I am working on it, but not sure, when I'll be able to post a solution. As a workaround what you had suggested seems good enough than having nothing. –  CV Radhakrishnan Sep 22 '12 at 4:04