-
Notifications
You must be signed in to change notification settings - Fork 478
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve styling of tables in LaTeXWriter #1938
Conversation
For larger tables I do find that it improves readability if you have some horizontal lines to guide you between the rows. Do you think it would still look good to have either light or dark gray lines between the rows? I do agree that it makes sense to distinguish the header from the body rows though. |
It's much better than before but the horizontal lines in between the rows is not very nice IMO. I kind of agree with
so how about something like with a very faint grey background to guide you? Generated with: \documentclass[12pt]{article}
\usepackage{booktabs}
\usepackage{color, colortbl}
\usepackage[table]{xcolor}
\definecolor{Gray}{gray}{0.93}
\usepackage[first=0,last=9]{lcg}
\newcommand{\ra}{\rand0.\arabic{rand}}
\begin{document}
\rowcolors{2}{Gray}{white}
\begin{table}[ht]
\centering
\begin{tabular}{cccccccc}
\toprule
&col1 &col2 &col3 &col4 & col5 &col6 &col7\\
\midrule
row1& \ra & \ra & \ra & \ra & \ra & \ra & \ra \\
row2& \ra & \ra & \ra & \ra & \ra & \ra & \ra \\
row2& \ra & \ra & \ra & \ra & \ra & \ra & \ra \\
row2& \ra & \ra & \ra & \ra & \ra & \ra & \ra \\
row2& \ra & \ra & \ra & \ra & \ra & \ra & \ra \\
row3& \ra & \ra & \ra & \ra & \ra & \ra & \ra \\
\bottomrule
\end{tabular}
\caption{My Table}
\end{table}
\end{document} |
I'll let @mortenpi decide. But I'd vote no lines and no color. Is this really less readable? |
First, color >> lines, so that's a great suggestion! As for the readability of color vs no color: I think for small, dense tables no color maybe even more readable. But I am concerned about large tables, with potentially some whitespace. E.g. this example If you would make it even bigger and have more variation in the line lengths, I think it would become tricky to read without any horizontal guides. |
The current tables have all borders and don't distinguish headers from subsequent rows.
6d8eb2d
to
35f7d29
Compare
Here's a big table from the JuMP docs: No colorWith colorFor now, I think the current state of the PR is an improvement in all cases, but it's hard to be perfect in every case. In the interest of increment change, I'd vote we merge, wait to see how things go in the ecosystem, and come back for more fixes/if anyone complains. |
Sounds good. Yea, there is always more bikeshedding that can be done with these things. But all the PRs you made are already a massive improvement to the look of the PDF, so thank you very much for taking them all on @odow! |
The current tables have all borders and don't distinguish headers from subsequent rows.
Current
New