2015-06-16 08:13:19 +02:00
|
|
|
% \iffalse meta-comment -------------------------------------------------------
|
|
|
|
% Copyright 2015 Matthias Vogelgesang and the LaTeX community. A full list of
|
|
|
|
% contributors can be found at
|
2014-09-22 17:10:05 +02:00
|
|
|
%
|
2015-06-16 08:13:19 +02:00
|
|
|
% https://github.com/matze/mtheme/graphs/contributors
|
2014-09-22 17:10:05 +02:00
|
|
|
%
|
2015-06-16 08:13:19 +02:00
|
|
|
% and the original template was based on the HSRM theme by Benjamin Weiss.
|
2015-06-14 20:11:54 +02:00
|
|
|
%
|
2015-06-16 08:13:19 +02:00
|
|
|
% This work is licensed under a Creative Commons Attribution-ShareAlike 4.0
|
|
|
|
% International License (https://creativecommons.org/licenses/by-sa/4.0/).
|
|
|
|
% ------------------------------------------------------------------------- \fi
|
2015-06-14 20:11:54 +02:00
|
|
|
% \iffalse
|
2015-06-16 09:00:53 +02:00
|
|
|
%<driver> \ProvidesFile{beamercolorthememetropolis.dtx}
|
2015-06-14 20:11:54 +02:00
|
|
|
%<*package>
|
2015-06-16 09:00:53 +02:00
|
|
|
\NeedsTeXFormat{LaTeX2e}
|
|
|
|
\ProvidesPackage{beamercolorthememetropolis}
|
2015-06-16 17:14:05 +02:00
|
|
|
[2015/06/12 A Modern Beamer Color Theme]
|
2015-06-14 20:11:54 +02:00
|
|
|
%</package>
|
2015-06-16 09:00:53 +02:00
|
|
|
%<driver> \documentclass{ltxdoc}
|
|
|
|
%<driver> \usepackage{beamercolorthememetropolis}
|
|
|
|
%<driver> \begin{document}
|
|
|
|
%<driver> \DocInput{beamercolorthememetropolis.dtx}
|
|
|
|
%<driver> \end{document}
|
2015-06-14 20:11:54 +02:00
|
|
|
% \fi
|
|
|
|
% \CheckSum{0}
|
|
|
|
% \StopEventually{}
|
|
|
|
% \iffalse
|
|
|
|
%<*package>
|
2015-06-16 09:00:53 +02:00
|
|
|
% ------------------------------------------------------------------------- \fi
|
2015-06-18 09:28:05 +02:00
|
|
|
% \section{Implementation: \textsc{metropolis} color theme}
|
2015-06-10 09:42:12 +02:00
|
|
|
% Options
|
2015-06-14 20:11:54 +02:00
|
|
|
%
|
|
|
|
%
|
2015-06-15 13:44:06 +02:00
|
|
|
% darkcolors
|
|
|
|
%
|
|
|
|
% \begin{macrocode}
|
|
|
|
\newif\if@beamer@metropolis@darkcolors
|
|
|
|
\@beamer@metropolis@darkcolorsfalse
|
|
|
|
\DeclareOptionBeamer{darkcolors}{
|
|
|
|
\@beamer@metropolis@darkcolorstrue
|
|
|
|
}
|
|
|
|
% \end{macrocode}
|
|
|
|
%
|
2015-06-14 20:11:54 +02:00
|
|
|
% Unknown option error handling
|
|
|
|
%
|
|
|
|
% \begin{macrocode}
|
2015-01-29 05:13:06 +01:00
|
|
|
\DeclareOptionBeamer*{%
|
|
|
|
\PackageWarning{beamercolorthememetropolis}{Unknown option `\CurrentOption'}%
|
|
|
|
}
|
|
|
|
\ProcessOptionsBeamer
|
2015-06-14 20:11:54 +02:00
|
|
|
% \end{macrocode}
|
2015-06-10 09:42:12 +02:00
|
|
|
%
|
2015-06-22 07:24:49 +02:00
|
|
|
%
|
|
|
|
%
|
|
|
|
% \subsection{Base colors}
|
2015-06-10 09:42:12 +02:00
|
|
|
%
|
2015-06-14 20:11:54 +02:00
|
|
|
% \begin{macrocode}
|
2014-09-22 17:10:05 +02:00
|
|
|
\definecolor{mDarkBrown}{HTML}{604c38}
|
|
|
|
\definecolor{mDarkTeal}{HTML}{23373b}
|
|
|
|
\definecolor{mLightBrown}{HTML}{EB811B}
|
2015-06-10 17:32:27 +02:00
|
|
|
\definecolor{mLightGreen}{HTML}{14B03D}
|
2015-06-14 20:11:54 +02:00
|
|
|
% \end{macrocode}
|
2015-06-10 09:42:12 +02:00
|
|
|
%
|
2015-06-22 07:24:49 +02:00
|
|
|
%
|
|
|
|
%
|
|
|
|
% \subsection{Base styles}
|
|
|
|
%
|
|
|
|
% All colors in the \textsc{metropolis} theme are derived from the definitions
|
|
|
|
% of |normal text|, |alerted text|, and |example text|.
|
2015-06-10 09:42:12 +02:00
|
|
|
%
|
2015-06-14 20:11:54 +02:00
|
|
|
% \begin{macrocode}
|
2015-06-15 13:44:06 +02:00
|
|
|
\if@beamer@metropolis@darkcolors
|
|
|
|
\setbeamercolor{normal text}{%
|
|
|
|
fg=black!2,
|
|
|
|
bg=mDarkTeal
|
|
|
|
}
|
|
|
|
\else
|
|
|
|
\setbeamercolor{normal text}{%
|
|
|
|
fg=mDarkTeal,
|
|
|
|
bg=black!2
|
|
|
|
}
|
|
|
|
\fi
|
2015-06-10 09:42:12 +02:00
|
|
|
\setbeamercolor{alerted text}{%
|
|
|
|
fg=mLightBrown
|
|
|
|
}
|
2015-06-10 17:32:27 +02:00
|
|
|
\setbeamercolor{example text}{%
|
|
|
|
fg=mLightGreen
|
|
|
|
}
|
2015-06-14 20:11:54 +02:00
|
|
|
% \end{macrocode}
|
2015-06-11 00:01:00 +02:00
|
|
|
%
|
|
|
|
%
|
2015-06-14 20:11:54 +02:00
|
|
|
% \begin{macrocode}
|
|
|
|
% \end{macrocode}
|
|
|
|
%
|
2015-06-22 07:24:49 +02:00
|
|
|
%
|
|
|
|
%
|
|
|
|
% \subsection{Derived colors}
|
|
|
|
%
|
|
|
|
% The titles and structural elements (e.g. |itemize| bullets) are set in the
|
|
|
|
% same color as |normal text|. This would ideally done by setting |normal text|
|
|
|
|
% as a parent style, which we do to set |titlelike|, but this doesn't work for
|
|
|
|
% |structure| as its foreground is set explicitly in
|
|
|
|
% |beamercolorthemedefault.sty|.
|
2015-06-14 20:11:54 +02:00
|
|
|
%
|
|
|
|
% \begin{macrocode}
|
2015-06-22 07:24:49 +02:00
|
|
|
\setbeamercolor{titlelike}{%
|
|
|
|
use=normal text,
|
|
|
|
parent=normal text
|
|
|
|
}
|
|
|
|
\setbeamercolor{structure}{%
|
|
|
|
fg=normal text.fg
|
|
|
|
}
|
2015-06-14 20:11:54 +02:00
|
|
|
% \end{macrocode}
|
|
|
|
%
|
|
|
|
% The “primary” palette should be used for the most important navigational
|
2015-06-22 07:24:49 +02:00
|
|
|
% elements, and possibly of other elements. The \textsc{metropolis} theme uses
|
|
|
|
% it for frame titles and slides.
|
2015-06-14 20:11:54 +02:00
|
|
|
%
|
|
|
|
% \begin{macrocode}
|
2015-06-10 17:32:27 +02:00
|
|
|
\setbeamercolor{palette primary}{%
|
|
|
|
use=normal text,
|
|
|
|
fg=normal text.bg,
|
|
|
|
bg=normal text.fg
|
2015-06-10 09:42:12 +02:00
|
|
|
}
|
2015-06-22 07:24:49 +02:00
|
|
|
\setbeamercolor{frametitle}{%
|
|
|
|
use=palette primary,
|
|
|
|
parent=palette primary
|
|
|
|
}
|
2015-06-14 20:11:54 +02:00
|
|
|
% \end{macrocode}
|
|
|
|
%
|
2015-06-22 07:24:49 +02:00
|
|
|
% The \textsc{metropolis} inner or outer themes optionally display progress
|
|
|
|
% bars in various locations. Their color is set by |progress bar| but the two
|
|
|
|
% different kinds can be customized separately. The horizontal rule on the title
|
|
|
|
% page is also set based on the progress bar color and can be customized with
|
|
|
|
% |title separator|.
|
2015-06-14 20:11:54 +02:00
|
|
|
%
|
|
|
|
% \begin{macrocode}
|
2015-06-22 07:24:49 +02:00
|
|
|
\setbeamercolor{progress bar}{%
|
|
|
|
use=alerted text,
|
|
|
|
fg=alerted text.fg,
|
|
|
|
bg=normal text.bg!50!normal text.fg
|
|
|
|
}
|
2015-06-18 09:23:33 +02:00
|
|
|
\setbeamercolor{title separator}{
|
|
|
|
use=progress bar,
|
|
|
|
parent=progress bar
|
|
|
|
}
|
|
|
|
\setbeamercolor{progress bar in head/foot}{%
|
|
|
|
use=progress bar,
|
|
|
|
parent=progress bar
|
|
|
|
}
|
|
|
|
\setbeamercolor{progress bar in section page}{
|
|
|
|
use=progress bar,
|
|
|
|
parent=progress bar
|
|
|
|
}
|
2015-06-14 20:11:54 +02:00
|
|
|
% \end{macrocode}
|
|
|
|
%
|
2015-06-11 00:01:00 +02:00
|
|
|
% Blocks
|
2015-06-14 20:11:54 +02:00
|
|
|
%
|
|
|
|
% \begin{macrocode}
|
2015-01-29 05:13:06 +01:00
|
|
|
\if@beamer@metropolis@blockbg
|
2015-06-10 09:42:12 +02:00
|
|
|
\setbeamercolor{block title}{%
|
|
|
|
use=normal text,
|
|
|
|
fg=normal text.fg,
|
|
|
|
bg=normal text.bg!80!fg
|
|
|
|
}
|
|
|
|
\else
|
|
|
|
\setbeamercolor{block title}{use=normal text, parent=normal text}
|
|
|
|
\fi
|
|
|
|
\setbeamercolor{block title alerted}{%
|
|
|
|
use={block title, alerted text},
|
|
|
|
bg=block title.bg,
|
|
|
|
fg=alerted text.fg
|
|
|
|
}
|
|
|
|
\setbeamercolor{block title example}{%
|
|
|
|
use={block title, example text},
|
|
|
|
bg=block title.bg,
|
|
|
|
fg=example text.fg
|
|
|
|
}
|
2015-06-11 00:01:00 +02:00
|
|
|
\setbeamercolor{block body alerted}{use=block body, parent=block body}
|
|
|
|
\setbeamercolor{block body example}{use=block body, parent=block body}
|
|
|
|
\setbeamercolor{block body}{
|
|
|
|
use={block title, normal text},
|
|
|
|
bg=block title.bg!50!normal text.bg
|
|
|
|
}
|
2015-06-14 20:11:54 +02:00
|
|
|
% \end{macrocode}
|
|
|
|
%
|
2015-06-11 00:01:00 +02:00
|
|
|
% Footnotes
|
2015-06-14 20:11:54 +02:00
|
|
|
%
|
|
|
|
% \begin{macrocode}
|
2015-06-11 00:01:00 +02:00
|
|
|
\setbeamercolor{footnote}{fg=normal text.fg!90}
|
|
|
|
\setbeamercolor{footnote mark}{fg=.}
|
2015-01-29 23:18:55 +01:00
|
|
|
\mode<all>
|
2015-06-14 20:11:54 +02:00
|
|
|
% \end{macrocode}
|
2015-06-22 07:24:49 +02:00
|
|
|
%
|
|
|
|
%
|
2015-06-14 20:11:54 +02:00
|
|
|
%
|
|
|
|
% \iffalse
|
|
|
|
%</package>
|
|
|
|
% \fi
|
|
|
|
% \Finale
|
|
|
|
\endinput
|