我正在制作一份讲义,在环境figure
和的帮助下我添加了一些图片marginfigure
。但我的问题是,当我编写讲义时,其中一个图的参考编号没有打印在 PDF 中。
这是 MWE
\PassOptionsToPackage{usenames,dvipsnames,table}{xcolor}
\documentclass[]{tufte-handout}
\usepackage[LGRx,TS1,T1]{fontenc}
\usepackage[utf8x]{inputenx}
\usepackage[polutonikogreek,spanish,activeacute,mexico]{babel}
\usepackage[sc,osf]{mathpazo}
\usepackage{amsmath,amssymb,amstext,amsthm}
%\usepackage{textcomp}
\usepackage{array,multirow,tabularx,ragged2e,booktabs}
\newcolumntype{Y}{>{\RaggedRight\arraybackslash}X}
\usepackage[per-mode=symbol]{siunitx}
\sisetup{
%output-decimal-marker = {,},
detect-weight= true,
range-units = brackets,
list-final-separator = { \translate{and} },
list-pair-separator = { \translate{and} },
range-phrase = { \translate{to (numerical range)} },
}
\usepackage{hyperref}
\usepackage{graphicx,subfigure,etex,tikz,pgfplots}
\graphicspath{{./imagen/}}
\usepackage[colorinlistoftodos,spanish,textsize=footnotesize]{todonotes}
\usepackage{acronym}
\acrodef{AHA}{American Heart Asociation}
\newcommand{\greek}[1]{{\selectlanguage{polutonikogreek}#1}}
\begin{document}
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent nec urna at lectus facilisis fringilla eu vel odio. Pellentesque luctus massa vel ipsum feugiat hendrerit. Suspendisse tristique malesuada consequat. Donec mi turpis, faucibus sit amet commodo sed, condimentum at sapien. Suspendisse consectetur urna dolor. Nulla vel libero at tortor suscipit accumsan. Donec sit amet mauris a ipsum malesuada molestie. Nulla fermentum nunc in metus pellentesque aliquet. Aenean hendrerit sem eu dui ornare, at interdum urna dictum. Donec nisi urna, varius eget consectetur ac, cursus non velit. Vestibulum eget sollicitudin dui, non interdum lectus. Vivamus eleifend euismod orci, sit amet posuere mauris placerat id.
Integer gravida laoreet massa sed scelerisque. Aenean scelerisque suscipit metus non suscipit. Aenean arcu metus, mollis eu sagittis et, cursus in justo. Nullam mollis auctor bibendum. Integer nec congue est, vitae scelerisque ipsum. Nullam ultrices sapien orci, eget vestibulum turpis euismod eget. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Vivamus sed quam id risus consequat gravida id a enim. Duis non nulla ac neque fringilla molestie. Mauris vel sagittis sapien. Morbi in posuere nisl. Vivamus consequat accumsan leo ut malesuada. Integer pretium fringilla suscipit. Suspendisse gravida urna ut luctus lobortis. Nunc at odio vel neque sagittis pharetra at a quam~\ref{fig:esqAHA}. Mauris quis ligula porttitor, mollis dui at, rutrum enim.
\begin{figure*}[htb]
\begin{flushleft}
\includegraphics[width=\textwidth]{F5_large}
\end{flushleft}
\caption[Drawing of cross-sections]{Drawing of cross-sections of identical, most proximal part of six left anterior descending coronary arteries. The morphology of the intima ranges from adaptive intimal thickening always present in this lesion-prone location to a type VI lesion in advanced atherosclerotic disease. Other cross-sections show sequence of atherosclerotic lesion types that may lead to type VI. Identical morphologies may be found in other lesion-prone parts of the coronary and many other arteries.}
\label{fig:esqAHA}
\end{figure*}
Mauris tristique imperdiet orci id rhoncus. Nam neque est, pellentesque non aliquam ac, eleifend nec lectus. Integer mollis porta elit, non pharetra diam. Duis eget est hendrerit, iaculis urna id, rutrum dui. Vivamus egestas sem a diam consequat commodo. Donec quis purus ultrices, sagittis eros nec, sagittis enim. Quisque egestas lorem ac pretium aliquet. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam sed posuere leo. Mauris odio velit, commodo at commodo id, rutrum nec justo. Donec in elit quis purus vestibulum scelerisque vitae eu lorem.
\begin{figure*}[htb]
\begin{flushleft}
\includegraphics[width=4in]{F4_large}
\end{flushleft}
\caption[Flow diagram]{Flow diagram in center column indicates pathways in evolution and progression of human atherosclerotic lesions. Roman numerals indicate histologically characteristic types of lesions enumerated in Table 2 and defined at left of flow diagram. The direction of arrows indicates sequence in which characteristic morphologies may change. From type I to type IV, changes in lesion morphology occur primarily because of increasing accumulation of lipid. The loop between types V and VI illustrates how lesions increase in thickness when thrombotic deposits form on their surfaces. Thrombotic deposits may form repeatedly over varied time spans in the same location and may be the principal mechanism for gradual occlusion of medium-sized arteries. }
\label{fig:sixAHA}
\end{figure*}
Phasellus commodo sed metus ac hendrerit. Ut feugiat molestie sem in viverra. Mauris sed suscipit erat, non pretium est. Cras auctor massa sit amet nulla aliquam, et dapibus ante lacinia. Donec et tempor risus, dignissim vulputate ipsum. Curabitur dui eros, vulputate euismod sollicitudin quis, aliquet eget nisi. Fusce id auctor tellus, quis congue dolor. Nam vel dignissim est. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Nam eget arcu ut tellus adipiscing sodales (see the figure~\ref{fig:sixAHA}). Pellentesque sed nunc urna.
Praesent blandit purus vitae tortor vestibulum, sit amet pharetra diam vestibulum. Phasellus sit amet gravida elit. Nulla laoreet blandit libero. Nam adipiscing congue adipiscing. Integer a nulla sit amet tortor scelerisque placerat at at lectus. Quisque tincidunt nisi in iaculis egestas. In ligula augue, aliquet a dui eu, malesuada rhoncus leo. Donec sit amet luctus ipsum. Nullam cursus erat erat, sit amet elementum lorem tempus nec. Ut nec augue porta, tristique justo eu, feugiat elit. Fusce semper, sapien feugiat tempor sodales, nulla justo laoreet sem, id placerat tortor elit ut erat. Nullam vitae nunc urna. Duis laoreet enim id metus egestas, rhoncus congue justo feugiat.
\end{document}
两个数据均取自这里和 分别为 4 和 5。
在我的 pdf 中,对第二个图的引用没有打印任何数字,而且每次引用时都会发生这种情况。这很奇怪。所有其他功能都运行正常。现在我在装有 MS Windows XP 和更新的 MikTeX 2.9 的 PC 上工作,所以我不知道出了什么问题。我有更多的图,其他图都运行正常。
就这样吧,问候。
答案1
您的使用LGRx
表明您的 TeX 系统不是最新的。目前最好的方法是避免声明任何希腊语编码。更新您的系统并修改序言如下:
\PassOptionsToPackage{usenames,dvipsnames,table}{xcolor}
\documentclass[]{tufte-handout}
\usepackage{etex} % should go first
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenx}
\usepackage[polutonikogreek,spanish,activeacute,mexico]{babel}
\usepackage[sc,osf]{mathpazo}
我也不推荐utf8x
。
您的问题是由于加载引起的,subfigure
该加载已被弃用近十年了。
而是加载subfig
,而不加载caption
,因为这样无法与tufte
类很好地配合:
\usepackage[caption=false]{subfig}
语法几乎相同,只是你说
\subfloat
而不是\subfigure
和\subtable
。
另外,hyperref
最后加载。