From 933330115b2b0eb0ae0e71e21f66977ac65d5790 Mon Sep 17 00:00:00 2001 From: Jan Benda Date: Thu, 4 Mar 2021 12:32:14 +0100 Subject: [PATCH] added symbol for message box --- beamercolorthemeut.sty | 1 + beamerthemelines.sty | 8 ++++++++ beamerthemeut.sty | 3 +++ lines-example.tex | 43 ++++++++++++++++++++++++++++-------------- ut-example.tex | 31 +++++++++++++++--------------- 5 files changed, 57 insertions(+), 29 deletions(-) diff --git a/beamercolorthemeut.sty b/beamercolorthemeut.sty index 62e36e9..4bc5cb1 100644 --- a/beamercolorthemeut.sty +++ b/beamercolorthemeut.sty @@ -74,6 +74,7 @@ \setbeamercolor{theorem line bottom}{fg=utorange} \setbeamercolor{message}{fg=white, bg=utred} +\setbeamercolor{message symbol}{fg=utgold} \setbeamercolor{section in toc}{parent={normal text}} \setbeamercolor{subsection in toc}{parent={normal text}} diff --git a/beamerthemelines.sty b/beamerthemelines.sty index 8ae62db..8209503 100644 --- a/beamerthemelines.sty +++ b/beamerthemelines.sty @@ -458,10 +458,17 @@ %%%%% new message box command: +\defbeamertemplate{message symbol}{default}{} +\defbeamertemplate{message symbol}{circle}{\raisebox{0.1ex}{$\bullet$}\thickspace} +\defbeamertemplate{message symbol}{arrow}{\itemarrow\thickspace} + +\setbeamertemplate{message symbol}[circle] + \defbeamertemplate{message}{default}{% \par\vskip\medskipamount% \usebeamerfont{message}% \begin{beamercolorbox}[wd=\columnwidth,ht=2.4ex,dp=0.9ex,leftskip=2mm,rightskip=2mm]{message} + {\usebeamercolor[fg]{message symbol}\usebeamertemplate{message symbol}}% \strut\insertmessage \end{beamercolorbox}} } @@ -476,6 +483,7 @@ \end{beamercolorbox} \nointerlineskip}% \begin{beamercolorbox}[wd=\columnwidth,ht=2.4ex,dp=0.9ex,leftskip=2mm,rightskip=2mm]{message} + {\usebeamercolor[fg]{message symbol}\usebeamertemplate{message symbol}}% \strut\insertmessage \end{beamercolorbox}} \nointerlineskip% diff --git a/beamerthemeut.sty b/beamerthemeut.sty index 35d661d..4fda49b 100644 --- a/beamerthemeut.sty +++ b/beamerthemeut.sty @@ -67,6 +67,9 @@ \setbeamertemplate{title page author and}[line] % space, comma, line, and \setbeamertemplate{title page institute and}[line] % default, space, comma, line +\setbeamertemplate{message symbol}[arrow] % default, circle, arrow +\setbeamertemplate{message}[lines]{0.5pt}{0.5pt} % default, lines + \setbeamertemplate{section name separator}[text][2pt] % space, text \setbeamertemplate{subsection name separator}[text][2pt] % space, text diff --git a/lines-example.tex b/lines-example.tex index decdd00..c1a3ae7 100644 --- a/lines-example.tex +++ b/lines-example.tex @@ -237,28 +237,41 @@ \end{block} \end{frame} -\begin{frame}{Block environments} +\begin{frame}[fragile]{Block environments with title} + ... add structure and color to a slide --- use them with care: \begin{block}{Some block} - Block with title and content: \texttt{block} environment with title as argument. - \end{block} - \begin{block}{} - Block with empty title. + Block with title and content\\ + \verb!\begin{block}{Some block}!\\ + \verb! Block with title and content!\\ + \verb!\end{block}! \end{block} \begin{alertblock}{Careful!} - Alert block with title and content: \texttt{alertblock} environment with title as argument. - \end{alertblock} - \begin{alertblock}{} - Alert block with empty title. + \texttt{alertblock} environment with title as argument. \end{alertblock} \begin{exampleblock}{Example} - Example block with title and content: \texttt{exampleblock} environment. + \texttt{exampleblock} environment with title as argument. \end{exampleblock} +\end{frame} + +\begin{frame}[fragile]{Block environments without title} + ... add color to a slide in a more subtle way: + \begin{block}{} + Block with empty title.\\ + \verb!\begin{block}{}!\\ + \verb! Block with empty title!\\ + \verb!\end{block}! + \end{block} + \begin{alertblock}{} + \texttt{alertblock} with empty title.\\ + And just some text. + \end{alertblock} \begin{exampleblock}{} - Example block with empty title. + \texttt{exampleblock} with empty title.\\ + And just some text. \end{exampleblock} \end{frame} -\begin{frame}{Theorems} +\begin{frame}{Theorems --- for mathematicians} \begin{theorem} \texttt{theorem} environment. \end{theorem} @@ -280,8 +293,10 @@ \end{proof} \end{frame} -\begin{frame}{Message box} - A new (non-beamer) command for highlighting important messages: +\begin{frame}[fragile]{Message box} + \begin{block}{A new (non-beamer) command for highlighting messages} + \verb!\messagebox{Take home message}! + \end{block} \vspace{5ex} \messagebox{Take home message} \vspace{5ex} diff --git a/ut-example.tex b/ut-example.tex index 43b5de3..e2afaca 100644 --- a/ut-example.tex +++ b/ut-example.tex @@ -153,10 +153,13 @@ Structural \structure{emphasis} is provided by the \verb!\structure{}! command. \end{frame} -\begin{frame}{Block environments with title} +\begin{frame}[fragile]{Block environments with title} ... add structure and color to a slide --- use them with care: \begin{block}{Some block} - \texttt{block} environment with title as argument. + Block with title and content\\ + \verb!\begin{block}{Some block}!\\ + \verb! Block with title and content!\\ + \verb!\end{block}! \end{block} \begin{alertblock}{Careful!} \texttt{alertblock} environment with title as argument. @@ -166,23 +169,25 @@ \end{exampleblock} \end{frame} -\begin{frame}{Block environments without title} +\begin{frame}[fragile]{Block environments without title} ... add color to a slide in a more subtle way: \begin{block}{} Block with empty title.\\ - And just some text. + \verb!\begin{block}{}!\\ + \verb! Block with empty title!\\ + \verb!\end{block}! \end{block} \begin{alertblock}{} - Alert block with empty title.\\ + \texttt{alertblock} with empty title.\\ And just some text. \end{alertblock} \begin{exampleblock}{} - Example block with empty title.\\ + \texttt{exampleblock} with empty title.\\ And just some text. \end{exampleblock} \end{frame} -\begin{frame}{Theorems} +\begin{frame}{Theorems --- for mathematicians} \begin{theorem} \texttt{theorem} environment. \end{theorem} @@ -199,8 +204,10 @@ \end{proof} \end{frame} -\begin{frame}{Message box} - A new (non-beamer) command for highlighting important messages: +\begin{frame}[fragile]{Message box} + \begin{block}{A new (non-beamer) command for highlighting messages} + \verb!\messagebox{Take home message}! + \end{block} \vspace{5ex} \messagebox{Take home message} \vspace{5ex} @@ -348,12 +355,6 @@ \end{itemize} \end{frame} -\begin{frame}{More resources} - \begin{block}{Beamer appearance cheat sheet} - \url{http://www.cpt.univ-mrs.fr/~masson/latex/Beamer-appearance-cheat-sheet.pdf} - \end{block} -\end{frame} - \end{document} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%