I redefine \subsection in the article class
\renewcommand\subsection{%
\penalty-8888
%\pagebreak[3]
\@startsection {subsection}{1}{0em}{1\parskip plus 1\parskip minus 1\parskip}{1\parskip plus 1\parskip minus 1\parskip}{\centering\rmfamily\bfseries\scshape}%
}
and at some point in my text, I have a subsection that is near the bottom. With pagebreak[3] enabled and \penalty commented, the subsection begins on the next page but the previous text is dilated towards the bottom. This is expected. Idem, if I use the option with \penalty-8888.
If I put a \newpage just before my subsection, I get a blank space at the bottom of the page. This is what is expected and what I want but only if it is necessary (say at two-third of the page); is it possible to moderate its triggering with an argument like \pagebreak has ?
PS: actually, I redefine the \subsubsection as well and I have the same problem. I redefine the \section too, but I put explicitly a \newpage in it so all is good.