config.tex 3.05 KB
Newer Older
Simon Spannagel's avatar
Simon Spannagel committed
1
2
3
4
5
% Add command to display allpix squared
\DeclareMathAlphabet\mathbfcal{OMS}{cmsy}{b}{n}
\newcommand{\corry}{$\mathcal{C}$orryvreckan\xspace}
\newcommand{\corrybold}{$\mathbfcal{C}$\textbf{orryvreckan}\xspace}

6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
% Temporary TODO commands
% \newcommand{\comment}[1]{#1} % DRAFT
\newcommand{\comment}[1]{} % FINAL

\newcommand{\needcite}{\comment{[CITE?] }}
\newcommand{\needref}{\comment{[REF?] }}
\newcommand{\todo}[1]{\comment{[TODO: #1] }}

\newcommand{\wip}{\textit{This section is not written yet.}}

% Paragraph with new line
\newcommand{\nlparagraph}[1]{\paragraph{#1}\mbox{}\\}

% Typeset framework parameter and escape underscores:
\DeclareUrlCommand\parameter{\bfseries\urlstyle{tt}}
21
22
23
24
25
\newcommand{\command}[1]{\parameter{#1}}

% Typeset directory and file names
\DeclareUrlCommand\dir{\urlstyle{tt}}
\newcommand{\file}[1]{\dir{#1}}
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46

% Define ini format used in the converted Markdown files
\lstdefinelanguage{Ini}
{
    basicstyle=\ttfamily\small,
    columns=fullflexible,
    morecomment=[s][\color{blue}\bfseries]{[}{]},
    morecomment=[l]{\#},
    morecomment=[l]{;},
    commentstyle=\color{gray}\ttfamily,
    alsoletter={=},
    morekeywords={=},
    otherkeywords={},
    keywordstyle={\color{green}\bfseries}
}

% Warning box
\newsavebox{\warningbox}
\newenvironment{warning}
  {\newcommand\colboxcolor{pink}%
   \begin{lrbox}{\warningbox}%
47
   \begin{minipage}{\dimexpr\linewidth-2em\relax}}
48
49
  {\end{minipage}\end{lrbox}%
   \begin{center}
50
51
     \setlength\fboxsep{0pt}
     \colorbox{\colboxcolor}{\setlength\fboxsep{1em}\fbox{\usebox{\warningbox}}}
52
53
54
  \end{center}}

% Command to add all modules
55
\newcommand{\includemodulesmd}{\def\temp{@CORRYVRECKAN_MODULE_FILES@}\ifx\temp\empty
56
  \textit{Module documentation not added because Markdown to \LaTeX~conversion was not possible. Pandoc is required for the conversion.}
57
\else
58
  \foreach \n in @CORRYVRECKAN_MODULE_FILES@ {\input{\n}}
59
60
61
\fi}

% Command to add a single converted markdown file
62
63
64
65
66
\newcommand{\inputmd}[1]{\def\temp{@other_tex_files@}\ifx\temp\empty
  \textit{This section is missing Markdown to \LaTeX~conversion was not possible. Pandoc is required for the conversion.}
\else
  \input{md/#1}
\fi}
67
68
69
70
71
72
73
74
75

% Set bibliography
\addbibresource{usermanual/references.bib}

% Set version
\newcommand{\version}{\lstinline|@CORRYVRECKAN_VERSION@|}
\newcommand{\project}{@CMAKE_PROJECT_NAME@}

% Create addreferences command (overwritten for HTML in config)
76
\newcommand{\addreferencesline}{\addcontentsline{toc}{chapter}{References}}
77
78
79

% Command to add the license (overwritten for HTML in config)
\newcommand{\addlicense}{
Simon Spannagel's avatar
Simon Spannagel committed
80
\begin{table}[H]
81
82
83
84
85
86
87
88
89
90
\centering
\renewcommand{\arraystretch}{1.5}% Spread rows out...
\begin{tabular}{>{\centering\arraybackslash}m{.10\textwidth}>{\raggedright\arraybackslash}m{.90\textwidth}}
 \Large{\ccLogo \ccAttribution} & \footnotesize{This manual is licensed under the Creative Commons Attribution 4.0 International License.\newline To view a copy of this license, visit \url{http://creativecommons.org/licenses/by/4.0/}.} \\
\end{tabular}
\end{table}
}

% Use new lines in FAQ (fixed for HTML in config)
\setlist[description]{style=nextline}