xelatex での epspdf 変換の問題

xelatex での epspdf 変換の問題

私は xelatex を使用しており、パッケージを使用して、図から不要な空の余白をオンザフライで削除しようとしています。図自体は動的に生成され、オプションをepspdfconversion使用してタイトな境界ボックスを計算するのは良いアイデアのように思えました。bboxepspdf

残念ながら、epspdfconversion は xelatex とうまく連携しないようです。以下は最低限の動作例です。

\documentclass{tufte-handout}

%\usepackage{xltxtra}
\usepackage{color}
\usepackage[bbox,pdftopdf=true,suffix=]{epspdfconversion}

\begin{document}
\includegraphics{unnamed-chunk-2.pdf}
\end{document}`

ただし、コメントを解除し\usepackage{xltxtra}て xelatex でコンパイルすると、次のメッセージが表示されます。

Package epstopdf Warning: Drivers other than `pdftex.def' are not supported.

epspdfconversion.sty is using epstopdf.sty with the following setup:
    update=true,
    verbose=true,
    prefersuffix=true,
    suffix=,
    option outdir not set. Default: same directory as the .eps-source-file
    append,
    enable
epspdf is used with the following command:
    epspdf --bbox <file> 
Package epspdfconversion Info: 
(epspdfconversion)             epspdf --bbox <file> is used to convert eps-pdf
(epspdfconversion)             (not epstopdf (script))
(epspdfconversion)              on input line 334.
! Undefined control sequence.
l.345 \epstopdfDeclareGraphicsRule
                                  {.eps}{pdf}{.pdf}{%
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
misspelled it (e.g., `\hobx'), type `I' and the correct
spelling (e.g., `I\hbox'). Otherwise just continue,
and I'll forget about whatever was undefined.

これは xelatex との競合のようです。epspdfconversion.sty私は追加の OTF フォントを使用しているので、xelatex の使用が必要なようです。この問題を解決または回避するための推奨事項はありますか?

答え1

epstopdf最初の警告が示すように、pdftexは のドライバでのみ動作します。ただし、も と同様に使用できます。graphicslualatexpdflatex

関連情報