我可能问了一些愚蠢的问题,但为什么推动mwe.tex
包含
\documentclass{article}
\pagestyle{empty}
\begin{document}
Text
\end{document}
通过dvilualatex mwe && dvips mwe
导致输出
在mwe.dvi
和 中mwe.ps
?
我以为dvilualatex
luatex
是通过而不是来生成 DVI 文件latex
,不是吗?
顺便一提,dvips
虽然字体文件存在,但是控制台上会打印出一个奇怪的“未找到字体”错误消息:
$ dvips mwe && ls -la /usr/share/texmf/fonts/opentype/public/lm/lmroman10-regular.otf
This is dvips(k) 2021.1 (TeX Live 2022/dev) Copyright 2021 Radical Eye Software (www.radicaleye.com)
' LuaTeX output 2022.03.07:1640' -> mwe.ps
dvips: Font [/usr/share/texmf/fonts/opentype/public/lm/lmroman10-regular.otf] not found; using cmr10
</usr/share/texlive/texmf-dist/fonts/pk/ljfour/public/cm/dpi600/cmr10.pk>
dvips: Checksum mismatch in font [/usr/share/texmf/fonts/opentype/public/lm/lmroman10-regular.otf]
</usr/share/texlive/texmf-dist/dvips/base/tex.pro>
</usr/share/texlive/texmf-dist/dvips/l3backend/l3backend-dvips.pro>
</usr/share/texlive/texmf-dist/dvips/base/special.pro>. [1]
-rw-r--r-- 1 root root 111536 7. Okt 2009 /usr/share/texmf/fonts/opentype/public/lm/lmroman10-regular.otf
我们用
$ dvilualatex --version
This is LuaTeX, Version 1.14.0 (TeX Live 2022/dev/Debian)
$ dvips --version
This is dvips(k) 2021.1 (TeX Live 2022/dev) Copyright 2021 Radical Eye Software
kpathsea version 6.3.4/dev
答案1
虽然可以做一些事情,但或多或少确实如此,如果使用 OpenType 字体,dviluatex 将会编写一个任何 dvi 驱动程序都无法使用的 dvi 文件。(dvipdfmx 在最近的版本中对此有一些支持,但如果目的是获得 PostScript,那就无济于事)。
在您显示的 dvips 输出中,您会看到它在 Unicode OpenType Latin Modern 上失败,用其错误后备 cmr10 pk 位图替换并希望获得最佳效果.....
如果你使用 7 位或 8 位经典 Tex 字体,则生成的 dvi 文件可用,例如
\documentclass{article}
\usepackage[T1]{fontenc}
\begin{document}
Hello world
\directlua{tex.write('look Lua is here!')}
\end{document}
在 dvilualatex 中运行良好
This is LuaTeX, Version 1.15.0 (TeX Live 2022)
restricted system commands enabled.
(./cc059.tex
LaTeX2e <2021-11-15> patch level 1
L3 programming layer <2022-02-24>
(/usr/local/texlive/2022/texmf-dist/tex/latex/base/article.cls
Document Class: article 2021/10/04 v1.4n Standard LaTeX document class
(/usr/local/texlive/2022/texmf-dist/tex/latex/base/size10.clo))
(/usr/local/texlive/2022/texmf-dist/tex/latex/base/fontenc.sty
(/usr/local/texlive/2022/texmf-dist/tex/latex/lm/t1lmr.fd))
(/home/davidc/texmf/tex/latex/l3backend/l3backend-dvips.def) (./cc059.aux)
(/usr/local/texlive/2022/texmf-dist/tex/latex/base/ts1cmr.fd) [1] (./cc059.aux)
)
406 words of node memory still in use:
3 hlist, 1 vlist, 1 rule, 2 glue, 3 kern, 1 glyph, 4 attribute, 48 glue_spec
, 4 attribute_list, 1 write nodes
avail lists: 2:33,3:11,4:2,5:24,6:6,7:139,9:36
Output written on cc059.dvi (1 page, 296 bytes).
Transcript written on cc059.log.
dvips 很高兴
$ dvips cc059
This is dvips(k) 2022.1 (TeX Live 2022) Copyright 2022 Radical Eye Software (www.radicaleye.com)
' LuaTeX output 2022.03.07:1636' -> cc059.ps
</usr/local/texlive/2022/texmf-dist/dvips/base/tex.pro>
</home/davidc/texmf/dvips/l3backend/l3backend-dvips.pro>
</usr/local/texlive/2022/texmf-dist/fonts/enc/dvips/lm/lm-ec.enc>
</usr/local/texlive/2022/texmf-dist/dvips/base/texps.pro>
</usr/local/texlive/2022/texmf-dist/dvips/base/special.pro>.
</usr/local/texlive/2022/texmf-dist/fonts/type1/public/lm/lmr10.pfb>[1]
并且生成的 PostScript 使用可扩展的 1 型拉丁现代字体: