[Tex/LaTex] How to center large figures in LaTeX and how to fix short justified lines

graphicshorizontal alignment

I have 2 questions:

  1. I am trying to center a figure in LaTeX, but above a certain size it just starts at the left margin and goes beyond the right. How can I make it actually center, so the amount it goes over the left margin is the same as the right?

  2. Some short lines justify to fill the whole page width, which makes it look really bad. Is there a way I can fix these lines, or maybe set the width for justification to be considered?

Thanks in advance.

Best Answer

  1. \centerline{\includegraphics{foo}}

  2. Can you provide an example? You can use \raggedright or even ragged2e package to control the paragraph. However, I wonder how the short lines fill the whole page width.

Related Question