# Table notes in threeparttable misaligned

Very new to this. Have written something like this:

\begin{threeparttable}

..... table contents....

\end{tabular}
\begin{tablenotes}[flushleft]
\small
\item table comment 1
\item table comment 2
\item blah blah comment 3
\end{tablenotes}
\end{threeparttable}


I wanted the notes to be flush left against the left edge of table, which it has done, but it is misagligned - there is a space before the first character of the first line of each note, the second line is aligned further left.

So looks like this:

    table comment 1..........

table 1 comment continued (spans two lines)

table comment 2


I want the notes to line up left in a straight line.

Also, anyway to put a small space between the notes? Thanks for any help!

-
Welcome to TeX.SE! I've taken the liberty of editing your posting by indenting all lines of code by four spaces; doing so automatically pretty-prints them. A suggestion: Don't post just some relevant code snippets, but an entire MWE -- minimum working example, starting with \documentclass and ending with \end{document} -- that generates the problem behavior you're looking to fix. Having such an MWE to work with greatly simplifies the task of finding out what's going on and how to provide a fix. – Mico May 29 '14 at 4:40

\item[<marker>] without the optional marker argument uses an empty marker as default. The marker is put into \tnote, more or less a wrapper for \textsuperscript (an empty superscript in math mode). Then \item appends the space \labelsep.

In short we have: $^{}$\kern\labelsep

The first adds space \scriptspace (see "The TeXbook", "Appendix G. Generating Boxes from formulas", rule 18c). The amount is 0.5 pt. \labelsep is 0.2em or about 2 pt. Thus the overall space is about 2.5 pt.

The space can therefore be removed by:

\item
\leavevmode
\kern-\scriptspace
\kern-\labelsep


The following example also adds some vertical space between the notes, by patching \TPTdoTablenotes:

\documentclass{article}
\usepackage{threeparttable}
\usepackage{etoolbox}

\makeatletter
\patchcmd\TPTdoTablenotes{%
\TPTnoteSettings
}{%
\TPTnoteSettings
\setlength{\itemsep}{2ex}%
}{}{\errmessage{Patching \noexpand\TPTdoTablenotes failed}}
\makeatother

\begin{document}
\begin{threeparttable}
\begin{tabular}{ll}
1&a\tnote{a}\\2&b\tnote{b}\\3&c\\
\hline
\end{tabular}
\begin{tablenotes}[flushleft]
\small
\item[a] table comment~1
\item[b] table comment~2
\item \leavevmode\kern-\scriptspace\kern-\labelsep table comment~3
\end{tablenotes}
\end{threeparttable}
\end{document}


-
I think -- but I could be wrong! -- that what the OP wants is some indentation of continuation lines of table footnotes, so that the text part is uniformly indented. – Mico May 29 '14 at 9:14
@Mico: The OP said "straight" line. But additionally he wants additional vertical spaced, which I now have addressed by the updated answer. – Heiko Oberdiek May 29 '14 at 9:28
The space for separating the table note mark seems not exactly \, -- the first line of 'table comment 3' in the output above still isn't exactly flush left. Using \item\hspace{-2.5pt}table comment~3 made it appear exactly flush left, regardless of font size or shape. Maybe it's -2.5pt? – Lin Yangchen Sep 18 '14 at 16:32
@YangchenLin Yes, you are right. With a finer analysis I now get as horizontal indentation space: \scriptspace + \labelsep (= 2.49997 pt). Answer fixed. – Heiko Oberdiek Sep 18 '14 at 17:38