这是我的问题。 我已经在 LaTeX 文档中写了一堆图形,我想将它们重新用于海报。 该图的代码如下所示:
\begin{figure}[htp]
\begin{center}
\subfigure[Figure A]{\label{fig:Sample-a}\includegraphics[scale=5]{Image1.png}}
\subfigure[Figure B]{\label{fig:Sampple-b}\includegraphics[scale=5]{Image2.png}}
\end{center}
\caption{This is my caption!}
\label{LineJustification}
\end{figure}
当我放在开头时它就起作用了:
\usepackage{subfigure}
\usepackage{graphicx}
当我将海报放在一起时,我使用的是我在 这个网站, 包含如下包:(
\documentclass[a0]{a0poster}
\pagestyle{empty}
\setcounter{secnumdepth}{0}
\usepackage[absolute]{textpos}
\usepackage[it]{subfigure}
并且我已经注释掉了横向文件中的图形、wrapfig 和 times 包,以防万一他们在干扰)。
那么什么给出呢? 当我尝试将相同的图形放入 a0poster 文档时,为什么会出现以下错误? 如果我不使用子图,文件会编译,但随后我必须重新处理所有图,这将是痛苦的。
!Undefined control sequence
<argument> if\@captype
topcap
I.154 \subfigure
[Figure A]{\label{fig:Sample-a}
(我正在使用 mactex,如果这意味着什么的话)
Here's my problem. I have a bunch of figures already written in a LaTeX document, and I'd like to reuse them for a poster. The code for the figure looks like:
\begin{figure}[htp]
\begin{center}
\subfigure[Figure A]{\label{fig:Sample-a}\includegraphics[scale=5]{Image1.png}}
\subfigure[Figure B]{\label{fig:Sampple-b}\includegraphics[scale=5]{Image2.png}}
\end{center}
\caption{This is my caption!}
\label{LineJustification}
\end{figure}
And it works when I put at the beginning:
\usepackage{subfigure}
\usepackage{graphicx}
When I'm putting together the poster, I'm using the template I've found online at this website, with packages like:
\documentclass[a0]{a0poster}
\pagestyle{empty}
\setcounter{secnumdepth}{0}
\usepackage[absolute]{textpos}
\usepackage[it]{subfigure}
(and I've commented out the graphics, wrapfig, and times packages from the landscape file, just in case they're interfering).
So what gives? Why do I get the following error when I try to put the same figure into the a0poster document? If I don't use subfigures, the file compiles, but then I'd have to rework all of my figures, which would be painful.
!Undefined control sequence
<argument> if\@captype
topcap
I.154 \subfigure
[Figure A]{\label{fig:Sample-a}
(I'm using mactex, if that means anything)
发布评论
评论(3)
下面的 TeX 文件在 PDFLaTeX 中对我来说工作得很好。 您需要更详细地描述您的问题,也许可以尝试将其精简为最小的示例。
我的pdfTeX、LaTeX、a0poster.cls和subfigure.sty的版本号如下:
The following TeX file works just fine for me in PDFLaTeX. You need to describe your problem in more detail, perhaps by trying to prune it down to a minimal example.
The version numbers of my pdfTeX, LaTeX, a0poster.cls, and subfigure.sty are as follows:
我听到的一种智慧是:你应该将海报制作为一页 A4 大小的文章,然后将其打印为 A0。 只需使用足够小的字体,例如
\footnotesize
。One wisdom I have heard: you should just do your posters as A4-sized articles with one page, and then print them as A0. Just use small enough font, like
\footnotesize
.我通过不使用子图,而是明确而准确地放置数字来解决这个问题。 有点肮脏的黑客行为,但海报反响很好。
I solved this problem by not using subfigure, but placing the figures explicitly and exactly. Kind of a dirty hack, but the poster went off well.