2

Is it possible to break long words (note, not lines) in table cell without adding \- or \allowbreak?

Current code is:

\begin{tabularx}{\textwidth}{|p{3.5cm}|p{3.5cm}|X|p{3cm}|p{3cm}|p{4cm}|}
\hline
Name & Name & Name & Name & Name & Name \\
\hline
 & & & & & \\
\hline
\end{tabularx}

How to allow long word breaking in, for example, first cell? In case, when word does not have white spaces? Position of line break is not important, let text just fill the cell and break if necessary.

marxin
  • 345

1 Answers1

3

I know it's late for this particular question, but I had the exactly same necessity as the op and found a way to solve it. I share the solution so that it can be helpful for other people having the same problem.

Very simply, the seqsplit package offers the \seqsplit{} command, that allows for breaking of long words at any position where Tex would like to (e.g. at the end of a table).

gprezza
  • 113