1 \ProvidesFile{kivitendo.sty}
7 \usepackage[utf8]{inputenc}
13 \newboolean{defaultbg}\setboolean{defaultbg}{true}
15 \newboolean{reqspeclogo}
16 \newboolean{secondpagelogo}
17 \DeclareOption{nologo}{\setboolean{defaultbg}{false}}
18 \DeclareOption{draftlogo}{\setboolean{defaultbg}{false}\setboolean{draftbg}{true}}
19 \DeclareOption{reqspeclogo}{\setboolean{reqspeclogo}{true}}
20 \DeclareOption{secondpagelogo}{\setboolean{defaultbg}{false}\setboolean{secondpagelogo}{true}}
24 \setlength{\voffset}{-1.5cm}
25 \setlength{\hoffset}{-2.5cm}
26 \setlength{\topmargin}{0cm}
27 \setlength{\headheight}{0.5cm}
28 \setlength{\headsep}{1cm}
29 \setlength{\topskip}{0pt}
30 \setlength{\oddsidemargin}{2cm}
31 \setlength{\textwidth}{16.4cm}
32 \setlength{\textheight}{25cm}
33 \setlength{\footskip}{1cm}
34 \setlength{\parindent}{0pt}
35 \setlength{\tabcolsep}{0.2cm}
37 \setlength{\unitlength}{1cm}
39 \newcommand{\kivitendobgsettings}{%
40 \setlength{\headsep}{2.5cm}
41 \setlength{\textheight}{22.5cm}
42 \setlength{\footskip}{0.9cm}
46 \newcommand{\defaultfont}{\fontfamily{cmss}\fontsize{10pt}{12pt}\fontseries{m}\selectfont}
47 \renewcommand{\familydefault}{cmss}
50 \newsavebox{\checkedbox}
51 \savebox{\checkedbox}(0.2,0.4){
52 \put(-0.15,-0.425){$\times$}
53 \put(-0.15,-0.45){$\Box$}
55 \newsavebox{\uncheckedbox}
56 \savebox{\uncheckedbox}(0.2,0.4){
57 \put(-0.15,-0.45){$\Box$}
61 \definecolor{kivitendoorange}{rgb}{1,0.4,0.2}
62 \definecolor{kivitendodarkred}{rgb}{0.49,0,0}
63 \definecolor{kivitendoyellow}{rgb}{1,1,0.4}
64 \definecolor{kivitendobggray}{gray}{0.9}
65 \definecolor{kivitendowhite}{gray}{1}
67 %% Kopf- und Fußzeilen
68 \newcommand{\kivitendofirsthead}{}
69 \newcommand{\kivitendofirstfoot}{}
70 \newcommand{\kivitendosecondhead}{}
71 \newcommand{\kivitendosecondfoot}{\centerline{\defaultfont\small Seite \thepage}}
73 \newcommand{\myhead}{%
74 \ifthenelse{\boolean{defaultbg}}{%
76 \put(-2.025,-28.1){\includegraphics*[width=\paperwidth,keepaspectratio=true]{images/hintergrund_seite1.png}}
79 \ifthenelse{\boolean{secondpagelogo}}{%
81 \put(-2.025,-28.1){\includegraphics*[width=\paperwidth,keepaspectratio=true]{images/hintergrund_seite2.png}}
84 \ifthenelse{\boolean{draftbg}}{%
86 \put(-2.025,-26.9){\includegraphics*[width=\paperwidth,keepaspectratio=true]{images/draft.png}}
89 \ifthenelse{\boolean{reqspeclogo}}{%
91 \put(3,-22){\includegraphics*[width=13cm,keepaspectratio=true]{images/schachfiguren.jpg}}
92 \put(0.275,-4.1){\colorbox{kivitendoorange}{\begin{minipage}[t][4.5cm]{2.5cm}\hspace*{2.5cm}\end{minipage}}}
93 \put(0.275,-8.8){\colorbox{kivitendodarkred}{\begin{minipage}[t][4.5cm]{2.5cm}\hspace*{2.5cm}\end{minipage}}}
94 \put(0.275,-13.5){\colorbox{kivitendoyellow}{\begin{minipage}[t][4.5cm]{2.5cm}\hspace*{2.5cm}\end{minipage}}}
100 \newcommand{\mysecondhead}{%
101 \ifthenelse{\boolean{defaultbg} \or \boolean{secondpagelogo}}{%
103 \put(-2.025,-28.1){\includegraphics*[width=\paperwidth,keepaspectratio=true]{images/hintergrund_seite2.png}}
106 \ifthenelse{\boolean{draftbg}}{%
108 \put(-2.025,-26.9){\includegraphics*[width=\paperwidth,keepaspectratio=true]{images/draft.png}}
114 \newcommand{\myfoot}{\kivitendofirstfoot}
115 \newcommand{\mysecondfoot}{\kivitendosecondfoot}
117 \renewcommand{\ps@headings}{%
118 \renewcommand{\@oddhead}{\myhead}
119 \renewcommand{\@evenhead}{\@oddhead}%
120 \renewcommand{\@oddfoot}{\myfoot}
121 \renewcommand{\@evenfoot}{\@oddfoot}%
124 \renewcommand{\ps@plain}{%
125 \renewcommand{\@oddhead}{\mysecondhead}
126 \renewcommand{\@evenhead}{\@oddhead}%
127 \renewcommand{\@oddfoot}{\mysecondfoot}
128 \renewcommand{\@evenfoot}{\@oddfoot}%
132 \thispagestyle{headings}
134 % Abschnitte mit Kasten hinterlegt
136 \newcommand{\reqspecsectionstyle}{%
137 \renewcommand{\thesection}{\alph{section}}
139 \def\section{\@ifstar\unnumberedsection\numberedsection}
144 \def\numberedsection{\@ifnextchar[%]
145 \numberedsectionwithtwoarguments\numberedsectionwithoneargument}
146 \def\unnumberedsection{\@ifnextchar[%]
147 \unnumberedsectionwithtwoarguments\unnumberedsectionwithoneargument}
148 \def\numberedsectionwithoneargument#1{\numberedsectionwithtwoarguments[#1]{#1}}
149 \def\unnumberedsectionwithoneargument#1{\unnumberedsectionwithtwoarguments[#1]{#1}}
150 \def\numberedsectionwithtwoarguments[#1]#2{%
154 \refstepcounter{section}%
157 \leavevmode\Large\bfseries\raggedright
159 \put(0,0){\colorbox{kivitendoorange}{\parbox{0.7cm}{\hspace*{0.7cm}\\\vspace*{0.2cm}}}}
161 \hspace*{0.3cm}\textcolor{white}{\thesection{}.}%
167 \addcontentsline{toc}{section}{\protect\numberline{\thesection{}.}#1}%
169 \def\unnumberedsectionwithtwoarguments[#1]#2{%
175 \leavevmode\Large\bfseries\raggedright
176 \leavevmode\Large\bfseries\raggedright