3Dbiology
LaTeX/Lyx



LyX-code for my PhD dissertation

***********************************************************



# define the general layout using fancy headers and footers, where the section and subsections appear in the right # upper corner of the header on the right page and the left upper corner on the left page in a double-sided #document.
\fancyhf{}
\fancyhead[LE]{\rightmark}
\fancyhead[RO]{\leftmark}
\fancyfoot[CEO]{\thepage}


#to change the headers when chapters are not numbered (chapter*); means that the "chaptertitle" appears on #either sider on each page
\markboth{chaptertitle}{}  


#to add the chapter* title to the toc
\addcontentsline{toc}{chapter}{References}


#to add the chapter* title to the toc with preserving the numbering in the toc
\addcontentsline{toc}{chapter}{\protect\numberline{6}References}


#to add the section* title to the toc

\addcontentsline{toc}{section}{whateverfancysectionname}


#to preserve the figure numbers for the consecutive papers without having an overlap with previous figure #numbers, I adapted the figure and table numbers to represent eacht paper; P1 for paper 1, P2 for paper 2 etc. #Then each figure/table would have : P1.1, P1.2 etc.. or P2.1, P2.2 etc..

#command added before the title of each paper. Below is the command for paper 1  (P1)
\renewcommand}{\thetable}{P1.\arabic{table}}
\setcounter{table}{0}
\renewcommand}{\thefigure}{P1.\arabic{figure}}
\setcounter{figure}{0}


#to begin a two-column formatting of the text
In the preamble:
\usepackage{multicol}

In ERT :
\begin{multicols}{2}
<text-becomes two-colums (not visible in LyX itself)>
\end{multicols}


#in case I wanted to start a figure on a new page and using the page break did not work

\vfill\newpage


#for other formatting:

#better looks: extra vertical space and horizontal lines to capture the abstract
#added before the Abstract started
\vspace{6pt}
\hrule
\vspace{6pt}


#added after the Abstract started

\vspace{6pt}
\hrule


#to indicate "degrees in centigrade" => the small superscript circle

In ERT:
$^{\circ}$


#to draw the Norwegian "ø"

in ERT:
\o