
나는 이런 종류의 테이블을 가지고 있습니다 :
\begin{tabular}{p{0.5\textwidth}|p{0.5\textwidth}}
caption1 & caption2 \\
\includegraphics[params]{path11} \includegraphics[params]{path12} ... \includegraphics[params]{path1N} & \includegraphics[params]{path21} \includegraphics[params]{path22} ... \includegraphics[params]{path2N} \\
\end{tabular}
이미지를 배열처럼 만들고 싶지만 열 너비를 고려하고 공간이 없으면 자동으로 새 이미지 행을 만들어야 합니다. 모든 이미지는 서로 닿지 않도록 여백을 두고 균등하게 배치되어야 합니다.
답변1
이미지를 \multicolumn{2}{c}{...}
매크로에 배치한 다음 \hfill
이미지 사이에 추가하여 이미지 사이에 약간의 여백을 확보할 수 있습니다. 충분히 작은 길이로 params
설정 해야 합니다 .width=<some length>
다음은 세 개의 이미지가 포함된 예입니다.
\documentclass{article}
\usepackage{graphicx}
\begin{document}
\begin{tabular}{p{0.49\textwidth}|p{0.49\textwidth}}
caption1 & caption2 \\
\multicolumn{2}{c}{%
\includegraphics[width=.3\textwidth]{example-image-a} \hfill
\includegraphics[width=.3\textwidth]{example-image-b} \hfill
\includegraphics[width=.3\textwidth]{example-image-c}
}
\end{tabular}
\end{document}
이미지를 수직으로 정렬해야 하는 경우 다음을 참조하세요.이미지가 중앙에 맞춰진 테이블을 만드는 방법은 무엇입니까?또는표의 왼쪽 상단에 그림을 정렬하는 방법은 무엇입니까?.