Commit d57decec authored by Reinhold Kainhofer's avatar Reinhold Kainhofer
Browse files

Initial Version, layout is completed

parents
*.backup
*.aux
*.log
*.out
*.toc
# AVÖ LaTeX Dokumentklassen
## Author: Reinhold Kainhofer, reinhold@kainhofer.com
LaTeX-Dokumentklassen für das Corporate Design der Aktuarvereinigung Österreichs (AVÖ, http://avoe.at/).
## Funktionialität
* ``\shorttitle{...}``: Kurztitel für die Fußzeile. Falls nicht angegeben, wird der \title{...} benutzt
* ``\themengebiet{...}``: Untertitel des Artikels (auch in Fußzeile)
* ``\arbeitskreis{...}``: Arbeitskreis (vor Author), auch in Kopfzeile
* Environment "documenthistory": Tabelle mit Versionskommentaren:
```{latex}
\begin{documenthistory}
0.1 & Erster Entwurf von ... & xx.xx.20xx\\\hline
0.2 & Review durch ... & xx.xx.20xx\\\hline
0.3 & Review durch ... & xx.xx.20xx\\\hline
1.0 & Freigabe durch ... & xx.xx.20xx\\
\end{documenthistory}
```
### Paket-Abhängigkeiten
* hyperref
* opensans
* titlesec
* geometry
* textcomp
* colortbl
* xcolor
* tabularx
* array
* lastpage
* graphicx
* fancyhdr
## Beispiel
```{latex}
\documentclass[a4paper,10pt]{avoearticle}
\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
\usepackage{fontenc}
\author{Reinhold Kainhofer}
\title{AVÖ \LaTeX{} Document Class}
\shorttitle{AV\"O Design}
\themengebiet{Corporate Identity}
\date{9. März 2018}
\arbeitskreis{Rechnungsgrundlagen}
\begin{document}
\maketitle
\tableofcontents
\section{Beispielkapitel}
Hier kommt der Text...
\end{document}
```
% avoearticle.cls
% LaTeX article class for AVÖ documents
\ProvidesClass{avoearticle}[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}{article}
}
% --- Class structure: execution of options part
% ---
\ProcessOptions \relax
\LoadClass{article}
\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.5cm,bottom=2cm,head=55pt,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}}
}
\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}\begin{tabular}{>{\bfseries}cll}%
{\bfseries\color{avoe}Version-\textnumero} & {\bfseries\color{avoe}\"Anderungen} & {\bfseries\color{avoe}Datum} \\
\noalign{\global\arrayrulewidth=2pt}\arrayrulecolor{avoe} \hline%
\noalign{\global\arrayrulewidth=0.4pt}\arrayrulecolor{black}
}{%
\hline\end{tabular}\end{center}
}
\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{\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
% \documentclass[a4paper,10pt,titlepage]{avoearticle}
\documentclass[a4paper,10pt]{avoearticle}
\usepackage{ucs}
\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
\usepackage{fontenc}
\usepackage{graphicx}
\usepackage{layout}
\author{Reinhold Kainhofer}
\title{AVÖ \LaTeX{} Document Class}
\shorttitle{AV\"O Design}
\themengebiet{Corporate Identity}
\date{9. März 2018}
\arbeitskreis{Rechnungsgrundlagen}
\begin{document}
% \layout
\maketitle
Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Etiam rhoncus. Maecenas tempus, tellus eget condimentum rhoncus, sem quam semper libero, sit amet adipiscing sem neque sed ipsum. Nam quam nunc, blandit vel, luctus pulvinar, hendrerit id, lorem. Maecenas nec odio et ante tincidunt tempus.
\tableofcontents
\chapter{test}
\section*{Dokumentenhistorie}
Diese Seite ist in der endgültigen Version des Dokuments zu entfernen.
\begin{documenthistory}
0.1 & Erster Entwurf von ... & xx.xx.20xx\\\hline
0.2 & Review durch ... & xx.xx.20xx\\\hline
0.3 & Review durch ... & xx.xx.20xx\\\hline
1.0 & Freigabe durch ... & xx.xx.20xx\\
\end{documenthistory}
\pagebreak
\section{Kapitel}
\subsection{Unterkapital}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium. Integer tincidunt. Cras dapibus.
Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum. Aenean imperdiet. Etiam ultricies nisi vel augue. Curabitur ullamcorper ultricies nisi. Nam eget dui. Etiam rhoncus. Maecenas tempus, tellus eget condimentum rhoncus, sem quam semper libero, sit amet adipiscing sem neque sed ipsum. Nam quam nunc, blandit vel, luctus pulvinar, hendrerit id, lorem. Maecenas nec odio et ante tincidunt tempus.
\subsection{Unterkapitel}
Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum.
\subsubsection{Unterkapitel}
Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum:
\begin{itemize}
\item Beispielaufzählung
\item Beispielaufzählung
\begin{itemize}
\item Beispielaufzählung
\item Beispielaufzählung
\begin{itemize}
\item Beispielaufzählung
\item Beispielaufzählung
\begin{itemize}
\item Beispielaufzählung
\item Beispielaufzählung
\end{itemize}
\end{itemize}
\end{itemize}
\item Beispielaufzählung
\item Beispielaufzählung
\end{itemize}
\subsubsection{Unterkapitel}
Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum:
\appendix
\section{Appendix}
Bei zusätzlichen themenspezifischen Anhängen, diese in Appendix A; Wenn es keine zusätzlichen An\-hän\-ge gibt, sind die Regularien und das Abkürzungsverzeichnis im Appendix A.
\section{Appendix B Überschrift 2 Appendix}
Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum.
\subsection{Appendix C Überschrift 3 Appendix}
Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum.
\subsection{Appendix D Überschrift 3 Appendix}
Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum.
\section*{Appendix E Überschrift 2 Appendix}
Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum.
\end{document}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment