I wanted to automatically pass to a newpage when i'm near the end of one on special occasions and so i was wondering if they were anything that would tell where it should be based on what is above. Exactly i would like something giving either the distance to the upper border of the page or the purcentage of advencement in the page.
PS: If you have a way to pass to a new page when near the end of one page, i will gladly accept it even if it doesn't match the rest of my question
Thanks for your answers
\the\pagegoalgives the expected total height of page box, and\the\pagetotalgives the accumulated total height of vertical boxes. Related question: https://tex.stackexchange.com/q/4017/79060 – muzimuzhi Z Mar 11 '20 at 04:50needspacewhich inserts a page break if the amount of space is less than a certain amount. That is, you "need a specific amount of space on the page", or else insert a page break. See pagebreak if only 1/4th of the page left? or How to compute the remaining space on the current page. – Werner Mar 11 '20 at 05:14\pagrebreak[3]can make a page break conditional to page break depending of page penalties. In practice, you will see that is rarely used and less of[3]will be ignored in most scenarios and [4] is mandatory, so .... – Fran Mar 11 '20 at 11:01