Questions tagged [makecell]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2
votes
1answer
44 views

Line break in \makecell in tabular cell in AASTeX results in extra column width?

I would like to use \makecell with to add line breaks in my table. However, this results in extra column width, with the width being what it would have been had the text not been broken onto two lines....
4
votes
1answer
37 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]{...
0
votes
2answers
35 views

\bfseries in makecell failure

I'm trying to insert \bfseries to each row of a \makecell command, but it is not compiling. MWE below: \documentclass{article} \usepackage{makecell} \begin{document} \begin{tabular}{l} \makecell[{...
0
votes
0answers
46 views

Conflict \thead function defined in two packages

I'm using both: \usepackage{makecell} \usepackage{tablestyles} in a *.tex document. If I use the previously shown order, I got an ! LaTeX Error: Command \thead already defined. error on the ...
0
votes
0answers
51 views

Alternative for makecell?

While working on a solution for Typographic conventions template / package I came across https://tex.stackexchange.com/a/26692/28139 which makes use of the optional argument for \\ to increase spacing ...
2
votes
2answers
38 views

Makecell: Declare default alignment in \usepackage[]

I want to load the makecell package with a default option to make all \makecell cells left-aligned by default. What should I substitute in for OPTIONS below to make left-alignment the default behavior ...
0
votes
0answers
21 views

package conflict in emulateapj's deluxetable and {array, makecell}

This mwe will fail in TeXLive 2020 (and in arXiv): \documentclass[apj]{emulateapj} \usepackage{array,makecell} \begin{document} \begin{deluxetable*}{lcl} stuff. \end{deluxetable*} \end{document} with ...
2
votes
2answers
65 views

Rotated bold font in NiceTabular table heading

I am making table using both nicematrix and makecell packages, because these packages applied together allow to obtain multirow heading cells containing rotated text (as pointed here; if I am not ...
1
vote
1answer
39 views

conflict between arydshln and makecell packages. How to resolve

I am using answer in how-to-place-a-vertical-dashed-line-between-columns-of-a-matrix to add dashed lines in a matrix. But I also load package makecell to fix another problem with tables as given in ...
2
votes
1answer
36 views

Can't simultaneously use makecell, threeparttable and tabulary

I'm trying to accomplish "threeparttables" while simultaneously using both makecell (to achieve within-cell rowbreaks) and tabulary (to make the tables not exceed \linewidth). But while I ...
2
votes
1answer
84 views

How to make a table with multirow rotated cells?

I am trying to make the table with automatically centered, rotated multirow cells. Something like in the picture, but with cells automatically fitted to their content: I tried to apply solutions ...
0
votes
0answers
34 views

Use a simplekv variable with a newline inside makecell

MWE: \documentclass{standalone} \usepackage{makecell} \usepackage{simplekv} \usepackage{tabularx} \setKVdefault[test]{ kv1 = {Test 2 \\ Test 3}% } \useKVdefault[test] \begin{document} \begin{...
3
votes
1answer
46 views

Automatic line break in tabularx environment

I'm trying to get a table that automatically inserts a line-break so some very long text can fit in the cell, instead of overflowing to the margins like it's doing now. I tried with \makecell but didn'...
6
votes
2answers
122 views

Issue combining makecell and cellcolor

I have seen similar question to this one already but none of the answers I have found seem to solve my problem. I'm trying to color the cells of the first column of my table, but I cannot find a ...
2
votes
3answers
103 views

Color cell incomplete in coloured columns LaTeX and hhline details trouble

I have a problem with my table in LaTeX. A few of cells doesn't fill well. I used the package "makecell" to do multirow and define new types of columns instead colortbl package (because I ...
1
vote
1answer
32 views

weird text place on the top of the column with makecell in latex table

I want that the text is placed in the top of the column in my table. I have the following code: \documentclass[a4paper,12pt]{scrreprt} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage[...
4
votes
2answers
92 views

Coloring a line of a table

I try to color only the first line of the table below, using the code: \documentclass{article} \usepackage{makecell} \usepackage{hhline} \usepackage{xcolor} \usepackage{colortbl} \usepackage{tabularx} ...
1
vote
0answers
47 views

How can I create an easily extensible table in latex?

My example table looks like this, but should be easily extensible to implement more nested or merged cells inside. For instance I want to add more lines to the content of the last column. Let's say 3 ...
1
vote
1answer
36 views

How to enable the automatic line breaks in table and forced the text to break?

I have created a table, and I have fixed its width, but the problem when I write a long text, the text breaks the line, I want to add an automatic line break when the text should respect the width of ...
0
votes
1answer
40 views

Vertical alignment of \makecell header

I have some issues with the vertical alignment of \makecell headers for a longtable. Basically, what I'm trying to achieve is that the single lettera A, B and E are vertically centered while the other ...
0
votes
3answers
102 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
4answers
72 views

Problem with colortbl and makecell

Here is an simple example. \documentclass{article} \usepackage[table]{xcolor} \usepackage{colortbl} \usepackage{multirow, makecell} \begin{document} \begin{tabular}{c} longer text\\ \cellcolor{...
0
votes
1answer
206 views

How to bold inside makecell?

I am using makecell for table cell, \makecell[ct] {Power \\ Profile} Now, I need to bold the content and hence I used, \makecell[ct] {\textbf{Power \\ Profile}} But its not compiling. How can I ...
1
vote
2answers
61 views

Unwanted space between letters in tabular cell

I am using below code, \begin{table} \caption{Performance comparison of CMOS VCO with the state-of-the-art} \label{tab:3_3} \setlength{\tabcolsep}{5pt} \centering \small \begin{tabular}{ |p{2cm}|p{...
2
votes
2answers
136 views

Vertical centering of multirowcell text when specifying other column widths

I have tables where I am trying to use two features together: multirowcell (from the makecell package) for cells that span multiple rows with new lines inserted into the text in specific locations, ...
2
votes
2answers
50 views

Reducing the line spacing for a rotated table cell

I'm trying to reduce the line spacing for the rotated table cells in order to reduce the width of the table and to make it look nicer. Also the cell "Material" looks kind of crammed. This is what it ...
2
votes
2answers
58 views

Align columns with numbers by decimal point and ratio symbol (colon :)

I want to achieve alignment by decimal number AND the colon (:) ratio symbol, similar to what is shown in the code below as opposed to what is shown in the figure. I would welcome any suggestions for ...
2
votes
1answer
37 views

How to achieve a centered header over right-aligned columns of numbers when the header is long relative to the width of the column of numbers

I have difficulties to produce a relatively wided centered header entry over a relatively narrow column of right-aligned numbers. The other way around it works fine with the makecell package as shown ...
1
vote
2answers
122 views

Cell size with multirow and rotated content

I have the problem, that the cell size on my rotated multirow cells does not adapt its size, so that the contents fit. I tried following the solution described in Long text in rotated multirow , but ...
1
vote
1answer
32 views

How to make a sentences to become 2 line using \thead [duplicate]

I had try include \thead but not working. I want to make Class AA and Class BB go into second line. \documentclass[12pt,oneside]{book} \usepackage[showframe]{geometry} \usepackage{amsmath} \...
0
votes
1answer
41 views

vertical text problem in table

I'm making a planning for some report, and used the LaTeX table generator to change it from Excel to LaTeX. However, if I'm running the generated code, the vertical text gets split up, which I don't ...
0
votes
1answer
386 views

Can we use \makecell in Tabularx

I am not sure why I cannot use \makecell Basically, I just want to have a content centre there. Making my life very difficult. \documentclass[12pt,oneside]{book} \usepackage[showframe]{geometry} \...
1
vote
2answers
116 views

\Xcline (makecell) doesn't lign up with \vrule

I'm not sure how to fix this problem where the \Xcline from makecell doesn't lign up with the \vrule I set in my longtable(need that since the actual table might span several pages). Here is a MWE of ...
1
vote
1answer
44 views

How to align rotated table cells

I need help with aligning rotated cell text. The problem is that I don't know in advance the text that appears in the table, so I can't use something like \settowidth\rotheadsize{text}. This is what ...
3
votes
2answers
77 views

Is it possible to create a command with another command, passing code as a string?

I want to loop through a list and print some text. The placement of that text is inside a table, inside a \makecell command. I could hard-code the items from the list I want, including some \\ ...
1
vote
1answer
151 views

How to Solve Error With Square [] Brackets on New Line in Header

In the table below, if I move the units in the square brackets to the next line in the header (e.g. [mg/g] on a new line), I get an error. However, if I use curved () brackets instead, there is no ...
3
votes
3answers
311 views

Colored tables with booktabs, makecell and cellspace

While experimenting with different table-packages, I realised, that each package basically stands for itself and often lacks in compatibility with other great packages. So I tried to create a table ...
0
votes
1answer
113 views

Fix errors for a specific table

I have a table with this MWE. \documentclass[a4paper,12pt]{article} \usepackage{amsmath,amssymb} \usepackage{booktabs,makecell} \begin{document} \begin{table}[htb] \captionsetup{justification=...
0
votes
0answers
108 views

\makecell is not working in \tabular{*} s columns, in the l first column it works fine

See this please: \documentclass[11pt]{article} \usepackage[nopar]{lipsum} \setlength\parindent{0pt}% globally suppress indentation \usepackage[format=hang,labelfont=bf]{caption} \usepackage{fullpage} ...
0
votes
1answer
118 views

Undefined control sequence \mcell@MB@ when using \diaghead

When I use the \diaghead provided by makecell package, I get Undefined control sequence errors. It seems the \mcell@MB@ and \mcell@MBjot are both undefined. Following is a simplified example adapted ...
0
votes
0answers
305 views

tabu+makecell+xcolor = Improper \prevdepth

The packages tabu, makecell and xcolor seems to interact in incompatible ways: MWE: \documentclass[10pt,a4paper]{article} \usepackage{tabu} \usepackage{makecell} \usepackage[usenames,dvipsnames]{...
3
votes
2answers
90 views

Even vertical distribution of lines in a multiline cell

I am trying to create a figure which has two or three photos on the right and text on the left. What I want is for the text on the left to be equally spread across the height of the cell (equal to the ...
1
vote
1answer
455 views

makecell package and column width

To create the tables I use the makecell package. I would need the last four columns have a with a smaller width than the first: this is my attempt \documentclass{article} \usepackage[T1]{fontenc} \...
5
votes
2answers
321 views

Table coloring doesn't extend all the way with makecell

This issue occurs while using xcolor to alternate the table color, while also using makecell to put multiple lines in a table cell. In this specific scenario, where a larger cell is in a colored line, ...
1
vote
2answers
957 views

How to use \thead with left align locally instead of globally?

How to align the contents of the \thead cell to the right? \documentclass[12pt]{memoir} \usepackage{tabularx} \usepackage{makecell} \begin{document} \begin{tabular}{|c|} \thead{Content \\ ...
1
vote
1answer
141 views

Evenly vertically spaced lines inside makecell

I have a table with a rotated header, and some makecells afterwards to fit the rotated header on one line: \documentclass{article} \usepackage{makecell} \usepackage{graphicx} \usepackage{booktabs} \...
4
votes
2answers
612 views

Align column in table on Plus/minus symbol with values of varying length and align header of first column with data?

I would like the data in the "Confidence Limit" column to align on the plus/minus symbol. Here is a link to a similar but different question Aligning +- sign in table. However, the values in my data ...
2
votes
0answers
226 views

Using makecell in tabu: incompatibility with the packages tcolorbox and todonotes

I have a problem when using the package tabu with makecell and tcolorbox and todonotes. This is my minimal example code: \documentclass[a4paper]{scrreprt} \usepackage{tcolorbox} \usepackage{todonotes}...
1
vote
3answers
1k views

How to get automatic line-breaks using tabularx and makecell?♀

I'm using the tabularx and makecell packages for the aesthetics of my tables. I used the X column type for columns with long texts and \makecell{...} for line-breaks into the cells. But when I try to ...
2
votes
2answers
90 views

Text not quite centred in table using makecell

See my code below and attached image showing output of the code. I'm producing a table which is just about finished, but one last thing is bothering me. The text in the cells of the column titled "...