Some text lines are longer than the rest of the column

Some text lines are not wrapped correctly and they are longer than the rest of the column. How to solve this?

Here a MWE:

\documentclass{acm_proc_article-sp}
\begin{document}
PTX source modules have a three-argument assembly language style
syntax with instruction operation codes and operands.

Contrary to popular belief, Lorem Popo is not simply random text.
Ippp available, but the majority have suffered alteration in some for
Contrary to popular belief, Lorem Popo is not simply random text.
Ippp available, but the majority have suffered alteration in some for
\end{document}


I do not want to re-phrase the text. What are my options?

• Welcome to TeX.sx! Please add 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}. – Mythio Apr 24 '13 at 20:25
• See if tex.stackexchange.com/questions/34721/… helps. – Torbjørn T. Apr 24 '13 at 20:29
• Yes, this is exactly what happens. I know there is a command that I can wrap such a paragraph into and latex does the line-breaking better. Don't recall the command. – ritter Apr 24 '13 at 20:34

Somehow the word "operands" slips through the hyphenation patterns. You fix this paragraph by saying

\hyphenation{op-er-and op-er-ands}


before \begin{document}.

This should be the warning you get:

Overfull \hbox (19.98651pt too wide) in paragraph at lines 20--22
\T1/aer/m/n/9 guage style syn-tax with in-struc-tion op-er-a-tion codes and ope
rands.


from which the missing hyphenation is clearly visible.

The word appears in the list of American English hyphenation exception file that on a TeX Live distribution is located at:

/usr/local/texlive/2012/texmf-dist/tex/generic/hyphenex/ushyphex.tex


You can also do

\input{ushyphenex}


so that many other words that are hyphenated incorrectly or incompletely can be taken care of.

I would try rewording the offending paragraph or looking for bad hyphenation before resorting to drastic measures such as \sloppy.

Curiously enough, with the British English hyphenation patterns the word is split as op-er-and (op-er-ands).

The class authors seem not being aware that the ae fonts have been obsolete for some years. However this is not the problem in this particular case.

I don't have acm_proc_article-sp class so I don't know your line width but adding \sloppy before the text will probably fix it.

• That was the command I was looking for!! Thanks – ritter Apr 24 '13 at 20:56
• \begin{sloppypar} ... \end{sloppypar} wrapped around just the offending paragraph(s) would limit its effect to where needed, with the likelihood that the rest of the document might look better. \sloppy is a bludgeon, where a scalpel wouls be more appropriate. – barbara beeton Apr 24 '13 at 21:12