1

After using a block with customized colors

\setbeamercolor{block title}{use=structure,fg=white,bg=red!75}
\setbeamercolor{block body}{use=structure,fg=black,bg=red!30}

How can you reset to the initial values of?

\frame
{
\frametitle{Hello}
\framesubtitle{Hi}
\setbeamercolor{block title}{use=structure,fg=white,bg=black}
\setbeamercolor{block body}{use=structure,fg=black,bg=gray!60}
\begin{block}{Say you will}
\begin{itemize}
  \item One
  \item Two
\end{itemize}
%  HOW TO RESET THE COLORS TO THE ORIGINAL VALUES
\end{block}
%
%
\begin{block}{Actividades}
\begin{enumerate}
\footnotesize{
  \item Me and you
  \item You and me  
}
\end{enumerate}
\end{block}
}
1
  • without testing: putting braces around that area should suffice – Bort Feb 4 '16 at 14:05
3

Simply put the colour modifications inside a {}

\documentclass{beamer}

\begin{document}

\frame
{
    \frametitle{Hello}
    \framesubtitle{Hi}

    {
    \setbeamercolor{block title}{use=structure,fg=white,bg=black}
    \setbeamercolor{block body}{use=structure,fg=black,bg=gray!60}
    \begin{block}{Say you will}
        \begin{itemize}
            \item One
            \item Two
        \end{itemize}
        %  HOW TO RESET THE COLORS TO THE ORIGINAL VALUES
    \end{block}
    }
    %
    %
    \begin{block}{Actividades}
        \begin{enumerate}
            \footnotesize{
                \item Me and you
                \item You and me  
            }
        \end{enumerate}
    \end{block}
}

\end{document}

enter image description here

3
  • but what you show is not the standard colours!! in the body the backgraound is ligth blue. Berkeley template. I don´t know the standard colours of block in the Bekeley template. – Mika Ike Feb 4 '16 at 14:09
  • 1
    @MikaIke The colors in samcarter's answer are the default one. You will have different ones if you use a color theme, but the point is that beamer colour modifications are local to {} group. – TonioElGringo Feb 4 '16 at 14:24
  • @MikaIke Well, I took all the information which was available in the incomplete example code in your question. But as TonioElGringo already stated, the colour theme should not have any influence on this solution. – samcarter_is_at_topanswers.xyz Feb 4 '16 at 15:17

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.