My Latex Report Preamble
This is the preamble I used in my latest project. A better description of the different packages will be made, when i get time, but for now you can just copy the preamble and try using it.
Report file including the preamble
\input { preamble }
\pagenumbering { roman }
\begin { document }
\input { prefaceTexFile }
\tableofcontents
\newpage
\pagenumbering { arabic }
\input { texFiles }
\clearpage
\addcontentsline { toc } { part } { Bibliography }
\bibliography { sourcesFile }
\clearpage
\addcontentsline { toc } { part } { Appendix }
\appendix
\input { appendixTexFile }
\end { document }
The Preamble
\documentclass[a4paper,twoside] { report }
% To support danish keys
\usepackage[latin1] { inputenc }
\usepackage[T1] { fontenc }
% Package to supply acronym functions
\usepackage[printonlyused] { acronym }
% Another new ref command
\usepackage { varioref }
% Package supplying algorithms layout.
\usepackage[boxed] { algorithm2e }
% Math packages
\usepackage { amssymb }
\usepackage { amsmath }
\usepackage { multirow }
\usepackage { amsthm }
\usepackage { bbm }
\usepackage { nicefrac }
% URL package, provides the \url { } tag
\usepackage { url }
% Source code listings
\usepackage { listings }
% Source Code Listings with highlight
\lstset { language=Java,tabsize=2,frame=single }
\lstset { tabsize=2 }
\lstset { breaklines = true }
% default is Listing
\renewcommand\lstlistingname { Code example }
% Graphic packages
\usepackage[pdftex] { graphicx }
\usepackage { subfigure }
\usepackage { graphics }
\usepackage { color }
% Rotate figures packages
\usepackage { rotating }
% Biblography
\bibliographystyle { plain }
% Chapter title style package
\usepackage[Bjarne] { fncychap }
% Header style
\usepackage { fancyhdr }
\pagestyle { fancy }
\fancyhf { } %Clears all header and footer fields, in preparation.
\fancyfoot[RO,LE] { \thepage } %Displays the page number in the footer, to the left on even pages and to the right on odd pages.
\fancyhead[LE] { \nouppercase { \leftmark } } %Displays the upper-level (section) information -
%as determined above - in non-upper case in the header, to the left on odd pages.
\fancyhead[RO] { \rightmark } %Displays the lower-level (chapter) information - as
%determined above - in the header, to the left on odd pages.%
\renewcommand { \headrulewidth } { 0.5pt } %Underlines the header. (Set to 0pt if not required).
\renewcommand { \headwidth } { \textwidth }
\renewcommand { \footrulewidth } { 0.5pt } %Underlines the footer. (Set to 0pt if not required).
\fancypagestyle { plain } { %
\fancyhf { } %Clears all header and footer fields, in preparation.
%\fancyfoot[LO,RE] { \thepage } %Displays the page number in the footer, left on odd page and right on even.
\fancyfoot[RO,LE] { \thepage } %Displays the page number in the footer, right on odd page and left on even.
%to the left on even pages and to the right on odd pages.
%\fancyhead[LO] { } %Displays the lower-level (chapter) information - as
%determined above - in the header, to the left on odd pages.
\renewcommand { \headrulewidth } { 0pt } %Underlines the header. (Set to 0pt if not required).
\renewcommand { \headwidth } { \textwidth }
\renewcommand { \footrulewidth } { 0.5pt } } %Underlines the footer. (Set to 0pt if not required).
% Package that provides the \fixme { } command
%\usepackage[draft] { fixme }
\title { your title }
\author { author name }
\date { \today }
% Makes all links black...
\usepackage[pdftex,colorlinks,linkcolor=black,urlcolor=black,citecolor=black,pagecolor=black] { hyperref }
% Depth of table of content set to one.
\setcounter { tocdepth } { 1 }