1

After asking this question about how to add some spacing between two row in a tabular environment, I figured out some strange behaviour of the itemize command within the tabular* environment.

Using the solution suggested by Steven B. Segletes leads me to another one. When I use the itemize command inside of my tabular* environment I am not able to remove the vertical spacing after it if it is at the very end of the cell. If it is some text before and after it is fine.

My MWE to illustrate my issue

\documentclass{article}
\usepackage[left=1.5cm,top=2cm,right=1.5cm,bottom=2.5cm,nohead,nofoot]{geometry}
\usepackage{enumitem}
\setlist{nosep}

\setlength{\tabcolsep}{0pt}
\newenvironment{entrylist}{%
  \begin{tabular*}{\textwidth}{@{\extracolsep{\fill}}ll}
}{%
  \end{tabular*}}

\renewcommand{\bfseries}{}
\newcommand{\entryacquis}[5]{%
  #1&\parbox[t]{14.5cm}{%
    \textbf{#2}%
    \hfill%
    #3\\%
    #4\strut}\\
{Skills~:} &#5} 

\begin{document}

\begin{entrylist}
\entryacquis
{6\thinspace --\thinspace 8.2008}
{Job Position}
{A company}
{something}
{Some learned skills}
\end{entrylist}
\vspace{40pt}

\begin{entrylist}
\entryacquis
{6\thinspace --\thinspace 8.2008}
{Job Position}
{A company}
{\begin{itemize}
\item Something
\end{itemize}}
{Some learned skills}
\end{entrylist}
\vspace{40pt}

\begin{entrylist}
\entryacquis
{6\thinspace --\thinspace 8.2008}
{Job Position}
{A company}
{text
\begin{itemize}
\item Something
\end{itemize}
text}
{Some learned skills}
\end{entrylist}

\end{document}

And the output it produce :

enter image description here

Can somebody help me to figure out how to have the same spacing as in the first table with a list of item at the very bottom of my table's cell ?

  • Within the right margin of this page, see all the "Related" posts. There's a combination that should work for you. – Werner Jun 2 '16 at 14:39
  • @Werner I already checked them all and many others. But I was not able to find out how to achieve what I want in my case. I also tried to put the itemize of a minipage but didn't work neither. – Pierrick Jun 2 '16 at 15:10
2

Just play with the before and after keys for itemize:

\documentclass{article}
\usepackage[hmargin=1.5cm,top=2cm,bottom=2.5cm,noheadfoot]{geometry}
\usepackage{enumitem}
\setlist{nosep}

\setlength{\tabcolsep}{0pt}
\newenvironment{entrylist}{%
  \begin{tabular*}{\textwidth}{@{\extracolsep{\fill}}ll}
}{%
  \end{tabular*}}

\renewcommand{\bfseries}{}
\newcommand{\entryacquis}[5]{%
  #1&\parbox[t]{14.5cm}{%
    \textbf{#2}%
    \hfill%
    #3\\%
    #4\strut}\\
{Skills~:} &#5}

\begin{document}

\begin{entrylist}
\entryacquis
{6\thinspace --\thinspace 8.2008}
{Job Position}
{A company}
{something}
{Some learned skills}
\end{entrylist}
\vspace{40pt}

\begin{entrylist}
\entryacquis
{6\thinspace --\thinspace 8.2008}
{Job Position}
{A company}
{\begin{itemize}[before=\vspace*{-\baselineskip}, after=\vspace*{-\baselineskip}]
\item Something
\end{itemize}}
{Some learned skills}
\end{entrylist}
\vspace{40pt}

\begin{entrylist}
\entryacquis
{6\thinspace --\thinspace 8.2008}
{Job Position}
{A company}
{text
\begin{itemize}
\item Something
\end{itemize}
text}
{Some learned skills}
\end{entrylist}

\end{document} 

enter image description here

  • Great ! That does what I want ! Can I also implement this in the preambule so it make the same things for all the itemize used in my document ? – Pierrick Jun 2 '16 at 15:55
  • 1
    I'm afraid if there's text before or after, it won't fit nicely. I suggest your define your own personal itemize, with these parameters (\setlist{myitemize}{…}), and use this personal itemize when there is no text. – Bernard Jun 2 '16 at 15:58
  • Yes you are right, if there is text before or after, then Both lines overlap each other. But it does the tricks for the moment. I will continue to search for another solution to implement it at the beginning. – Pierrick Jun 2 '16 at 16:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.