2 % luatexja-fontspec.sty
5 \NeedsTeXFormat{LaTeX2e}
6 \ProvidesPackage{luatexja-fontspec}[2015/01/15 fontspec support of LuaTeX-ja]
7 \RequirePackage{l3keys2e,luatexja}
10 \bool_new:N \ltj_fontspec_match
11 \cs_set:Nn \ltj_fontspec_pass_opts: {}
12 \keys_define:nn { luatexja-fontspec }
14 match .bool_set:N = \ltj_fontspec_match_bool,
15 match .default:n = true,
16 pass .code:n = \cs_set:Nn \ltj_fontspec_pass_opts: {#1},% 互換性
18 \ProcessKeysOptions { luatexja-fontspec }
19 \RequirePackage[\ltj_fontspec_pass_opts:]{fontspec}[2014/06/01]% v2.4
20 \RequirePackage{luatexja-fontspec-24}
23 %%%%%%%% Now we completely ignore kanjifont definition file.
26 % We must redefine \try@load@fontshape to ignore kanjifont definitions at all.
27 \def\try@load@fontshape{%
29 \ifx\csname \f@encoding+\f@family\endcsname\relax
30 \directlua{luatexja.jfont.is_kenc('\luatexluaescapestring{\f@encoding}')}%
31 \ifin@\else % Alphabetic font
32 \@font@info{Try loading font information for \f@encoding+\f@family}%
33 \global\expandafter\let
34 \csname\f@encoding+\f@family\endcsname\@empty
36 \let\nfss@catcodes\relax
39 \noexpand\InputIfFileExists{\f@encoding\f@family.fd}}}%
41 {\@input@{\f@encoding\f@family.fd}}%