[Tex/LaTex] How to achieve an automatic linebreak in tabularx with \multicolumn

line-breakingmulticolumntabularx

I'm working with tabularx and now I'd like to combine all 3 cells of one line to a single one, but my text is quite long and I don't know how to get it to make automatic linebreak in the text in this environment.
Someone know what I should do?

\documentclass[10pt,a4paper,final,twoside]{book}
\usepackage{amsmath}

\usepackage{tabularx}
\usepackage{makecell}
\usepackage{multirow}

\usepackage{multicol}
\setlength{\columnsep}{1.5cm}
\setlength{\columnseprule}{0.2pt}

\usepackage{polyglossia}
\setmainlanguage{french}

  \begin{document}
  \begin{center}
    \begin{tabularx}{1.\linewidth}{|p{.31\linewidth} | p{.31\linewidth} |     p{.31\linewidth} |}
    \hline 
    \textbf{Ernout/Meillet\textsubscript{4}} & \textbf{REW\textsubscript{3}} & \textbf{DÉRom}  \\ 
    \hline 
    apert\={u}ra & ap\u{e}rt\={u}ra & \makecell[l]{*/aper\textquotesingle t-ur-a/\\\hspace{4pt} $\longrightarrow$ I. */aper\textquotesingle t-ur-a/  \\ \hspace{4pt} $\longrightarrow$ II. */oper\textquotesingle t-ur-a/} \\ 
    \hline
    \multicolumn{3}{|c|}{Les issues romanes ont été subdivisées selon les deux types dont elles relèvent : */aper't-ur-a/ (I.) et */oper't-ur-a/ (II.). I. représente une évolution phonétique régulière de protorom. */aper't-ur-a/ et il existe en italien, romanche, espagnol, asturien, galicien et portugais....  }   \\
    \hline 
    \end{tabularx} 
    \end{center}

enter image description here

Best Answer

Use X columns and a p column for the last part.

\documentclass[10pt,a4paper,final,twoside]{book}
\usepackage{amsmath}

\usepackage{tabularx}
\usepackage{makecell}
\usepackage{polyglossia}

\setmainlanguage{french}

\begin{document}

\begin{center}

\begin{tabularx}{\linewidth}{|X|X|X|}
\hline 
\textbf{Ernout/Meillet\textsubscript{4}} & \textbf{REW\textsubscript{3}} & \textbf{DÉRom}  \\ 
\hline 
apert\={u}ra & ap\u{e}rt\={u}ra & 
  \makecell[l]{%
    */aper\textquotesingle t-ur-a/\\
    \hspace{4pt} $\longrightarrow$ I. */aper\textquotesingle t-ur-a/ \\
    \hspace{4pt} $\longrightarrow$ II. */oper\textquotesingle t-ur-a/
  } \\
\hline
\multicolumn{3}{|p{\dimexpr\linewidth-2\tabcolsep-2\arrayrulewidth}|}{%
  Les issues romanes ont été subdivisées selon les deux types dont elles
  relèvent: */aper't-ur-a/ (I.) et */oper't-ur-a/ (II.). I. représente
  une évolution phonétique régulière de protorom. */aper't-ur-a/ et il
  existe en italien, romanche, espagnol, asturien, galicien et portugais....  } \\
\hline 
\end{tabularx} 
\end{center}

\end{document}

enter image description here

Related Question