6
votes
Accepted
Color issue with the combination of the longtable, rowcolor, and makecell
You can avoid the problem by using longtblr from the tabularray package:
\documentclass[a4paper]{article}
\usepackage[table]{xcolor}
\definecolor{lightblue}{rgb}{0.93,0.95,1.0}
\usepackage{tabularray}...
6
votes
Long table with all Mathematics columns
In addition to following @PeterGrill's suggestion to load the array package, you may want to give some thought to give the longtable more visual appeal. Importantly, it isn't necessary -- or even ...
5
votes
Accepted
Pages won't break when making table using xltabular
Any kind of long tables (as are longtable, xltabular, ltablex etc.) should not be encapsulated in float table. It prevent that they can be broken over several pages.
Using xltabular, which is ...
5
votes
Pages won't break when making table using xltabular
You never applied any type of long tables. If you need xltabular for instance, below is an example.
I made a couple of changes: moved title from the bottom to the top, added geometry to increase space ...
4
votes
Accepted
Centering text in longtable
I suggest you employ the basic c column type for the first four columns; since the ability to perform automatic line-breaking is not a requirement for these columns, why use the p column type? And, do ...
4
votes
Coloring rows with longtable, and with multirows
As I see your table, you not need multi row cells.
Using \longtblr of tabularray package enable to write concise table code:
\documentclass{article}
\usepackage[dvipsnames,table]{xcolor}
\definecolor{...
4
votes
Color issue with the combination of the longtable, rowcolor, and makecell
Here is a solution with {NiceTabular} of nicematrix. I have replaced in your code {longtable} by {NiceTabular} and I have put your instruction \rowcolors{1}{lightblue}{white} in the so-called \...
4
votes
Accepted
Fit image to a multirow cell in a landscape long table
Like this?
simpler, far more concise table code can be obtained by use of the longtblr of tabularray package
table is huge, so you may consider to reduce page borders that table would have more space ...
4
votes
Table too long for one page and column content not vertically aligned
Here's a code based on longtable with working headers and footers. I also added two packages: listings improves code formatting; and cellspace inserts extra vertical spacing between rows.
\...
4
votes
Accepted
Some issues with longtable, math coloumn, rowcolor and arraystretch
\documentclass{book}
\usepackage[margin=15mm]{geometry}
\usepackage{physics}
\usepackage[svgnames]{xcolor}
\usepackage{tabularray}
\begin{document}
\begin{longtblr}
[
caption = {title},
label ...
4
votes
using xurl package with \href and a long \url within the longtable package
you have to use \nolinkurl to see the effects of xurl
\RequirePackage[hyphens]{xurl}
\documentclass[12pt,a4paper]{article}
\usepackage{lipsum}
\usepackage{xcolor}
\usepackage{longtable}
\usepackage{...
4
votes
Vertically centering subtable in cells of a main longtable
The way you're entering the data in the longtable environment, LaTeX "knows" about individual cells -- and about shifting some of the down (or up) if they're the argument of a \multirow ...
4
votes
Accepted
Problem with vertical centering of cells of a same row of a longtable
I suggest you switch the underlying column type of the L, C, and R column types from p to m. (m is mnemonic for "middle", I suppose.)
\documentclass{article}
\usepackage{longtable,array,...
4
votes
Accepted
How to split a table across pages using longtable?
(updated the answer to switch from a longtable setup to a tabularx setup)
If you eliminate the line breaks in columns 2, 3, and 4, you can typeset the entire table on a single page.
The following ...
3
votes
Accepted
Coloring rows with longtable, and with multirows
Merge cells from the "bottom" with a negative number of cells. It seems that colours applied to rows overlap the text. If you move \multirow to the bottom, you let the text be typeset after ...
3
votes
Accepted
Increase the font in a table whilst fitting it in a page
In your table code is very easy went to lost ... Also image of table is poor quality, so reading data from it is impossible.
So, I edit few first eleven rows of your table. In this effort may happen, ...
3
votes
Increase the font in a table whilst fitting it in a page
I suppose the title of your query, "Increase the font [size]" could be changed to "stop reducing the font size", because serious font size reduction is exactly what \resizebox does....
3
votes
Longtable doesn't include right border
Instead of longtable I would rather use longtblr of tabularray package.
For lists in the second column seems to be better to use enumerate list with resume*=<list name> option.
In MWE below I ...
3
votes
Accepted
Longtable doesn't include right border
I would like to suggest a couple of things.
If you want to number any element, in your case rows, use counters so you don't have to remember the next value.
LaTeX already have lists, which you can use ...
3
votes
Accepted
Long landscaped tables - how to make text continue to fill the previous page?
It's been three years since the question was posted, so I hope it is still useful for someone out there. The problem can be solved by using the package "afterpage", in which the command ...
3
votes
Accepted
Bold caption-tag in tabularray table
You can change the caption tag font like this:
\documentclass{article}
\RequirePackage[font=small, labelfont=bf, labelsep=period]{caption}
\usepackage{tabularray}
\begin{document}
\begin{table}[...
3
votes
Table too long for one page and column content not vertically aligned
Here's a longtable based solution that strives to give the table a more open "look" by using the line-drawing macros of the booktabs package -- specifically, \midrule, \addlinespace, and \...
3
votes
Some issues with longtable, math coloumn, rowcolor and arraystretch
As supplement to nice Clara answer with a little bit changed table layout:
no newgeometry for table, table can nice fit in existed table layout
bigger rowsep
different way to "centering" of ...
3
votes
Accepted
\endlastheader in longtable?
You can easily do it with longtblr of the wonderful package tabularray:
\documentclass{article}
\usepackage{tabularray}
\DefTblrTemplate{conthead-text}{default}{- Continued from previous page}
\...
3
votes
Accepted
Multipage cells with tabularray
It's possible to simulate a table in which cell would span multiple pages. As suggested, the main package would be paracol because in this environment paragraphs can continue on following pages. ...
3
votes
Accepted
htlatex: problem with caption in longtable
Try this version of longtable.4ht:
% longtable.4ht (2022-04-28-13:47), generated from tex4ht-4ht.tex
% Copyright 1997-2009 Eitan M. Gurari
% Copyright 2009-2022 TeX Users Group
%
% This work may be ...
3
votes
Longtable format question
You can read the doc of tabularray to learn how to set caption or other.
Open
If you want open, you need to calculate the leftpos and rightpos, you can read rounding error (?) when doing double or ...
3
votes
How to fix text displaying on top of table line
Unfortunately you not provide MWE (Minimal Working Example), a small but complete document, so we haven't any information about used document class nor about used fonts and your page layout.
Your ...
3
votes
Accepted
Long Table extended cross the paper margin
Welcome to TeX.Se!
Since relevant part of your document preamble is unknow, I use article document class and in MWE (Minimal Working Example) add needed package for compilation of your table. So, it ...
3
votes
caption placement and reference
This caption formatting is defined in the document class. You should probably keep it as is because it conforms with the APA formatting (see APA7 tables).
If you really want to change it and keep ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
longtable × 2529tables × 1024
captions × 199
page-breaking × 163
tabularx × 144
landscape × 108
multicolumn × 94
spacing × 93
multirow × 91
vertical-alignment × 81
horizontal-alignment × 77
tabu × 64
width × 56
threeparttable × 53
margins × 49
floats × 47
formatting × 43
columns × 43
longtabu × 43
line-breaking × 42
header-footer × 39
color × 38
booktabs × 38
pgfplotstable × 36
footnotes × 35