字体形状‘TS1/aer/m/n’未定义

字体形状‘TS1/aer/m/n’未定义

我不断收到此错误“字体形状TS1/aer/m/n' undefined (Font) using改为 TS1/cmr/m/n'”。我猜这与使用破折号有关。我经常在带有破折号的行中收到此错误“不完全确定”。我正在提供 MWE。我很感激您的帮助,欢迎任何改进,因为我是乳胶新手,第一次将它用于我的论文。可以找到 thesis.cls这里

\documentclass[12pt]{thesis}

%%% preample %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


%%% packages %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


%\usepackage[T1]{fontenc}        % euro quality fonts [T1] (togeth. w/ textcomp) - commented - Islam
\usepackage{textcomp, amssymb}  % additional symbols (there are more packages)
\usepackage{amsfonts}
\usepackage{amsmath}    % already been here (and used it to insert bold symobls in math equations) - Islam
%\usepackage[latin1]{inputenc}   % umlaute in input file
\usepackage[utf8]{inputenc}  %% - added - Islam
\usepackage{setspace}           % doublespacing
\usepackage{anysize}            % margin package sets tighter margins
\usepackage[all]{xy}            % creating figures within latex
%\usepackage[tight]{subfigure}% subfigures: figures within figures
\usepackage[none]{hyphenat}
\usepackage[flushleft]{threeparttable}
\usepackage{lscape}
\usepackage{array}
\usepackage{afterpage}
\usepackage{natbib}
\usepackage{comment}
\usepackage{subcaption}
\usepackage{longtable}
\usepackage{gensymb}
%\usepackage{pdfpages}
\usepackage[title]{appendix}
\usepackage{chngcntr}
\counterwithout*{footnote}{chapter} %prevent resetting the footnotes in each chapter
\newcolumntype{G}{>{\centering\arraybackslash}m{2cm}}
\newcolumntype{E}{>{\centering\arraybackslash}m{3cm}}
\DeclareMathOperator{\argmin}{argmin} %Define argmin
\marginsize{1.8in}{0.8in}{0.8in}{0.8in} % Trang's margins

\usepackage{ifpdf}              % if pdflatex then ... else ...
\ifpdf
  \pdfadjustspacing=1           % make pdflatex behave like latex
  \usepackage{aeguill}          % PS converted CM fonts for better acro preview
  \usepackage[pdftex]{graphicx} % graphics packages
  \usepackage[pdftex]{color}    % color packages
  \usepackage[pdftex]{thumbpdf} % create thumbnails (run thumbpdf as well)
  \usepackage[pdftex,colorlinks,%
              pagebackref=true, % bibliography -> text
              linktocpage=true, % toc etc: make page number active (not name)
              plainpages=false, % distinguish roman and arabic pagenumbers
              bookmarksopen=true,%
              bookmarksnumbered=true,%
              pdfauthor={My name goes here},%
              pdftitle={thesistitle},% 
              pdfsubject={PhD Thesis},%
              pdfkeywords={keyword1, keyword2, keyword3},%
             ]{hyperref}        % clickabe references
             \hypersetup{colorlinks = true, 
                urlcolor = blue,                linkcolor=blue, 
                citecolor=blue
             }
\else
  \usepackage[hypertex,
              plainpages=false, % distinguish roman and arabic pagenumbers
              linktocpage=true, % toc etc: make page number active (not name)
             ]{hyperref}        % clickabe references in .dvi
             \hypersetup{colorlinks = true, 
                urlcolor = blue, 
                linkcolor=blue, 
                citecolor=blue
             }
                                % purposely included before color package
  \usepackage[dvips]{color}     % color packages; needed by xy
  \usepackage[dvips]{graphicx}  % graphics packages
\fi

%% ============== Added by me  ====================================
  %%% added for the longtable in chapter 4 %%%%
\usepackage{ragged2e,  % for \RaggedRight macro
            booktabs,  % for well-spaced horizontal rules
            longtable} % for longtable environment
\newcolumntype{P}[1]{>{\RaggedRight}p{#1}} % disable full justification
%%% added for tables (based on tutorial)
\usepackage{rotating}  % for sidewaystable
\usepackage{dcolumn}  % aligning decimals (might be unnecessary)
    \newcolumntype{d}[1]{D{.}{.}{#1}}

\usepackage{threeparttablex} % threeparttable for longtable

\usepackage{lipsum} 

%% wrappers for tables (some might not be needed I guess)
% *****************************************************************
% Estout LaTeX wrapper
% *****************************************************************

%%Original code developed by Jörg Weber: see
%% https://www.jwe.cc/2012/03/stata-latex-tables-estout/
%% and
%% https://www.jwe.cc/blog/

\let\estinput=\input % define a new input command so that we can still flatten the document

\newcommand{\estwide}[3]{
        \vspace{.75ex}{
            %\textsymbols% Note the added command here
            \begin{tabular*}
            {\textwidth}{@{\hskip\tabcolsep\extracolsep\fill}l*{#2}{#3}}
            \toprule
            \estinput{#1}
            \\ \bottomrule          % 08 Dec 2021. Add these slashes.
            \addlinespace[.75ex]
            \end{tabular*}
            }
        }   

\newcommand{\estauto}[3]{
        \vspace{.75ex}{
            %\textsymbols% Note the added command here
            \begin{tabular}{l*{#2}{#3}}
            \toprule
            \estinput{#1}
            \\ \bottomrule          % 08 Dec 2021. Add these slashes.
            \addlinespace[.75ex]
            \end{tabular}
            }
        }

% Allow line breaks with \\ in specialcells
\newcommand{\specialcell}[2][c]{%
    \begin{tabular}[#1]{@{}c@{}}#2\end{tabular}
}

\newcommand{\sym}[1]{\rlap{#1}}% Thanks David Carlisle


%%%%%%%%%%% End of wrapper %%%%%%%%%%%%%%%%%%%%%

% hyperref must be the second last package and glossary the last package

% index
\usepackage{makeidx}                       % for \printindex
\makeindex                                 % creates paper.idx index file

% glossary
%\usepackage[style=super, cols=3]{glossary} % for \printclossary   % obslete - Islam

%%% style and finetuning %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\pagestyle{plain}               % pagestyle: headings, empty, plain

% new theorems
\newtheorem{example}{Example}
\newtheorem{proof}{Proof}


%%% document %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{document}

\pagenumbering{roman} % titlepage does not get a number - that's odd, but good.

\ifpdf\pdfbookmark[1]{Title}{label:title}\fi              \input{titlepage.tex}
%\newpage                                                     \input{spruch.tex}

% {\doublespacing
%   \newpage\ifpdf\pdfbookmark[1]{Acknowledgement}{label:ack}\fi\input{acknowledge.tex}
%   \newpage\ifpdf\pdfbookmark[1]{Abstract}{label:abst}\fi     \input{abstract.tex}
% }

\newpage\ifpdf\pdfbookmark[1]{Table of Contents}{label:toc}\fi \tableofcontents
\newpage\ifpdf\pdfbookmark[1]{List of Figures}{label:lof}\fi     \listoffigures
\newpage\ifpdf\pdfbookmark[1]{List of Tables}{label:lot}\fi       \listoftables

{\doublespacing
  \newpage\pagenumbering{arabic}
  % \newpage\input{./chap1.tex}

%% temporarily copied from chap1.tex
\lipsum[2-9]
I am citing this paper \citep{angrist2009mostly,bound1995problems} here I am citing this paper \citep{angrist2009mostly,bound1995problems} here I am citing this paper \citep{angrist2009mostly,bound199} So we can\footnote{A notable exception investigate the provide capsules to women of reproductive age and young children in order to suppress the high rate of deficiency with focus on low-risk districts. The authors document positive effects on schooling and a number of health outcomes. H2020 replicated work while improving the identification strategy and using sample, finding no impact on health ttainment.} 
\begin{equation}
    \begin{aligned}
        X_{i} =\ &\gamma_{0} + \gamma_{1}D_{i} + f(X_{i}) + Z_{i}\gamma_{2} + \omega_{i}
    \end{aligned}
    \label{chap1:eqn1}%
\end{equation}

  % Bibliography and Glossary          (\phantomsection is needed for hyperlinks)

  \newpage\phantomsection%
  \addcontentsline{toc}{chapter}{\bibname}              % add Bibliography to TOC
  \bibliographystyle{te}\bibliography{references}


  \newpage\phantomsection%
  \addcontentsline{toc}{chapter}{\indexname}                   % add Index to TOC
  \printindex
  % commented out - Islam (related to glossary.sty error)
  % \newpage\phantomsection%
  % \addcontentsline{toc}{chapter}{Glossary}                  % add Glossary to TOC
  % \printglossary
} % added this
\end{document}


%%%% references.bib
\begin{comment}
@book{angrist2009mostly,
  title     = {Mostly harmless econometrics: An empiricist's companion},
  author    = {Angrist, Joshua D and Pischke, J{\"o}rn-Steffen},
  year      = {2009},
  publisher = {Princeton university press}
}

@article{bound1995problems,
  title     = {Problems with instrumental variables estimation when the correlation between the instruments and the endogenous explanatory variable is weak},
  author    = {Bound, John and Jaeger, David A and Baker, Regina M},
  journal   = {Journal of the American statistical association},
  volume    = {90},
  number    = {430},
  pages     = {443--450},
  year      = {1995},
  publisher = {Taylor \& Francis}
}
\end{comment}

%%%% thesis.cls
\begin{comment}
% my thesis

% First identify the class:

\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{thesis}

\DeclareOption*{\PassOptionsToClass{\CurrentOption}{report}}

\ProcessOptions

\LoadClass{report}

% add dots to chapters in TOC
\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\@tempdima
      \hskip -\leftskip
      #1\nobreak \leaders\hbox{$\m@th\mkern \@dotsep mu\hbox{.}\mkern \@dotsep mu$}  \hfil \nobreak\hb@xt@\@pnumwidth{\hss #2}\par
      \penalty\@highpenalty
    \endgroup
  \fi}


% no indentation for paragraphs and space inbetween paragraphs  (euro standard)
% this happens to spread also the table of contents, list of figures and tables
\setlength{\parindent}{0pt}
\setlength{\parskip}{7pt plus 2pt minus 1pt}


% Make the captions in your floats of the form:
% Figure 1 -> Fig. 1

\renewcommand{\figurename}{Fig.}
\renewcommand{\contentsname}{Table of Contents}


% force footnotes to the bottom
\usepackage[bottom]{footmisc}


% Redefining the \section command:

%\renewcommand{\section}{\@startsection
%{section}%                   % the name
%{1}%                         % the level
%{0mm}%                       % the indent
%{-\baselineskip}%            % the before skip
%{0.5\baselineskip}%          % the after skip
%{\normalfont\large\itshape}} % the style


% Redefining the chapter heading styles

% Numbered chapter heading style:

\renewcommand{\@makechapterhead}[1]{%
  {\singlespacing
    \parindent \z@ \raggedright \normalfont
    \rule{\textwidth}{2pt}                           % horizontal line
    \vspace{5pt}%                                    % add some vertical space
    \ifnum \c@secnumdepth >\m@ne
        \huge\scshape \@chapapp\space \thechapter    % Chapter followed by number
        \par\nobreak
    \fi
    \interlinepenalty\@M
    \huge \scshape \bf #1\par                        % chapter title
    \vspace{5pt}%                                    % add some vertical space
    \nobreak
    \vskip 40\p@
  }}

% Unnumbered chapter heading style:

\renewcommand{\@makeschapterhead}[1]{%
  {\singlespacing
    \parindent \z@ \raggedright
    \normalfont
    \rule{\textwidth}{2pt}                           % horizontal line
    \vspace{5pt}%                                    % add some vertical space
    \interlinepenalty\@M
    \huge \scshape \bf #1\par                        % chapter title
    \vspace{5pt}%                                    % add some vertical space
    \nobreak
    \vskip 40\p@
  }}


% end of file:
\endinput

\end{comment}

答案1

正如 Ulrike Fischer 在评论中所说,问题出在\usepackage{aeguill}。这会加载不支持 TS1 文本符号的字体。它是几个过时的软件包之一,其中大多数都是无害的。

重复该错误的 MWE 是:

\documentclass{article}
\usepackage{aeguill}

\begin{document}
40\textdegree
\end{document}

您可以直接删除该行\usepackage{aeguill}。如果您确实想保留它,您可以启用以前通过以下方式加载的符号textcomp

\usepackage{substitutefont}
\substitutefont{TS1}{aer}{cmr}

或者

\usepackage{substitutefont}
\substitutefont{TS1}{aer}{lmr}

相关内容