git.iko.soy/typeable/pandoc
on master help sign in
PDF: revert fix for #4484 (only compress images on last run).

Closes #4755. This will mean some increase in the time it takes to produce an image-heavy PDF with xelatex, but it will make tables of contents correct, which is more important. Note that the production time should also be decreased by the previous commit, which fixed a logic error affecting the number of runs. That change might mitigate the effect of this one.

commit146555e63623bfd1b960a0ef9b66c7853f6f6b3c authorJohn MacFarlane <jgm@berkeley.edu> dateFri 6 Jul 2018, 23:51 (8 years ago) parent55e8cb0
1 file changed+1−6
src/Text/Pandoc/PDF.hs+1−6
src/Text/Pandoc/PDF.hs+1−6
@@ -285,12 +285,7 @@ runTeXProgram verbosity program args runNumber numRuns tmpDir source = do
285285 let file' = file
286286#endif
287287 let programArgs = ["-halt-on-error", "-interaction", "nonstopmode",
288− "-output-directory", tmpDir'] ++
289− -- see #4484, only compress images on last run:
290− if program == "xelatex" && runNumber < numRuns
291− then ["-output-driver", "xdvipdfmx -z0"]
292− else []
293− ++ args ++ [file']
288+ "-output-directory", tmpDir'] ++ args ++ [file']
294289 env' <- getEnvironment
295290 let sep = [searchPathSeparator]
296291 let texinputs = maybe (tmpDir' ++ sep) ((tmpDir' ++ sep) ++)