I'm trying to make that the title of the last section appears as frametitle only on the first frame after each \section{...}
code.
Now, i'm doing it manually with this code :
\newcommand{\TS}[0]{
\mode<beamer>{
\frametitle{\thesection \insertsection}
}}
And I put manualy on the first frame after \section{title of the last section}
this code :
\section{title of the last section}
\begin{frame}
\TS
content of the frame with the last section in frametitle.
\end{frame}
\begin{frame}
This is the second frame without a title.
\end{frame}
So I want make this to made done automatically (and also put as frame subtitle the subsection if exists, and only put the subsection as frametitle if the current section as been displayed on a previous frame, …. I hope I'm being precise enough).
I've read this subject in order to try to customise it with part of the code, but without any success.
Best Answer
You need to find a frame-related hook. Below I've used
\beamer@checkframetitle
that inserts\insertsectiontitle
only for the first frame after\section
:An update to the above, which inserts the
\subsection
as\framesubtitle
on the first slide after\section
, and as\frametitle
after that: