Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am using inline lists (from the enumitem package) within a table (see Comma-separated list environment) Originally, I had an issue where the inline list would expand horizontally to the width of the table. I mostly fixed this using a \hfill after the inline list, but this doesn't seem to work for the last table row. Does anyone have any ideas how I could fix this?

Here is the relevant LaTeX code:

\newlist{commalist}{description*}{4}
\setlist[commalist]{itemjoin={{,}},itemjoin*={{ and}},afterlabel=\unskip{{~}}}`

\newenvironment{technicalSkills}%
{%
\def\lwidth{0.3\textwidth}%
\def\rwidth{0.64\textwidth}%
%
\newcommand\technicalSkillsItem[2]{%
\ifdef{\separator}{\separator}{}%
##1 & %
\begin{commalist}%
##2 %
\end{commalist}. \hfill %
\def\separator{\\[0.5em]}%
}%
%
\begin{longtable}{>{\bfseries}L{\lwidth}!{\VRule}R{\rwidth}}%
}
{\end{longtable}}


\section*{Technical Skills}
\begin{technicalSkills}
%
\technicalSkillsItem{Programming Languages}
{\item C
\item C++
\item Java
\item Perl
\item Python}
%
\technicalSkillsItem{Web-Based Development}
{\item PHP
\item JavaScript
\item CSS
\item HTML}
%
\technicalSkillsItem{Document markup}
{\item \LaTeX}
%
\technicalSkillsItem{Databases}
{\item Oracle
\item MySQL
\item postgreSQL}
%
\technicalSkillsItem{Operating Systems}
{\item Microsoft Windows
\item Linux
\item Solaris}
%
\technicalSkillsItem{Tools}
{\item Git
\item Subversion
\item Eclipse IDE}
%
\end{technicalSkills}
share|improve this question
1  
Please, complete the code to a MWE. –  egreg Jul 9 '12 at 21:53
1  
Please always post complete documents that may be processed by latex. The fragment contains may undefined commands and undefined tablular L column, so it is virtually impossible for anyone to guess what it does or how to help make it do something different. –  David Carlisle Jul 9 '12 at 21:56
    
Just guessing, try a \\ before \end{technicalSkills} –  JLDiaz Jul 9 '12 at 22:08

2 Answers 2

Just add \par before \end{longtable} in the definition of the technicalSkills environment.

share|improve this answer
up vote 0 down vote accepted

I added \phantom{} after the end of the commalist (ie. \end{commalist}. \phantom{}). This seems to work best for me.

share|improve this answer
1  
\null would be a better choice. –  egreg Jul 12 '12 at 23:20
    
Noted, thanks for the advice. –  Joshua Spence Jul 18 '12 at 5:46

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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