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.

Is there a way to achieve something like openright, but for sections in the article class?

The MWE would be somthing like this, real simple:

\documentclass{article}
\begin{document}

\tableofcontents

\section{Number 1}
Some text...
\section{Number 2}
Some text...
\section{Number 3}
Some text...
\section{Number 4}
Some text...

\end{document}

But every section should start on the right page.

share|improve this question
1  
To be frank, if you want to start sections on a new (odd) page, you dhould really consider using report (or something like that). –  Johannes_B Sep 1 at 21:48

1 Answer 1

up vote 4 down vote accepted

Very likely you are using the wrong class.

Nevertheless, \cleardoublepage can be added before each \section. Also class option twoside needs to be set:

\documentclass[twoside]{article}

\usepackage{etoolbox}
\pretocmd\section{\cleardoublepage}{}%
  {\errmessage{Patching \noexpand\section failed}}

\begin{document}

\tableofcontents

\section{Number 1}
Some text...
\section{Number 2}
Some text...
\section{Number 3}
Some text...
\section{Number 4}
Some text...

\end{document}
share|improve this answer
    
yes, I should have used the report class, but I'm rather new to latex and I decided that this way looked better after printing and then it was too late to change all the sectioning in the entire document, but this helped me and saved me lots of time. Thank you!! –  piptin Sep 1 at 23:06

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.