How can I create a block in LaTeX Beamer in "Sandwich Style", i.e., that has both a title and a footer. Ideally, the background colors could even be different. Here is an illustration (with incorrect spacing):

Image that shows how it should (roughly) look like

  • 1
    I would love to see an answer with only beamer native code (no tcolorbox)
    – f.boc
    Nov 13, 2013 at 11:08

2 Answers 2


With tcolorbox is easy to make a sandwich box. This one uses bicolor skin. There also exists a beamer skin which produces more 'a la beamer' boxes, but I don't know how to set a different background color for lower text part like bicolor does.


\newtcolorbox{sandwich}[1]{bicolor, colframe=blue!75!black, colback=red!50!white, colbacklower=blue!75!black, collower=white,title=#1}

\begin{frame}{Sandwich box with tcolorbox}

\begin{sandwich}{Testing 1-2-3}
This is a text
Yet another text


enter image description here



To complete Ignasi's answer, it is possible produce more " a la Beamer " sandwich boxes rounding corners, removing the frame and adding shadows, or alternatively use a beamer skin and a bicolor skin together, in that order. The MWE show both cases:

\setbeamercolor*{block title example}{fg=red!50!black,bg= green!80!black!50}
\setbeamercolor*{block body example}{fg=green!20!black, bg= green!15}
\setbeamercolor*{block body alerted}{fg= orange!50!black, bg= orange!15}
\setbeamercolor*{block title alerted}{fg=yellow!50, bg= orange!50!red}

\begin {document}
\begin{frame}{Sandwich box a la Beamer}

\begin{exampleblock}{Example  block}Text\end{exampleblock}
\begin{alertblock}{Alert block}Text\end{alertblock}

% Without beamer skin: 

colback=block body alerted.bg,
colbacklower=block body example.bg,
collower=block title.bg,
colframe=block title.bg, %structure, %blue!75!black,
frame style={left color=block title.bg,
right color=block title example.bg!100!black},
% better shadow than beamer skin
fuzzy shadow={1mm}{-1mm}{-.25mm}{.5pt}{structure!20!black}% blue!30!black!80} 
,title=Testing 1-2-3]
A bicolor box
a la \dotfill \alert{no} Beamer mode 


% With beamer skin: 

beamer, % Warning: must be before of bicolor skin
colback=block body.bg,
colbacklower=block body example.bg,
collower=block body alerted.fg,
colupper=block body example.fg,
%colframe=block title.bg,
coltitle=block title alerted.fg,
frame style={draw=none,fill=none, left color=block title.bg, right color=block title.bg!70!black},
interior style={left color=block body alerted.bg, right color=block title alerted.bg},
,title=Testing 1-2-3]
A bicolor box
a la Beamer mode



As showed above, it is possible have 3 color and even gradients. I recommend to be cautious with this, using with moderation Beamer colours to be consistent with the rest of the presentation. Note that above code is only to show how to do, it is not intended to be an model of good taste (Get a elegant color scheme is a task for you.)

  • Thanks a lot for your indeed elegant answer. Do you know if there is a way to get the spacing exactly as with the classical beamer boxes? For example, the top right box has a caption with more height than the classical beamer box. Thanks!
    – DCTLib
    Nov 14, 2013 at 18:42
  • @Ruedi, try to add toptitle=-.5mm, bottomtitle=-1mm, as first options in each tcolorbox.
    – Fran
    Nov 14, 2013 at 19:07

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .