Generalnew sections at bottom of page not being pushed to next page

LaTeX specific issues not fitting into one of the other forums of this category.
sfranky
Posts: 9
Joined: Thu Nov 29, 2007 3:21 pm

new sections at bottom of page not being pushed to next page

Post by sfranky »

hi all!
i m new here, and although i ve been using latex for many years, I m not at all familiar with how it works internally.
So my problem is this: I thought latex was supposed to be pushing sections that are at the bottom of the page automatically to the following page, but this doesn't seem to happen in my case.. any ideas? i don't want to push them manually each time with pagebreaks, because every time i make a big change to the book i have to reposition them!!
the packages i m using are these:
\documentclass[11pt,a4paper,titlepage]{reitz_new}
\usepackage[greek]{babel}
\usepackage[iso-8859-7]{inputenc}
\usepackage{kerkis} %(this is a greek font)
\usepackage{psfig}
\usepackage{epsfig}
%\usepackage{xr}
\usepackage{cancel}
\usepackage{amstext}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{fancybox}
%%%%%%%%%%\usepackage{makeidx,showidx}
\usepackage{bm}
\usepackage{amsfonts}
\usepackage{extarrows}
\usepackage{picins}
\usepackage{amsthm}
\usepackage{makeidx}
\usepackage{fancyhdr}
\pagestyle{fancyplain}

thanks everyone!
sotiris

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

new sections at bottom of page not being pushed to next page

Post by localghost »

sfranky wrote: […] I thought latex was supposed to be pushing sections that are at the bottom of the page automatically to the following page, but this doesn't seem to happen in my case. […]

Who claims that? This is a misunderstanding. Sections are never set on the next page automatically when there's enough space left. But there are two possible solutions.
  1. Force the placement on the next side manually by adding a \newpage command right in front of every section.
  2. Split your document into several files where each file contains a single section and include them in your header file.

Code: Select all

\documentclass[11pt,a4paper,titlepage]{reitz_new}
…
\begin{document}
  …
  \include{section1}    % First section saved in file section1.tex
  \include{section2}    % Second section saved in file section1.tex
  …
\end{document}

Best regards and welcome on Board
Thorsten
sfranky
Posts: 9
Joined: Thu Nov 29, 2007 3:21 pm

Re: new sections at bottom of page not being pushed to next page

Post by sfranky »

thanks for your reply and welcoming!
Unfortunately, as I ve stated in my first post, it will take ages to manually put pagebreaks or newpages (it's almost the same, is't it?) and I will also have to change them from time to time as I add/remove content,
and,
the other solution, I m already doing that!!! It's not working!!?
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

new sections at bottom of page not being pushed to next page

Post by localghost »

Maybe a problem of the to me unknown documentclass. Where does it come from? Search engines didn't put on any hits. Please post a minimal working example and put the class file in the attachment.
User avatar
Juanjo
Posts: 657
Joined: Sat Jan 27, 2007 12:46 am

new sections at bottom of page not being pushed to next page

Post by Juanjo »

This thread, although a bit different, shows that the \section command can be redefined to automatically perform a \newpage command. It may be of some interest for the present question.
sfranky
Posts: 9
Joined: Thu Nov 29, 2007 3:21 pm

Re: new sections at bottom of page not being pushed to next page

Post by sfranky »

hmm, does it matter that the structure is more like this:

\documentclass[11pt,a4paper,titlepage]{reitz_new}
…
\begin{document}
…
\include{chapter1}
\input{section1}
\input{section2}
....

\include{chapter2}
…
\end{document}


?
i can't nest includes so i put inputs.. does \input do the same thing as \include, regarding the section placement?
User avatar
Juanjo
Posts: 657
Joined: Sat Jan 27, 2007 12:46 am

Re: new sections at bottom of page not being pushed to next page

Post by Juanjo »

No, of course. The command \include starts a new page, but \input doesn't.

Where do you want to start a new page? Before every section? Even the first one of every chapter?
The CTAN lion is an artwork by Duane Bibby. Courtesy of www.ctan.org.
sfranky
Posts: 9
Joined: Thu Nov 29, 2007 3:21 pm

Re: new sections at bottom of page not being pushed to next page

Post by sfranky »

@localghost: i will try and make a mwe later tonight!
@juanjo: I compile, and open the pdf document. In some pages, there is a section at the bottom of the page, as in, it's the last thing written on the page. I want to make all these bottom-showing sections show up in the following page instead, but without leaving a serious gap, if possible. I d rather not mess with the hierarchy of the document if possible (I mean, I wouldnt like to make it flat, one wrapper with a list of includes instead of includes with unputs inside)
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

new sections at bottom of page not being pushed to next page

Post by localghost »

sfranky wrote: @localghost: i will try and make a mwe later tonight!

That's not necessary any more. My questions were answered in the course of this thread. If you haven't done so yet, add some commands to your preamble.

Code: Select all

\clubpenalty10000
\widowpenalty10000
These are normally to suppress widows and orphans, but could also affect the behaviour of section titles at the bottom of a page.
sfranky
Posts: 9
Joined: Thu Nov 29, 2007 3:21 pm

Re: new sections at bottom of page not being pushed to next page

Post by sfranky »

nope, it didn't... :cry:
(hmm it doesn't seem to be working for what it is supposed to be either... :?: am i doing something wrong?)
Post Reply