我正在使用\boldsymbol{}
和\textit{}
,但它们无法被识别。文档序言如下:
\documentclass{book}
\usepackage[spanish]{babel}
\selectlanguage{spanish}
\usepackage[utf8]{inputenc}
\setcounter{tocdepth}{4}
\setcounter{secnumdepth}{4}
\usepackage{parskip}
\usepackage{graphicx}
\usepackage{multirow}
\usepackage{amsmath, calc}
\usepackage[margin=1.5in]{geometryit is}
\usepackage{hyperref}
\usepackage{textcomp}
\usepackage{listings}
\usepackage[svgnames]{xcolor}
\usepackage{fontspec}
\usepackage{mathptmx}
\usepackage[nottoc,notlot,notlof]{tocbibind}
\usepackage[numbers]{natbib}
\begin{document}
For example, I'm using $\boldsymbol{x}_t$ and
\textit{vector de estados} within a paragraph.
\end{document}
哪些行与字体或命令有关,不起作用?我应该更改什么?
答案1
\documentclass{book}
\usepackage[spanish]{babel}
\selectlanguage{spanish}
\usepackage[utf8]{inputenc}
\setcounter{tocdepth}{4}
\setcounter{secnumdepth}{4}
\usepackage{parskip}
\usepackage{graphicx}
\usepackage{multirow}
\usepackage{amsmath, calc}
\usepackage[margin=1.5in]{geometry}
\usepackage{hyperref}
\usepackage{textcomp}
\usepackage{listings}
\usepackage[svgnames]{xcolor}
%\usepackage{fontspec}
\usepackage{mathptmx}
\usepackage[nottoc,notlot,notlof]{tocbibind}
\usepackage[numbers]{natbib}
\begin{document}
For example, I'm using $\boldsymbol{x}_t$ and \textit{vector de estados} within a paragraph.
\end{document}
mathptmx
很旧,没有粗体字体,更好的克隆是newtxmath
\documentclass{book}
\usepackage[spanish]{babel}
\selectlanguage{spanish}
\usepackage[utf8]{inputenc}
\setcounter{tocdepth}{4}
\setcounter{secnumdepth}{4}
\usepackage{parskip}
\usepackage{graphicx}
\usepackage{multirow}
\usepackage{amsmath, calc}
\usepackage[margin=1.5in]{geometry}
\usepackage{hyperref}
%\usepackage{textcomp}
\usepackage{listings}
\usepackage[svgnames]{xcolor}
%\usepackage{fontspec}
%\usepackage{mathptmx}
\usepackage{newtxtext,newtxmath}
\usepackage[nottoc,notlot,notlof]{tocbibind}
\usepackage[numbers]{natbib}
\begin{document}
For example, I'm using $\boldsymbol{x}_t$ and \textit{vector de estados} within a paragraph.
\end{document}