5

I am writing my PhD thesis. When I refer to a PhD thesis, the title of the thesis is underlined. When the title is too long, there is no break and the title is written out of the margin of the page. I show you the code I used, followed by an example.

LaTeX code

%!TEX TS-program = latexmk
%!TEX encoding = IsoLatin

\documentclass[PhD,english,francais]{ulthese}
\ifxetex\else  \usepackage[latin1]{inputenc}\fi

\usepackage{amsmath}       
\usepackage{icomma}
\usepackage{graphicx}
\usepackage{mathptmx} 
\usepackage{array,multirow,makecell}
\usepackage{colortbl} 
  \definecolor{grisfonce}{rgb}{192,192,192}
  \definecolor{grisclair}{rgb}{204,204,204}
\usepackage{soul} 
\usepackage{media9} 
\usepackage{easylist} 
\usepackage{ulem} 
\usepackage[pdftex]{hyperref}
\hypersetup{% 
  colorlinks=true,allcolors=ULlinkcolor,citecolor=blue,pdftitle={Mémoire de thèse}, pdfauthor={Sébastien Meghezi}, pdfsubject={Biomécanique et génie tissulaire}, pdfkeywords={mécanique, génie tissulaire, collagène, cellules, agents de réticulation, remodelage} %
}

\newcommand{\hlgrisclair}[1]{\sethlcolor{grisclair}\hl{#1}}
\addto\captionsfrench{\def\tablename{Tableau}} 


\usepackage[acronym,section,nonumberlist]{glossaries}
\newglossarystyle{modlong3col}{%
\glossarystyle{long3col}%
\renewcommand{\glsgroupskip}{}
}
\makeglossaries

\frenchbsetup{%
    CompactItemize=false,         
    ThinSpaceInFrenchNumbers=true 
  }

\bibliographystyle{apalike} % plain, abbrv, apalike, ieeetr

\titre{Title}
\auteur{Author}
\programme{Ph.D.}
\faculteUL{Faculty of Science and Engineering}
\annee{2015}
\settocdepth{subsection}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%\usepackage[comma,authoryear]{natbib} 

\begin{document}

\frontmatter                    % pages liminaires
\pagetitre                      % production de la page titre
\cleardoublepage
\tableofcontents                % production de la TdM
\cleardoublepage
\listoftables                   % production de la liste des tableaux
\cleardoublepage
\listoffigures                  % production de la liste des figures
\cleardoublepage

\mainmatter
\citep{Zaman2013}
\citep{LHeureux2007}

\bibliography{Bibliotrial}               % production de la bibliographie
\end{document}

Bibliotrial.bib file

Automatically generated by Mendeley Desktop 1.13.6
Any changes to this file will be lost if it is regenerated by Mendeley.

BibTeX export options can be customized via Preferences -> BibTeX in Mendeley Desktop

@phdthesis{Zaman2013,
author = {Zaman, Nishat},
file = {:Users/Sebastien/Documents/Doctorat/Bibliographie/Articletheque/Zaman - Influence of Loading and Matrix Stiffness on Airway Smooth Muscle Contractile Function and Phenotype within a 3D Microtissue Cul.pdf:pdf},
pages = {132},
school = {Dalhousie University (Halifax), Canada},
title = {{Influence of Loading and Matrix Stiffness on Airway Smooth Muscle Contractile 
Function and Phenotype within a 3D Microtissue Culture Model}},
type = {Master of Applied Science},
year = {2013}
}


@article{LHeureux2007,
author = {L'Heureux, Nicolas and McAllister, Todd N and de la Fuente, Luis M},
doi = {10.1056/NEJMc071536},
file = {:Users/Sebastien/Documents/Doctorat/Bibliographie/Articletheque/L'Heureux, McAllister, de la Fuente - Tissue-engineered blood vessel for adult arterial revascularization. - 2007.pdf:pdf},
issn = {1533-4406},
journal = {The New England journal of medicine},
keywords = {80 and over,Adult,Aged,Arteriovenous Shunt,Blood Vessel Prosthesis,Humans,Middle Aged,Prosthesis Design,Renal Dialysis,Surgical,Tissue Engineering,Vascular Surgical Procedures},
month = oct,
number = {14},
pages = {1451--3},
pmid = {17914054},
title = {{Tissue-engineered blood vessel for adult arterial revascularization.}},
url = {http://www.ncbi.nlm.nih.gov/pubmed/17914054},
volume = {357},
year = {2007}
}

Result

enter image description here

Thanks for your help!

Sebastien

egreg
  • 1,121,712
Mszigmo
  • 63

2 Answers2

4

The culprit is \usepackage{ulem} that changes \em (and \emph) to mean underline rather than italicize.

Underlining is something that should never appear in a printed text; the package ulem is very primitive in this respect and its underlining feature prohibits line breaks. However, nobody should ever use it for any purpose.

So, remove \usepackage{ulem} or, if you really need some of its features in your thesis, load it as

\usepackage[normalem]{ulem}

so it won't clobber \em and \emph.

egreg
  • 1,121,712
  • Surprisingly I used the package "ulem" because I observed there was no break if i used the command "\underline" with a long sentence. I used it also to be able to make different kinds of underlining. But you are right, it looks like this package was the origin of my problem when citing thesis. Since I used the ulem in the body of my thesis, I prefer to load it like you told me. Thank you very much for your help! – Mszigmo Apr 12 '15 at 19:48
0

You didn't include your Bibliotrial.bib file, but I'm guessing you're using the underline command there. The .bib file should only include the raw data for the bibliography; all of the stylistic choices should be made using the bibliography style file (apalike.bst in this case). So you should choose a different style that does what you want. If someone at your university already provided you with a thesis template, they probably also have a style file you can use. If you have to follow the style of a journal in your field, the journal's website may also provide their style file in the author/submission instructions. If you're on your own, you can make/modify style files so that the references appear exactly as you like (see Is there an (easy) way to create or personalize .bst files?).

That said, if you just need a quick but ugly fix, you can manually split the underline command in your .bib file:

title={\underline{Influence of Loading and Matrix Stiffness on Airway
       Smooth Muscle Contractile} \\ \underline{Function and ...}},
alaferg
  • 1,079
  • I don't have any spécifications from my university regarding the bibliographie style. However, I would like to see for example (L'Heureux et al., 2007) as a citation in the main text and L'Heureux, N., McAllister, T. N., and de la Fuente, L. M. (2007). Tissue-engineered blood vessel for adult arterial revascularization. The New England journal of medicine, 357(14) :1451–3. – Mszigmo Apr 12 '15 at 18:49
  • Thank you for the link you gave me. However I didn't think it would be so difficult to modify the format of the references. I would like to use your "quick but ugly fix" but I am not able to do that since I don't use the command "\underline". I guess there is a command in apalike format that says that the title of the thesis is underlined. As you can see my reference manager is Mendeley. I export my bibliography from Mendeley in .bib file. So when all the writing part will be done, I would like to export the bibliography and modify the .bib file to add a break in the title. – Mszigmo Apr 12 '15 at 18:58
  • Thanks for posting your .bib: now I see that my assumption was wrong. So I agree with @egreg's answer, in which case the title will break at the appropriate place automatically. If you ever do have to modify your own style file, it's tedious but not that difficult. The link I posted above also links to an online generator http://www.podoblaz.net/cml/?id=39 that you simply answer questions to generate the style file and it even shows the references and citations as they will appear. – alaferg Apr 14 '15 at 21:42
  • Thank you very much for your help alaferg I will try the online generator for sure! – Mszigmo Apr 16 '15 at 00:03