I'm trying to create my own Beamer theme and I have a problem in handling the headline. I would like to create a headline with a coloured line for the frame title, while for other frames I want a classical headline with sections and possibly subsections. Here is the part of the code I use:
\defbeamertemplate*{headline}
{ \ifnum\c@framenumber>1
\leavevmode%
\hbox{%
\begin{beamercolorbox}[wd=\paperwidth,ht=\headerheight,dp=0pt]{}%
\ifx\insertsection\@empty
\else
{
{\usebeamerfont{headsection}\hspace{1em} \color{LightBlue}\insertsection}
\ifx\insertsubsection\@empty
\else
{\hspace{0.5em}$\vert$ \hspace{0.5em}{\usebeamerfont{headsubsection}\color{DarkGray}\insertsubsection}}%
\fi
}
\fi
\end{beamercolorbox}%
} %
\vskip0pt%
\else
\hbox{%
\begin{beamercolorbox}[wd=\paperwidth,ht=20pt,dp=0pt]{linemid}
\end{beamercolorbox}%
}
\fi
}
In such a way I obtain a result which is not satisfactory because the coloured line in title frame is OK, but sections and subsection of the following frames (and so the title and the body of the frame) are shifted down. It seems that beamer keeps the space reserved for the first headline, but I don't want that. Is there a way to fix the problem?