15

I am using the following document class:

\documentclass[twocolumn]{svjour3}

Unfortunately, the two columns of output text just look horrible as they are not properly aligned on the right-hand side of the text. I am just wondering whether I can automatically tell LaTeX to align it nicely on the right-hand side or if I have to manually tell LaTeX when to break a line as this is sometimes not happening.

3
  • 1
    Could you create a full example where we can reproduce the problem? Oct 19, 2011 at 15:30
  • Welcome to TeX.sx! Your question was migrated here from Stack Overflow. Please register on this site, too, and make sure that both accounts are associated with each other, otherwise you won't be able to comment on or accept answers or edit your question.
    – Werner
    Oct 19, 2011 at 16:58
  • 4
    In the minimal example \documentclass[twocolumn]{svjour3}\usepackage{lipsum}\begin{document}\lipsum[1-9]\end{document} the alignment in the columns are justified. I'm using this version of svjour3. Are your alignment issues dealing with poor hyphenation?
    – Werner
    Oct 19, 2011 at 16:59

1 Answer 1

24

It is indeed possible to reproduce the described behavior with the svjour3 document class for SPringer journals with the following minimal code

\documentclass[twocolumn]{svjour3}
\usepackage{lipsum}
\begin{document}
\lipsum[1-14]
\end{document}

The highlighting was added manually:

enter image description here

The reason this is occurring is that TeX was not able to meet all the rules for spacing as per the Overfull \hbox messages. One way to fix this is to add \sloppy which relaxes the rules for inter word spacing. See the answers to Why is text being placed beyond the specified line width? for a more detailed explanation.

\documentclass[twocolumn]{svjour3}
\usepackage{lipsum}
\begin{document}\sloppy
\lipsum[1-14]
\end{document}

which yields:

enter image description here

Alternatively, as Marco suggested, you could add \usepackage{microtype} to the preamble. See the microtype package documentation for more details.

If you are not set on justified text, you can use \raggeddright, or \RaggedRight from the ragged2e package.

6
  • 1
    You can also use the package microtype. Oct 21, 2011 at 20:41
  • @MarcoDaniel: I think that is a better solution. Perhaps you should add that as an answer. Oct 21, 2011 at 20:51
  • 1
    You can edit your answer. It isn't a competition here ;-) Oct 22, 2011 at 6:58
  • Even \sloppy works with ACM sig-alternate class file too. That was great. But it waste some space for automatic alignment.
    – Espanta
    Mar 10, 2014 at 16:17
  • @Espanta: Not sure how I can help with such little information. I'd suggest you post a new question and include a fully compilable MWE including \documentclass and the appropriate packages that reproduces the problem. You can reference this question if it is relevant. Mar 10, 2014 at 16:24

You must log in to answer this question.