[Tex/LaTex] How to avoid a linebreak before a comma

line-breakingpunctuation

I just had a problem with a linebreak after a word ending with a hyphen which was followed by a comma.

This example shows the problem:
(The example is constructed, but this just occurred to me in a real text!)

    \documentclass[11pt, a4paper]{scrartcl}

\usepackage[ngerman]{babel}

\begin{document}

aaDas ist ein Absatz. Das ist ein Absatz. Das ist ein Absatz. Es gibt zeit-, temperatur-,  und weggesteuerte Verfahren ein Absatz. Das ist ein Absatz.Das ist ein Absatz. Das ist ein Absatz.Das ist ein Absatz. Das ist ein Absatz.Das ist ein Absatz. Das ist ein Absatz.Das ist ein Absatz. Das ist ein Absatz.

    \end{document}

example image

As I can not imagine any scenario where a comma at the beginning of a line could make sense, I wonder how I could tell LaTeX to absolutely avoid that.

Best Answer

You should use "~ for that. See the documentation for babel (texdoc babel).

aaDas ist ein Absatz. Das ist ein Absatz. Das ist ein Absatz. Es gibt zeit"~, temperatur"~, und weggesteuerte Verfahren ein Absatz.
Das ist ein Absatz.Das ist ein Absatz. Das ist ein Absatz.Das ist ein Absatz. Das ist ein Absatz.Das ist ein Absatz. Das ist ein
Absatz.Das ist ein Absatz. Das ist ein Absatz.
Related Question