Forums: 公開討議/質問 (Thread #42343)

TeX Live 2020でのluatexja-presetの挙動についての質問 (2020-05-15 14:17 by tsuucat #84970)

こんにちは、最近TeX Live 2020にアップデートした者です。
TeX Live 2020でluatexjaが動くかどうか試していたら、バグなのか意図されたものなのかわからなかったものがあったので質問します。

環境: macOS Mojave

(1) 原ノ味プリセットの\mgfamily
TeX Live 2020では原ノ味フォントがデフォルトになったことを知りました。
気になったのはuplatex + dvipdfmxでの \usepackage[deluxe,jis2004]{otf}では\mgfamilyにHaranoAjiGothic-Medium.otfが割り当てられ、
lualatex (ltjsarticle)での \usepackage[deluxe,jis2004]{luatexja-preset} では\mgfamilyにHaranoAjiGothic-Heavy.otfが割り当てられていることです。
これは意図されたものでしょうか。
-> https://osdn.net/projects/luatex-ja/scm/git/luatexja/commits/745fcf561e5fec57a2bea92e86b1f141e3bf52f4 で変更された?

(2) macOS付属のヒラギノ利用時のエラー
macOS付属のヒラギノ(多書体)を埋め込もうとして、\usepackage[deluxe,jis2004,hiragino-pron]{luatexja-preset} を書くとエラーが出て途中で失敗します。

% tl2020-sample-lt.tex
\documentclass[a4paper]{ltjsarticle}
\usepackage[no-math]{fontspec}
\usepackage[deluxe,jis2004,hiragino-pron]{luatexja-preset}
(省略)

$ lualatex tl2020-sample-lt.tex
This is LuaHBTeX, Version 1.12.0 (TeX Live 2020)
restricted system commands enabled.
(./tl2020-sample-lt.tex
LaTeX2e <2020-02-02> patch level 5
L3 programming layer <2020-04-06>
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/ltjsarticle.cls
Document Class: ltjsarticle 2019/11/23 ltjsclasses
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/luatexja.sty
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/luatexja-core.sty
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexbase/luatexbase.sty
(/usr/local/texlive/2020/texmf-dist/tex/luatex/ctablestack/ctablestack.sty))
(/usr/local/texlive/2020/texmf-dist/tex/generic/ltxcmds/ltxcmds.sty)
(/usr/local/texlive/2020/texmf-dist/tex/latex/pdftexcmds/pdftexcmds.sty
(/usr/local/texlive/2020/texmf-dist/tex/generic/infwarerr/infwarerr.sty)
(/usr/local/texlive/2020/texmf-dist/tex/generic/iftex/iftex.sty))
(/usr/local/texlive/2020/texmf-dist/tex/latex/xkeyval/xkeyval.sty
(/usr/local/texlive/2020/texmf-dist/tex/generic/xkeyval/xkeyval.tex
(/usr/local/texlive/2020/texmf-dist/tex/generic/xkeyval/xkvutils.tex
(/usr/local/texlive/2020/texmf-dist/tex/generic/xkeyval/keyval.tex))))
(/usr/local/texlive/2020/texmf-dist/tex/generic/atbegshi/atbegshi.sty)
(/usr/local/texlive/2020/texmf-dist/tex/latex/etoolbox/etoolbox.sty)
(/usr/local/texlive/2020/texmf-dist/tex/latex/everyhook/everyhook.sty
(/usr/local/texlive/2020/texmf-dist/tex/latex/svn-prov/svn-prov.sty))(load cach
e: /Users/masahiro/Library/texlive/2020/texmf-var/luatexja/ltj-cid-auto-adobe-j
apan1.luc) (/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/ltj-base.sty
) (/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/ltj-latex.sty
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/patches/lltjfont.sty
(/usr/local/texlive/2020/texmf-dist/tex/latex/base/tuenc.def)
(/usr/local/texlive/2020/texmf-dist/tex/latex/ms/everysel.sty)
ABD: EverySelectfont initializing macros)
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/patches/lltjdefs.sty
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/jfm-ujisv.lua)
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/jfm-ujis.lua))
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/patches/lltjcore.sty)
(/usr/local/texlive/2020/texmf-dist/tex/latex/filehook/filehook.sty)
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/patches/lltjp-geometry.
sty (/usr/local/texlive/2020/texmf-dist/tex/latex/l3kernel/expl3.sty
(/usr/local/texlive/2020/texmf-dist/tex/latex/l3backend/l3backend-pdfmode.def))
(/usr/local/texlive/2020/texmf-dist/tex/generic/iftex/ifluatex.sty))))
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/luatexja-compat.sty(loa
d cache: /Users/masahiro/Library/texlive/2020/texmf-var/luatexja/ltj-jisx0208.l
uc))) (/usr/local/texlive/2020/texmf-dist/tex/platex/jsclasses/jslogo.sty)
(/usr/local/texlive/2020/texmf-dist/tex/latex/sttools/stfloats.sty)
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/patches/lltjp-stfloats.
sty)) (/usr/local/texlive/2020/texmf-dist/tex/latex/fontspec/fontspec.sty
(/usr/local/texlive/2020/texmf-dist/tex/latex/l3packages/xparse/xparse.sty)
(/usr/local/texlive/2020/texmf-dist/tex/latex/fontspec/fontspec-luatex.sty
(/usr/local/texlive/2020/texmf-dist/tex/latex/base/fontenc.sty)
(/usr/local/texlive/2020/texmf-dist/tex/latex/fontspec/fontspec.cfg)))
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/patches/lltjp-fontspec.
sty)
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.
sty
(/usr/local/texlive/2020/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty)

(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspe
c.sty
(/usr/local/texlive/2020/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspe
c-27c.sty))

Package luatexja-preset Warning: Japanese fonts will be scaled by 0.924715.


Package luatexja-fontspec Warning: \addjfontfeature(s) ignored;
(luatexja-fontspec) it cannot be used with a font that wasn't
(luatexja-fontspec) selected by luatexja-fontspec.



Package fontspec Warning: OpenType feature 'CJKShape=JIS2004' (jp04) not
(fontspec) available for font 'HiraMinProN-W3' with script
(fontspec) 'CJK' and language 'Default'.


luaotfload | db : Reload initiated (formats: otf,ttf,ttc); reason: "Font HiraMinProN-W2 not found.".
luaotfload | resolve : sequence of 3 lookups yielded nothing appropriate.

! Package fontspec Error: The font "HiraMinProN-W2" cannot be found.

For immediate help type H <return>.
...

l.718 \ltjapplypreset {}

?

HiraMinProN-W2がないことが原因のようで、ドキュメントにはHiraMinProN-W2は購入が必要と書かれています。ただ、以前は通ってた気がします(曖昧です)。
以前も同様だったでしょうか。

Reply to #84970×

You can not use Wiki syntax
You are not logged in. To discriminate your posts from the rest, you need to pick a nickname. (The uniqueness of nickname is not reserved. It is possible that someone else could use the exactly same nickname. If you want assurance of your identity, you are recommended to login before posting.) Login

Re: TeX Live 2020でのluatexja-presetの挙動についての質問 (2020-05-15 15:31 by h7k #84971)

> (1) 原ノ味プリセットの\mgfamily
> 気になったのはuplatex + dvipdfmxでの \usepackage[deluxe,jis2004]{otf}では\mgfamilyにHaranoAjiGothic-Medium.otfが割り当てられ、
> lualatex (ltjsarticle)での \usepackage[deluxe,jis2004]{luatexja-preset} では\mgfamilyにHaranoAjiGothic-Heavy.otfが割り当てられていることです。

Source Han Serif/Sans, Noto CJK フォントでもそのようになっていますが,
これらについてのプリセットを導入した際に,よく考えず「小塚だと Heavy に
しているからなあ」とでも考えて丸ゴシックを Heavy に割り当てたのだと思います.
すでに気づいておられるように 745fcf56 で dvipdfmx の方に合わせたので,
次バージョンをリリースした際には直ると思います.

> (2) macOS付属のヒラギノ利用時のエラー
> ! Package fontspec Error: The font "HiraMinProN-W2" cannot be found.
こちらでも確認しました.
細明朝・極太ゴチ・丸ゴについては見つからなかったら
(エラーにはせずに)それぞれ中明朝・太ゴチ・太ゴチで代替させている
つもりだったのですが,なぜかうまくいってない…….
Reply to #84970

Reply to #84971×

You can not use Wiki syntax
You are not logged in. To discriminate your posts from the rest, you need to pick a nickname. (The uniqueness of nickname is not reserved. It is possible that someone else could use the exactly same nickname. If you want assurance of your identity, you are recommended to login before posting.) Login

Re: TeX Live 2020でのluatexja-presetの挙動についての質問 (2020-05-15 15:42 by h7k #84972)

メッセージ #84971 への返信
> > (2) macOS付属のヒラギノ利用時のエラー
> > ! Package fontspec Error: The font "HiraMinProN-W2" cannot be found.
> こちらでも確認しました.
> 細明朝・極太ゴチ・丸ゴについては見つからなかったら
> (エラーにはせずに)それぞれ中明朝・太ゴチ・太ゴチで代替させている
> つもりだったのですが,なぜかうまくいってない…….

commit 9f067912b で luatexja-preset.sty の内部命令に __ をつけたのですが,
細明朝・極太ゴチ・丸ゴの代替処理のところにつけ忘れていました.
26d71858 で直しましたが,どうでしょうか?
Reply to #84971

Reply to #84972×

You can not use Wiki syntax
You are not logged in. To discriminate your posts from the rest, you need to pick a nickname. (The uniqueness of nickname is not reserved. It is possible that someone else could use the exactly same nickname. If you want assurance of your identity, you are recommended to login before posting.) Login

Re: TeX Live 2020でのluatexja-presetの挙動についての質問 (2020-05-15 15:56 by h7k #84973)

メッセージ #84972 への返信
> commit 9f067912b で luatexja-preset.sty の内部命令に __ をつけたのですが,
> 細明朝・極太ゴチ・丸ゴの代替処理のところにつけ忘れていました.
> 26d71858 で直しましたが,どうでしょうか?

と思ったら今度はいつでも代替されていたので,30e12722a でさらに修正.
Reply to #84972

Reply to #84973×

You can not use Wiki syntax
You are not logged in. To discriminate your posts from the rest, you need to pick a nickname. (The uniqueness of nickname is not reserved. It is possible that someone else could use the exactly same nickname. If you want assurance of your identity, you are recommended to login before posting.) Login

Re: TeX Live 2020でのluatexja-presetの挙動についての質問 (2020-05-15 16:53 by tsuucat #84977)

メッセージ #84973 への返信
> メッセージ #84972 への返信
> > commit 9f067912b で luatexja-preset.sty の内部命令に __ をつけたのですが,
> > 細明朝・極太ゴチ・丸ゴの代替処理のところにつけ忘れていました.
> > 26d71858 で直しましたが,どうでしょうか?
>
> と思ったら今度はいつでも代替されていたので,30e12722a でさらに修正.

対応ありがとうございます。新しいものを取ってきて試してみると、以下のように変わり、エラーなくPDFを生成することができました。

luaotfload | db : Reload initiated (formats: otf,ttf,ttc); reason: "Font HiraMinProN-W2 not found.".
luaotfload | resolve : sequence of 3 lookups yielded nothing appropriate.

Package luatexja-preset Warning: Font HiraMinProN-W2 (mc/l) is not found.
(luatexja-preset) Hence I substitute HiraMinProN-W3 (mc/m) for
(luatexja-preset) it.

回答と対応ありがとうございました。🙇‍♂️
Reply to #84973

Reply to #84977×

You can not use Wiki syntax
You are not logged in. To discriminate your posts from the rest, you need to pick a nickname. (The uniqueness of nickname is not reserved. It is possible that someone else could use the exactly same nickname. If you want assurance of your identity, you are recommended to login before posting.) Login