1

Similar problems with soul package can be found here and here. But since my problem is simpler than those (even related with spacing) I guess that it could have a simpler solution.

The problem occurs using underlined text \ul{} containing spacing corrections .\.

Here is the MWE

\documentclass{report}
\usepackage{soulutf8}    

\begin{document}
Regular text. 

\ul{Underlined text.} 

Regular text. 

\ul{Underlined text with abbreviated word, for example L. Euler}. 

Regular text. 

\ul{Underlined text with abbreviated word and spacing corrections using \texttt{dot backslash}, for example L.\ Euler}

\end{document}

The result is

enter image description here

Sigur
  • 37,330
  • (not tested) i think that if you can separate the dot from the backslash in the input in such a way that latex still recognizes that the last period is punctuation, you'll get the proper spacing without losing the following word. try inserting braces there: .{}\ – barbara beeton Jun 06 '14 at 13:48
  • @barbarabeeton, it still does not work. – Sigur Jun 06 '14 at 13:50
  • i've just performed some experiments that demonstrate that soul does not apply end-of-sentence spacing after abbreviations. or even, for that matter, at the end of sentences. (i'll have to check the documentation to see if that's mentioned.) if you'd like me to show the test in an answer, let me know, otherwise this comment will suffice. – barbara beeton Jun 06 '14 at 14:22
  • @barbarabeeton, thanks for your effort to understand the problem and maybe find a solution. Don't worry, you don't need to show the tests. I'll just follow the comments here. For a while I'm not using spacing corrections. Thanks again. – Sigur Jun 06 '14 at 14:34
  • @Sigur: Use either L.{} Euler or L.~Euler. – Werner Jun 06 '14 at 14:37
  • @Werner, is the result the same? Or is it almost similar? – Sigur Jun 06 '14 at 14:40
  • 1
    After an uppercase letter, TeX does not think that the abbreviation dot is a period ater a sentence with prolonged space. L. Euler is sufficient here. – Heiko Oberdiek Jun 06 '14 at 14:48
  • @HeikoOberdiek -- true, and relevant here, but i've pretty well demonstrated (to my own satisfaction) that soul does not observe the prolonged space even at the end of a sentence. i intend to explore this more fully when i have more time on the weekend. – barbara beeton Jun 06 '14 at 14:51
  • @HeikoOberdiek, nice! I didn't know about it. Is it the same with two letters (e.g. Ap.\ Foo)? – Sigur Jun 06 '14 at 14:51
  • 1
    @Sigur: It's equivalent, except that ~ inserts a non-breaking space (or tie), keeping L. together with Euler. – Werner Jun 06 '14 at 14:53
  • 1
    @Sigur: No, the letter before the dot is lowercase. – Heiko Oberdiek Jun 06 '14 at 15:00

0 Answers0