This seems to be such a simple issue, but I still have not found an answer to this question. I am using a non-float tabular environment. Depending on how many rows my table has, the distance to the preceding line changes.
If I have table with one row, the distance between the last non-table line and the first line in the table one baselineskip as I want. However, if I have a table with more than one row the table moves up closer to the preceding line, where the exact distance depends on the letters in the line. (please find the example and the output below)
Is there a way to set the distance of the table to the line before to a set value?
Thanks for your help in advance.
\documentclass[fontsize=11pt]{scrartcl}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\begin{document}
\setlength{\tabcolsep}{0pt}
\setlength{\parskip}{0pt}
\setlength{\parindent}{0pt}
lipsum\\lipsum\\
\begin{tabular}{p{0.2 \linewidth}p{0.2 \linewidth}}
\hline
lipsum & lipsum
\\\hline
\end{tabular}%
\vspace{1cm}
lipsum\\lipsum\\
\begin{tabular}{p{0.2 \linewidth}p{0.2 \linewidth}}
\hline
lipsum & lipsum\\
lipsum & lipsum
\\\hline
\end{tabular}%
\vspace{1cm}
libsum\\libsum\\
\begin{tabular}{p{0.2 \linewidth}p{0.2 \linewidth}}
\hline
lipsum & lipsum
\\\hline
\end{tabular}%
\vspace{1cm}
libsum\\libsum\\
\begin{tabular}{p{0.2 \linewidth}p{0.2 \linewidth}}
\hline
lipsum & lipsum\\
lipsum & lipsum
\\\hline
\end{tabular}%
\vspace{1cm}
\end{document}
\begin{tabular}[t]
but better not to have any\\
outside the tabular\hline
the text is in all cases exactly one\baselineskip
away. But I guess that is good enough for my purposes.