diff options
author | Karl Berry <karl@freefriends.org> | 2022-05-30 20:05:28 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2022-05-30 20:05:28 +0000 |
commit | 8b38524142f4b0ed52b819dc06f677c98c4f6bc4 (patch) | |
tree | 79c1b66ed1f5fb104009b5e63d133b282e3b3b6f /Master/texmf-dist | |
parent | e2f9c0f49df6e2b1aa60fff5ed97c2502fdb673d (diff) |
beamerthemeamurmaple (30may22)
git-svn-id: svn://tug.org/texlive/trunk@63443 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r-- | Master/texmf-dist/doc/latex/beamerthemeamurmaple/LICENSE | 14 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/beamerthemeamurmaple/README.md | 30 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/beamerthemeamurmaple/beamer-amurmaple-doc.pdf | bin | 0 -> 348965 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/beamerthemeamurmaple/beamer-amurmaple-doc.tex | 577 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/beamerthemeamurmaple/logo.png | bin | 0 -> 170260 bytes | |||
-rw-r--r-- | Master/texmf-dist/tex/latex/beamerthemeamurmaple/beamerthemeAmurmaple.sty | 629 |
6 files changed, 1250 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/beamerthemeamurmaple/LICENSE b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/LICENSE new file mode 100644 index 00000000000..ffd12ae975a --- /dev/null +++ b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/LICENSE @@ -0,0 +1,14 @@ +Copyright 2022 Maxime CHUPIN + +This work may be distributed and/or modified under the +conditions of the LaTeX Project Public License, either version 1.3 +of this license or (at your option) any later version. +The latest version of this license is in + http://www.latex-project.org/lppl.txt +and version 1.3 or later is part of all distributions of LaTeX +version 2005/12/01 or later. + +This work has the LPPL maintenance status `maintained'. + +The Current Maintainer of this work is Maxime CHUPIN. + diff --git a/Master/texmf-dist/doc/latex/beamerthemeamurmaple/README.md b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/README.md new file mode 100644 index 00000000000..8ef8c1579d8 --- /dev/null +++ b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/README.md @@ -0,0 +1,30 @@ +# Amurmaple + +This Beamer theme is a suitable theme for my use of Beamer in applied mathematics research. It meets my needs in my work. However, if you like this theme, and if you want to ask for or make improvements, don’t hesitate to write to me ! + +## Use + +```latex +\usetheme{Amurmaple} +``` + +## Documentation + +See the [PDF file](doc/beamer-amurmaple-doc.pdf). + + +## Local installation + +Paste the file `beamerthemeAmurmaple.sty` in your local `~/texmf/tex/latex/contrib/beamer-contrib/themes/beamer-amurmaple/`. + +## Licence + +Copyright (C) 2022 by Maxime CHUPIN +<chupin at ceremade.dauphine.fr> + +This work may be distributed and/or modified under the conditions of the LaTeX Project Public License, either version 1.3 of this license or (at your option) any later version. The latest version of this license is in [http://www.latex-project.org/lppl.txt](http://www.latex-project.org/lppl.txt) and version 1.3 or later is part of all distributions of LaTeXversion 2005/12/01 or later. +% +## Author: +Maxime CHUPIN chupin at ceremade.dauphine.fr + +This work has the LPPL maintenance status "author-maintained". diff --git a/Master/texmf-dist/doc/latex/beamerthemeamurmaple/beamer-amurmaple-doc.pdf b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/beamer-amurmaple-doc.pdf Binary files differnew file mode 100644 index 00000000000..02313f5b23d --- /dev/null +++ b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/beamer-amurmaple-doc.pdf diff --git a/Master/texmf-dist/doc/latex/beamerthemeamurmaple/beamer-amurmaple-doc.tex b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/beamer-amurmaple-doc.tex new file mode 100644 index 00000000000..3b07affb7be --- /dev/null +++ b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/beamer-amurmaple-doc.tex @@ -0,0 +1,577 @@ +% Copyright (C) 2022 by Maxime CHUPIN +% <chupin at ceremade.dauphine.fr> +% ------------------------------------------------------- +% +% This work may be distributed and/or modified under the +% conditions of the LaTeX Project Public License, either version 1.3 +% of this license or (at your option) any later version. +% The latest version of this license is in +% http://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX +% version 2005/12/01 or later. +% +% Author: Maxime CHUPIN +% chupin at ceremade.dauphine.fr +% +% This work has the LPPL maintenance status "author-maintained". + +\documentclass[10pt,aspectratio=169,english]{beamer} +\usepackage[charter]{mathdesign} +\usepackage{hologo} +\usepackage{luamesh} + +\usepackage{babel} +\usepackage{pgfpages} +\usepackage{tcolorbox} +\usepackage{biblatex} +%\hypersetup{colorlinks=true} + +\tcbuselibrary{listings,breakable} +\tcbuselibrary{documentation} +\tcbset{ + color command=AmurmapleRed, + color environment=AmurmapleRed, + color option=AmurmapleGreen +} +\usetheme[ +%nogauge, +nomail, +delaunay, +%amurmapleblue +]{Amurmaple} + +\lstset{ + numberstyle=\footnotesize\color{gray}, + keywordstyle=\ttfamily\bfseries\color{structure}, + basicstyle=\ttfamily\normalsize, + commentstyle=\itshape\color{gray}, + stringstyle=\ttfamily, + showstringspaces=false, + language=[LaTeX]TeX, + breaklines=true, + breakindent=30pt, + defaultdialect=[LaTeX]TeX, + morekeywords={usetheme,definecolor, beamerbutton, beamerskipbutton, + beamerreturnbutton, structure, alert, sectionpage, mail, webpage, + collaboration, subtitle, institute, titlegraphic, sepframe, includegraphics, + thanksframe, inserttitlegraphic, framesection, boxalert,appendix} + % frame=tb +} + + +\newtcblisting{Code}{% + arc=0pt,outer arc=0pt, + colback=structure!3, + colframe=structure, + breakable, + boxsep=0pt,left=5pt,right=5pt,top=5pt,bottom=5pt, bottomtitle = + 3pt, toptitle=3pt, + boxrule=0pt,bottomrule=0.5pt,toprule=0.5pt, toprule at break = + 0pt, bottomrule at break = 0pt, + listing options={breaklines,basicstyle=\ttfamily},listing only, +} + +\newtcblisting{Exemple}{% + arc=0pt,outer arc=0pt, + colback=structure!3, + colframe=structure, + breakable, + boxsep=0pt,left=3pt,right=3pt,top=2pt,bottom=2pt, bottomtitle = + 0pt, toptitle=0pt, + boxrule=0pt,bottomrule=0.5pt,toprule=0.5pt, toprule at break = + 0pt, bottomrule at break = 0pt, + listing options={breaklines,basicstyle=\ttfamily}, +} + +\newtcblisting{CodePreambule}{% + arc=0pt,outer arc=0pt, + colback=AmurmapleBlue!5, + colframe=AmurmapleBlue, + breakable, + boxsep=0pt,left=5pt,right=5pt,top=5pt,bottom=5pt, bottomtitle = + 3pt, toptitle=3pt, + boxrule=0pt,bottomrule=0.5pt,toprule=0.5pt, toprule at break = + 0pt, bottomrule at break = 0pt, + enhanced, + overlay ={% + \node[ minimum width=1cm, + anchor=south east,yshift=-0cm,fill=AmurmapleBlue] at (frame.south east) + {\itshape\color{white} preamble}; + % \node[ minimum width=1cm, + % anchor=south east,yshift=-0cm,color=gray,opacity=0.7] at (frame.south east) + % {\itshape\small préambule}; + }, + listing options={ + breaklines, + basicstyle=\ttfamily, + },listing only, +} + + + + +\title[Amurmaple documentation]{Amurmaple Beamer Theme} +\author[M.~Chupin]{Maxime Chupin} +\subtitle{documentation\quad v.1.0} +\institute[CNRS]{CNRS\\ +University of Paris-Dauphine} +\date{Mai 28, 2022} +\titlegraphic{\includegraphics[width=4cm]{logo.png}} +\mail{chupin@ceremade.dauphine.fr} +\webpage{www.ceremade.dauphine.fr/~chupin/} +\collaboration{in collaboration with Beamer and \hologo{LaTeX3}} + +\bibliography{biblio.bib} +\usefonttheme{serif} + + + + + + +\begin{document} + +\maketitle + +\sepframe[title={Table of contents}] +\section{Introduction} + +\begin{frame}{Introduction} +\begin{information} +This Beamer theme is a suitable theme for my use of Beamer in applied +mathematics research. + +It meets my needs in my work. However, if you like this theme, and if you want +to ask for or make improvements, don't hesitate to write to me ! + +Obviously, we refer to the documentation of the Beamer class for details, and we +will assume in this little documentation that the reader is familiar with the +Beamer class. +\end{information} + +\end{frame} + + +\section{How to use it} + +\sepframe + +\begin{frame}[fragile]{How to use Amurmaple theme} + \begin{itemize} + \item The Amurmaple beamer theme consists in the file + \texttt{beamerthemeAmurmaple.sty} that you can put in your local + \texttt{\~{}/texmf/tex/latex/contrib/beamer-contrib/themes/beamer-amurmaple} + directory. + \item Simply add in your preamble\footnote{Note that the listing environments + of this document are not provided by Amurmaple theme.} + \begin{CodePreambule} +\documentclass{beamer} +\usetheme{Amurmaple} +\end{CodePreambule} +\item This theme depends on the following packages: + \begin{multicols}{2} + \begin{itemize} + \item \lstinline+tcolorbox+; + \item \lstinline+multicol+; + \item \lstinline+xparse+; + \item \lstinline+xfp+; + \item \lstinline+expl3+; + \item \lstinline+iftex+. + \end{itemize} +\end{multicols} +\end{itemize} +\end{frame} + +\subsection{Theme Options} + +\begin{frame}[fragile]{Theme Options} + There are some options available : + \begin{description} + \item[nogauge:] that suppresses the gauge at the top of the vertical side bar + of the current slide ; + \item[nomail:] that suppresses the mail in the vertical side bar of + the current slide ; + \item[delaunay:] that produces a Delaunay mesh of random points in + the ``structure'' slides (title, section, etc.). \alert{This option can only be + used with \hologo{LuaLaTeX}} and depends on the + package~\lstinline{luamesh}\footfullcite{Luamesh}; + \item[amurmapleblue:] that changes the main color (\lstinline+structure+) to a + certain blue (see slide~\ref{sl:color}) ; + \item[amurmaplegreen:] that changes the main color (\lstinline+structure+) to a + certain green (see slide~\ref{sl:color}); + \end{description} + For example, these slides are produced with the following call\footnote{We use + the \texttt{charter} font family of \texttt{mathdesign} with the serif Beamer theme.}: + \begin{CodePreambule} +\usetheme[nomail,delaunay]{Amurmaple} + \end{CodePreambule} +\end{frame} + + + +\section{Classical Beamer Tools} +\sepframe +\subsection{Colors} + +\begin{frame}[fragile, allowframebreaks]{Colors of the theme} + This theme provides some colors : + \begin{Code} +\definecolor{AmurmapleRed}{rgb}{0.6,0.,0.} +\definecolor{AmurmapleOrange}{RGB}{230,108,17} +\definecolor{AmurmapleBlue}{RGB}{55,119,231} +\definecolor{AmurmapleGreen}{rgb}{0.1,0.4,0.1} +\end{Code} + +\textcolor{AmurmapleRed}{\lstinline+AmurmapleRed+} is used to redefine the \lstinline+structure+ +Beamer color\footnote{So if you redefine the \lstinline+structure+ color, the Amurmaple +theme should change correctly.}, \textcolor{AmurmapleOrange}{\lstinline+AmurmapleOrange+} is used to redefine +the \lstinline+text alerted+ Beamer color, \textcolor{AmurmapleGreen}{\lstinline+AmurmapleGreen+} is +used for the math definition (see slide~\ref{sl:definition}) and for the +\lstinline+block title example+ Beamer color, and the +\textcolor{AmurmapleBlue}{\lstinline+AmurmapleBlue+} for the new environnement +\lstinline+information+ (see slide~\ref{sl:information}). +\framebreak + +\framesection{Color Theme Option}\label{sl:color} + +This theme provides two theme options to change the color settings: +\begin{description} +\item[amurmapleblue] that sets \texttt{AmurmapleBlue!80!black} as \texttt{structure} + color ; +\item[amurmaplegreen] that sets \texttt{AmurmapleGreen!80!black} as \texttt{structure} + color. +\end{description} +In fact, internally, four colors are defined: \lstinline+Amurmaple@structure+, +\lstinline+Amurmaple@alert+, \lstinline+Amurmaple@info+ and +\lstinline+Amurmaple@example+. + +The color theme option is used as follow +\begin{Code} + \usetheme[amurmapleblue]{amurmaple} +\end{Code} +\end{frame} + +\subsection{Classical commands} + +\begin{frame}[fragile]{Classical Beamer Commands} + \framesubtitle{Customization} + \framesection{Beamer buttons} + \begin{Exemple} +\beamerbutton{Button}~\beamerskipbutton{Skip Button}~\beamerreturnbutton{Return} +\end{Exemple} +\framesection{Alert and structure commands} +\begin{Exemple} +\structure{Test structure} \alert{Test alert} +\end{Exemple} +\end{frame} + +\begin{frame}[fragile]{Results of \texttt{$\backslash$tableofcontents}} + \tableofcontents +\end{frame} + +\subsection{Classical environnement} + +\begin{frame}[allowframebreaks,fragile]{Classical Beamer environments} + \framesection{Block environments} + \begin{block}{Block} + Test of the \lstinline+\begin{block}...\end{block}+ Beamer environment. + \end{block} + \begin{alertblock}{Alert Block} + Test of the \lstinline+\begin{alertblock}...\end{alertblock}+ Beamer environment. + \end{alertblock} + \begin{exampleblock}{Example Block} + Test of the \lstinline+\begin{exampleblock}...\end{exampleblock}+ Beamer environment. + \end{exampleblock} + + \framebreak + +\framesection{Abstract environment} + + \begin{abstract} + This is the result of the \lstinline+\begin{abstract}...\end{abstract}+ + environment. + \end{abstract} + + \framesection{Quotation environment} + + The environment \lstinline+\begin{quotation}[+\meta{author(s)}\lstinline+]...\end{quotation}+ has been + redefined allowing an optional argument to provide the author(s) of the + quotation. + + \begin{quotation}[Donald E. Knuth, \emph{The \TeX book}] +Gentle reader: This is a handbook about \TeX, a new typesetting system G +intended for the creation of beautiful books—and especially for books that +contain a lot of mathematics. +\end{quotation} + +\framebreak +\framesection{Lists} + +The style of the standard enumerate and itemize lists has been modified as you +can see below + +\begin{multicols}{2} + \begin{itemize} +\item Eggs +\item Plants + \begin{itemize} + \item Flowers + \end{itemize} +\item Animals +\end{itemize} +\columnbreak +\begin{enumerate} +\item Eggs +\item Plants +\item Animals + \begin{enumerate} + \item Dogs + \item Cats + \end{enumerate} +\end{enumerate} +\end{multicols} +\end{frame} + + +\subsection{Section and Part Frames} + +\newsavebox{\codebox}% To store any verbatim content +\begin{lrbox}{\codebox} + \begin{Code} +\begin{frame} +\sectionpage +\end{frame} + +%\begin{frame} +%\partpage +%\end{frame} +\end{Code} +\end{lrbox} + +\begin{frame}[fragile]{Section and Part Frames} + The standard \texttt{section page} and \texttt{part page} have been modified. + + The following code produce the next slide (the part slide is not generated + because this document does not use part sectionning). + + \usebox{\codebox} + +\end{frame} + +\begin{frame} +\sectionpage +\end{frame} + +\subsection{Maths} + +\begin{frame}[fragile,allowframebreaks]{Maths environnement} + \begin{itemize} + \item \lstinline+\begin{theorem}+\oarg{Title of th. (optional)}\lstinline+...\end{theorem}+ + \begin{theorem}[Title of th. (optional)] + There exists an infinite set. + \end{theorem} + \item \lstinline+\begin{example}...\end{example}+ + \begin{example} + The set of natural numbers is infinite. + \end{example} + \item \lstinline+\begin{definition}+\oarg{Title of def. (optional)}\lstinline+...\end{definition}+\label{sl:definition} + \begin{definition}[Title of def. (optional)] + A simple definition. + \end{definition} + \framebreak + \item \lstinline+\begin{corollary}+\oarg{Title of corollary (optional)}\lstinline+...\end{corollary}+ + \begin{corollary}[Title of corollary (optional)] + A simple corollary. + \end{corollary} + \item \lstinline+\begin{proof}...\end{proof}+ + \begin{proof} + This follows from the axiom of infinity. + \end{proof} + \end{itemize} +\end{frame} + + + +\section{Title Page} + +\sepframe + +\begin{frame}[fragile,allowframebreaks]{Title Page} + As shown in this document, the title page has been customized. + In addition to the classic commands for making the title page, the Amurmaple + theme provides new commands. + + The new commands are : + \begin{itemize} + \item \lstinline+\mail+\marg{mail}: that is used to provide the mail. Without the theme option + \lstinline+nomail+, it is also added on the vertical side bar on the current + slide. + \item \lstinline+\webpage+\marg{webpage}: that is used to provide the personal webpage of + the speaker (or the project website). + \item \lstinline+\collaboration+\marg{collaboration(s)}: that is used to provide the collaborators + for the presented work. + \end{itemize} + + \framebreak + + Here the example used to generate this documentation. + \begin{Code} +\title[Amurmaple documentation]{Amurmaple Beamer Theme} +\author[M.~Chupin]{Maxime Chupin} +\subtitle{documentation} +\institute[CNRS]{CNRS\\ +University of Paris-Dauphine} +\date{Mai 08, 2022} +\titlegraphic{\includegraphics[width=4cm]{logo.png}} +\mail{chupin@ceremade.dauphine.fr} +\webpage{www.ceremade.dauphine.fr/~chupin/} +\collaboration{in collaboration with Beamer and \hologo{LaTeX3}} +\end{Code} + +\end{frame} + +\section{New Frame Commands} + +\sepframe + +\begin{frame}[fragile]{\texttt{sepframe} command} +\bigskip +\begin{docCommand}{sepframe}{\oarg{title=\meta{mytitle},image=\meta{my image}}} +The newcommand \lstinline+\sepframe+ is provided by the Amurmaple theme. This +command allows you to generate a slide in the manner of a section page but with +a slight improvement. In the red part below is generated the table of contents +(with depth 1). + +Moreover, this command admits two optional arguments: +\begin{description} +\item[title:] this optional argument allows to modify the default title of the + frame (which is the current section name) ; +\item[image:] this optional argument allows to add an image to the frame (no + image by default). +\end{description} + +\end{docCommand} + + + +For exemple, we could use +\begin{Code} +\sepframe[title={My title},image={\includegraphics[width=5cm]{logo.png}}] +\end{Code} + +The result is the next frame. +\end{frame} + +\sepframe[title={My title},image={\includegraphics[width=5cm]{logo.png}}] + +\begin{frame}[fragile]{\texttt{thanksframe} command} + + \begin{docCommand}{thanksframe}{\marg{thanking message}} + The newcommand \lstinline+\thanksframe+ is provided by the Amurmaple + theme. This command allows you to generate a slide to thank the audience. + The text written to thank is a mandatory argument (e.g. ``\emph{The end}'') + and the optional argument allows to change the default image which is the + \emph{title graphics} (\lstinline+\inserttitlegraphic+ exactly). +\end{docCommand} +The following code produces the next slide. + \begin{Code} +\thanksframe{Merci beaucoup~!} + \end{Code} +\end{frame} + +\thanksframe{Merci beaucoup~!} + +\section{New Commands and Environments} + +\begin{frame}[fragile,allowframebreaks]{Some New Commands and Environments} + The Amurmaple theme provides some other commands and environments. + + \framesection{New Commands} + + \begin{docCommand}{framesection}{\marg{text}} + Command to add a section title inside a frame. + + The following example produced the previous frame sectioning \emph{New Commands} + \begin{Code} +\framesection{New Commands} +\end{Code} +\end{docCommand} +\begin{docCommand}{boxalert}{\marg{text}} +Another \lstinline+\alert+ command with a colored box. + \begin{Exemple} +\boxalert{This is another} command box to compare to \alert{this one}. + \end{Exemple} +\end{docCommand} +\framebreak + +\framesection{New Environments} +{\itshape \structure{Note:} Each environment provided by the Amurmaple theme uses +translations for title names. Hence, depending on the \texttt{babel} setting, +\emph{Remark} becomes \emph{Remarque, Bemerkung,}\dots} + +\begin{docEnvironment}{information}{\oarg{changed title}} + The Amurmaple theme provides an information environment.\label{sl:information} + \begin{Code} +\begin{information} + This is important information. +\end{information} + \end{Code} + \begin{information} + This is an important information. + \end{information} + + This environment has an optional argument to change the \emph{Information} + title. + \begin{Code} +\begin{information}[More information] + Maybe more important information? +\end{information} +\end{Code} + +\begin{information}[More information] + Maybe more important information? +\end{information} +Because this environment is built with a \texttt{tcolorbox}, to use a footnote in it, you have to use \lstinline+\footnote[frame]{...}+. +\end{docEnvironment} + +\begin{docEnvironment}{remark}{\oarg{title complement}} +The Amurmaple theme provides a remark environment with an optional + argument to add a comment in the title (as for the theorem environment). + \begin{Code} +\begin{remark}[Some complement] + This is a capital remark. +\end{remark} +\end{Code} +\begin{remark}[Some complement] + This is a capital remark. +\end{remark} + +Because this environment is built with a \texttt{tcolorbox}, to use a footnote in it, you have to use \lstinline+\footnote[frame]{...}+. +\end{docEnvironment} + +\end{frame} + +\appendix + +\section{Appendix} + +\sepframe + +\begin{frame}[fragile]{Appendix} + In the appendix part of the document, (after the command + \lstinline+\appendix+) the display is slightly modified as you + can see in this slide. If the gauge exists, it disappears, the numbering + of slides is reset and the display is in roman form. +\end{frame} + + +\thanksframe{The end!} + + + +\end{document} + +%%% Local Variables: +%%% mode: latex +%%% TeX-master: t +%%% End: diff --git a/Master/texmf-dist/doc/latex/beamerthemeamurmaple/logo.png b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/logo.png Binary files differnew file mode 100644 index 00000000000..687f327f420 --- /dev/null +++ b/Master/texmf-dist/doc/latex/beamerthemeamurmaple/logo.png diff --git a/Master/texmf-dist/tex/latex/beamerthemeamurmaple/beamerthemeAmurmaple.sty b/Master/texmf-dist/tex/latex/beamerthemeamurmaple/beamerthemeAmurmaple.sty new file mode 100644 index 00000000000..6167a9d3f77 --- /dev/null +++ b/Master/texmf-dist/tex/latex/beamerthemeamurmaple/beamerthemeAmurmaple.sty @@ -0,0 +1,629 @@ +% Copyright (C) 2022 by Maxime CHUPIN +% <chupin at ceremade.dauphine.fr> +% ------------------------------------------------------- +% +% This work may be distributed and/or modified under the +% conditions of the LaTeX Project Public License, either version 1.3 +% of this license or (at your option) any later version. +% The latest version of this license is in +% http://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX +% version 2005/12/01 or later. +% +% Author: Maxime CHUPIN +% chupin at ceremade.dauphine.fr +% +% This work has the LPPL maintenance status "author-maintained". + +\NeedsTeXFormat{LaTeX2e}[2021-11-15] +\ProvidesPackage{beamerthemeAmurmaple}[2022/05/28 v.1.0 Theme for the Beamer +class]% + +\newif\ifbeamer@nogauge +\beamer@nogaugetrue +\DeclareOptionBeamer{nogauge}{\beamer@nogaugefalse} +\newif\ifbeamer@nomail +\beamer@nomailtrue +\DeclareOptionBeamer{nomail}{\beamer@nomailfalse} +\newif\ifbeamer@delaunay +\beamer@delaunayfalse +\DeclareOptionBeamer{delaunay}{\beamer@delaunaytrue} +\newif\ifbeamer@amurmapleblue +\beamer@amurmaplebluefalse +\DeclareOptionBeamer{amurmapleblue}{\beamer@amurmaplebluetrue} +\newif\ifbeamer@amurmaplegreen +\beamer@amurmaplegreenfalse +\DeclareOptionBeamer{amurmaplegreen}{\beamer@amurmaplegreentrue} +\ProcessOptionsBeamer + +\RequirePackage{tcolorbox} +\RequirePackage{multicol} +\RequirePackage{xparse} +\RequirePackage{xfp} +\RequirePackage{expl3} +\RequirePackage{iftex} + + + +\ifbeamer@delaunay +\ifLuaTeX +\else +\errmessage{Delaunay option only available with luaLaTeX} +\fi +\fi + + +% dimensions +\ExplSyntaxOn +\dim_const:Nn \c_amurmaple_barre_dim { 15pt } +\dim_const:Nn \c_amurmaple_margin {10pt} +\tl_set:Nx \l_amurmaple_margin_left { \dim_eval:n { \c_amurmaple_barre_dim+\c_amurmaple_margin } } + +\setbeamersize +{ + text~ margin~ left=\l_amurmaple_margin_left, + text~ margin~ right=\c_amurmaple_margin +} +\ExplSyntaxOff + +\ifLuaTeX +\RequirePackage{luamesh} +\fi + +% randomseed +\ExplSyntaxOn +\sys_gset_rand_seed:n {\time} +\ExplSyntaxOff + +% counters to set the depth of toc in \sepframe +\newcounter{amurmapletoc} +\setcounter{amurmapletoc}{1} +\newcounter{amurmaple@oldtoc} + +\ExplSyntaxOn +% stores all students, separated by commas +\tl_new:N \l_amurmaple_mail_tl +\tl_new:N \l_amurmaple_webpage_tl +\tl_new:N \l_amurmaple_collab_tl + +\NewDocumentCommand{\mail}{m}{ + \tl_set:Nn \l_amurmaple_mail_tl {#1} +} + +\NewDocumentCommand{\webpage}{m}{ + \tl_set:Nn \l_amurmaple_webpage_tl {#1} +} + +\NewDocumentCommand{\collaboration}{m}{ + \tl_set:Nn \l_amurmaple_collab_tl {#1} +} + + +\NewDocumentCommand{\amurmaple@printmail}{}{ + \IfValueT { \l_amurmaple_mail_tl} { + \tl_use:N \l_amurmaple_mail_tl + } +} +\NewDocumentCommand{\amurmaple@printwebpage}{}{ + \IfValueT { \l_amurmaple_webpage_tl} { + \tl_use:N \l_amurmaple_webpage_tl + } +} +\ExplSyntaxOff +\mode<presentation> + +\useinnertheme{rectangles} + +\tcbuselibrary{skins} + + +\usefonttheme{professionalfonts} +\usetikzlibrary{backgrounds} +\usetikzlibrary{quotes,angles} +\usetikzlibrary{automata} +\usetikzlibrary{arrows} + +% some colors +\definecolor{AmurmapleRed}{rgb}{0.6,0.,0.} +\definecolor{AmurmapleOrange}{RGB}{230,108,17} +\definecolor{AmurmapleBlue}{RGB}{55,119,231} +\definecolor{AmurmapleGreen}{rgb}{0.1,0.4,0.1} + +\colorlet{Amurmaple@structure}{AmurmapleRed} +\colorlet{Amurmaple@alert}{AmurmapleOrange} +\colorlet{Amurmaple@info}{AmurmapleBlue} +\colorlet{Amurmaple@example}{AmurmapleGreen} +% +\ifbeamer@amurmapleblue +\colorlet{Amurmaple@structure}{AmurmapleBlue!80!black} +\colorlet{Amurmaple@alert}{AmurmapleOrange} +\colorlet{Amurmaple@info}{AmurmapleRed} +\colorlet{Amurmaple@example}{AmurmapleGreen} +\fi +\ifbeamer@amurmaplegreen +\colorlet{Amurmaple@structure}{AmurmapleGreen!80!black} +\colorlet{Amurmaple@alert}{AmurmapleOrange} +\colorlet{Amurmaple@info}{AmurmapleRed} +\colorlet{Amurmaple@example}{AmurmapleBlue} +\fi + +\setbeamercolor{structure}{fg=Amurmaple@structure} +\setbeamercolor{itemize item}{fg=structure!60} +\setbeamercolor{itemize subitem}{fg=structure!60} +\setbeamercolor{enumerate item}{bg=structure!60,fg=white} +\setbeamercolor{enumerate subitem}{fg=structure!60} +\setbeamercolor{block title}{fg=structure} +%\setbeamercolor{section in head/foot}{bg=Brown} +%\setbeamercolor{author in head/foot}{bg=Brown} +%\setbeamercolor{date in head/foot}{fg=Brown} +\setbeamercolor{alerted text}{fg=Amurmaple@alert,bg=Amurmaple@alert!20} +\setbeamercolor{subsection in toc}{fg=gray!70!black} +% new +\setbeamercolor{mail}{fg=structure!60} + +\setbeamertemplate{subsection in toc} + {\leavevmode\leftskip=2em\rule{0.6em}{0.6em}\hskip0.5em\inserttocsubsection\par} + + +\def\amurmaple@gauge{% + \def\pourc{\numexpr(10*\insertframenumber/\insertmainframenumber)}% + \def\xj{\numexpr(4.95*\pourc)} + %\resetcolorseries[9]{PiedDePage}% + \begin{tikzpicture}[x=0.7cm,y=0.7cm] + \draw[color=white] (-.1,-.1)--(1.6,-.1)--(1.6,.2)--(-.1,.2)--cycle; + \foreach \i in {0,...,10}{% + \ifnum\i<\pourc% + \fill[color=white]%PiedDePage!!+] + (0+0.15*\i,0)--(0.15+0.15*\i,0)--(0.15+0.15*\i,.1)--(0+0.15*\i,.1)--cycle; + \fi + } + \end{tikzpicture} +} + +% background +\ExplSyntaxOn +\setbeamertemplate{background}% +{% + \hypersetup{linkcolor=white} + \begin{tikzpicture}[remember~picture,overlay] + \fill[Amurmaple@structure] + (current~page.south~west) rectangle ([xshift=\c_amurmaple_barre_dim]current~ + page.north~west); + \node[anchor=north~west,rotate=90,color=white] at (current~page.south~west) + (title) {\scriptsize\insertshorttitle\quad---\quad \insertshortauthor + \ifbeamer@nomail + \quad \texttt{\amurmaple@printmail} + \fi + }; + \ifbeamer@nogauge + \ifnum\insertframenumber>\insertmainframenumber % gauge only in main part + \else + \node[anchor=north~east,rotate=90,color=white] at (current~page.north~west) + (gauge) {\amurmaple@gauge}; + \fi + \fi + \end{tikzpicture} +} +\ExplSyntaxOff +% +% +\setbeamertemplate{navigation symbols}{} +\newcounter{amurmaple@appendixframenumber} +\newcounter{amurmaple@appendixtotalframenumber} +\newcounter{amurmaple@numberofframes} +\newcounter{amurmaple@numberofmainframes} +\addtobeamertemplate{navigation symbols}{}{% + \hspace{1em}% + \setcounter{amurmaple@numberofframes}{\inserttotalframenumber} + \setcounter{amurmaple@numberofmainframes}{\insertmainframenumber} + \setcounter{amurmaple@appendixtotalframenumber}{\numexpr\value{amurmaple@numberofframes}-\value{amurmaple@numberofmainframes}} + \setcounter{amurmaple@appendixframenumber}{\numexpr\value{framenumber}-\value{amurmaple@numberofmainframes}} + \ifnum\insertframenumber>\insertmainframenumber% appendix + \footnotesize\color{black}\roman{amurmaple@appendixframenumber}/\roman{amurmaple@appendixtotalframenumber} + \else % main part + \footnotesize\color{black}\insertframenumber/\insertmainframenumber + \fi +} + +% TOC +\setbeamertemplate{section in toc}[square] +\setbeamercolor{section number projected}{bg=white,fg=structure} + + +% itemize enumerate +\setbeamertemplate{itemize item}{$\blacktriangleright$} +\setbeamertemplate{itemize subitem}{\small$\blacktriangleright$} +\setbeamertemplate{enumerate item} +{ + \hbox{% + \usebeamerfont*{item projected}% + \usebeamercolor[bg]{enumerate item}% original: [bg] + \vrule width2.25ex height1.85ex depth.4ex% + \hskip-2.25ex% + \hbox to2.25ex{% + \hfil% + \usebeamercolor[fg]{enumerate item}\insertenumlabel% original: [fg] + \hfil}% + }% +} +\setbeamertemplate{enumerate subitem}{\alph{enumii}.} + +% some fonts +\setbeamerfont{block title}{size=\bfseries} +\setbeamerfont{author}{size=\bfseries\large} +\setbeamerfont{institute}{size=\normalsize\itshape} +\setbeamerfont{title}{size=\huge\bfseries} +\setbeamerfont{date}{size=\footnotesize} +\setbeamerfont{subtitle}{size=\Large\normalfont\slshape} +% new +\setbeamerfont{mail}{size=\small\ttfamily} + +% title page +\ExplSyntaxOn +% list to get the points +\tl_new:N \l_delaunaypointlist_tl +\NewDocumentCommand\amurmaple@buildpoints{}{ + \tl_clear:N \l_delaunaypointlist_tl + \int_set:Nn \l_tmpa_int { 1 } + \tl_put_right:Nn \l_delaunaypointlist_tl {(0,0);(16,0);(16,4.5);(0,4.5);} + \int_do_while:nNnn { \l_tmpa_int} < {40} + { + \tl_put_right:Nn \l_delaunaypointlist_tl {(\fpeval{16*rand()},\fpeval{4.5*rand()});} + \int_incr:N \l_tmpa_int + } + \tl_put_right:Nn \l_delaunaypointlist_tl {(\fpeval{16*rand()},\fpeval{4.5*rand()})} +} + +\NewExpandableDocumentCommand\amurmaple@buildmesh{}{ +\node[anchor = north~west] at + ([xshift=-50pt,yshift=30pt]current~page.north~west){\resizebox{1.5\paperwidth}{0.8\paperheight}{\buildMeshBW[color=structure!15,colorBbox=structure!15,scale=2cm]{\l_delaunaypointlist_tl}}}; +} + +\setbeamertemplate{title~page}{% + \bgroup + \setbeamertemplate{background}% + {} + \begin{tikzpicture}[remember~picture,overlay] + \fill[white] + ([yshift=15pt]current~page.west) rectangle (current~page.north~ + east); + \ifbeamer@delaunay + \ifLuaTeX + \amurmaple@buildpoints + \amurmaple@buildmesh + \fi + \fi + \fill[structure] + ([yshift=15pt]current~page.west)~rectangle~(current~page.south~ + east); + \node[anchor=east]~ + at~([yshift=-35pt,xshift=-20pt]current~page.north~east)~(author)~ + {\parbox[t]{.6\paperwidth}{\raggedleft% + \usebeamerfont{author}\color{structure}% + \insertauthor + \IfValueT { \l_amurmaple_mail_tl} { + \par \usebeamerfont{mail}\usebeamercolor[fg]{mail} \tl_use:N \l_amurmaple_mail_tl + } + \IfValueT { \l_amurmaple_webpage_tl} { + \par \usebeamerfont{mail}\usebeamercolor[fg]{mail} \expandafter\url{\tl_use:N \l_amurmaple_webpage_tl} + } + }}; + \node[anchor=north~east] + at~([yshift=-60pt,xshift=-20pt]current~page.north~east) + (institute) + {\parbox[t]{.78\paperwidth}{\raggedleft% + \usebeamerfont{institute}\textcolor{gray}{\insertinstitute}}}; + \node[anchor=south~east] + at ([yshift=15pt,xshift=-20pt]current~page.east) + (date) + {\parbox[t]{.78\paperwidth}{\raggedleft% + \usebeamerfont{date}\textcolor{black}{\insertdate}}}; + \node[anchor=south~west] + at ([yshift=20pt]current~page.west)~(logo) + {\parbox[t]{.19\paperwidth}{\raggedleft% + \usebeamercolor[fg]{titlegraphic}\inserttitlegraphic}}; + \node[anchor=east] + at ([yshift=-25pt,xshift=-20pt]current~ + page.east) (title) + {\parbox[t]{\textwidth}{\raggedleft% + \usebeamerfont{title}\color{white}% + \inserttitle + \ifx\insertsubtitle\@empty% + \else\par\bigskip \usebeamerfont{subtitle}\color{white}\insertsubtitle + \fi + }}; + \IfValueT { \l_amurmaple_collab_tl} { + \node[anchor=south,white,text~width=0.95\linewidth,align=center] at ([yshift=10pt]current~page.south) {\itshape\tl_use:N \l_amurmaple_collab_tl}; + } +\end{tikzpicture} +\egroup +} +\ExplSyntaxOff + +\renewcommand{\maketitle}{% + \begingroup + \setbeamertemplate{background}% + {} + \setbeamertemplate{navigation symbols}{} + \setbeamercolor{background canvas}{bg=white} + \begin{frame}[noframenumbering,plain] + \titlepage + \end{frame} + \endgroup +} + +% section page +\setbeamertemplate{section page}{ + \hypersetup{linkcolor=structure} + \begin{tikzpicture}[remember picture,overlay] + \fill[white] + ([yshift=15pt]current page.west) rectangle (current page.north + east); + \ifbeamer@delaunay + \ifLuaTeX + \amurmaple@buildpoints + \amurmaple@buildmesh + \fi + \fi + \fill[structure] + ([yshift=15pt]current page.west) rectangle (current page.south + east); + \node[anchor=east, font=\huge, text width=0.95\linewidth,align=right] + at ([yshift=-50pt,xshift=-20pt]current page.north east) (section) + { Section \insertsectionnumber: \bfseries\textcolor{structure}{\insertsection}}; + \end{tikzpicture} +} + +% part page +\setbeamertemplate{part page}{ + \hypersetup{linkcolor=structure} + \begin{tikzpicture}[remember picture,overlay] + \fill[white] + ([yshift=15pt]current page.west) rectangle (current page.south + east); + \fill[structure] + ([yshift=15pt]current page.west) rectangle (current page.north + east); + + \node[anchor=north] + at ([yshift=-20pt]current page.north) (section) + {\Large\textcolor{white}{Part~\insertpartnumber}}; + \node[anchor=north, font=\huge\bfseries, text width=0.9\linewidth,align=center] + at ([yshift=-50pt]current page.north) (part) + {\textcolor{white}{\insertpart}}; + \end{tikzpicture} +} + + + +% frame title +\setbeamercolor{frametitle}{fg=structure} +\setbeamerfont{frametitle}{size=\bfseries\Large} +\setbeamertemplate{frametitle}{% + \raggedleft + \usebeamerfont{frametitle}\insertframetitle% + \vphantom{g}% To avoid fluctuations per frame + \par + \raggedleft + \vspace*{-0.3cm} + \rule{0.5\paperwidth}{2pt}\hspace*{-1cm}%% + \par + \raggedleft + \vspace*{-0.3cm}% + {\ifx\insertframesubtitle\@empty% + \else% + \usebeamerfont{framesubtitle}\insertframesubtitle% + \fi}% + \par +} + +%%%%%%%%%%%%%% +%%% commands +%%%%%%%%%%%%%% + +\newenvironment{boxalertenv}{\begin{altenv}% + {\usebeamertemplate{alerted text begin}\usebeamercolor[fg]{alerted text}\usebeamerfont{alerted text}\colorbox{bg}} + {\usebeamertemplate{alerted text end}}{\color{.}}{}}{\end{altenv}} + +\newcommand<>{\boxalert}[1]{{% + \begin{boxalertenv}#2{#1}\end{boxalertenv}% +}} + +% new one a subtitle inside a frame +\NewDocumentCommand{\framesection}{m}{ + \medskip + \noindent{\large\bfseries\textcolor{structure}{#1}}\par\vspace*{-0.2cm} + \hspace*{-0.5cm}{\color{structure}\rule{0.4\paperwidth}{2pt}}\par\smallskip% +} +% new one define a separation frame with a title and the TOC + +%% key/value +\ExplSyntaxOn +\keys_define:nn { amurmaple/sepframe } { + title .tl_set:N = \l_sepframetitle_tl , + image .tl_set:N = \l_sepframeimage_tl +} + +\NewDocumentCommand{\sepframe}{o}{ + % key/value + \IfNoValueF{#1}{ + \keys_set:nn { amurmaple/sepframe} {#1} + } + \begingroup + \setcounter{amurmaple@oldtoc}{\value{tocdepth}} + \setbeamercolor{section~in~toc}{fg=white} + \str_if_eq:VnTF{\l_sepframetitle_tl}{}{% + \def\amurmaple@septitle{\secname} + }{% + \def\amurmaple@septitle{\l_sepframetitle_tl} + } + \setbeamertemplate{background}{} + \setbeamertemplate{navigation~symbols}{} + \setbeamercolor{background~canvas}{bg=white} + \begin{frame}[noframenumbering,plain] + \begin{tikzpicture}[remember~picture,overlay] + \ifbeamer@delaunay + \ifLuaTeX + \amurmaple@buildpoints + \amurmaple@buildmesh + \fi + \fi + \fill[structure] + ([yshift=15pt]current~page.west) rectangle (current~page.south~ + east); + \node[anchor=east,text~width = 0.75\linewidth, font=\huge\bfseries,align=right] + at ([yshift=-50pt,xshift=-20pt]current~page.north~east) (section) + {\textcolor{structure}{\amurmaple@septitle}}; + \node[] + at ([yshift=-40pt]current~page.center) (toc) + {\color{white}\begin{minipage}{0.9\paperwidth}% + \begin{multicols}{2}\hypersetup{linkcolor=white}\setcounter{tocdepth}{\theamurmapletoc}\tableofcontents% + \end{multicols}\end{minipage} + }; + \str_if_eq:VnTF{\l_sepframeimage_tl}{}{% + }{ + \node[anchor=south~west] + at ([yshift=20pt]current~page.west) (logo) + {\parbox[t]{.19\paperwidth}{\raggedleft% + \usebeamercolor[fg]{titlegraphic}\l_sepframeimage_tl}}; + } + \end{tikzpicture} + \setcounter{tocdepth}{\value{amurmaple@oldtoc}} + \end{frame} + \endgroup + \tl_clear:N \l_sepframetitle_tl + \tl_clear:N \l_sepframeimage_tl +} + +\ExplSyntaxOff + + +% new one define a thanks frame with a simple message to thank +\NewDocumentCommand{\thanksframe}{o m}{ + \begingroup + \setbeamertemplate{background}{} + \setbeamertemplate{navigation symbols}{} + \setbeamercolor{background canvas}{bg=white} + \IfNoValueTF{#1}{% + \def\amurmaple@finalgraphic{\inserttitlegraphic} + }{% + \def\amurmaple@finalgraphic{#1} + } + \begin{frame}[noframenumbering,plain] + \begin{tikzpicture}[remember picture,overlay] + \ifbeamer@delaunay + \ifLuaTeX + \amurmaple@buildpoints + \amurmaple@buildmesh + \fi + \fi + \fill[structure] + ([yshift=15pt]current page.west) rectangle (current page.south + east); + \node[anchor=east,text width = 0.95\linewidth, font=\huge\bfseries,align=right] + at ([yshift=50pt,xshift=-20pt]current page.south east) (section) + {\textcolor{white}{#2}}; + \node[anchor=south west] + at ([yshift=20pt]current page.west) (logo) + {\parbox[t]{.19\paperwidth}{\raggedleft% + \usebeamercolor[fg]{titlegraphic}\amurmaple@finalgraphic}}; + \end{tikzpicture} + \end{frame} + \endgroup +} + + +\setbeamertemplate{button}{\tikz + \node[ + inner xsep=4pt, + minimum height = 2em, + draw=structure!80, + fill=structure!50, + rounded corners=1pt, + align=center] {\footnotesize\insertbuttontext};} + +\RenewDocumentEnvironment{abstract}{}{% + \begin{tcolorbox}[boxrule=0pt,frame hidden,sharp corners,enhanced,borderline + north={1pt}{0pt}{structure},borderline + south={1pt}{0pt}{structure}] + \begin{center}\bfseries + \abstractname + \end{center}\itshape + } + {% + \end{tcolorbox}% +}% + +\RenewDocumentEnvironment{quotation}{o}{% + \begin{tcolorbox}[boxrule=0pt,frame hidden,sharp corners,enhanced,borderline west={4pt}{0pt}{structure}]\itshape + } + {% + \IfNoValueTF{#1}{% + }{ + \begin{flushright} + \normalfont #1 + \end{flushright} + \end{tcolorbox}% + }% +} + +\newcommand\amurmaple@info{\raisebox{-1mm}{\tikz{\node[circle,fill=Amurmaple@info,align=center,text + width=1em,inner sep = 0.0mm] + {\rmfamily\itshape\bfseries\color{white} i};}}} + +\NewDocumentEnvironment{information}{o}{% + \tcbset{leftrule=1mm,rightrule=0mm,toprule=0mm, bottomrule=0mm,% + colframe=Amurmaple@info, + sharp corners, + detach title,% + before title={\amurmaple@info~}, + fonttitle = \color{black}\bfseries\sffamily, + before upper={\tcbtitle\par\medskip} + } + \IfNoValueTF{#1}{% + \begin{tcolorbox}[title=\translate{Information}] + }{ + \begin{tcolorbox}[title=#1] + } + }% + {% + \end{tcolorbox} + }% + + \NewDocumentEnvironment{remark}{o}{ + \tcbset{% + arc=0pt,outer arc=0pt,colback=gray!10!white,colframe=gray!60!white, + boxsep=0pt,left=10pt,right=10pt,top=8pt,bottom=10pt, bottomtitle = 3pt, toptitle=3pt, + boxrule=0pt,bottomrule=0.5pt,toprule=0.5pt + } + \smallskip + \begin{tcolorbox}[fonttitle=\bfseries,title={\translate{Remark} \IfNoValueF{#1}{(#1)}}]}% + {\end{tcolorbox}\medskip +} + + +%%%%%%%%%%%% maths + +\AtBeginEnvironment{theorem}{% + \setbeamercolor{block body}{fg=black,bg=gray!20} + \setbeamercolor{block title}{fg=white,bg=structure} +} + +\AtBeginEnvironment{definition}{% + \setbeamercolor{block body}{fg=black,bg=gray!10} + \setbeamercolor{block title}{fg=Amurmaple@example,bg=Amurmaple@example!40} +} + +\AtBeginEnvironment{corollary}{% + \setbeamercolor{block body}{fg=black,bg=gray!10} + \setbeamercolor{block title}{fg=structure,bg=structure!30} +} + + +\setbeamercolor{block title alerted}{use=structure,fg=white,bg=Amurmaple@alert} +\setbeamercolor{block body alerted}{parent=normal text,use=block + title,bg=gray!10} + +\setbeamercolor{block title example}{fg=Amurmaple@example} +\mode +<all>
\ No newline at end of file |