{tabularx} is a package that defines an environment tabularx, an extension of tabular which has an additional column designator, X, which creates a paragraph-like column whose width automatically expands so that the declared width of the environment is filled.

learn more… | top users | synonyms

2
votes
2answers
53 views

fitting text into the tabular and tabular into the page

I've created the following table with help of @Zarko. Now I have some questions about layout. Code: \documentclass[11pt,a4paper]{article} \usepackage[english]{babel} \usepackage[T1]{fontenc} \...
2
votes
1answer
364 views

Color midrule in tabularx [duplicate]

I have created a table using tabularx. Can I color the \midrule instead of having it colored black as default?
2
votes
1answer
365 views

Multipage table using tcolorbox and tabularx

Good day, Sirs and Madams! I am experiencing issues while composing a big table over several pages. I'd like to use tcolorbox in combination with tabularx. Unfortunately, this does not work out as ...
2
votes
2answers
49 views

When using colortbl, column is still white. What am I doing wrong?

It is probably apparent I'm trying to color the last column green, but for me, it shows up as white still. Also, if I understand correctly '>' is just used by tabularx for demarcating formatting ...
2
votes
1answer
83 views

Performance question - Tabularx or manual column width calculation?

I'm using the tabularx package and the provided X column type to get dynamic column widths. Since the pdflatex run takes longer and longer, I'm wondering whether it would be faster to use an ...
2
votes
2answers
182 views

How to *disable* Lua's Microtype for a given tabular column?

I'm looking for a way to disable Lua's Microtype (note the capital M - to distinguish from the lower case microtype package) in the first tabular column of the MWE given below: \documentclass[a4paper]...
2
votes
2answers
9k views

Wrapping text in \multicolumn

I would like to wrap (and center) text within \multicolumn. Tabularx and tabilary only wrap the text outside of the \multicolumn{} columns. I would also like to define the column width as defined by ...
2
votes
1answer
247 views

Last cell in complex table not behaving

I am having a hard time figuring out why the text in the last cell on each row of this complex table I am creating is not positioning correctly. As you can see from my code, the issue only occurs when ...
2
votes
1answer
1k views

tabular tabularx automatic linebreak (p/m/b doesn't work as expected)

The following snipped should break at the end of the column \begin{table}[hb] \begin{tabular}{|l|p{.5\textwidth}|} \hline \bfseries Col 1 & \bfseries Col 2\\\hline \hline Line ...
2
votes
1answer
49 views

Centering in Tabularx does not work

I am trying to center columns using \newcolumntype{Y}{>{\centering\arraybackslash}X}. However, it does not work in the following example. \documentclass[11pt]{article} \usepackage{setspace} \...
2
votes
2answers
62 views

How to set latex table columns from the rightmost margin?

I want to display a table in latex. Currently I have the following situation. \usepackage{array} \newcolumntype{P}[1]{>{\raggedright\arraybackslash}p{#1}} \begin{table}[h!] \begin{tabularx}{0.45\...
2
votes
1answer
110 views

Header and text overlapping

How to avoid overlapping of the header and text? \documentclass{article} \usepackage[utf8]{inputenc} \usepackage[russian]{babel} \usepackage{multirow,tabularx} \usepackage[a4paper,...
2
votes
1answer
113 views

Align Numbers in tabularx with standard deviation

I'm trying to make this table with numbers and standard deviation, how can I aligns the numbers properly? The spacing between numbers and st.dev is too high and the numbers are not aligned to the ...
2
votes
1answer
115 views

Mixing m and X in tabularx

I have a problem with tables containing m and X columns. I need one column which should be vertically centered and another one which should fill the available horizontal space. My problem is that the ...
2
votes
1answer
46 views

Space to the right of the table

Not really sure why there is a space at the right hand side of the following table. Also the numbers inside the table should be shifted a bit to the left. \documentclass[12pt,a4paper]{article} \...
2
votes
1answer
55 views

Troubles for fit this floating table to the page

Sorry for the question but I have the following MWE: \documentclass[fontsize=10pt,paper=letter,headings=big,bibliography=totoc,DIV=9,headsepline=true,]{scrbook} \usepackage[usenames,dvipsnames,...
2
votes
1answer
277 views

Long (two-page) table in twocolumn document

I'm trying to include a not too lengthy table of mathematical notation definitions in a paper I'm writing. The paper is in twocolumn mode, the definition table has to span both columns, because ...
2
votes
1answer
230 views

Align numeric values from knitr command \Sexpr{} by decimal in table created with booktabs and tabularx

I am writing my thesis as dynamic document using .Rnw, knitr and R. I ran my statistical analyses in an external R-script, which I sourced into my main .Rnw-file. I also want to create some tables ...
2
votes
1answer
480 views

tabularx table and the indentation from the addmargin environment

I have a problem with the indentation done by the addmargin environment of the koma script and the use of tabularx table. Clearly the \textwidth uses the original width of the text and not the smaller ...
2
votes
1answer
87 views

My Table Adds Page Breaks

I am making a table and have two problems. Here is the start of the TeX file: \documentclass[12pt]{article} \usepackage{tabularx} \usepackage{afterpage} \usepackage{pdflscape} \usepackage{amsmath} \...
2
votes
2answers
168 views

Need help with long and wide table; tried longtabu, longtable, sidewaystable and nothing seems to fit!

I've literally been spending hours, trying to fit this long and wide table with a series of packages: tabu, longtabu, tabularx, sidewaystable, but nothing seems to fit. This is for a thesis so I ...
2
votes
1answer
673 views

TabularX vertical alignment

Since the enumiten Package (and therefore leftmargin=*) doesnt work in custom environments, I was trying to trick a bit, doing the items in a table like this (don't ask..) : \documentclass[fleqn,...
2
votes
1answer
1k views

How to reduce distance between two columns?

I have 5 columns in my table. So I want to reduce distance between two columns to make it look good. In the following figure, I want to reduce distance between column 1 and 2. I tried \setlength{\...
2
votes
1answer
1k views

How do I typeset a table with a caption within a tabularx within another table with a caption?

Unfortunately, it keeps bugging me with forgotten \endgroup, float(s) lost, not in outer par mode and so on. In other words, why can't I do something like this (the actual table is significantly more ...
2
votes
2answers
39 views

Tabularx problem

I always used tabularx withouth any problem, but now I can't make it work anymore and I don't understand why. Could you tell me what's the problem ? \documentclass[10pt,a4paper,final,twoside]{book} \...
2
votes
2answers
35 views

Alignment in table depends on length of header

When I delete the header "General variables used in the header" in the code (or any long text), the two columns overlap like this: Current output: Current code: \documentclass[12pt,twoside]{book} ...
2
votes
1answer
22 views

Table \rowcolor \multicolumn color displacement

I have the following table: \documentclass[a4paper,12pt,twoside]{book} \usepackage[utf8x]{inputenc} \usepackage[table,xcdraw]{xcolor} \usepackage{tabularx, threeparttable} \usepackage{multirow} \...
2
votes
2answers
52 views

Math mode in table headers (tabularx)

I am editing a document, using a custom class. The author has numbers with a bar over them in a table header, e.g. $0.58\bar3$. However, when I try to compile it I get the following errors: ! Package ...
2
votes
1answer
37 views

tabularx/siunitx table: column of integers not properly aligned

I have adapted a table format recently suggested on t.SE, which works well except for two issues. MWE is below. \usepackage{array} \usepackage{dcolumn} \usepackage{tabularx} \usepackage{...
2
votes
2answers
69 views

center alignment of headers in table

I have the following part table: \begin{table}[!h] \centering \begin{adjustbox}{width=1\textwidth} \small \begin{tabular}{|l||l|} \hline \textbf{Element Name} & \textbf{Description} \\ \hline ...
2
votes
1answer
28 views

Multicolumn and multirow (tabularx)

I have a table, and it should be also border betwen C and D in the second row and border between 12 and 13. How to do that? \documentclass{article} \usepackage[utf8]{inputenc} \usepackage[...
2
votes
1answer
64 views

Vertical/Horizontal Rules in TabularX

I am trying to help kids identify whole numbers vs mixed numbers vs proper fractions vs improper fractions. I am having them practice using this table which needs two fixes. Vertical rules between ...
2
votes
1answer
49 views

Alternating coloured rows in table - line width of colouring -

I'm creating a table with alternating coloured rows. However, the colour seems to extend the top- bottom rule of the table, which doesn't look quite right. Also, my header row probably should be a ...
2
votes
1answer
36 views

How to fix default table number and description separator

I have 2 tables using different packages, but the caption gennerate different: When I use table with tabularx: Table 1 – A simple example When I use longtable: Table 2: A simple example \...
2
votes
1answer
34 views

Tabularx p column broken vertical line with manual linebreak

I have a table that uses tabularx with some p columns and some X columns. In the p columns I manually added line breaks. Everything is fine except the fact that the vertical lines that divide the ...
2
votes
1answer
70 views

“Misplaced \noalign” error when compiling table made using \tabularx

Can someone help me fix the problem? \begin{table*}[t] \centering \caption{Message header fields (64-bit total)} \label{table:header} \begin{tabularx}{\textwidth}{|l|l|l|} \hline \multicolumn{1}{|c|}{...
2
votes
2answers
53 views

Help on converting tabularx to longtable

I have a table written inside a tabularx environment, but now is too large and I need to convert it in a longtable, preserving the same column distribution and width. I don't know how to adjust the ...
2
votes
1answer
34 views

Refer to table body in new environment

I'm trying to create a new environment based on tabularx. I'd like it to have a \bottomrule at the end. How do I refer to the table rows on the new environment definition? Right now the bottom line is ...
2
votes
1answer
64 views

Vertically Center Last Column of tabularx

How do you vertically center the last column of a tabularx table? I tried to create a custom column, though, TBH, I don't really know what I'm doing. Basically, I'd like the contents of the left and ...
2
votes
1answer
92 views

How to align text vertically and horizontally in table cells of the same column?

I want to top align and right justify the text in all tabularx cells of a certain column. So far, I tried: \documentclass[a4paper,10pt]{article} \usepackage[top=2cm,bottom=2cm,right=2cm,left=3cm]{...
2
votes
1answer
89 views

Text alignment in tabularx header only works for the first column

\begin{tabularx}{.96\textwidth}{@{\extracolsep{\fill}}|c|c|c| } \hline \textbf{Xxx1} & \textbf{Xxx2} & \textbf{Xxx3} \\ \hline & & \\ \hline \end{tabularx} Why ...
2
votes
2answers
267 views

Draw vertical line on top of horizontal table lines

I'm using two \hline for horizontal line and \begin{tabular}{c | c c c c c} option for vertical line. This is some part of my table: I want vertical line on top of double horizontal lines. How can ...
2
votes
1answer
97 views

How to I use a longtabu inside \newenvironment?

I have the following newenvironment defined using tabularx \newenvironment{factlist}{% \newdimen\unbaseline \unbaseline=\dimexpr-\baselinestretch\baselineskip\relax \renewcommand\item[2]{%...
2
votes
1answer
100 views

Centered columns with fixed width using tabularx

How do I center the last seven columns in the attached text without dropping the fixed table width or the fixed column width? \documentclass[a4paper,12pt,oneside]{article} \usepackage{amsmath,amssymb,...
2
votes
1answer
538 views

Decimal alignment in tables with tabularx and multicolumn

in my masterthesis I want to create regression tables the numbers in the table are aligned by the decimal point. Here is a MWE to get an impression what I'm talking about: \documentclass[10pt,...
2
votes
1answer
118 views

\newenvironment behaviour with \begin{landscape}

I would like to use landscape mode for a \newenvironment{lessonPlanner} in which I have a table. but I get an error when I embed \begin{landscape} and \end{landscape} in the begin and end statments of ...
2
votes
2answers
207 views

Tabularx and short caption causes error

I'm trying to construct a multi-page, landscape table with variable column widths. It was working until I started to get a problem with the caption. If I try to include a short caption I get the error ...
2
votes
2answers
135 views

vertically center text in a table

I've got the following table: \documentclass[11pt]{article} \usepackage{rotating} \usepackage[ lmargin=1.0in, rmargin=1.0in, tmargin=2.0cm, bmargin=2.0cm ]{geometry} \usepackage{...
2
votes
1answer
382 views

Force Kile to create tables that are inside the page width

I am using the Tabular Wizard on Kile to create a \tabularx environment for one of my tables, and I want it to fit inside a page. Currently this is my setup: {% \newcommand{\mc}[3]{\multicolumn{#1}{#...
2
votes
2answers
4k views

Big Table in latex

Could you please helping me to draw a nice big tables like this one , I don't know how to mange the big table in LateX Many thanks