# Latex define font for entire document

Here is my tex sample. I got one problem that, my entire document font changed back to default. In the beginning I have

  \documentclass[12pt,a4paper]{report}
\usepackage[labelfont=bf]{caption}
\usepackage[T1]{fontenc}
\usepackage{mathptmx}

\usepackage[english]{babel}
\usepackage{longtable}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage{color}
\usepackage{pdfpages}
\usepackage{float}
\usepackage{listings}

\usepackage[nottoc]{tocbibind}
\renewcommand\bibname{References}

\usepackage{lmodern}

\author{XXX}
\title{USER Instruction}
\begin{document}

\tableofcontents

\newpage
\clearpage
\phantomsection
\listoffigures

\newpage
\clearpage
\phantomsection
\listoftables

\setcounter{chapter}{0}

\chapter{INTRODUCTION}
%\pagenumbering{arabic}

\subsection{Data}
it can be divided into two operations:

\section{The pt}

\chapter{ASA }

llllllllllllllll

\chapter{Cooo}

k

\chapter{CoooK}

lkkkkkkkkk
\section{CoooWork}

In th

\bibliography{Bibliography}

\end{document}


Which gives me similar with Times font. But it just changed someday, and I tried many ways can not get the Times font. The font does not change whatever I do....can anyone help me with this? Thanks a lot.

• LaTeX changes font only when it's ordered to. A minimal example showing the issue is needed: it's likely that when you'll be preparing it, you'll find the cause. – egreg Jul 7 '15 at 8:56
• Minimal? Anyways, why do you load \usepackage{lmodern}? – Torbjørn T. Jul 7 '15 at 10:20
• @ Torbjørn T. you are totally right....this is the problem. thanks a lot – user2307344 Jul 7 '15 at 10:37

You have \usepackage{mathptmx} followed later by \usepackage{lmodern}. This means that the mathptmx font choices and settings are applied first and then they are overridden by those from lmodern (which is close to the default LaTeX font). So all you need to do is remove the \usepackage{lmodern}.