# Use several different fonts in latex beamer / change font for block title only

I want to use a specific font only for the headings. Does anybody know how to change the font (and I mean really the font, not only its appearance like bold, italic or so) for the beamer block title only?

In the code below I added an own block-environment where the font is selected manually. I would like to do the same for the default blocks (maybe the setbeamerfont command can be used for this but I have found no way to do so).

Furthermore, my own block has the deficit that it does not change its appearance according to the setbeamerfont command, i.e. if I select a bold font for the title, it changes the appearance of the ordinary block, but not my own one.

\documentclass[slidestop]{beamer}

\newenvironment<>{myblock}[1]{%
\begin{actionenv}#2%
\def\insertblocktitle{\fontfamily{LinuxLibertineO}\selectfont #1\par}%
\par%
\usebeamertemplate{block begin}}
{\par%
\usebeamertemplate{block end}%
\end{actionenv}}

\begin{document}

\setbeamerfont{block title}{series=\bfseries}

\begin{frame}{Test}
\begin{block}{The quick brown fox jumps}
Test
\end{block}
\begin{myblock}{The quick brown fox jumps}
Test
\end{myblock}
\end{frame}

\end{document}

-

Like so:

\documentclass{beamer}

\setbeamerfont{block title}{family={\fontfamily{ptm}} }

\begin{document}

\frame{
\begin{block}{in a block}
default font
\end{block}
}

\end{document}


You will find the commands used in the beamer guide. You could even use \setbeamerfont{block title}{family*={LinuxLibertineO}}.

-
Thank you for your help. However, I have problems to combine this with other font atributes like \setbeamerfont{block title}{family={\fontfamily{LinuxLibertineO}},shape=\itshape} does not work. Do you also know a fix for that? –  7asd44 Jan 20 '13 at 13:07