commit 2387651038885b875a5c5d073e17bfd555dde405 Author: Niklas Birk Date: Thu May 12 02:16:27 2022 +0200 First commit diff --git a/beamercolorthemeNik.sty b/beamercolorthemeNik.sty new file mode 100644 index 0000000..d74ade4 --- /dev/null +++ b/beamercolorthemeNik.sty @@ -0,0 +1,100 @@ +\mode + +% define colors +\definecolor{DraculaBackground}{HTML}{282a36} +\definecolor{DraculaCurrentLine}{HTML}{44475a} +\definecolor{DraculaSelection}{HTML}{44475a} +\definecolor{DraculaForeground}{HTML}{f8f8f2} +\definecolor{DraculaComment}{HTML}{6272a4} + +\definecolor{DraculaCyan}{HTML}{8be9fd} +\definecolor{DraculaGreen}{HTML}{50fa7b} +\definecolor{DraculaOrange}{HTML}{ffb86c} +\definecolor{DraculaPink}{HTML}{ff79c6} +\definecolor{DraculaPurple}{HTML}{bd93f9} +\definecolor{DraculaRed}{HTML}{ff5555} +\definecolor{DraculaYellow}{HTML}{f1fa8c} + +% define color variables +\colorlet{ColorAlertedText}{DraculaRed} +\colorlet{ColorSubtitle}{DraculaPurple} +\colorlet{ColorSubsectionInToc}{ColorSubtitle} + +\colorlet{ColorBackground}{DraculaBackground} +\colorlet{ColorText}{DraculaForeground} +\colorlet{ColorExampleText}{DraculaCyan} +\colorlet{ColorStructure}{DraculaCyan} +\colorlet{ColorTitle}{DraculaGreen} +\colorlet{ColorSubsectionInTocShaded}{DraculaComment!20!DraculaCurrentLine} + +\colorlet{ColorItemizeItem}{DraculaGreen} + +%% block color +%%% normal block +\colorlet{ColorBlockTitleBg}{DraculaCurrentLine!80} +\colorlet{ColorBlockBodyBg}{DraculaPurple!50!DraculaCurrentLine} +\colorlet{ColorBlockBodyFg}{DraculaCyan} + +%%% example block +\colorlet{ColorExampleBlockTitleBg}{ColorBlockTitleBg} +\colorlet{ColorExampleBlockBodyBg}{DraculaCyan!50!DraculaCurrentLine} +\colorlet{ColorExampleBlockBodyFg}{DraculaForeground} + +%%% alerted block +\colorlet{ColorAlertedBlockTitleBg}{ColorBlockTitleBg} +\colorlet{ColorAlertedBlockBodyBg}{DraculaRed!50!DraculaCurrentLine} +\colorlet{ColorAlertedBlockBodyFg}{DraculaForeground} + + +\colorlet{ColorNormalText}{ColorText} +\colorlet{ColorFrameTitle}{ColorTitle} +\colorlet{ColorFrameSubtitle}{ColorSubtitle} +\colorlet{ColorSectionInToc}{ColorTitle} +\colorlet{ColorEnumerateColor}{ColorItemizeItem} +\colorlet{ColorSectionInHeadFoot}{ColorStructure} + +% set beamer color +\setbeamercolor*{background canvas}{bg=ColorBackground} +\setbeamercolor*{normal text}{fg=ColorNormalText} +\setbeamercolor*{alerted text}{fg=ColorAlertedText} +\setbeamercolor*{example text}{fg=ColorExampleText} +\setbeamercolor*{structure}{fg=ColorStructure} + +% title colors +\setbeamercolor*{title}{fg=ColorTitle} +\setbeamercolor*{subtitle}{fg=ColorSubtitle} + +\setbeamercolor*{frametitle}{fg=ColorFrameTitle} +\setbeamercolor*{framesubtitle}{fg=ColorFrameSubtitle} + +% section colors +\setbeamercolor*{section in toc}{fg=ColorSectionInToc} + +\setbeamercolor*{subsection in toc}{fg=ColorSubsectionInToc} +\setbeamercolor*{subsection in toc shaded}{fg=ColorSubsectionInTocShaded} + +\setbeamercolor*{subsubsection in toc}{fg=ColorSubsectionInToc} +\setbeamercolor*{subsubsection in toc shaded}{fg=ColorSubsectionInTocShaded} + +% item colors +\setbeamercolor*{itemize item}{fg=ColorItemizeItem} +\setbeamercolor*{enumerate item}{fg=ColorEnumerateColor} + +\setbeamercolor*{section in head/foot}{bg=ColorBackground, fg=ColorSectionInHeadFoot} + +% block color +\setbeamercolor{block title}{bg=ColorBlockTitleBg,fg=DraculaYellow} +\setbeamercolor{block body}{bg=ColorBlockBodyBg,fg=ColorBlockBodyFg} + +\setbeamercolor{block title example}{bg=ColorExampleBlockTitleBg,fg=DraculaYellow,parent={example text}} +\setbeamercolor{block body example}{bg=ColorExampleBlockBodyBg,fg=ColorExampleBlockBodyFg} + +\setbeamercolor{block title alerted}{bg=ColorAlertedBlockTitleBg,fg=DraculaOrange,parent={alerted text}} +\setbeamercolor{block body alerted}{bg=ColorAlertedBlockBodyBg,fg=ColorAlertedBlockBodyFg} + +\setbeamercolor{caption}{fg=DraculaPink} + +\mode + + +\endinput diff --git a/beamerfontthemeNik.sty b/beamerfontthemeNik.sty new file mode 100644 index 0000000..1672c7e --- /dev/null +++ b/beamerfontthemeNik.sty @@ -0,0 +1,24 @@ +\mode + +% fonts + +\setbeamerfont{structure}{family=\rmfamily,series=\bfseries} + +\setbeamerfont{title}{size=\Huge,parent=structure} +\setbeamerfont{subtitle}{size=\Large,parent=title} + +\setbeamerfont{section in toc}{size=\Large,parent=structure} +\setbeamerfont{section in head/foot}{size=\tiny,parent=structure} +\setbeamerfont{subsection in toc}{size=\large,parent={section in toc}} + +\setbeamerfont{frametitle}{parent=structure,size=\Large} +\setbeamerfont{framesubtitle}{parent=frametitle,size=\large} + +\setbeamerfont{caption}{size=\footnotesize} + +\setbeamerfont{block title}{size=\normalsize,series=\mdseries,parent={structure,block body}} + +\setbeamerfont{item}{parent=structure,series=\mdseries} + +\mode + diff --git a/beamerthemeNik.sty b/beamerthemeNik.sty new file mode 100644 index 0000000..76babda --- /dev/null +++ b/beamerthemeNik.sty @@ -0,0 +1,77 @@ +\ProvidesPackage{beamerthemeNik}[2022/05/11 v0.1 A simple beamer theme using Dracula color scheme for my own needs] + +\mode + +\RequirePackage{ifthen} + +\usecolortheme{Nik} +\usefonttheme{Nik} + +\setbeamertemplate{navigation symbols}{} + +\setbeamersize{text margin left=10mm,text margin right=10mm} + +\setbeamertemplate{caption}{\insertcaption} + +\setbeamertemplate{itemize item}{$\ast$} +\setbeamertemplate{itemize subitem}{$\ast$} +\setbeamertemplate{itemize subsubitem}{$\ast$} + +\setbeamertemplate{frametitle}{ + {\usebeamercolor[fg]{normal text} \mdseries >> }~\boldmath\insertframetitle% + \hfill\ifx\insertframesubtitle\@empty\else{\usebeamerfont{framesubtitle}\usebeamercolor[fg]{framesubtitle}\insertframesubtitle}\fi +} +\setbeamertemplate{frametitle continuation}[from second][\insertcontinuationtext] +\setbeamertemplate{headline} +{% +\begin{beamercolorbox}{section in head/foot} + \vskip2pt\insertnavigation{\paperwidth}\vskip5pt +\end{beamercolorbox}% +} +\setbeamertemplate{footline}{ + \newbox\nord@tmpbox + \vskip0.3cm + \hskip0.3cm + \insertauthor $\qquad$ \insertdate $\qquad$ \insertinstitute + \setbox\nord@tmpbox\hbox{[\insertframenumber/\inserttotalframenumber]} + \vspace{5.2mm} + \hspace{2mm}\noindent\hfill\box\nord@tmpbox\hspace{2mm} + \vspace{1.3mm} +} +\setbeamertemplate{title page}{ + \renewcommand\thefootnote{\fnsymbol{footnote}} + \setcounter{footnote}{1} % \dagger + {\usebeamerfont{title}\usebeamercolor[fg]{title}\bfseries\boldmath\inserttitle} + \ifx\insertsubtitle\@empty\else\\[1em] {\usebeamerfont{subtitle}\usebeamercolor[fg]{subtitle}\insertsubtitle}\fi~\\[2em] + {\structure{von}} \insertauthor\ \ifx\insertinstitute\@empty\else\quad(\insertinstitute)\fi + \\[1pt] + {\structure{am}} \insertdate\\ + \renewcommand\thefootnote{\arabic{footnote}} + \setcounter{footnote}{0} +} + +% table of contents +\setbeamertemplate{section in toc}{ + %\inserttocsection\\\smallskip + Was kommt?\\\medskip +} +\setbeamertemplate{subsection in toc}{~$\ast$~~\inserttocsubsection\\\smallskip} +\setbeamertemplate{subsection in toc shaded}[default][100] + +% block +\setbeamertemplate{blocks}[rounded][shadow=false] +\addtobeamertemplate{block begin}{% + \setlength{\textwidth}{0.85\textwidth}% +}{} +\addtobeamertemplate{block alerted begin}{% + \setlength{\textwidth}{0.85\textwidth}% +}{} +\addtobeamertemplate{block example begin}{% + \setlength{\textwidth}{0.85\textwidth}% +}{} + + +\mode + + +\endinput diff --git a/template.pdf b/template.pdf new file mode 100644 index 0000000..1fef78a Binary files /dev/null and b/template.pdf differ diff --git a/template.tex b/template.tex new file mode 100644 index 0000000..1ba31bc --- /dev/null +++ b/template.tex @@ -0,0 +1,135 @@ +\documentclass[compress]{beamer} +\usepackage[utf8]{inputenc} +\usepackage[T1]{fontenc} +\usepackage[ngerman]{babel} +\usepackage{listings} +\usepackage{fontspec} +\usepackage{graphicx} + +\usetheme{Nik} + +%\setmainfont{Yanone Kaffeesatz} +%\setsansfont{Andika New Basic} +%\setmonofont{DejaVu Sans Mono} + +\setmainfont{Yanone Kaffeesatz} +\setsansfont{Andika New Basic} +\setmonofont{Fira Code} + +% listing +\lstset{ + language=Java, % choose the language of the code + numbers=left, % where to put the line-numbers + %stepnumber=1, % the step between two line-numbers. + %numbersep=5pt, % how far the line-numbers are from the code + numberstyle=\tiny\color{DraculaGreen}\ttfamily, + backgroundcolor=\color{DraculaBackground}, % choose the background color. You must add \usepackage{color} + showspaces=false, % show spaces adding particular underscores + showstringspaces=false, % underline spaces within strings + showtabs=false, % show tabs within strings adding particular underscores + tabsize=4, % sets default tabsize to 4 spaces + captionpos=b, % sets the caption-position to bottom + breaklines=true, % sets automatic line breaking + breakatwhitespace=true, % sets if automatic breaks should only happen at whitespace + title=\lstname, % show the filename of files included with \lstinputlisting; + basicstyle=\color{DraculaForeground}\ttfamily, % sets font style for the code + keywordstyle=\color{DraculaPink}\ttfamily, % sets color for keywords + stringstyle=\color{DraculaYellow}\ttfamily, % sets color for strings + commentstyle=\color{DraculaComment}\ttfamily, % sets color for comments + emph={format_string, eff_ana_bf, permute, eff_ana_btr}, + emphstyle=\color{DraculaCyan}\ttfamily +} + +% table of contents +\AtBeginSection[] +{ + \begin{frame}[c,noframenumbering,plain] + \tableofcontents[sectionstyle=show/hide,subsectionstyle=show/show/hide] + \end{frame} +} + +\AtBeginSubsection[] +{ + \begin{frame}[c,noframenumbering,plain] + \tableofcontents[sectionstyle=show/hide,subsectionstyle=show/shaded/hide,subsubsectionstyle=show/show/hide] + \end{frame} +} + +\author{Niklas Birk} +\title{Niks Theme} +\subtitle{Dracula Style} +\institute{TUBAF / RWU} + +\begin{document} + + \begin{frame}[plain] + \maketitle + \end{frame} + + \section{Niks Theme} + + \subsection{Normales} + \subsubsection{Aufzählungen und Texte} + \begin{frame} + \frametitle{Normales} + \framesubtitle{Aufzählungen und Texte} + + \begin{itemize} + \item Information und Mathematik $\rightarrow$ Computer? + \item Information und Automatik $\rightarrow$ Computer? + \end{itemize} + \end{frame} + \subsubsection{Zitat} + \begin{frame} + \frametitle{Normales} + \framesubtitle{Zitat} + + \begin{quote} + \centering + „In der Informatik geht es genau so wenig um Computer, wie in der Astronomie um Teleskope.“\\ + - Edsger Dijsktra + \end{quote} + \end{frame} + + \subsection{Blöcke und Listings} + \subsubsection{Normal, Beispiel und Achtung} + \begin{frame} + \frametitle{Blöcke} + \framesubtitle{Normal, Beispiel und Achtung} + + \begin{block}{Aussage} + Eine \emph{Aussage} ist ein sprachliches Gebilde, + dem eindeutig ein Wahrheitswert (\emph{wahr} oder \emph{falsch}) zugeordnet werden kann. + \end{block} + + \begin{exampleblock}{Beispiel} + Eine \emph{Aussage} ist ein sprachliches Gebilde, + dem eindeutig ein Wahrheitswert (\emph{wahr} oder \emph{falsch}) zugeordnet werden kann. + \end{exampleblock} + + \begin{alertblock}{Achtung!} + Eine \emph{Aussage} ist ein sprachliches Gebilde, + dem eindeutig ein Wahrheitswert (\emph{wahr} oder \emph{falsch}) zugeordnet werden kann. + \end{alertblock} + \end{frame} + \subsubsection{Listings} + \begin{frame}[fragile] + \frametitle{Blöcke und Listings} + \framesubtitle{Listings} + +\begin{lstlisting} +int i = 10; +do { + i = i - 3; +} while (i > 5); +\end{lstlisting} + + \begin{exampleblock}{Beispiel} +\begin{lstlisting} +for (int i=1; i <= 10; i++) { + System.out.println("Ausgabe:" + i); +} +\end{lstlisting} + \end{exampleblock} + \end{frame} +\end{document} \ No newline at end of file