2

I am making a presentation in LaTex using the Beamer document class. I am using the Hannover theme. This has a navigation bar on the left side and the content of the presentation is on the right hand side.

I want to place background image on a slide (or a frame) but only on the right hand side (spanning the entire right hand side only). I followed this link --> How to insert a background image in a beamer frame? . However, part of the image also lies behind the navigation bar (which I do not want). How can I achieve this?

Edit 1: Here's an MWE:

\documentclass[xcolor={dvipsnames}]{beamer}
\usetheme{Hannover}
\usecolortheme{rose}

\begin{document}
    \section{A section}
    {
        \usebackgroundtemplate{\includegraphics[width=\paperwidth {../img/cluster-ex-1.png}}%
        \begin{frame}
            \begin{center}
                \LARGE
                    \textit{\textbf{Title of the frame}}            
            \end{center}
        \end{frame}
    }
\end{document}

Here is the result: Result of above latex code

As you can see, the image also lies behind the navigation bar, which I do not want. I want it to occupy the entire right hand side of the presentation only. How can I do the same?

Python_user
  • 215
  • 2
  • 7

1 Answers1

3
\documentclass{beamer}
\usetheme{Hannover}

\makeatletter
    \newlength{\imagewidth}
    \setlength{\imagewidth}{\paperwidth}
    \addtolength{\imagewidth}{-\beamer@sidebarwidth}

    \newlength{\sidebarwidth}
    \setlength{\sidebarwidth}{\beamer@sidebarwidth}
\makeatother

\usebackgroundtemplate{%
    \hspace*{\sidebarwidth}%
    \includegraphics[width=\imagewidth,height=\paperheight]{example-image}%
}

\begin{document}

\begin{frame}
content
\end{frame}

\end{document}

enter image description here