Questions tagged [rowcolor]
The rowcolor tag has no usage guidance.
153
questions
0
votes
1
answer
53
views
Incorrect formatting of table with graphics inside using centering statements
I am trying to produce this beautiful table with ducks.
I have two formatting issues that are connected:
the most annoying one is that when zooming on the table
the white \Xhline or the color bands ...
0
votes
1
answer
51
views
Can't colour the right rows table
I have made a table with a table generator. I want the two first rows to be white, the following row to be grey and white intermittently.
This is the code I generated:
Preamble:
(long since this is a ...
1
vote
0
answers
25
views
below space not coming correctly using colortbl.sty and rowcolor
My codes are:
\documentclass[executive,twoside, justified, symmetric, notoc,openany]{tufte-book}
\usepackage{booktabs}
\usepackage{longtable}
\usepackage{colortbl}
\usepackage{setspace}
\usepackage{...
2
votes
1
answer
106
views
\rowcolor makes the text disappear
I use rowcolors{...} to color a table, After that, some text from my column disappear slightly .
Why is that, and what can I do to fix the error?
\documentclass[12pt,a4paper]{article}
\...
0
votes
3
answers
38
views
How to make a longtable with \extracolsep zebra striped
I found out from this question that one can make a longtable zebra striped by using
\rowcolors{2}{white}{gray!25}
So I tried it but noticed that it doesn't look good in my project - the stripe sticks ...
0
votes
1
answer
23
views
How to get \clearpage and \rowcolor to work together in a longtable?
I have this multi-page longtable where I need to nudge a row over to the next page for layout purposes. Normally I'd just start the row with \clearpage (and this has worked elsewhere) but this time I ...
0
votes
1
answer
50
views
Rowcolor gaps in the intercolumn space [closed]
I have a table that uses alternating white and gray colored rows, but there is always a lack of color applied to the intercolumn space. I have tried what other threads suggested in using variations of ...
1
vote
2
answers
35
views
multirow with color does not work properly
First, there is not any error message, but I have this problem in which I want to merge rows horizontally, but I do not know why the text appears like that:
Code:
\documentclass{article}
\usepackage[...
2
votes
2
answers
170
views
How do I add vertical space of 10pt between the rows so that it is not as congested, while still maintaining the row colors?
\begin{document}
\begin{table}[H]
\centering
\begin{tabular}{ccccccccc}
\toprule
String Tension & \multicolumn{8}{c}{Rebound Height / m $\pm$ 0.05 m}\\
kg/ $\pm$ 0.5 & ...
3
votes
1
answer
294
views
How to reset alternating row colors using xcolor and longtable?
I am attempting to automate alternating row colors in a longtable environment. My rows alternate between gray and white, and the alternating persists across pagebreaks. My issue is that I would like ...
0
votes
0
answers
112
views
Undefined control sequence using \rowcolor, \cellcolor and \multicolumn (packages already installed)
I am using https://www.tablesgenerator.com in order to create my table. The code is:
% Please add the following required packages to your document preamble:
% \usepackage{multirow}
% \usepackage[table,...
0
votes
3
answers
100
views
The taburowcolors doesn't change the row color
I need to highlight the special line on my table. For doing that, I use the next configuration:
\documentclass[9pt]{scrreport}
\usepackage{tabu,booktabs}
\usepackage{booktabs}
\usepackage{numprint,...
1
vote
2
answers
74
views
How to do \nopagebreak in xltabular with \multicolumn and \rowcolor?
After reading tons of answers here, the docs and log output I have no idea to solve my \nopagebreak issue.
Based on the How to insert a \pagebreak before a \multicolumn? answer I build this MWE:
\...
1
vote
2
answers
137
views
Tabularx alternate row colors not working
I'm unable to get alternate row colors to display for any of my tables inside sections. What am I missing?
My MWE for a sample section:
main.tex
\documentclass{article}
\usepackage[document]{ragged2e}
...
1
vote
1
answer
91
views
Problem with \rowcolor command in nicematrix package
I am having problems with the \rowcolor command in nicematrix package. Here is a MWE.
\documentclass{article}
\usepackage{nicematrix}
\begin{document}
We define the product \(AB\) by
%Example 1
\...
1
vote
1
answer
145
views
Alternating row color in all tabularx
I would like to colour every alternating row in every tabularx.
I know that I may gain this for all normal tabulars by using the following code in the preamble:
\usepackage[table]{xcolor}
\definecolor{...
0
votes
1
answer
76
views
Is it possible to color the rows (with different colors in each row) in an xltabular environment?
I would like to color the text containing in the table row but with different colors in each row. How can I do this? Below, I show my minimum code.
\documentclass[12pt, article]{memoir}
% Packages
\...
1
vote
2
answers
41
views
Rowcolor not working when tabular contents is in a separated file
I am having some issues in using rowcolor in some tables that have the contents in separated files. The following code works normally
\documentclass{article}
\usepackage{booktabs}
\usepackage{color, ...
2
votes
1
answer
65
views
rule, colorbox, space
I have three questions about this table:
The space between the \toprule and the description is greater than the space between the description and the \midrule. How Could I change this that both ...
3
votes
3
answers
158
views
\rowcolors command (xcolor, option [table]) and different table environments
Using xcolor.\rowcolors together with booktabs.\midrule I have encountered some weird behaviour. To make it plain: the point is not whether or why the tables look so utterly ugly ...
In the MWE there ...
7
votes
2
answers
198
views
rowcolor too large when removing space on rows
I am a LaTeX beginner and facing an issue that I can't seem to find the answer for... I am creating a table (using booktabs but my issue also occurs when not using the package), and whenever I remove ...
0
votes
2
answers
109
views
how can shading rows in table
I wanted to do shading in a table according to its rows. For example, if you see the table below:
a b c d
a 90 10 0 0
b 0 80 10 10
c 0 0 95 5
d 0 10 5 85
I want to shade ...
2
votes
2
answers
220
views
Reset rowcolors of table
I had some tables with alternating row coloring, using \rowcolors{1}{white}{gray} and tabular environment. After that, I wanted to reset my rowcolors to the default, so I did \rowcolors{1}{white}{...
2
votes
2
answers
115
views
How do I reduce the height of a colored row in a table?
I want to get this:
I wrote this, when I put [-1.5ex] after \\, I can get reduced row height but the color of the row is still normal row height. How can I make the color's height reduce? Any ...
3
votes
1
answer
53
views
rowcolor uneffective in longtable with makecell
I'm trying to color the rows of a longtable with rowcolor as follow (in the MWE I have onyl included few rows of the very long table):
\documentclass[a4paper]{article}
\usepackage[fontsize=8pt]{...
2
votes
2
answers
46
views
Altering table row colors trought multirow
I can alternate the color of the rows in a table with \rowcolors. However, when I use \multirow it makes breaks the 'logical coherency':
How it works:
How should it works:
MWE for the first output:
\...
5
votes
2
answers
90
views
Tabularx, rowcolors, rotated multirow text in table
I'm having issues with my tables, specifically with alternating row colors. In my tables, I have a column in which I display the category of the row entry. E.g., for olympic weightlifting, I ...
3
votes
3
answers
274
views
Three alternating row colours in a table with multirow
I have an horribly complex LaTeX table which I try to make a bit more readable.
I would like to use three different row colours, starting at the batch size column.
It is very difficult to do so, ...
1
vote
0
answers
51
views
`\rowcolor{}` does not color the row in a table [duplicate]
My goal is to color a row as lightgray, but instead of coloring a row it just prints green string in the row. What my be the reason for this and how can I fix it?
I am using following example with ...
2
votes
1
answer
42
views
Alternating rowcoloring by xcolor not identical for all tables
I am trying to apply alternating colors to my document, by use of the xcolor package with the table option. As far as I am aware it is possible to define the alternating colors in the preamble, so ...
1
vote
3
answers
201
views
\rowcolor and @{} issue
In the next example we can see that
\rowcolor does not take into account the declaration @{} in tabular preambles.
Is this a normal behavior?
Is there some elegant way to avoid that spurious filled ...
0
votes
2
answers
152
views
How make colored headrow in a table?
I have the following table
\newcommand{\headrow}{\rowcolor{black!20}}
\definecolor{Gray}{gray}{0.90}
\begin{table}[ht]\rowcolors{1}{Gray}{white}
\begin{center}
\caption{Test Table}
\begin{tabular}{l|...
0
votes
1
answer
102
views
Color \multirow?
I want to draw a table using threepartable. I want the following structure:
1- the first line includes 2 rows:\multirow
2- the second line includes also two rows
3-the third line include 3 rows
4- ...
1
vote
2
answers
77
views
mult-colored multirow tables (not using \multirow{-x})
I wonder if there's a different way to do the alternate colors in a multirow tables.
Everywhere people use "\multirow{-x}" but i would like to know if there's a way of doing it without any ...
0
votes
0
answers
90
views
Highlighted column and row not working. How to resolve it?
I need to highlight some columns and rows in the table. But the following code is not working. So kindly help me to resolve the issue. I am using miktex with winedt. Thank you.
\documentclass[CEJMed,...
0
votes
1
answer
199
views
How to prevent overflow of row/cell colors in booktabs? [duplicate]
Based on this answer you know how to easily create rows with background colors. This also works for booktabs.
Edit: This is how it looks by default with \begin{tabular}{lccc}:
But we want to change ...
0
votes
1
answer
58
views
Non-uniform row color for multi-columns + multi-rows (Partially colored rows withing merged columns and rows region)
Regarding the MWE shown below, I do not know the reason for non-uniform row color among merged columns and rows. Although I am using the command (\rowcolor{gray!25}), rows are partially colored in the ...
0
votes
2
answers
238
views
rows of alternating colors in longtable: filling whitespace depending on the row number
I'm using the longtable package along with booktabs-style rules and alternating row colors. The MWE
\documentclass{article}
\usepackage[a6paper]{geometry}
\usepackage[T1]{fontenc}
\usepackage[utf8]{...
4
votes
2
answers
87
views
\rowcolor covers text in tables because of using @{\,} between columns
The table contains components of a recipe and i would like to mark replaced components with gray color.
The reason for the coverage seems to be the manual reduction of the space between the columns ...
2
votes
3
answers
160
views
color overhang with rowcolors in a table
I load xcolor with option table, to get alternating row colors
However, I can't remove the color padding before the text of the first column (when using @{}.
In xcolor documentation, I see options for ...
0
votes
0
answers
20
views
Coloring cells correctly when using tabu, multicolumn, and multirow [duplicate]
I have made the following table header using tabu, however as you can see there is a white line separating the two merged cells of the \multirow. Does anyone have any advice on how to fix this?
Code ...
0
votes
3
answers
220
views
Rowcolor overhang with makecell
When I trim the sides of tables using @{}, the \rowcolor hangs over the sides. I've fixed this with <{\kern-\tabcolsep} on the first and last column (according to this question). However, if \...
1
vote
1
answer
170
views
Rowcolors in a longtable with three parts
I have a longtable inside a ThreePartTable environment and I want to have alternating row colors across page breaks. I want to have no color on the first row, since the header is also colored. The ...
2
votes
2
answers
86
views
Coloring cells in a table redux: Vertical and horizontal bars hidden in most views/zooms
When using \cellcolor or \rowcolor to shade a cell (or row of cells) in a table, the vertical and horizontal separators become randomly obscured or hidden when viewing the PDF. This is true for ...
1
vote
1
answer
192
views
Rowcolor, Multicolumn, and Tabu
Ok, I want to create an environment that prepares my table in such a way that I have consistent results.
\documentclass[10pt]{article}
\usepackage[table]{xcolor}
\usepackage{graphics}
\usepackage{...
0
votes
1
answer
124
views
Table with multicolumn highlighted row
I'm trying to make the following table:
I can create the structure easily. However I have a problem in the row colour:
\newcolumntype{L}[1]{>{\raggedright\let\newline\\\arraybackslash\hspace{0pt}}...
3
votes
1
answer
129
views
color table rows with more than 2 colors, restarting every (n) rows
My first question here. MWE provided, short and detailed.
I want to color the rows of a table, not just alternating 2 colors, but a series of multiple colors, or perhaps 6 shades of grey. *cough*
...
0
votes
1
answer
91
views
\rowcolor doesn't fill complete cell
I use a template to create use cases in latex (Template information). This is how it normaly looks:
The latex source to use it looks like this:
\begin{usecase}
\addtitle{test text to show the ...
0
votes
1
answer
30
views
Coloring Entire Rows in a Multicolumn [duplicate]
\documentclass[a4paper, twocolumn, 12pt, notitlepage, nofootinbib]{revtex4-1}
\usepackage[top=25mm,bottom=25mm,left=25mm,right=25mm]{geometry}
\usepackage[table]{xcolor}
\usepackage{amsmath,amsfonts,...
4
votes
5
answers
485
views
Problem with highlighting a row in a table
I can highlight a row in a table (see below), but it's not centered on the text. Is there a way to fix this?
Code:
\documentclass[11pt]{article}
\usepackage{color, colortbl,booktabs}
\definecolor{...