texlive[71181] Master/texmf-dist: luatexja (5may24)
commits+karl at tug.org
commits+karl at tug.org
Sun May 5 21:43:08 CEST 2024
Revision: 71181
https://tug.org/svn/texlive?view=revision&revision=71181
Author: karl
Date: 2024-05-05 21:43:08 +0200 (Sun, 05 May 2024)
Log Message:
-----------
luatexja (5may24)
Modified Paths:
--------------
trunk/Master/texmf-dist/doc/luatex/luatexja/COPYING
trunk/Master/texmf-dist/doc/luatex/luatexja/README
trunk/Master/texmf-dist/doc/luatex/luatexja/luatexja-en.pdf
trunk/Master/texmf-dist/doc/luatex/luatexja/luatexja-ja.pdf
trunk/Master/texmf-dist/doc/luatex/luatexja/luatexja.dtx
trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec.sty
trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty
trunk/Master/texmf-dist/tex/luatex/luatexja/ltj-base.lua
trunk/Master/texmf-dist/tex/luatex/luatexja/luatexja.sty
trunk/Master/texmf-dist/tex/luatex/luatexja/patches/lltjp-fontspec.sty
trunk/Master/texmf-dist/tex/luatex/luatexja/patches/lltjp-unicode-math.sty
Added Paths:
-----------
trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec-29c.sty
Modified: trunk/Master/texmf-dist/doc/luatex/luatexja/COPYING
===================================================================
--- trunk/Master/texmf-dist/doc/luatex/luatexja/COPYING 2024-05-05 19:42:43 UTC (rev 71180)
+++ trunk/Master/texmf-dist/doc/luatex/luatexja/COPYING 2024-05-05 19:43:08 UTC (rev 71181)
@@ -1,4 +1,4 @@
-Copyright (c) 2011--2023 The LuaTeX-ja project, All rights reserved.
+Copyright (c) 2011--2024 The LuaTeX-ja project, All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
Modified: trunk/Master/texmf-dist/doc/luatex/luatexja/README
===================================================================
--- trunk/Master/texmf-dist/doc/luatex/luatexja/README 2024-05-05 19:42:43 UTC (rev 71180)
+++ trunk/Master/texmf-dist/doc/luatex/luatexja/README 2024-05-05 19:43:08 UTC (rev 71181)
@@ -1,6 +1,6 @@
-The LuaTeX-ja Package 20240219.0
+The LuaTeX-ja Package 20240505.0
--------------------------------
-Copyright (c) 2011--2023 The LuaTeX-ja project
+Copyright (c) 2011--2024 The LuaTeX-ja project
License: modified BSD (see COPYING)
LuaTeX-ja is a macro package for typesetting Japanese documents with LuaTeX.
@@ -25,6 +25,7 @@
- luaotfload (v3.1 or later recommended)
- adobemapping (Adobe CMap files)
- LaTeX2e 2020-02-02 patch level 5 or later (if you want to use with LaTeX)
+ - l3kernel about 2023-10-10 or later
- etoolbox package
- ltxcmds package, pdftexcmds package
- filehook package, atbegshi package (for LaTeX2e 2020-02-02)
@@ -32,7 +33,7 @@
- Harano Aji fonts (https://github.com/trueroad/HaranoAjiFonts)
more specifically, HaranoAjiMincho-Regular and HaranoAjiGothic-Medium
- Using LuaTeX-ja with LuaHBTeX is not well tested.
+ Using LuaTeX-ja with Harfbuzz is not well tested.
One might be able to typeset documents without an error, but with
some unwanted results.
@@ -41,7 +42,7 @@
2. If you must/want to install manually:
a. Download the source archive from CTAN,
- or tagged as 20240219.0 in the Git repository by
+ or tagged as 20240505.0 in the Git repository by
<https://github.com/luatexja/luatexja/archive/refs/tags/$VER.zip>
b. Extract the archive and process following three files by LuaLaTeX
@@ -91,4 +92,4 @@
This file and ltj-kinsoku.lua are not used anymore.
(Do not remove ltj-kinsoku.tex.)
-Last commit date: Mon Feb 19 19:11:46 2024 +0900
+Last commit date: Sun May 5 22:35:36 2024 +0900
Modified: trunk/Master/texmf-dist/doc/luatex/luatexja/luatexja-en.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/doc/luatex/luatexja/luatexja-ja.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/doc/luatex/luatexja/luatexja.dtx
===================================================================
--- trunk/Master/texmf-dist/doc/luatex/luatexja/luatexja.dtx 2024-05-05 19:42:43 UTC (rev 71180)
+++ trunk/Master/texmf-dist/doc/luatex/luatexja/luatexja.dtx 2024-05-05 19:43:08 UTC (rev 71181)
@@ -648,9 +648,6 @@
%<ja> (DVI出力(\cs{outputmode=0})は対応していない.)
\item recent \href{https://github.com/latex3/luaotfload}{\Pkg{luaotfload}} (v3.1 or later recommended)
\item \Pkg{adobemapping} (Adobe cmap and pdfmapping files)
-\item \LaTeXe\ 2020-02-02 patch level 5 or later
-%<en> (if you want to use \LuaTeX-ja with \LaTeXe)
-%<ja> (\LaTeXe 下で\LuaTeX-jaを使う場合)
\item \href{https://github.com/josephwright/etoolbox/}{\Pkg{etoolbox}}
%<en> (if you want to use \LuaTeX-ja with \LaTeXe)
%<ja> (\LaTeXe 下で\LuaTeX-jaを使う場合)
Added: trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec-29c.sty
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec-29c.sty (rev 0)
+++ trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec-29c.sty 2024-05-05 19:43:08 UTC (rev 71181)
@@ -0,0 +1,415 @@
+%
+% luatexja-fontspec-29c.sty
+%
+
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{luatexja-fontspec-29c}[2024-05-05 fontspec support of LuaTeX-ja]
+\RequirePackage{l3keys2e}
+\ExplSyntaxOn
+
+%%%%%%%% Change Japanese font family by \rmfamily or not
+\bool_if:NT \__ltj_fontspec_match_bool {
+ \renewcommand\jttdefault{\gtdefault}
+ \@ltj at match@familytrue
+}
+%%%%%%%% Messages
+\msg_new:nnn {luatexja-fontspec} {addjfontfeatures-ignored}
+{
+ \string\addjfontfeature (s)~ ignored;\\
+ it~ cannot~ be~ used~ with~ a~ font~ that~ wasn't~ selected~ by~ luatexja-fontspec.
+}
+
+\msg_new:nnn {luatexja-fontspec} {altfont-ignored-by-norange}
+{
+ ignored~ sublist~ `#1'~ in~ AltFont~ (no~ range~ is~ specified).
+}
+
+\msg_new:nnn {luatexja-fontspec} {altfont-ignored-by-rangeonly}
+{
+ ignored~ sublist~ `#1'~ in~ AltFont~ (only~ range~ is~ specified).
+}
+
+\cs_generate_variant:Nn \prg_new_conditional:Nnn {Nnx}
+
+%%%%%%%% Internal control sequences
+%% Each CS is ltj_fontspec version that corresponds to original CS of fontspec.
+\cs_new:Nn \__ltj_fontspec_define_option:nn {
+ \__fontspec_keys_define_code:nnn {fontspec} {#1} {#2}
+}
+\cs_new:Nn \__ltj_fontspec_define_preparse_external:nn {
+ \__fontspec_keys_define_code:nnn {fontspec-preparse-external} {#1} {#2}
+}
+\cs_new:Nn \__ltj_fontspec_define_altfont_option:nn {
+ \__fontspec_keys_define_code:nnn {fontspec-ltjaltfont} {#1} {#2}
+}
+
+%% Alternate Fonts
+%% Spec: AltFont = {
+%% ...
+%% { Range = <range>, <font features> },
+%% { Range = <range>, Font = <font name>, <font features> },
+%% { Range = <range>, Font = <font name> },
+%% ...
+%% }
+\tl_new:N \l__ltj_fontspec_altname_tl
+\tl_new:N \l__ltj_fontspec_altrange_tl
+\clist_new:N \l__ltj_fontspec_altfont_clist
+\clist_new:N \l__ltj_fontspec_altfont_leftover_clist
+\int_new:N \g__ltj_fontspec_altnumber_int
+
+\__ltj_fontspec_define_altfont_option:nn {Range} {
+ \tl_set:Nn \l__ltj_fontspec_altrange_tl {#1}
+}
+\__ltj_fontspec_define_altfont_option:nn {Font} {
+ \fontspec_complete_fontname:Nn \l__ltj_fontspec_altname_tl {#1}
+}
+\__fontspec_keys_define_code:nnn {fontspec-ltjaltfont-reparse} {AltFont} {
+ \clist_put_right:Nn \l__ltj_fontspec_altfont_clist { #1 }
+}
+\__fontspec_keys_define_code:nnn {fontspec-ltjaltfont-reparse} {YokoFeatures} {
+ \clist_put_right:Nn \l__ltj_fontspec_fontfeat_yoko_clist { #1 }
+}
+\__fontspec_keys_define_code:nnn {fontspec-ltjaltfont-reparse} {TateFeatures} {
+ \clist_put_right:Nn \l__ltj_fontspec_fontfeat_tate_clist { #1 }
+}
+\__fontspec_keys_define_code:nnn {fontspec-ltjaltfont-reparse} {TateFont} {
+ \tl_if_empty:nF {#1} {
+ \fontspec_complete_fontname:Nn \l__ltj_fontspec_fontname_tate_tl {#1}
+ }
+}
+%%
+\clist_new:N \l__ltj_fontspec_fontfeat_yoko_clist
+\clist_new:N \l__ltj_fontspec_fontfeat_tate_clist
+\tl_new:N \l__ltj_fontspec_fontname_tate_tl
+
+\cs_new:Npn \__ltj_fontspec_DeclareFontFamily #1 #2 #3 {
+ \DeclareKanjiFamily {JY3} {#2} {#3}
+ \DeclareKanjiFamily {JT3} {#2} {#3}
+}
+
+%% save and restore global variable
+\tl_new:N \g__ltj_fontspec_kanji_nfss_family_tl
+\tl_new:N \g__ltj_fontspec_orig_nfss_family_tl
+\seq_new:N \l__ltj_fontspec_kanji_bf_series_seq
+\seq_new:N \l__ltj_fontspec_orig_bf_series_seq
+\clist_new:N \g__ltj_fontspec_kanji_default_fontopts_clist
+\clist_new:N \g__ltj_fontspec_orig_default_fontopts_clist
+
+\cs_new:Nn \__ltj_set_global_variable_for_kanji: {
+ \tl_gset_eq:NN \g__ltj_fontspec_orig_nfss_family_tl \g__fontspec_nfss_family_tl
+ \tl_gset_eq:NN \g__fontspec_nfss_family_tl \g__ltj_fontspec_kanji_nfss_family_tl
+ \seq_set_eq:NN \l__ltj_fontspec_orig_bf_series_seq \l__fontspec_bf_series_seq
+ \seq_set_eq:NN \l__fontspec_bf_series_seq \l__ltj_fontspec_kanji_bf_series_seq
+ %\seq_gclear:N \g__fontspec_bf_series_seq
+ \clist_set_eq:NN \g__ltj_fontspec_orig_default_fontopts_clist \g__fontspec_default_fontopts_clist
+ \clist_set_eq:NN \g__fontspec_default_fontopts_clist \g__ltj_fontspec_kanji_default_fontopts_clist
+}
+
+\cs_new:Nn \__ltj_restore_global_variable: {
+ \tl_gset_eq:NN \g__ltj_fontspec_kanji_nfss_family_tl \g__fontspec_nfss_family_tl
+ \tl_gset_eq:NN \g__fontspec_nfss_family_tl \g__ltj_fontspec_orig_nfss_family_tl
+ \seq_set_eq:NN \l__ltj_fontspec_kanji_bf_series_seq \l__fontspec_bf_series_seq
+ \seq_set_eq:NN \l__fontspec_bf_series_seq \l__ltj_fontspec_orig_bf_series_seq
+ \clist_set_eq:NN \g__ltj_fontspec_kanji_default_fontopts_clist \g__fontspec_default_fontopts_clist
+ \clist_set_eq:NN \g__fontspec_default_fontopts_clist \g__ltj_fontspec_orig_default_fontopts_clist
+}
+
+\cs_set_eq:NN \__ltj_orig_fontspec_select_font_family:nn \__fontspec_select_font_family:nn
+\cs_new_protected:Nn \__ltj_fontspec_select_font_family:nn {
+ \group_begin:
+ \__ltj_fontspec_define_option:nn {NoEmbed} {}
+ \__ltj_fontspec_define_option:nn {AltFont} {
+ \clist_put_right:Nn \l__ltj_fontspec_altfont_clist { ##1 }
+ }
+ \__ltj_fontspec_define_option:nn {CID} {
+ \__fontspec_update_featstr:n {cid=##1}
+ }
+ \__ltj_fontspec_define_option:nn {Kanjiskip} {
+ \str_if_eq:eeTF {false} { \str_lower_case:n { ##1 } }{
+ \__fontspec_update_featstr:n {-ltjksp}
+ } {
+ \__fontspec_update_featstr:n {+ltjksp}
+ }
+ }
+ \__ltj_fontspec_define_option:nn {JFM} {
+ \__fontspec_update_featstr:n {jfm=##1}
+ }
+ % vary by shape
+ \__ltj_fontspec_define_option:nn {YokoFeatures} {
+ \clist_put_right:Nn \l__ltj_fontspec_fontfeat_yoko_clist { ##1 }
+ }
+ \__ltj_fontspec_define_option:nn {TateFeatures} {
+ \clist_put_right:Nn \l__ltj_fontspec_fontfeat_tate_clist { ##1 }
+ }
+ \__ltj_fontspec_define_option:nn {TateFont}
+ {
+ \tl_if_empty:nF {##1} {
+ \fontspec_complete_fontname:Nn \l__ltj_fontspec_fontname_tate_tl {##1}
+ }
+ }
+ \__ltj_fontspec_define_option:nn {JFM-var} {
+ \__fontspec_update_featstr:n {jfmvar=##1}
+ }
+ \__ltj_fontspec_define_preparse_external:nn {NoEmbed} {
+ \cs_set:Npn \__fontspec_fontname_wrap:n ##1 {psft:##1}
+ }
+
+ %% Omit the warning message
+ %% "OpenType feature 'Kerning=Off' (-kern) not available ..."
+ \keys_define:nn {fontspec-opentype} {
+ Kerning/Off.code:n=\__fontspec_update_featstr:n {-kern}
+ }
+ \clist_set:Ne \g__fontspec_default_fontopts_clist {
+ YokoFeatures = { JFM=\ltj at stdyokojfm }, TateFeatures = { JFM=\ltj at stdtatejfm },
+ Scale=\Cjascale, Kerning=Off, Script=CJK,
+ \g__ltj_fontspec_kanji_default_fontopts_clist
+ }
+ \prop_set_eq:NN \g__fontspec_fontopts_prop \g__ltj_fontspec_fontopts_prop
+ \cs_set_eq:NN \__fontspec_make_font_shapes:Nnnnn \__ltj_fontspec_make_font_shapes:Nnnnn
+ \cs_set_eq:NN \DeclareFontFamily \__ltj_fontspec_DeclareFontFamily
+ \tl_set:Nn \g_fontspec_encoding_tl {JY3}
+ \__ltj_orig_fontspec_select_font_family:nn{#1}{#2}
+
+ \cs_gset:Npx \__ltj_fontspec_aftergroup {
+ \exp_not:N \tl_set:Nn \exp_not:N \l_fontspec_family_tl { \l_fontspec_family_tl }
+ }
+ \aftergroup \__ltj_fontspec_aftergroup
+ \group_end:
+}
+
+%% declare_shape
+
+\cs_new:Nn \__ltj_fontspec_declare_shape_yoko:nnnn {
+ \__ltj_fontspec_declare_shape_aux:nnnnnn {#1} {#2} {#3} {#4} { JY3 } { \l__ltj_fontspec_fontfeat_yoko_clist }
+}
+\cs_new:Nn \__ltj_fontspec_declare_shape_tate:nnnn {
+ \__ltj_fontspec_declare_shape_aux:nnnnnn {#1} {#2} {#3} {#4} { JT3 } { \l__ltj_fontspec_fontfeat_tate_clist }
+}
+\cs_new:Nn \__ltj_fontspec_declare_shape:nnnn {
+ \__ltj_fontspec_declare_shape_yoko:nnnn {#1} {#2} {#3} {#4}
+ \__ltj_fontspec_declare_shape_tate:nnnn {#1} {#2} {#3} {#4}
+}
+\cs_generate_variant:Nn \__ltj_fontspec_declare_shape:nnnn {nnxx}
+\cs_generate_variant:Nn \__ltj_fontspec_declare_shape_yoko:nnnn {nnxx}
+\cs_generate_variant:Nn \__ltj_fontspec_declare_shape_tate:nnnn {nnxx}
+
+\cs_new:Nn \__ltj_fontspec_declare_shape_aux:nnnnnn
+{
+ \tl_build_begin:N \l__fontspec_nfss_tl
+ \tl_build_begin:N \l__fontspec_nfss_sc_tl
+ \tl_set_eq:NN \l__fontspec_saved_fontname_tl \l_fontspec_fontname_tl
+
+ \tl_set:Nn \g_fontspec_encoding_tl {#5}
+ \tl_set:Nn \g__fontspec_nfss_enc_tl {#5}
+ \exp_args:Ne \clist_map_inline:nn {#4}
+ { \__ltj_fontspec_setup_single_size:nnn {#3} {#6} {##1} }
+ \tl_build_end:N \l__fontspec_nfss_tl
+ \tl_build_end:N \l__fontspec_nfss_sc_tl
+
+ \bool_set_true:N \l__fontspec_nosc_bool
+ \__fontspec_declare_shapes_normal:nn {#1} {#2}
+ \__fontspec_declare_shape_slanted:nn {#1} {#2}
+}
+
+\cs_new:Nn \__ltj_fontspec_setup_single_size:nnn
+{
+ \tl_clear:N \l__fontspec_size_tl
+ \tl_set_eq:NN \l__fontspec_sizedfont_tl \l__fontspec_saved_fontname_tl % in case not spec'ed
+
+ \keys_set_known:neN {fontspec-sizing} { \exp_after:wN \use:n #3 }
+ \l__fontspec_sizing_leftover_clist
+ \tl_if_empty:NT \l__fontspec_size_tl { \__fontspec_error:n {no-size-info} }
+
+ \str_if_eq:eeTF { \g__fontspec_nfss_enc_tl } { JY3 } {
+ % "normal"
+ \__fontspec_load_fontname:Nn \l_fontspec_fontname_tl {\l__fontspec_sizedfont_tl}
+ } {
+ \tl_if_empty:NTF \l__ltj_fontspec_fontname_tate_tl
+ { \__fontspec_load_fontname:Nn \l_fontspec_fontname_tl {\l__fontspec_sizedfont_tl} }
+ { \__fontspec_load_fontname:Nn \l_fontspec_fontname_tl {\l__ltj_fontspec_fontname_tate_tl} }
+ }
+ \__fontspec_setup_nfss:Nnnn \l__fontspec_nfss_tl {#1} {#2} {}
+}
+
+\cs_new:Nn \__ltj_fontspec_set_family:Nnn {
+ \__ltj_set_global_variable_for_kanji:
+ \cs_set_eq:NN \__fontspec_select_font_family:nn \__ltj_fontspec_select_font_family:nn
+ \__ltj_orig_fontspec_set_family:Nnn #1 {#2} {#3}
+ \cs_set_eq:NN \__fontspec_select_font_family:nn \__ltj_orig_fontspec_select_font_family:nn
+ \__ltj_restore_global_variable:
+}
+\cs_set_eq:NN \__ltj_orig_fontspec_set_family:Nnn \fontspec_set_family:Nnn
+\cs_set_eq:NN \__ltj_orig_fontspec_make_font_shapes:Nnnnn \__fontspec_make_font_shapes:Nnnnn
+\cs_set_eq:NN \__ltj_fontspec_orig_DeclareFontShape \DeclareFontShape
+
+\cs_new:Nn \__ltj_fontspec_make_font_shapes:Nnnnn {
+ \group_begin:
+ %% 基底フォント
+ \cs_set_eq:NN \__fontspec_font_set:Nnn \use_none:nnn
+ \cs_set_eq:NN \__fontspec_font_if_null:NT \use_none:nn
+ \cs_set_eq:NN \__fontspec_declare_shape:nnxx \__ltj_fontspec_declare_shape:nnxx
+ \__ltj_orig_fontspec_make_font_shapes:Nnnnn {#1} {#2} {#3} {#4} {#5}
+ %%
+ \__ltj_fontspec_make_font_shapes_alt:Nnnnnn {#1}{#2}{#3}
+ {#4, \l__ltj_fontspec_fontfeat_yoko_clist}{#5} {JY3 }
+ \__ltj_fontspec_make_font_shapes_alt:Nnnnnn {#1}{#2}{#3}
+ {#4, \l__ltj_fontspec_fontfeat_tate_clist}{#5} {JT3}
+ \group_end:
+ }
+
+%%% Altfont 内部処理部
+\cs_new:Nn \__ltj_fontspec_make_font_shapes_alt:Nnnnnn {
+ \group_begin:
+ \str_if_eq:eeTF { #6 } { JY3 } {
+ \cs_set_eq:NN \__fontspec_declare_shape:nnxx \__ltj_fontspec_declare_shape_yoko:nnxx
+ }{
+ \cs_set_eq:NN \__fontspec_declare_shape:nnxx \__ltj_fontspec_declare_shape_tate:nnxx
+ }
+ \keys_set_known:nn {fontspec-ltjaltfont-reparse} { #4 }
+ \clist_if_empty:NF \l__ltj_fontspec_altfont_clist {
+ \int_gzero:N \g__ltj_fontspec_altnumber_int
+ \clist_map_inline:Nn \l__ltj_fontspec_altfont_clist {
+ \tl_clear:N \l__ltj_fontspec_altrange_tl
+ \tl_set:Nn \l__ltj_fontspec_altname_tl { #1 }
+ \tl_set:Nn \l_tmpa_tl { #1 }
+
+ \keys_set_known:neN {fontspec-ltjaltfont} { \exp_after:wN \use:n ##1 }
+ \l__ltj_fontspec_altfont_leftover_clist
+ \keys_set_known:nn {fontspec-ltjaltfont-reparse} { \exp_after:wN \use:n ##1 }
+
+ \tl_if_empty:NT \l__ltj_fontspec_altrange_tl {
+ \msg_warning:nnn {luatexja-fontspec} {altfont-ignored-by-norange} { ##1 }
+ } {
+ \bool_if:nTF {
+ \tl_if_eq_p:NN \l__ltj_fontspec_altname_tl \l_tmpa_tl
+ &&
+ \tl_if_empty_p:N \l__ltj_fontspec_altfont_leftover_clist
+ } {
+ \msg_warning:nnn {luatexja-fontspec} {altfont-ignored-by-rangeonly} { ##1 }
+ } {
+ \__ltj_orig_fontspec_make_font_shapes:Nnnnn
+ { \l__ltj_fontspec_altname_tl } {#2}
+ {#3 _ alt \int_use:N \g__ltj_fontspec_altnumber_int }
+ {#4, \l__ltj_fontspec_altfont_leftover_clist }
+ {#5}
+ \DeclareAlternateKanjiFont
+ { #6 }{ \g__fontspec_nfss_family_tl }{#2}{#3}%
+ { #6 }{ \g__fontspec_nfss_family_tl }{#2}
+ { #3 _alt \int_use:N \g__ltj_fontspec_altnumber_int }
+ { \l__ltj_fontspec_altrange_tl }
+ \int_gincr:N \g__ltj_fontspec_altnumber_int
+ }
+ }
+ }
+ }
+ \group_end:
+}
+
+
+%%%%%%%% User commands
+\DeclareDocumentCommand \jfontspec { O{} m O{} } {
+ \__ltj_fontspec_set_family:Nnn \k at family {#1,#3}{#2}
+ \selectfont
+ \ignorespaces
+}
+
+\DeclareDocumentCommand \setmainjfont { O{} m O{} } {
+ \ifdefined\DeclareFontSeriesDefault
+ \DeclareFontSeriesDefault[mc]{bf}{\bfdefault}
+ \fi
+ \__ltj_fontspec_set_family:Nnn \mcdefault {#1,#3}{#2}
+ \unless\ifltj at disablejfam
+ \DeclareSymbolFont{mincho}{JY3}{\mcdefault}{\mddefault}{n}
+ \SetSymbolFont{mincho}{bold}{JY3}{\mcdefault}{\bfdefault}{n}
+ \fi
+ \normalfont
+}
+
+\DeclareDocumentCommand \setsansjfont { O{} m O{} } {
+ \ifdefined\DeclareFontSeriesDefault
+ \DeclareFontSeriesDefault[gt]{bf}{\bfdefault}
+ \fi
+ \__ltj_fontspec_set_family:Nnn \gtdefault {#1,#3}{#2}
+ \unless\ifltj at disablejfam
+ \DeclareMathAlphabet{\mathgt}{JY3}{\gtdefault}{\mddefault}{n}
+ \fi
+ \normalfont
+}
+
+\DeclareDocumentCommand \setmonojfont { O{} m O{} } {
+ \ifdefined\DeclareFontSeriesDefault
+ \DeclareFontSeriesDefault[jtt]{bf}{\bfdefault}
+ \fi
+ \__ltj_fontspec_set_family:Nnn \jttdefault {#1,#3}{#2}
+ \normalfont
+}
+
+\DeclareDocumentCommand \newjfontfamily { m O{} m O{} } {
+ \cs_set_eq:NN \fontspec_set_family:Nnn \__ltj_fontspec_set_family:Nnn
+ \newfontfamily #1 [#2,#4] {#3}
+ \cs_set_eq:NN \fontspec_set_family:Nnn \__ltj_orig_fontspec_set_family:Nnn
+}
+\DeclareDocumentCommand \renewjfontfamily { m O{} m O{} } {
+ \cs_set_eq:NN \fontspec_set_family:Nnn \__ltj_fontspec_set_family:Nnn
+ \renewfontfamily #1 [#2,#4] {#3}
+ \cs_set_eq:NN \fontspec_set_family:Nnn \__ltj_orig_fontspec_set_family:Nnn
+}
+\DeclareDocumentCommand \setjfontfamily { m O{} m O{} } {
+ \cs_set_eq:NN \fontspec_set_family:Nnn \__ltj_fontspec_set_family:Nnn
+ \setfontfamily #1 [#2,#4] {#3}
+ \cs_set_eq:NN \fontspec_set_family:Nnn \__ltj_orig_fontspec_set_family:Nnn
+}
+
+\DeclareDocumentCommand \newjfontface { m O{} m O{} } {
+ \newjfontfamily #1 [ BoldFont={},ItalicFont={},SmallCapsFont={},#2,#4 ] {#3}
+}
+
+\prop_new:N \l__ltj_fontspec_tmp_prop
+\prop_new:N \g__ltj_fontspec_fontopts_prop
+\DeclareDocumentCommand \defaultjfontfeatures { t+ o m }
+ {
+ \IfNoValueTF {#2}
+ { \__ltj_fontspec_set_default_features:nn {#1} {#3} }
+ { \__ltj_fontspec_set_font_default_features:nnn {#1} {#2} {#3} }
+ \ignorespaces
+ }
+\cs_new:Nn \__ltj_fontspec_set_default_features:nn
+ {
+ \__ltj_set_global_variable_for_kanji:
+ \__fontspec_set_default_features:nn {#1} {#2}
+ \__ltj_restore_global_variable:
+ }
+\cs_new:Nn \__ltj_fontspec_set_font_default_features:nnn
+ {
+ \prop_set_eq:NN \l__ltj_fontspec_tmp_prop \g__fontspec_fontopts_prop
+ \prop_set_eq:NN \g__fontspec_fontopts_prop \g__ltj_fontspec_fontopts_prop
+ \__fontspec_set_font_default_features:nnn {#1} {#2} {#3}
+ \prop_set_eq:NN \g__ltj_fontspec_fontopts_prop \g__fontspec_fontopts_prop
+ \prop_set_eq:NN \g__fontspec_fontopts_prop \l__ltj_fontspec_tmp_prop
+ }
+
+\DeclareDocumentCommand \addjfontfeatures {m} {
+ \__ltj_fontspec_if_fontspec_font:TF
+ {
+ \__ltj_set_global_variable_for_kanji:
+ \group_begin:
+ \tl_set_eq:NN \f at family \k at family
+ \cs_set_eq:NN \__fontspec_select_font_family:nn \__ltj_fontspec_select_font_family:nn
+ \addfontfeatures {#1}
+ \group_end:
+ \kanjifamily\g__fontspec_nfss_family_tl\selectfont
+ \__ltj_restore_global_variable:
+ }{
+ \msg_warning:nn {luatexja-fontspec} {addjfontfeatures-ignored}
+ }
+ \ignorespaces
+}
+
+\cs_set_eq:NN \addjfontfeature \addjfontfeatures
+
+\prg_new_conditional:Nnn \__ltj_fontspec_if_fontspec_font: {TF,T,F}
+{
+ \cs_if_exist:cTF {g__fontspec_fontinfo_ \k at family _prop} \prg_return_true: \prg_return_false:
+}
+
+\endinput
Property changes on: trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec-29c.sty
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec.sty
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec.sty 2024-05-05 19:42:43 UTC (rev 71180)
+++ trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec.sty 2024-05-05 19:43:08 UTC (rev 71181)
@@ -28,7 +28,11 @@
\ProcessKeysOptions{ luatexja-fontspec }
\RequirePackage{fontspec}[2019/03/15]% v2.7c
-\RequirePackage{luatexja-fontspec-27c} % v2.7c
+\@ifpackagelater{fontspec}{2024-05-03}{%
+ \RequirePackage{luatexja-fontspec-29c} % v2.9c
+}{
+ \RequirePackage{luatexja-fontspec-27c} % v2.7c
+}
\ExplSyntaxOff
%%%%%%%% Now we completely ignore kanjifont definition file.
Modified: trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty 2024-05-05 19:42:43 UTC (rev 71180)
+++ trunk/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty 2024-05-05 19:43:08 UTC (rev 71181)
@@ -1,5 +1,5 @@
% luatexja-preset.sty
-\ProvidesPackage{luatexja-preset}[2022-06-19 Japanese font presets]
+\ProvidesPackage{luatexja-preset}[2024-03-30 Japanese font presets]
\RequirePackage{expl3,l3keys2e}
\RequirePackage{luatexja}
@@ -57,7 +57,7 @@
}
\seq_put_right:Nn \g__ltjpreset_presets_seq { #1 }
}
-\cs_generate_variant:Nn \ltjpreset_declare_preset:nn {nx}
+\cs_generate_variant:Nn \ltjpreset_declare_preset:nn {ne}
\cs_new:Nn \__ltjpreset_declare_bool_option:nn {
\bool_new:c { g__ltjpreset_#1_bool }
\bool_set_false:c { g__ltjpreset_#1_bool }
@@ -100,6 +100,7 @@
mc .groups:n = { preset }, mc .value_required:n = true,
mc-bx .code:n =
\prop_put:Nnn \g__ltjpreset_font_prop { mc-b } {#1},
+ mc-bx .groups:n = { preset }, mc-bx .value_required:n = true,
gt .code:n =
\prop_put:Nnn \g__ltjpreset_font_prop { gt-u } {#1}
\prop_put:Nnn \g__ltjpreset_font_prop { gt-d } {#1}
@@ -112,6 +113,7 @@
\prop_put:Nnn \g__ltjpreset_font_prop { gt-d } {#1},
gt .groups:n = { preset }, gt .value_required:n = true,
gt-m .groups:n = { preset }, gt-m .value_required:n = true,
+ gt-bx .groups:n = { preset }, gt-bx .value_required:n = true,
}
\cs_set:Nn \ltjpreset_define_preset_prop:n {
\keys_define:nn { luatexja-preset } {
@@ -152,7 +154,7 @@
% 小塚 (Adobe)
%% Pro
-\ltjpreset_declare_preset:nx{kozuka-pro}{
+\ltjpreset_declare_preset:ne{kozuka-pro}{
mc-m = KozMinPro-Regular, mc-b = KozMinPro-Bold,
gt-d = KozGoPro-Regular, gt-b = KozGoPro-Bold,
gt-u = KozGoPro-Medium, gt-eb = KozGoPro-Heavy,
@@ -160,7 +162,7 @@
__custom = false, __office = false, __noembed = false,
}
%% Pr6
-\ltjpreset_declare_preset:nx{kozuka-pr6}{
+\ltjpreset_declare_preset:ne{kozuka-pr6}{
mc-m = KozMinProVI-Regular, mc-b = KozMinProVI-Bold,
gt-d = KozGoProVI-Regular, gt-b = KozGoProVI-Bold,
gt-u = KozGoProVI-Medium, gt-eb = KozGoProVI-Heavy,
@@ -168,7 +170,7 @@
__custom = false, __office = false, __noembed = false,
}
%% Pr6N
-\ltjpreset_declare_preset:nx{kozuka-pr6n}{
+\ltjpreset_declare_preset:ne{kozuka-pr6n}{
mc-m = KozMinPr6N-Regular, mc-b = KozMinPr6N-Bold,
gt-d = KozGoPr6N-Regular, gt-b = KozGoPr6N-Bold,
gt-u = KozGoPr6N-Medium, gt-eb = KozGoPr6N-Heavy,
@@ -177,7 +179,7 @@
}
% ヒラギノ (OSX)
-\ltjpreset_declare_preset:nx{hiragino-pro}{
+\ltjpreset_declare_preset:ne{hiragino-pro}{
mc-m = HiraMinPro-W3, mc-b = HiraMinPro-W6,
gt-d = HiraKakuPro-W3, gt-b = HiraKakuPro-W6,
gt-u = HiraKakuPro-W6, gt-eb = HiraKakuStd-W8,
@@ -184,7 +186,7 @@
mg-m = HiraMaruPro-W4, mc-l = HiraMinPro-W2,
__custom = false, __office = false, __noembed = false,
}
-\ltjpreset_declare_preset:nx{hiragino-pron}{
+\ltjpreset_declare_preset:ne{hiragino-pron}{
mc-m = HiraMinProN-W3, mc-b = HiraMinProN-W6,
gt-d = HiraKakuProN-W3, gt-b = HiraKakuProN-W6,
gt-u = HiraKakuProN-W6, gt-eb = HiraKakuStdN-W8,
@@ -193,7 +195,7 @@
}
% モリサワ
-\ltjpreset_declare_preset:nx{bizud}{
+\ltjpreset_declare_preset:ne{bizud}{
mc = BIZ-UDMinchoM.ttc,
gt-d = BIZ-UDGothicR.ttc, gt-b = BIZ-UDGothicB.ttc,
gt-u = BIZ-UDGothicR.ttc, gt-eb = BIZ-UDGothicB.ttc,
@@ -200,7 +202,7 @@
mg-m = BIZ-UDGothicB.ttc,
__custom = false, __office = false, __noembed = false,
}
-\ltjpreset_declare_preset:nx{morisawa-pro}{
+\ltjpreset_declare_preset:ne{morisawa-pro}{
mc = A-OTF-RyuminPro-Light.otf, mc-b = A-OTF-FutoMinA101Pro-Bold.otf,
gt-d = A-OTF-GothicBBBPro-Medium.otf , gt-b = A-OTF-FutoGoB101Pro-Bold.otf,
gt-u = A-OTF-GothicBBBPro-Medium.otf , gt-eb = A-OTF-MidashiGoPro-MB31.otf,
@@ -207,7 +209,7 @@
mg-m = A-OTF-Jun101Pro-Light.otf,
__custom = false, __office = false, __noembed = false,
}
-\ltjpreset_declare_preset:nx{morisawa-pr6n}{
+\ltjpreset_declare_preset:ne{morisawa-pr6n}{
mc = A-OTF-RyuminPr6N-Light.otf, mc-b = A-OTF-FutoMinA101Pr6N-Bold.otf,
gt-d = A-OTF-GothicBBBPr6N-Medium.otf , gt-b = A-OTF-FutoGoB101Pr6N-Bold.otf,
gt-u = A-OTF-GothicBBBPr6N-Medium.otf , gt-eb = A-OTF-MidashiGoPr6N-MB31.otf,
@@ -216,7 +218,7 @@
}
% 游明朝/游ゴシック (Win8.1)
-\ltjpreset_declare_preset:nx{yu-win}{
+\ltjpreset_declare_preset:ne{yu-win}{
mc-m = YuMincho-Regular, mc-b = YuMincho-Demibold,
gt-d = YuGothic-Regular, gt-b = YuGothic-Bold,
gt-u = YuGothic-Regular, gt-eb = YuGothic-Bold,
@@ -224,7 +226,7 @@
__custom = false, __office = false, __noembed = false,
}
% Win10
-\ltjpreset_declare_preset:nx{yu-win10}{
+\ltjpreset_declare_preset:ne{yu-win10}{
mc-m = YuMincho-Regular, mc-b = YuMincho-Demibold,
gt-d = YuGothic-Regular, gt-b = YuGothic-Bold,
gt-u = YuGothic-Medium, gt-eb = YuGothic-Bold,
@@ -234,7 +236,7 @@
% Yu fonts in OSX
% according to http://support.apple.com/kb/HT5944
-\ltjpreset_declare_preset:nx{yu-osx}{
+\ltjpreset_declare_preset:ne{yu-osx}{
mc = YuMincho~Medium, mc-b = YuMincho~Demibold,
gt-d = YuGothic~Medium, gt-u = YuGothic~Medium,
gt-b = YuGothic~Bold, gt-eb = YuGothic~Bold,
@@ -243,7 +245,7 @@
}
% moga-mobo
-\ltjpreset_declare_preset:nx{moga-mobo}{
+\ltjpreset_declare_preset:ne{moga-mobo}{
mc = Moga90Mincho, mc-b = Moga90Mincho~Bold,
gt-d = Moga90Gothic, gt-b = Moga90Gothic~Bold,
gt-u = Moga90Gothic, gt-eb = Moga90Gothic~Bold,
@@ -250,7 +252,7 @@
mg-m = Mobo90Gothic,
__custom = false, __office = false, __noembed = false,
}
-\ltjpreset_declare_preset:nx{moga-mobo-ex}{
+\ltjpreset_declare_preset:ne{moga-mobo-ex}{
mc = MogaEx90Mincho, mc-b = MogaEx90Mincho~Bold,
gt-d = MogaEx90Gothic, gt-b = MogaEx90Gothic~Bold,
gt-u = MogaEx90Gothic, gt-eb = MogaEx90Gothic~Bold,
@@ -259,7 +261,7 @@
}
% Ume fones
-\ltjpreset_declare_preset:nx{ume}{
+\ltjpreset_declare_preset:ne{ume}{
mc = Ume~Mincho,
gt-d = Ume~Gothic, gt-b = Ume~Gothic~O5,
gt-u = Ume~Gothic~O5, gt-eb = Ume~Gothic~O5,
@@ -268,7 +270,7 @@
}
% Source Han {Serif,Sans}
-\ltjpreset_declare_preset:nx{sourcehan}{
+\ltjpreset_declare_preset:ne{sourcehan}{
mc-m = Source~Han~Serif~Regular,
mc-b = Source~Han~Serif~Bold,
gt-d = Source~Han~Sans~Regular,
@@ -279,7 +281,7 @@
mc-l = Source~Han~Serif~Light,
__custom = false, __office = false, __noembed = false,
}
-\ltjpreset_declare_preset:nx{sourcehan-jp}{
+\ltjpreset_declare_preset:ne{sourcehan-jp}{
mc-m = Source~Han~Serif~JP~Regular,
mc-b = Source~Han~Serif~JP~Bold,
gt-d = Source~Han~Sans~JP~Regular,
@@ -290,7 +292,7 @@
mc-l = Source~Han~Serif~JP~Light,
__custom = false, __office = false, __noembed = false,
}
-\ltjpreset_declare_preset:nx{noto-otc}{
+\ltjpreset_declare_preset:ne{noto-otc}{
mc-m = Noto~Serif~CJK~Regular,
mc-b = Noto~Serif~CJK~Bold,
gt-d = Noto~Sans~CJK~Regular,
@@ -301,7 +303,7 @@
mc-l = Noto~Serif~CJK~Light,
__custom = false, __office = false, __noembed = false,
}
-\ltjpreset_declare_preset:nx{noto-otf}{
+\ltjpreset_declare_preset:ne{noto-otf}{
mc-m = Noto~Serif~CJK~JP~Regular,
mc-b = Noto~Serif~CJK~JP~Bold,
gt-d = Noto~Sans~CJK~JP~Regular,
@@ -312,10 +314,10 @@
mc-l = Noto~Serif~CJK~JP~Light,
__custom = false, __office = false, __noembed = false,
}
-\ltjpreset_declare_preset:nx{noto}{
+\ltjpreset_declare_preset:ne{noto}{
noto-otf,
}
-\ltjpreset_declare_preset:nx{noto-jp}{
+\ltjpreset_declare_preset:ne{noto-jp}{
mc-m = Noto~Serif~JP~Regular,
mc-b = Noto~Serif~JP~Bold,
gt-d = Noto~Sans~JP~Regular,
@@ -328,7 +330,7 @@
}
% HaranoAji {Mincho, Gothic}
-\ltjpreset_declare_preset:nx{haranoaji}{
+\ltjpreset_declare_preset:ne{haranoaji}{
mc-m = HaranoAjiMincho-Regular.otf,
mc-b = HaranoAjiMincho-Bold.otf,
gt-d = HaranoAjiGothic-Regular.otf,
@@ -342,30 +344,30 @@
% ipa, ipaex, ms
-\ltjpreset_declare_preset:nx{ipa}{
+\ltjpreset_declare_preset:ne{ipa}{
\__ltjpreset_set_uni:nn { IPAMincho } { IPAGothic }
}
-\ltjpreset_declare_preset:nx{ipaex}{
+\ltjpreset_declare_preset:ne{ipaex}{
\__ltjpreset_set_uni:nn { IPAExMincho } { IPAExGothic }
}
-\ltjpreset_declare_preset:nx{ms}{
+\ltjpreset_declare_preset:ne{ms}{
\__ltjpreset_set_uni:nn { MS-Mincho } { MS-Gothic }
}
% {ipa,ipaex,ms}-dx % Office 付属フォントを利用
-\ltjpreset_declare_preset:nx{ipaex-hg}{
+\ltjpreset_declare_preset:ne{ipaex-hg}{
\__ltjpreset_set_office:nn { IPAExMincho } { IPAExGothic }
}
-\ltjpreset_declare_preset:nx{ipa-hg}{
+\ltjpreset_declare_preset:ne{ipa-hg}{
\__ltjpreset_set_office:nn { IPAMincho } { IPAGothic }
}
-\ltjpreset_declare_preset:nx{ms-hg}{
+\ltjpreset_declare_preset:ne{ms-hg}{
\__ltjpreset_set_office:nn { MS-Mincho } { MS-Gothic }
}
% 非埋込
-\ltjpreset_declare_preset:nx{noembed}{
+\ltjpreset_declare_preset:ne{noembed}{
\__ltjpreset_set_uni:nn { Ryumin-Light } { GothicBBB-Medium },
__custom = false, __office = false, __noembed = true,
}
@@ -385,12 +387,12 @@
\bool_if:NF \g__ltjpreset_custom_bool {
\tl_set:Nn \l_tmpa_tl {, CJKShape=JIS2004 }
\tl_if_eq:NNT \l__ltjpreset_kanji_shape_tl \l_tmpa_tl {
- \tl_set:Nx \l_tmpb_tl { \prop_item:Nn \g__ltjpreset_font_prop { mc-m } }
+ \tl_set:Ne \l_tmpb_tl { \prop_item:Nn \g__ltjpreset_font_prop { mc-m } }
\tl_if_in:NnT \l_tmpb_tl { Moga90Mincho } {
\prop_clear:N \l_tmpa_prop
\prop_map_inline:Nn \g__ltjpreset_font_prop {
\tl_set:Nn \l_tmpb_tl { ##2 } \tl_remove_all:Nn \l_tmpb_tl {90}
- \prop_put:Nnx \l_tmpa_prop { ##1 } { \tl_use:N \l_tmpb_tl }
+ \prop_put:Nne \l_tmpa_prop { ##1 } { \tl_use:N \l_tmpb_tl }
}
\prop_set_eq:NN \g__ltjpreset_font_prop \l_tmpa_prop
}
@@ -398,7 +400,7 @@
\prop_clear:N \l_tmpa_prop
\prop_map_inline:Nn \g__ltjpreset_font_prop {
\tl_set:Nn \l_tmpb_tl { ##2 } \tl_remove_all:Nn \l_tmpb_tl {90}
- \prop_put:Nnx \l_tmpa_prop { ##1 } { \tl_use:N \l_tmpb_tl }
+ \prop_put:Nne \l_tmpa_prop { ##1 } { \tl_use:N \l_tmpb_tl }
}
\prop_set_eq:NN \g__ltjpreset_font_prop \l_tmpa_prop
}
@@ -405,37 +407,37 @@
}
}
%%%% リストからの展開
- \cs_set:Nx \__ltjpreset_font_mc_l: { \prop_item:Nn \g__ltjpreset_font_prop { mc-l } }
- \cs_set:Nx \__ltjpreset_font_mc_m: { \prop_item:Nn \g__ltjpreset_font_prop { mc-m } }
- \cs_set:Nx \__ltjpreset_font_mc_b: { \prop_item:Nn \g__ltjpreset_font_prop { mc-b } }
- \cs_set:Nx \__ltjpreset_font_gt_m: { \prop_item:Nn \g__ltjpreset_font_prop { gt-d } }
- \cs_set:Nx \__ltjpreset_font_gt_u: { \prop_item:Nn \g__ltjpreset_font_prop { gt-u } }
- \cs_set:Nx \__ltjpreset_font_gt_b: { \prop_item:Nn \g__ltjpreset_font_prop { gt-b } }
- \cs_set:Nx \__ltjpreset_font_gt_eb: { \prop_item:Nn \g__ltjpreset_font_prop { gt-eb } }
- \cs_set:Nx \__ltjpreset_font_mg_m: { \prop_item:Nn \g__ltjpreset_font_prop { mg-m } }
+ \cs_set:Ne \__ltjpreset_font_mc_l: { \prop_item:Nn \g__ltjpreset_font_prop { mc-l } }
+ \cs_set:Ne \__ltjpreset_font_mc_m: { \prop_item:Nn \g__ltjpreset_font_prop { mc-m } }
+ \cs_set:Ne \__ltjpreset_font_mc_b: { \prop_item:Nn \g__ltjpreset_font_prop { mc-b } }
+ \cs_set:Ne \__ltjpreset_font_gt_m: { \prop_item:Nn \g__ltjpreset_font_prop { gt-d } }
+ \cs_set:Ne \__ltjpreset_font_gt_u: { \prop_item:Nn \g__ltjpreset_font_prop { gt-u } }
+ \cs_set:Ne \__ltjpreset_font_gt_b: { \prop_item:Nn \g__ltjpreset_font_prop { gt-b } }
+ \cs_set:Ne \__ltjpreset_font_gt_eb: { \prop_item:Nn \g__ltjpreset_font_prop { gt-eb } }
+ \cs_set:Ne \__ltjpreset_font_mg_m: { \prop_item:Nn \g__ltjpreset_font_prop { mg-m } }
%% HG 系フォント + JIS2004/90JIS のときはフォント名を置換
\bool_if:nT { !\g__ltjpreset_custom_bool && \g__ltjpreset_office_bool } {
\tl_set:Nn \l_tmpa_tl {, CJKShape=JIS2004 }
\tl_if_eq:NNT \l__ltjpreset_kanji_shape_tl \l_tmpa_tl {
- \cs_set:Nx \__ltjpreset_font_mc_b: { hgrme04.ttc }
- \cs_set:Nx \__ltjpreset_font_gt_b: { hgrge04.ttc }
- \cs_set:Nx \__ltjpreset_font_gt_eb: { hgrsgu04.ttc }
- \cs_set:Nx \__ltjpreset_font_mg_m: { hgrsmp04.ttf }
+ \cs_set:Ne \__ltjpreset_font_mc_b: { hgrme04.ttc }
+ \cs_set:Ne \__ltjpreset_font_gt_b: { hgrge04.ttc }
+ \cs_set:Ne \__ltjpreset_font_gt_eb: { hgrsgu04.ttc }
+ \cs_set:Ne \__ltjpreset_font_mg_m: { hgrsmp04.ttf }
\cs_set_eq:NN \__ltjpreset_font_gt_m: \__ltjpreset_font_gt_u:
% HG ゴシックM のときはそうはいかないので 1 ウェイト時のゴシック体を使う
}
\tl_set:Nn \l_tmpa_tl {, CJKShape=JIS1990 }
\tl_if_eq:NNT \l__ltjpreset_kanji_shape_tl \l_tmpa_tl {
- \cs_set:Nx \__ltjpreset_font_mc_b: { hgrme.ttc }
- \cs_set:Nx \__ltjpreset_font_gt_b: { hgrge.ttc }
- \cs_set:Nx \__ltjpreset_font_gt_eb: { hgrsgu.ttc }
- \cs_set:Nx \__ltjpreset_font_mg_m: { hgrsmp.ttf }
+ \cs_set:Ne \__ltjpreset_font_mc_b: { hgrme.ttc }
+ \cs_set:Ne \__ltjpreset_font_gt_b: { hgrge.ttc }
+ \cs_set:Ne \__ltjpreset_font_gt_eb: { hgrsgu.ttc }
+ \cs_set:Ne \__ltjpreset_font_mg_m: { hgrsmp.ttf }
}
}
% mc/l
- \tl_set:Nx \l_tmpa_tl { \__ltjpreset_font_mc_l: }
+ \tl_set:Ne \l_tmpa_tl { \__ltjpreset_font_mc_l: }
\tl_if_empty:NT \l_tmpa_tl {\tl_set:Nn \l_tmpa_tl {~}}
- \cs_set:Nx \__ltjpreset_font_mc_l: {
+ \cs_set:Ne \__ltjpreset_font_mc_l: {
\tl_if_blank:nTF \l_tmpa_tl { \__ltjpreset_font_mc_m: } {\tl_use:N \l_tmpa_tl }
}
%% bold オプションの処理
@@ -479,7 +481,7 @@
\__ltjpreset_wrap_fontname:e { \cs:w __ltjpreset_font_#1_#2: \cs_end: }
\font \g__ltjpreset_font_test: = \l__ltjpreset_font_name:\relax
\ifx \g__ltjpreset_font_test: \nullfont
- \msg_warning:nnxxxx { luatexja-preset }{ no-font }
+ \msg_warning:nneeee { luatexja-preset }{ no-font }
{ \cs:w __ltjpreset_font_#1_#2: \cs_end: }{ #1/#2 }
{ \cs:w __ltjpreset_font_#3_#4: \cs_end: }{ #3/#4 }
\cs_gset_eq:cc { __ltjpreset_font_#1_#2: } { __ltjpreset_font_#3_#4: }
@@ -520,7 +522,7 @@
}
\fp_compare:nNnF \Cjascale = 1
- { \msg_warning:nnx { luatexja-preset }{ scale }{ \Cjascale } }
+ { \msg_warning:nne { luatexja-preset }{ scale }{ \Cjascale } }
% {1: encoding}{2: family}{3: series}{4: shape}{5: fontname}{6: feature}{7: scale}
\cs_new:Nn \__ltjpreset_declare_font_shape:nnnnnnn {
@@ -589,7 +591,7 @@
}
\tl_set:Nn \l_tmpa_tl {, CJKShape=JIS2004 }
\tl_if_eq:NNT \l__ltjpreset_kanji_shape_tl \l_tmpa_tl {
- \tl_set:Nx \l__ltjpreset_kanji_shape_tl { ;+jp04 }
+ \tl_set:Ne \l__ltjpreset_kanji_shape_tl { ;+jp04 }
}
\__ltjpreset_define_family:nnn {mc} {m} {\__ltjpreset_font_mc_m:}
\__ltjpreset_define_family:nnn {mc} {bx} {\__ltjpreset_font_mc_b:}
@@ -610,7 +612,7 @@
} {
\RequirePackage{luatexja-fontspec}
% scale
- \msg_warning:nnx { luatexja-preset }{ scale }{ \Cjascale }
+ \msg_warning:nne { luatexja-preset }{ scale }{ \Cjascale }
\tl_new:N \l__ltjpreset_add_features_tl
\bool_if:NT \g__ltjpreset_expert_bool {
@@ -621,7 +623,7 @@
\addjfontfeature{ Kerning=Off }
% 実際の fontspec の呼びだし
\cs_new:Nn \__ltjpreset_do_fontset: { \group_begin:
- \tl_gset:Nx \l__ltjpreset_add_features_tl {
+ \tl_gset:Ne \l__ltjpreset_add_features_tl {
\tl_use:N \l__ltjpreset_kanji_shape_tl,
YokoFeatures = { JFM = \tl_use:N \__ltjpreset_use_jfm_yoko_tl },
TateFeatures = { JFM = \tl_use:N \__ltjpreset_use_jfm_tate_tl },
Modified: trunk/Master/texmf-dist/tex/luatex/luatexja/ltj-base.lua
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/luatexja/ltj-base.lua 2024-05-05 19:42:43 UTC (rev 71180)
+++ trunk/Master/texmf-dist/tex/luatex/luatexja/ltj-base.lua 2024-05-05 19:43:08 UTC (rev 71181)
@@ -398,6 +398,19 @@
return
end
+--- fix \e at alloc@luafunction at count (gh:5)
+do
+ local t = lua.get_functions_table()
+ local m = 0
+ local n = tex.getcount('e at alloc@luafunction at count')
+ for i = 1,math.max(n, #t)+100 do-- I think 100 is sufficient
+ if t[i] then m = i end
+ end
+ if m>n then
+ tex.setcount('global', 'e at alloc@luafunction at count', m)
+ end
+end
+
-------------------- mock of debug logger
if not ltjb.out_debug then
local function no_op() end
Modified: trunk/Master/texmf-dist/tex/luatex/luatexja/luatexja.sty
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/luatexja/luatexja.sty 2024-05-05 19:42:43 UTC (rev 71180)
+++ trunk/Master/texmf-dist/tex/luatex/luatexja/luatexja.sty 2024-05-05 19:43:08 UTC (rev 71181)
@@ -27,7 +27,7 @@
\newif\ifltj at disablejfam
%%%% VERSION
-\def\LuaTeXjaversion{20240219.0}
+\def\LuaTeXjaversion{20240505.0}
%% Check if LaTeX is used.
\begingroup\expandafter\expandafter\expandafter\endgroup
Modified: trunk/Master/texmf-dist/tex/luatex/luatexja/patches/lltjp-fontspec.sty
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/luatexja/patches/lltjp-fontspec.sty 2024-05-05 19:42:43 UTC (rev 71180)
+++ trunk/Master/texmf-dist/tex/luatex/luatexja/patches/lltjp-fontspec.sty 2024-05-05 19:43:08 UTC (rev 71181)
@@ -35,7 +35,7 @@
{
\fontspec_set_family:Nnn \l__fontspec_rmfamily_family_tl {#1} {#2}
\tl_set_eq:NN \rmdefault \l__fontspec_rmfamily_family_tl
- \use:x
+ \use:e
{
\exp_not:n { \DeclareRobustCommand \rmfamily }
{
@@ -54,7 +54,7 @@
{
\fontspec_set_family:Nnn \l__fontspec_sffamily_family_tl {#1} {#2}
\tl_set_eq:NN \sfdefault \l__fontspec_sffamily_family_tl
- \use:x
+ \use:e
{
\exp_not:n { \DeclareRobustCommand \sffamily }
{
@@ -73,7 +73,7 @@
{
\fontspec_set_family:Nnn \l__fontspec_ttfamily_family_tl {#1} {#2}
\tl_set_eq:NN \ttdefault \l__fontspec_ttfamily_family_tl
- \use:x
+ \use:e
{
\exp_not:n { \DeclareRobustCommand \ttfamily }
{
@@ -94,7 +94,7 @@
{
\fontspec_set_family:Nnn \l__fontspec_rmfamily_family_tl {#1} {#2}
\tl_set_eq:NN \rmdefault \l__fontspec_rmfamily_family_tl
- \use:x
+ \use:e
{
\exp_not:n { \DeclareRobustCommand \rmfamily }
{
@@ -113,7 +113,7 @@
{
\fontspec_set_family:Nnn \l__fontspec_sffamily_family_tl {#1} {#2}
\tl_set_eq:NN \sfdefault \l__fontspec_sffamily_family_tl
- \use:x
+ \use:e
{
\exp_not:n { \DeclareRobustCommand \sffamily }
{
@@ -132,7 +132,7 @@
{
\fontspec_set_family:Nnn \l__fontspec_ttfamily_family_tl {#1} {#2}
\tl_set_eq:NN \ttdefault \l__fontspec_ttfamily_family_tl
- \use:x
+ \use:e
{
\exp_not:n { \DeclareRobustCommand \ttfamily }
{
Modified: trunk/Master/texmf-dist/tex/luatex/luatexja/patches/lltjp-unicode-math.sty
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/luatexja/patches/lltjp-unicode-math.sty 2024-05-05 19:42:43 UTC (rev 71180)
+++ trunk/Master/texmf-dist/tex/luatex/luatexja/patches/lltjp-unicode-math.sty 2024-05-05 19:43:08 UTC (rev 71181)
@@ -46,9 +46,9 @@
% ltjsclasses: use lua
\cs_new:Nn \lltjp_um_unmag_fsize:
{
- \cs_gset:Nx \lltjp_um_f at size: {\directlua{luatexja.ltjs_unmagnify_fsize(\f at size)}}
- \cs_gset:Nx \lltjp_um_sf at size: {\directlua{luatexja.ltjs_unmagnify_fsize(\sf at size)}}
- \cs_gset:Nx \lltjp_um_ssf at size: {\directlua{luatexja.ltjs_unmagnify_fsize(\ssf at size)}}
+ \cs_gset:Ne \lltjp_um_f at size: {\directlua{luatexja.ltjs_unmagnify_fsize(\f at size)}}
+ \cs_gset:Ne \lltjp_um_sf at size: {\directlua{luatexja.ltjs_unmagnify_fsize(\sf at size)}}
+ \cs_gset:Ne \lltjp_um_ssf at size: {\directlua{luatexja.ltjs_unmagnify_fsize(\ssf at size)}}
}
}{
% bxjscls: use \jsc at preadjust@extract at font
More information about the tex-live-commits
mailing list.