views:

749

answers:

2

I need to have codes in the format A4. The codes are so long that I would like to make two pages in my document horizontal. Other pages should be vertical.

How can you make two pages horizontal in LaTeX?

+3  A: 

Install and include this package

\usepackage{lscape}

Then when you wan't to make a horizontal (landscape) page just use landscape environment

\begin{landscape}
horizontal content here
\end{landscape}
RaYell
I am deleting my same solution below. One small caveat. If you are using pdflatex, make sure you use the pdflscape package.More info: http://www.ctan.org/pkg/lscape
SplittingField
@SplittingField: Thank you for pointing that out! - I had already an issue with `lscpape`.
Masi
pdflscape may be better if you are creating pdfs, but latex doesn't always produce pdfs so saying which one is better depends of what you are trying to do. Anyway, both packages gives you the same `landscape` that works rather well.
RaYell
Agreed. In general, I have found latex to be used as a more general term which includes latex, pdflatex, xelatex, etc. ;-)
SplittingField
+1  A: 

For completeness, it should be noted that the lscape package only works with Latex. If you use pdfLatex, you should use the pdflscape style.

For more information see this CTAN Link.

SplittingField
Do you know how you can have the pagenumbers also horizontally?
Masi
Are you sure you want to do that? it is generally against the "Standard Rules" for theses, etc. And the answer is no, not off the top of my head.. ;-)
SplittingField
I did not know that. Thank you for pointing it out!
Masi