[Tex/LaTex] subsection font size with beamer theme Warsaw

beamerfontsizeheader-footer

I am trying to change the font size of subsection bar of a beamer presentation using Warsaw.
I found this which is doing exactly the same for the Berlin. I tried that in my presentation with Warsaw and getting error:

/usr/share/texlive/texmf-dist/tex/latex/beamer/themes/theme/beamerthemeDarmsta
dt.sty
(/usr/share/texlive/texmf-dist/tex/latex/beamer/themes/outer/beamerouterthemesm
oothbars.sty)) (/usr/share/texlive/texmf-dist/tex/latex/lipsum/lipsum.sty)

! LaTeX Error: Missing \begin{document}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              

l.32 }

Not much insight to me.
I am putting my minimal code (using Berlin), to show what I want to achieve with Warsaw. I just want to have such larger subsection headerbar using Warsaw

\documentclass[10pt,a4paper,xcolor=dvipsnames,xcolor=table]{beamer}
\mode<presentation>
{\usetheme{Berlin} \setbeamercovered{transparent}}
\usetheme{Darmstadt}
\usepackage{lipsum}
\setbeamerfont*{section in head/foot}{size=\large}
\setbeamerfont*{subsection in head/foot}{size=\large}

\newlength\SubHt
\settoheight\SubHt{\usebeamerfont{subsection in head/foot}S}
\newlength\SubDh
\settodepth\SubDh{\usebeamerfont{subsection in head/foot}g}

\makeatletter
\setbeamertemplate{headline}
{%
  \begin{beamercolorbox}[colsep=1.5pt]{upper separation line head}
  \end{beamercolorbox}
  \begin{beamercolorbox}{section in head/foot}
    \vskip2pt\insertnavigation{\paperwidth}\vskip2pt
  \end{beamercolorbox}%
  \ifbeamer@theme@subsection%
    \begin{beamercolorbox}[colsep=1.5pt]{middle separation line head}
    \end{beamercolorbox}
    \begin{beamercolorbox}[ht=1.5\SubHt,dp=1.5\SubDh,%defaults: ht=2.5ex,  dp=1.125ex
      leftskip=.3cm,rightskip=.3cm plus1fil]{subsection in head/foot}
      \usebeamerfont{subsection in head/foot}\insertsubsectionhead
    \end{beamercolorbox}%
  \fi%
  \begin{beamercolorbox}[colsep=1.5pt]{lower separation line head}
  \end{beamercolorbox}
}
\makeatother

\begin{document}
  \section{sec1}
  \subsection{sss}
\begin{frame}
  \frametitle{}
  \lipsum
\end{frame}
\end{document}

Best Answer

Warsaw uses the shadow outer theme, which is in turn based on split; whereas Berlin uses the miniframes outer theme.

To get what you want, you just have to look into your local texmf tree,

TEXMF/tex/latex/beamer/base/themes/outer/

find the beamerouterthemesplit.sty file, copy the definition for headline. Then make the appropriate changes to the height and depth.

Code

\documentclass[10pt,a4paper,xcolor=dvipsnames,xcolor=table]{beamer}
\mode<presentation>
{\usetheme{Warsaw} \setbeamercovered{transparent}}
% \usetheme{Darmstadt}
\usepackage{lipsum}
\setbeamerfont*{section in head/foot}{size=\large}
\setbeamerfont*{subsection in head/foot}{size=\large}

\newlength\SubHt
\settoheight\SubHt{\usebeamerfont{subsection in head/foot}S}
\newlength\SubDh
\settodepth\SubDh{\usebeamerfont{subsection in head/foot}g}

\makeatletter
\setbeamertemplate{headline}
{%
  \leavevmode%
  \begin{beamercolorbox}[wd=.5\paperwidth,ht=1.5\SubHt,dp=1.5\SubDh]{section in head/foot}%
    \insertsectionnavigationhorizontal{.5\paperwidth}{\hskip0pt plus1filll}{}%
  \end{beamercolorbox}%
  \begin{beamercolorbox}[wd=.5\paperwidth,ht=1.5\SubHt,dp=1.5\SubDh]{subsection in head/foot}%
    \insertsubsectionnavigationhorizontal{.5\paperwidth}{}{\hskip0pt plus1filll}%
  \end{beamercolorbox}%
}
\makeatother

\begin{document}
  \section{sec1}
  \subsection{sss}
\begin{frame}
  \frametitle{}
  \lipsum[1]
\end{frame}
\end{document}

Output

enter image description here