TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to customize the title of my scrreprt class document.

The \titlehead looks like this (basically, three 'columns' created with three instances of \minipage):



      Foo \\
      Bar \\

I have two problems:

  1. I want the top of the logo, to align with the top of the text in the other two minipages. I used the [t] option of \minipage to achieve this. But while the two textual minipages line up properly, the image doesn't. It gets rendered much higher than the text. I assume this is because \includegraphics is not text and so, the [t] option is meaningless for the first minipage. So what should I be doing to set this right?

  2. I expected the total widths of the minipages to add up to \textwidth. But if I set the third minipage to 0.3\textwidth (so that the total width adds up to whole), PDFLaTeX decides to push my third minipage down because apparently the three of them side-by-side are too wide. Is there some way I can cleanly fix this? e.g. like, making the third \minipage fill the available horizontal space? If so, how?

share|improve this question
i won't tackle the alignment, but the width problem might be solved by placing a % immediately after the first two instances of \end{minipage}. another approach, decidedly plain, not latex, is to insert \hss in those same locations, setting \parfillskip=0pt locally, and ending the \titlehead argument with \par. – barbara beeton Nov 28 '12 at 19:01
Thanks @barbarabeeton! I had forgotten that those newlines count for white space as well. – ArjunShankar Nov 29 '12 at 11:11
up vote 4 down vote accepted

You can use the adjustbox package:


  Foo \\
  Bar \\


Notice how the end of lines are masked so they don't count as a space.

The demo option to graphicx and the geometry package are just to show the example (they provide a mock image and the frame respectively).

enter image description here

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.