2

I have enable put a blank page in each section:

\setuphead[section][page=yes]

I want to not to insert a page blank after some specific sections:

Eg.

\section{Section 1}%starts a new page after
bla...
\section{Section 2}% I need this section does not start a new page
bla...
2

Another option might be to define a new section command:

\setuphead[section][page=yes]

\definehead[sectionnopage][section][page=no]

\starttext
Some text here.
\section[title=Section 1]
bla...
\sectionnopage[title=Section 2]
bla...
\stoptext
| improve this answer | |
2

You can use \disablepagebreaks in a group around the section, but I don't know whether this has any side effects.

\setuphead[section][page=yes]

\starttext

\section{Section 1}
bla...

{\disablepagebreaks\section{Section 2}}
bla...

\stoptext

There seems to be no counterpart to \disablepagebreaks. It's still possible to define one, but keep in mind that this is not supported and might break in unexpected ways.

\unprotect
\let\normal_page_breaks_process\page_breaks_process
\unexpanded\def\enablepagebreaks%
    {\let\page_breaks_process\normal_page_breaks_process}
\protect

\setuphead[section][page=yes]

\starttext

\section{Section 1}
bla...

\disablepagebreaks
\section{Section 2}
\enablepagebreaks
bla...

\stoptext
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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