5

My title page has a background image. However, when the presentation has sections (that create a navigation bar), there is a white box on top of the image. How can I get rid of it?

\documentclass[14pt]{beamer}   % 
\graphicspath{ {./graphics/} }
\mode<presentation>
{
  \usetheme{Warsaw}
  \usecolortheme{wolverine}
  \setbeamercovered{transparent}
}
\setbeamertemplate{navigation symbols}{}%remove navigation symbols

\begin{document}
{
\setbeamertemplate{headline}{}
\setbeamertemplate{footline}{}
\usebackgroundtemplate{\includegraphics[width=\paperwidth,height=\paperheight]{square-land-background.jpg}}%

\begin{frame}{}
\end{frame}
}


\section{Introduction}
\begin{frame}{a}
\end{frame}


\section{first part}
\begin{frame}{b}
\end{frame}


\end{document}

I tried both solutions to this question: Beamer: Removing headline and its space on a single frame (for plan), but keeping the footline but they did not work.

5

A native beamer solution without additional packages:

\documentclass[14pt]{beamer} 
\usetheme{Warsaw}
\usecolortheme{wolverine}
\setbeamercovered{transparent}

\setbeamertemplate{navigation symbols}{}%remove navigation symbols

\begin{document}
{
\setbeamertemplate{headline}{\vskip\headheight}
\setbeamertemplate{footline}{}
\usebackgroundtemplate{\includegraphics[width=\paperwidth,height=\paperheight]{example-image}}%
\begin{frame}{}
\end{frame}
}


\section{Introduction}
\begin{frame}{a}
\end{frame}


\section{first part}
\begin{frame}{b}
\end{frame}


\end{document}

enter image description here

  • So the main change is "\setbeamertemplate{headline}{\vskip\headheight}", right? This works excellent. Thanks! – Erel Segal-Halevi Dec 22 '16 at 5:40
  • 1
    @ErelSegal-Halevi Yes, that's the relevant change. This just removes the space reserved for the headline. – user36296 Dec 22 '16 at 9:58
  • @samcarter Could you help me understand why adding a positive value skip \vskip\headheight to \setbeamertemplate{headline}{} removes the headline space? – Jonathan Komar Sep 5 '18 at 11:28
  • @JonathanKomar That is either deep beamer voodoo or very dirty hack (up to you which term you want to use) :) The trick is to make the headline heigher than the space reserved for it (anything larger than \vskip\headheight) will do. Because beamer only calculates the headheight at the start of the document, this will shift the main content of the frame relative to the headline, but the headline will nevertheless only start at the top of the page -> voila the image is shifted upwards. – user36296 Sep 5 '18 at 11:41
5

Set the image at page shipout as an overlay (using eso-pic):

enter image description here

\documentclass{beamer}

\usepackage{eso-pic}

\mode<presentation>
{
  \usetheme{Warsaw}
  \usecolortheme{wolverine}
  \setbeamercovered{transparent}
}
\setbeamertemplate{navigation symbols}{} % remove navigation symbols

\begin{document}

\begin{frame}{title page}
\AddToShipoutPictureFG*{
  \AtPageLowerLeft{%
    \includegraphics[width=\paperwidth,height=\paperheight]{example-image}%
  }
}
\end{frame}

\section{Introduction}
\begin{frame}{a}
\end{frame}

\section{first part}
\begin{frame}{b}
\end{frame}

\end{document}
3

\usebackgroundtemplate places the background image below the header. When you use \setbeamertemplate{headline}{}, you are only clearing the header contents, not deleting it, so what remains is the white background canvas.

One option is to define the background as an explicitly positioned tikzpicture. This will initially require two builds in order to place the image correctly, and the image will appear as the background for all frames. The following code shows the difference.

\documentclass{beamer} 
\usepackage{tikz}
    \usetikzlibrary{positioning}
\mode<presentation>
{
  \usetheme{Warsaw}
  \usecolortheme{wolverine}
  \setbeamercovered{transparent}
}
\setbeamertemplate{navigation symbols}{}%remove navigation symbols

\begin{document}
\setbeamertemplate{headline}{}
\setbeamertemplate{footline}{}

\usebackgroundtemplate{\includegraphics[width=\paperwidth,height=\paperheight]{example-image}}%

\begin{frame}{}
\end{frame}

\section{Introduction}
\begin{frame}{a}
\end{frame}

\usebackgroundtemplate{%
\begin{tikzpicture}[remember picture,overlay]
\node at (current page.center){\includegraphics[width=\paperwidth,height=\paperheight]{example-image}};
\end{tikzpicture}
}

\section{first part}
\begin{frame}{b}
\end{frame}

\end{document}

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.