is there a simple way to add some content at the end of pages similarly to \AtEndDocument
(for example something like \AtThisPageEnd
) ?
I looked at everyhook
and everypage
, but it doesn't look that it's possible to do it with these packages.
Does someone have an idea ?
Edit: To be more precise, I try to change the layout for some page using the geometry package. I manage to make it work when the textwidth is constant. The problem comes when it is not, see this example
\documentclass [a4paper]{article}
\usepackage [showframe]{geometry}
\usepackage {atbegshi}
\usepackage {lipsum}
\title{The Title}
\author{Me}
\date{\today}
\geometry{
paperwidth=18cm,
paperheight=18cm,
textwidth=9cm,
}
\makeatletter
\gdef\setGeometryPage
{
\ifnum\thepage=2
\global\let\setGeometryPage =\relax
\expandafter \@gobble % gobble clearpage
\newgeometry
{
textwidth=12cm,
}%
\fi
\aftergroup\setGeometryPage
}
\AtBeginShipout{
\AtBeginShipoutUpperLeft{
\setGeometryPage
}
}
\makeatother
\begin{document}
\maketitle
\section{First section}
\lipsum[1]
This part is the transition with the next page.
This part is the transition with the next page.
This part is the
%\clearpage\noindent
transition
\lipsum[1-2]
\end{document}
A workaround (not very nice) is to add the \clearpage\noindent
at the end of the first page (see example comment).
(NB: I'd like to set the layout only with the geometry
package here)
\thispagestyle{zzz}
and then specify your text in the page foot of the zzz style.\vfill
command and write whatever you want after it.