使用 epic 和 eepic 包编译过时代码时出现问题

使用 epic 和 eepic 包编译过时代码时出现问题

我收到一个需要编译的非常大的 tex 文件,但是在尝试编译它时,我反复收到非 pdf 特殊忽略错误,随后文档中没有任何包含的图形。

经过一番研究,我得出结论,它一定是 epic 和 eepic 包,但我无法找到一种解决方法,以便它仍然可以正确编译,而无需重写数百行代码。

下面是引起我痉挛的典型例子:

编辑:更新示例代码,以便它可以编译我遇到的所有错误。

\documentclass[12pt,amsfonts]{book}
\usepackage{amssymb,amsmath}
\usepackage{stmaryrd}
\usepackage{amsfonts}
\usepackage{graphics}
\usepackage{epic,eepic}
\begin{document}

\date{}

\begin{figure}[h] % This is Figure 1.1
\begin{picture}(440,480)(-230,-280)
\setlength{\unitlength}{0.3pt}
\drawline(-388,898)(564,-887)
\drawline(1200,77)(-1200,77)
\drawline(-36,-900)(-36,900)
\drawline(714,897)(-636,-903)
\drawline(1194,605)(-1191,-667)
\drawline(600,-899)(-747,897)
\drawline(388,-898)(-564,887)
\put(-660,-259){\circle{1248}}
\put(-20,-99){\circle{32}}
\put(-88,105){\circle{104}}
\put(-16,-63){\circle{40}}
\put(484,-363){\circle{1040}}
\put(-60,-91){\circle{48}}
\put(120,209){\circle{312}}
\put(-12,5){\circle{144}}
\put(-216,-63){\circle{280}}
\put(288,-175){\circle{504}}
\put(84,437){\circle{720}}
\end{picture}
\end{figure}


\end{document}

答案1

不对代码做任何更改(我只是将 0.3pt 修改为 0.2pt 以使图片适合普通纸张),使用pict2e(代替\Line\drawline

\documentclass[12pt,amsfonts]{book}
\usepackage{amssymb,amsmath}
\usepackage{stmaryrd}
\usepackage{amsfonts}
\usepackage{graphics}
%\usepackage{epic,eepic}
\usepackage{pict2e}
\newcommand{\drawline}{\Line}
\begin{document}

\date{}

\begin{figure}[ht] % This is Figure 1.1
\begin{picture}(440,480)(-230,-280)
\setlength{\unitlength}{0.2pt}% 0.3 is too big
\drawline(-388,898)(564,-887)
\drawline(1200,77)(-1200,77)
\drawline(-36,-900)(-36,900)
\drawline(714,897)(-636,-903)
\drawline(1194,605)(-1191,-667)
\drawline(600,-899)(-747,897)
\drawline(388,-898)(-564,887)
\put(-660,-259){\circle{1248}}
\put(-20,-99){\circle{32}}
\put(-88,105){\circle{104}}
\put(-16,-63){\circle{40}}
\put(484,-363){\circle{1040}}
\put(-60,-91){\circle{48}}
\put(120,209){\circle{312}}
\put(-12,5){\circle{144}}
\put(-216,-63){\circle{280}}
\put(288,-175){\circle{504}}
\put(84,437){\circle{720}}
\end{picture}
\end{figure}

\end{document}

在此处输入图片描述

相关内容