Biblatex implementation in progress
This commit is contained in:
parent
1dbf731131
commit
373b222ad8
32
.gitignore
vendored
32
.gitignore
vendored
@ -1,26 +1,28 @@
|
||||
.DS_Store*
|
||||
*.aux*
|
||||
*.log
|
||||
*.log*
|
||||
*.lof*
|
||||
*.lot*
|
||||
*.out*
|
||||
*.gz
|
||||
*.gz*
|
||||
*.toc*
|
||||
*.bbl
|
||||
*.blg
|
||||
*~
|
||||
*.nlo
|
||||
*.bbl*
|
||||
*.bcf*
|
||||
*.blg*
|
||||
*~*
|
||||
*.nlo*
|
||||
*make
|
||||
*.d
|
||||
*.btmp
|
||||
*.fls
|
||||
*.glo
|
||||
*.idx
|
||||
*.ist
|
||||
*.ilg
|
||||
*.ind
|
||||
*.btmp*
|
||||
*.fls*
|
||||
*.glo*
|
||||
*.idx*
|
||||
*.ist*
|
||||
*.ilg*
|
||||
*.ind*
|
||||
*cookie*
|
||||
*#*
|
||||
*.nls
|
||||
*.nlg
|
||||
*.nls*
|
||||
*.nlg*
|
||||
thesis.txt*
|
||||
*.run.xml*
|
||||
|
@ -30,27 +30,31 @@
|
||||
\DeclareOption{index}{\PHD@indextrue}
|
||||
|
||||
% ******************************* Font Option **********************************
|
||||
\newif\ifsetFont\setFontfalse % Font is not set
|
||||
\newif\ifsetFont\setFontfalse % Font is not set
|
||||
|
||||
\newif\ifPHD@times\PHD@timesfalse % Times with Math Support
|
||||
\newif\ifPHD@times\PHD@timesfalse % Times with Math Support
|
||||
\DeclareOption{times}{\PHD@timestrue}
|
||||
|
||||
\newif\ifPHD@fourier\PHD@fourierfalse % Fourier with Math Support
|
||||
\newif\ifPHD@fourier\PHD@fourierfalse % Fourier with Math Support
|
||||
\DeclareOption{fourier}{\PHD@fouriertrue}
|
||||
|
||||
\newif\ifPHD@customfont\PHD@customfontfalse % Custom Font with Math Support
|
||||
\newif\ifPHD@customfont\PHD@customfontfalse % Custom Font with Math Support
|
||||
\DeclareOption{customfont}{\PHD@customfonttrue}
|
||||
|
||||
% ******************************* Bibliography *********************************
|
||||
\newif\ifsetBib\setBibfalse % Using Custom Bibliography
|
||||
\newif\ifsetBib\setBibfalse % Custom Bibliography = true/false
|
||||
\newif\ifsetBiBLaTeX\setBiBLaTeXfalse % BiBLaTeX = True / False
|
||||
|
||||
\newif\ifPHD@authoryear\PHD@authoryearfalse % Author-Year citation
|
||||
\newif\ifPHD@biblatex\PHD@biblatexfalse % BiBLaTeX
|
||||
\DeclareOption{biblatex}{\PHD@biblatextrue}
|
||||
|
||||
\newif\ifPHD@authoryear\PHD@authoryearfalse % Author-Year citation
|
||||
\DeclareOption{authoryear}{\PHD@authoryeartrue}
|
||||
|
||||
\newif\ifPHD@numbered\PHD@numberedfalse % Numbered citiation
|
||||
\newif\ifPHD@numbered\PHD@numberedfalse % Numbered citiation
|
||||
\DeclareOption{numbered}{\PHD@numberedtrue}
|
||||
|
||||
\newif\ifPHD@custombib\PHD@custombibfalse % Custom Bibliography
|
||||
\newif\ifPHD@custombib\PHD@custombibfalse % Custom Bibliography
|
||||
\DeclareOption{custombib}{\PHD@custombibtrue}
|
||||
|
||||
% ************************* Header / Footer Styling ****************************
|
||||
@ -273,22 +277,35 @@ supported!}
|
||||
|
||||
% ******************************* Bibliography *********************************
|
||||
\ifPHD@authoryear
|
||||
\ifPHD@biblatex
|
||||
\RequirePackage[backend = biber, style = authoryear, citestyle = alphabetic, sorting = nty, natbib = true]{biblatex}
|
||||
\setBiBLaTeXtrue
|
||||
\else
|
||||
\RequirePackage[round, sort, numbers, authoryear]{natbib} %author year
|
||||
\fi
|
||||
\setBibtrue
|
||||
\else
|
||||
\ifPHD@numbered
|
||||
\ifPHD@biblatex
|
||||
\RequirePackage[backend = biber, style = numeric-comp, citestyle = numeric, sorting = none, natbib = true]{biblatex}
|
||||
\setBiBLaTeXtrue
|
||||
\else
|
||||
\RequirePackage[numbers,sort&compress]{natbib} % numbered citation
|
||||
\fi
|
||||
\setBibtrue
|
||||
\else
|
||||
\ifPHD@custombib
|
||||
\setBibfalse
|
||||
\ifPHD@biblatex
|
||||
\setBiBLaTeXtrue
|
||||
\fi
|
||||
\else
|
||||
\RequirePackage[numbers,sort&compress]{natbib} % Default - numbered
|
||||
\setBibtrue
|
||||
\ClassWarning{PhDThesisPSnPDF}{No bibliography style was specified.
|
||||
Default numbered style is used. If you would like to use a different style, use
|
||||
`authoryear' or `numbered' in the options in documentclass or use `custombib`
|
||||
and define the natbibpackage with required style in the Preamble.tex file}
|
||||
and define the natbib package or biblatex package with required style in the Preamble.tex file}
|
||||
\fi
|
||||
\fi
|
||||
\fi
|
||||
|
@ -4,6 +4,7 @@
|
||||
% Add `custommargin' in the document class options to use this section
|
||||
% Set {innerside margin / outerside margin / topmargin / bottom margin} and
|
||||
% other page dimensions
|
||||
|
||||
\ifsetMargin
|
||||
\else
|
||||
\RequirePackage[left=37mm,right=30mm,top=35mm,bottom=30mm]{geometry}
|
||||
@ -14,10 +15,12 @@
|
||||
% ******************* Fonts (like different typewriter fonts etc.)*************
|
||||
|
||||
% Add `customfont' in the document class option to use this section
|
||||
|
||||
\ifsetFont
|
||||
\else
|
||||
% Set your custom font here and use `customfont' in options. Leave empty to
|
||||
% load computer modern font (default LaTeX font).
|
||||
|
||||
\RequirePackage{libertine}
|
||||
\fi
|
||||
|
||||
@ -29,9 +32,14 @@
|
||||
% Add `custombib' in the document class option to use this section
|
||||
\ifsetBib % True, Bibliography option is chosen in class options
|
||||
\else % If custom bibliography style chosen then load bibstyle here
|
||||
\RequirePackage[square, sort, numbers, authoryear]{natbib} % CustomBib
|
||||
\ifsetBiBLaTeX
|
||||
\RequirePackage[backend = biber, style = numeric-comp, citestyle = numeric, sorting = nty, natbib = true]{biblatex}
|
||||
\else
|
||||
\RequirePackage[square, sort, numbers, authoryear]{natbib} % CustomBib
|
||||
\fi
|
||||
\fi
|
||||
|
||||
|
||||
% changes the default name `Bibliography` -> `References'
|
||||
\renewcommand{\bibname}{References}
|
||||
|
||||
@ -132,5 +140,4 @@
|
||||
% The default value of both \appendixtocname and \appendixpagename is `Appendices'. These names can all be changed via:
|
||||
|
||||
%\renewcommand{\appendixtocname}{List of appendices}
|
||||
|
||||
%\renewcommand{\appendixname}{Appndx}
|
||||
|
BIN
thesis.pdf
Normal file
BIN
thesis.pdf
Normal file
Binary file not shown.
22
thesis.tex
22
thesis.tex
@ -1,7 +1,7 @@
|
||||
% ******************************* PhD Thesis Template **************************
|
||||
% Please have a look at the README.md file for info on how to use the template
|
||||
|
||||
\documentclass[a4paper,12pt,times,numbered,print,index]{Classes/PhDThesisPSnPDF}
|
||||
\documentclass[a4paper,12pt,times,custombib,print,index,biblatex]{Classes/PhDThesisPSnPDF}
|
||||
|
||||
% ******************************************************************************
|
||||
% ******************************* Class Options ********************************
|
||||
@ -71,6 +71,10 @@
|
||||
% Preamble: Contains packages and user-defined commands and settings
|
||||
\input{Preamble/preamble}
|
||||
|
||||
\ifsetBiBLaTeX
|
||||
\bibliography{References/references}
|
||||
\fi
|
||||
|
||||
% ************************ Thesis Information & Meta-data **********************
|
||||
%% The title of the thesis
|
||||
\title{Writing your PhD Thesis in \texorpdfstring{\\ \LaTeX2e}{LaTeX2e}}
|
||||
@ -168,14 +172,20 @@ Cambridge}}
|
||||
|
||||
\begin{spacing}{0.9}
|
||||
|
||||
|
||||
%\ifsetBiBLaTeX % BiBLaTeX
|
||||
\printbibliography
|
||||
|
||||
%\else % NatBiB
|
||||
|
||||
% Bibliography style previews: http://nodonn.tipido.net/bibstyle.php
|
||||
|
||||
\bibliographystyle{apalike}
|
||||
%\bibliographystyle{plainnat} % use this to have URLs listed in References
|
||||
%\bibliographystyle{apalike}
|
||||
%%\bibliographystyle{plainnat} % use this to have URLs listed in References
|
||||
|
||||
\cleardoublepage
|
||||
|
||||
\bibliography{References/references} % Path to your References.bib file
|
||||
%\cleardoublepage
|
||||
%\bibliography{References/references} % Path to your References.bib file
|
||||
%\fi
|
||||
|
||||
\end{spacing}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user