[Tex/LaTex] In Beamer, create a square with a number in it (like enumerate)

#enumeratebeamerlists

I have an enumerate environment with square icons, which gives me a colored square with a number inside for each item.

Below this, I have things I would like to visually correspond with these items. So I am looking to just make this same square with a number inside. Any ideas?

Edit: Here is a minimal working example:

\documentclass[mathserif,xcolor=svgnames]{beamer}
\setbeamertemplate{enumerate items}[square]
\begin{document}

\begin{frame}{Example}
 \begin{enumerate}
  \item Hello there
 \end{enumerate}
\end{frame}

\end{document}

Best Answer

The code for creating the boxes can be found in beamerbaseauxtemplates.sty. You can wrap it in a new command so you can use it outside enumerations:

\documentclass[mathserif,xcolor=svgnames]{beamer}
\setbeamertemplate{enumerate items}[square]
\begin{document}

\newcommand\boxednumber[1]
{%
  \hbox{%
    \usebeamerfont*{item projected}%
    \usebeamercolor[bg]{item projected}%
    \vrule width2.25ex height1.85ex depth.4ex%
    \hskip-2.25ex%
    \hbox to2.25ex{%
      \hfil%
      \color{fg}#1%
      \hfil}%
  }%
}

\begin{frame}{Example}
 \begin{enumerate}
  \item Hello there
 \end{enumerate}

Let's talk about item \boxednumber{1}
\end{frame}

\end{document}
Related Question