-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Discussion/suggestion] Wrong driver selection results in incorrect PDF - forcibly use correct driver? #41
Comments
Yes, this will I think get better if we can eventually move graphics and color to use l3backend rather than the driver specific code here in graphics-def, it's harder to get the wrong backend in that case. Allowing the driver to be set via a package option, and in particular allow it to be set differently on different packages, was not the best choice, but it was hard to get every choice right before anyone had used any package options, and it's worked "well enough" over the years.... The document you show is not in itself an error just run on the wrong engine but there are worse cases that are essentially unrecoverable
can not end well. Loading |
Thanks David for your answer. Yeah, one can shoot oneself very easily with these options, as we see again and again. What really puzzles me is that we do create incorrect pdfs, which is a bad outcome I think. I agree that loading Not sure this can be achieved easily, though. |
we can do something, it's just that, as you will know, making something an error that has not been an error for the previous 30 years will break someone's pipeline, somewhere. There will be people patching in code to force things through. I'm a bit wary of making the options silently switch to dvi mode but it would be relatively easy for dvipdfmx.def and other dvi-only back end files to have an
and similarly pdftex.def could complain if not in pdf mode by begin{document} I'd have to worry a bit about the plain tex support in graphics-pln, but that wouldn't be the first time. |
Yes, agreed, that doesn't sound like a good idea.
That sounds like a good idea, at least for me. |
agreed, abort then with an explanation why and how to fix |
Not a bug but a discussion/suggestion:
If a user forces a certain graphics driver with
and the actual file is compiled with
pdflatex
(because it includes png/pdf/whatever),the generated PDF is not standards conform.
Example document:
Compiling this with
pdflatex
produces a PDF that contains invalid code, from the uncompress pdf:(see lengthy discussion here pdfminer/pdfminer.six#947)
Using the correct driver for pdflatex, or using latex/dvipdfmx produces correct PDF.
Of course, this is a user error! The question is, can we do something better here? Overriding the selected driver when it is obviously wrong?
The text was updated successfully, but these errors were encountered: