summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/modernposter
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-01-02 23:19:40 +0000
committerKarl Berry <karl@freefriends.org>2018-01-02 23:19:40 +0000
commit9158dbdb39e37a9bc2fb3f0814ca198a3f5444ac (patch)
tree80dbc578a712cec2d3954fdfa62df3f0f85ee829 /Master/texmf-dist/tex/latex/modernposter
parent685cec803afc9aea54127325a7dc839ba9e7a563 (diff)
modernposter (2jan18)
git-svn-id: svn://tug.org/texlive/trunk@46193 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/modernposter')
-rw-r--r--Master/texmf-dist/tex/latex/modernposter/modernposter.cls234
1 files changed, 234 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/modernposter/modernposter.cls b/Master/texmf-dist/tex/latex/modernposter/modernposter.cls
new file mode 100644
index 00000000000..3db991199b7
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/modernposter/modernposter.cls
@@ -0,0 +1,234 @@
+% modernposter.cls
+%
+% This file is part of the modernposter LaTeX template
+%
+% Version 1.01.2 2018/01/02
+%
+% Copyright 2018 David Derler
+%
+% This work is licensed under the Creative Commons Attribution-ShareAlike 4.0
+% International license (cf. https://creativecommons.org/licenses/by-sa/4.0/)
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesClass{modernposter}[2018/01/02 v1.01.2 Modern poster template. Inspired by metropolis beamer template.]
+
+\LoadClass[portrait]{a0poster}
+
+%------------------------------------------------------------------------------
+% Color definitions
+%------------------------------------------------------------------------------
+\RequirePackage{xcolor}
+
+\definecolor{c1}{HTML}{CB4B16}
+\definecolor{c2}{HTML}{586E75}
+\definecolor{c3}{HTML}{6C71C4}
+\definecolor{c4}{HTML}{D33682}
+\definecolor{c5}{HTML}{268BD2}
+\definecolor{c6}{HTML}{B58900}
+\definecolor{c7}{HTML}{859900}
+\definecolor{c8}{HTML}{DC322F}
+\definecolor{c9}{HTML}{002B36}
+\definecolor{c10}{HTML}{FF8000}
+
+\definecolor{mDarkTeal}{HTML}{23373b}
+\definecolor{mDarkBrown}{HTML}{604c38}
+
+\newcommand{\orange}[1]{\textcolor{c10}{#1}}
+\newcommand{\gray}[1]{\textcolor{c2}{#1}}
+\newcommand{\purple}[1]{\textcolor{c3}{#1}}
+\newcommand{\pink}[1]{\textcolor{c4}{#1}}
+\newcommand{\blue}[1]{\textcolor{c5}{#1}}
+\newcommand{\yellow}[1]{\textcolor{c6}{#1}}
+\newcommand{\green}[1]{\textcolor{c7}{#1}}
+\newcommand{\red}[1]{\textcolor{c8}{#1}}
+\newcommand{\black}[1]{\textcolor{c9}{#1}
+
+}
+
+%------------------------------------------------------------------------------
+% Options
+%------------------------------------------------------------------------------
+\RequirePackage{pgfkeys}
+\RequirePackage{pgfopts}
+
+
+\pgfkeys{/modernposter/.cd,
+ hlcolor/.store in=\modernposter@hlcolor,
+ logo/.store in=\modernposter@logo,
+ hlcolor=FF8000,
+ logo=none}
+
+\ProcessPgfOptions{/modernposter}
+
+\definecolor{hlcol}{HTML}{\modernposter@hlcolor}
+
+\newcommand{\highlight}[1]{\textcolor{hlcol}{#1}}
+
+%------------------------------------------------------------------------------
+% Lengths and sizes
+%------------------------------------------------------------------------------
+\RequirePackage{relsize}
+
+\newlength{\colheight}
+\newlength{\colwidth}
+\newlength{\coltextwidth}
+\newlength{\colsep}
+\newlength{\boxheight}
+\newlength{\boxlinewidth}
+
+%------------------------------------------------------------------------------
+% Tikz stuff
+%------------------------------------------------------------------------------
+\RequirePackage{tikz}
+\usetikzlibrary{positioning, backgrounds, shapes.misc}
+
+%------------------------------------------------------------------------------
+% Style
+%------------------------------------------------------------------------------
+\RequirePackage{enumitem}
+\RequirePackage{fontawesome}
+\RequirePackage{sfmath}
+\setlength{\itemindent}{10in}
+\setlist[itemize]{leftmargin=1in}
+\setlist[enumerate]{leftmargin=1in}
+
+\let\oldparboxrestore\@arrayparboxrestore
+\renewcommand{\@arrayparboxrestore}{
+ \oldparboxrestore
+ \makeatletter
+ \parskip0.4em
+ \makeatother
+ }
+
+\let\faiconold\faicon
+\renewcommand{\faicon}[1]{{\rmfamily \faiconold{#1}}}
+
+\renewcommand{\labelitemi}{$\bullet$~~}
+\renewcommand{\labelitemii}{\faicon{angle-right}~~}
+
+\RequirePackage[light,sfdefault]{FiraSans}
+
+%------------------------------------------------------------------------------
+% Begin/End Document commands
+%------------------------------------------------------------------------------
+\RequirePackage{etoolbox}
+\AfterEndPreamble{
+ \setlength{\colheight}{111.6em}
+ \setlength{\colwidth}{\dimexpr0.4525\linewidth\relax}
+ \setlength{\coltextwidth}{\dimexpr\colwidth-2em\relax}
+ \setlength{\colsep}{\dimexpr0.01\linewidth\relax}
+ \setlength{\boxheight}{\dimexpr0.33\colheight\relax}
+ \setlength{\boxlinewidth}{1mm}
+ \begin{tikzpicture}[remember picture,
+ overlay,
+ every node/.style={inner sep=0,outer sep=0}]
+}
+
+\AtBeginDocument{
+ \makeatletter
+ \def\bfseries@sf{m}
+ \SetSymbolFont{operators}{normal}{\math@encoding}{\math@sfdefault}{l}{n}
+ \SetSymbolFont{operators}{bold}{\math@encoding}{\math@sfdefault}{m}{n}
+ \DeclareSymbolFont{SFMath}{\math@encoding}{\math@sfdefault}{l}{sl}
+ \SetSymbolFont{SFMath}{normal}{\math@encoding}{\math@sfdefault}{l}{sl}
+ \SetSymbolFont{SFMath}{bold}{\math@encoding}{\math@sfdefault}{m}{\mathnormal@bold@shape}
+ \makeatother
+}
+
+\AtEndDocument{
+ \end{tikzpicture}
+}
+
+%------------------------------------------------------------------------------
+% Title commands
+%------------------------------------------------------------------------------
+\RequirePackage[hidelinks]{hyperref}
+\RequirePackage{xifthen,xstring}
+
+\def\@email{}
+\newcommand{\email}[1]{\def\@email{#1}}
+
+\renewcommand{\maketitle}{
+ \node[text height=\paperheight,
+ text width=\paperwidth,
+ fill=black!10,
+ anchor=north west] at (current page.north west)
+ {};
+ \node[text height=15em,
+ text width=\paperwidth-15em,
+ fill=mDarkTeal,
+ anchor=north west] (header) at (current page.north west)
+ {};
+ \node[text width=\paperwidth,
+ text height=0.15em,
+ fill=hlcol,
+ yshift=-15em] (sep) at (current page.north)
+ {};
+ \expandafter\ifstrequal\expandafter{\modernposter@logo}{none}{}{
+ \node[anchor=west,
+ xshift=1em] (logo) at (header.east)
+ {\includegraphics[width=13em]{\modernposter@logo}};
+ }
+ \node[anchor=east,
+ yshift=3.4em,
+ xshift=-2.5em] (title) at (header.east)
+ {\veryHuge \color{white} \bf \@title};
+ \node[anchor=east,
+ yshift=-0.8em,
+ xshift=-2.5em] (authors) at (header.east)
+ {\veryHuge\smaller\smaller \color{white} \bf \@author};
+ \node[anchor=east,
+ yshift=-4.3em,
+ xshift=-2.5em] (email) at (header.east)
+ {\veryHuge\smaller\smaller \color{white} \bf\tt \href{mailto:\@email}{\@email}};
+}
+
+%------------------------------------------------------------------------------
+% Poster commands
+%------------------------------------------------------------------------------
+\RequirePackage{environ}
+
+\newcounter{numcols}
+\NewEnviron{postercolumn}{
+ \ifnum\value{numcols}=0
+ \node[text width=\colwidth,
+ xshift=4em,
+ below=3em of sep.west,
+ anchor=north west] (col1)
+ {~\\[\colsep]\BODY};
+ \else
+ \node[text width=\colwidth,
+ xshift=\colsep,
+ anchor=north west] at (col1.north east)
+ {~\\[\colsep]\BODY};
+ \fi
+ \stepcounter{numcols}
+}
+
+\newcommand{\posterbox}[3][\boxheight]{
+ \begin{tikzpicture}
+ \node[text width=\colwidth,
+ minimum height=#1,
+ rounded corners,
+ line width=\boxlinewidth,
+ draw=mDarkTeal,
+ fill=black!2] (content)
+ {};
+ \node[anchor=north west,
+ yshift=-6.2em,
+ xshift=1em] at (content.north west)
+ {\Large\parbox{\coltextwidth}{#3~}};
+ \node[text width=\colwidth,
+ fill=mDarkTeal,
+ text depth=1.4em,
+ text height=4em,
+ rounded corners,
+ align=center,
+ anchor=north west] (heading) at (content.north west)
+ {\Huge{\color{white} ~~\bf #2}};
+ \end{tikzpicture}\\[\colsep]
+}
+
+\newcommand{\doubleposterbox}[5][0.6]{
+ \posterbox[#1\boxheight]{#2}{#3}
+ \posterbox[\boxheight-#1\boxheight-\colsep-1.33\boxlinewidth]{#4}{#5}
+} \ No newline at end of file