Figure and table side by side with common caption
Pass the b
option to your tabular
environment, too. BTW, Please consider always adding a minimal working example (MWE) that illustrates your problem. It will be much easier for us to reproduce your situation and find out what the issue is when we see compilable code, starting with \documentclass{...}
and ending with \end{document}
. I have converted your code snippet into a MWE here.
\documentclass[10pt]{article}
\begin{document}
\begin{figure}
\begin{minipage}[b]{0.60\linewidth}
\centering
%\includegraphics[width=\linewidth]{example-image}
\rule{6cm}{6cm} %to simulate an actual figure
\end{minipage}%
\begin{minipage}[b]{0.30\linewidth}
\centering
\begin{tabular}[b]{ |l|l|l| }
\hline
\multicolumn{3}{|c|}{Zzzzzz} \\
\hline \hline
A & B & C \\ \hline
0 & 0 & 0\\ \hline
0 & 1 & 0\\ \hline
1 & 0 & 0\\ \hline
1 & 1 & 1\\ \hline%
\end{tabular}
\end{minipage}
\caption{Bla bla}
\label{fig:test}
\end{figure}
\end{document}
Similarly to Aligning a figure and table side by side where the alignment is on top, you need a little trick here:
\documentclass[a4paper,10pt]{article}
\begin{document}
\begin{figure}
\begin{minipage}[b]{0.60\linewidth}
\centering
\rule{6cm}{6cm} %to simulate an actual figure
\par\vspace{0pt}
\end{minipage}%
\begin{minipage}[b]{0.30\linewidth}
\centering%
\begin{tabular}{ |l|l|l| }%
\hline%
\multicolumn{3}{|c|}{Zzzzzz} \\%
\hline \hline
A & B & C \\ \hline%
0 & 0 & 0\\ \hline%
0 & 1 & 0\\ \hline%
1 & 0 & 0\\ \hline%
1 & 1 & 1\\ \hline%
\end{tabular}%
\par\vspace{0pt}
\end{minipage}
\caption{Bla bla}
\label{fig:test}
\end{figure}
\end{document}
Notice the \par\vspace{0pt}
at the end of the minipages. The trick is taken from epslatex.pdf, Section 11.4.1, where the misinterpretation of the [b]
parameter of minipages is explained.