This answer was moved from a duplicate using the Berkeley theme. The code is practically the same as Gonzalo Medina's (since both themes use the sidebar outer theme), but maybe it adds some value for the interested reader (no background color on the right and width/height of the logos)
This might work:
I will add a longer explanation how I came to this solution (and I am by far a Beamer expert), so other can see how to approach problems like this.
First you see that the used theme is "Berkeley", so going into the definition file beamerthemeBerkeley.sty
(just google it and you'll find the code).
There we can see that the outer theme (the one responsible for the sidebar and title and all) is "sidebar", so next we take a look at beamerouterthemesidebar.sty
and search for the keyword logo
and see that it is used in the headline definition.
What I did then is edit the definition to add another logo (logoright
) the the right side (by copy and paste with an \hfill
inbetween) and define some commands to set the logo. Just adjust the size of the images to your liking.
If you want to adjust the height or width (or both) of the images to the header/sidebar you can set the logos by:
\makeatletter
\logo{\includegraphics[width=\beamer@sidebarwidth,height=\beamer@headheight]{example-image-a}}
\logoright{\includegraphics[width=\beamer@sidebarwidth,height=\beamer@headheight]{example-image-b}}
\makeatother
\documentclass{beamer}
\usetheme{Berkeley}
\def\insertlogoright{\usebeamertemplate*{logoright}}
\def\logoright{\setbeamertemplate{logoright}}
\makeatletter
\defbeamertemplate*{headline}{mycustom theme}
{%
\begin{beamercolorbox}[wd=\paperwidth]{frametitle}
\ifx\beamer@sidebarside\beamer@lefttext%
\else%
\hfill%
\fi%
\ifdim\beamer@sidebarwidth>0pt%
\usebeamercolor[bg]{logo}%
\vrule width\beamer@sidebarwidth height \beamer@headheight%
\hskip-\beamer@sidebarwidth%
\hbox to \beamer@sidebarwidth{%
\hss%
\vbox to \beamer@headheight{%
\vss\hbox{\color{fg}\insertlogo}\vss%
}%
\hss}%
\hfill%
\hbox to \beamer@sidebarwidth{%
\hss%
\vbox to \beamer@headheight{%
\vss\hbox{\color{fg}\insertlogoright}\vss%
}%
\hss}%
\else%
\vrule width0pt height \beamer@headheight%
\fi%
\end{beamercolorbox}
}
\makeatother
\logo{\includegraphics[width=1.2cm,keepaspectratio]{example-image-a}}
\logoright{\includegraphics[width=1.2cm,keepaspectratio]{example-image-b}}
\title{The Title}
\author{The Author}
\institute{The Institute}
\begin{document}
{
\setbeamertemplate{logo}{}
\setbeamertemplate{logoright}{}
\begin{frame}
\maketitle
\end{frame}
}
\begin{frame}{this}
test
\end{frame}
\end{document}