1

I'm using Led editor in Windows 7. I want to use Times font but the output pdf fonts are somewhat different.

Here are the codes for Times font

\usepackage[T1]{fontenc}
\usepackage{winfonts}
\fontfamily{times-ttf}\selectfont 
\renewcommand{\ttdefault}{times-ttf}
  \renewcommand{\rmdefault}{times-ttf}
  \renewcommand{\sfdefault}{times-ttf}
\renewcommand*\familydefault{\ttdefault}

and I copy the winfonts.sty in the same directory. What may cause this problem or am I doing something wrong?

N.N.
  • 36,163
  • why don't you simply use \usepackage{mathptmx} or \usepackage{times}? –  Aug 09 '11 at 11:47
  • 2
    Copying winfonts.sty is not enough. What have you done with the other files? And did you add \pdfmapfile{=winfonts.map} to your document? – Ulrike Fischer Aug 09 '11 at 12:06

1 Answers1

2

Copying the .sty file is not enough to install this package. You should follow the steps described in the package README file.

If you only need a font that looks like Times, consider using

\usepackage{mathptmx}

The times package is deprecated and should not be used.

Another way to get the real Times New Roman font is to use XeLaTeX or LuaLaTeX with the fontspec package:

\documentclass{article}

\usepackage{fontspec}

\setmainfont[Ligatures=TeX]{Times New Roman}

\begin{document}

Hello World

\end{document}

(Compile with xelatex or lualatex. If you choose this route, see this or this question for a start.)

Andrey Vihrov
  • 22,325