3

I'm using ACM SIG format in LaTeX (editing the sample). I want to add tables, and i did, but the distance between caption and table is weird.

Table 1 is fine, but the space in between is too small for Table 2. How do I fix it?

enter image description here

Code for table:

\begin{table} 
\centering 
\caption{Some Typical Commands} 
\begin{tabular}{|c|c|c|} \hline Command&A Number&Comments\\ \hline \texttt{{\char'134}alignauthor} & 100& Author alignment\\ \hline \texttt{{\char'134}numberofauthors}& 200& Author enumeration\\ \hline \texttt{{\char'134}table}& 300 & For tables\\ \hline \texttt{{\char'134}table*}& 400& For wider tables\\ \hline\end{tabular} \end{table}

I'm using sig-alternate-05-2015 document class.

0

1 Answer 1

3

Note that none of the letters in the second caption happen to have a descender component, i.e., a component that protrudes below the baseline. I suggest you change the second \caption instruction to

\caption{Parameters of DRAM and NAND Flash\strut}

The directive \strut, which is provided by the LaTeX kernel, inserts a (what else?) "typographic strut", with a depth of 0.3\baselineskip and a height of 0.7\baselineskip (and zero width, making the object invisible).


Here's an MWE that use the sig-alternate-05-2015 document class. Observe the difference that having a \strut directive makes for the position of the second caption.

enter image description here

\documentclass{sig-alternate-05-2015}
\newcommand\mytab{% a little test tabular...
    \begin{tabular}{|c|c|c|}
    \hline
    Parameter & DRAM & NAND Flash\\
    \hline
    Access Latency & 40ns & 1.5 (ms/blk) \\
    \hline
    \end{tabular}}
\begin{document}
\begin{table}
\centering

\caption{Parameters of DRAM and NAND Flash}
\mytab

\bigskip

\caption{Parameters of DRAM and NAND Flash\strut}
\mytab

\end{table}
\end{document}
2
  • omg! im using exact the same document class! it works perfectly :) Thank you so much!!
    – Veronica
    Commented Sep 30, 2016 at 4:49
  • @ShimHyunjeong - Good to know that my guess as to the document class was correct. :-)
    – Mico
    Commented Sep 30, 2016 at 4:52

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .