Skip to content
Snippets Groups Projects
Commit f0eea11f authored by Reinhold Kainhofer's avatar Reinhold Kainhofer
Browse files

Update the report and article classes from the AVOe2018-P docs

parent c71580c1
No related branches found
No related tags found
No related merge requests found
...@@ -46,25 +46,25 @@ ...@@ -46,25 +46,25 @@
% \RequirePackage[T1]{fontenc} % \RequirePackage[T1]{fontenc}
\RequirePackage{titlesec} \RequirePackage{titlesec}
\titleformat{\section} % command \titleformat{\section} % command
{\LARGE\scshape\raggedright} % format: Large, small capitals, bold, left-aligned {\LARGE\scshape\raggedright} % format: Large, small capitals, bold, left-aligned
{\thesection}{.5em} % label and separator {\thesection}{.5em} % label and separator
{} % before-code {} % before-code
% [\titlerule] % after-code % [\titlerule] % after-code
\titleformat{\subsection} % command \titleformat{\subsection} % command
{\Large\scshape\raggedright} % format: Large, small capitals, bold, left-aligned {\Large\scshape\raggedright} % format: Large, small capitals, bold, left-aligned
{\thesubsection}{.5em} % label and separator {\thesubsection}{.5em} % label and separator
{} % before-code {} % before-code
% [\titlerule] % after-code % [\titlerule] % after-code
\titleformat{\subsubsection} % command \titleformat{\subsubsection} % command
{\large\scshape\raggedright} % format: Large, small capitals, bold, left-aligned {\large\scshape\raggedright} % format: Large, small capitals, bold, left-aligned
{\thesubsubsection}{.5em} % label and separator {\thesubsubsection}{.5em} % label and separator
{} % before-code {} % before-code
% [\titlerule] % after-code % [\titlerule] % after-code
% Page layout % Page layout
% For debugging, add the "showframe" option to geometry! % For debugging, add the "showframe" option to geometry!
\RequirePackage[left=2.5cm,right=2.5cm,top=1.5cm,bottom=2cm,head=55pt,foot=30pt,includeheadfoot]{geometry} \RequirePackage[left=2.5cm,right=2.5cm,top=1.cm,bottom=2cm,head=50pt,foot=30pt,includeheadfoot]{geometry}
\RequirePackage{textcomp} \RequirePackage{textcomp}
\RequirePackage{colortbl} \RequirePackage{colortbl}
\RequirePackage{xcolor} \RequirePackage{xcolor}
...@@ -101,7 +101,7 @@ ...@@ -101,7 +101,7 @@
\AtBeginDocument{\thispagestyle{firstpage}} \AtBeginDocument{\thispagestyle{firstpage}}
% \setlength{\headheight}{55pt}% % \setlength{\headheight}{55pt}%
% \setlength{\footheight}{35pt}% % \setlength{\footheight}{35pt}%
% %
% \newenvironment{documenthistory}{% % \newenvironment{documenthistory}{%
% \begin{tabularx}{\linewidth}{>{\bfseries}cXl}% % \begin{tabularx}{\linewidth}{>{\bfseries}cXl}%
% {\bfseries\color{avoe}Version-\textnumero} & {\bfseries\color{avoe}\"Anderungen} & {\bfseries\color{avoe}Datum} \setlength\arrayrulewidth{5pt}\arrayrulecolor{avoe}\\ \hline% % {\bfseries\color{avoe}Version-\textnumero} & {\bfseries\color{avoe}\"Anderungen} & {\bfseries\color{avoe}Datum} \setlength\arrayrulewidth{5pt}\arrayrulecolor{avoe}\\ \hline%
...@@ -111,22 +111,25 @@ ...@@ -111,22 +111,25 @@
% } % }
% Allow temporarily changing the left/right margins (inside a % Allow temporarily changing the left/right margins (inside a
% \begin{changemargin}{left}{right}...\end{changemargin} environment) % \begin{changemargin}{left}{right}...\end{changemargin} environment)
\def\changemargin#1#2{\list{}{\rightmargin#2\leftmargin#1}\item[]} \def\changemargin#1#2{\list{}{\rightmargin#2\leftmargin#1}\item[]}
\let\endchangemargin=\endlist \let\endchangemargin=\endlist
% \setlength\arrayrulewidth{2pt} % \setlength\arrayrulewidth{2pt}
\newenvironment{documenthistory}{% \newenvironment{documenthistory}{%
\begin{center}\begin{tabular}{>{\bfseries}cll}% % \begin{center}
{\bfseries\color{avoe}Version-\textnumero} & {\bfseries\color{avoe}\"Anderungen} & {\bfseries\color{avoe}Datum} \\ \tabularx{\linewidth}{>{\bfseries}c>{\raggedright\arraybackslash}Xll}%
\textcolor{avoe}{\bfseries Version-\textnumero} & \textcolor{avoe}{\bfseries \"Anderungen} & \textcolor{avoe}{\bfseries Person} & \textcolor{avoe}{\bfseries Datum} \\
\noalign{\global\arrayrulewidth=2pt}\arrayrulecolor{avoe} \hline% \noalign{\global\arrayrulewidth=2pt}\arrayrulecolor{avoe} \hline%
\noalign{\global\arrayrulewidth=0.4pt}\arrayrulecolor{black} \noalign{\global\arrayrulewidth=0.4pt}\arrayrulecolor{black}
}{% }{%
\hline\end{tabular}\end{center} % \hline
\endtabularx
} }
\if@titlepage \if@titlepage
\renewcommand\maketitle{\hypersetup{pageanchor=false}\newgeometry{left=3.5cm,right=3.5cm,top=6cm, bottom=3cm}\begin{titlepage}% \renewcommand\maketitle{\hypersetup{pageanchor=false}\newgeometry{left=3.5cm,right=3.5cm,top=6cm, bottom=3cm}\begin{titlepage}%
\let\footnotesize\small \let\footnotesize\small
...@@ -213,8 +216,8 @@ ...@@ -213,8 +216,8 @@
{\Huge \@title \par}% {\Huge \@title \par}%
\ifdefined\@themengebiet{\vskip 5\p@\Large\scshape \@themengebiet \par}\fi% \ifdefined\@themengebiet{\vskip 5\p@\Large\scshape \@themengebiet \par}\fi%
\begin{center}% \begin{center}%
% \ifdefined\@arbeitskreis{\large\lineskip .75em{}Arbeitskreis \@arbeitskreis\par}\fi \ifdefined\@arbeitskreis{\vskip 1em\large\lineskip .75em{}Arbeitskreis \@arbeitskreis\par}\fi
% {\large\lineskip .75em\@author\par}% {\large\lineskip .75em\@author\par}%
\vskip 1.5em% \vskip 1.5em%
{\large \@date \par}% % Set date in \large size. {\large \@date \par}% % Set date in \large size.
\end{center}\par \end{center}\par
......
% avoearticle.cls
% LaTeX article class for AVÖ documents
\ProvidesClass{avoereport}[2018/03/09 version 1.00 Minutes of meetings]
\NeedsTeXFormat{LaTeX2e}
% --- Class structure: declaration of options part
% ---
% This class extends the article class
% Read all the documentclass options; pass them to article
%\DeclareOption*{\InputIfFileExists{\CurrentOption.min}{}{%
%\PassOptionsToClass{\CurrentOption}{article}}}
\DeclareOption*{
\PassOptionsToClass{\CurrentOption}{report}
}
% --- Class structure: execution of options part
% ---
\ProcessOptions \relax
\LoadClass{report}
\RequirePackage[hidelinks]{hyperref}
\def\arbeitskreis#1{\gdef\@arbeitskreis{#1}}
\def\date#1{\gdef\@date{#1}\gdef\@footdate{#1}}
\def\@footdate{\@empty}
\def\date#1{\gdef\@date{#1}\gdef\@footdate{#1}}
\def\@footdate{\@empty}
\def\title#1{\gdef\@title{#1}\gdef\@shorttitle{#1}}
\def\shorttitle#1{\gdef\@shorttitle{#1}}
\def\themengebiet#1{\gdef\@themengebiet{#1}}
\RequirePackage[default,osfigures,scale=0.95]{opensans} %% Alternatively
%% use the option 'defaultsans' instead of 'default' to replace the
%% sans serif font only.
% \RequirePackage[T1]{fontenc}
% \RequirePackage[sfdefault]{arimo}
% \RequirePackage[T1]{fontenc}
\RequirePackage{titlesec}
\titleformat{\section} % command
{\LARGE\scshape\raggedright} % format: Large, small capitals, bold, left-aligned
{\thesection}{.5em} % label and separator
{} % before-code
% [\titlerule] % after-code
\titleformat{\subsection} % command
{\Large\scshape\raggedright} % format: Large, small capitals, bold, left-aligned
{\thesubsection}{.5em} % label and separator
{} % before-code
% [\titlerule] % after-code
\titleformat{\subsubsection} % command
{\large\scshape\raggedright} % format: Large, small capitals, bold, left-aligned
{\thesubsubsection}{.5em} % label and separator
{} % before-code
% [\titlerule] % after-code
% Page layout
% For debugging, add the "showframe" option to geometry!
\RequirePackage[left=2.5cm,right=2.5cm,top=1.cm,bottom=2cm,head=50pt,foot=30pt,includeheadfoot]{geometry}
\RequirePackage{textcomp}
\RequirePackage{colortbl}
\RequirePackage{xcolor}
\RequirePackage{tabularx}
\RequirePackage{array}
\RequirePackage{lastpage}
\RequirePackage{graphicx}
\definecolor{avoe}{RGB}{15,112,183}
\definecolor{avoehdr}{RGB}{90,90,90}
\RequirePackage{fancyhdr}
\fancypagestyle{firstpage}{%
\fancyhf{} % clear all six fields
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{0pt}
}
\fancypagestyle{followingpage}{%
\fancyhf{} % clear all six fields
\fancyhead[L]{\includegraphics[width=6cm]{avoelogo.png}}
\fancyhead[R]{\color{avoehdr}\large\scshape\ifdefined\@arbeitskreis{}Arbeitskreis\\\@arbeitskreis\fi}
\cfoot{\color{avoehdr}Seite \thepage\ von \pageref{LastPage}}
\lfoot{\color{avoehdr}\@shorttitle\ifdefined\@shorttitle\ifdefined\@themengebiet\\\fi\fi\@themengebiet}
\rfoot{\color{avoehdr}\@footdate}
% \fancyhead[RE,LO]{\show@committee, \show@date}
% \fancyhead[LE,RO]{page \thepage}
\renewcommand{\headrulewidth}{2pt}
\renewcommand{\footrulewidth}{0.5pt}
\renewcommand{\headrule}{\hbox to\headwidth{\color{avoe}\leaders\hrule height \headrulewidth\hfill}}
}
% Redefine the plain style for the first page of a chapter (no header, but normal footer like on all other pages)
\fancypagestyle{plain}{%
\fancyhf{} % clear all six fields
% \fancyhead[L]{\includegraphics[width=6cm]{avoelogo.png}}
% \fancyhead[R]{\color{avoehdr}\large\scshape\ifdefined\@arbeitskreis{}Arbeitskreis\\\@arbeitskreis\fi}
\cfoot{\color{avoehdr}Seite \thepage\ von \pageref{LastPage}}
\lfoot{\color{avoehdr}\@shorttitle\ifdefined\@shorttitle\ifdefined\@themengebiet\\\fi\fi\@themengebiet}
\rfoot{\color{avoehdr}\@footdate}
% \fancyhead[RE,LO]{\show@committee, \show@date}
% \fancyhead[LE,RO]{page \thepage}
% \renewcommand{\headrulewidth}{2pt}
\renewcommand{\footrulewidth}{0.5pt}
\renewcommand{\headrule}{}
}
\pagestyle{followingpage}
\AtBeginDocument{\thispagestyle{firstpage}}
% \setlength{\headheight}{55pt}%
% \setlength{\footheight}{35pt}%
%
% \newenvironment{documenthistory}{%
% \begin{tabularx}{\linewidth}{>{\bfseries}cXl}%
% {\bfseries\color{avoe}Version-\textnumero} & {\bfseries\color{avoe}\"Anderungen} & {\bfseries\color{avoe}Datum} \setlength\arrayrulewidth{5pt}\arrayrulecolor{avoe}\\ \hline%
% \setlength\arrayrulewidth{0.4pt}\arrayrulecolor{black}
% }{%
% \hline\end{tabularx}
% }
% Allow temporarily changing the left/right margins (inside a
% \begin{changemargin}{left}{right}...\end{changemargin} environment)
\def\changemargin#1#2{\list{}{\rightmargin#2\leftmargin#1}\item[]}
\let\endchangemargin=\endlist
% \setlength\arrayrulewidth{2pt}
\newenvironment{documenthistory}{%
% \begin{center}
\tabularx{\linewidth}{>{\bfseries}c>{\raggedright\arraybackslash}Xll}%
\textcolor{avoe}{\bfseries Version-\textnumero} & \textcolor{avoe}{\bfseries \"Anderungen} & \textcolor{avoe}{\bfseries Person} & \textcolor{avoe}{\bfseries Datum} \\
\noalign{\global\arrayrulewidth=2pt}\arrayrulecolor{avoe} \hline%
\noalign{\global\arrayrulewidth=0.4pt}\arrayrulecolor{black}
}{%
% \hline
\endtabularx
}
\if@titlepage
\renewcommand\maketitle{\hypersetup{pageanchor=false}\newgeometry{left=3.5cm,right=3.5cm,top=6cm, bottom=3cm}\begin{titlepage}%
\let\footnotesize\small
\let\footnoterule\relax
\let \footnote \thanks
\color{avoehdr}%
{\color{avoe}\rule{0.945\linewidth}{1mm}\par\vskip 1em}
{\quad\includegraphics[width=8cm]{avoelogo.png}\par}
\null\vfil
% \vskip 60\p@
{\Huge \@title \par}%
\ifdefined\@themengebiet{\vskip 10\p@\Large\scshape \@themengebiet \par}\fi%
\null\vfil
\null\vfil
\null\vfil
\begin{center}%
\ifdefined\@arbeitskreis{\large\lineskip .75em{}Arbeitskreis \@arbeitskreis\par}\fi
{\large\lineskip .75em\@author\par}%
\vskip 1.5em%
{\large \@date \par}% % Set date in \large size.
\end{center}\par
\@thanks
\null\vfil
\vfil\null
\thispagestyle{empty}
\end{titlepage}%
\restoregeometry%
\hypersetup{pageanchor=true}%
\setcounter{footnote}{0}%
\global\let\thanks\relax
\global\let\maketitle\relax
\global\let\@thanks\@empty
\global\let\@author\@empty
\global\let\@date\@empty
\global\let\@title\@empty
\global\let\title\relax
\global\let\author\relax
\global\let\date\relax
\global\let\and\relax
}
\else
\renewcommand\maketitle{\par
\begingroup
\renewcommand\thefootnote{\@fnsymbol\c@footnote}%
\def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}%
\long\def\@makefntext##1{\parindent 1em\noindent
\hb@xt@1.8em{%
\hss\@textsuperscript{\normalfont\@thefnmark}}##1}%
\if@twocolumn
\ifnum \col@number=\@ne
\@maketitle
\else
\twocolumn[\@maketitle]%
\fi
\else
\newpage
\global\@topnum\z@ % Prevents figures from going at top of page.
\@maketitle
\fi
\thispagestyle{plain}\@thanks
\endgroup
\setcounter{footnote}{0}%
\global\let\thanks\relax
\global\let\maketitle\relax
\global\let\@maketitle\relax
\global\let\@thanks\@empty
\global\let\@author\@empty
\global\let\@date\@empty
\global\let\@title\@empty
\global\let\title\relax
\global\let\author\relax
\global\let\date\relax
\global\let\and\relax
}
\def\@maketitle{%
\newpage
\null
\vskip 2em%
\begin{changemargin}{1cm}{1cm}
\color{avoehdr}%
{\color{avoe}\rule{0.945\linewidth}{1mm}\par\vskip 1em}
{\quad\includegraphics[width=8cm]{avoelogo.png}\par}
\vskip 1.5em
{\Huge \@title \par}%
\ifdefined\@themengebiet{\vskip 5\p@\Large\scshape \@themengebiet \par}\fi%
\begin{center}%
\ifdefined\@arbeitskreis{\vskip 1em\large\lineskip .75em{}Arbeitskreis \@arbeitskreis\par}\fi
{\large\lineskip .75em\@author\par}%
\vskip 1.5em%
{\large \@date \par}% % Set date in \large size.
\end{center}\par
\end{changemargin}
\vskip 1.5em}
\fi
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment