From 9f67495e9fd4d9c7c49facf920e0f751d19b4b6d Mon Sep 17 00:00:00 2001
From: Yoann Guilhem <yoann.guilhem@esrf.fr>
Date: Wed, 12 Sep 2012 13:27:42 +0000
Subject: [PATCH] Documentation: - translate sources + Preamble.tex into
 DCTDoc.cls document class - fix title pages - fix Makefile

git-svn-id: https://svn.code.sf.net/p/dct/code/trunk@733 4c865b51-4357-4376-afb4-474e03ccb993
---
 DCT_Documentation/DCTDoc.cls                | 228 ++++++++++++++++++++
 DCT_Documentation/Makefile                  |  35 ++-
 DCT_Documentation/common/Preamble.tex       | 162 --------------
 DCT_Documentation/main.tex                  |  52 ++---
 DCT_Documentation/main/titlepage.tex        |   7 +
 DCT_Documentation/user_manual.tex           |  32 +--
 DCT_Documentation/user_manual/titlepage.tex |  11 +-
 7 files changed, 279 insertions(+), 248 deletions(-)
 create mode 100644 DCT_Documentation/DCTDoc.cls
 delete mode 100644 DCT_Documentation/common/Preamble.tex
 create mode 100644 DCT_Documentation/main/titlepage.tex

diff --git a/DCT_Documentation/DCTDoc.cls b/DCT_Documentation/DCTDoc.cls
new file mode 100644
index 00000000..f9adcd99
--- /dev/null
+++ b/DCT_Documentation/DCTDoc.cls
@@ -0,0 +1,228 @@
+\NeedsTeXFormat{LaTeX2e}
+ 
+\ProvidesClass{DCTDoc}[2012/08/30 v1.0 DCT documentation class]
+
+% Passes and class options to the underlying article class
+\DeclareOption*{\PassOptionsToClass{\CurrentOption}{scrreprt}}
+\ProcessOptions
+
+\LoadClass[a4paper,12pt,twoside,openright,final,
+           titlepage,
+           pagesize,
+           headsepline,
+           nofootsepline,
+           onelinecaption,
+           tablecaptionabove,
+           liststotoc,
+           idxtotoc,
+           bibtotoc,
+           tocindent,
+           nochapterprefix,
+           appendixprefix]{scrreprt}[2009/07/24]
+
+% \@ifclasslater{scrreprt}{2009/07/24}{
+% % With koma-script >= 3.0
+% \LoadClass[a4paper,12pt,twoside,openright,final]{scrreprt}[2009/07/24]
+% %\LoadClass[a4paper,12pt,twoside,openright,final]{scrreprt}
+% 
+% \KOMAoption{titlepage}{true}
+% \KOMAoptions{pagesize}
+% %\KOMAoption{pagesize}{true}
+% \KOMAoption{headsepline}{true}
+% \KOMAoption{footsepline}{false}
+% \KOMAoption{captions}{oneline,tableabove}
+% \KOMAoption{toc}{listof,bibliography,indent,index}
+% %\KOMAoptions{DIV13}{true}             % type area
+% %\KOMAoptions{bigheadings}{true}
+% %\KOMAoption{pointlessnumbers}{true}
+% \KOMAoption{chapterprefix}{false}
+% \KOMAoption{appendixprefix}{true}
+% %\KOMAoption{BCOR}{15mm}               % binding correction
+% %\KOMAoption{cleardoublepage}{empty}
+% %\KOMAoption{parskip}{}
+% }{
+% \LoadClass[a4paper,12pt,twoside,openright,final,
+%            titlepage,
+%            pagesize,
+%            headsepline,
+%            footsepline,
+%            onelinecaption,
+%            tablecaptionabove,
+%            liststotoc,
+%            idxtotoc,
+%            bibtotoc,
+%            tocindent,
+%            chapterprefix=false,
+%            appendixprefix]{scrreprt}
+% }
+% 
+% %\KOMAoptions{DIV13=true}             % type area
+% %\KOMAoptions{bigheadings=true}
+% %\KOMAoptions{pointlessnumbers==true}
+% %\KOMAoptions{BCOR=15mm}               % binding correction
+% %\KOMAoptions{cleardoublepage=empty}
+% %\KOMAoptions{parskip=}
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%                   (1) PACKAGES                       %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+\RequirePackage[latin1]{inputenc} % use applemac if you are on an apple laptop, ansinew for Windows, but latin1 should be fine for most systems
+\RequirePackage[T1]{fontenc}
+\RequirePackage{lmodern}
+\RequirePackage{textcomp}
+\RequirePackage[pdftex]{graphicx}
+\RequirePackage[pdftex]{color}
+\RequirePackage{a4}
+\RequirePackage{acronym} % texlive-latex-extra should be installed to compile with acronym style
+\RequirePackage{makeidx}
+\RequirePackage[numbers,sort&compress]{natbib} % for bibliography
+\RequirePackage{appendix}
+
+\RequirePackage{subfigure} % almost OBSOLETE (but not for tetex-3.0) -> switch to subfig or subcaption
+
+\RequirePackage{amsmath,amssymb,amsbsy} % match package, eg align statt eqnarray
+\RequirePackage{amsfonts}     % Set of miscellaneous TeX fonts that augment the standard Computer Modern set normally distributed with TeX
+\RequirePackage{xspace}       % Extra spaces and lengths
+\RequirePackage{enumerate}    % Enhanced enumerations
+\RequirePackage{multirow}     % multi-row cells in the tables
+\RequirePackage{multicol}     % multi-column layout
+\RequirePackage{longtable}    % Long tables over multiple pages
+\RequirePackage[cm]{fullpage} % Shorter margins, wider text layout
+\RequirePackage{fancyhdr}     % For headers and footers
+\RequirePackage{listings}     % To insert code
+%\RequirePackage[2007/09/29]{kvsetkeys}
+%\RequirePackage{svn-multi}  % To interact with svn
+\RequirePackage[pdftex, colorlinks=true, pdfstartview=FitV, linkcolor=red, citecolor=green, urlcolor=blue]{hyperref} % hyperlinks
+\RequirePackage[all]{hypcap}
+\RequirePackage[english]{babel}
+\RequirePackage{caption}     % Latest caption package
+%\RequirePackage{subcaption}  % Too recent for teTeX-3.0
+
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%                   (2) SETTINGS                       %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% If you put this into your preamble, floats on pages of their own will appear at the top of the page.
+% If it's too high just take a different value than 0pt.  
+% fig or tab alone on page no longer in center
+\makeatletter
+\setlength{\@fptop}{0pt}
+\makeatother
+
+% Use \index{word} to tag special expressions \printindex will then give you word-page-index
+\makeindex
+
+\setcounter{tocdepth}{1}
+\setcounter{secnumdepth}{1}
+\uchyph=0 % stop hypenation of upper case words
+% Distance to figures in floatin environment
+%\setlength{\intextsep}{3mm plus2mm minus2mm}
+%\setlength{\abovecaptionskip}{0mm}
+%\setlength{\belowcaptionskip}{0mm}
+
+% Fix header layout and space
+\pagestyle{headings}
+\headsep=20pt
+\headheight=14.2pt
+
+% Remove all indentation
+\setlength{\parindent}{0pt}
+
+% autoref names, you can change here the default behaviour link names
+\renewcommand{\figureautorefname}{fig.}
+\newcommand{\subfigureautorefname}{fig.}
+\renewcommand{\tableautorefname}{tab.}
+\renewcommand{\chapterautorefname}{chap.}
+\renewcommand{\sectionautorefname}{sect.}
+\renewcommand{\subsectionautorefname}{subsect.}
+\renewcommand{\equationautorefname}{eq.}
+
+% Cosmetics
+\renewcommand{\setthesection}{\Alph{section}}
+\renewcommand{\labelitemi}{$\bullet$}
+\renewcommand{\labelitemii}{$\diamond$}
+\renewcommand{\labelitemiii}{$\ast$}
+\renewcommand{\labelitemiv}{$\cdot$}
+
+% Colors
+\definecolor{codeBG}{gray}{0.9}
+\definecolor{outBG}{gray}{0.75}
+
+% Code listing settings
+\lstset{
+basicstyle=\ttfamily,
+breaklines=true
+}
+\lstdefinestyle{intext}{
+basicstyle=\ttfamily
+}
+\lstdefinestyle{outoftext}{
+basicstyle=\ttfamily\small,
+backgroundcolor=\color{codeBG},
+prebreak=...,
+postbreak=...
+}
+\lstdefinestyle{outoftext2}{
+basicstyle=\ttfamily\small,
+backgroundcolor=\color{outBG},
+prebreak=...,
+postbreak=...
+}
+\lstloadlanguages{sh,bash,Matlab,Python,Octave,C,C++}
+
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%                  (3) COMMANDS                        %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% define here useful and often used commands to shorten writing unless you define it in acronyms
+\newcommand{\dct}{Diffraction Contrast Tomography}
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%
+% LaTeX commands to print:
+%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% files, directories, pathes in text
+\def\file{\lstinline[language=,basicstyle=\sl]}
+
+% Matlab and shell commands in text
+\def\mCom{\lstinline[language=Matlab,basicstyle=\tt]}
+\def\sCom{\lstinline[language=sh,basicstyle=\tt]}
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Environments to print out-of-text multiline code:
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% Matlab code
+\lstnewenvironment{mCode}
+{\lstset{language=Matlab,style=outoftext}}
+{}
+
+% C code
+\lstnewenvironment{cCode}
+{\lstset{language=C,style=outoftext}}
+{}
+
+% C++ code
+\lstnewenvironment{cppCode}
+{\lstset{language=C++,style=outoftext}}
+{}
+
+% sh code
+\lstnewenvironment{shCode}
+{\lstset{language=sh,style=outoftext}}
+{}
+
+% any code
+\lstnewenvironment{Code}
+{\lstset{language=,style=outoftext}}
+{}
+
+% output
+\lstnewenvironment{mOut}
+{\lstset{language=,style=outoftext2}}
+{}
+
+\endinput
diff --git a/DCT_Documentation/Makefile b/DCT_Documentation/Makefile
index 4ff7f30e..196c822b 100644
--- a/DCT_Documentation/Makefile
+++ b/DCT_Documentation/Makefile
@@ -2,6 +2,9 @@
 #  Variables  #
 ###############
 
+# Document class
+CLASS = DCTDoc.cls
+
 # Main documentation
 MAIN = main
 MAIN_TEXFILES = $(wildcard $(MAIN)/*.tex)
@@ -22,9 +25,10 @@ PLOT_FILES    = $(wildcard plots/*.*)
 GRAPHIC_FILES = $(PHOTO_FILES) $(FIGURE_FILES) $(PLOT_FILES)
 
 # Dependencies
-MAIN_DEP  = $(MAIN_TEXFILES) $(COMMON) $(FUNCTIONS) $(BIB_FILES) $(GRAPHIC_FILES)
-USER_DEP  = $(USER_TEXFILES) $(COMMON) $(FUNCTIONS) $(BIB_FILES) $(GRAPHIC_FILES)
-DOCUMENTS = $(MAIN) $(USER_MANUAL)
+COMMON_DEP = $(CLASS) $(COMMON) $(FUNCTIONS) $(BIB_FILES) $(GRAPHIC_FILES)
+MAIN_DEP   = $(MAIN_TEXFILES) $(COMMON_DEP)
+USER_DEP   = $(USER_TEXFILES) $(COMMON_DEP)
+DOCUMENTS  = $(MAIN) $(USER_MANUAL)
 
 # Shell and commands
 SHELL  = /bin/sh
@@ -33,7 +37,7 @@ RM     = /bin/rm
 LS     = /bin/ls
 #LATEX  = pdflatex --interaction nonstopmode -shell-escape
 LATEX  = pdflatex -halt-on-error -shell-escape
-BIBTEX = bibtex
+BIBTEX = bibtex --terse
 VIEWER = evince
 
 # Check if it is needed to rerun LaTeX
@@ -41,8 +45,6 @@ RERUN     = 'There were undefined references|Rerun to get (cross-references|cita
 # Check if all references and citations are defined 
 UNDEFINED = '(Reference|Citation) `[[:alnum:]:_-]*[[:punct:]] on page [[:digit:]]+ undefined on input line [[:digit:]]+\.|Label `[[:alnum:]:_-]*[[:punct:]] multiply defined.|Acronym `[[:alnum:]:_-]*[[:punct:]] is not defined on input line [[:digit:]]+\.'
 
-Package acronym Warning: Acronym `OAR' is not defined on input line 105.
-
 # Colors
 RED   =\033[31m
 NORMAL=\033[0m
@@ -52,20 +54,14 @@ BOLD  =\033[1m
 #  Targets  #
 #############
 
-.PHONY: all main user_manual example clean reallyclean help
+.PHONY: all main user_manual clean reallyclean help
 
-all: $(MAIN).pdf $(USER_MANUAL).pdf
+all: main user_manual
 
 main: $(MAIN).pdf
 
 user_manual: $(USER_MANUAL).pdf
 
-example: f_example.tex $(FUNCTIONS)
-	@$(LATEX) $<
-	@grep -qE $(RERUN) $(f_example).log && $(LATEX) $<
-	@grep -qE $(RERUN) $(f_example).log && $(LATEX) $<
-	@$(call f_info,f_example)
-
 $(MAIN).pdf: $(MAIN).tex $(MAIN_DEP)
 	@$(call f_compile,$(MAIN))
 	@$(call f_info,$(MAIN))
@@ -105,17 +101,14 @@ help:
 
 define f_compile
   $(LATEX) $1
-  $(BIBTEX) $(1)
-  grep -qE $(RERUN) $(1).log && $(LATEX) $<
-  grep -qE $(RERUN) $(1).log && $(LATEX) $<
+  $(BIBTEX) $1
+  grep -qE $(RERUN) $1.log && $(LATEX) $1 || true 
+  grep -qE $(RERUN) $1.log && $(LATEX) $1 || true
+  grep -qE $(RERUN) $1.log && $(LATEX) $1 || true
 endef
 
 define f_info
   $(ECHO) "-----------------------------------------"
-  # This work but it is ugly when undefined references
-  #if [ -f $1.blg ] ; then $(ECHO) -n "BibTeX Warnings : $(RED)" && grep '^Warning' $1.blg || $(ECHO) "$(NORMAL)None ; fi
-  #grep -iE $(UNDEFINED) $1.log || $(ECHO) "$(NORMAL)None"
-  # This work better
   if [ -f $1.blg ] ; then $(ECHO) -n "BibTeX Warnings : " && ($(ECHO) "$(RED)"; grep '^Warning' $1.blg) | sed '$$s/^\x1b\[31m$$/\x1b[0mNone/' ; fi
   $(ECHO) -n "$(NORMAL)Citations or references undefined : "
   ($(ECHO) "$(RED)"; cat $1.log | tr -d '\n' | grep -Eio $(UNDEFINED)) | sed '$$s/^\x1b\[31m$$/\x1b[0mNone/'
diff --git a/DCT_Documentation/common/Preamble.tex b/DCT_Documentation/common/Preamble.tex
deleted file mode 100644
index b49461d8..00000000
--- a/DCT_Documentation/common/Preamble.tex
+++ /dev/null
@@ -1,162 +0,0 @@
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%                   (1) PACKAGES                       %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-\usepackage[latin1]{inputenc} % use applemac if you are on an apple laptop, ansinew for Windows, but latin1 should be fine for most systems
-\usepackage[T1]{fontenc}
-\usepackage{lmodern}
-\usepackage{textcomp}
-\usepackage[pdftex]{graphicx}
-\usepackage[pdftex]{color}
-\usepackage{a4}
-\usepackage{acronym} % texlive-latex-extra should be installed to compile with acronym style
-\usepackage{makeidx}
-\usepackage[numbers,sort&compress]{natbib} % for bibliography
-\usepackage{appendix}
-
-\usepackage{subfigure} % almost OBSOLETE -> switch to subfig or subcaption
-
-\usepackage{amsmath,amssymb,amsbsy} % match package, eg align statt eqnarray
-\usepackage{amsfonts} % set of miscellaneous TeX fonts that augment the standard Computer Modern set normally distributed with TeX
-\usepackage{xspace} % extra spaces and lengths
-\usepackage{enumerate} % enumerate geht einfach zu aendern zb zu latein 2 anfangen
-\usepackage{multirow} % multi-row cells in the tables
-\usepackage{multicol} % multi-column layout
-\usepackage{longtable} % long tables over multiple pages
-\usepackage[cm]{fullpage} % shorten margin, wider text layout
-\usepackage{fancyhdr} % For headers and footers
-\usepackage{listings} % To insert code
-%\usepackage[2007/09/29]{kvsetkeys}
-%\usepackage{svn-multi}  % To interact with svn
-\usepackage[pdftex, colorlinks=true, pdfstartview=FitV, linkcolor=red, citecolor=green, urlcolor=blue]{hyperref} % hyperlinks
-\usepackage[all]{hypcap}
-\usepackage[english]{babel}
-\usepackage{caption}     % Latest caption package
-%\usepackage{subcaption} % subcaption package % TOO RECENT FOR REDHAT4
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%                   (2) SETTINGS                       %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-% If you put this into your preamble, floats on pages of their own will appear at the top of the page.
-% If it's too high just take a different value than 0pt.  
-% fig or tab alone on page no longer in center
-\makeatletter
-\setlength{\@fptop}{0pt}
-\makeatother
-
-% Use \index{word} to tag special expressions \printindex will then give you word-page-index
-\makeindex
-
-\setcounter{tocdepth}{1}
-\setcounter{secnumdepth}{1}
-\uchyph=0 % stop hypenation of upper case words
-% Distance to figures in floatin environment
-%\setlength{\intextsep}{3mm plus2mm minus2mm}
-%\setlength{\abovecaptionskip}{0mm}
-%\setlength{\belowcaptionskip}{0mm}
-
-% Fix header layout and space
-\pagestyle{headings}
-\headsep=20pt
-\headheight=14.2pt
-
-% Remove all indentation
-\setlength{\parindent}{0pt}
-
-% autoref names, you can change here the default behaviour link names
-\renewcommand{\figureautorefname}{fig.}
-\newcommand{\subfigureautorefname}{fig.}
-\renewcommand{\tableautorefname}{tab.}
-\renewcommand{\chapterautorefname}{chap.}
-\renewcommand{\sectionautorefname}{sect.}
-\renewcommand{\subsectionautorefname}{subsect.}
-\renewcommand{\equationautorefname}{eq.}
-
-% Cosmetics
-\renewcommand{\setthesection}{\Alph{section}}
-\renewcommand{\labelitemi}{$\bullet$}
-\renewcommand{\labelitemii}{$\diamond$}
-\renewcommand{\labelitemiii}{$\ast$}
-\renewcommand{\labelitemiv}{$\cdot$}
-
-% Colors
-\definecolor{codeBG}{gray}{0.9}
-\definecolor{outBG}{gray}{0.6}
-
-% Code listing settings
-\lstset{
-basicstyle=\ttfamily,
-breaklines=true
-}
-\lstdefinestyle{intext}{
-basicstyle=\ttfamily
-}
-\lstdefinestyle{outoftext}{
-basicstyle=\ttfamily\small,
-backgroundcolor=\color{codeBG},
-prebreak=...,
-postbreak=...
-}
-\lstdefinestyle{outoftext2}{
-basicstyle=\footnotesize, 
-backgroundcolor=\color{outBG},
-prebreak=...,
-postbreak=...
-}
-
-
-\lstloadlanguages{sh,bash,Matlab,Python,Octave,C,C++}
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%                  (3) COMMANDS                        %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-% define here useful and often used commands to shorten writing unless you define it in acronyms
-\newcommand{\dct}{Diffraction Contrast Tomography}
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%
-% LaTeX commands to print:
-%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-% files, directories, pathes in text
-\def\file{\lstinline[language=,basicstyle=\sl]}
-
-% Matlab and shell commands in text
-\def\mCom{\lstinline[language=Matlab,basicstyle=\tt]}
-\def\sCom{\lstinline[language=sh,basicstyle=\tt]}
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% Environments to print out-of-text multiline code:
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-% Matlab code
-\lstnewenvironment{mCode}
-{\lstset{language=Matlab,style=outoftext}}
-{}
-
-% C code
-\lstnewenvironment{cCode}
-{\lstset{language=C,style=outoftext}}
-{}
-
-% C++ code
-\lstnewenvironment{cppCode}
-{\lstset{language=C++,style=outoftext}}
-{}
-
-% sh code
-\lstnewenvironment{shCode}
-{\lstset{language=sh,style=outoftext}}
-{}
-
-% any code
-\lstnewenvironment{Code}
-{\lstset{language=,style=outoftext}}
-{}
-
-% output
-\lstnewenvironment{mOut}
-{\lstset{language=,style=outoftext2}}
-{}
-
diff --git a/DCT_Documentation/main.tex b/DCT_Documentation/main.tex
index d6f58fdf..7b9b1670 100644
--- a/DCT_Documentation/main.tex
+++ b/DCT_Documentation/main.tex
@@ -1,31 +1,6 @@
-\documentclass[a4paper,
-               pagesize,
-               DIV13,%12,% type area 
-               twoside,% bookstyle, even and odd pages style different
-               openright,% chapter always starts on the right page
-               cleardoublepage=empty,%
-               titlepage,%
-               %parskip,%			
-               headsepline,%
-               footsepline=false,%
-               chapterprefix=false,%
-              %appendixprefix,%
-               onelinecaption,%  1st line: centered, otherwise
-               12pt,%
-               bigheadings,%
-               liststotoc,%
-               tocindent,%
-               listsindent,%
-               %abstracton,%
-               pointlessnumbers,% srcreprt
-               BCOR=15mm,	% binding correction
-               final
-               %tablecaptionabove
-               ]
-               {scrreprt}
-
-% All the packages, settings and commands should be put in the Preamble.tex file
-\input{common/Preamble.tex}
+\documentclass{DCTDoc}
+
+% All the packages, settings and commands should be put in the DCTDoc.cls file
 
 \begin{document}
 
@@ -35,21 +10,26 @@
 
   \tableofcontents
 
-  \include{main/missing}
-
   \include{main/introduction}
   \include{main/3DRXD}
 
   \include{main/DCT_Setup}
   \include{main/Geometry}
-  \include{main/FED_Strain}
-  \include{main/DCT_Operation}
-  \include{main/Software}
-  \include{main/Calibration_Measurements}
+  %\include{main/FED_Strain}
+  %\include{main/DCT_Operation}
+  %\include{main/Software}
+  %\include{main/Calibration_Measurements}
+
+  \appendix
 
   % put acronyms and technical terms in this chapter, they are then also available in shortform and hyperlinked via \acs{DCT},\acf{DCT},\acl{DCT}
+  \include{main/missing}
+  %\include{main/Links}
   \input{common/acronyms}
-  \include{main/Links}
-  \include{main/bibliography}
+
+  % Bibliography
+  \nocite{*}
+  \bibliographystyle{unsrtnat}
+  \bibliography{bib/example} % just an example for the moment
 
 \end{document}
diff --git a/DCT_Documentation/main/titlepage.tex b/DCT_Documentation/main/titlepage.tex
new file mode 100644
index 00000000..153bfd7a
--- /dev/null
+++ b/DCT_Documentation/main/titlepage.tex
@@ -0,0 +1,7 @@
+\title{DCT Manual\\[1em]Compiled on: \today}
+
+\author{Y. Guilhem \and A. King \and W. Ludwig \and L. Nervo \and P. Reischig \and S. Schmiederer \and N. Vigano}
+
+%\date{}
+
+\maketitle
diff --git a/DCT_Documentation/user_manual.tex b/DCT_Documentation/user_manual.tex
index e3b6eaa0..ef398d1e 100644
--- a/DCT_Documentation/user_manual.tex
+++ b/DCT_Documentation/user_manual.tex
@@ -1,31 +1,6 @@
-\documentclass[a4paper,
-               pagesize,
-               DIV13,%12,% type area 
-               twoside,% bookstyle, even and odd pages style different
-               openright,% chapter always starts on the right page
-               cleardoublepage=empty,%
-               titlepage,%
-               %parskip,%			
-               headsepline,%
-               footsepline=false,%
-               chapterprefix=false,%
-               %appendixprefix,%
-               onelinecaption,%  1st line: centered, otherwise
-               12pt,%
-               bigheadings,%
-               liststotoc,%
-               tocindent,%
-               listsindent,%
-               %abstracton,%
-               pointlessnumbers,% srcreprt
-               %BCOR=15mm, % binding correction
-               final
-               %tablecaptionabove
-               ]
-               {scrreprt}
-
-% All the packages, settings and commands should be put in the Preamble.tex file
-\input{common/Preamble.tex}
+\documentclass{DCTDoc}
+
+% All the packages, settings and commands should be put in the DCTDoc.cls file
 
 \begin{document}
 
@@ -48,6 +23,7 @@
   \include{user_manual/Visualization}
 
   \appendix
+
   % Put acronyms and technical terms in this chapter, they are then also available in shortform and hyperlinked via \acs{DCT},\acf{DCT},\acl{DCT}
   \input{common/acronyms}
 
diff --git a/DCT_Documentation/user_manual/titlepage.tex b/DCT_Documentation/user_manual/titlepage.tex
index cf96f8ca..25271371 100644
--- a/DCT_Documentation/user_manual/titlepage.tex
+++ b/DCT_Documentation/user_manual/titlepage.tex
@@ -24,11 +24,20 @@
 
 %\end{titlepage}
 
+%\titlehead{title head }
+%\subject{subject }
+%\title{title }
+%\subtitle{subtitle }
+%\author{author }
+%\date{date }
+%\publishers{publisher }
+%\and
+%\thanks{footnote }
 
 
 \title{DCT User Manual\\[1em]Compiled on: \today}
 
-\author{Y. Guilhem \and A. King \and W. Ludwig \and L. Nervo \and N. Vigano \and P. Reischig \and S. Schmiederer}
+\author{Y. Guilhem \and A. King \and W. Ludwig \and L. Nervo \and P. Reischig \and S. Schmiederer \and N. Vigano}
 
 %\date{}
 
-- 
GitLab