Closed Maia-Everett closed 3 years ago
Looks like \newcommand
in subfile preamble is now broken too. Is this intended behavior?
It is documented, so it is a feature, not a bug ;-)
Let me guess: The problems occur when typesetting the main document that includes this file via \subfile
, but it works when typesetting the subfile directly, right?
The default behavior since 2.0 is that the preamble is only processed when typesetting the subfile but is ignored when loading the subfile from the main file (together with \documentclass
, \begin{document}
, \end{document}
and everything following \end{document}
). These are the options:
subfiles
package with the option v1
, i.e., \usepackage[v1]{subfiles}
. This will restore the behavior from older verions.\begin{document}
. Then they will be processed in any case.
I have a subfile that defines and then uses a font family using the
fontspec
package, like this:This works correctly with
subfiles
1.6, but version 2.2 breaks it:If I move the
\newfontfamily
command to the root.tex
file, the document compiles correctly.