|
| 1 | +\DocumentMetadata |
| 2 | +{ |
| 3 | +lang=de-DE, |
| 4 | +pdfstandard=UA-2, |
| 5 | +testphase= |
| 6 | +{phase-III, |
| 7 | + title, |
| 8 | + table, |
| 9 | + firstaid} |
| 10 | +} |
| 11 | +% |
| 12 | +\documentclass[8pt, a4paper]{article} |
| 13 | +\usepackage[ngerman]{babel} |
| 14 | +\usepackage{amsmath,amssymb} |
| 15 | +\usepackage{iftex} |
| 16 | +\usepackage{geometry} |
| 17 | +\usepackage{xcolor} |
| 18 | +\usepackage{tikz} |
| 19 | +\usepackage{microtype} |
| 20 | +\usepackage[absolute,overlay]{textpos} |
| 21 | +\usepackage{tocloft} |
| 22 | +% Gets corrected using \newgeometry{...} in the document |
| 23 | +% Used for the cover page |
| 24 | +\geometry{top=0pt, left=0pt, right=0pt, bottom=0pt} |
| 25 | + |
| 26 | +% import our custom fonts |
| 27 | +\usepackage{fontspec} |
| 28 | +\newfontfamily{Inter}[Path=$template_path$/assets/font/,Extension=.ttf, |
| 29 | + UprightFont=*-Regular, BoldFont=*-Bold, ItalicFont=*-Italic, BoldItalicFont=*-BoldItalic] |
| 30 | + |
| 31 | +\setmainfont{Inter} |
| 32 | +\setmonofont{Inter} |
| 33 | + |
| 34 | +% import our custom fonts |
| 35 | +\usepackage{hyperref} % clickable URls and cross-references |
| 36 | +\hypersetup{ |
| 37 | + urlbordercolor=black, |
| 38 | + urlcolor=yellow, |
| 39 | + pdfborderstyle={/S/U/W 1}, % underline links instead of boxes |
| 40 | + linktoc=all, |
| 41 | + pdftitle={$document_title$ - Version: $version$}, |
| 42 | + pdfdisplaydoctitle=true, |
| 43 | + pdflang={de}, |
| 44 | + pdfstartview=FitH, |
| 45 | + bookmarksnumbered=true, |
| 46 | + bookmarkstype=toc, |
| 47 | + bookmarks=true |
| 48 | +} |
| 49 | + |
| 50 | +$for(header-includes)$ |
| 51 | +$header-includes$ |
| 52 | +$endfor$ |
| 53 | + |
| 54 | +%%%%%%%%%%%%%%%%%%%% |
| 55 | +\makeatletter |
| 56 | +% change the font size of the section titles |
| 57 | +\renewcommand\LARGE{\@setfontsize\LARGE{17pt}{16}} |
| 58 | +\renewcommand\Large{\@setfontsize\Large{15pt}{14}} |
| 59 | +\renewcommand\normalsize{\@setfontsize\normalsize{10pt}{18}} |
| 60 | +\renewcommand\footnotesize{\@setfontsize\footnotesize{8pt}{9}} |
| 61 | +\renewcommand\small{\@setfontsize\small{8pt}{9}} |
| 62 | +% remove ident in toc |
| 63 | +\renewcommand*\l@subsection{\@dottedtocline{2}{0pt}{2.3em}} |
| 64 | +\setlength{\parindent}{0pt} |
| 65 | +\setlength{\parskip}{6pt plus 2pt minus 1pt} |
| 66 | + |
| 67 | +\usepackage{longtable,booktabs,array} |
| 68 | +\usepackage{calc} % for calculating minipage widths |
| 69 | +% Correct order of tables after \paragraph or \subparagraph |
| 70 | +\usepackage{etoolbox} |
| 71 | + |
| 72 | +\patchcmd\longtable{\par}{\if@noskipsec\mbox{}\fi\par}{}{} |
| 73 | + |
| 74 | +\usepackage{graphicx} |
| 75 | +\def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth\else\Gin@nat@width\fi} |
| 76 | +\def\maxheight{\ifdim\Gin@nat@height>\textheight\textheight\else\Gin@nat@height\fi} |
| 77 | +% Scale images if necessary, so that they will not overflow the page |
| 78 | +% margins by default, and it is still possible to overwrite the defaults |
| 79 | +% using explicit options in \includegraphics[width, height, ...]{} |
| 80 | +\setkeys{Gin}{width=\maxwidth,height=\maxheight,keepaspectratio} |
| 81 | +\def\fps@figure{htbp} |
| 82 | + |
| 83 | +\makeatother |
| 84 | +%%%%%%%%%%%%%%%%%%%% |
| 85 | + |
| 86 | +\usepackage{setspace} |
| 87 | + |
| 88 | +%change the footnote spacing between text and footnote |
| 89 | +\setlength{\skip\footins}{1cm} |
| 90 | +% space between footnotes |
| 91 | +\setlength{\footnotesep}{0.5cm} |
| 92 | + |
| 93 | +\usepackage{fancyhdr} |
| 94 | +\usepackage{lipsum}% just to generate text for the example |
| 95 | + |
| 96 | +% header title and page number |
| 97 | +\fancyhf{} |
| 98 | +\fancyhead[L]{\small\rightmark} |
| 99 | +\fancyhead[R]{\small\thepage} |
| 100 | + |
| 101 | +\fancyhead[C]{\sffamily\small{DevGuard SBOM Report for $app_title_part_one$ $app_title_part_two$ ($version$)}} |
| 102 | + |
| 103 | +% only sections inside the header - not subsections |
| 104 | +\renewcommand\subsectionmark[1]{} |
| 105 | +\renewcommand{\sectionmark}[1]{\markright{#1}} |
| 106 | + |
| 107 | +\setlength{\emergencystretch}{3em} % prevent overfull lines |
| 108 | +\providecommand{\tightlist}{% |
| 109 | + \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}} |
| 110 | + |
| 111 | + |
| 112 | +\author{} |
| 113 | +\date{} |
| 114 | + |
| 115 | +% define a color box for the different controls |
| 116 | +\usepackage[most]{tcolorbox} |
| 117 | +\definecolor{block-gray}{gray}{0.85} |
| 118 | +\definecolor{subblock-gray}{gray}{0.95} |
| 119 | +\definecolor{black}{rgb}{0,0,0} |
| 120 | +\definecolor{primary}{rgb}{0.059,0.071,0.086} |
| 121 | +\definecolor{white}{rgb}{1,1,1} |
| 122 | + |
| 123 | +\newtcolorbox{controlbox}{colback=block-gray,left=4pt,right=4pt,top=4pt,bottom=4pt, |
| 124 | +boxrule=0pt,boxsep=0pt,breakable,sharp corners,after=\vspace{0pt}} |
| 125 | +\newtcolorbox{controlsubbox}{colback=subblock-gray,left=4pt,right=4pt,top=4pt,bottom=4pt, |
| 126 | +boxrule=0pt,boxsep=0pt,breakable,sharp corners,before=\vspace{-2pt}} |
| 127 | + |
| 128 | +% removes the huge padding around lists |
| 129 | +\usepackage{enumitem} |
| 130 | +\setlist[itemize]{topsep=0pt, partopsep=0pt, parsep=0pt, itemsep=0pt} |
| 131 | + |
| 132 | +\usepackage{afterpage} |
| 133 | +\newcommand\blankpage{% |
| 134 | + \null |
| 135 | + \thispagestyle{empty}% |
| 136 | + \addtocounter{page}{-1}% |
| 137 | + \newpage} |
| 138 | + |
| 139 | +\newcommand\emptypage{% |
| 140 | + \null |
| 141 | + \thispagestyle{empty}% |
| 142 | + \newpage} |
| 143 | + |
| 144 | +\renewcommand{\cftfigpresnum}{Abbildung } |
| 145 | +\setlength{\cftfignumwidth}{6em} |
| 146 | + |
| 147 | +\makeatletter |
| 148 | +\let\@cftmakeloftitle\relax |
| 149 | +\makeatother |
| 150 | + |
| 151 | +\usepackage{setspace} |
| 152 | + |
| 153 | +\begin{document} |
| 154 | + |
| 155 | +% cover page 1 - U1 |
| 156 | +\begin{titlepage} |
| 157 | + \pagecolor{primary} |
| 158 | + \begin{picture}(-5,0)(2.5,0) |
| 159 | + \put(0,-830){\includegraphics[alt={Hintergrundbild},width=\paperwidth,height=\paperheight]{$template_path$/assets/background.png}} |
| 160 | + \put(70,-140){\fontsize{40}{1}\selectfont\color{white}\textbf{DevGuard SBOM Report}} |
| 161 | + \put(38,-620){\fontsize{11}{1}\selectfont\color{white}\textbf{$generation_date$}} |
| 162 | + \put(38,-680){\parbox{55mm}{\raggedright\fontsize{16}{1}\selectfont\color{white}\textbf{$app_title_part_one$}}} |
| 163 | + \put(38,-700){\parbox{55mm}{\raggedright\fontsize{16}{1}\selectfont\color{white}\textbf{$app_title_part_two$}}} |
| 164 | + \put(254,-620){\fontsize{11}{1}\selectfont\color{white}\textbf{Prepared for:}} |
| 165 | + \put(254,-640){\fontsize{11}{1}\selectfont\color{white}$organization_name$} |
| 166 | + \put(380,-620){\fontsize{11}{1}\selectfont\color{white}\textbf{Integrity:}} |
| 167 | + \put(380,-640){\parbox{50mm}{\raggedright\fontsize{8}{1}\selectfont\color{white}$integrity$}} |
| 168 | + \put(300,-696){\fontsize{11}{1}\selectfont\color{white}\textbf{Prepared by:}} |
| 169 | + \put(300,-716){\fontsize{11}{1}\selectfont\color{white}DevGuard} |
| 170 | + \put(38,-800){\fontsize{8}{1}\selectfont\color{white}devguard.org} |
| 171 | + \put(460,-800){\fontsize{8}{1}\selectfont\color{white}community@devguard.org} |
| 172 | + \end{picture} |
| 173 | +\end{titlepage} |
| 174 | +\pagecolor{white} |
| 175 | +\clearpage |
| 176 | + |
| 177 | +% correct the margins of the pdf document |
| 178 | +\newgeometry{left=2.5cm, right=2.5cm, top=3cm, bottom=2cm} |
| 179 | +\pagestyle{fancy} |
| 180 | + |
| 181 | + |
| 182 | +%%%% |
| 183 | +% Main Document Content |
| 184 | +%%%% |
| 185 | +$body$ |
| 186 | + |
| 187 | + |
| 188 | +$for(include-after)$ |
| 189 | +$include-after$ |
| 190 | +$endfor$ |
| 191 | + |
| 192 | +\clearpage |
| 193 | + |
| 194 | +% cover page 4 - U4 |
| 195 | +\thispagestyle{empty} |
| 196 | +\normalsize\color{white} |
| 197 | +\pagecolor{primary} |
| 198 | + |
| 199 | +\begin{tikzpicture}[remember picture,overlay] |
| 200 | + \node at (current page.south east) [xshift=-0.5cm, yshift=0.5cm, anchor=south east] { |
| 201 | + \includegraphics[width=2cm]{$template_path$/assets/qr.png} |
| 202 | + }; |
| 203 | +\end{tikzpicture} |
| 204 | +\begin{textblock*}{5cm}(0.75cm,27.75cm) % {block width} (coords) |
| 205 | + \url{devguard.org}\\ |
| 206 | +\end{textblock*} |
| 207 | + |
| 208 | +\end{document} |
0 commit comments