| 1 |
%% This is file `bfh-hkb-doc.cfg' version 2.2.6 (2026-01-12), |
| 2 |
%% it is part of |
| 3 |
%% BFH-CI -- Corporate Design for Bern University of Applied Sciences |
| 4 |
%% ---------------------------------------------------------------------------- |
| 5 |
%% |
| 6 |
%% Copyright (C) 2021--2026 by |
| 7 |
%% Marei Peischl <[email protected]> |
| 8 |
%% Andreas Habegger <[email protected]> |
| 9 |
%% |
| 10 |
%% ============================================================================ |
| 11 |
%% This work may be distributed and/or modified under the |
| 12 |
%% conditions of the LaTeX Project Public License, either version 1.3c |
| 13 |
%% of this license or (at your option) any later version. |
| 14 |
%% The latest version of this license is in |
| 15 |
%% http://www.latex-project.org/lppl.txt |
| 16 |
%% and version 1.3c or later is part of all distributions of LaTeX |
| 17 |
%% version 2008/05/04 or later. |
| 18 |
%% |
| 19 |
%% This work has the LPPL maintenance status `maintained'. |
| 20 |
%% |
| 21 |
%% The Current Maintainers of this work are |
| 22 |
%% Marei Peischl <[email protected]> |
| 23 |
%% Andreas Habegger <[email protected]> |
| 24 |
%% |
| 25 |
%% The development respository can be found at |
| 26 |
%% https://gitlab.ti.bfh.ch/bfh-latex/bfh-ci/ |
| 27 |
%% Please use the issue tracker for feedback! |
| 28 |
%% |
| 29 |
%% ============================================================================ |
| 30 |
%% |
| 31 |
\ProvidesExplFile{bfh-hkb-doc.cfg}{2026-01-12}{2.2.6}{hkb-doc module for bfhthesis} |
| 32 |
\RenewDocumentCommand{\titlegraphic}{sm}{ |
| 33 |
\IfBooleanTF{#1}{ |
| 34 |
\tl_gset:Nn \g_ptxcd_titleimage_code_tl { |
| 35 |
\hbox_set:Nn \l__ptxcd_titlegraphic_box {\raisebox{\depth}{#2}} |
| 36 |
\box_resize_to_ht:Nn \l__ptxcd_titlegraphic_box {\height} |
| 37 |
\dim_compare:nTF {\box_wd:N \l__ptxcd_titlegraphic_box - \width > \c_zero_dim} |
| 38 |
{ |
| 39 |
\dim_set:Nn \l_tmpa_dim {.5\box_ht:N \l__ptxcd_titlegraphic_box - .5\height} |
| 40 |
\clipbox{0pt~\dim_eval:n{\l_tmpa_dim}~0pt~\dim_eval:n{\l_tmpa_dim}}{\box_use:N \l__ptxcd_titlegraphic_box} |
| 41 |
}{ |
| 42 |
\box_use:N \l__ptxcd_titlegraphic_box |
| 43 |
} |
| 44 |
} |
| 45 |
}{ |
| 46 |
\tl_gset:Nn \g_ptxcd_titleimage_code_tl {#2} |
| 47 |
} |
| 48 |
} |
| 49 |
|
| 50 |
\cs_new:Nn \__ptxcd_title_tabular_entry:n { |
| 51 |
\tl_if_in:nnTF {#1} {= } { |
| 52 |
\__ptxcd_title_tabular_entry:w #1 \q_stop |
| 53 |
} { |
| 54 |
\text_titlecase_first:n {#1}\\ |
| 55 |
} |
| 56 |
} |
| 57 |
|
| 58 |
\cs_new:Npn \__ptxcd_title_tabular_entry:w #1 = #2 \q_stop { |
| 59 |
\text_titlecase_first:n {#1}\unskip :& #2 \\ |
| 60 |
} |
| 61 |
|
| 62 |
\seq_new:N \g__ptxcd_projectData_seq |
| 63 |
\newcommand*{\ProjectData}[1]{ |
| 64 |
\seq_gset_from_clist:Nn \g__ptxcd_projectData_seq {#1} |
| 65 |
} |
| 66 |
|
| 67 |
\colorlet{BFH-Title}{black} |
| 68 |
|
| 69 |
\newkomafont{titledata}{\normalfont\footnotesize} |
| 70 |
\setkomafont{disposition}{\bfseries} |
| 71 |
\addtokomafont{subtitle}{\mdseries\LARGE} |
| 72 |
\addtokomafont{caption}{\tiny} |
| 73 |
\setkomafont{caption}{\footnotesize} |
| 74 |
\setkomafont{captionlabel}{\usekomafont{caption}\bfseries} |
| 75 |
|
| 76 |
\setkomafont{pageheadfoot}{\footnotesize} |
| 77 |
\setkomafont{footnote}{} |
| 78 |
\setkomafont{pagenumber}{\fontsize{6pt}{6pt}\selectfont} |
| 79 |
|
| 80 |
\colorlet{BFH-textaccentcolor}{.} |
| 81 |
|
| 82 |
\cs_if_exist:NTF \chapter { |
| 83 |
\RedeclareSectionCommand[ |
| 84 |
beforeskip=0pt |
| 85 |
]{chapter} |
| 86 |
\setkomafont{chapter}{\LARGE} |
| 87 |
\setkomafont{section}{\Large} |
| 88 |
\setkomafont{subsection}{\large} |
| 89 |
\setkomafont{subsubsection}{\mdseries} |
| 90 |
\setkomafont{paragraph}{\mdseries} |
| 91 |
\setkomafont{subparagraph}{\mdseries} |
| 92 |
} { |
| 93 |
\setkomafont{section}{\LARGE} |
| 94 |
\setkomafont{subsection}{\large} |
| 95 |
\setkomafont{subsubsection}{\mdseries} |
| 96 |
\setkomafont{paragraph}{\mdseries} |
| 97 |
\setkomafont{subparagraph}{\mdseries} |
| 98 |
} |
| 99 |
|
| 100 |
\AddToHook{begindocument/end}{ |
| 101 |
\defcaptionname{swissgerman,nswissgerman,german,ngerman}{\refname}{Literaturverzeichnis} |
| 102 |
\defcaptionname{swissgerman,nswissgerman,german,ngerman}{\bibname}{Literaturverzeichnis} |
| 103 |
\defcaptionname{swissgerman,nswissgerman,german,ngerman}{\figurename}{Fig.} |
| 104 |
\defcaptionname{swissgerman,nswissgerman,german,ngerman}{\tablename}{Tab.} |
| 105 |
} |
| 106 |
|
| 107 |
\RedeclareSectionCommand[ |
| 108 |
style=section, |
| 109 |
runin=false, |
| 110 |
afterskip=0pt |
| 111 |
]{paragraph} |
| 112 |
|
| 113 |
\RedeclareSectionCommand[ |
| 114 |
style=section, |
| 115 |
runin=false, |
| 116 |
afterskip=0pt |
| 117 |
]{subparagraph} |
| 118 |
|
| 119 |
\RequirePackage{tabularx} |
| 120 |
|
| 121 |
|
| 122 |
\renewcommand*{\maketitle}[1][1]{ |
| 123 |
\def\and{,~ } |
| 124 |
\cs_if_exist_use:N \ptxcd_pass_TitleData: |
| 125 |
\if@titlepage |
| 126 |
\begin{titlepage} |
| 127 |
\KOMAoptions{fontsize=11pt} |
| 128 |
\setcounter{page}{% |
| 129 |
#1% |
| 130 |
}% |
| 131 |
\def\thefootnote{\fnsymbol{footnote}} |
| 132 |
\setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative |
| 133 |
\thispagestyle{empty}%TODO title. |
| 134 |
\vspace*{-2cm} |
| 135 |
\tl_if_eq:cnTF {BFH-optional-Logo} {true} { |
| 136 |
\raisebox{.75mm}{\includegraphics[height=17mm]{example-image}} |
| 137 |
\hspace{1.25cm}\includegraphics[height=19mm]{example-image} |
| 138 |
}{ |
| 139 |
\raisebox{.75mm}{\includegraphics[height=17mm]{HKB_Markenzeichen\str_if_eq:VnF \g__ptxcd_colormode_tl {RGB} {_CMYK}}} |
| 140 |
\hspace{1.25cm}\includegraphics[height=19mm]{CRC_Logo\str_if_eq:VnF \g__ptxcd_colormode_tl {RGB} {_CMYK}} |
| 141 |
} |
| 142 |
\par |
| 143 |
\vspace{2.15cm} |
| 144 |
\begingroup |
| 145 |
\def\width{\dimexpr14.75cm} |
| 146 |
\def\height{\dimexpr11.1cm} |
| 147 |
\tl_if_empty:NF \g_ptxcd_titleimage_code_tl { |
| 148 |
\g_ptxcd_titleimage_code_tl |
| 149 |
} |
| 150 |
\par |
| 151 |
\endgroup |
| 152 |
\vspace{1.7cm} |
| 153 |
|
| 154 |
\begingroup |
| 155 |
\usekomafont{disposition} |
| 156 |
{\usekomafont{title}\@title\par} |
| 157 |
\endgroup |
| 158 |
|
| 159 |
\ifx\@subtitle\@empty\else{\vspace{.2\baselineskip}\usekomafont{subtitle}\@subtitle\par}\fi |
| 160 |
|
| 161 |
\vfill |
| 162 |
\usekomafont{titledata} |
| 163 |
\begin{tabularx}{\linewidth}{@{}l@{\hspace{1.6em}}X@{}}% |
| 164 |
\seq_map_function:NN \g__ptxcd_projectData_seq \__ptxcd_title_tabular_entry:n |
| 165 |
\end{tabularx} |
| 166 |
\vspace*{-2\baselineskip} |
| 167 |
|
| 168 |
\@thanks\let\@thanks\@empty |
| 169 |
\if@twoside |
| 170 |
\@tempswatrue |
| 171 |
\if@tempswa |
| 172 |
\next@tpage |
| 173 |
\begin{minipage}[t]{\textwidth} |
| 174 |
\@uppertitleback |
| 175 |
\end{minipage}\par |
| 176 |
\vfill |
| 177 |
\begin{minipage}[b]{\textwidth} |
| 178 |
\@lowertitleback |
| 179 |
\end{minipage}\par |
| 180 |
\@thanks\let\@thanks\@empty |
| 181 |
\fi |
| 182 |
\fi |
| 183 |
\ifx\@dedication\@empty |
| 184 |
\else |
| 185 |
\next@tdpage\null\vfill |
| 186 |
{\centering\usekomafont{dedication}{\@dedication \par}}% |
| 187 |
\vskip \z@ \@plus3fill |
| 188 |
\@thanks\let\@thanks\@empty |
| 189 |
\cleardoubleemptypage |
| 190 |
\fi |
| 191 |
\end{titlepage} |
| 192 |
\setcounter{footnote}{0}% |
| 193 |
\global\let\and\relax |
| 194 |
\cleardoublepage |
| 195 |
\else |
| 196 |
\par |
| 197 |
\@tempcnta=% |
| 198 |
#1% |
| 199 |
\relax\ifnum\@tempcnta=1\else |
| 200 |
\ClassWarning{\KOMAClassName}{% |
| 201 |
Optional argument of \string\maketitle\space ignored\MessageBreak |
| 202 |
in `titlepage=false' mode% |
| 203 |
}% |
| 204 |
\fi |
| 205 |
\ifx\@uppertitleback\@empty\else |
| 206 |
\ClassWarning{\KOMAClassName}{% |
| 207 |
non empty \string\uppertitleback\space ignored |
| 208 |
by \string\maketitle\MessageBreak |
| 209 |
in `titlepage=false' mode% |
| 210 |
}% |
| 211 |
\fi |
| 212 |
\ifx\@lowertitleback\@empty\else |
| 213 |
\ClassWarning{\KOMAClassName}{% |
| 214 |
non empty \string\lowertitleback\space ignored |
| 215 |
by \string\maketitle\MessageBreak |
| 216 |
in `titlepage=false' mode% |
| 217 |
}% |
| 218 |
\fi |
| 219 |
\begingroup |
| 220 |
\let\titlepage@restore\relax |
| 221 |
\def\thefootnote{\fnsymbol{footnote}} |
| 222 |
\next@tdpage |
| 223 |
\ifx\@extratitle\@empty |
| 224 |
\ifx\@frontispiece\@empty\else \mbox{}\fi |
| 225 |
\else |
| 226 |
\@makeextratitle |
| 227 |
\fi |
| 228 |
\ifx\@frontispiece\@empty |
| 229 |
\ifx\@extratitle\@empty\else\next@tdpage\fi |
| 230 |
\else |
| 231 |
\next@tpage |
| 232 |
\@makefrontispiece |
| 233 |
\next@tdpage |
| 234 |
\fi |
| 235 |
\if@twocolumn |
| 236 |
\twocolumn[\@maketitle] |
| 237 |
\else |
| 238 |
\@maketitle |
| 239 |
\fi |
| 240 |
\ifx\titlepagestyle\@empty\else\thispagestyle{\titlepagestyle}\fi |
| 241 |
\global\let\@thanks\@empty |
| 242 |
\endgroup |
| 243 |
\fi |
| 244 |
} |
| 245 |
|
| 246 |
|
| 247 |
\clearpairofpagestyles |
| 248 |
\ofoot[\pagemark]{\pagemark} |
| 249 |
|
| 250 |
% disable adjustment of \labelitemi |
| 251 |
\RemoveFromHook{begindocument/end}[bfh-ci-label] |
| 252 |
|
| 253 |
% margins |
| 254 |
\dim_if_exist:NF \g_ptxcd_innerMargin_dim { |
| 255 |
\dim_new:N \g_ptxcd_innerMargin_dim |
| 256 |
\dim_new:N \g_ptxcd_outerMargin_dim |
| 257 |
\dim_new:N \g_ptxcd_bottomMargin_dim |
| 258 |
\dim_new:N \g_ptxcd_topMargin_dim |
| 259 |
\dim_new:N \g_ptxcd_topLogoMargin_dim |
| 260 |
\dim_new:N \g_ptxcd_columnSep_dim |
| 261 |
\RequirePackage{geometry} |
| 262 |
} |
| 263 |
\dim_gset:Nn \g_ptxcd_columnSep_dim {4mm} |
| 264 |
|
| 265 |
\dim_gset:Nn \g_ptxcd_topMargin_dim {26mm} |
| 266 |
\dim_gset:Nn \g_ptxcd_bottomMargin_dim {15mm}%20mm} |
| 267 |
\dim_gset:Nn \g_ptxcd_innerMargin_dim {35mm} |
| 268 |
\dim_gset:Nn \g_ptxcd_outerMargin_dim {28mm}%12mm} |
| 269 |
\dim_gset:Nn \g_ptxcd_topLogoMargin_dim {25mm} |
| 270 |
|
| 271 |
\geometry{ |
| 272 |
includefoot, |
| 273 |
% footskip=\dim_eval:n {\footskip+\baselineskip}, |
| 274 |
top=\g_ptxcd_topMargin_dim, |
| 275 |
inner=\g_ptxcd_innerMargin_dim, |
| 276 |
outer=\dim_eval:n {\g_ptxcd_outerMargin_dim}, |
| 277 |
bottom=\dimexpr\g_ptxcd_bottomMargin_dim-\dp\strutbox, |
| 278 |
columnsep= \g_ptxcd_columnSep_dim, |
| 279 |
} |
| 280 |
|
| 281 |
|
| 282 |
\KOMAoptions{ |
| 283 |
bibliography=totoc, |
| 284 |
listof=totoc, |
| 285 |
parskip=full, |
| 286 |
fontsize=9bp, |
| 287 |
headsepline=false, |
| 288 |
captions=nooneline, |
| 289 |
footwidth=\dimexpr\textwidth+13mm, |
| 290 |
} |
| 291 |
|
| 292 |
\DeclareTOCStyleEntries[beforeskip=1ex]{tocline}{section,subsection,subsubsection,paragraph,subparagraph} |
| 293 |
|
| 294 |
\cs_if_exist:NTF \chapter { |
| 295 |
\DeclareTOCStyleEntries[beforeskip=\baselineskip]{tocline}{chapter} |
| 296 |
}{ |
| 297 |
\DeclareTOCStyleEntries[beforeskip=\baselineskip]{tocline}{section} |
| 298 |
} |
| 299 |
|
| 300 |
|
| 301 |
\setcounter{secnumdepth}{\subparagraphnumdepth} |
| 302 |
\setcounter{tocdepth}{\subparagraphnumdepth} |
| 303 |
|
| 304 |
\raggedbottom |
| 305 |
|
| 306 |
\iftutex |
| 307 |
\setsansfont{texgyreheros}[Scale=1.1,LetterSpace=1.3] |
| 308 |
\fi |
| 309 |
\renewcommand*{\familydefault}{\sfdefault} |
| 310 |
|
| 311 |
\endinput |