[texhax] latex help? ["shortisch formula"]

Uwe Lück uwe.lueck at web.de
Tue Apr 18 04:22:20 CEST 2006


Now a FAQ pointer (improving earlier fiddling about finding
something satisfying between "fussy" and "sloppy", sorry):

At 23:02 06.04.06, Karl Berry wrote:

>     So what I need is a way of telling latex to write the mbox on a new
>     line if the previous line cannot contain it properly.
>
>I think what's happening is that an unbreakable formula, even a shortish
>formula, is simply a hard thing to break lines around.  When TeX keeps
>it at the end of the line (making a too-long line), I think it's because
>it sees every alternative as worse.  To test this theory, try doing
>\begin{sloppypar}
>Your entire paragraph ...
>\mbox{$V=ZI$}
>... rest of paragraph
>\end{sloppypar}
>
>And see if it moves down.  (I expect the spacing will be pretty awful.)
>
>If this works out, since you don't want to use sloppypar around every
>paragraph, the real solution might be to adjust some of TeX's line
>breaking parameters, notably \tolerance, to allow looser paragraphs in
>general.

Somewhere in the middle of
    http://www.tex.ac.uk/cgi-bin/texfaq2html?label=overfull
playing with \tolerance is explained.

Sorry for my earlier idea of \nobreakf, which just saves you from
typing the curly braces of \mbox; however, curly braces are a
nuisance on PC keyboards indeed. And the ordinary \nobreak
after `=' suffices as well (TeXbook p. 174).

With "shortish terms" in mathematical formulas, not to be broken,
while the relation may be broken, you could add \nobreakbin
inside them, after
   \makeatletter
   \newcommand{\nobreakbin}{\binoppenalty\@M}
   \makeatother

HTH -- Uwe.

(... feel somewhat obliged to continue Robin's FAQ pointers
... just playing with Scott Pakin's Visual FAQ
... these FAQ pages are great in briefly surveying possibilities
of dealing with a certain problem, instead of longwindedly
explaining certain commands or packages
... indeed, Karl, "notably \tolerance"!)



More information about the texhax mailing list