hfu_asta/asta-fuwa_kompendium/compendium.cls

191 lines
6.3 KiB
TeX

% LaTeX Template für die Verfasste Studierendenschaft
% Copyright © 2022 Valentin Weber
% Copyright © 2022 Justin Dretvic
% Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
% The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
% THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{compendium}[2022-07-05 Protocol LaTeX Class]
\LoadClass[a4paper,10pt,twoside]{article}
% ##################################################
% Allgemeine Pakete
% ##################################################
\RequirePackage{titlesec} % Anpassen der Sections
\RequirePackage{hyperref} % [hidelinks]
\RequirePackage{listings} % Für Codesippets
\RequirePackage{csquotes} % Anführungsstriche einheitlich und leicht änderbar
\MakeInnerQuote{"}
\RequirePackage{svg} % Einbinden von SVGs
\RequirePackage{graphicx} % Einbinden von Bildern
\graphicspath{ {./images/} }
\RequirePackage[ngerman]{babel} % Dokumentsprache setzten
\RequirePackage{newclude} % ???
%\RequirePackage{svg} % Unterstützung von svg Dateien
\RequirePackage{fancyhdr} % Header weitere Anpassungen
\RequirePackage{array} % Damit ganze Spalten formatierbar sind
\RequirePackage[ddmmyyyy]{datetime} % Erweiterte einstellungen des Datums
\renewcommand{\dateseparator}{.} % Punkttrennung des Datums
\RequirePackage{tabularx} % Tabellen mit Zeilenumbruch
\RequirePackage{wasysym} % ???
\RequirePackage{pdfpages} % ???
\RequirePackage{blindtext} % erzeugen von Blindtexten
% ##################################################
% Seitenränder
% ##################################################
\RequirePackage{geometry}
\geometry{
a4paper,
portrait,
top=25mm,
bottom=20mm,
bindingoffset=5mm,
inner=20mm,
outer=20mm,
%left=25mm,
%right=20mm,
%showframe, %Aktivieren um Seitengrenzen anzuzeigen
}
% ##################################################
% Schrift
% ##################################################
% Schriftart / Font
\RequirePackage{fontspec}
\setmainfont[
BoldFont={Arial Bold},
ItalicFont={Arial Italic},
BoldItalicFont={Arial Bold Italic}
]{Arial}
\newfontfamily{\UniversCondensed}{UniversCondensedBold}[Extension = .ttf, Path = fonts/]
% Zeilenabstand
\RequirePackage{setspace}
\singlespacing % 1 Zeilenabstand
% ##################################################
% Farben
% ##################################################
\RequirePackage{tcolorbox} % farbige Boxen
\RequirePackage{xcolor} % Farben 'x' ist neuer und unterstützt 'RGB' (0-255)
\RequirePackage{colortbl} % Farben im tabular
\definecolor{headerColor}{RGB}{128,128,128} % Farbe des Headers
\definecolor{lightgrey}{RGB}{240,240,240}
\definecolor{astagreen}{RGB}{128,186, 39}
\definecolor{astablue}{RGB}{0,60,80}
\definecolor{vstgreen}{RGB}{0,132,77}
\definecolor{blue}{RGB}{0,0,255}
\definecolor{red}{RGB}{255,0,0}
\definecolor{green}{RGB}{0,255,0}
\definecolor{yellow}{RGB}{255,255,0}
% ##################################################
% Formatierung
% ##################################################
% Einrückungen von Aufzählungen wird angemessen berechnet
%\setlist[itemize]{leftmargin=*}
% Aufzählung auf '-' Symbol ändern
\def\labelitemi{--}
% Zeilenbstand bei Aufzählungen
%\setlist[enumerate]{itemsep=0mm}
%\setlist[itemize]{itemsep=0mm}
% ##################################################
% Dokumentvariablen
% ##################################################
% Hervorhebung der Teile die geändert werden müssen
\newcommand{\default}{\textcolor{red}{DEFAULT}}
\newcommand{\red}[1]{\textcolor{red}{#1}}
% ##################################################
% Header und Footer
% ##################################################
\pagestyle{fancy}
%\lhead{\fontsize{10}{0}\selectfont \textcolor{headerColor}{Kompendium des Campus-AStA Furtwangen}}
%\rhead{\fontsize{10}{0}\selectfont \textcolor{headerColor}{Seite \thepage}}
%\cfoot{}
\fancyhead[EL,OR]{\fontsize{10}{0}\selectfont \textcolor{headerColor}{Seite \thepage}}
\fancyhead[ER,OL]{\fontsize{10}{0}\selectfont \textcolor{headerColor}{Kompendium des Campus-AStA Furtwangen}}
\fancypagestyle{headings}{}
\fancypagestyle{plain}{}
% ##################################################
% Hyperref
% ##################################################
\hypersetup{
colorlinks,
citecolor=black,
filecolor=black,
linkcolor=black,
urlcolor=black
}
% ##################################################
% Section
% ##################################################
\titleformat{\section}
{\color{astablue}\normalfont\Large\bfseries}
{\color{astablue}\thesection}{1em}{}
% ##################################################
% Abkürzungsverzeichnis
% ##################################################
\RequirePackage[nohyperlinks]{acronym}
\RequirePackage{lscape}
% ##################################################
% Tabellen
% ##################################################
\RequirePackage{multicol}
\RequirePackage{multirow}
\renewcommand{\arraystretch}{1.5}
\newcolumntype{B}{>{\raggedright\arraybackslash}m{0.1\textwidth}}
\newcolumntype{C}{>{\centering\arraybackslash}m{0.01\textwidth}}
\newcolumntype{T}{>{\raggedright\arraybackslash}m{0.3\textwidth}}
% ##################################################
% To Be Documentated
% ##################################################
\RequirePackage{parskip} % http://ctan.org/pkg/parskip
\RequirePackage{shrug}