Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

How can I left-align the [multiple-row] text in the right portion of my header using fancyhdr? I have something like this

\rhead{row 1\\row 2\\row 3}

where the rows aren't the same length, and I wish for them to be aligned on the left.

share|improve this question
add comment

1 Answer

up vote 6 down vote accepted

You could use \parbox in the argument of \rhead. For example:

\rhead{\parbox{5cm}{row 1\\row 2\\row 3}}

If you would like to align the widest row to the right margin, you could use \settowidth together with a length macro and use it for the parbox width. Or have a look at the eqparbox package for auto-sizing parboxes in general.

share|improve this answer
    
Perfect...thanks! –  Kristen Nov 15 '10 at 21:37
    
@Kristen: Consider not only to accept, but also to upvote Stefans answer. ;-) –  lockstep Nov 15 '10 at 21:47
add comment

Your Answer

 
discard

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.