Fix use of psfrags in ps backend + usetex. #16913
Merged
+14
−11
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Looks like psfrags interacts badly with
\newgeometry
, so we need touse
\geometry
instead in the custom preamble to set the paper size.In turn this means that
\usepackage{geometry}
needs to move to beforethe custom preamble into
TexManager._get_preamble()
, and thus wecan't pass the dvips option to it anymore, but fortunately dvips is
documented as the default driver anyways (section 5.6 of
geometry
docs). Also, in order to keep everything under 79 characters wide,
change
{72in,72in}
to just72in
(which is synonymous per section4.3.3 of
geometry
docs).Also insert some extra newlines in the generated tex file for ease of
debugging.
Closes #16898; sorry I don't have a test for now.
PR Summary
PR Checklist