[pdftex] Bug report / suggestion

Heiko Oberdiek oberdiek at uni-freiburg.de
Wed Sep 3 20:55:17 CEST 2008


On Wed, Sep 03, 2008 at 11:59:45AM +0200, Thomas Werner wrote:

> Recently I encountered a very annoying difficulty in using latex.
> There is nothing bad about this and I do not consider this a bug.
> 
> The option '-output-format=dvi' is ignored, when [pdftex] is used
> in the preamble of the input file.

Of course, driver option `pdftex' means pdfTeX in *PDF* mode.
Thus you are first saying DVI mode, then PDF mode, the latter
wins and then you are complaining? Stop lying to LaTeX and
specify the right DVI driver, e.g.
  \usepackage[dvips]{color}
(Or even without option, pdfTeX in PDF mode is automatically
detected by most packages and config files can specify
default DVI drivers).

> Is it possible to make pdfTeX tell the user that (t)his option is
> ignored, because it contradicts the information of the input file?

Usually packages color/graphics/... are configured in such a way
that pdfTeX in PDF mode is detected and dvips is used for DVI mode.
If you are using dvips, then you don't need a driver option:
  \usepackage{color}
Otherwise use package ifpdf:

\usepackage{ifpdf}
\ifpdf
  \usepackage[pdftex]{color}
\else
  \usepackage[dvips]{color}% or whatever DVI driver you want to use
\fi

> As far as I have seen in the command line output and the log-file,
> this is not mentioned by the tex-compiler.
> 
> I would have appreciated such a hint from pdfTeX very much, since
> the information 'Output witten on whatever.pdf' in the described
> situation just means, that the output (somehow) does not have the
> intended format.

There is no need for such a hint. Option -output-format=dvi only
means the job starts with mode DVI. But the mode may be changed
many, many times before the first page is output (or some other
mode depended stuff is invoked).

Yours sincerely
  Heiko <oberdiek at uni-freiburg.de>
-- 


More information about the pdftex mailing list