%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% STYLE MATTER: %%%%%%%%%%%%%  *** please do not edit *** %%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\topmargin 20mm      % the top margin is not less than 2 cm
\textheight 24.0cm
\textwidth 152mm
\oddsidemargin 35mm    % the binding margin is not less than 3.5 cm
\evensidemargin 35mm
\headsep 0in

\voffset -28mm
\hoffset -23mm

\renewcommand{\contentsname}{Table of Contents}
%\renewcommand{\baselinestretch}{1.4}
%\renewcommand{\theequation}{\thesection.\arabic{equation}}
\pagenumbering{roman}
%\newlength{\unithsp}
%\setlength{\unithsp}{1mm}
%\def\hs#1{\hspace*{#1\unitvsp}}
%\newlength{\unitvsp}
%\setlength{\unitvsp}{1mm}
%\def\vs#1{\vspace*{#1\unitvsp}}

\renewcommand{\baselinestretch}{1.5}\normalsize
\def\title#1{\def\ntitle{#1}}
\def\author#1{\def\nauthor{#1}}
\def\supervisor#1{\def\nsupervisor{#1}}
\def\degree#1{\def\ndegree{#1}}
\def\date#1{\def\ndate{#1}}
\newcommand{\Thesistitle}{
\newpage
\null\vspace*{0.5in}
\begin{center}
{\Large\bf \ntitle}

\vspace*{3.5cm}
{\large\bf \nauthor}
\vspace*{2cm}

A thesis submitted in partial fulfillment of the requirements

for the degree of

{\normalsize \ndegree}

\vspace*{3.5cm}


{\normalsize Principal Supervisor: \nsupervisor}

\vspace*{1cm}
Hong Kong Baptist University

\vspace*{1cm}
{\normalsize \ndate}

\thispagestyle{empty}
\end{center}}

\renewenvironment{abstract}
{\newpage
\setcounter{page}{1}
\addcontentsline{toc}{chapter}{Abstract}
\begin{center}{\Large\bf Abstract}\normalsize
\end{center}
\vspace*{0.5cm}
\renewcommand{\baselinestretch}{1} \normalsize}
{\newpage}

\newenvironment{acknowledgement}
{\newpage
\addcontentsline{toc}{chapter}{Acknowledgements}
\begin{center}{\Large\bf Acknowledgements}\normalsize
\end{center} \vspace*{0.5cm}}{}

\newcommand{\thesis}{
\newpage
\pagenumbering{arabic} \setcounter{chapter}{0}
\setcounter{section}{0} \setcounter{page}{1}
}

\makeatletter
\renewcommand*\l@chapter[2]{%
  \ifnum \c@tocdepth >\m@ne
    \addpenalty{-\@highpenalty}%
    \vskip 1.0em \@plus\p@
    \setlength\@tempdima{1.5em}%
    \begingroup
      \parindent \z@  \rightskip \@pnumwidth
      \parfillskip -\@pnumwidth
      \leavevmode %\bfseries
      \advance \leftskip 2.4cm %\leftskip\@tempdima
      \hskip -\leftskip
      #1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\hss #2}\par
      \penalty\@highpenalty
    \endgroup
  \fi}
\def\@chapter[#1]#2{\ifnum \c@secnumdepth >\m@ne
                         \refstepcounter{chapter}%
                         \typeout{\@chapapp\space\thechapter.}%
                         \addcontentsline{toc}{chapter}%
                                   {\protect \numberline {Chapter \thechapter}\hspace*{1.5cm} #1}%
                    \else
                      \addcontentsline{toc}{chapter}{#1}%
                    \fi
                    \chaptermark{#1}%
                    \addtocontents{lof}{\protect\addvspace{10\p@}}%
                    \addtocontents{lot}{\protect\addvspace{10\p@}}%
                    \if@twocolumn
                      \@topnewpage[\@makechapterhead{#2}]%
                    \else
                      \@makechapterhead{#2}%
                      \@afterheading
                    \fi}
\makeatother
