Tell me more ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I want to include a logo in my slides. I am using this:

\logo{\includegraphics[scale=0.05]{../../Logos/CMS_logo_black.png}}

but, due to some graphics are big, in some slides the main graphic overlays the logo.

How can I remove the logo from some slides but keep it in others?

Thanks,

share|improve this question

1 Answer

up vote 12 down vote accepted

There are two simple ways to do this:

With a conditional

You can create a conditional to insert the logo only if the condition is true, and then turn the logo on and off as needed.

\documentclass{beamer}
\newif\ifplacelogo % create a new conditional
\placelogotrue % set it to true
\logo{\ifplacelogo\color{red}\rule{.5cm}{.5cm}\fi} % replace with your own command
\begin{document}
\begin{frame}
   \frametitle{Test frame}
\end{frame}
\placelogofalse % turn the logo off (needs to be outside the {frame} environment)
\begin{frame}
   \frametitle{Test frame no logo}
\end{frame}
\placelogotrue % turn the logo back on for subsequent slides
\begin{frame}
   \frametitle{Test frame with logo again}
\end{frame}
\end{document}

With grouping and local redefinition

Another alternative, which doesn't require a conditional, would be to enclose the frame (or set of frames) in a group and redefine the logo template within the group.

\documentclass{beamer}

\logo{\color{red}\rule{.5cm}{.5cm}}
\newcommand{\nologo}{\setbeamertemplate{logo}{}} % command to set the logo to nothing
\title{A title}
\author{An author}

\begin{document}

\maketitle

\begin{frame}[t]\frametitle{Test frame}
\end{frame}

% must enclose the frame(s) without the logo in braces
% any number of frames can be within the group (here 2).

{\nologo
\begin{frame}\frametitle{Test frame no logo}
\end{frame}
\begin{frame}\frametitle{Another Test frame no logo}
\end{frame}
}

\begin{frame}\frametitle{Test frame with logo again}
\end{frame}
\end{document}
share|improve this answer
it works, Thanks Alan!!! – Alejandro Apr 30 '12 at 3:10

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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