我刚刚升级到 TexLive 2022(我之前使用的是 2016 版)。现在 XeLaTeX 无法排版我的文件。
我正在使用子文件将常见的前言和宏保存在一个地方,并引用几个较小的文件。
文件:test-format.tex:
%!TEX TS-program = xelatex
%!TEX encoding = UTF-8 Unicode
%, letterpaper
\documentclass[12pt,oneside,letterpaper,draft]{memoir}
\usepackage{ifxetex}
\usepackage{fontspec,xltxtra,xunicode}
\defaultfontfeatures{Mapping=tex-text,Ligatures=TeX}
\usepackage{lmodern}
\usepackage[spanish,es-noindentfirst]{babel}
\usepackage{hyperref}
\usepackage{setspace}
\usepackage{subfiles}
\usepackage{titlesec}
\usepackage{verse}
\usepackage[svgnames]{xcolor}
\usepackage{graphicx}
\usepackage{wrapfig}
\usepackage{calc}
\usepackage{ebgaramond}
\usepackage{microtype}
\usepackage{calligra}
\usepackage{lettrine}
\usepackage{ragged2e}
\usepackage{fourier-orns}
\usepackage{datetime}
\microtypesetup{babel=true,final}
然后归档 test.tex
\documentclass[test-format.tex]{subfiles}
\begin{document}
hello
\end{document}
排版会产生以下输出:
This is XeTeX, Version 3.141592653-2.6-0.999994 (TeX Live 2022) (preloaded format=xelatex)
restricted \write18 enabled.
entering extended mode
(./test.tex
LaTeX2e <2021-11-15> patch level 1
L3 programming layer <2022-04-29>
(/usr/local/texlive/2022/texmf-dist/tex/latex/subfiles/subfiles.cls
Document Class: subfiles 2020/11/14 v2.2 Multi-file projects (class)
Preamble taken from file `test-format.tex'
(/usr/local/texlive/2022/texmf-dist/tex/latex/import/import.sty)
(./test-format.tex
(/usr/local/texlive/2022/texmf-dist/tex/latex/memoir/memoir.cls
Document Class: memoir 2022/02/20 v3.7q configurable book, report, article docu
ment class
(/usr/local/texlive/2022/texmf-dist/tex/latex/etoolbox/etoolbox.sty)
(/usr/local/texlive/2022/texmf-dist/tex/generic/iftex/iftex.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/memoir/mem12.clo)
(/usr/local/texlive/2022/texmf-dist/tex/latex/tools/array.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/tools/dcolumn.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/tools/delarray.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/tools/tabularx.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/textcase/textcase.sty))
(/usr/local/texlive/2022/texmf-dist/tex/generic/iftex/ifxetex.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/fontspec/fontspec.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/l3packages/xparse/xparse.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/l3kernel/expl3.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/l3backend/l3backend-xetex.def)))
(/usr/local/texlive/2022/texmf-dist/tex/latex/fontspec/fontspec-xetex.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/base/fontenc.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/fontspec/fontspec.cfg)))
(/usr/local/texlive/2022/texmf-dist/tex/xelatex/xltxtra/xltxtra.sty
(/usr/local/texlive/2022/texmf-dist/tex/generic/iftex/ifluatex.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/realscripts/realscripts.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/metalogo/metalogo.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/graphicx.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/keyval.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/graphics.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/trig.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/graphics-cfg/graphics.cfg)
(/usr/local/texlive/2022/texmf-dist/tex/latex/graphics-def/xetex.def)))))
(/usr/local/texlive/2022/texmf-dist/tex/xelatex/xunicode/xunicode.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/tipa/t3enc.def))
(/usr/local/texlive/2022/texmf-dist/tex/latex/lm/lmodern.sty)
(/usr/local/texlive/2022/texmf-dist/tex/generic/babel/babel.sty
(/usr/local/texlive/2022/texmf-dist/tex/generic/babel/xebabel.def
(/usr/local/texlive/2022/texmf-dist/tex/generic/babel/txtbabel.def))
(/usr/local/texlive/2022/texmf-dist/tex/generic/babel-spanish/spanish.ldf))
(/usr/local/texlive/2022/texmf-dist/tex/latex/hyperref/hyperref.sty
(/usr/local/texlive/2022/texmf-dist/tex/generic/ltxcmds/ltxcmds.sty)
(/usr/local/texlive/2022/texmf-dist/tex/generic/pdftexcmds/pdftexcmds.sty
(/usr/local/texlive/2022/texmf-dist/tex/generic/infwarerr/infwarerr.sty))
(/usr/local/texlive/2022/texmf-dist/tex/generic/kvsetkeys/kvsetkeys.sty)
(/usr/local/texlive/2022/texmf-dist/tex/generic/kvdefinekeys/kvdefinekeys.sty)
(/usr/local/texlive/2022/texmf-dist/tex/generic/pdfescape/pdfescape.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/hycolor/hycolor.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/letltxmacro/letltxmacro.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/auxhook/auxhook.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/kvoptions/kvoptions.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/hyperref/pd1enc.def)
(/usr/local/texlive/2022/texmf-dist/tex/generic/intcalc/intcalc.sty)
(/usr/local/texlive/2022/texmf-dist/tex/generic/etexcmds/etexcmds.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/hyperref/puenc.def
(/usr/local/texlive/2022/texmf-dist/tex/latex/hyperref/puenc-greekbasic.def))
(/usr/local/texlive/2022/texmf-dist/tex/latex/url/url.sty)
(/usr/local/texlive/2022/texmf-dist/tex/generic/bitset/bitset.sty
(/usr/local/texlive/2022/texmf-dist/tex/generic/bigintcalc/bigintcalc.sty))
(/usr/local/texlive/2022/texmf-dist/tex/latex/base/atbegshi-ltx.sty))
(/usr/local/texlive/2022/texmf-dist/tex/latex/memoir/memhfixc.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/hyperref/hxetex.def
(/usr/local/texlive/2022/texmf-dist/tex/generic/stringenc/stringenc.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/rerunfilecheck/rerunfilecheck.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/base/atveryend-ltx.sty)
(/usr/local/texlive/2022/texmf-dist/tex/generic/uniquecounter/uniquecounter.sty
))) (/usr/local/texlive/2022/texmf-dist/tex/latex/subfiles/subfiles.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/titlesec/titlesec.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/xcolor/xcolor.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/graphics-cfg/color.cfg)
(/usr/local/texlive/2022/texmf-dist/tex/latex/xcolor/svgnam.def))
(/usr/local/texlive/2022/texmf-dist/tex/latex/wrapfig/wrapfig.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/tools/calc.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/ebgaramond/ebgaramond.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/xkeyval/xkeyval.sty
(/usr/local/texlive/2022/texmf-dist/tex/generic/xkeyval/xkeyval.tex
(/usr/local/texlive/2022/texmf-dist/tex/generic/xkeyval/xkvutils.tex)))
(/usr/local/texlive/2022/texmf-dist/tex/latex/base/textcomp.sty)
Missing character: There is no (U+0020) in font [EBGaramond-Initials.otf]/OT!
Missing character: There is no (U+0020) in font [EBGaramond-Initials.otf]/OT!
Missing character: There is no (U+0020) in font [EBGaramond-Initials.otf]/OT:
language=dflt;!
) (/usr/local/texlive/2022/texmf-dist/tex/latex/microtype/microtype.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/microtype/microtype-xetex.def)
(/usr/local/texlive/2022/texmf-dist/tex/latex/microtype/microtype.cfg))
(/usr/local/texlive/2022/texmf-dist/tex/latex/fundus-calligra/calligra.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/lettrine/lettrine.sty
(/usr/local/texlive/2022/texmf-dist/tex/generic/minifp/minifp.sty)
Loading lettrine.cfg
(/usr/local/texlive/2022/texmf-dist/tex/latex/lettrine/lettrine.cfg))
(/usr/local/texlive/2022/texmf-dist/tex/latex/ragged2e/ragged2e.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/fourier/fourier-orns.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/datetime/datetime.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/fmtcount/fmtcount.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/base/ifthen.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/fmtcount/fcprefix.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/fmtcount/fcnumparser.sty))
(/usr/local/texlive/2022/texmf-dist/tex/latex/amsmath/amsgen.sty)
Package fmtcount Warning: \ordinal already defined use \FCordinal instead. on i
nput line 466.
) (/usr/local/texlive/2022/texmf-dist/tex/latex/datetime/datetime-defaults.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/datetime/dt-spanish.def)))))
*
任何帮助将不胜感激。
答案1
提示*
意味着 TeX 读取了文件的末尾并且正在等待用户输入。
你可以用更简单的测试文件进行重现
\documentclass{memoir}
\usepackage{subfiles}
\usepackage{microtype}
\microtypesetup{babel=true,final}
产生
This is pdfTeX, Version 3.141592653-2.6-1.40.24 (TeX Live 2022) (preloaded format=pdflatex)
restricted \write18 enabled.
entering extended mode
(./cc263.tex
LaTeX2e <2021-11-15> patch level 1
L3 programming layer <2022-04-29>
(/usr/local/texlive/2022/texmf-dist/tex/latex/memoir/memoir.cls
Document Class: memoir 2022/02/20 v3.7q configurable book, report, article docu
ment class
(/usr/local/texlive/2022/texmf-dist/tex/latex/etoolbox/etoolbox.sty)
(/usr/local/texlive/2022/texmf-dist/tex/generic/iftex/iftex.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/memoir/mem10.clo)
(/usr/local/texlive/2022/texmf-dist/tex/latex/tools/array.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/tools/dcolumn.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/tools/delarray.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/tools/tabularx.sty)
(./textcase.sty))
(/usr/local/texlive/2022/texmf-dist/tex/latex/subfiles/subfiles.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/import/import.sty))
(/usr/local/texlive/2022/texmf-dist/tex/latex/microtype/microtype.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/keyval.sty)
(/usr/local/texlive/2022/texmf-dist/tex/latex/microtype/microtype-pdftex.def)
(/usr/local/texlive/2022/texmf-dist/tex/latex/microtype/microtype.cfg)))
*
这不是一个错误,而是一个诱导性提示,因此您可以输入如下 tex 命令
*\begin{document}
(/usr/local/texlive/2022/texmf-dist/tex/latex/l3backend/l3backend-pdftex.def)
(./cc263.aux)
Package microtype Warning: You did not load the babel or the polyglossia packag
e.
(microtype) The `babel' option won't have any effect.
(/usr/local/texlive/2022/texmf-dist/tex/latex/microtype/mt-cmr.cfg)
*hello
*\end{document}
[1{/usr/local/texlive/2022/texmf-var/fonts/map/pdftex/updmap/pdftex.map}]
(./cc263.aux)</usr/local/texlive/2022/texmf-dist/fonts/type1/public/amsfonts/cm
/cmr10.pfb>
Output written on cc263.pdf (1 page, 11170 bytes).
Transcript written on cc263.log.
输出结果
当然,以交互方式添加命令只会影响他的运行,因此要实现永久性的更改,您需要添加
\begin{document}
hello
\end{document}
至上述文件的末尾。
将其添加到文件末尾test-format.tex
同样会在处理时停止 tex 读取文件末尾的内容subfiles
。
答案2
回答我自己的问题:
评论包子文件在里面测试格式.tex文件修复了该问题。
%\usepackage{subfiles}