GeneralEnvironment colorblock: How to set the TITLE always in BOLD

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
corderin
Posts: 77
Joined: Sun Dec 14, 2008 2:27 pm

Environment colorblock: How to set the TITLE always in BOLD

Post by corderin »

This is my defined environment for colored blocks, where the colors are passed as arguments.

\documentclass[xcolor=svgnames]{beamer}


\usetheme{PaloAlto}
\usepackage[ansinew]{inputenc}
\usepackage[spanish]{babel}
\usepackage[T1]{fontenc}
\usepackage{cmbright}
\usepackage{fancybox}
%
\setbeamercolor{yellow}{fg=black,bg=yellow}
\setbeamercolor{lightyellow}{fg=black,bg=yellow!40}
\setbeamercolor{orange}{fg=black,bg=orange}
\setbeamercolor{lightorange}{fg=black,bg=orange!40}
%\setbeamercolor{item}{fg=yellow,bg=yellow}

\newenvironment{colorblock}[2]
{\setbeamercolor{item}{fg=#1,bg=#1}\begin{beamerboxesrounded}[upper=#1,lower=#2,shadow=true]}
{\end{beamerboxesrounded}}


\begin{document}

\begin{frame}

\begin{colorblock}{yellow}{lightyellow}{Title}
\begin{itemize}
\item First
\end{itemize}
\end{colorblock}
\begin{colorblock}{orange}{lightorange}{Title}
\begin{itemize}
\item First
\end{itemize}
\end{colorblock}

\end{frame}

\end{document}
Now I want to set the Title always BOLD, but I would like to define that on the environment, this way I won´t have to typ always something like that to get my BOLD TITLE:
\begin{colorblock}{orange}{lightorange}{\bfseriesTitle}

\end{colorblock}

Could somebody help me?

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

Post Reply