In the following minimal example, the tabular seems to be indented, unless I misunderstand (for example, maybe left-aligned does not do what I think?)
\documentclass{article}
\begin{document}
\noindent Here is some text
\vspace{.2cm}
\noindent\begin{tabular}{ll}
text in row 1, col 1& text in row 1, col 2\tabularnewline
text in row 2, col 1& text in row 2, col 2
\end{tabular}
\noindent Some text afterward
\end{document}
produces the following output:
I have found the following related posts but the solutions do not work for me:
Little indentation despite \noindent after tabu custom-environment
LyX: Removing indentation from a table
Indentation after '\tabular' environments
I've tried to add \setlength{\parindent}{0pt}
but that does not seem to make a difference.
Best Answer
This is as a result of the
\tabcolsep
space inserted around every column. Using a column specification with@{}
will remove the column separation at that specific column:As a discussionary reference, see Why is my
tabular
wider than the sum of its columns’ widths?.