![在 LyX 上使用 pdflatex 加载阿拉伯文脚本时出现问题](https://linux22.com/image/467423/%E5%9C%A8%20LyX%20%E4%B8%8A%E4%BD%BF%E7%94%A8%20pdflatex%20%E5%8A%A0%E8%BD%BD%E9%98%BF%E6%8B%89%E4%BC%AF%E6%96%87%E8%84%9A%E6%9C%AC%E6%97%B6%E5%87%BA%E7%8E%B0%E9%97%AE%E9%A2%98.png)
当我尝试使用 pdfTeX 引擎在 LyX 上将包含阿拉伯文本的文档导出为 PDF 时,出现了这样的错误。
!pdfTeX 错误:pdflatex (文件 ae_almohanad_bold.pfb):无法打开 Type 1 字体 f
我的 LaTeX 日志中的日志如下:
This is pdfTeX, Version 3.141592653-2.6-1.40.25 (MiKTeX 23.5) (preloaded format=pdflatex 2023.7.25) 26 JUL 2023 19:44
entering extended mode
restricted \write18 enabled.
%&-line parsing enabled.
**./tes_bahasa_arab-2.tex
(tes_bahasa_arab-2.tex
LaTeX2e <2023-06-01> patch level 1
L3 programming layer <2023-06-30>
(/home/hikam/.miktex/texmfs/install/tex/latex/base/article.cls
Document Class: article 2023/05/17 v1.4n Standard LaTeX document class
(/home/hikam/.miktex/texmfs/install/tex/latex/base/size10.clo
File: size10.clo 2023/05/17 v1.4n Standard LaTeX file (size option)
)
\c@part=\count185
\c@section=\count186
\c@subsection=\count187
\c@subsubsection=\count188
\c@paragraph=\count189
\c@subparagraph=\count190
\c@figure=\count191
\c@table=\count192
\abovecaptionskip=\skip48
\belowcaptionskip=\skip49
\bibindent=\dimen140
) (/home/hikam/.miktex/texmfs/install/tex/latex/base/fontenc.sty
Package: fontenc 2021/04/29 v2.0v Standard LaTeX package
(/home/hikam/.miktex/texmfs/install/tex/latex/arabi/laeenc.def
File: laeenc.def 2006/01/01 v0.1 Local Arabic font encoding (test version: may
change)
Now handling font encoding LAE ...
... processing UTF-8 mapping file for font encoding LAE
(/home/hikam/.miktex/texmfs/install/tex/latex/arabi/laeenc.dfu
File: laeenc.dfu 2006/01/01 v1.0 UTF-8 support for Arabic and Farsi for use wit
h inputenc
defining Unicode char U+066A (decimal 1642)
defining Unicode char U+060C (decimal 1548)
defining Unicode char U+0660 (decimal 1632)
defining Unicode char U+0661 (decimal 1633)
defining Unicode char U+0662 (decimal 1634)
defining Unicode char U+0663 (decimal 1635)
defining Unicode char U+0664 (decimal 1636)
defining Unicode char U+0665 (decimal 1637)
defining Unicode char U+0666 (decimal 1638)
defining Unicode char U+0667 (decimal 1639)
defining Unicode char U+0668 (decimal 1640)
defining Unicode char U+0669 (decimal 1641)
defining Unicode char U+061B (decimal 1563)
defining Unicode char U+061F (decimal 1567)
defining Unicode char U+0621 (decimal 1569)
defining Unicode char U+0622 (decimal 1570)
defining Unicode char U+0623 (decimal 1571)
defining Unicode char U+0624 (decimal 1572)
defining Unicode char U+0625 (decimal 1573)
defining Unicode char U+0626 (decimal 1574)
defining Unicode char U+0627 (decimal 1575)
defining Unicode char U+0628 (decimal 1576)
defining Unicode char U+0629 (decimal 1577)
defining Unicode char U+062A (decimal 1578)
defining Unicode char U+062B (decimal 1579)
defining Unicode char U+062C (decimal 1580)
defining Unicode char U+062D (decimal 1581)
defining Unicode char U+062E (decimal 1582)
defining Unicode char U+062F (decimal 1583)
defining Unicode char U+0630 (decimal 1584)
defining Unicode char U+0631 (decimal 1585)
defining Unicode char U+0632 (decimal 1586)
defining Unicode char U+0633 (decimal 1587)
defining Unicode char U+0634 (decimal 1588)
defining Unicode char U+0635 (decimal 1589)
defining Unicode char U+0636 (decimal 1590)
defining Unicode char U+0637 (decimal 1591)
defining Unicode char U+0638 (decimal 1592)
defining Unicode char U+0639 (decimal 1593)
defining Unicode char U+063A (decimal 1594)
defining Unicode char U+0640 (decimal 1600)
defining Unicode char U+0641 (decimal 1601)
defining Unicode char U+0642 (decimal 1602)
defining Unicode char U+0643 (decimal 1603)
defining Unicode char U+0644 (decimal 1604)
defining Unicode char U+0645 (decimal 1605)
defining Unicode char U+0646 (decimal 1606)
defining Unicode char U+0647 (decimal 1607)
defining Unicode char U+0648 (decimal 1608)
defining Unicode char U+0649 (decimal 1609)
defining Unicode char U+064A (decimal 1610)
defining Unicode char U+064B (decimal 1611)
defining Unicode char U+064C (decimal 1612)
defining Unicode char U+064D (decimal 1613)
defining Unicode char U+064E (decimal 1614)
defining Unicode char U+064F (decimal 1615)
defining Unicode char U+0650 (decimal 1616)
defining Unicode char U+0651 (decimal 1617)
defining Unicode char U+0652 (decimal 1618)
defining Unicode char U+067E (decimal 1662)
defining Unicode char U+0686 (decimal 1670)
defining Unicode char U+0698 (decimal 1688)
defining Unicode char U+06A9 (decimal 1705)
defining Unicode char U+06AF (decimal 1711)
defining Unicode char U+06CC (decimal 1740)
defining Unicode char U+06F0 (decimal 1776)
defining Unicode char U+06F1 (decimal 1777)
defining Unicode char U+06F2 (decimal 1778)
defining Unicode char U+06F3 (decimal 1779)
defining Unicode char U+06F4 (decimal 1780)
defining Unicode char U+06F5 (decimal 1781)
defining Unicode char U+06F6 (decimal 1782)
defining Unicode char U+06F7 (decimal 1783)
defining Unicode char U+06F8 (decimal 1784)
defining Unicode char U+06F9 (decimal 1785)
defining Unicode char U+200C (decimal 8204)
defining Unicode char U+06D5 (decimal 1749)
))) (/home/hikam/.miktex/texmfs/install/tex/latex/base/inputenc.sty
Package: inputenc 2021/02/14 v1.3d Input encoding file
\inpenc@prehook=\toks17
\inpenc@posthook=\toks18
(/home/hikam/.miktex/texmfs/install/tex/latex/arabi/cp1256.def
File: cp1256.def 2006/01/01 v0.1 CP1256 Arabic input encoding file
) (/home/hikam/.miktex/texmfs/install/tex/latex/base/latin9.def
File: latin9.def 2021/02/14 v1.3d Input encoding file
)) (/home/hikam/.miktex/texmfs/install/tex/generic/babel/babel.sty
Package: babel 2023/06/26 v3.90 The Babel package
\babel@savecnt=\count193
\U@D=\dimen141
\l@unhyphenated=\language1
(/home/hikam/.miktex/texmfs/install/tex/generic/babel/txtbabel.def)
\bbl@readstream=\read2
\bbl@dirlevel=\count194
*************************************
* Local config file bblopts.cfg used
*
(/home/hikam/.miktex/texmfs/install/tex/latex/arabi/bblopts.cfg
File: bblopts.cfg 2005/09/08 v0.1 add Arabic and Farsi to "declared" options of
babel
) (/home/hikam/.miktex/texmfs/install/tex/latex/arabi/arabic.ldf
File: arabic.ldf
Language: arabic 2006/01/01 v0.1 Arabic support for the babel system
Package babel Warning: No hyphenation patterns were preloaded for
(babel) the language 'Arabic' into the format.
(babel) Please, configure your TeX system to add them and
(babel) rebuild the format. Now I will use the patterns
(babel) preloaded for \language=0 instead on input line 35.
...
!pdfTeX error: pdflatex (file ae_almohanad_bold.pfb): cannot open Type 1 font f
ile for reading
==> Fatal error occurred, no output PDF file produced!
问题是什么?如何解决?。即使如此,我目前仍在使用 TeXLive 的完整软件包,或者texlive-full
现在在我的 Xubuntu 22.04 计算机上使用。我目前使用 LyX 版本 2.3.6。
我复制了一个文件夹,其中包含使用 TeX 渲染阿拉伯文本所需的所有字体。只是知道我在 LyX 上使用 arabi 渲染我的阿拉伯文本。
我将arabi
文件从 CTAN 移至我的主目录中的下载 (Unduhan) 文件夹,并将其中的 Type 1 字体文件夹 ( /home/hikam/Unduhan/arabi/arabi/texmf/fonts/type1/arabi/
) 复制到目录/usr/share/texmf/fonts/type1/
。即使这样也无法解决我之前提到的问题。
需要知道它ae_almohanad_bold.pfb
位于arabi
我复制到 texmf 目录的下载文件夹内。