| 1 |
%% |
| 2 |
%% This is file `fontspec-xetex.sty', |
| 3 |
%% generated with the docstrip utility. |
| 4 |
%% |
| 5 |
%% The original source files were: |
| 6 |
%% |
| 7 |
%% fontspec.dtx (with options: `fontspec,XE') |
| 8 |
%% fontspec-code-load.dtx (with options: `fontspec,XE') |
| 9 |
%% fontspec-code-vars.dtx (with options: `fontspec,XE') |
| 10 |
%% fontspec-code-msg.dtx (with options: `fontspec,XE') |
| 11 |
%% fontspec-code-opening.dtx (with options: `fontspec,XE') |
| 12 |
%% fontspec-code-fontload.dtx (with options: `fontspec,XE') |
| 13 |
%% fontspec-code-interfaces.dtx (with options: `fontspec,XE') |
| 14 |
%% fontspec-code-user.dtx (with options: `fontspec,XE') |
| 15 |
%% fontspec-code-api.dtx (with options: `fontspec,XE') |
| 16 |
%% fontspec-code-internal.dtx (with options: `fontspec,XE') |
| 17 |
%% fontspec-code-opentype.dtx (with options: `fontspec,XE') |
| 18 |
%% fontspec-code-graphite.dtx (with options: `fontspec,XE') |
| 19 |
%% fontspec-code-keyval.dtx (with options: `fontspec,XE') |
| 20 |
%% fontspec-code-feat-opentype.dtx (with options: `fontspec,XE') |
| 21 |
%% fontspec-code-scripts.dtx (with options: `fontspec,XE') |
| 22 |
%% fontspec-code-lang.dtx (with options: `fontspec,XE') |
| 23 |
%% fontspec-code-feat-aat.dtx (with options: `fontspec,XE') |
| 24 |
%% fontspec-code-enc.dtx (with options: `fontspec,XE') |
| 25 |
%% fontspec-code-math.dtx (with options: `fontspec,XE') |
| 26 |
%% fontspec-code-closing.dtx (with options: `fontspec,XE') |
| 27 |
%% fontspec-code-xfss.dtx (with options: `fontspec,XE') |
| 28 |
%% ------------------------------------------------ |
| 29 |
%% The FONTSPEC package <latex3.github.io/fontspec> |
| 30 |
%% ------------------------------------------------ |
| 31 |
%% Copyright 2022-2025 The LaTeX project, LPPL "maintainer" |
| 32 |
%% Copyright 2004-2022 Will Robertson |
| 33 |
%% Copyright 2009-2013 Khaled Hosny |
| 34 |
%% ------------------------------------------------ |
| 35 |
%% This package is free software and may be redistributed and/or modified under |
| 36 |
%% the conditions of the LaTeX Project Public License, version 1.3c or higher |
| 37 |
%% (your choice): <http://www.latex-project.org/lppl/>. |
| 38 |
%% ------------------------------------------------ |
| 39 |
%%^^A%% fontspec.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 40 |
%%^^A%% Metadata for the package, including files and versioning |
| 41 |
|
| 42 |
\RequirePackage{xparse} |
| 43 |
\ProvidesExplPackage{fontspec-xetex}% |
| 44 |
{2025/09/29}{2.9g}{Font selection for XeLaTeX and LuaLaTeX} |
| 45 |
|
| 46 |
%%^^A%% fontspec-code-load.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 47 |
%%^^A%% fontspec-code-vars.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 48 |
\bool_new:N \l__fontspec_firsttime_bool |
| 49 |
\bool_new:N \l__fontspec_never_check_bool |
| 50 |
\bool_new:N \l__fontspec_nobf_bool |
| 51 |
\bool_new:N \l__fontspec_noit_bool |
| 52 |
\bool_new:N \l__fontspec_nosc_bool |
| 53 |
\bool_new:N \l__fontspec_check_bool |
| 54 |
\bool_new:N \l__fontspec_tfm_bool |
| 55 |
\bool_new:N \l__fontspec_atsui_bool |
| 56 |
\bool_new:N \l__fontspec_ot_bool |
| 57 |
\bool_new:N \l__fontspec_mm_bool |
| 58 |
\bool_new:N \l__fontspec_harfbuzz_bool |
| 59 |
\bool_new:N \l__fontspec_graphite_bool |
| 60 |
\bool_new:N \l__fontspec_fontcfg_bool |
| 61 |
\bool_set_true:N \l__fontspec_fontcfg_bool |
| 62 |
\bool_new:N \g__fontspec_math_euler_bool |
| 63 |
\bool_new:N \g__fontspec_math_lucida_bool |
| 64 |
\bool_new:N \g__fontspec_pkg_euler_loaded_bool |
| 65 |
\bool_new:N \l__fontspec_tmpa_bool |
| 66 |
\bool_new:N \l__fontspec_disable_defaults_bool |
| 67 |
\bool_new:N \l__fontspec_alias_bool |
| 68 |
\bool_new:N \l__fontspec_external_bool |
| 69 |
\bool_new:N \l__fontspec_defining_encoding_bool |
| 70 |
\bool_new:N \l__fontspec_scriptlang_exist_bool |
| 71 |
\bool_new:N \g__fontspec_em_normalise_slant_bool |
| 72 |
\bool_new:N \l__fontspec_external_kpse_bool |
| 73 |
\int_new:N \l__fontspec_script_int |
| 74 |
\int_new:N \l__fontspec_language_int |
| 75 |
\int_new:N \l__fontspec_strnum_int |
| 76 |
\int_new:N \l__fontspec_tmp_int |
| 77 |
\int_new:N \l__fontspec_tmpa_int |
| 78 |
\int_new:N \l__fontspec_tmpb_int |
| 79 |
\int_new:N \l__fontspec_tmpc_int |
| 80 |
\int_new:N \l__fontspec_em_int |
| 81 |
\int_new:N \l__fontspec_emdef_int |
| 82 |
\int_new:N \l__fontspec_strong_int |
| 83 |
\int_new:N \l__fontspec_strongdef_int |
| 84 |
\fp_new:N \l__fontspec_tmpa_fp |
| 85 |
\fp_new:N \l__fontspec_tmpb_fp |
| 86 |
\dim_new:N \l__fontspec_tmpa_dim |
| 87 |
\dim_new:N \l__fontspec_tmpb_dim |
| 88 |
\dim_new:N \l__fontspec_tmpc_dim |
| 89 |
\seq_new:N \l__fontspec_bf_series_seq |
| 90 |
\clist_new:N \g__fontspec_default_fontopts_clist |
| 91 |
\clist_new:N \g__fontspec_all_keyval_modules_clist |
| 92 |
\clist_new:N \l__fontspec_sizefeat_clist |
| 93 |
\clist_set:Nn \l__fontspec_sizefeat_clist {Size={-}} |
| 94 |
\clist_new:N \l__fontspec_extensions_clist |
| 95 |
\clist_new:N \l__fontspec_fontopts_clist |
| 96 |
\clist_new:N \l__fontspec_family_fontopts_clist |
| 97 |
\clist_new:N \l__fontspec_all_features_clist |
| 98 |
\clist_new:N \l__fontspec_leftover_clist |
| 99 |
\clist_new:N \l__fontspec_keys_leftover_clist |
| 100 |
\clist_new:N \l__fontspec_sizing_leftover_clist |
| 101 |
\clist_new:N \l__fontspec_fontfeat_clist |
| 102 |
\clist_new:N \l__fontspec_fontfeat_curr_clist |
| 103 |
\clist_new:N \l__fontspec_arg_clist |
| 104 |
\clist_new:N \l__fontspec_this_feat_clist |
| 105 |
\clist_new:N \l__fontspec_fontfeat_up_clist |
| 106 |
\clist_new:N \l__fontspec_fontfeat_bf_clist |
| 107 |
\clist_new:N \l__fontspec_fontfeat_it_clist |
| 108 |
\clist_new:N \l__fontspec_fontfeat_bfit_clist |
| 109 |
\clist_new:N \l__fontspec_fontfeat_sl_clist |
| 110 |
\clist_new:N \l__fontspec_fontfeat_bfsl_clist |
| 111 |
\clist_new:N \l__fontspec_fontfeat_sw_clist |
| 112 |
\clist_new:N \l__fontspec_fontfeat_bfsw_clist |
| 113 |
\clist_new:N \l__fontspec_fontfeat_sc_clist |
| 114 |
\prop_new:N \g__fontspec_fontopts_prop |
| 115 |
\prop_new:N \l__fontspec_nfss_prop |
| 116 |
\prop_new:N \l__fontspec_nfssfont_prop |
| 117 |
\prop_new:N \g__fontspec_OT_features_prop |
| 118 |
\prop_new:N \g__fontspec_all_opentype_feature_names_prop |
| 119 |
\prop_new:N \g__fontspec_em_prop |
| 120 |
\prop_new:N \g__fontspec_strong_prop |
| 121 |
\prop_new:N \g__fontspec_fontid_family_prop |
| 122 |
\prop_new:N \g__fontspec_family_int_prop |
| 123 |
\prop_new:N \g__fontspec_rawvariations_prop |
| 124 |
\tl_new:N \l_fontspec_family_tl |
| 125 |
\tl_new:N \g_fontspec_encoding_tl |
| 126 |
\tl_new:N \l_fontspec_fontname_tl |
| 127 |
\tl_clear_new:N \UTFencname |
| 128 |
\tl_clear_new:N \cyrillicencoding |
| 129 |
\tl_clear_new:N \latinencoding |
| 130 |
\tl_new:N \l__fontspec_renderer_tl |
| 131 |
\tl_new:N \l__fontspec_mode_tl |
| 132 |
\tl_new:N \l__fontspec_shaper_tl |
| 133 |
\tl_new:N \g__fontspec_defined_shapes_tl |
| 134 |
\tl_new:N \g__fontspec_single_feat_tl |
| 135 |
\tl_new:N \l__fontspec_basename_tl |
| 136 |
\tl_new:N \g__fontspec_curr_series_tl |
| 137 |
\tl_new:N \l__fontspec_curr_fontname_tl |
| 138 |
\tl_new:N \l__fontspec_curr_bfname_tl |
| 139 |
\tl_new:N \l__fontspec_ext_filename_tl |
| 140 |
\tl_new:N \l__fontspec_extension_tl |
| 141 |
\tl_new:N \l__fontspec_font_path_tl |
| 142 |
\tl_new:N \l__fontspec_fontid_tl |
| 143 |
\tl_new:N \l__fontspec_fontname_tl |
| 144 |
\tl_new:N \l__fontspec_options_tl |
| 145 |
\tl_new:N \l__fontspec_saved_fontname_tl |
| 146 |
\tl_new:N \l__fontspec_prev_unicode_name_tl |
| 147 |
\tl_new:N \g__fontspec_nfss_enc_tl |
| 148 |
\tl_new:N \g__fontspec_nfss_family_tl |
| 149 |
\tl_new:N \l__fontspec_nfss_sc_tl |
| 150 |
\tl_new:N \l__fontspec_nfss_tl |
| 151 |
\tl_new:N \l__fontspec_nfss_fam_tl |
| 152 |
\tl_new:N \l__fontspec_size_tl |
| 153 |
\tl_new:N \l__fontspec_sizedfont_tl |
| 154 |
\tl_new:N \l__fontspec_this_font_tl |
| 155 |
\tl_new:N \l__fontspec_ttc_index_tl |
| 156 |
\tl_new:N \l__fontspec_smcp_shape_tl |
| 157 |
\tl_new:N \l__fontspec_emshape_query_tl |
| 158 |
\tl_new:N \l__fontspec_em_switch_tl |
| 159 |
\tl_new:N \l__fontspec_strong_switch_tl |
| 160 |
\tl_new:N \l__fontspec_tmp_tl |
| 161 |
\tl_new:N \l__fontspec_tmpa_tl |
| 162 |
\tl_new:N \l__fontspec_tmpb_tl |
| 163 |
\tl_new:N \l__fontspec_em_tmp_tl |
| 164 |
\tl_new:N \l__fontspec_strong_tmp_tl |
| 165 |
\tl_new:N \g__fontspec_mathrm_tl |
| 166 |
\tl_new:N \g__fontspec_bfmathrm_tl |
| 167 |
\tl_new:N \g__fontspec_mathsf_tl |
| 168 |
\tl_new:N \g__fontspec_mathtt_tl |
| 169 |
\tl_gset:Nn \g__fontspec_mathrm_tl {\rmdefault} |
| 170 |
\tl_gset:Nn \g__fontspec_mathsf_tl {\sfdefault} |
| 171 |
\tl_gset:Nn \g__fontspec_mathtt_tl {\ttdefault} |
| 172 |
\tl_new:N \l__fontspec_family_label_tl |
| 173 |
\tl_new:N \l__fontspec_fake_slant_tl |
| 174 |
\tl_new:N \l__fontspec_fake_embolden_tl |
| 175 |
\tl_new:N \l__fontspec_fontname_up_tl |
| 176 |
\tl_new:N \l__fontspec_fontname_bf_tl |
| 177 |
\tl_new:N \l__fontspec_fontname_it_tl |
| 178 |
\tl_new:N \l__fontspec_fontname_bfit_tl |
| 179 |
\tl_new:N \l__fontspec_fontname_sl_tl |
| 180 |
\tl_new:N \l__fontspec_fontname_bfsl_tl |
| 181 |
\tl_new:N \l__fontspec_fontname_sw_tl |
| 182 |
\tl_new:N \l__fontspec_fontname_bfsw_tl |
| 183 |
\tl_new:N \l__fontspec_fontname_sc_tl |
| 184 |
\tl_new:N \l__fontspec_script_tl |
| 185 |
\tl_new:N \l__fontspec_script_name_tl |
| 186 |
\tl_set:Nn \l__fontspec_script_name_tl {CustomDefault} |
| 187 |
\tl_new:N \l__fontspec_lang_tl |
| 188 |
\tl_new:N \l__fontspec_lang_name_tl |
| 189 |
\tl_set:Nn \l__fontspec_lang_name_tl {Default} |
| 190 |
\tl_new:N \l__fontspec_scale_tl |
| 191 |
\tl_new:N \l__fontspec_hyphenchar_tl |
| 192 |
\tl_new:N \l__fontspec_hexcol_tl |
| 193 |
\tl_new:N \l__fontspec_opacity_tl |
| 194 |
\tl_new:N \l__fontspec_optical_size_tl |
| 195 |
\tl_new:N \l__fontspec_mapping_tl |
| 196 |
\tl_new:N \l__fontspec_punctspace_adjust_tl |
| 197 |
\tl_new:N \l__fontspec_wordspace_adjust_tl |
| 198 |
\tl_new:N \l__fontspec_postadjust_tl |
| 199 |
\tl_new:N \g__fontspec_instance_tl |
| 200 |
\tl_const:Nn \c__fontspec_hexcol_tl {000000} |
| 201 |
\tl_const:Nn \c__fontspec_opacity_tl {FF~} |
| 202 |
\tl_const:Nn \c__fontspec_postadjust_tl { \l__fontspec_wordspace_adjust_tl \l__fontspec_punctspace_adjust_tl } |
| 203 |
\tl_new:N \g__fontspec_rawfeatures_sclist |
| 204 |
\tl_new:N \l__fontspec_pre_feat_sclist |
| 205 |
\tl_new:N \l__fontspec_rmfamily_family_tl |
| 206 |
\tl_new:N \l__fontspec_sffamily_family_tl |
| 207 |
\tl_new:N \l__fontspec_ttfamily_family_tl |
| 208 |
\tl_new:N \l__fontspec_rmfamily_encoding_tl |
| 209 |
\tl_new:N \l__fontspec_sffamily_encoding_tl |
| 210 |
\tl_new:N \l__fontspec_ttfamily_encoding_tl |
| 211 |
|
| 212 |
%%^^A%% fontspec-code-msg.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 213 |
\cs_new:Npn \__fontspec_error:n { \msg_error:nn {fontspec} } |
| 214 |
\cs_new:Npn \__fontspec_error:nn { \msg_error:nnn {fontspec} } |
| 215 |
\cs_new:Npn \__fontspec_error:nx { \msg_error:nnx {fontspec} } |
| 216 |
\cs_new:Npn \__fontspec_error:nxx { \msg_error:nnxx {fontspec} } |
| 217 |
\cs_new:Npn \__fontspec_warning:n { \msg_warning:nn {fontspec} } |
| 218 |
\cs_new:Npn \__fontspec_warning:nx { \msg_warning:nnx {fontspec} } |
| 219 |
\cs_new:Npn \__fontspec_warning:nxx { \msg_warning:nnxx {fontspec} } |
| 220 |
\cs_new:Npn \__fontspec_info:n { \msg_info:nn {fontspec} } |
| 221 |
\cs_new:Npn \__fontspec_info:nx { \msg_info:nnx {fontspec} } |
| 222 |
\cs_new:Npn \__fontspec_info:nxx { \msg_info:nnxx {fontspec} } |
| 223 |
\cs_new:Npn \__fontspec_trace:n { \msg_trace:nn {fontspec} } |
| 224 |
\cs_new:Nn \__fontspec_msg_new:nn |
| 225 |
{ |
| 226 |
\msg_new:nnx {fontspec} {#1} { ^^J \tl_trim_spaces:n {#2} } |
| 227 |
} |
| 228 |
\cs_new:Nn \__fontspec_msg_new:nnn |
| 229 |
{ |
| 230 |
\msg_new:nnxx {fontspec} {#1} { ^^J \tl_trim_spaces:n {#2} } |
| 231 |
{ \tl_trim_spaces:n {#3} } |
| 232 |
} |
| 233 |
\char_set_catcode_space:n {32} |
| 234 |
\__fontspec_msg_new:nn {only-inside-encdef} |
| 235 |
{ |
| 236 |
\exp_not:N #1 can only be used in the second argument |
| 237 |
to \string\DeclareUnicodeEncoding. |
| 238 |
} |
| 239 |
\__fontspec_msg_new:nn {no-size-info} |
| 240 |
{ |
| 241 |
Size information must be supplied.\\ |
| 242 |
For example, SizeFeatures={Size={8-12},...}. |
| 243 |
} |
| 244 |
\__fontspec_msg_new:nnn {font-not-found} |
| 245 |
{ |
| 246 |
The font "#1" cannot be found; this may be but usually is not |
| 247 |
a fontspec bug. Either there is a typo in the font name/file, |
| 248 |
the font is not installed (correctly), or there is a bug |
| 249 |
in the underlying font loading engine (XeTeX/luaotfload). |
| 250 |
} |
| 251 |
{ |
| 252 |
A font might not be found for many reasons.\\ |
| 253 |
Check the spelling, where the font is installed etc. etc.\\\\ |
| 254 |
When in doubt, ask someone for help! |
| 255 |
} |
| 256 |
\__fontspec_msg_new:nnn {rename-feature-not-exist} |
| 257 |
{ |
| 258 |
The feature #1 doesn't appear to be defined. |
| 259 |
} |
| 260 |
{ |
| 261 |
It looks like you're trying to rename a feature that doesn't exist. |
| 262 |
} |
| 263 |
\__fontspec_msg_new:nn {no-glyph} |
| 264 |
{ |
| 265 |
'#1' does not contain glyph #2. |
| 266 |
} |
| 267 |
\__fontspec_msg_new:nnn {euler-too-late} |
| 268 |
{ |
| 269 |
The euler package must be loaded BEFORE fontspec. |
| 270 |
} |
| 271 |
{ |
| 272 |
fontspec only overwrites euler's attempt to |
| 273 |
define the maths text fonts if fontspec is |
| 274 |
loaded after euler. Type <return> to proceed |
| 275 |
with incorrect \string\mathit, \string\mathbf, etc. |
| 276 |
} |
| 277 |
\__fontspec_msg_new:nnn {no-xcolor} |
| 278 |
{ |
| 279 |
Cannot load named colours without the xcolor package. |
| 280 |
} |
| 281 |
{ |
| 282 |
Sorry, I can't do anything to help. Instead of loading |
| 283 |
the color package, use xcolor instead. |
| 284 |
} |
| 285 |
\__fontspec_msg_new:nnn {unknown-color-model} |
| 286 |
{ |
| 287 |
Error loading colour `#1'; unknown colour model. |
| 288 |
} |
| 289 |
{ |
| 290 |
Sorry, I can't do anything to help. Please report this error |
| 291 |
to my developer with a minimal example that causes the problem. |
| 292 |
} |
| 293 |
\__fontspec_msg_new:nnn {not-in-addfontfeatures} |
| 294 |
{ |
| 295 |
The "#1" font feature cannot be used in \string\addfontfeatures. |
| 296 |
} |
| 297 |
{ |
| 298 |
This is due to how TeX loads fonts; such settings |
| 299 |
are global so adding them mid-document within a group causes |
| 300 |
confusion. You'll need to define multiple font families to achieve |
| 301 |
what you want. |
| 302 |
} |
| 303 |
\__fontspec_msg_new:nn {tu-clash} |
| 304 |
{ |
| 305 |
I have found the tuenc.def encoding definition file but the TU encoding is not |
| 306 |
defined by the LaTeX2e kernel; attempting to correct but you really should update |
| 307 |
to the latest version of LaTeX2e. |
| 308 |
} |
| 309 |
\__fontspec_msg_new:nn {tu-missing} |
| 310 |
{ |
| 311 |
The TU encoding seems to be missing; please update to the latest version of LaTeX2e. |
| 312 |
} |
| 313 |
\__fontspec_msg_new:nn {addfontfeatures-ignored} |
| 314 |
{ |
| 315 |
\string\addfontfeature (s) ignored \msg_line_context:; |
| 316 |
it cannot be used with a font that wasn't selected by a fontspec command.\\ |
| 317 |
\\ |
| 318 |
The current font is "\use:c{font@name}".\\ |
| 319 |
\int_compare:nTF { \clist_count:n {#1} = 1 } |
| 320 |
{ The requested feature is "#1". } |
| 321 |
{ The requested features are "#1". } |
| 322 |
} |
| 323 |
\__fontspec_msg_new:nn {feature-option-overwrite} |
| 324 |
{ |
| 325 |
Option '#2' of font feature '#1' overwritten. |
| 326 |
} |
| 327 |
\__fontspec_msg_new:nn {ot-tag-too-long} |
| 328 |
{ |
| 329 |
OpenType tag '#1' is too long; script, language, and feature tags must be four characters or fewer. |
| 330 |
} |
| 331 |
\__fontspec_msg_new:nn {aat-feature-not-exist} |
| 332 |
{ |
| 333 |
'\l_keys_key_tl=\l_keys_value_tl' feature not supported |
| 334 |
for AAT font '\l_fontspec_fontname_tl'. |
| 335 |
} |
| 336 |
\__fontspec_msg_new:nn {aat-feature-not-exist-in-font} |
| 337 |
{ |
| 338 |
AAT feature '\l_keys_key_tl=\l_keys_value_tl' (#1) not available |
| 339 |
in font '\l_fontspec_fontname_tl'. |
| 340 |
} |
| 341 |
\__fontspec_msg_new:nn {no-opticals} |
| 342 |
{ |
| 343 |
'#1' doesn't appear to have an Optical Size axis. |
| 344 |
} |
| 345 |
\__fontspec_msg_new:nn {script-not-exist} |
| 346 |
{ |
| 347 |
Script '#2' not explicitly supported within font '#1'. |
| 348 |
Check the typeset output, and if it is okay then ignore this warning. |
| 349 |
Otherwise a different font should be chosen. |
| 350 |
} |
| 351 |
\__fontspec_msg_new:nn {language-not-exist} |
| 352 |
{ |
| 353 |
Language '#1' not explicitly supported |
| 354 |
within font '\l_fontspec_fontname_tl' |
| 355 |
with script '\l__fontspec_script_name_tl'. |
| 356 |
Check the typeset output, and if it is okay then ignore this warning. |
| 357 |
Otherwise a different font should be chosen. |
| 358 |
} |
| 359 |
\__fontspec_msg_new:nn {only-xetex-feature} |
| 360 |
{ |
| 361 |
Ignored XeTeX-only feature: '#1'. |
| 362 |
} |
| 363 |
\__fontspec_msg_new:nn {only-luatex-feature} |
| 364 |
{ |
| 365 |
Ignored LuaTeX-only feature: '#1'. |
| 366 |
} |
| 367 |
\__fontspec_msg_new:nn {unknown-renderer} |
| 368 |
{ |
| 369 |
Renderer '#1' unknown. Assuming Harfbuzz with 'shaper=#1'. |
| 370 |
Please raise a fontspec issue to add this shaper to the interface. |
| 371 |
} |
| 372 |
\__fontspec_msg_new:nn {no-mapping} |
| 373 |
{ |
| 374 |
Input mapping not supported in LuaTeX. |
| 375 |
} |
| 376 |
\__fontspec_msg_new:nn {no-mapping-ligtex} |
| 377 |
{ |
| 378 |
Input mapping not supported in LuaTeX.\\ |
| 379 |
Use "Ligatures=TeX" instead of "Mapping=tex-text". |
| 380 |
} |
| 381 |
\__fontspec_msg_new:nn {font-index-needs-ttc} |
| 382 |
{ |
| 383 |
The "FontIndex" feature is only supported by TTC (TrueType Collection) fonts.\\ |
| 384 |
Feature ignored. |
| 385 |
} |
| 386 |
\__fontspec_msg_new:nn {feat-cannot-remove} |
| 387 |
{ |
| 388 |
The "#1" feature cannot be deactivated. Request ignored. |
| 389 |
} |
| 390 |
\__fontspec_msg_new:nn {defining-font} |
| 391 |
{ |
| 392 |
Font family '\g__fontspec_nfss_family_tl' created for font '#2' |
| 393 |
with options [\l__fontspec_all_features_clist].\\ |
| 394 |
\\ |
| 395 |
This font family consists of the following NFSS series/shapes:\\ |
| 396 |
\g__fontspec_defined_shapes_tl |
| 397 |
} |
| 398 |
\__fontspec_msg_new:nn {no-font-shape} |
| 399 |
{ |
| 400 |
Could not resolve font "#1" (it probably doesn't exist). |
| 401 |
} |
| 402 |
\__fontspec_msg_new:nn {set-scale} |
| 403 |
{ |
| 404 |
\l_fontspec_fontname_tl\space scale = \l__fontspec_scale_tl. |
| 405 |
} |
| 406 |
\__fontspec_msg_new:nn {setup-math} |
| 407 |
{ |
| 408 |
Adjusting the maths setup (use [no-math] to avoid this). |
| 409 |
} |
| 410 |
\__fontspec_msg_new:nn {opa-twice} |
| 411 |
{ |
| 412 |
Opacity set twice, in both Colour and Opacity.\\ |
| 413 |
Using specification "Opacity=#1". |
| 414 |
} |
| 415 |
\__fontspec_msg_new:nn {opa-twice-col} |
| 416 |
{ |
| 417 |
Opacity set twice, in both Opacity and Colour.\\ |
| 418 |
Using an opacity specification in hex of "#1/FF". |
| 419 |
} |
| 420 |
\__fontspec_msg_new:nn {bad-colour} |
| 421 |
{ |
| 422 |
Bad colour declaration "#1". |
| 423 |
Colour must be one of:\\ |
| 424 |
* a named xcolor colour\\ |
| 425 |
* a six-digit hex colour RRGGBB\\ |
| 426 |
* an eight-digit hex colour RRGGBBTT with opacity |
| 427 |
} |
| 428 |
\char_set_catcode_ignore:n {32} |
| 429 |
|
| 430 |
%%^^A%% fontspec-code-opening.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 431 |
\cs_if_exist:cF {T@TU} |
| 432 |
{ |
| 433 |
\__fontspec_warning:n {tu-clash} |
| 434 |
\DeclareFontEncoding{TU}{}{} |
| 435 |
\DeclareFontSubstitution{TU}{lmr}{m}{n} |
| 436 |
} |
| 437 |
\tl_gset:Nn \g_fontspec_encoding_tl { TU } |
| 438 |
\tl_set:Nn \rmdefault {lmr} |
| 439 |
\tl_set:Nn \sfdefault {lmss} |
| 440 |
\tl_set:Nn \ttdefault {lmtt} |
| 441 |
\RequirePackage[\g_fontspec_encoding_tl]{fontenc} |
| 442 |
\tl_set_eq:NN \UTFencname \g_fontspec_encoding_tl % for xunicode if needed |
| 443 |
\tl_if_in:NnT \@filelist {.cls} { \normalsize } |
| 444 |
\tl_set_eq:NN \cyrillicencoding \g_fontspec_encoding_tl |
| 445 |
\tl_set_eq:NN \latinencoding \g_fontspec_encoding_tl |
| 446 |
\AtBeginDocument |
| 447 |
{ |
| 448 |
\tl_set_eq:NN \cyrillicencoding \g_fontspec_encoding_tl |
| 449 |
\tl_set_eq:NN \latinencoding \g_fontspec_encoding_tl |
| 450 |
} |
| 451 |
\cs_new:Npn \FontspecSetCheckBoolTrue { \bool_set_true:N \l__fontspec_check_bool } |
| 452 |
\cs_new:Npn \FontspecSetCheckBoolFalse { \bool_set_false:N \l__fontspec_check_bool } |
| 453 |
\cs_new:Nn \__fontspec_keys_set_known:nnN |
| 454 |
{ |
| 455 |
\keys_set_known:nnN {#1} {#2} #3 |
| 456 |
} |
| 457 |
\cs_generate_variant:Nn \__fontspec_keys_set_known:nnN {nx} |
| 458 |
\cs_new:Nn \__fontspec_int_mult_truncate:Nn |
| 459 |
{ |
| 460 |
\int_set:Nn #1 { \__dim_eval:w #2 #1 \__dim_eval_end: } |
| 461 |
} |
| 462 |
\cs_generate_variant:Nn \int_set:Nn {Nv} |
| 463 |
\cs_generate_variant:Nn \prop_gput_if_not_in:Nnn {NeV} |
| 464 |
\cs_generate_variant:Nn \prop_gput:Nnn {Nxn} % needed by unicode-math |
| 465 |
\cs_generate_variant:Nn \tl_if_empty:nF {f} |
| 466 |
\cs_generate_variant:Nn \tl_if_eq:nnT {oe} |
| 467 |
\cs_generate_variant:Nn \msg_new:nnn {nnx} |
| 468 |
\cs_generate_variant:Nn \msg_new:nnnn {nnxx} |
| 469 |
|
| 470 |
%%^^A%% fontspec-code-fontload.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 471 |
|
| 472 |
\cs_set:Npn \__fontspec_primitive_font_set:Nnn #1#2#3 |
| 473 |
{ |
| 474 |
\font #1 = #2 ~at~ \dim_eval:n {#3} \scan_stop: |
| 475 |
} |
| 476 |
\cs_set:Npn \__fontspec_primitive_font_gset:Nnn #1#2#3 |
| 477 |
{ |
| 478 |
\global \font #1 = #2 ~at~ \dim_eval:n {#3} \scan_stop: |
| 479 |
} |
| 480 |
\cs_set:Npn \__fontspec_font_suppress_not_found_error: |
| 481 |
{ |
| 482 |
\int_set:Nn \suppressfontnotfounderror {1} |
| 483 |
} |
| 484 |
\prg_new_conditional:Nnn \__fontspec_primitive_font_if_null:N {p,TF,T,F} |
| 485 |
{ |
| 486 |
\ifx #1 \nullfont |
| 487 |
\prg_return_true: |
| 488 |
\else |
| 489 |
\prg_return_false: |
| 490 |
\fi |
| 491 |
} |
| 492 |
\prg_new_conditional:Nnn \__fontspec_primitive_font_set:Nnn {TF,T,F} |
| 493 |
{ |
| 494 |
\__fontspec_primitive_font_set:Nnn #1 {#2} {#3} |
| 495 |
\__fontspec_primitive_font_if_null:NTF #1 {\prg_return_false:} {\prg_return_true:} |
| 496 |
} |
| 497 |
\prg_new_conditional:Nnn \__fontspec_primitive_font_gset:Nnn {TF,T,F} |
| 498 |
{ |
| 499 |
\__fontspec_primitive_font_gset:Nnn #1 {#2} {#3} |
| 500 |
\__fontspec_primitive_font_if_null:NTF #1 {\prg_return_false:} {\prg_return_true:} |
| 501 |
} |
| 502 |
\cs_set:Npn \__fontspec_primitive_font_set:Onn { \exp_last_unbraced:No \__fontspec_primitive_font_set:Nnn } |
| 503 |
\cs_set:Npn \__fontspec_primitive_font_set:OnnF { \exp_last_unbraced:No \__fontspec_primitive_font_set:NnnF } |
| 504 |
\cs_set:Npn \__fontspec_primitive_font_gset:Onn { \exp_last_unbraced:No \__fontspec_primitive_font_gset:Nnn } |
| 505 |
\cs_set:Npn \__fontspec_primitive_font_gset:OnnF { \exp_last_unbraced:No \__fontspec_primitive_font_gset:NnnF } |
| 506 |
\prg_new_conditional:Nnn \__fontspec_primitive_font_if_exist:n {TF,T,F} |
| 507 |
{ |
| 508 |
\group_begin: |
| 509 |
\__fontspec_font_suppress_not_found_error: |
| 510 |
\__fontspec_primitive_font_set:Nnn \l__fontspec_primitive_font {#1} { \f@size pt - 1sp } |
| 511 |
\__fontspec_primitive_font_if_null:NTF \l__fontspec_primitive_font |
| 512 |
{ \group_end: \prg_return_false: } |
| 513 |
{ \group_end: \prg_return_true: } |
| 514 |
} |
| 515 |
\prg_new_conditional:Nnn \__fontspec_primitive_font_glyph_if_exist:Nn {p,TF,T,F} |
| 516 |
{ |
| 517 |
\tex_iffontchar:D #1 \int_eval:n {#2} \scan_stop: |
| 518 |
\prg_return_true: |
| 519 |
\else: |
| 520 |
\prg_return_false: |
| 521 |
\fi: |
| 522 |
} |
| 523 |
\cs_new:Nn \__fontspec_primitive_font_set_hyphenchar:Nn |
| 524 |
{ |
| 525 |
\tex_hyphenchar:D #1 = \int_eval:n {#2} \scan_stop: |
| 526 |
} |
| 527 |
\cs_new_eq:NN \__fontspec_primitive_font_get_name:N \fontname |
| 528 |
\cs_new:Npn \__fontspec_primitive_font_current_name: |
| 529 |
{ |
| 530 |
\__fontspec_primitive_font_get_name:N \tex_font:D |
| 531 |
} |
| 532 |
|
| 533 |
%%^^A%% fontspec-code-interfaces.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 534 |
|
| 535 |
\NewDocumentCommand \fontspec { O{} m O{} } |
| 536 |
{ |
| 537 |
\__fontspec_main_fontspec:nn {#1,#3} {#2} |
| 538 |
\ignorespaces |
| 539 |
} |
| 540 |
\NewDocumentCommand \setmainfont { O{} m O{} } |
| 541 |
{ |
| 542 |
\__fontspec_main_setmainfont:nn {#1,#3} {#2} |
| 543 |
\ignorespaces |
| 544 |
} |
| 545 |
\NewDocumentCommand \setsansfont { O{} m O{} } |
| 546 |
{ |
| 547 |
\__fontspec_main_setsansfont:nn {#1,#3} {#2} |
| 548 |
\ignorespaces |
| 549 |
} |
| 550 |
\NewDocumentCommand \setmonofont { O{} m O{} } |
| 551 |
{ |
| 552 |
\__fontspec_main_setmonofont:nn {#1,#3} {#2} |
| 553 |
\ignorespaces |
| 554 |
} |
| 555 |
\NewDocumentCommand \setmathrm { O{} m O{} } |
| 556 |
{ |
| 557 |
\__fontspec_main_setmathrm:nn {#1,#3} {#2} |
| 558 |
} |
| 559 |
\NewDocumentCommand \setboldmathrm { O{} m O{} } |
| 560 |
{ |
| 561 |
\__fontspec_main_setboldmathrm:nn {#1,#3} {#2} |
| 562 |
} |
| 563 |
\NewDocumentCommand \setmathsf { O{} m O{} } |
| 564 |
{ |
| 565 |
\__fontspec_main_setmathsf:nn {#1,#3} {#2} |
| 566 |
} |
| 567 |
\NewDocumentCommand \setmathtt { O{} m O{} } |
| 568 |
{ |
| 569 |
\__fontspec_main_setmathtt:nn {#1,#3} {#2} |
| 570 |
} |
| 571 |
\NewDocumentCommand \setromanfont { O{} m O{} } |
| 572 |
{ |
| 573 |
\__fontspec_main_setmainfont:nn {#1,#3} {#2} |
| 574 |
} |
| 575 |
\NewDocumentCommand \newfontfamily { m O{} m O{} } |
| 576 |
{ |
| 577 |
\__fontspec_main_newfontfamily:NnnN #1 {#2,#4} {#3} \NewDocumentCommand |
| 578 |
} |
| 579 |
\NewDocumentCommand \renewfontfamily { m O{} m O{} } |
| 580 |
{ |
| 581 |
\__fontspec_main_newfontfamily:NnnN #1 {#2,#4} {#3} \RenewDocumentCommand |
| 582 |
} |
| 583 |
\NewDocumentCommand \setfontfamily { m O{} m O{} } |
| 584 |
{ |
| 585 |
\__fontspec_main_newfontfamily:NnnN #1 {#2,#4} {#3} \DeclareDocumentCommand |
| 586 |
} |
| 587 |
\NewDocumentCommand \providefontfamily { m O{} m O{} } |
| 588 |
{ |
| 589 |
\__fontspec_main_newfontfamily:NnnN #1 {#2,#4} {#3} \ProvideDocumentCommand |
| 590 |
} |
| 591 |
\NewDocumentCommand \newfontface { m O{} m O{} } |
| 592 |
{ |
| 593 |
\__fontspec_main_newfontface:NnnN #1 {#2,#4} {#3} \NewDocumentCommand |
| 594 |
} |
| 595 |
\NewDocumentCommand \renewfontface { m O{} m O{} } |
| 596 |
{ |
| 597 |
\__fontspec_main_newfontface:NnnN #1 {#2,#4} {#3} \RenewDocumentCommand |
| 598 |
} |
| 599 |
\NewDocumentCommand \setfontface { m O{} m O{} } |
| 600 |
{ |
| 601 |
\__fontspec_main_newfontface:NnnN #1 {#2,#4} {#3} \DeclareDocumentCommand |
| 602 |
} |
| 603 |
\NewDocumentCommand \providefontface { m O{} m O{} } |
| 604 |
{ |
| 605 |
\__fontspec_main_newfontface:NnnN #1 {#2,#4} {#3} \ProvideDocumentCommand |
| 606 |
} |
| 607 |
\NewDocumentCommand \defaultfontfeatures { t+ o m } |
| 608 |
{ |
| 609 |
\IfNoValueTF {#2} |
| 610 |
{ \__fontspec_set_default_features:nn {#1} {#3} } |
| 611 |
{ \__fontspec_set_font_default_features:nnn {#1} {#2} {#3} } |
| 612 |
\ignorespaces |
| 613 |
} |
| 614 |
\NewDocumentCommand \addfontfeatures {m} |
| 615 |
{ |
| 616 |
\__fontspec_main_addfontfeatures:n {#1} |
| 617 |
} |
| 618 |
\NewDocumentCommand \addfontfeature {m} |
| 619 |
{ |
| 620 |
\__fontspec_main_addfontfeatures:n {#1} |
| 621 |
} |
| 622 |
\NewDocumentCommand \newfontfeature {mm} |
| 623 |
{ |
| 624 |
\__fontspec_main_newfontfeature:nn {#1} {#2} |
| 625 |
} |
| 626 |
\NewDocumentCommand \newAATfeature {mmmm} |
| 627 |
{ |
| 628 |
\__fontspec_main_newAATfeature:nnnn {#1} {#2} {#3} {#4} |
| 629 |
} |
| 630 |
\NewDocumentCommand \newopentypefeature {mmm} |
| 631 |
{ |
| 632 |
\__fontspec_main_newopentypefeature:nnn {#1} {#2} {#3} |
| 633 |
} |
| 634 |
\NewDocumentCommand \newICUfeature {mmm} |
| 635 |
{ |
| 636 |
\__fontspec_main_newopentypefeature:nnn {#1} {#2} {#3} |
| 637 |
} |
| 638 |
\NewDocumentCommand \aliasfontfeature {mm} |
| 639 |
{ |
| 640 |
\__fontspec_main_aliasfontfeature:nn {#1} {#2} |
| 641 |
} |
| 642 |
\NewDocumentCommand \aliasfontfeatureoption {mmm} |
| 643 |
{ |
| 644 |
\__fontspec_main_aliasfontfeatureoption:nnn {#1} {#2} {#3} |
| 645 |
} |
| 646 |
\NewDocumentCommand \newfontscript {mm} |
| 647 |
{ |
| 648 |
\fontspec_new_script:nn {#1} {#2} |
| 649 |
} |
| 650 |
\NewDocumentCommand \newfontlanguage {mm} |
| 651 |
{ |
| 652 |
\fontspec_new_lang:nn {#1} {#2} |
| 653 |
} |
| 654 |
\NewDocumentCommand \DeclareFontExtensions {m} |
| 655 |
{ |
| 656 |
\__fontspec_main_DeclareFontExtensions:n {#1} |
| 657 |
} |
| 658 |
\NewDocumentCommand \IfFontFeatureActiveTF {mmm} |
| 659 |
{ |
| 660 |
\__fontspec_main_IfFontFeatureActiveTF:nnn {#1} {#2} {#3} |
| 661 |
} |
| 662 |
\AtBeginDocument |
| 663 |
{ |
| 664 |
\RenewDocumentCommand \oldstylenums {m} |
| 665 |
{ |
| 666 |
\__fontspec_main_oldstylenums:n {#1} |
| 667 |
} |
| 668 |
} |
| 669 |
\NewDocumentCommand \liningnums {m} |
| 670 |
{ |
| 671 |
\__fontspec_main_liningnums:n {#1} |
| 672 |
} |
| 673 |
|
| 674 |
%%^^A%% fontspec-code-user.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 675 |
|
| 676 |
\cs_new:Nn \__fontspec_main_fontspec:nn |
| 677 |
{ |
| 678 |
\fontspec_set_family:Nnn \f@family {#1} {#2} |
| 679 |
\fontencoding { \g__fontspec_nfss_enc_tl } |
| 680 |
\selectfont |
| 681 |
} |
| 682 |
\tl_set:Nn \l__fontspec_rmfamily_encoding_tl { \encodingdefault } |
| 683 |
\tl_set:Nn \l__fontspec_sffamily_encoding_tl { \encodingdefault } |
| 684 |
\tl_set:Nn \l__fontspec_ttfamily_encoding_tl { \encodingdefault } |
| 685 |
\AddToHook{rmfamily}{ \fontencoding \l__fontspec_rmfamily_encoding_tl } |
| 686 |
\AddToHook{sffamily}{ \fontencoding \l__fontspec_sffamily_encoding_tl } |
| 687 |
\AddToHook{ttfamily}{ \fontencoding \l__fontspec_ttfamily_encoding_tl } |
| 688 |
\cs_new:Nn \__fontspec_main_setmainfont:nn |
| 689 |
{ |
| 690 |
\DeclareFontSeriesDefault[rm]{bf}{\bfdefault} |
| 691 |
\fontspec_set_family:Nnn \l__fontspec_rmfamily_family_tl {#1} {#2} |
| 692 |
\tl_set_eq:NN \rmdefault \l__fontspec_rmfamily_family_tl |
| 693 |
\tl_set_eq:NN \l__fontspec_rmfamily_encoding_tl \g__fontspec_nfss_enc_tl |
| 694 |
\str_if_eq:eeT {\familydefault} {\rmdefault} |
| 695 |
{ \tl_set_eq:NN \encodingdefault \g__fontspec_nfss_enc_tl } |
| 696 |
\__fontspec_setmainfont_hook:nn {#1} {#2} % for unicode-math only |
| 697 |
\normalfont |
| 698 |
} |
| 699 |
\cs_new:Nn \__fontspec_main_setsansfont:nn |
| 700 |
{ |
| 701 |
\DeclareFontSeriesDefault[sf]{bf}{\bfdefault} |
| 702 |
\fontspec_set_family:Nnn \l__fontspec_sffamily_family_tl {#1} {#2} |
| 703 |
\tl_set_eq:NN \sfdefault \l__fontspec_sffamily_family_tl |
| 704 |
\tl_set_eq:NN \l__fontspec_sffamily_encoding_tl \g__fontspec_nfss_enc_tl |
| 705 |
\str_if_eq:eeT {\familydefault} {\sfdefault} |
| 706 |
{ \tl_set_eq:NN \encodingdefault \g__fontspec_nfss_enc_tl } |
| 707 |
\__fontspec_setsansfont_hook:nn {#1} {#2} % for unicode-math only |
| 708 |
\normalfont |
| 709 |
} |
| 710 |
\cs_new:Nn \__fontspec_main_setmonofont:nn |
| 711 |
{ |
| 712 |
\DeclareFontSeriesDefault[tt]{bf}{\bfdefault} |
| 713 |
\fontspec_set_family:Nnn \l__fontspec_ttfamily_family_tl {#1} {#2} |
| 714 |
\tl_set_eq:NN \ttdefault \l__fontspec_ttfamily_family_tl |
| 715 |
\tl_set_eq:NN \l__fontspec_ttfamily_encoding_tl \g__fontspec_nfss_enc_tl |
| 716 |
\str_if_eq:eeT {\familydefault} {\ttdefault} |
| 717 |
{ \tl_set_eq:NN \encodingdefault \g__fontspec_nfss_enc_tl } |
| 718 |
\__fontspec_setmonofont_hook:nn {#1} {#2} % for unicode-math only |
| 719 |
\normalfont |
| 720 |
} |
| 721 |
\cs_new:Nn \__fontspec_main_setmathrm:nn |
| 722 |
{ |
| 723 |
\fontspec_gset_family:Nnn \g__fontspec_mathrm_tl {#1} {#2} |
| 724 |
\__fontspec_setmathrm_hook:nn {#1} {#2} % for unicode-math only |
| 725 |
} |
| 726 |
\cs_new:Nn \__fontspec_main_setboldmathrm:nn |
| 727 |
{ |
| 728 |
\fontspec_gset_family:Nnn \g__fontspec_bfmathrm_tl {#1} {#2} |
| 729 |
\__fontspec_setboldmathrm_hook:nn {#1} {#2} % for unicode-math only |
| 730 |
} |
| 731 |
\cs_new:Nn \__fontspec_main_setmathsf:nn |
| 732 |
{ |
| 733 |
\fontspec_gset_family:Nnn \g__fontspec_mathsf_tl {#1} {#2} |
| 734 |
\__fontspec_setmathsf_hook:nn {#1} {#2} % for unicode-math only |
| 735 |
} |
| 736 |
\cs_new:Nn \__fontspec_main_setmathtt:nn |
| 737 |
{ |
| 738 |
\fontspec_gset_family:Nnn \g__fontspec_mathtt_tl {#1} {#2} |
| 739 |
\__fontspec_setmathtt_hook:nn {#1} {#2} % for unicode-math only |
| 740 |
} |
| 741 |
\cs_set_eq:NN \__fontspec_setmainfont_hook:nn \use_none:nn |
| 742 |
\cs_set_eq:NN \__fontspec_setsansfont_hook:nn \use_none:nn |
| 743 |
\cs_set_eq:NN \__fontspec_setmonofont_hook:nn \use_none:nn |
| 744 |
\cs_set_eq:NN \__fontspec_setmathrm_hook:nn \use_none:nn |
| 745 |
\cs_set_eq:NN \__fontspec_setmathsf_hook:nn \use_none:nn |
| 746 |
\cs_set_eq:NN \__fontspec_setmathtt_hook:nn \use_none:nn |
| 747 |
\cs_set_eq:NN \__fontspec_setboldmathrm_hook:nn \use_none:nn |
| 748 |
\@onlypreamble\setmathrm |
| 749 |
\@onlypreamble\setboldmathrm |
| 750 |
\@onlypreamble\setmathsf |
| 751 |
\@onlypreamble\setmathtt |
| 752 |
\tl_gset:Nn \g__fontspec_mathrm_tl {\rmdefault} |
| 753 |
\tl_gset:Nn \g__fontspec_mathsf_tl {\sfdefault} |
| 754 |
\tl_gset:Nn \g__fontspec_mathtt_tl {\ttdefault} |
| 755 |
\cs_new:Nn \__fontspec_main_newfontfamily:NnnN |
| 756 |
{ |
| 757 |
\fontspec_set_family:cnn { l__fontspec_ \cs_to_str:N #1 _family_tl } {#2} {#3} |
| 758 |
\use:x |
| 759 |
{ |
| 760 |
\exp_not:N #4 \exp_not:N #1 {} |
| 761 |
{ |
| 762 |
\exp_not:N \fontfamily { \use:c { l__fontspec_ \cs_to_str:N #1 _family_tl } } |
| 763 |
\exp_not:N \fontencoding { \g__fontspec_nfss_enc_tl } |
| 764 |
\exp_not:N \selectfont |
| 765 |
} |
| 766 |
} |
| 767 |
} |
| 768 |
\cs_new:Nn \__fontspec_main_newfontface:NnnN |
| 769 |
{ |
| 770 |
\__fontspec_main_newfontfamily:NnnN #1 { BoldFont={},ItalicFont={},SmallCapsFont={},#2 } {#3} #4 |
| 771 |
} |
| 772 |
\cs_new:Nn \__fontspec_set_default_features:nn |
| 773 |
{ |
| 774 |
\IfBooleanTF {#1} \clist_gput_right:Nn \clist_gset:Nn |
| 775 |
\g__fontspec_default_fontopts_clist {#2} |
| 776 |
} |
| 777 |
\cs_new:Nn \__fontspec_set_font_default_features:nnn |
| 778 |
{ |
| 779 |
\clist_map_inline:nn {#2} |
| 780 |
{ |
| 781 |
\tl_if_single:nTF {##1} |
| 782 |
{ \tl_set:No \l__fontspec_tmp_tl { \cs:w l__fontspec_ \cs_to_str:N ##1 _family_tl\cs_end: } } |
| 783 |
{ \__fontspec_sanitise_fontname:Nn \l__fontspec_tmp_tl {##1} } |
| 784 |
|
| 785 |
\IfBooleanTF {#1} |
| 786 |
{ |
| 787 |
\prop_get:NVNF \g__fontspec_fontopts_prop \l__fontspec_tmp_tl \l__fontspec_tmpb_tl |
| 788 |
{ \tl_clear:N \l__fontspec_tmpb_tl } |
| 789 |
\tl_put_right:Nn \l__fontspec_tmpb_tl {#3,} |
| 790 |
\prop_gput:NVV \g__fontspec_fontopts_prop \l__fontspec_tmp_tl \l__fontspec_tmpb_tl |
| 791 |
} |
| 792 |
{ |
| 793 |
\tl_if_empty:nTF {#3} |
| 794 |
{ \prop_gremove:NV \g__fontspec_fontopts_prop \l__fontspec_tmp_tl } |
| 795 |
{ \prop_gput:NVn \g__fontspec_fontopts_prop \l__fontspec_tmp_tl {#3,} } |
| 796 |
} |
| 797 |
} |
| 798 |
} |
| 799 |
\cs_new:Nn \__fontspec_main_addfontfeatures:n |
| 800 |
{ |
| 801 |
\fontspec_if_fontspec_font:TF |
| 802 |
{ |
| 803 |
\group_begin: |
| 804 |
\keys_set_known:nnN {fontspec-addfeatures} {#1} \l__fontspec_tmp_tl |
| 805 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {options} \l__fontspec_options_tl |
| 806 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {fontname} \l__fontspec_fontname_tl |
| 807 |
\bool_set_true:N \l__fontspec_disable_defaults_bool |
| 808 |
\use:x |
| 809 |
{ |
| 810 |
\__fontspec_select_font_family:nn |
| 811 |
{ \l__fontspec_options_tl , #1 } {\l__fontspec_fontname_tl} |
| 812 |
} |
| 813 |
\group_end: |
| 814 |
\fontfamily \g__fontspec_nfss_family_tl \selectfont |
| 815 |
} |
| 816 |
{ |
| 817 |
\__fontspec_warning:nx {addfontfeatures-ignored} {#1} |
| 818 |
} |
| 819 |
\ignorespaces |
| 820 |
} |
| 821 |
\cs_new:Nn \__fontspec_main_newfontfeature:nn |
| 822 |
{ |
| 823 |
\keys_define:nn { fontspec } |
| 824 |
{ |
| 825 |
#1 .code:n = { \__fontspec_update_featstr:n {#2} } |
| 826 |
} |
| 827 |
} |
| 828 |
\cs_new:Nn \__fontspec_main_newAATfeature:nnnn |
| 829 |
{ |
| 830 |
\keys_if_exist:nnF { fontspec } {#1} |
| 831 |
{ \__fontspec_define_aat_feature_group:n {#1} } |
| 832 |
|
| 833 |
\keys_if_choice_exist:nnnT {fontspec} {#1} {#2} |
| 834 |
{ \__fontspec_warning:nxx {feature-option-overwrite} {#1} {#2} } |
| 835 |
|
| 836 |
\__fontspec_define_aat_feature:nnnn {#1}{#2}{#3}{#4} |
| 837 |
} |
| 838 |
\cs_new:Nn \__fontspec_main_newopentypefeature:nnn |
| 839 |
{ |
| 840 |
\keys_if_exist:nnF { fontspec / options } {#1} |
| 841 |
{ \__fontspec_define_opentype_feature_group:n {#1} } |
| 842 |
|
| 843 |
\keys_if_choice_exist:nnnT {fontspec} {#1} {#2} |
| 844 |
{ \__fontspec_warning:nxx {feature-option-overwrite} {#1} {#2} } |
| 845 |
|
| 846 |
\exp_args:Nnnx \__fontspec_define_opentype_feature:nnnnn |
| 847 |
{#1} {#2} { \__fontspec_strip_plus_minus:n {#3} } {#3} {} |
| 848 |
} |
| 849 |
\cs_new:Nn \__fontspec_strip_plus_minus:n { \__fontspec_strip_plus_minus_aux:Nq #1 \q_nil } |
| 850 |
\cs_new:Npn \__fontspec_strip_plus_minus_aux:Nq #1#2 \q_nil |
| 851 |
{ |
| 852 |
\str_case:nnF {#1} { {+} {#2} {-} {#2} } {#1#2} |
| 853 |
} |
| 854 |
\cs_new:Nn \__fontspec_main_aliasfontfeature:nn |
| 855 |
{ |
| 856 |
\bool_set_false:N \l__fontspec_alias_bool |
| 857 |
|
| 858 |
\clist_map_inline:Nn \g__fontspec_all_keyval_modules_clist |
| 859 |
{ |
| 860 |
\keys_if_exist:nnT {##1} {#1} |
| 861 |
{ |
| 862 |
\bool_set_true:N \l__fontspec_alias_bool |
| 863 |
\keys_define:nn {##1} |
| 864 |
{ #2 .code:n = { \keys_set:nn {##1} { #1 = {####1} } } } |
| 865 |
} |
| 866 |
} |
| 867 |
|
| 868 |
\bool_if:NF \l__fontspec_alias_bool |
| 869 |
{ \__fontspec_warning:nx {rename-feature-not-exist} {#1} } |
| 870 |
} |
| 871 |
\cs_new:Nn \__fontspec_main_aliasfontfeatureoption:nnn |
| 872 |
{ |
| 873 |
\bool_set_false:N \l__fontspec_alias_bool |
| 874 |
|
| 875 |
\clist_map_inline:Nn \g__fontspec_all_keyval_modules_clist |
| 876 |
{ |
| 877 |
\keys_if_exist:nnT { ##1 / #1 } {#2} |
| 878 |
{ |
| 879 |
\bool_set_true:N \l__fontspec_alias_bool |
| 880 |
\keys_define:nn { ##1 / #1 } |
| 881 |
{ #3 .code:n = { \keys_set:nn {##1} { #1 = {#2} } } } |
| 882 |
} |
| 883 |
|
| 884 |
\keys_if_exist:nnT { ##1 / #1 } {#2Reset} |
| 885 |
{ |
| 886 |
\keys_define:nn { ##1 / #1 } |
| 887 |
{ #3Reset .code:n = { \keys_set:nn {##1} { #1 = {#2Reset} } } } |
| 888 |
} |
| 889 |
|
| 890 |
\keys_if_exist:nnT { ##1 / #1 } {#2Off} |
| 891 |
{ |
| 892 |
\keys_define:nn { ##1 / #1 } |
| 893 |
{ #3Off .code:n = { \keys_set:nn {##1} { #1 = {#2Off} } } } |
| 894 |
} |
| 895 |
} |
| 896 |
|
| 897 |
\bool_if:NF \l__fontspec_alias_bool |
| 898 |
{ \__fontspec_warning:nx {rename-feature-not-exist} {#1/#2} } |
| 899 |
} |
| 900 |
\cs_new:Nn \__fontspec_main_DeclareFontExtensions:n |
| 901 |
{ |
| 902 |
\clist_set:Nn \l__fontspec_extensions_clist { #1 } |
| 903 |
} |
| 904 |
\__fontspec_main_DeclareFontExtensions:n {.otf,.ttf,.OTF,.TTF,.ttc,.TTC,.dfont} |
| 905 |
\cs_new:Nn \__fontspec_main_IfFontFeatureActiveTF:nnn |
| 906 |
{ |
| 907 |
\__fontspec_if_font_feature:nTF {#1} {#2} {#3} |
| 908 |
} |
| 909 |
\prg_new_conditional:Nnn \__fontspec_if_font_feature:n {TF} |
| 910 |
{ |
| 911 |
\tl_gclear:N \g__fontspec_single_feat_tl |
| 912 |
\group_begin: |
| 913 |
\__fontspec_font_suppress_not_found_error: |
| 914 |
\__fontspec_init: |
| 915 |
\bool_set_true:N \l__fontspec_ot_bool |
| 916 |
\bool_set_true:N \l__fontspec_never_check_bool |
| 917 |
\bool_set_false:N \l__fontspec_firsttime_bool |
| 918 |
\clist_clear:N \l__fontspec_fontfeat_clist |
| 919 |
\__fontspec_get_features:n {#1} |
| 920 |
\group_end: |
| 921 |
|
| 922 |
|
| 923 |
\tl_if_empty:NTF \g__fontspec_single_feat_tl { \prg_return_false: } |
| 924 |
{ |
| 925 |
\exp_args:NV \fontspec_if_current_feature:nTF \g__fontspec_single_feat_tl |
| 926 |
{ \prg_return_true: } { \prg_return_false: } |
| 927 |
} |
| 928 |
} |
| 929 |
\cs_new_protected:Nn \__fontspec_main_oldstylenums:n |
| 930 |
{ |
| 931 |
\group_begin: |
| 932 |
\addfontfeature{Numbers=OldStyle} |
| 933 |
#1 |
| 934 |
\group_end: |
| 935 |
} |
| 936 |
\cs_new_protected:Nn \__fontspec_main_liningnums:n |
| 937 |
{ |
| 938 |
\group_begin: |
| 939 |
\addfontfeature{Numbers=Lining} |
| 940 |
#1 |
| 941 |
\group_end: |
| 942 |
} |
| 943 |
|
| 944 |
%%^^A%% fontspec-code-api.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 945 |
|
| 946 |
\prg_new_conditional:Nnn \fontspec_if_fontspec_font: {TF,T,F} |
| 947 |
{ |
| 948 |
\cs_if_exist:cTF {g__fontspec_fontinfo_ \f@family _prop} \prg_return_true: \prg_return_false: |
| 949 |
} |
| 950 |
\prg_new_conditional:Nnn \fontspec_if_aat_feature:nn {TF,T,F} |
| 951 |
{ |
| 952 |
\fontspec_if_fontspec_font:TF |
| 953 |
{ |
| 954 |
\__fontspec_set_font_type:N \font |
| 955 |
\bool_if:NTF \l__fontspec_atsui_bool |
| 956 |
{ |
| 957 |
\__fontspec_make_AAT_feature_string:NnnTF \font {#1} {#2} |
| 958 |
\prg_return_true: \prg_return_false: |
| 959 |
} |
| 960 |
{ |
| 961 |
\prg_return_false: |
| 962 |
} |
| 963 |
} |
| 964 |
{ |
| 965 |
\prg_return_false: |
| 966 |
} |
| 967 |
} |
| 968 |
\prg_new_conditional:Nnn \fontspec_if_opentype: {TF,T,F} |
| 969 |
{ |
| 970 |
\fontspec_if_fontspec_font:TF |
| 971 |
{ |
| 972 |
\__fontspec_set_font_type:N \font |
| 973 |
\bool_if:NTF \l__fontspec_ot_bool \prg_return_true: \prg_return_false: |
| 974 |
} |
| 975 |
{ |
| 976 |
\prg_return_false: |
| 977 |
} |
| 978 |
} |
| 979 |
\prg_new_conditional:Nnn \fontspec_if_feature:n {TF,T,F} |
| 980 |
{ |
| 981 |
\fontspec_if_fontspec_font:TF |
| 982 |
{ |
| 983 |
\__fontspec_set_font_type:N \font |
| 984 |
\bool_if:NTF \l__fontspec_ot_bool |
| 985 |
{ |
| 986 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {script-num} \l__fontspec_tmp_tl |
| 987 |
\int_set:Nn \l__fontspec_script_int {\l__fontspec_tmp_tl} |
| 988 |
|
| 989 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {lang-num} \l__fontspec_tmp_tl |
| 990 |
\int_set:Nn \l__fontspec_language_int {\l__fontspec_tmp_tl} |
| 991 |
|
| 992 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {script-tag} \l__fontspec_script_tl |
| 993 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {lang-tag} \l__fontspec_lang_tl |
| 994 |
|
| 995 |
\__fontspec_check_ot_feat:NnnnTF \font {#1} {\l__fontspec_lang_tl} {\l__fontspec_script_tl} {\prg_return_true:} {\prg_return_false:} |
| 996 |
} |
| 997 |
{ |
| 998 |
\prg_return_false: |
| 999 |
} |
| 1000 |
} |
| 1001 |
{ |
| 1002 |
\prg_return_false: |
| 1003 |
} |
| 1004 |
} |
| 1005 |
\prg_new_conditional:Nnn \fontspec_if_feature:nnn {TF,T,F} |
| 1006 |
{ |
| 1007 |
\fontspec_if_fontspec_font:TF |
| 1008 |
{ |
| 1009 |
\__fontspec_set_font_type:N \font |
| 1010 |
\bool_if:NTF \l__fontspec_ot_bool |
| 1011 |
{ |
| 1012 |
\__fontspec_check_ot_feat:NnnnTF \font {#3} {#2} {#1} \prg_return_true: \prg_return_false: |
| 1013 |
} |
| 1014 |
{ \prg_return_false: } |
| 1015 |
} |
| 1016 |
{ \prg_return_false: } |
| 1017 |
} |
| 1018 |
\prg_new_conditional:Nnn \fontspec_if_script:n {TF,T,F} |
| 1019 |
{ |
| 1020 |
\fontspec_if_fontspec_font:TF |
| 1021 |
{ |
| 1022 |
\__fontspec_set_font_type:N \font |
| 1023 |
\bool_if:NTF \l__fontspec_ot_bool |
| 1024 |
{ |
| 1025 |
\__fontspec_check_script:NnTF \font {#1} \prg_return_true: \prg_return_false: |
| 1026 |
} |
| 1027 |
{ \prg_return_false: } |
| 1028 |
} |
| 1029 |
{ \prg_return_false: } |
| 1030 |
} |
| 1031 |
\prg_new_conditional:Nnn \fontspec_if_language:n {TF,T,F} |
| 1032 |
{ |
| 1033 |
\fontspec_if_fontspec_font:TF |
| 1034 |
{ |
| 1035 |
\__fontspec_set_font_type:N \font |
| 1036 |
\bool_if:NTF \l__fontspec_ot_bool |
| 1037 |
{ |
| 1038 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {script-num} \l__fontspec_tmp_tl |
| 1039 |
\int_set:Nn \l__fontspec_script_int {\l__fontspec_tmp_tl} |
| 1040 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {script-tag} \l__fontspec_script_tl |
| 1041 |
|
| 1042 |
\__fontspec_check_lang:NnTF \font {#1} \prg_return_true: \prg_return_false: |
| 1043 |
} |
| 1044 |
{ \prg_return_false: } |
| 1045 |
} |
| 1046 |
{ \prg_return_false: } |
| 1047 |
} |
| 1048 |
\prg_new_conditional:Nnn \fontspec_if_language:nn {TF,T,F} |
| 1049 |
{ |
| 1050 |
\fontspec_if_fontspec_font:TF |
| 1051 |
{ |
| 1052 |
\__fontspec_set_font_type:N \font |
| 1053 |
\bool_if:NTF \l__fontspec_ot_bool |
| 1054 |
{ |
| 1055 |
\__fontspec_check_lang:NnnTF \font {#2} {#1} \prg_return_true: \prg_return_false: |
| 1056 |
} |
| 1057 |
{ \prg_return_false: } |
| 1058 |
} |
| 1059 |
{ \prg_return_false: } |
| 1060 |
} |
| 1061 |
\prg_new_conditional:Nnn \fontspec_if_current_script:n {TF,T,F} |
| 1062 |
{ |
| 1063 |
\fontspec_if_fontspec_font:TF |
| 1064 |
{ |
| 1065 |
\__fontspec_set_font_type:N \font |
| 1066 |
\bool_if:NTF \l__fontspec_ot_bool |
| 1067 |
{ |
| 1068 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {script-tag} \l__fontspec_tmp_tl |
| 1069 |
\str_if_eq:nVTF {#1} \l__fontspec_tmp_tl |
| 1070 |
{\prg_return_true:} {\prg_return_false:} |
| 1071 |
} |
| 1072 |
{ \prg_return_false: } |
| 1073 |
} |
| 1074 |
{ \prg_return_false: } |
| 1075 |
} |
| 1076 |
\prg_new_conditional:Nnn \fontspec_if_current_language:n {TF,T,F} |
| 1077 |
{ |
| 1078 |
\fontspec_if_fontspec_font:TF |
| 1079 |
{ |
| 1080 |
\__fontspec_set_font_type:N \font |
| 1081 |
\bool_if:NTF \l__fontspec_ot_bool |
| 1082 |
{ |
| 1083 |
\prop_get:cnN {g__fontspec_fontinfo_ \f@family _prop} {lang-tag} \l__fontspec_tmp_tl |
| 1084 |
\str_if_eq:nVTF {#1} \l__fontspec_tmp_tl |
| 1085 |
{\prg_return_true:} {\prg_return_false:} |
| 1086 |
} |
| 1087 |
{ \prg_return_false: } |
| 1088 |
} |
| 1089 |
{ \prg_return_false: } |
| 1090 |
} |
| 1091 |
\cs_new:Nn \__fontspec_tl_new_if_free:N { \tl_if_exist:NF #1 { \tl_new:N #1 } } |
| 1092 |
\cs_new:Nn \__fontspec_set_family:NnnN |
| 1093 |
{ |
| 1094 |
\tl_set:Nn \l__fontspec_fontface_cs_tl {\l_fontspec_font} % reset |
| 1095 |
\tl_set:Nn \l__fontspec_family_label_tl {#1} |
| 1096 |
\__fontspec_select_font_family:nn {#2} {#3} |
| 1097 |
\__fontspec_tl_new_if_free:N #1 |
| 1098 |
#4 #1 \l_fontspec_family_tl |
| 1099 |
\tl_set:Nn \l__fontspec_fontface_cs_tl {\l_fontspec_font} % reset |
| 1100 |
} |
| 1101 |
\cs_new:Nn \fontspec_gset_family:Nnn { \__fontspec_set_family:NnnN #1 {#2} {#3} \tl_gset_eq:NN } |
| 1102 |
\cs_new:Nn \fontspec_set_family:Nnn { \__fontspec_set_family:NnnN #1 {#2} {#3} \tl_set_eq:NN } |
| 1103 |
\cs_generate_variant:Nn \fontspec_set_family:Nnn {c} |
| 1104 |
\tl_new:N \l__fontspec_fontface_cs_tl |
| 1105 |
\tl_set:Nn \l__fontspec_fontface_cs_tl {\l_fontspec_font} |
| 1106 |
\cs_new:Nn \__fontspec_set_fontface:NNnnN |
| 1107 |
{ |
| 1108 |
\tl_set:Nn \l__fontspec_fontface_cs_tl {#1} |
| 1109 |
\tl_set:Nn \l__fontspec_family_label_tl {#2} |
| 1110 |
\__fontspec_select_font_family:nn {#3} {#4} |
| 1111 |
#5 #2 \l_fontspec_family_tl |
| 1112 |
\tl_set:Nn \l__fontspec_fontface_cs_tl {\l_fontspec_font} % reset |
| 1113 |
} |
| 1114 |
\cs_new:Nn \fontspec_gset_fontface:NNnn { \__fontspec_set_fontface:NNnnN #1 #2 {#3} {#4} \tl_gset_eq:NN } |
| 1115 |
\cs_new:Nn \fontspec_set_fontface:NNnn { \__fontspec_set_fontface:NNnnN #1 #2 {#3} {#4} \tl_set_eq:NN } |
| 1116 |
\prg_new_conditional:Nnn \fontspec_font_if_exist:n {TF,T,F} |
| 1117 |
{ |
| 1118 |
\group_begin: |
| 1119 |
\__fontspec_init: |
| 1120 |
\__fontspec_if_detect_external:nT {#1} { \__fontspec_font_is_file: } |
| 1121 |
\__fontspec_primitive_font_if_exist:nTF { \__fontspec_construct_font_call:nn {#1} {} } |
| 1122 |
{ \group_end: \prg_return_true: } |
| 1123 |
{ \group_end: \prg_return_false: } |
| 1124 |
} |
| 1125 |
\cs_set_eq:NN \IfFontExistsTF \fontspec_font_if_exist:nTF |
| 1126 |
|
| 1127 |
\prg_new_conditional:Nnn \fontspec_if_current_feature:n {TF,T,F} |
| 1128 |
{ |
| 1129 |
\exp_args:Nxx \tl_if_in:nnTF |
| 1130 |
{ \__fontspec_primitive_font_current_name: } { \tl_to_str:n {#1} } |
| 1131 |
{ \prg_return_true: } { \prg_return_false: } |
| 1132 |
} |
| 1133 |
\prg_new_conditional:Nnn \fontspec_if_small_caps: {TF,T,F} |
| 1134 |
{ |
| 1135 |
\__fontspec_if_merge_shape:nTF {sc} |
| 1136 |
{ |
| 1137 |
\tl_set_eq:Nc \l__fontspec_smcp_shape_tl { \__fontspec_shape_merge:nn {\f@shape} {sc} } |
| 1138 |
} |
| 1139 |
{ |
| 1140 |
\tl_set:Nn \l__fontspec_smcp_shape_tl {sc} |
| 1141 |
} |
| 1142 |
|
| 1143 |
\cs_if_exist:cTF { \f@encoding/\f@family/\f@series/\l__fontspec_smcp_shape_tl } |
| 1144 |
{ |
| 1145 |
\tl_if_eq:ccTF |
| 1146 |
{ \f@encoding/\f@family/\f@series/\l__fontspec_smcp_shape_tl } |
| 1147 |
{ \f@encoding/\f@family/\f@series/\shapedefault } |
| 1148 |
{ \prg_return_false: } |
| 1149 |
{ \prg_return_true: } |
| 1150 |
} |
| 1151 |
{ \prg_return_false: } |
| 1152 |
} |
| 1153 |
|
| 1154 |
%%^^A%% fontspec-code-internal.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 1155 |
|
| 1156 |
\cs_new_protected:Nn \__fontspec_select_font_family:nn |
| 1157 |
{ |
| 1158 |
\group_begin: |
| 1159 |
\__fontspec_font_suppress_not_found_error: |
| 1160 |
\__fontspec_init: |
| 1161 |
|
| 1162 |
\__fontspec_sanitise_fontname:Nn \l_fontspec_fontname_tl {#2} |
| 1163 |
\tl_set_eq:NN \l__fontspec_fontname_up_tl \l_fontspec_fontname_tl |
| 1164 |
\tl_set_eq:NN \l__fontspec_basename_tl \l_fontspec_fontname_tl |
| 1165 |
|
| 1166 |
|
| 1167 |
\__fontspec_if_detect_external:nT {#2} |
| 1168 |
{ \keys_set:nn {fontspec-preparse-external} {Path} } |
| 1169 |
|
| 1170 |
\keys_set_known:nn {fontspec-preparse-cfg} {#1} |
| 1171 |
|
| 1172 |
\__fontspec_init_ttc:n {#2} |
| 1173 |
\__fontspec_load_external_fontoptions:N \l_fontspec_fontname_tl |
| 1174 |
|
| 1175 |
\__fontspec_extract_all_features:n {#1} |
| 1176 |
\tl_set:Nx \l__fontspec_fontid_tl { \tl_to_str:N \l_fontspec_fontname_tl-:-\tl_to_str:N \l__fontspec_all_features_clist } |
| 1177 |
|
| 1178 |
|
| 1179 |
\__fontspec_preparse_features: |
| 1180 |
|
| 1181 |
|
| 1182 |
\__fontspec_load_font: |
| 1183 |
\__fontspec_set_scriptlang: |
| 1184 |
\__fontspec_get_features:n {} |
| 1185 |
\bool_set_false:N \l__fontspec_firsttime_bool |
| 1186 |
|
| 1187 |
\__fontspec_save_family_needed:nTF {#2} |
| 1188 |
{ |
| 1189 |
\__fontspec_save_family:nn {#1} {#2} |
| 1190 |
} |
| 1191 |
{ |
| 1192 |
} |
| 1193 |
\group_end: |
| 1194 |
|
| 1195 |
\tl_set_eq:NN \l_fontspec_family_tl \g__fontspec_nfss_family_tl |
| 1196 |
} |
| 1197 |
\cs_set_eq:NN \fontspec_select:nn \__fontspec_select_font_family:nn %% deprecated, for compatibility only |
| 1198 |
\cs_new:Nn \__fontspec_sanitise_fontname:Nn |
| 1199 |
{ |
| 1200 |
\tl_set:Nx #1 {#2} |
| 1201 |
\tl_trim_spaces:N #1 |
| 1202 |
\__fontspec_process_ext:N #1 |
| 1203 |
} |
| 1204 |
|
| 1205 |
\cs_new:Nn \__fontspec_process_ext:N |
| 1206 |
{ |
| 1207 |
\clist_map_inline:Nn \l__fontspec_extensions_clist |
| 1208 |
{ |
| 1209 |
\tl_if_in:NnT #1 {##1} |
| 1210 |
{ |
| 1211 |
\tl_remove_once:Nn #1 {##1} |
| 1212 |
\tl_set:Nn \l__fontspec_extension_tl {##1} |
| 1213 |
\__fontspec_font_is_file: |
| 1214 |
\clist_map_break: |
| 1215 |
} |
| 1216 |
} |
| 1217 |
} |
| 1218 |
\prg_new_conditional:Nnn \__fontspec_if_detect_external:n {T} |
| 1219 |
{ |
| 1220 |
\clist_map_inline:Nn \l__fontspec_extensions_clist |
| 1221 |
{ |
| 1222 |
\bool_set_false:N \l__fontspec_tmpa_bool |
| 1223 |
\exp_args:Nx % <- this should be handled earlier |
| 1224 |
\tl_if_in:nnT {#1 <= end_of_string} {##1 <= end_of_string} |
| 1225 |
{ \bool_set_true:N \l__fontspec_tmpa_bool \clist_map_break: } |
| 1226 |
} |
| 1227 |
\bool_if:NTF \l__fontspec_tmpa_bool \prg_return_true: \prg_return_false: |
| 1228 |
} |
| 1229 |
\cs_new:Nn \__fontspec_init_ttc:n |
| 1230 |
{ |
| 1231 |
\str_if_eq:eeT { \str_lowercase:f {\l__fontspec_extension_tl} } {.ttc} |
| 1232 |
{ |
| 1233 |
\tl_set_eq:NN \l__fontspec_fontname_it_tl \l_fontspec_fontname_tl |
| 1234 |
\tl_set_eq:NN \l__fontspec_fontname_bf_tl \l_fontspec_fontname_tl |
| 1235 |
\tl_set_eq:NN \l__fontspec_fontname_bfit_tl \l_fontspec_fontname_tl |
| 1236 |
} |
| 1237 |
} |
| 1238 |
\cs_new:Nn \__fontspec_load_external_fontoptions:N |
| 1239 |
{ |
| 1240 |
\bool_if:NT \l__fontspec_fontcfg_bool |
| 1241 |
{ |
| 1242 |
\tl_set:Nx \l__fontspec_ext_filename_tl {#1.fontspec} |
| 1243 |
\tl_remove_all:Nn \l__fontspec_ext_filename_tl {~} |
| 1244 |
\prop_if_in:NVF \g__fontspec_fontopts_prop #1 |
| 1245 |
{ |
| 1246 |
\exp_args:No \file_if_exist:nTF { \l__fontspec_ext_filename_tl } |
| 1247 |
{ |
| 1248 |
\file_input:n { \l__fontspec_ext_filename_tl } |
| 1249 |
} |
| 1250 |
{ |
| 1251 |
\tl_remove_all:Nn \l__fontspec_ext_filename_tl {~} |
| 1252 |
\exp_args:No \file_if_exist:nT { \l__fontspec_ext_filename_tl } |
| 1253 |
{ \file_input:n { \l__fontspec_ext_filename_tl } } |
| 1254 |
} |
| 1255 |
} |
| 1256 |
} |
| 1257 |
} |
| 1258 |
\cs_new:Nn \__fontspec_extract_all_features:n |
| 1259 |
{ |
| 1260 |
\bool_if:NTF \l__fontspec_disable_defaults_bool |
| 1261 |
{ |
| 1262 |
\clist_set:Nx \l__fontspec_all_features_clist {#1} |
| 1263 |
} |
| 1264 |
{ |
| 1265 |
\prop_get:NVNF \g__fontspec_fontopts_prop \l_fontspec_fontname_tl \l__fontspec_fontopts_clist |
| 1266 |
{ \clist_clear:N \l__fontspec_fontopts_clist } |
| 1267 |
|
| 1268 |
\prop_get:NVNF \g__fontspec_fontopts_prop \l__fontspec_family_label_tl \l__fontspec_family_fontopts_clist |
| 1269 |
{ \clist_clear:N \l__fontspec_family_fontopts_clist } |
| 1270 |
\tl_clear:N \l__fontspec_family_label_tl |
| 1271 |
|
| 1272 |
\clist_set:Nx \l__fontspec_all_features_clist |
| 1273 |
{ |
| 1274 |
\g__fontspec_default_fontopts_clist, |
| 1275 |
\l__fontspec_family_fontopts_clist, |
| 1276 |
\l__fontspec_fontopts_clist, |
| 1277 |
#1 |
| 1278 |
} |
| 1279 |
} |
| 1280 |
} |
| 1281 |
\cs_new:Nn \__fontspec_preparse_features: |
| 1282 |
{ |
| 1283 |
|
| 1284 |
\__fontspec_keys_set_known:nxN {fontspec-preparse-external} |
| 1285 |
{ \l__fontspec_all_features_clist } |
| 1286 |
\l__fontspec_keys_leftover_clist |
| 1287 |
|
| 1288 |
\tl_set_eq:NN \l_fontspec_fontname_tl \l__fontspec_fontname_up_tl |
| 1289 |
\__fontspec_keys_set_known:nxN {fontspec-renderer} {\l__fontspec_keys_leftover_clist} |
| 1290 |
\l__fontspec_keys_leftover_clist |
| 1291 |
\__fontspec_keys_set_known:nxN {fontspec-preparse} {\l__fontspec_keys_leftover_clist} |
| 1292 |
\l__fontspec_fontfeat_clist |
| 1293 |
} |
| 1294 |
\cs_new:Nn \__fontspec_load_font: |
| 1295 |
{ |
| 1296 |
|
| 1297 |
\__fontspec_sanitise_fontname:Nn \l__fontspec_fontname_up_tl { \l__fontspec_fontname_up_tl } |
| 1298 |
\__fontspec_primitive_font_set:NnnF \l__fontspec_test_font |
| 1299 |
{ \__fontspec_construct_font_call:nn { \l__fontspec_fontname_up_tl } { \l__fontspec_pre_feat_sclist } } |
| 1300 |
{ \f@size pt - 2sp } |
| 1301 |
{ \__fontspec_error:nx {font-not-found} {\l__fontspec_fontname_up_tl} } |
| 1302 |
|
| 1303 |
\__fontspec_set_font_type:N \l__fontspec_test_font |
| 1304 |
\__fontspec_primitive_font_gset:Onn \l__fontspec_fontface_cs_tl |
| 1305 |
{ \__fontspec_construct_font_call:nn { \l__fontspec_fontname_up_tl } { \l__fontspec_pre_feat_sclist } } |
| 1306 |
{ \f@size pt + 2sp } |
| 1307 |
|
| 1308 |
\l__fontspec_fontface_cs_tl % this is necessary for LuaLaTeX to check the scripts properly |
| 1309 |
|
| 1310 |
} |
| 1311 |
\cs_new:Nn \__fontspec_construct_font_call:nnnnnn |
| 1312 |
{ |
| 1313 |
" \__fontspec_fontname_wrap:n { #1 #2 #3 } |
| 1314 |
#4 #5 |
| 1315 |
\str_if_eq:eeF {#6}{} {:#6} " |
| 1316 |
} |
| 1317 |
\cs_new:Nn \__fontspec_construct_font_call:nn |
| 1318 |
{ |
| 1319 |
\__fontspec_construct_font_call:nnnnnn |
| 1320 |
{#1} |
| 1321 |
\l__fontspec_extension_tl |
| 1322 |
\l__fontspec_ttc_index_tl |
| 1323 |
\l__fontspec_renderer_tl |
| 1324 |
\l__fontspec_optical_size_tl |
| 1325 |
{#2} |
| 1326 |
} |
| 1327 |
\cs_new:Nn \__fontspec_font_is_name: |
| 1328 |
{ |
| 1329 |
\cs_set_eq:NN \__fontspec_fontname_wrap:n \use:n |
| 1330 |
} |
| 1331 |
\cs_new:Nn \__fontspec_font_is_file: |
| 1332 |
{ |
| 1333 |
\bool_set_true:N \l__fontspec_external_bool |
| 1334 |
\bool_lazy_and:nnTF { \l__fontspec_external_kpse_bool } { \tl_if_empty_p:N \l__fontspec_font_path_tl } |
| 1335 |
{ |
| 1336 |
\cs_set:Npn \__fontspec_fontname_wrap:n ##1 { kpse: ##1 } |
| 1337 |
} |
| 1338 |
{ |
| 1339 |
\cs_set:Npn \__fontspec_fontname_wrap:n ##1 { [ \l__fontspec_font_path_tl ##1 ] } |
| 1340 |
} |
| 1341 |
} |
| 1342 |
\cs_new:Nn \__fontspec_set_scriptlang: |
| 1343 |
{ |
| 1344 |
\bool_if:NT \l__fontspec_firsttime_bool |
| 1345 |
{ |
| 1346 |
\tl_if_empty:NF \l__fontspec_script_name_tl |
| 1347 |
{ |
| 1348 |
\keys_set:ne {fontspec-opentype} {Script=\l__fontspec_script_name_tl} |
| 1349 |
\keys_set:ne {fontspec-opentype} {Language=\l__fontspec_lang_name_tl} |
| 1350 |
} |
| 1351 |
} |
| 1352 |
} |
| 1353 |
\cs_new:Nn \__fontspec_get_features:n |
| 1354 |
{ |
| 1355 |
\__fontspec_init_fontface: |
| 1356 |
\__fontspec_keys_set_known:nxN {fontspec-renderer} {\l__fontspec_fontfeat_clist,#1} |
| 1357 |
\l__fontspec_keys_leftover_clist |
| 1358 |
\__fontspec_keys_set_known:nxN {fontspec} {\l__fontspec_keys_leftover_clist} \l__fontspec_keys_leftover_clist |
| 1359 |
\bool_if:NTF \l__fontspec_ot_bool |
| 1360 |
{ |
| 1361 |
\keys_set_known:nV {fontspec-opentype} \l__fontspec_keys_leftover_clist |
| 1362 |
} |
| 1363 |
{ |
| 1364 |
\bool_if:nT { \l__fontspec_atsui_bool || \l__fontspec_graphite_bool } |
| 1365 |
{ \keys_set_known:nV {fontspec-aat} \l__fontspec_keys_leftover_clist } |
| 1366 |
} |
| 1367 |
|
| 1368 |
\tl_if_empty:NF \l__fontspec_mapping_tl |
| 1369 |
{ \__fontspec_update_featstr:n { mapping = \l__fontspec_mapping_tl } } |
| 1370 |
|
| 1371 |
\str_if_eq:eeF { \l__fontspec_hexcol_tl \l__fontspec_opacity_tl } |
| 1372 |
{ \c__fontspec_hexcol_tl \c__fontspec_opacity_tl } |
| 1373 |
{ \__fontspec_update_featstr:n { color = \l__fontspec_hexcol_tl\l__fontspec_opacity_tl } } |
| 1374 |
} |
| 1375 |
\prg_new_conditional:Nnn \__fontspec_save_family_needed:n { TF } |
| 1376 |
{ |
| 1377 |
|
| 1378 |
|
| 1379 |
\tl_if_empty:NTF \l__fontspec_nfss_fam_tl |
| 1380 |
{ |
| 1381 |
\prop_get:NVNTF \g__fontspec_fontid_family_prop \l__fontspec_fontid_tl \l__fontspec_tmp_tl |
| 1382 |
{ |
| 1383 |
\tl_gset_eq:NN \g__fontspec_nfss_family_tl \l__fontspec_tmp_tl |
| 1384 |
\prg_return_false: |
| 1385 |
} |
| 1386 |
{ |
| 1387 |
\tl_set:Nx \l__fontspec_tmp_tl {#1} |
| 1388 |
\tl_remove_all:Nn \l__fontspec_tmp_tl { ~ } |
| 1389 |
\__fontspec_save_fontid_family:VV \l__fontspec_fontid_tl \l__fontspec_tmp_tl |
| 1390 |
\prg_return_true: |
| 1391 |
} |
| 1392 |
} |
| 1393 |
{ |
| 1394 |
\tl_gset_eq:NN \g__fontspec_nfss_family_tl \l__fontspec_nfss_fam_tl |
| 1395 |
\cs_undefine:c { g__fontspec_fontinfo_ \g__fontspec_nfss_family_tl _prop } |
| 1396 |
\prg_return_true: |
| 1397 |
} |
| 1398 |
} |
| 1399 |
\cs_new:Nn \__fontspec_save_fontid_family:nn |
| 1400 |
{ |
| 1401 |
\prop_get:NnNTF \g__fontspec_family_int_prop {#2} \l__fontspec_tmp_tl |
| 1402 |
{ |
| 1403 |
\tl_set:Nx \l__fontspec_tmp_tl |
| 1404 |
{ \int_eval:n { \l__fontspec_tmp_tl + 1 } } |
| 1405 |
} |
| 1406 |
{ \tl_set:Nn \l__fontspec_tmp_tl { 0 } } |
| 1407 |
\prop_gput:NnV \g__fontspec_family_int_prop {#2} \l__fontspec_tmp_tl |
| 1408 |
\tl_gset:Nx \g__fontspec_nfss_family_tl { #2 ( \l__fontspec_tmp_tl ) } |
| 1409 |
\prop_gput:NnV \g__fontspec_fontid_family_prop {#1} \g__fontspec_nfss_family_tl |
| 1410 |
} |
| 1411 |
\cs_generate_variant:Nn \__fontspec_save_fontid_family:nn { VV } |
| 1412 |
\cs_new:Nn \__fontspec_save_family:nn |
| 1413 |
{ |
| 1414 |
\__fontspec_save_fontinfo:n {#2} |
| 1415 |
\__fontspec_find_autofonts: |
| 1416 |
\DeclareFontFamily{\g__fontspec_nfss_enc_tl}{\g__fontspec_nfss_family_tl}{} |
| 1417 |
\__fontspec_set_faces: |
| 1418 |
\__fontspec_info:nxx {defining-font} {#1} {#2} |
| 1419 |
} |
| 1420 |
\cs_new:Nn \__fontspec_save_fontinfo:n |
| 1421 |
{ |
| 1422 |
\prop_new:c {g__fontspec_fontinfo_ \g__fontspec_nfss_family_tl _prop} |
| 1423 |
\prop_gput:cnx {g__fontspec_fontinfo_ \g__fontspec_nfss_family_tl _prop} {fontname} { #1 } |
| 1424 |
\prop_gput:cnx {g__fontspec_fontinfo_ \g__fontspec_nfss_family_tl _prop} {options} { \l__fontspec_all_features_clist } |
| 1425 |
\prop_gput:cnx {g__fontspec_fontinfo_ \g__fontspec_nfss_family_tl _prop} {fontdef} |
| 1426 |
{ |
| 1427 |
\__fontspec_construct_font_call:nn {\l_fontspec_fontname_tl} |
| 1428 |
{ \l__fontspec_pre_feat_sclist \g__fontspec_rawfeatures_sclist \__fontspec_get_variations: } |
| 1429 |
} |
| 1430 |
\prop_gput:cnV {g__fontspec_fontinfo_ \g__fontspec_nfss_family_tl _prop} {script-num} \l__fontspec_script_int |
| 1431 |
\prop_gput:cnV {g__fontspec_fontinfo_ \g__fontspec_nfss_family_tl _prop} {lang-num} \l__fontspec_language_int |
| 1432 |
\prop_gput:cnV {g__fontspec_fontinfo_ \g__fontspec_nfss_family_tl _prop} {script-tag} \l__fontspec_script_tl |
| 1433 |
\prop_gput:cnV {g__fontspec_fontinfo_ \g__fontspec_nfss_family_tl _prop} {lang-tag} \l__fontspec_lang_tl |
| 1434 |
} |
| 1435 |
\cs_new:Nn \__fontspec_find_autofonts: |
| 1436 |
{ |
| 1437 |
\bool_if:nF {\l__fontspec_noit_bool || \l__fontspec_nobf_bool} |
| 1438 |
{ |
| 1439 |
\__fontspec_set_autofont:Nnn \l__fontspec_fontname_bfit_tl {\l__fontspec_fontname_it_tl} {/B} |
| 1440 |
\__fontspec_set_autofont:Nnn \l__fontspec_fontname_bfit_tl {\l__fontspec_fontname_bf_tl} {/I} |
| 1441 |
\__fontspec_set_autofont:Nnn \l__fontspec_fontname_bfit_tl {\l_fontspec_fontname_tl} {/BI} |
| 1442 |
} |
| 1443 |
|
| 1444 |
\bool_if:NF \l__fontspec_nobf_bool |
| 1445 |
{ |
| 1446 |
\__fontspec_set_autofont:Nnn \l__fontspec_fontname_bf_tl {\l_fontspec_fontname_tl} {/B} |
| 1447 |
} |
| 1448 |
|
| 1449 |
\bool_if:NF \l__fontspec_noit_bool |
| 1450 |
{ |
| 1451 |
\__fontspec_set_autofont:Nnn \l__fontspec_fontname_it_tl {\l_fontspec_fontname_tl} {/I} |
| 1452 |
} |
| 1453 |
|
| 1454 |
\__fontspec_set_autofont:Nnn \l__fontspec_fontname_bfsl_tl {\l__fontspec_fontname_sl_tl} {/B} |
| 1455 |
} |
| 1456 |
\cs_new:Nn \__fontspec_set_faces: |
| 1457 |
{ |
| 1458 |
\__fontspec_add_nfssfont:nnnn \mddefault \shapedefault \l_fontspec_fontname_tl \l__fontspec_fontfeat_up_clist |
| 1459 |
\__fontspec_add_nfssfont:nnnn \bfdefault \shapedefault \l__fontspec_fontname_bf_tl \l__fontspec_fontfeat_bf_clist |
| 1460 |
\__fontspec_add_nfssfont:nnnn \mddefault \itdefault \l__fontspec_fontname_it_tl \l__fontspec_fontfeat_it_clist |
| 1461 |
\__fontspec_add_nfssfont:nnnn \mddefault \sldefault \l__fontspec_fontname_sl_tl \l__fontspec_fontfeat_sl_clist |
| 1462 |
\__fontspec_add_nfssfont:nnnn \mddefault \swdefault \l__fontspec_fontname_sw_tl \l__fontspec_fontfeat_sw_clist |
| 1463 |
\__fontspec_add_nfssfont:nnnn \bfdefault \itdefault \l__fontspec_fontname_bfit_tl \l__fontspec_fontfeat_bfit_clist |
| 1464 |
\__fontspec_add_nfssfont:nnnn \bfdefault \sldefault \l__fontspec_fontname_bfsl_tl \l__fontspec_fontfeat_bfsl_clist |
| 1465 |
\__fontspec_add_nfssfont:nnnn \bfdefault \swdefault \l__fontspec_fontname_bfsw_tl \l__fontspec_fontfeat_bfsw_clist |
| 1466 |
\prop_map_inline:Nn \l__fontspec_nfssfont_prop { \__fontspec_set_faces_aux:nnnnn ##2 } |
| 1467 |
} |
| 1468 |
\cs_new:Nn \__fontspec_set_faces_aux:nnnnn |
| 1469 |
{ |
| 1470 |
\fontspec_complete_fontname:Nn \l__fontspec_curr_fontname_tl {#3} |
| 1471 |
\__fontspec_make_font_shapes:Nnnnn \l__fontspec_curr_fontname_tl {#1} {#2} {#4} {#5} |
| 1472 |
} |
| 1473 |
\cs_new:Nn \fontspec_complete_fontname:Nn |
| 1474 |
{ |
| 1475 |
\tl_set:Nx #1 {#2} |
| 1476 |
\tl_if_in:NnF \l_fontspec_fontname_tl {*} |
| 1477 |
{ |
| 1478 |
\tl_replace_all:Nne #1 {*} {\l__fontspec_basename_tl} |
| 1479 |
} |
| 1480 |
} |
| 1481 |
\cs_new:Nn \__fontspec_add_nfssfont:nnnn |
| 1482 |
{ |
| 1483 |
\tl_set:Nx \l__fontspec_this_font_tl {#3} |
| 1484 |
|
| 1485 |
\tl_if_empty:eTF {#4} |
| 1486 |
{ \clist_set:Nn \l__fontspec_sizefeat_clist {Size={-}} } |
| 1487 |
{ \__fontspec_keys_set_known:nxN {fontspec-preparse-nested} {#4} \l__fontspec_tmp_tl } |
| 1488 |
|
| 1489 |
\tl_if_empty:NF \l__fontspec_this_font_tl |
| 1490 |
{ |
| 1491 |
\prop_put:Nee \l__fontspec_nfssfont_prop {#1/#2} |
| 1492 |
{ {#1}{#2}{\l__fontspec_this_font_tl}{#4}{\l__fontspec_sizefeat_clist} } |
| 1493 |
} |
| 1494 |
} |
| 1495 |
\cs_new:Nn \__fontspec_set_font_type:N |
| 1496 |
{ |
| 1497 |
\bool_set_false:N \l__fontspec_tfm_bool |
| 1498 |
\bool_set_false:N \l__fontspec_atsui_bool |
| 1499 |
\bool_set_false:N \l__fontspec_ot_bool |
| 1500 |
\bool_set_false:N \l__fontspec_mm_bool |
| 1501 |
\bool_set_false:N \l__fontspec_graphite_bool |
| 1502 |
\ifcase\XeTeXfonttype #1 |
| 1503 |
\bool_set_true:N \l__fontspec_tfm_bool |
| 1504 |
\or |
| 1505 |
\bool_set_true:N \l__fontspec_atsui_bool |
| 1506 |
\tl_if_empty:NT \l__fontspec_renderer_tl { \tl_set:Nn \l__fontspec_renderer_tl {/AAT} } |
| 1507 |
\ifnum\XeTeXcountvariations #1 > 0\relax |
| 1508 |
\bool_set_true:N \l__fontspec_mm_bool |
| 1509 |
\fi |
| 1510 |
\or |
| 1511 |
\bool_set_true:N \l__fontspec_ot_bool |
| 1512 |
\tl_if_empty:NT \l__fontspec_renderer_tl { \tl_set:Nn \l__fontspec_renderer_tl {/OT} } |
| 1513 |
\or |
| 1514 |
\bool_set_true:N \l__fontspec_graphite_bool |
| 1515 |
\tl_if_empty:NT \l__fontspec_renderer_tl { \tl_set:Nn \l__fontspec_renderer_tl {/GR} } |
| 1516 |
\fi |
| 1517 |
} |
| 1518 |
\cs_new:Nn \__fontspec_set_autofont:Nnn |
| 1519 |
{ |
| 1520 |
\bool_if:NF \l__fontspec_external_bool |
| 1521 |
{ |
| 1522 |
\tl_if_empty:eF {#2} |
| 1523 |
{ |
| 1524 |
\tl_if_empty:NT #1 |
| 1525 |
{ |
| 1526 |
\__fontspec_if_autofont:nnTF {#2} {#3} |
| 1527 |
{ \tl_set:Nx #1 {#2#3} } |
| 1528 |
{ \__fontspec_info:nx {no-font-shape} {#2#3} } |
| 1529 |
} |
| 1530 |
} |
| 1531 |
} |
| 1532 |
} |
| 1533 |
\prg_new_conditional:Nnn \__fontspec_if_autofont:nn {T,TF} |
| 1534 |
{ |
| 1535 |
\group_begin: |
| 1536 |
\__fontspec_primitive_font_set:Nnn \l__fontspec_tmpa_font { \__fontspec_construct_font_call:nn {#1} { \l__fontspec_pre_feat_sclist } } { \f@size pt + 1sp } |
| 1537 |
\__fontspec_primitive_font_set:Nnn \l__fontspec_tmpb_font { \__fontspec_construct_font_call:nn {#1#2} { \l__fontspec_pre_feat_sclist } } { \f@size pt + 1sp } |
| 1538 |
\cs_if_eq:NNTF \l__fontspec_tmpa_font \l__fontspec_tmpb_font |
| 1539 |
{ \group_end: \prg_return_false: } |
| 1540 |
{ \group_end: \prg_return_true: } |
| 1541 |
} |
| 1542 |
\cs_new:Nn \__fontspec_make_font_shapes:Nnnnn |
| 1543 |
{ |
| 1544 |
\group_begin: |
| 1545 |
\__fontspec_keys_set_known:nxN {fontspec-preparse-external} { #4 } \l__fontspec_leftover_clist |
| 1546 |
\__fontspec_load_fontname:Nn \l_fontspec_fontname_tl {#1} |
| 1547 |
\__fontspec_declare_shape:nnxx {#2} {#3} { \l__fontspec_fontopts_clist, \l__fontspec_leftover_clist } {#5} |
| 1548 |
\group_end: |
| 1549 |
} |
| 1550 |
\cs_new:Nn \__fontspec_load_fontname:Nn |
| 1551 |
{ |
| 1552 |
\__fontspec_sanitise_fontname:Nn #1 {#2} |
| 1553 |
\__fontspec_load_external_fontoptions:N #1 |
| 1554 |
\prop_get:NVNF \g__fontspec_fontopts_prop #1 \l__fontspec_fontopts_clist |
| 1555 |
{ \clist_clear:N \l__fontspec_fontopts_clist } |
| 1556 |
\keys_set_groups:nnV {fontspec/fontname} {getfontname} \l__fontspec_fontopts_clist |
| 1557 |
\__fontspec_primitive_font_set:OnnF \l__fontspec_fontface_cs_tl |
| 1558 |
{ \__fontspec_construct_font_call:nn {#1} { \l__fontspec_pre_feat_sclist } } { \f@size pt + 2sp } |
| 1559 |
{ \__fontspec_error:nx {font-not-found} {#2} } |
| 1560 |
} |
| 1561 |
\keys_define:nn {fontspec/fontname} |
| 1562 |
{ |
| 1563 |
Font .tl_set:N = \l_fontspec_fontname_tl , |
| 1564 |
Font .groups:n = {getfontname} , |
| 1565 |
} |
| 1566 |
\cs_new:Nn \__fontspec_declare_shape:nnnn |
| 1567 |
{ |
| 1568 |
\tl_build_begin:N \l__fontspec_nfss_tl |
| 1569 |
\tl_build_begin:N \l__fontspec_nfss_sc_tl |
| 1570 |
\tl_set_eq:NN \l__fontspec_saved_fontname_tl \l_fontspec_fontname_tl |
| 1571 |
|
| 1572 |
\exp_args:Nx \clist_map_inline:nn {#4} { \__fontspec_setup_single_size:nn {#3} {##1} } |
| 1573 |
|
| 1574 |
\tl_build_end:N \l__fontspec_nfss_tl |
| 1575 |
\tl_build_end:N \l__fontspec_nfss_sc_tl |
| 1576 |
|
| 1577 |
\__fontspec_declare_shapes_normal:nn {#1} {#2} |
| 1578 |
\__fontspec_declare_shapes_smcaps:nn {#1} {#2} |
| 1579 |
\__fontspec_declare_shape_slanted:nn {#1} {#2} |
| 1580 |
\__fontspec_declare_shapes_bx:nn {#1} {#2} |
| 1581 |
\__fontspec_declare_shape_loginfo:nn {#1} {#2} |
| 1582 |
} |
| 1583 |
\cs_generate_variant:Nn \__fontspec_declare_shape:nnnn {nnxx} |
| 1584 |
\cs_new:Nn \__fontspec_setup_single_size:nn |
| 1585 |
{ |
| 1586 |
\tl_clear:N \l__fontspec_size_tl |
| 1587 |
\tl_set_eq:NN \l__fontspec_sizedfont_tl \l__fontspec_saved_fontname_tl % in case not spec'ed |
| 1588 |
|
| 1589 |
\keys_set_known:neN {fontspec-sizing} { \exp_after:wN \use:n #2 } |
| 1590 |
\l__fontspec_sizing_leftover_clist |
| 1591 |
\tl_if_empty:NT \l__fontspec_size_tl { \__fontspec_error:n {no-size-info} } |
| 1592 |
|
| 1593 |
% "normal" |
| 1594 |
\__fontspec_load_fontname:Nn \l_fontspec_fontname_tl {\l__fontspec_sizedfont_tl} |
| 1595 |
\__fontspec_setup_nfss:Nn \l__fontspec_nfss_tl { #1 , \l__fontspec_sizing_leftover_clist } |
| 1596 |
|
| 1597 |
% small caps |
| 1598 |
\clist_set_eq:NN \l__fontspec_fontfeat_curr_clist \l__fontspec_fontfeat_sc_clist |
| 1599 |
|
| 1600 |
\bool_if:NF \l__fontspec_nosc_bool |
| 1601 |
{ |
| 1602 |
\tl_if_empty:NTF \l__fontspec_fontname_sc_tl |
| 1603 |
{ |
| 1604 |
\__fontspec_make_smallcaps:TF |
| 1605 |
{ |
| 1606 |
\clist_put_left:Nn \l__fontspec_fontfeat_curr_clist {Letters=SmallCaps} |
| 1607 |
} |
| 1608 |
{ |
| 1609 |
\bool_set_true:N \l__fontspec_nosc_bool |
| 1610 |
} |
| 1611 |
} |
| 1612 |
{ \__fontspec_load_fontname:Nn \l_fontspec_fontname_tl {\l__fontspec_fontname_sc_tl} }% local for each size |
| 1613 |
} |
| 1614 |
|
| 1615 |
\bool_if:NF \l__fontspec_nosc_bool |
| 1616 |
{ |
| 1617 |
\__fontspec_setup_nfss:Nn \l__fontspec_nfss_sc_tl |
| 1618 |
{#1 , \l__fontspec_sizing_leftover_clist , \l__fontspec_fontfeat_curr_clist} |
| 1619 |
} |
| 1620 |
} |
| 1621 |
\cs_new:Nn \__fontspec_setup_nfss:Nn |
| 1622 |
{ |
| 1623 |
|
| 1624 |
\__fontspec_get_features:n { #2 } |
| 1625 |
|
| 1626 |
|
| 1627 |
\tl_if_empty:NF \l__fontspec_scale_tl |
| 1628 |
{ |
| 1629 |
\tl_set:Nx \l__fontspec_scale_tl { s*[\l__fontspec_scale_tl] } |
| 1630 |
} |
| 1631 |
|
| 1632 |
\tl_build_put_right:Nx #1 |
| 1633 |
{ |
| 1634 |
<\l__fontspec_size_tl> \l__fontspec_scale_tl |
| 1635 |
\__fontspec_construct_font_call:nn { \l_fontspec_fontname_tl } |
| 1636 |
{ \l__fontspec_pre_feat_sclist \g__fontspec_rawfeatures_sclist \__fontspec_get_variations: } |
| 1637 |
} |
| 1638 |
} |
| 1639 |
\cs_new:Nn \__fontspec_declare_shapes_normal:nn |
| 1640 |
{ |
| 1641 |
\__fontspec_DeclareFontShape:xxxxxx {\g__fontspec_nfss_enc_tl} {\g__fontspec_nfss_family_tl} |
| 1642 |
{#1} {#2} {\l__fontspec_nfss_tl}{\l__fontspec_postadjust_tl} |
| 1643 |
} |
| 1644 |
\cs_new:Nn \__fontspec_declare_shapes_smcaps:nn |
| 1645 |
{ |
| 1646 |
\tl_if_empty:NF \l__fontspec_nfss_sc_tl |
| 1647 |
{ |
| 1648 |
\__fontspec_DeclareFontShape:xxxxxx {\g__fontspec_nfss_enc_tl} {\g__fontspec_nfss_family_tl} {#1} |
| 1649 |
{ \__fontspec_combo_sc_shape:n {#2} } {\l__fontspec_nfss_sc_tl} {\l__fontspec_postadjust_tl} |
| 1650 |
} |
| 1651 |
} |
| 1652 |
\cs_new:Nn \__fontspec_combo_sc_shape:n |
| 1653 |
{ |
| 1654 |
\tl_if_exist:cTF { \__fontspec_shape_merge:nn {#1} {\scdefault} } |
| 1655 |
{ \tl_use:c { \__fontspec_shape_merge:nn {#1} {\scdefault} } } |
| 1656 |
{ \scdefault#1 } |
| 1657 |
} |
| 1658 |
\cs_new:Nn \__fontspec_DeclareFontShape:nnnnnn |
| 1659 |
{ |
| 1660 |
\group_begin: |
| 1661 |
\normalsize |
| 1662 |
\cs_undefine:c {#1/#2/#3/#4/\f@size} |
| 1663 |
\group_end: |
| 1664 |
\DeclareFontShape{#1}{#2}{#3}{#4}{#5}{#6} |
| 1665 |
} |
| 1666 |
\cs_generate_variant:Nn \__fontspec_DeclareFontShape:nnnnnn {xxxxxx} |
| 1667 |
\cs_new:Nn \__fontspec_declare_shape_slanted:nn |
| 1668 |
{ |
| 1669 |
\bool_if:nT |
| 1670 |
{ |
| 1671 |
\str_if_eq_p:ee {#2} {\itdefault} && |
| 1672 |
!(\str_if_eq_p:ee {\itdefault} {\sldefault}) |
| 1673 |
} |
| 1674 |
{ |
| 1675 |
\__fontspec_DeclareFontShape:xxxxxx {\g__fontspec_nfss_enc_tl}{\g__fontspec_nfss_family_tl}{#1}{\sldefault} |
| 1676 |
{<->ssub*\g__fontspec_nfss_family_tl/#1/\itdefault}{\l__fontspec_postadjust_tl} |
| 1677 |
} |
| 1678 |
} |
| 1679 |
\cs_new:Nn \__fontspec_declare_shapes_bx:nn |
| 1680 |
{ |
| 1681 |
\bool_if:nT |
| 1682 |
{ |
| 1683 |
\str_if_eq_p:ee {#1} {\bfdefault} && |
| 1684 |
!(\str_if_eq_p:ee {\bfdefault} {bx}) |
| 1685 |
} |
| 1686 |
{ |
| 1687 |
% bx/? |
| 1688 |
\__fontspec_DeclareFontShape:xxxxxx {\g__fontspec_nfss_enc_tl} {\g__fontspec_nfss_family_tl} |
| 1689 |
{bx} {#2} |
| 1690 |
{ <->ssub*\g__fontspec_nfss_family_tl/\bfdefault/#2 } |
| 1691 |
{ \l__fontspec_postadjust_tl } |
| 1692 |
|
| 1693 |
% bx/sc -> b/sc |
| 1694 |
\tl_if_empty:NF \l__fontspec_nfss_sc_tl |
| 1695 |
{ |
| 1696 |
\__fontspec_DeclareFontShape:xxxxxx {\g__fontspec_nfss_enc_tl} {\g__fontspec_nfss_family_tl} |
| 1697 |
{bx} { \__fontspec_combo_sc_shape:n {#2} } |
| 1698 |
{ <->ssub*\g__fontspec_nfss_family_tl/\bfdefault/#2 } |
| 1699 |
{ \l__fontspec_postadjust_tl } |
| 1700 |
} |
| 1701 |
|
| 1702 |
% bx/sl -> bx/it |
| 1703 |
\bool_if:nT |
| 1704 |
{ |
| 1705 |
\str_if_eq_p:ee {#2} {\itdefault} && |
| 1706 |
!(\str_if_eq_p:ee {\itdefault} {\sldefault}) |
| 1707 |
} |
| 1708 |
{ |
| 1709 |
\__fontspec_DeclareFontShape:xxxxxx {\g__fontspec_nfss_enc_tl} {\g__fontspec_nfss_family_tl} |
| 1710 |
{bx} {\sldefault} |
| 1711 |
{ <->ssub*\g__fontspec_nfss_family_tl/bx/\itdefault } |
| 1712 |
{ \l__fontspec_postadjust_tl } |
| 1713 |
} |
| 1714 |
|
| 1715 |
} |
| 1716 |
} |
| 1717 |
\cs_new:Nn \__fontspec_declare_shape_loginfo:nn |
| 1718 |
{ |
| 1719 |
\tl_gput_right:Nx \g__fontspec_defined_shapes_tl |
| 1720 |
{ |
| 1721 |
\exp_not:n { \\ } |
| 1722 |
-~ \exp_not:N \str_case:nn {#1/#2} |
| 1723 |
{ |
| 1724 |
{\mddefault/\shapedefault} {'normal'~} |
| 1725 |
{\bfdefault/\shapedefault} {'bold'~} |
| 1726 |
{\mddefault/\itdefault} {'italic'~} |
| 1727 |
{\mddefault/\sldefault} {'slanted'~} |
| 1728 |
{\mddefault/\swdefault} {'swash'~} |
| 1729 |
{\bfdefault/\itdefault} {'bold~ italic'~} |
| 1730 |
{\bfdefault/\sldefault} {'bold~ slanted'~} |
| 1731 |
{\bfdefault/\swdefault} {'bold~ swash'~} |
| 1732 |
} (#1/#2)~ |
| 1733 |
with~ NFSS~ spec.:~ |
| 1734 |
\l__fontspec_nfss_tl |
| 1735 |
\tl_if_empty:NF \l__fontspec_nfss_sc_tl |
| 1736 |
{ |
| 1737 |
\exp_not:n { \\ } |
| 1738 |
-~ \exp_not:N \str_case:nn { #1 / \__fontspec_combo_sc_shape:n {#2} } |
| 1739 |
{ |
| 1740 |
{\mddefault/\scdefault} {'small~ caps'~} |
| 1741 |
{\bfdefault/\scdefault} {'bold~ small~ caps'~} |
| 1742 |
{\mddefault/\scitdefault} {'italic~ small~ caps'~} |
| 1743 |
{\bfdefault/\scitdefault} {'bold~ italic~ small~ caps'~} |
| 1744 |
{\mddefault/\scsldefault} {'slanted~ small~ caps'~} |
| 1745 |
{\bfdefault/\scsldefault} {'bold~ slanted~ small~ caps'~} |
| 1746 |
}~( #1 / \__fontspec_combo_sc_shape:n {#2} )~ |
| 1747 |
with~ NFSS~ spec.:~ |
| 1748 |
\l__fontspec_nfss_sc_tl |
| 1749 |
\tl_if_empty:fF {\l__fontspec_postadjust_tl} |
| 1750 |
{ |
| 1751 |
\exp_not:N \\ and~ font~ adjustment~ code: |
| 1752 |
\exp_not:N \\ \l__fontspec_postadjust_tl |
| 1753 |
} |
| 1754 |
} |
| 1755 |
} |
| 1756 |
} |
| 1757 |
\tl_set:Nn \l__fontspec_pre_feat_sclist |
| 1758 |
{ |
| 1759 |
\bool_if:NT \l__fontspec_ot_bool |
| 1760 |
{ |
| 1761 |
\tl_if_empty:NF \l__fontspec_script_tl { script = \l__fontspec_script_tl ; } |
| 1762 |
\tl_if_empty:NF \l__fontspec_lang_tl { language = \l__fontspec_lang_tl ; } |
| 1763 |
} |
| 1764 |
} |
| 1765 |
\cs_new:Nn \__fontspec_make_ot_smallcaps:TF |
| 1766 |
{ |
| 1767 |
\bool_set_false:N \l__fontspec_tmpa_bool |
| 1768 |
\exp_args:Ne \clist_map_inline:nn { \l__fontspec_lang_tl , \g__fontspec_default_langs_clist } |
| 1769 |
{ |
| 1770 |
\exp_args:Ne \clist_map_inline:nn { \l__fontspec_script_tl , \g__fontspec_default_scripts_clist } |
| 1771 |
{ |
| 1772 |
\exp_args:No \__fontspec_check_ot_feat:NnnnT \l__fontspec_fontface_cs_tl {smcp} {##1} {####1} |
| 1773 |
{ |
| 1774 |
\bool_set_true:N \l__fontspec_tmpa_bool |
| 1775 |
\clist_map_break: |
| 1776 |
} |
| 1777 |
} |
| 1778 |
} |
| 1779 |
\bool_if:NTF \l__fontspec_tmpa_bool {#1} {#2} |
| 1780 |
} |
| 1781 |
\cs_new:Nn \__fontspec_make_smallcaps:TF |
| 1782 |
{ |
| 1783 |
\bool_if:NTF \l__fontspec_ot_bool |
| 1784 |
{ \__fontspec_make_ot_smallcaps:TF {#1} {#2} } |
| 1785 |
{ |
| 1786 |
\bool_if:NT \l__fontspec_atsui_bool |
| 1787 |
{ |
| 1788 |
\exp_args:No \__fontspec_make_AAT_feature_string:NnnTF |
| 1789 |
\l__fontspec_fontface_cs_tl {3} {3} {#1} {#2} |
| 1790 |
} |
| 1791 |
} |
| 1792 |
} |
| 1793 |
\cs_new:Nn \__fontspec_update_featstr:n |
| 1794 |
{ |
| 1795 |
\bool_if:NF \l__fontspec_firsttime_bool |
| 1796 |
{ |
| 1797 |
\tl_gset:Nx \g__fontspec_single_feat_tl { #1 } |
| 1798 |
\tl_gput_right:Nx \g__fontspec_rawfeatures_sclist {#1;} |
| 1799 |
} |
| 1800 |
} |
| 1801 |
\cs_new:Nn \__fontspec_remove_clashing_featstr:n |
| 1802 |
{ |
| 1803 |
\clist_map_inline:nn {#1} |
| 1804 |
{ |
| 1805 |
\tl_gremove_all:Nn \g__fontspec_rawfeatures_sclist {##1;} |
| 1806 |
} |
| 1807 |
} |
| 1808 |
\cs_generate_variant:Nn \__fontspec_remove_clashing_featstr:n {x} |
| 1809 |
\cs_generate_variant:Nn \tl_tail:n { e } |
| 1810 |
\cs_new:Nn \__fontspec_format_axis:nn |
| 1811 |
{ |
| 1812 |
, #1 = #2 |
| 1813 |
} |
| 1814 |
\cs_new:Nn \__fontspec_get_variations: |
| 1815 |
{ |
| 1816 |
\tl_if_empty:NF \g__fontspec_instance_tl |
| 1817 |
{ |
| 1818 |
instance = { \g__fontspec_instance_tl }; |
| 1819 |
} |
| 1820 |
\prop_if_empty:NF \g__fontspec_rawvariations_prop |
| 1821 |
{ |
| 1822 |
axis = { |
| 1823 |
\tl_tail:e { |
| 1824 |
\prop_map_function:NN \g__fontspec_rawvariations_prop \__fontspec_format_axis:nn |
| 1825 |
} |
| 1826 |
}; |
| 1827 |
} |
| 1828 |
} |
| 1829 |
\cs_set:Npn \__fontspec_init: |
| 1830 |
{ |
| 1831 |
\bool_set_false:N \l__fontspec_ot_bool |
| 1832 |
\bool_set_true:N \l__fontspec_firsttime_bool |
| 1833 |
\__fontspec_font_is_name: |
| 1834 |
\tl_clear:N \l__fontspec_font_path_tl |
| 1835 |
\tl_clear:N \l__fontspec_optical_size_tl |
| 1836 |
\tl_clear:N \l__fontspec_ttc_index_tl |
| 1837 |
\tl_clear:N \l__fontspec_renderer_tl |
| 1838 |
\tl_gclear:N \g__fontspec_defined_shapes_tl |
| 1839 |
\tl_gclear:N \g__fontspec_curr_series_tl |
| 1840 |
\tl_gset_eq:NN \g__fontspec_nfss_enc_tl \g_fontspec_encoding_tl |
| 1841 |
} |
| 1842 |
\cs_new:Nn \__fontspec_init_fontface: |
| 1843 |
{ |
| 1844 |
\tl_gclear:N \g__fontspec_rawfeatures_sclist |
| 1845 |
\prop_gclear:N \g__fontspec_rawvariations_prop |
| 1846 |
\tl_gclear:N \g__fontspec_instance_tl |
| 1847 |
\tl_clear:N \l__fontspec_scale_tl |
| 1848 |
\tl_set_eq:NN \l__fontspec_opacity_tl \c__fontspec_opacity_tl |
| 1849 |
\tl_set_eq:NN \l__fontspec_hexcol_tl \c__fontspec_hexcol_tl |
| 1850 |
\tl_set_eq:NN \l__fontspec_postadjust_tl \c__fontspec_postadjust_tl |
| 1851 |
\tl_clear:N \l__fontspec_wordspace_adjust_tl |
| 1852 |
\tl_clear:N \l__fontspec_punctspace_adjust_tl |
| 1853 |
} |
| 1854 |
\cs_new:Nn \__fontspec_iv_str_to_num:Nn |
| 1855 |
{ |
| 1856 |
\__fontspec_strip_leading_sign:Nw #1#2 \q_nil |
| 1857 |
} |
| 1858 |
\cs_generate_variant:Nn \__fontspec_iv_str_to_num:Nn {Nx} |
| 1859 |
\cs_set:Npn \__fontspec_strip_leading_sign:Nw #1#2#3 \q_nil |
| 1860 |
{ |
| 1861 |
\bool_if:nTF { \str_if_eq_p:nn {#2} {+} || \str_if_eq_p:nn {#2} {-} } |
| 1862 |
{ \__fontspec_iv_str_to_num:w #1 \q_nil #3 \c_empty_tl \c_empty_tl \q_nil } |
| 1863 |
{ \__fontspec_iv_str_to_num:w #1 \q_nil #2#3 \c_empty_tl \c_empty_tl \q_nil } |
| 1864 |
} |
| 1865 |
\cs_set:Npn \__fontspec_iv_str_to_num:w #1 \q_nil #2#3#4#5#6 \q_nil |
| 1866 |
{ |
| 1867 |
\int_compare:nT { \tl_count:n {#6} > 2 } |
| 1868 |
{ \__fontspec_error:nx {ot-tag-too-long} {#2#3#4#5#6} } |
| 1869 |
|
| 1870 |
\int_set:Nn #1 |
| 1871 |
{ |
| 1872 |
`#2 * "1000000 |
| 1873 |
+ `#3 * "10000 |
| 1874 |
+ \ifx \c_empty_tl #4 32 \else `#4 \fi * "100 |
| 1875 |
+ \ifx \c_empty_tl #5 32 \else `#5 \fi |
| 1876 |
} |
| 1877 |
} |
| 1878 |
|
| 1879 |
%%^^A%% fontspec-code-opentype.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 1880 |
|
| 1881 |
\cs_new:Nn \__fontspec_define_opentype_variation_axis:nn |
| 1882 |
{ |
| 1883 |
\keys_define:nn {fontspec-opentype} |
| 1884 |
{ |
| 1885 |
#1 .code:n = { |
| 1886 |
\prop_gput:Nnn \g__fontspec_rawvariations_prop { #2 } { ##1 } |
| 1887 |
}, |
| 1888 |
#1 .value_required:n = true, |
| 1889 |
#1 .groups:n = {opentype}, |
| 1890 |
} |
| 1891 |
} |
| 1892 |
\cs_new:Nn \__fontspec_define_opentype_feature_group:n |
| 1893 |
{ |
| 1894 |
\keys_define:nn {fontspec-opentype} { #1 .multichoice: , .groups:n = {opentype} } |
| 1895 |
} |
| 1896 |
\cs_new:Nn \__fontspec_feat_prop_add:nn |
| 1897 |
{ |
| 1898 |
\tl_if_empty:nF {#1} |
| 1899 |
{ |
| 1900 |
\prop_if_in:NnF \g__fontspec_OT_features_prop {#1} |
| 1901 |
{ |
| 1902 |
\prop_gput:Nnn \g__fontspec_OT_features_prop {#1} {#2} |
| 1903 |
} |
| 1904 |
} |
| 1905 |
} |
| 1906 |
\cs_new:Nn \__fontspec_define_opentype_feature:nnnnn |
| 1907 |
{ |
| 1908 |
\__fontspec_feat_prop_add:nn {#3} {#1\,=\,#2} |
| 1909 |
\tl_if_empty:nTF {#4} |
| 1910 |
{ |
| 1911 |
\keys_define:nn {fontspec-opentype} |
| 1912 |
{ |
| 1913 |
#1/#2 .code:n = |
| 1914 |
{ \__fontspec_remove_clashing_featstr:n {#5} } , |
| 1915 |
#1/#2 .groups:n = {opentype} |
| 1916 |
} |
| 1917 |
} |
| 1918 |
{ |
| 1919 |
\keys_define:nn {fontspec-opentype} |
| 1920 |
{ |
| 1921 |
#1/#2 .code:n = |
| 1922 |
{ |
| 1923 |
\__fontspec_make_OT_feature:nnn {#3} {#4} {#5} |
| 1924 |
} , |
| 1925 |
#1/#2 .groups:n = {opentype} |
| 1926 |
} |
| 1927 |
} |
| 1928 |
} |
| 1929 |
\cs_new:Nn \__fontspec_feat_off:n {#1Off} |
| 1930 |
\cs_new:Nn \__fontspec_feat_reset:n {#1Reset} |
| 1931 |
\cs_new:Nn \__fontspec_define_opentype_onoffreset:nnnnn |
| 1932 |
{ |
| 1933 |
\exp_args:Nnx \__fontspec_define_opentype_feature:nnnnn {#1} {#2} {#3} {+#4} {#5} |
| 1934 |
\exp_args:Nnx \__fontspec_define_opentype_feature:nnnnn {#1} { \__fontspec_feat_off:n {#2} } {#3} {-#4} {} |
| 1935 |
\exp_args:Nnx \__fontspec_define_opentype_feature:nnnnn {#1} { \__fontspec_feat_reset:n {#2} } {} {} {+#4,-#4} |
| 1936 |
} |
| 1937 |
\cs_new:Nn \__fontspec_define_opentype_onreset:nnnnn |
| 1938 |
{ |
| 1939 |
\exp_args:Nnx \__fontspec_define_opentype_feature:nnnnn {#1} {#2} {#3} {#4} {#5} |
| 1940 |
\exp_args:Nnx \__fontspec_define_opentype_feature:nnnnn {#1} { \__fontspec_feat_reset:n {#2} } {} {} {#4} |
| 1941 |
} |
| 1942 |
\cs_new:Nn \__fontspec_make_OT_feature:nnn |
| 1943 |
{ |
| 1944 |
\__fontspec_remove_clashing_featstr:x { #2 , \__fontspec_swap_plus_minus:n {#2} , #3 } |
| 1945 |
\__fontspec_update_featstr:n {#2} |
| 1946 |
} |
| 1947 |
\cs_generate_variant:Nn \__fontspec_make_OT_feature:nnn {xxx} |
| 1948 |
\cs_new:Nn \__fontspec_swap_plus_minus:n { \__fontspec_swap_plus_minus_aux:Nq #1 \q_nil } |
| 1949 |
\cs_new:Npn \__fontspec_swap_plus_minus_aux:Nq #1#2 \q_nil |
| 1950 |
{ \str_case:nn {#1} { {+} {-#2} {-} {+#2} } } |
| 1951 |
\prg_new_conditional:Nnn \__fontspec_check_script:Nn {TF,T,F} |
| 1952 |
{ |
| 1953 |
\bool_if:NTF \l__fontspec_never_check_bool |
| 1954 |
{ \prg_return_true: } |
| 1955 |
{ |
| 1956 |
\bool_if:nTF { \tl_if_empty_p:e {#2} } |
| 1957 |
{ \prg_return_false: } |
| 1958 |
{ |
| 1959 |
\__fontspec_iv_str_to_num:Nx \l__fontspec_strnum_int {#2} |
| 1960 |
\int_set:Nn \l_tmpb_int { \XeTeXOTcountscripts #1 } |
| 1961 |
\int_zero:N \l_tmpa_int |
| 1962 |
\bool_set_false:N \l__fontspec_check_bool |
| 1963 |
\bool_until_do:nn { \int_compare_p:nNn \l_tmpa_int = \l_tmpb_int } |
| 1964 |
{ |
| 1965 |
\ifnum \XeTeXOTscripttag #1 \l_tmpa_int = \l__fontspec_strnum_int |
| 1966 |
\bool_set_true:N \l__fontspec_check_bool |
| 1967 |
\int_set:Nn \l_tmpa_int {\l_tmpb_int} |
| 1968 |
\else |
| 1969 |
\int_incr:N \l_tmpa_int |
| 1970 |
\fi |
| 1971 |
} |
| 1972 |
\bool_if:NTF \l__fontspec_check_bool \prg_return_true: \prg_return_false: |
| 1973 |
} |
| 1974 |
} |
| 1975 |
} |
| 1976 |
\prg_new_conditional:Nnn \__fontspec_check_lang:Nn {TF,F} |
| 1977 |
{ |
| 1978 |
\__fontspec_check_lang:NnnTF #1 {#2} {\l__fontspec_script_tl} {\prg_return_true:} {\prg_return_false:} |
| 1979 |
} |
| 1980 |
\prg_new_conditional:Nnn \__fontspec_check_lang:Nnn {TF} |
| 1981 |
{ |
| 1982 |
\bool_if:NTF \l__fontspec_never_check_bool |
| 1983 |
{ \prg_return_true: } |
| 1984 |
{ |
| 1985 |
\bool_if:nTF { \tl_if_empty_p:e {#3} } |
| 1986 |
{ \prg_return_false: } |
| 1987 |
{ |
| 1988 |
\__fontspec_iv_str_to_num:Nx \l__fontspec_strnum_int {#2} |
| 1989 |
\__fontspec_iv_str_to_num:Nx \l__fontspec_script_int {#3} |
| 1990 |
\int_set:Nn \l__fontspec_tmpb_int |
| 1991 |
{ \XeTeXOTcountlanguages #1 \l__fontspec_script_int } |
| 1992 |
\int_zero:N \l__fontspec_tmpa_int |
| 1993 |
\bool_set_false:N \l__fontspec_check_bool |
| 1994 |
\bool_until_do:nn { \int_compare_p:nNn \l__fontspec_tmpa_int = \l__fontspec_tmpb_int } |
| 1995 |
{ |
| 1996 |
\int_set:Nn \l__fontspec_tmpc_int |
| 1997 |
{ \XeTeXOTlanguagetag #1 \l__fontspec_script_int \l__fontspec_tmpa_int } |
| 1998 |
|
| 1999 |
\int_compare:nNnTF \l__fontspec_tmpc_int = \l__fontspec_strnum_int |
| 2000 |
{ |
| 2001 |
\bool_set_true:N \l__fontspec_check_bool |
| 2002 |
\int_set:Nn \l__fontspec_tmpa_int {\l__fontspec_tmpb_int} |
| 2003 |
} |
| 2004 |
{ |
| 2005 |
\int_incr:N \l__fontspec_tmpa_int |
| 2006 |
} |
| 2007 |
} |
| 2008 |
\bool_if:NTF \l__fontspec_check_bool \prg_return_true: \prg_return_false: |
| 2009 |
} |
| 2010 |
} |
| 2011 |
} |
| 2012 |
\prg_new_conditional:Nnn \__fontspec_check_ot_feat:Nnnn {TF,T,F} |
| 2013 |
{ |
| 2014 |
\bool_if:NTF \l__fontspec_never_check_bool |
| 2015 |
{ \prg_return_true: } |
| 2016 |
{ |
| 2017 |
\bool_if:nTF { \tl_if_empty_p:e {#3} || \tl_if_empty_p:e {#4} } |
| 2018 |
{ \prg_return_false: } |
| 2019 |
{ |
| 2020 |
\__fontspec_iv_str_to_num:Nx \l__fontspec_strnum_int {#2} |
| 2021 |
|
| 2022 |
\str_if_eq:eeTF {#3} {dflt} |
| 2023 |
{ \int_zero:N \l__fontspec_language_int } |
| 2024 |
{ \__fontspec_iv_str_to_num:Nx \l__fontspec_language_int {#3} } |
| 2025 |
\__fontspec_iv_str_to_num:Nx \l__fontspec_script_int {#4} |
| 2026 |
|
| 2027 |
\int_set:Nn \l_tmpb_int |
| 2028 |
{ \XeTeXOTcountfeatures #1 \l__fontspec_script_int \l__fontspec_language_int } |
| 2029 |
|
| 2030 |
\int_zero:N \l_tmpa_int |
| 2031 |
\bool_set_false:N \l__fontspec_check_bool |
| 2032 |
\bool_until_do:nn { \int_compare_p:nNn \l_tmpa_int = \l_tmpb_int } |
| 2033 |
{ |
| 2034 |
\ifnum\XeTeXOTfeaturetag #1 \l__fontspec_script_int \l__fontspec_language_int |
| 2035 |
\l_tmpa_int =\l__fontspec_strnum_int |
| 2036 |
\bool_set_true:N \l__fontspec_check_bool |
| 2037 |
\int_set:Nn \l_tmpa_int {\l_tmpb_int} |
| 2038 |
\else |
| 2039 |
\int_incr:N \l_tmpa_int |
| 2040 |
\fi |
| 2041 |
} |
| 2042 |
\bool_if:NTF \l__fontspec_check_bool \prg_return_true: \prg_return_false: |
| 2043 |
} |
| 2044 |
} |
| 2045 |
} |
| 2046 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {aalt}{Access~All~Alternates} |
| 2047 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {abvf}{Above-base~Forms} |
| 2048 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {abvm}{Above-base~Mark~Positioning} |
| 2049 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {abvs}{Above-base~Substitutions} |
| 2050 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {afrc}{Alternative~Fractions} |
| 2051 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {akhn}{Akhands} |
| 2052 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {blwf}{Below-base~Forms} |
| 2053 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {blwm}{Below-base~Mark~Positioning} |
| 2054 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {blws}{Below-base~Substitutions} |
| 2055 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {calt}{Contextual~Alternates} |
| 2056 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {case}{Case-Sensitive~Forms} |
| 2057 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ccmp}{Glyph~Composition~/~Decomposition} |
| 2058 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {cfar}{Conjunct~Form~After~Ro} |
| 2059 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {cjct}{Conjunct~Forms} |
| 2060 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {clig}{Contextual~Ligatures} |
| 2061 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {cpct}{Centered~CJK~Punctuation} |
| 2062 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {cpsp}{Capital~Spacing} |
| 2063 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {cswh}{Contextual~Swash} |
| 2064 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {curs}{Cursive~Positioning} |
| 2065 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {cvNN}{Character~Variant~$N$} |
| 2066 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {c2pc}{Petite~Capitals~From~Capitals} |
| 2067 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {c2sc}{Small~Capitals~From~Capitals} |
| 2068 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {dist}{Distances} |
| 2069 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {dlig}{Discretionary~Ligatures} |
| 2070 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {dnom}{Denominators} |
| 2071 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {dtls}{Dotless~Forms} |
| 2072 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {expt}{Expert~Forms} |
| 2073 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {falt}{Final~Glyph~on~Line~Alternates} |
| 2074 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {fin2}{Terminal~Forms~\#2} |
| 2075 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {fin3}{Terminal~Forms~\#3} |
| 2076 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {fina}{Terminal~Forms} |
| 2077 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {flac}{Flattened~accent~forms} |
| 2078 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {frac}{Fractions} |
| 2079 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {fwid}{Full~Widths} |
| 2080 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {half}{Half~Forms} |
| 2081 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {haln}{Halant~Forms} |
| 2082 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {halt}{Alternate~Half~Widths} |
| 2083 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {hist}{Historical~Forms} |
| 2084 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {hkna}{Horizontal~Kana~Alternates} |
| 2085 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {hlig}{Historical~Ligatures} |
| 2086 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {hngl}{Hangul} |
| 2087 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {hojo}{Hojo~Kanji~Forms} |
| 2088 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {hwid}{Half~Widths} |
| 2089 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {init}{Initial~Forms} |
| 2090 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {isol}{Isolated~Forms} |
| 2091 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ital}{Italics} |
| 2092 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {jalt}{Justification~Alternates} |
| 2093 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {jp78}{JIS78~Forms} |
| 2094 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {jp83}{JIS83~Forms} |
| 2095 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {jp90}{JIS90~Forms} |
| 2096 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {jp04}{JIS2004~Forms} |
| 2097 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {kern}{Kerning} |
| 2098 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {lfbd}{Left~Bounds} |
| 2099 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {liga}{Standard~Ligatures} |
| 2100 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ljmo}{Leading~Jamo~Forms} |
| 2101 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {lnum}{Lining~Figures} |
| 2102 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {locl}{Localized~Forms} |
| 2103 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ltra}{Left-to-right~alternates} |
| 2104 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ltrm}{Left-to-right~mirrored~forms} |
| 2105 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {mark}{Mark~Positioning} |
| 2106 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {med2}{Medial~Forms~\#2} |
| 2107 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {medi}{Medial~Forms} |
| 2108 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {mgrk}{Mathematical~Greek} |
| 2109 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {mkmk}{Mark~to~Mark~Positioning} |
| 2110 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {mset}{Mark~Positioning~via~Substitution} |
| 2111 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {nalt}{Alternate~Annotation~Forms} |
| 2112 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {nlck}{NLC~Kanji~Forms} |
| 2113 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {nukt}{Nukta~Forms} |
| 2114 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {numr}{Numerators} |
| 2115 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {onum}{Oldstyle~Figures} |
| 2116 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {opbd}{Optical~Bounds} |
| 2117 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ordn}{Ordinals} |
| 2118 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ornm}{Ornaments} |
| 2119 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {palt}{Proportional~Alternate~Widths} |
| 2120 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {pcap}{Petite~Capitals} |
| 2121 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {pkna}{Proportional~Kana} |
| 2122 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {pnum}{Proportional~Figures} |
| 2123 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {pref}{Pre-Base~Forms} |
| 2124 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {pres}{Pre-base~Substitutions} |
| 2125 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {pstf}{Post-base~Forms} |
| 2126 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {psts}{Post-base~Substitutions} |
| 2127 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {pwid}{Proportional~Widths} |
| 2128 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {qwid}{Quarter~Widths} |
| 2129 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {rand}{Randomize} |
| 2130 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {rclt}{Required~Contextual~Alternates} |
| 2131 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {rkrf}{Rakar~Forms} |
| 2132 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {rlig}{Required~Ligatures} |
| 2133 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {rphf}{Reph~Forms} |
| 2134 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {rtbd}{Right~Bounds} |
| 2135 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {rtla}{Right-to-left~alternates} |
| 2136 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {rtlm}{Right-to-left~mirrored~forms} |
| 2137 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ruby}{Ruby~Notation~Forms} |
| 2138 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {rvrn}{Required~Variation~Alternates} |
| 2139 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {salt}{Stylistic~Alternates} |
| 2140 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {sinf}{Scientific~Inferiors} |
| 2141 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {size}{Optical~size} |
| 2142 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {smcp}{Small~Capitals} |
| 2143 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {smpl}{Simplified~Forms} |
| 2144 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ssNN}{Stylistic~Set~$N$} |
| 2145 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {ssty}{Math~script~style~alternates} |
| 2146 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {stch}{Stretching~Glyph~Decomposition} |
| 2147 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {subs}{Subscript} |
| 2148 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {sups}{Superscript} |
| 2149 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {swsh}{Swash} |
| 2150 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {titl}{Titling} |
| 2151 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {tjmo}{Trailing~Jamo~Forms} |
| 2152 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {tnam}{Traditional~Name~Forms} |
| 2153 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {tnum}{Tabular~Figures} |
| 2154 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {trad}{Traditional~Forms} |
| 2155 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {twid}{Third~Widths} |
| 2156 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {unic}{Unicase} |
| 2157 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {valt}{Alternate~Vertical~Metrics} |
| 2158 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {vatu}{Vattu~Variants} |
| 2159 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {vert}{Vertical~Writing} |
| 2160 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {vhal}{Alternate~Vertical~Half~Metrics} |
| 2161 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {vjmo}{Vowel~Jamo~Forms} |
| 2162 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {vkna}{Vertical~Kana~Alternates} |
| 2163 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {vkrn}{Vertical~Kerning} |
| 2164 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {vpal}{Proportional~Alternate~Vertical~Metrics} |
| 2165 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {vrt2}{Vertical~Alternates~and~Rotation} |
| 2166 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {vrtr}{Vertical~Alternates~for~Rotation} |
| 2167 |
\prop_gput:Nnn \g__fontspec_all_opentype_feature_names_prop {zero}{Slashed~Zero} |
| 2168 |
|
| 2169 |
%%^^A%% fontspec-code-graphite.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 2170 |
|
| 2171 |
|
| 2172 |
\cs_new:Nn \__fontspec_define_aat_feature_group:n |
| 2173 |
{ |
| 2174 |
\keys_define:nn {fontspec-aat} { #1 .multichoice: } |
| 2175 |
} |
| 2176 |
\cs_new:Nn \__fontspec_define_aat_feature:nnnn |
| 2177 |
{ |
| 2178 |
\keys_define:nn {fontspec-aat} |
| 2179 |
{ |
| 2180 |
#1/#2 .code:n = { \__fontspec_make_AAT_feature:nn {#3}{#4} } |
| 2181 |
} |
| 2182 |
} |
| 2183 |
|
| 2184 |
\cs_new:Nn \__fontspec_make_AAT_feature:nn |
| 2185 |
{ |
| 2186 |
\tl_if_empty:nTF {#1} |
| 2187 |
{ \__fontspec_warning:n {aat-feature-not-exist} } |
| 2188 |
{ |
| 2189 |
\exp_args:No \__fontspec_make_AAT_feature_string:NnnTF \l__fontspec_fontface_cs_tl {#1} {#2} |
| 2190 |
{ |
| 2191 |
\__fontspec_update_featstr:n {\l_fontspec_feature_string_tl} |
| 2192 |
} |
| 2193 |
{ |
| 2194 |
\__fontspec_warning:nx {aat-feature-not-exist-in-font} {#1,#2} |
| 2195 |
} |
| 2196 |
} |
| 2197 |
} |
| 2198 |
\prg_new_conditional:Nnn \__fontspec_make_AAT_feature_string:Nnn {TF,T,F} |
| 2199 |
{ |
| 2200 |
\tl_set:Nx \l__fontspec_tmpa_tl { \XeTeXfeaturename #1 #2 } |
| 2201 |
\tl_if_empty:NTF \l__fontspec_tmpa_tl |
| 2202 |
{ \prg_return_false: } |
| 2203 |
{ |
| 2204 |
\int_compare:nTF { \XeTeXisexclusivefeature #1 #2 > 0 } |
| 2205 |
{ |
| 2206 |
\tl_set:Nx \l__fontspec_tmpb_tl {\XeTeXselectorname #1 #2\space #3} |
| 2207 |
} |
| 2208 |
{ |
| 2209 |
\int_if_even:nTF {#3} |
| 2210 |
{ |
| 2211 |
\tl_set:Nx \l__fontspec_tmpb_tl {\XeTeXselectorname #1 #2\space #3} |
| 2212 |
} |
| 2213 |
{ |
| 2214 |
\tl_set:Nx \l__fontspec_tmpb_tl |
| 2215 |
{ |
| 2216 |
\XeTeXselectorname #1 #2\space \numexpr#3-1\relax |
| 2217 |
} |
| 2218 |
\tl_if_empty:NF \l__fontspec_tmpb_tl { \tl_put_left:Nn \l__fontspec_tmpb_tl {!} } |
| 2219 |
} |
| 2220 |
} |
| 2221 |
|
| 2222 |
\tl_if_empty:NTF \l__fontspec_tmpb_tl |
| 2223 |
{ \prg_return_false: } |
| 2224 |
{ |
| 2225 |
\tl_set:Nx \l_fontspec_feature_string_tl { \l__fontspec_tmpa_tl = \l__fontspec_tmpb_tl } |
| 2226 |
\prg_return_true: |
| 2227 |
} |
| 2228 |
} |
| 2229 |
} |
| 2230 |
|
| 2231 |
%%^^A%% fontspec-code-keyval.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 2232 |
|
| 2233 |
\clist_gset:Nn \g__fontspec_all_keyval_modules_clist |
| 2234 |
{ |
| 2235 |
fontspec, fontspec-opentype, fontspec-aat, |
| 2236 |
fontspec-preparse, fontspec-preparse-cfg, fontspec-preparse-external, fontspec-preparse-nested, |
| 2237 |
fontspec-renderer |
| 2238 |
} |
| 2239 |
\cs_new:Nn \__fontspec_keys_define_code:nnn |
| 2240 |
{ |
| 2241 |
\keys_define:nn {#1} { #2 .code:n = {#3} } |
| 2242 |
} |
| 2243 |
\cs_new:Nn \__fontspec_aff_error:n |
| 2244 |
{ |
| 2245 |
\__fontspec_keys_define_code:nnn {fontspec-addfeatures} {#1} |
| 2246 |
{ \__fontspec_error:nx {not-in-addfontfeatures} {#1} } |
| 2247 |
} |
| 2248 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-cfg} {IgnoreFontspecFile} |
| 2249 |
{ |
| 2250 |
\bool_set_false:N \l__fontspec_fontcfg_bool |
| 2251 |
} |
| 2252 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {IgnoreFontspecFile} |
| 2253 |
{ |
| 2254 |
\bool_set_false:N \l__fontspec_fontcfg_bool |
| 2255 |
} |
| 2256 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {Path} |
| 2257 |
{ |
| 2258 |
\bool_set_true:N \l__fontspec_nobf_bool |
| 2259 |
\bool_set_true:N \l__fontspec_noit_bool |
| 2260 |
\tl_set:Nn \l__fontspec_font_path_tl {#1} |
| 2261 |
\__fontspec_font_is_file: |
| 2262 |
\keys_set:nn {fontspec-renderer} {Renderer=OpenType} |
| 2263 |
} |
| 2264 |
\aliasfontfeature{Path}{ExternalLocation} |
| 2265 |
\__fontspec_keys_define_code:nnn {fontspec} {Path} {} |
| 2266 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {Extension} |
| 2267 |
{ |
| 2268 |
\tl_set:Nn \l__fontspec_extension_tl {#1} |
| 2269 |
\bool_if:NF \l__fontspec_external_bool |
| 2270 |
{ |
| 2271 |
\keys_set:nn {fontspec-preparse-external} {Path} |
| 2272 |
} |
| 2273 |
} |
| 2274 |
\tl_clear:N \l__fontspec_extension_tl |
| 2275 |
\__fontspec_keys_define_code:nnn {fontspec} {Extension} {} |
| 2276 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {KpseOnly} |
| 2277 |
{ |
| 2278 |
\bool_set_true:N \l__fontspec_external_kpse_bool |
| 2279 |
\bool_if:NT \l__fontspec_external_bool \__fontspec_font_is_file: |
| 2280 |
} |
| 2281 |
\__fontspec_keys_define_code:nnn {fontspec} {KpseOnly} {} |
| 2282 |
\keys_define:nn {fontspec-renderer} |
| 2283 |
{ |
| 2284 |
Renderer .choices:nn = |
| 2285 |
{AAT,ICU,OpenType,Graphite,Full,Basic,Node,Base,HarfBuzz,Harfbuzz} |
| 2286 |
{ |
| 2287 |
\int_compare:nTF {\l_keys_choice_int <= 4} |
| 2288 |
{ |
| 2289 |
\tl_set:Nx \l__fontspec_renderer_tl |
| 2290 |
{ |
| 2291 |
\int_case:nn \l_keys_choice_int { 1 {/AAT} 2 {/OT} 3 {/OT} 4 {/GR} } |
| 2292 |
} |
| 2293 |
\tl_gset:Nx \g__fontspec_single_feat_tl { \l__fontspec_renderer_tl } |
| 2294 |
} |
| 2295 |
{ |
| 2296 |
\__fontspec_warning:nx {only-luatex-feature} {Renderer=Full/Basic/Node/Base/HarfBuzz} |
| 2297 |
} |
| 2298 |
} |
| 2299 |
} |
| 2300 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {Script} |
| 2301 |
{ |
| 2302 |
\tl_if_empty:NT \l__fontspec_renderer_tl { \keys_set:nn {fontspec-renderer} {Renderer=OpenType} } |
| 2303 |
\tl_set:Nn \l__fontspec_script_name_tl {#1} |
| 2304 |
} |
| 2305 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {Language} |
| 2306 |
{ |
| 2307 |
\tl_if_empty:NT \l__fontspec_renderer_tl { \keys_set:nn {fontspec-renderer} {Renderer=OpenType} } |
| 2308 |
\tl_set:Nn \l__fontspec_lang_name_tl {#1} |
| 2309 |
} |
| 2310 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {FontIndex} |
| 2311 |
{ |
| 2312 |
\str_if_eq:eeF { \str_lowercase:f {\l__fontspec_extension_tl} } {.ttc} |
| 2313 |
{ \__fontspec_warning:n {font-index-needs-ttc} } |
| 2314 |
\tl_set:Nn \l__fontspec_ttc_index_tl {:#1} |
| 2315 |
} |
| 2316 |
\__fontspec_keys_define_code:nnn {fontspec} {FontIndex} |
| 2317 |
{ |
| 2318 |
\tl_set:Nn \l__fontspec_ttc_index_tl {:#1} |
| 2319 |
} |
| 2320 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {UprightFont} |
| 2321 |
{ |
| 2322 |
\fontspec_complete_fontname:Nn \l__fontspec_fontname_up_tl {#1} |
| 2323 |
} |
| 2324 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {ItalicFont} |
| 2325 |
{ |
| 2326 |
\tl_if_empty:nTF {#1} |
| 2327 |
{ |
| 2328 |
\bool_set_true:N \l__fontspec_noit_bool |
| 2329 |
} |
| 2330 |
{ |
| 2331 |
\bool_set_false:N \l__fontspec_noit_bool |
| 2332 |
\fontspec_complete_fontname:Nn \l__fontspec_fontname_it_tl {#1} |
| 2333 |
} |
| 2334 |
} |
| 2335 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {SlantedFont} |
| 2336 |
{ |
| 2337 |
\fontspec_complete_fontname:Nn \l__fontspec_fontname_sl_tl {#1} |
| 2338 |
} |
| 2339 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {SwashFont} |
| 2340 |
{ |
| 2341 |
\fontspec_complete_fontname:Nn \l__fontspec_fontname_sw_tl {#1} |
| 2342 |
} |
| 2343 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {BoldFont} |
| 2344 |
{ |
| 2345 |
\tl_if_empty:nTF {#1} |
| 2346 |
{ |
| 2347 |
\bool_set_true:N \l__fontspec_nobf_bool |
| 2348 |
} |
| 2349 |
{ |
| 2350 |
\bool_set_false:N \l__fontspec_nobf_bool |
| 2351 |
\fontspec_complete_fontname:Nn \l__fontspec_curr_bfname_tl {#1} |
| 2352 |
|
| 2353 |
\seq_if_empty:NT \l__fontspec_bf_series_seq |
| 2354 |
{ |
| 2355 |
\tl_gset:Nx \g__fontspec_curr_series_tl {\bfdefault} |
| 2356 |
\seq_put_right:Nx \l__fontspec_bf_series_seq {\bfdefault} |
| 2357 |
} |
| 2358 |
|
| 2359 |
\tl_if_eq:oeT \g__fontspec_curr_series_tl {\bfdefault} |
| 2360 |
{ |
| 2361 |
\tl_set_eq:NN \l__fontspec_fontname_bf_tl \l__fontspec_curr_bfname_tl |
| 2362 |
} |
| 2363 |
|
| 2364 |
\prop_put:NeV \l__fontspec_nfss_prop {BoldFont-\g__fontspec_curr_series_tl} \l__fontspec_curr_bfname_tl |
| 2365 |
|
| 2366 |
|
| 2367 |
} |
| 2368 |
} |
| 2369 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {BoldItalicFont} |
| 2370 |
{ |
| 2371 |
\fontspec_complete_fontname:Nn \l__fontspec_fontname_bfit_tl {#1} |
| 2372 |
} |
| 2373 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {BoldSlantedFont} |
| 2374 |
{ |
| 2375 |
\fontspec_complete_fontname:Nn \l__fontspec_fontname_bfsl_tl {#1} |
| 2376 |
} |
| 2377 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-external} {BoldSwashFont} |
| 2378 |
{ |
| 2379 |
\fontspec_complete_fontname:Nn \l__fontspec_fontname_bfsw_tl {#1} |
| 2380 |
} |
| 2381 |
\__fontspec_keys_define_code:nnn {fontspec} {SmallCapsFont} |
| 2382 |
{ |
| 2383 |
\tl_if_empty:nTF {#1} |
| 2384 |
{ |
| 2385 |
\bool_set_true:N \l__fontspec_nosc_bool |
| 2386 |
} |
| 2387 |
{ |
| 2388 |
\bool_set_false:N \l__fontspec_nosc_bool |
| 2389 |
\fontspec_complete_fontname:Nn \l__fontspec_fontname_sc_tl {#1} |
| 2390 |
} |
| 2391 |
} |
| 2392 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {UprightFeatures} |
| 2393 |
{ |
| 2394 |
\clist_put_right:Nn \l__fontspec_fontfeat_up_clist {#1} |
| 2395 |
} |
| 2396 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {BoldFeatures} |
| 2397 |
{ |
| 2398 |
\clist_put_right:Nn \l__fontspec_fontfeat_bf_clist {#1} |
| 2399 |
} |
| 2400 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {ItalicFeatures} |
| 2401 |
{ |
| 2402 |
\clist_put_right:Nn \l__fontspec_fontfeat_it_clist {#1} |
| 2403 |
} |
| 2404 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {BoldItalicFeatures} |
| 2405 |
{ |
| 2406 |
\clist_put_right:Nn \l__fontspec_fontfeat_bfit_clist {#1} |
| 2407 |
} |
| 2408 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {SlantedFeatures} |
| 2409 |
{ |
| 2410 |
\clist_put_right:Nn \l__fontspec_fontfeat_sl_clist {#1} |
| 2411 |
} |
| 2412 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {BoldSlantedFeatures} |
| 2413 |
{ |
| 2414 |
\clist_put_right:Nn \l__fontspec_fontfeat_bfsl_clist {#1} |
| 2415 |
} |
| 2416 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {SwashFeatures} |
| 2417 |
{ |
| 2418 |
\clist_put_right:Nn \l__fontspec_fontfeat_sw_clist {#1} |
| 2419 |
} |
| 2420 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {BoldSwashFeatures} |
| 2421 |
{ |
| 2422 |
\clist_put_right:Nn \l__fontspec_fontfeat_bfsw_clist {#1} |
| 2423 |
} |
| 2424 |
\__fontspec_keys_define_code:nnn {fontspec} {SmallCapsFeatures} |
| 2425 |
{ |
| 2426 |
\bool_if:NF \l__fontspec_firsttime_bool |
| 2427 |
{ |
| 2428 |
\clist_put_right:Nn \l__fontspec_fontfeat_sc_clist {#1} |
| 2429 |
} |
| 2430 |
} |
| 2431 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {SizeFeatures} |
| 2432 |
{ |
| 2433 |
\clist_set:Nn \l__fontspec_sizefeat_clist {#1} |
| 2434 |
\clist_put_right:Nn \l__fontspec_fontfeat_up_clist { SizeFeatures = {#1} } |
| 2435 |
} |
| 2436 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-nested} {SizeFeatures} |
| 2437 |
{ |
| 2438 |
\clist_set:Nn \l__fontspec_sizefeat_clist {#1} |
| 2439 |
\tl_if_empty:NT \l__fontspec_this_font_tl |
| 2440 |
{ \tl_set:Nn \l__fontspec_this_font_tl { -- } } % needs to be non-empty as a flag |
| 2441 |
} |
| 2442 |
\__fontspec_keys_define_code:nnn {fontspec-preparse-nested} {Font} |
| 2443 |
{ |
| 2444 |
\tl_set:Nn \l__fontspec_this_font_tl {#1} |
| 2445 |
} |
| 2446 |
\__fontspec_keys_define_code:nnn {fontspec} {SizeFeatures} |
| 2447 |
{ |
| 2448 |
% dummy |
| 2449 |
} |
| 2450 |
\__fontspec_keys_define_code:nnn {fontspec} {Font} |
| 2451 |
{ |
| 2452 |
% dummy |
| 2453 |
} |
| 2454 |
\__fontspec_keys_define_code:nnn {fontspec-sizing} {Size} |
| 2455 |
{ |
| 2456 |
\tl_set:Nn \l__fontspec_size_tl {#1} |
| 2457 |
} |
| 2458 |
\__fontspec_keys_define_code:nnn {fontspec-sizing} {Font} |
| 2459 |
{ |
| 2460 |
\fontspec_complete_fontname:Nn \l__fontspec_sizedfont_tl {#1} |
| 2461 |
} |
| 2462 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {UprightFont} {} |
| 2463 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {ItalicFont} {} |
| 2464 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {SlantedFont} {} |
| 2465 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {BoldFont} {} |
| 2466 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {BoldItalicFont} {} |
| 2467 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {BoldSlantedFont} {} |
| 2468 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {NFSSEncoding} |
| 2469 |
{ |
| 2470 |
\tl_gset:Nx \g__fontspec_nfss_enc_tl { #1 } |
| 2471 |
} |
| 2472 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {NFSSFamily} |
| 2473 |
{ |
| 2474 |
\tl_set:Nx \l__fontspec_nfss_fam_tl { #1 } |
| 2475 |
} |
| 2476 |
\__fontspec_keys_define_code:nnn {fontspec-preparse} {FontFace} |
| 2477 |
{ |
| 2478 |
\tl_clear:N \l__fontspec_this_font_tl |
| 2479 |
\clist_set:No \l__fontspec_arg_clist { \use_iii:nnn #1 } |
| 2480 |
\clist_set_eq:NN \l__fontspec_this_feat_clist \l__fontspec_arg_clist |
| 2481 |
\int_compare:nT { \clist_count:N \l__fontspec_arg_clist = 1 } |
| 2482 |
{ |
| 2483 |
\tl_if_in:NnF \l__fontspec_arg_clist {=} |
| 2484 |
{ |
| 2485 |
\tl_set_eq:NN \l__fontspec_this_font_tl \l__fontspec_arg_clist |
| 2486 |
\tl_clear:N \l__fontspec_this_feat_clist |
| 2487 |
} |
| 2488 |
} |
| 2489 |
|
| 2490 |
\__fontspec_add_nfssfont:nnnn |
| 2491 |
{\use_i:nnn #1} {\use_ii:nnn #1} {\l__fontspec_this_font_tl} {\l__fontspec_this_feat_clist} |
| 2492 |
} |
| 2493 |
\__fontspec_keys_define_code:nnn {fontspec} {Scale} |
| 2494 |
{ |
| 2495 |
\str_case:nnF {#1} |
| 2496 |
{ |
| 2497 |
{MatchLowercase} { \__fontspec_calc_scale:n {5} } |
| 2498 |
{MatchUppercase} { \__fontspec_calc_scale:n {8} } |
| 2499 |
{MatchAveragecase} { \__fontspec_calc_scale:nn {5} {8} } |
| 2500 |
} |
| 2501 |
{ \tl_set:Nx \l__fontspec_scale_tl {#1} } |
| 2502 |
\__fontspec_info:n {set-scale} |
| 2503 |
} |
| 2504 |
\__fontspec_keys_define_code:nnn {fontspec} {ScaleAgain} |
| 2505 |
{ |
| 2506 |
\tl_if_empty:NT \l__fontspec_scale_tl { \tl_set:Nn \l__fontspec_scale_tl {1} } |
| 2507 |
\tl_set:Nx \l__fontspec_scale_tl { \fp_eval:n { #1 * \l__fontspec_scale_tl } } |
| 2508 |
\__fontspec_info:n {set-scale} |
| 2509 |
} |
| 2510 |
\cs_new:Nn \__fontspec_calc_scale:n |
| 2511 |
{ |
| 2512 |
\group_begin: |
| 2513 |
|
| 2514 |
\fontencoding { \encodingdefault } |
| 2515 |
\fontfamily { \familydefault } |
| 2516 |
\selectfont |
| 2517 |
|
| 2518 |
\__fontspec_set_font_dimen:NnN \l__fontspec_tmpa_dim {#1} \font |
| 2519 |
\__fontspec_set_font_dimen:NnN \l__fontspec_tmpb_dim {#1} \l__fontspec_fontface_cs_tl |
| 2520 |
|
| 2521 |
\tl_set:Nx \l__fontspec_scale_tl |
| 2522 |
{ |
| 2523 |
\fp_eval:n { \dim_to_fp:n {\l__fontspec_tmpa_dim} / |
| 2524 |
\dim_to_fp:n {\l__fontspec_tmpb_dim} } |
| 2525 |
} |
| 2526 |
|
| 2527 |
\exp_args:NNNx |
| 2528 |
\group_end: |
| 2529 |
\tl_set:Nx \l__fontspec_scale_tl { \l__fontspec_scale_tl } |
| 2530 |
} |
| 2531 |
\cs_new:Nn \__fontspec_calc_scale:nn |
| 2532 |
{ |
| 2533 |
\group_begin: |
| 2534 |
\__fontspec_calc_scale:n {#1} |
| 2535 |
\tl_set_eq:NN \l__fontspec_tmp_tl \l__fontspec_scale_tl |
| 2536 |
\__fontspec_calc_scale:n {#2} |
| 2537 |
\tl_set:Nx \l__fontspec_scale_tl |
| 2538 |
{ |
| 2539 |
\fp_eval:n { (\l__fontspec_tmp_tl + \l__fontspec_scale_tl)/2 } |
| 2540 |
} |
| 2541 |
\exp_args:NNNx |
| 2542 |
\group_end: |
| 2543 |
\tl_set:Nx \l__fontspec_scale_tl { \l__fontspec_scale_tl } |
| 2544 |
} |
| 2545 |
\cs_new:Nn \__fontspec_set_font_dimen:NnN |
| 2546 |
{ |
| 2547 |
\dim_set:Nn #1 { \fontdimen #2 #3 } |
| 2548 |
\dim_compare:nNnT #1 = {0pt} |
| 2549 |
{ |
| 2550 |
\settoheight #1 |
| 2551 |
{ |
| 2552 |
\str_if_eq:nnTF {#3} {\font} \rmfamily #3 |
| 2553 |
\int_case:nnF #2 |
| 2554 |
{ |
| 2555 |
{5} {x} % x-height |
| 2556 |
{8} {X} % cap-height |
| 2557 |
} {?} % "else" clause; never reached. |
| 2558 |
} |
| 2559 |
} |
| 2560 |
} |
| 2561 |
\__fontspec_keys_define_code:nnn {fontspec} {WordSpace} |
| 2562 |
{ |
| 2563 |
\bool_if:NF \l__fontspec_firsttime_bool |
| 2564 |
{ \_fontspec_parse_wordspace:w #1,,,\q_stop } |
| 2565 |
} |
| 2566 |
\__fontspec_aff_error:n {WordSpace} |
| 2567 |
\cs_set:Npn \_fontspec_parse_wordspace:w #1,#2,#3,#4 \q_stop |
| 2568 |
{ |
| 2569 |
\tl_if_empty:nTF {#4} |
| 2570 |
{ |
| 2571 |
\tl_set:Nn \l__fontspec_wordspace_adjust_tl |
| 2572 |
{ |
| 2573 |
\fontdimen 2 \font = #1 \fontdimen 2 \font |
| 2574 |
\fontdimen 3 \font = #1 \fontdimen 3 \font |
| 2575 |
\fontdimen 4 \font = #1 \fontdimen 4 \font |
| 2576 |
} |
| 2577 |
} |
| 2578 |
{ |
| 2579 |
\tl_set:Nn \l__fontspec_wordspace_adjust_tl |
| 2580 |
{ |
| 2581 |
\fontdimen 2 \font = #1 \fontdimen 2 \font |
| 2582 |
\fontdimen 3 \font = #2 \fontdimen 3 \font |
| 2583 |
\fontdimen 4 \font = #3 \fontdimen 4 \font |
| 2584 |
} |
| 2585 |
} |
| 2586 |
} |
| 2587 |
\__fontspec_keys_define_code:nnn {fontspec} {PunctuationSpace} |
| 2588 |
{ |
| 2589 |
\str_case_e:nnF {#1} |
| 2590 |
{ |
| 2591 |
{WordSpace} |
| 2592 |
{ |
| 2593 |
\tl_set:Nn \l__fontspec_punctspace_adjust_tl |
| 2594 |
{ \fontdimen 7 \font = 0 \fontdimen 2 \font } |
| 2595 |
} |
| 2596 |
{TwiceWordSpace} |
| 2597 |
{ |
| 2598 |
\tl_set:Nn \l__fontspec_punctspace_adjust_tl |
| 2599 |
{ \fontdimen 7 \font = 1 \fontdimen 2 \font } |
| 2600 |
} |
| 2601 |
} |
| 2602 |
{ |
| 2603 |
\tl_set:Nn \l__fontspec_punctspace_adjust_tl |
| 2604 |
{ \fontdimen 7 \font = #1 \fontdimen 7 \font } |
| 2605 |
} |
| 2606 |
} |
| 2607 |
\__fontspec_aff_error:n {PunctuationSpace} |
| 2608 |
\__fontspec_keys_define_code:nnn {fontspec} {FontAdjustment} |
| 2609 |
{ |
| 2610 |
\tl_put_right:Nx \l__fontspec_postadjust_tl {#1} |
| 2611 |
} |
| 2612 |
\__fontspec_keys_define_code:nnn {fontspec} {LetterSpace} |
| 2613 |
{ |
| 2614 |
\__fontspec_update_featstr:n {letterspace=#1} |
| 2615 |
} |
| 2616 |
\__fontspec_keys_define_code:nnn {fontspec} {HyphenChar} |
| 2617 |
{ |
| 2618 |
\str_if_eq:nnTF {#1} {None} |
| 2619 |
{ |
| 2620 |
\tl_put_right:Nn \l__fontspec_postadjust_tl |
| 2621 |
{ \__fontspec_primitive_font_set_hyphenchar:Nn \font {-1} } |
| 2622 |
} |
| 2623 |
{ |
| 2624 |
|
| 2625 |
\tl_if_single:nTF {#1} |
| 2626 |
{ \tl_set:Nn \l__fontspec_hyphenchar_tl {`#1} } |
| 2627 |
{ \tl_set:Nn \l__fontspec_hyphenchar_tl { #1} } |
| 2628 |
|
| 2629 |
\exp_args:No \__fontspec_primitive_font_glyph_if_exist:NnTF \l__fontspec_fontface_cs_tl {\l__fontspec_hyphenchar_tl} |
| 2630 |
{ |
| 2631 |
\tl_put_right:Nn \l__fontspec_postadjust_tl |
| 2632 |
{ \__fontspec_primitive_font_set_hyphenchar:Nn \font { \l__fontspec_hyphenchar_tl } } |
| 2633 |
} |
| 2634 |
{ \__fontspec_error:nxx {no-glyph}{\l_fontspec_fontname_tl}{#1} } |
| 2635 |
|
| 2636 |
} |
| 2637 |
} |
| 2638 |
\__fontspec_aff_error:n {HyphenChar} |
| 2639 |
\__fontspec_keys_define_code:nnn {fontspec} {Color} |
| 2640 |
{ |
| 2641 |
\color_if_exist:nTF {#1} |
| 2642 |
{ |
| 2643 |
\color_export:nnN {#1} {HTML}\l__fontspec_hexcol_tl |
| 2644 |
} |
| 2645 |
{ |
| 2646 |
\cs_if_exist:cTF { \token_to_str:N \color@ #1 } |
| 2647 |
{ |
| 2648 |
\convertcolorspec{named}{#1}{HTML}\l__fontspec_hexcol_tl |
| 2649 |
} |
| 2650 |
{ |
| 2651 |
\int_compare:nTF { \tl_count:n {#1} == 6 } |
| 2652 |
{ \tl_set:Nn \l__fontspec_hexcol_tl {#1} } |
| 2653 |
{ |
| 2654 |
\int_compare:nTF { \tl_count:n {#1} == 8 } |
| 2655 |
{ \fontspec_parse_colour:viii #1 } |
| 2656 |
{ |
| 2657 |
\bool_if:NF \l__fontspec_firsttime_bool |
| 2658 |
{ \__fontspec_warning:nx {bad-colour} {#1} } |
| 2659 |
} |
| 2660 |
} |
| 2661 |
} |
| 2662 |
} |
| 2663 |
} |
| 2664 |
\cs_set:Npn \fontspec_parse_colour:viii #1#2#3#4#5#6#7#8 |
| 2665 |
{ |
| 2666 |
\tl_set:Nn \l__fontspec_hexcol_tl {#1#2#3#4#5#6} |
| 2667 |
\tl_if_eq:NNF \l__fontspec_opacity_tl \c__fontspec_opacity_tl |
| 2668 |
{ |
| 2669 |
\bool_if:NF \l__fontspec_firsttime_bool |
| 2670 |
{ \__fontspec_warning:nx {opa-twice-col} {#7#8} } |
| 2671 |
} |
| 2672 |
\tl_set:Nn \l__fontspec_opacity_tl {#7#8} |
| 2673 |
} |
| 2674 |
\aliasfontfeature{Color}{Colour} |
| 2675 |
\__fontspec_keys_define_code:nnn {fontspec} {Opacity} |
| 2676 |
{ |
| 2677 |
\int_set:Nn \l__fontspec_tmp_int {255} |
| 2678 |
\__fontspec_int_mult_truncate:Nn \l__fontspec_tmp_int { #1 } |
| 2679 |
\tl_if_eq:NNF \l__fontspec_opacity_tl \c__fontspec_opacity_tl |
| 2680 |
{ |
| 2681 |
\bool_if:NF \l__fontspec_firsttime_bool |
| 2682 |
{ \__fontspec_warning:nx {opa-twice} {#1} } |
| 2683 |
} |
| 2684 |
\tl_set:Nx \l__fontspec_opacity_tl |
| 2685 |
{ |
| 2686 |
\int_compare:nT { \l__fontspec_tmp_int <= "F } {0} % zero pad |
| 2687 |
\int_to_hex:n { \l__fontspec_tmp_int } |
| 2688 |
} |
| 2689 |
} |
| 2690 |
\__fontspec_keys_define_code:nnn {fontspec-aat} {Mapping} |
| 2691 |
{ |
| 2692 |
\tl_set:Nn \l__fontspec_mapping_tl { #1 } |
| 2693 |
} |
| 2694 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {Mapping} |
| 2695 |
{ |
| 2696 |
\tl_set:Nn \l__fontspec_mapping_tl { #1 } |
| 2697 |
} |
| 2698 |
\__fontspec_keys_define_code:nnn {fontspec} {Weight} |
| 2699 |
{ |
| 2700 |
\__fontspec_update_featstr:n{weight=#1} |
| 2701 |
} |
| 2702 |
\__fontspec_keys_define_code:nnn {fontspec} {Width} |
| 2703 |
{ |
| 2704 |
\__fontspec_update_featstr:n{width=#1} |
| 2705 |
} |
| 2706 |
\__fontspec_define_opentype_variation_axis:nn {Slant} {slnt} |
| 2707 |
\__fontspec_keys_define_code:nnn {fontspec} {OpticalSize} |
| 2708 |
{ |
| 2709 |
\bool_if:NTF \l__fontspec_ot_bool |
| 2710 |
{ |
| 2711 |
\tl_set:Nn \l__fontspec_optical_size_tl {/ S = #1} |
| 2712 |
} |
| 2713 |
{ |
| 2714 |
\bool_if:NT \l__fontspec_mm_bool |
| 2715 |
{ |
| 2716 |
\__fontspec_update_featstr:n { optical size = #1 } |
| 2717 |
} |
| 2718 |
} |
| 2719 |
\bool_if:nT { !\l__fontspec_ot_bool && !\l__fontspec_mm_bool } |
| 2720 |
{ |
| 2721 |
\bool_if:NT \l__fontspec_firsttime_bool |
| 2722 |
{ \__fontspec_warning:nx {no-opticals} {\l_fontspec_fontname_tl} } |
| 2723 |
} |
| 2724 |
} |
| 2725 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {RawAxis} |
| 2726 |
{ |
| 2727 |
\prop_gput_from_keyval:Nn \g__fontspec_rawvariations_prop {#1} |
| 2728 |
} |
| 2729 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {Instance} |
| 2730 |
{ |
| 2731 |
\tl_gset:Nn \g__fontspec_instance_tl {#1} |
| 2732 |
} |
| 2733 |
\keys_define:nn {fontspec} |
| 2734 |
{ |
| 2735 |
FakeSlant .code:n = |
| 2736 |
{ |
| 2737 |
\__fontspec_update_featstr:n {slant=#1} |
| 2738 |
}, |
| 2739 |
FakeSlant .default:n = {0.2} |
| 2740 |
} |
| 2741 |
\keys_define:nn {fontspec} |
| 2742 |
{ |
| 2743 |
FakeStretch .code:n = |
| 2744 |
{ |
| 2745 |
\__fontspec_update_featstr:n {extend=#1} |
| 2746 |
}, |
| 2747 |
FakeStretch .default:n = {1.2} |
| 2748 |
} |
| 2749 |
\keys_define:nn {fontspec} |
| 2750 |
{ |
| 2751 |
FakeBold .code:n = |
| 2752 |
{ |
| 2753 |
\__fontspec_update_featstr:n {embolden=#1} |
| 2754 |
}, |
| 2755 |
FakeBold .default:n = {1.5} |
| 2756 |
} |
| 2757 |
\keys_define:nn {fontspec} |
| 2758 |
{ |
| 2759 |
AutoFakeSlant .code:n = |
| 2760 |
{ |
| 2761 |
\bool_if:NT \l__fontspec_firsttime_bool |
| 2762 |
{ |
| 2763 |
\tl_set:Nn \l__fontspec_fake_slant_tl {#1} |
| 2764 |
\clist_put_right:Nn \l__fontspec_fontfeat_it_clist {FakeSlant=#1} |
| 2765 |
\tl_set_eq:NN \l__fontspec_fontname_it_tl \l_fontspec_fontname_tl |
| 2766 |
\bool_set_false:N \l__fontspec_noit_bool |
| 2767 |
|
| 2768 |
\tl_if_empty:NF \l__fontspec_fake_embolden_tl |
| 2769 |
{ |
| 2770 |
\clist_put_right:Nx \l__fontspec_fontfeat_bfit_clist |
| 2771 |
{FakeBold=\l__fontspec_fake_embolden_tl} |
| 2772 |
\clist_put_right:Nx \l__fontspec_fontfeat_bfit_clist {FakeSlant=#1} |
| 2773 |
\tl_set_eq:NN \l__fontspec_fontname_bfit_tl \l_fontspec_fontname_tl |
| 2774 |
} |
| 2775 |
} |
| 2776 |
}, |
| 2777 |
AutoFakeSlant .default:n = {0.2} |
| 2778 |
} |
| 2779 |
\keys_define:nn {fontspec} |
| 2780 |
{ |
| 2781 |
AutoFakeBold .code:n = |
| 2782 |
{ |
| 2783 |
\bool_if:NT \l__fontspec_firsttime_bool |
| 2784 |
{ |
| 2785 |
\tl_set:Nn \l__fontspec_fake_embolden_tl {#1} |
| 2786 |
\clist_put_right:Nn \l__fontspec_fontfeat_bf_clist {FakeBold=#1} |
| 2787 |
\tl_set_eq:NN \l__fontspec_fontname_bf_tl \l_fontspec_fontname_tl |
| 2788 |
\bool_set_false:N \l__fontspec_nobf_bool |
| 2789 |
|
| 2790 |
\tl_if_empty:NF \l__fontspec_fake_slant_tl |
| 2791 |
{ |
| 2792 |
\clist_put_right:Nx \l__fontspec_fontfeat_bfit_clist |
| 2793 |
{FakeSlant=\l__fontspec_fake_slant_tl} |
| 2794 |
\clist_put_right:Nx \l__fontspec_fontfeat_bfit_clist {FakeBold=#1} |
| 2795 |
\tl_set_eq:NN \l__fontspec_fontname_bfit_tl \l_fontspec_fontname_tl |
| 2796 |
} |
| 2797 |
} |
| 2798 |
}, |
| 2799 |
AutoFakeBold .default:n = {1.5} |
| 2800 |
} |
| 2801 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} {RawFeature} |
| 2802 |
{ |
| 2803 |
\__fontspec_update_featstr:n {#1} |
| 2804 |
} |
| 2805 |
\__fontspec_keys_define_code:nnn {fontspec-aat} {RawFeature} |
| 2806 |
{ |
| 2807 |
\__fontspec_update_featstr:n {#1} |
| 2808 |
} |
| 2809 |
|
| 2810 |
%%^^A%% fontspec-code-feat-opentype.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 2811 |
|
| 2812 |
\__fontspec_feat_prop_add:nn {salt} { Alternate\,=\,$N$ } |
| 2813 |
\__fontspec_feat_prop_add:nn {nalt} { Annotation\,=\,$N$ } |
| 2814 |
\__fontspec_feat_prop_add:nn {ornm} { Ornament\,=\,$N$ } |
| 2815 |
\__fontspec_feat_prop_add:nn {cvNN} { CharacterVariant\,=\,$N$:$M$ } |
| 2816 |
\__fontspec_feat_prop_add:nn {ssNN} { StylisticSet\,=\,$N$ } |
| 2817 |
\__fontspec_define_opentype_feature_group:n {Ligatures} |
| 2818 |
\__fontspec_define_opentype_feature:nnnnn {Ligatures} {ResetAll} {} {} |
| 2819 |
{ |
| 2820 |
+dlig,-dlig,+rlig,-rlig,+liga,-liga,+dlig,-dlig,+clig,-clig,+hlig,-hlig, |
| 2821 |
mapping = tex-text |
| 2822 |
} |
| 2823 |
\__fontspec_define_opentype_onoffreset:nnnnn {Ligatures} {Required} {rlig} {rlig} {} |
| 2824 |
\__fontspec_define_opentype_onoffreset:nnnnn {Ligatures} {Common} {liga} {liga} {} |
| 2825 |
\__fontspec_define_opentype_onoffreset:nnnnn {Ligatures} {Rare} {dlig} {dlig} {} |
| 2826 |
\__fontspec_define_opentype_onoffreset:nnnnn {Ligatures} {Discretionary} {dlig} {dlig} {} |
| 2827 |
\__fontspec_define_opentype_onoffreset:nnnnn {Ligatures} {Contextual} {clig} {clig} {} |
| 2828 |
\__fontspec_define_opentype_onoffreset:nnnnn {Ligatures} {Historic} {hlig} {hlig} {} |
| 2829 |
\keys_define:nn {fontspec-opentype} |
| 2830 |
{ |
| 2831 |
Ligatures / TeX .code:n = { \tl_set:Nn \l__fontspec_mapping_tl {tex-text} }, |
| 2832 |
Ligatures / TeXOff .code:n = { \tl_clear:N \l__fontspec_mapping_tl }, |
| 2833 |
Ligatures / TeXReset .code:n = { \tl_clear:N \l__fontspec_mapping_tl }, |
| 2834 |
} |
| 2835 |
\__fontspec_define_opentype_feature_group:n {Letters} |
| 2836 |
\__fontspec_define_opentype_feature:nnnnn {Letters} {ResetAll} {} {} |
| 2837 |
{ |
| 2838 |
+smcp,+pcap,+c2sc,+c2pc,+unic,+rand, |
| 2839 |
-smcp,-pcap,-c2sc,-c2pc,-unic,-rand |
| 2840 |
} |
| 2841 |
\__fontspec_define_opentype_onoffreset:nnnnn {Letters} {SmallCaps} {smcp} {smcp} {+pcap,+unic} |
| 2842 |
\__fontspec_define_opentype_onoffreset:nnnnn {Letters} {PetiteCaps} {pcap} {pcap} {+smcp,+unic} |
| 2843 |
\__fontspec_define_opentype_onoffreset:nnnnn {Letters} {UppercaseSmallCaps} {c2sc} {c2sc} {+c2pc,+unic} |
| 2844 |
\__fontspec_define_opentype_onoffreset:nnnnn {Letters} {UppercasePetiteCaps} {c2pc} {c2pc} {+c2sc,+unic} |
| 2845 |
\__fontspec_define_opentype_onoffreset:nnnnn {Letters} {Unicase} {unic} {unic} {} |
| 2846 |
\__fontspec_define_opentype_onoffreset:nnnnn {Letters} {Random} {rand} {rand} {} |
| 2847 |
\__fontspec_define_opentype_feature_group:n {Numbers} |
| 2848 |
\__fontspec_define_opentype_feature:nnnnn {Numbers} {ResetAll} {} {} |
| 2849 |
{ |
| 2850 |
+tnum,-tnum, |
| 2851 |
+pnum,-pnum, |
| 2852 |
+onum,-onum, |
| 2853 |
+lnum,-lnum, |
| 2854 |
+zero,-zero, |
| 2855 |
+anum,-anum, |
| 2856 |
} |
| 2857 |
\__fontspec_define_opentype_onoffreset:nnnnn {Numbers} {Monospaced} {tnum} {tnum} {+pnum,-pnum} |
| 2858 |
\__fontspec_define_opentype_onoffreset:nnnnn {Numbers} {Proportional} {pnum} {pnum} {+tnum,-tnum} |
| 2859 |
\__fontspec_define_opentype_onoffreset:nnnnn {Numbers} {Lowercase} {onum} {onum} {+lnum,-lnum} |
| 2860 |
\__fontspec_define_opentype_onoffreset:nnnnn {Numbers} {Uppercase} {lnum} {lnum} {+onum,-onum} |
| 2861 |
\__fontspec_define_opentype_onoffreset:nnnnn {Numbers} {SlashedZero} {zero} {zero} {} |
| 2862 |
\aliasfontfeatureoption {Numbers} {Monospaced} {Tabular} |
| 2863 |
\aliasfontfeatureoption {Numbers} {Lowercase} {OldStyle} |
| 2864 |
\aliasfontfeatureoption {Numbers} {Uppercase} {Lining} |
| 2865 |
\__fontspec_define_opentype_feature_group:n {VerticalPosition} |
| 2866 |
\__fontspec_define_opentype_feature:nnnnn {VerticalPosition} {ResetAll} {} {} |
| 2867 |
{ |
| 2868 |
+sups,-sups, |
| 2869 |
+subs,-subs, |
| 2870 |
+ordn,-ordn, |
| 2871 |
+numr,-numr, |
| 2872 |
+dnom,-dnom, |
| 2873 |
+sinf,-sinf, |
| 2874 |
} |
| 2875 |
\__fontspec_define_opentype_onoffreset:nnnnn {VerticalPosition} {Superior} {sups} {sups} {+subs,+ordn,+numr,+dnom,+sinf} |
| 2876 |
\__fontspec_define_opentype_onoffreset:nnnnn {VerticalPosition} {Inferior} {subs} {subs} {+sups,+ordn,+numr,+dnom,+sinf} |
| 2877 |
\__fontspec_define_opentype_onoffreset:nnnnn {VerticalPosition} {Ordinal} {ordn} {ordn} {+sups,+subs,+numr,+dnom,+sinf} |
| 2878 |
\__fontspec_define_opentype_onoffreset:nnnnn {VerticalPosition} {Numerator} {numr} {numr} {+sups,+subs,+ordn,+dnom,+sinf} |
| 2879 |
\__fontspec_define_opentype_onoffreset:nnnnn {VerticalPosition} {Denominator} {dnom} {dnom} {+sups,+subs,+ordn,+numr,+sinf} |
| 2880 |
\__fontspec_define_opentype_onoffreset:nnnnn {VerticalPosition} {ScientificInferior} {sinf} {sinf} {+sups,+subs,+ordn,+numr,+dnom} |
| 2881 |
\__fontspec_define_opentype_feature_group:n {Contextuals} |
| 2882 |
\__fontspec_define_opentype_feature:nnnnn {Contextuals} {ResetAll} {} {} |
| 2883 |
{ |
| 2884 |
+cswh,-cswh, |
| 2885 |
+calt,-calt, |
| 2886 |
+init,-init, |
| 2887 |
+fina,-fina, |
| 2888 |
+falt,-falt, |
| 2889 |
+medi,-medi, |
| 2890 |
} |
| 2891 |
\__fontspec_define_opentype_onoffreset:nnnnn {Contextuals} {Swash} {cswh} {cswh} {} |
| 2892 |
\__fontspec_define_opentype_onoffreset:nnnnn {Contextuals} {Alternate} {calt} {calt} {} |
| 2893 |
\__fontspec_define_opentype_onoffreset:nnnnn {Contextuals} {WordInitial} {init} {init} {} |
| 2894 |
\__fontspec_define_opentype_onoffreset:nnnnn {Contextuals} {WordFinal} {fina} {fina} {} |
| 2895 |
\__fontspec_define_opentype_onoffreset:nnnnn {Contextuals} {LineFinal} {falt} {falt} {} |
| 2896 |
\__fontspec_define_opentype_onoffreset:nnnnn {Contextuals} {Inner} {medi} {medi} {} |
| 2897 |
\__fontspec_define_opentype_feature_group:n {Diacritics} |
| 2898 |
\__fontspec_define_opentype_feature:nnnnn {Diacritics} {ResetAll} {} {} |
| 2899 |
{ |
| 2900 |
+mark,-mark, |
| 2901 |
+mkmk,-mkmk, |
| 2902 |
+abvm,-abvm, |
| 2903 |
+blwm,-blwm, |
| 2904 |
} |
| 2905 |
\__fontspec_define_opentype_onoffreset:nnnnn {Diacritics} {MarkToBase} {mark} {mark} {} |
| 2906 |
\__fontspec_define_opentype_onoffreset:nnnnn {Diacritics} {MarkToMark} {mkmk} {mkmk} {} |
| 2907 |
\__fontspec_define_opentype_onoffreset:nnnnn {Diacritics} {AboveBase} {abvm} {abvm} {} |
| 2908 |
\__fontspec_define_opentype_onoffreset:nnnnn {Diacritics} {BelowBase} {blwm} {blwm} {} |
| 2909 |
\__fontspec_define_opentype_feature_group:n {Kerning} |
| 2910 |
\__fontspec_define_opentype_feature:nnnnn {Kerning} {ResetAll} {} {} |
| 2911 |
{ |
| 2912 |
+cpsp,-cpsp, |
| 2913 |
+kern,-kern, |
| 2914 |
} |
| 2915 |
\__fontspec_define_opentype_onoffreset:nnnnn {Kerning} {Uppercase} {cpsp} {cpsp} {} |
| 2916 |
\__fontspec_define_opentype_feature:nnnnn {Kerning} {On} {kern} {+kern} {-kern} |
| 2917 |
\__fontspec_define_opentype_feature:nnnnn {Kerning} {Off} {kern} {-kern} {+kern} |
| 2918 |
\__fontspec_define_opentype_feature:nnnnn {Kerning} {Reset} {} {} {+kern,-kern} |
| 2919 |
\__fontspec_define_opentype_feature_group:n {Fractions} |
| 2920 |
\__fontspec_define_opentype_feature:nnnnn {Fractions} {ResetAll} {} {} |
| 2921 |
{ |
| 2922 |
+frac,-frac, |
| 2923 |
+afrc,-afrc, |
| 2924 |
} |
| 2925 |
\__fontspec_define_opentype_feature:nnnnn {Fractions} {On} {frac} {+frac} {} |
| 2926 |
\__fontspec_define_opentype_feature:nnnnn {Fractions} {Off} {frac} {-frac} {} |
| 2927 |
\__fontspec_define_opentype_feature:nnnnn {Fractions} {Reset} {} {} {+frac,-frac} |
| 2928 |
\__fontspec_define_opentype_onoffreset:nnnnn {Fractions} {Alternate} {afrc} {afrc} {-frac} |
| 2929 |
\__fontspec_define_opentype_feature_group:n {LocalForms} |
| 2930 |
\__fontspec_define_opentype_feature:nnnnn {LocalForms} {On} {locl} {+locl} {} |
| 2931 |
\__fontspec_define_opentype_feature:nnnnn {LocalForms} {Off} {locl} {-locl} {} |
| 2932 |
\__fontspec_define_opentype_feature:nnnnn {LocalForms} {Reset} {} {} {+locl,-locl} |
| 2933 |
|
| 2934 |
\__fontspec_define_opentype_feature_group:n {Style} |
| 2935 |
\__fontspec_define_opentype_feature:nnnnn {Style} {ResetAll} {} {} |
| 2936 |
{ |
| 2937 |
+salt,-salt, |
| 2938 |
+ital,-ital, |
| 2939 |
+ruby,-ruby, |
| 2940 |
+swsh,-swsh, |
| 2941 |
+hist,-hist, |
| 2942 |
+titl,-titl, |
| 2943 |
+hkna,-hkna, |
| 2944 |
+vkna,-vkna, |
| 2945 |
+ssty=0,-ssty=0, |
| 2946 |
+ssty=1,-ssty=1, |
| 2947 |
} |
| 2948 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {Alternate} {salt} {salt} {} |
| 2949 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {Italic} {ital} {ital} {} |
| 2950 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {Ruby} {ruby} {ruby} {} |
| 2951 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {Swash} {swsh} {swsh} {} |
| 2952 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {Cursive} {swsh} {curs} {} |
| 2953 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {Historic} {hist} {hist} {} |
| 2954 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {Titling} {titl} {titl} {} |
| 2955 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {TitlingCaps} {titl} {titl} {} % backwards compat |
| 2956 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {HorizontalKana} {hkna} {hkna} {+vkna,+pkna} |
| 2957 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {VerticalKana} {vkna} {vkna} {+hkna,+pkna} |
| 2958 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {ProportionalKana} {pkna} {pkna} {+vkna,+hkna} |
| 2959 |
\__fontspec_define_opentype_feature:nnnnn {Style} {MathScript} {ssty} {+ssty=0} {+ssty=1} |
| 2960 |
\__fontspec_define_opentype_feature:nnnnn {Style} {MathScriptScript} {ssty} {+ssty=1} {+ssty=0} |
| 2961 |
\__fontspec_define_opentype_onoffreset:nnnnn {Style} {Uppercase} {case} {case} {} |
| 2962 |
\__fontspec_define_opentype_feature_group:n {CJKShape} |
| 2963 |
\__fontspec_define_opentype_feature:nnnnn {CJKShape} {ResetAll} {} {} |
| 2964 |
{ |
| 2965 |
+trad,-trad, |
| 2966 |
+smpl,-smpl, |
| 2967 |
+jp78,-jp78, |
| 2968 |
+jp83,-jp83, |
| 2969 |
+jp90,-jp90, |
| 2970 |
+jp04,-jp04, |
| 2971 |
+expt,-expt, |
| 2972 |
+nlck,-nlck, |
| 2973 |
} |
| 2974 |
\__fontspec_define_opentype_onoffreset:nnnnn {CJKShape} {Traditional} {trad} {trad} {+smpl,+jp78,+jp83,+jp90,+jp04,+expt,+nlck} |
| 2975 |
\__fontspec_define_opentype_onoffreset:nnnnn {CJKShape} {Simplified} {smpl} {smpl} {+trad,+jp78,+jp83,+jp90,+jp04,+expt,+nlck} |
| 2976 |
\__fontspec_define_opentype_onoffreset:nnnnn {CJKShape} {JIS1978} {jp78} {jp78} {+trad,+smpl,+jp83,+jp90,+jp04,+expt,+nlck} |
| 2977 |
\__fontspec_define_opentype_onoffreset:nnnnn {CJKShape} {JIS1983} {jp83} {jp83} {+trad,+smpl,+jp78,+jp90,+jp04,+expt,+nlck} |
| 2978 |
\__fontspec_define_opentype_onoffreset:nnnnn {CJKShape} {JIS1990} {jp90} {jp90} {+trad,+smpl,+jp78,+jp83,+jp04,+expt,+nlck} |
| 2979 |
\__fontspec_define_opentype_onoffreset:nnnnn {CJKShape} {JIS2004} {jp04} {jp04} {+trad,+smpl,+jp78,+jp83,+jp90,+expt,+nlck} |
| 2980 |
\__fontspec_define_opentype_onoffreset:nnnnn {CJKShape} {Expert} {expt} {expt} {+trad,+smpl,+jp78,+jp83,+jp90,+jp04,+nlck} |
| 2981 |
\__fontspec_define_opentype_onoffreset:nnnnn {CJKShape} {NLC} {nlck} {nlck} {+trad,+smpl,+jp78,+jp83,+jp90,+jp04,+expt} |
| 2982 |
\__fontspec_define_opentype_feature_group:n {CharacterWidth} |
| 2983 |
\__fontspec_define_opentype_feature:nnnnn {CharacterWidth} {ResetAll} {} {} |
| 2984 |
{ |
| 2985 |
+pwid,-pwid, |
| 2986 |
+fwid,-fwid, |
| 2987 |
+hwid,-hwid, |
| 2988 |
+twid,-twid, |
| 2989 |
+qwid,-qwid, |
| 2990 |
+palt,-palt, |
| 2991 |
+halt,-halt, |
| 2992 |
} |
| 2993 |
\__fontspec_define_opentype_onoffreset:nnnnn {CharacterWidth} {Proportional} {pwid} {pwid} {+fwid,+hwid,+twid,+qwid,+palt,+halt} |
| 2994 |
\__fontspec_define_opentype_onoffreset:nnnnn {CharacterWidth} {Full} {fwid} {fwid} {+pwid,+hwid,+twid,+qwid,+palt,+halt} |
| 2995 |
\__fontspec_define_opentype_onoffreset:nnnnn {CharacterWidth} {Half} {hwid} {hwid} {+pwid,+fwid,+twid,+qwid,+palt,+halt} |
| 2996 |
\__fontspec_define_opentype_onoffreset:nnnnn {CharacterWidth} {Third} {twid} {twid} {+pwid,+fwid,+hwid,+qwid,+palt,+halt} |
| 2997 |
\__fontspec_define_opentype_onoffreset:nnnnn {CharacterWidth} {Quarter} {qwid} {qwid} {+pwid,+fwid,+hwid,+twid,+palt,+halt} |
| 2998 |
\__fontspec_define_opentype_onoffreset:nnnnn {CharacterWidth} {AlternateProportional} {palt} {palt} {+pwid,+fwid,+hwid,+twid,+qwid,+halt} |
| 2999 |
\__fontspec_define_opentype_onoffreset:nnnnn {CharacterWidth} {AlternateHalf} {halt} {halt} {+pwid,+fwid,+hwid,+twid,+qwid,+palt} |
| 3000 |
\__fontspec_define_opentype_feature_group:n {Vertical} |
| 3001 |
\__fontspec_define_opentype_onoffreset:nnnnn {Vertical} {RotatedGlyphs} {vrt2} {vrt2} {+vrtr,+vert} |
| 3002 |
\__fontspec_define_opentype_onoffreset:nnnnn {Vertical} {AlternatesForRotation} {vrtr} {vrtr} {+vrt2} |
| 3003 |
\__fontspec_define_opentype_onoffreset:nnnnn {Vertical} {Alternates} {vert} {vert} {+vrt2} |
| 3004 |
\__fontspec_define_opentype_onoffreset:nnnnn {Vertical} {KanaAlternates} {vkna} {vkna} {+hkna} |
| 3005 |
\__fontspec_define_opentype_onoffreset:nnnnn {Vertical} {Kerning} {vkrn} {vkrn} {} |
| 3006 |
\__fontspec_define_opentype_onoffreset:nnnnn {Vertical} {AlternateMetrics} {valt} {valt} {+vhal,+vpal,+kern} |
| 3007 |
\__fontspec_define_opentype_onoffreset:nnnnn {Vertical} {HalfMetrics} {vhal} {vhal} {+valt,+vpal,+kern} |
| 3008 |
\__fontspec_define_opentype_onoffreset:nnnnn {Vertical} {ProportionalMetrics} {vpal} {vpal} {+valt,+vhal} |
| 3009 |
\__fontspec_define_opentype_feature_group:n {Alternate} |
| 3010 |
\keys_define:nn {fontspec-opentype} |
| 3011 |
{ |
| 3012 |
Alternate .default:n = {0} , |
| 3013 |
Alternate .groups:n = {opentype}, |
| 3014 |
Alternate / unknown .code:n = |
| 3015 |
{ |
| 3016 |
\clist_map_inline:nn {#1} |
| 3017 |
{ \__fontspec_make_OT_feature:nnn {salt}{ +salt = ##1 }{} } |
| 3018 |
} |
| 3019 |
} |
| 3020 |
\aliasfontfeature{Alternate}{StylisticAlternates} |
| 3021 |
\__fontspec_define_opentype_feature_group:n {Variant} |
| 3022 |
\keys_define:nn {fontspec-opentype} |
| 3023 |
{ |
| 3024 |
Variant .default:n = {0} , |
| 3025 |
Variant .groups:n = {opentype} , |
| 3026 |
Variant / unknown .code:n = |
| 3027 |
{ |
| 3028 |
\clist_map_inline:nn {#1} |
| 3029 |
{ |
| 3030 |
\__fontspec_make_OT_feature:xxx { ss \two@digits {##1} } { +ss \two@digits {##1} } {} |
| 3031 |
} |
| 3032 |
} |
| 3033 |
} |
| 3034 |
\aliasfontfeature{Variant}{StylisticSet} |
| 3035 |
\__fontspec_define_opentype_feature_group:n {CharacterVariant} |
| 3036 |
\use:x |
| 3037 |
{ |
| 3038 |
\cs_new:Npn \exp_not:N \fontspec_parse_cv:w |
| 3039 |
##1 \c_colon_str ##2 \c_colon_str ##3 \exp_not:N \q_nil |
| 3040 |
{ |
| 3041 |
\__fontspec_make_OT_feature:xxx |
| 3042 |
{ cv \exp_not:N \two@digits {##1} } |
| 3043 |
{ +cv \exp_not:N \two@digits {##1} = ##2 } {} |
| 3044 |
} |
| 3045 |
\keys_define:nn {fontspec-opentype} |
| 3046 |
{ |
| 3047 |
CharacterVariant / unknown .code:n = |
| 3048 |
{ |
| 3049 |
\clist_map_inline:nn {##1} |
| 3050 |
{ |
| 3051 |
\exp_not:N \fontspec_parse_cv:w |
| 3052 |
####1 \c_colon_str 0 \c_colon_str \exp_not:N \q_nil |
| 3053 |
} |
| 3054 |
} |
| 3055 |
} |
| 3056 |
} |
| 3057 |
\__fontspec_define_opentype_feature_group:n {Annotation} |
| 3058 |
\keys_define:nn {fontspec-opentype} |
| 3059 |
{ |
| 3060 |
Annotation .default:n = {0} , |
| 3061 |
Annotation .groups:n = {opentype}, |
| 3062 |
Annotation / unknown .code:n = |
| 3063 |
{ |
| 3064 |
\__fontspec_make_OT_feature:nnn {nalt} {+nalt=#1} {} |
| 3065 |
} |
| 3066 |
} |
| 3067 |
\__fontspec_define_opentype_feature_group:n {Ornament} |
| 3068 |
\keys_define:nn {fontspec-opentype} |
| 3069 |
{ |
| 3070 |
Ornament .default:n = {0} , |
| 3071 |
Ornament .groups:n = {opentype}, |
| 3072 |
Ornament / unknown .code:n = |
| 3073 |
{ |
| 3074 |
\__fontspec_make_OT_feature:nnn {ornm} { +ornm=#1 } {} |
| 3075 |
} |
| 3076 |
} |
| 3077 |
\keys_define:nn {fontspec-opentype} |
| 3078 |
{ |
| 3079 |
Script .choice: , |
| 3080 |
Script .groups:n = {opentype} , |
| 3081 |
} |
| 3082 |
\cs_new:Nn \fontspec_new_script:nn |
| 3083 |
{ |
| 3084 |
\keys_define:nn {fontspec-opentype} { Script / #1 .code:n = |
| 3085 |
{ |
| 3086 |
\bool_set_false:N \l__fontspec_scriptlang_exist_bool |
| 3087 |
\clist_map_inline:nn {#2} |
| 3088 |
{ |
| 3089 |
\exp_args:No \__fontspec_check_script:NnT \l__fontspec_fontface_cs_tl {####1} |
| 3090 |
{ |
| 3091 |
\tl_set:Nn \l__fontspec_script_name_tl {#1} |
| 3092 |
\tl_set:Nn \l__fontspec_script_tl {####1} |
| 3093 |
\int_set:Nn \l__fontspec_script_int {\l__fontspec_strnum_int} |
| 3094 |
\bool_set_true:N \l__fontspec_scriptlang_exist_bool |
| 3095 |
\tl_gset:Nx \g__fontspec_single_feat_tl { script=####1 } |
| 3096 |
\clist_map_break: |
| 3097 |
} |
| 3098 |
} |
| 3099 |
\bool_if:NF \l__fontspec_scriptlang_exist_bool |
| 3100 |
{ |
| 3101 |
\__fontspec_info:nxx {script-not-exist} {\l_fontspec_fontname_tl} {#1} |
| 3102 |
\clist_set:Nn \l_tmpa_clist {#2} |
| 3103 |
\clist_get:NN \l_tmpa_clist \l__fontspec_script_tl |
| 3104 |
\exp_args:Noo \__fontspec_check_script:NnF \l__fontspec_fontface_cs_tl \l__fontspec_script_tl |
| 3105 |
{ |
| 3106 |
\tl_set:Nn \l__fontspec_script_name_tl {#1} |
| 3107 |
\int_set:Nn \l__fontspec_script_int {\l__fontspec_strnum_int} |
| 3108 |
\tl_gset:Nx \g__fontspec_single_feat_tl { script=\l__fontspec_script_tl } |
| 3109 |
} |
| 3110 |
} |
| 3111 |
} |
| 3112 |
} |
| 3113 |
} |
| 3114 |
\clist_new:N \g__fontspec_default_scripts_clist |
| 3115 |
\cs_new:Nn \fontspec_default_script:n |
| 3116 |
{ |
| 3117 |
\clist_gset:Nn \g__fontspec_default_scripts_clist {#1} |
| 3118 |
} |
| 3119 |
\fontspec_default_script:n {latn,DFLT} |
| 3120 |
\keys_define:nn {fontspec-opentype} { Script / CustomDefault .code:n = |
| 3121 |
{ |
| 3122 |
\bool_set_false:N \l__fontspec_scriptlang_exist_bool |
| 3123 |
\clist_map_inline:Nn \g__fontspec_default_scripts_clist |
| 3124 |
{ |
| 3125 |
\exp_args:No \__fontspec_check_script:NnT \l__fontspec_fontface_cs_tl {##1} |
| 3126 |
{ |
| 3127 |
\tl_set:Nn \l__fontspec_script_name_tl {Default (##1)} |
| 3128 |
\tl_set:Nn \l__fontspec_script_tl {##1} |
| 3129 |
\int_set:Nn \l__fontspec_script_int {\l__fontspec_strnum_int} |
| 3130 |
\bool_set_true:N \l__fontspec_scriptlang_exist_bool |
| 3131 |
\tl_gset:Nx \g__fontspec_single_feat_tl { script=##1 } |
| 3132 |
\clist_map_break: |
| 3133 |
} |
| 3134 |
} |
| 3135 |
\bool_if:NF \l__fontspec_scriptlang_exist_bool |
| 3136 |
{ |
| 3137 |
\tl_clear:N \l__fontspec_script_name_tl |
| 3138 |
} |
| 3139 |
} |
| 3140 |
} |
| 3141 |
\keys_define:nn {fontspec-opentype} |
| 3142 |
{ |
| 3143 |
Language .choice: , |
| 3144 |
Language .groups:n = {opentype} , |
| 3145 |
} |
| 3146 |
\cs_new:Nn \fontspec_new_lang:nn |
| 3147 |
{ |
| 3148 |
\keys_define:nn {fontspec-opentype} { Language / #1 .code:n = |
| 3149 |
{ |
| 3150 |
\bool_set_false:N \l__fontspec_scriptlang_exist_bool |
| 3151 |
\clist_map_inline:nn {#2} |
| 3152 |
{ |
| 3153 |
\exp_args:No \__fontspec_check_lang:NnTF \l__fontspec_fontface_cs_tl {####1} |
| 3154 |
{ |
| 3155 |
\tl_set:Nn \l__fontspec_lang_tl {####1} |
| 3156 |
\int_set:Nn \l__fontspec_language_int {\l__fontspec_strnum_int} |
| 3157 |
\tl_gset:Nx \g__fontspec_single_feat_tl { language=####1 } |
| 3158 |
\bool_set_true:N \l__fontspec_scriptlang_exist_bool |
| 3159 |
\clist_map_break: |
| 3160 |
} |
| 3161 |
} |
| 3162 |
\bool_if:NF \l__fontspec_scriptlang_exist_bool |
| 3163 |
{ |
| 3164 |
\__fontspec_info:nx {language-not-exist} {#1} |
| 3165 |
\clist_set:Nn \l_tmpa_clist {#2} |
| 3166 |
\clist_get:NN \l_tmpa_clist \l__fontspec_lang_tl |
| 3167 |
\exp_args:Noo \__fontspec_check_lang:NnF \l__fontspec_fontface_cs_tl \l__fontspec_lang_tl |
| 3168 |
{ |
| 3169 |
\tl_set:Nn \l__fontspec_lang_name_tl {#1} |
| 3170 |
\int_set:Nn \l__fontspec_language_int {\l__fontspec_strnum_int} |
| 3171 |
\tl_gset:Nx \g__fontspec_single_feat_tl { language=\l__fontspec_lang_tl } |
| 3172 |
} |
| 3173 |
} |
| 3174 |
} |
| 3175 |
} |
| 3176 |
} |
| 3177 |
\clist_new:N \g__fontspec_default_langs_clist |
| 3178 |
\cs_new:Nn \fontspec_default_lang:n |
| 3179 |
{ |
| 3180 |
\clist_gset:Nn \g__fontspec_default_langs_clist {#1} |
| 3181 |
} |
| 3182 |
\fontspec_default_lang:n {dflt} |
| 3183 |
\__fontspec_keys_define_code:nnn {fontspec-opentype} { Language / Default } |
| 3184 |
{ |
| 3185 |
\tl_set:Nn \l__fontspec_lang_tl {dflt} |
| 3186 |
\int_zero:N \l__fontspec_language_int |
| 3187 |
\tl_gset:Nn \g__fontspec_single_feat_tl { language=dflt } |
| 3188 |
} |
| 3189 |
\cs_new:Nn \__fontspec_ot_compat:nn |
| 3190 |
{ |
| 3191 |
\aliasfontfeatureoption {#1} {#2Off} {No#2} |
| 3192 |
} |
| 3193 |
\__fontspec_ot_compat:nn {Ligatures} {Rare} |
| 3194 |
\__fontspec_ot_compat:nn {Ligatures} {Required} |
| 3195 |
\__fontspec_ot_compat:nn {Ligatures} {Common} |
| 3196 |
\__fontspec_ot_compat:nn {Ligatures} {Discretionary} |
| 3197 |
\__fontspec_ot_compat:nn {Ligatures} {Contextual} |
| 3198 |
\__fontspec_ot_compat:nn {Ligatures} {Historic} |
| 3199 |
\__fontspec_ot_compat:nn {Numbers} {SlashedZero} |
| 3200 |
\__fontspec_ot_compat:nn {Contextuals} {Swash} |
| 3201 |
\__fontspec_ot_compat:nn {Contextuals} {Alternate} |
| 3202 |
\__fontspec_ot_compat:nn {Contextuals} {WordInitial} |
| 3203 |
\__fontspec_ot_compat:nn {Contextuals} {WordFinal} |
| 3204 |
\__fontspec_ot_compat:nn {Contextuals} {LineFinal} |
| 3205 |
\__fontspec_ot_compat:nn {Contextuals} {Inner} |
| 3206 |
\__fontspec_ot_compat:nn {Diacritics} {MarkToBase} |
| 3207 |
\__fontspec_ot_compat:nn {Diacritics} {MarkToMark} |
| 3208 |
\__fontspec_ot_compat:nn {Diacritics} {AboveBase} |
| 3209 |
\__fontspec_ot_compat:nn {Diacritics} {BelowBase} |
| 3210 |
|
| 3211 |
%%^^A%% fontspec-code-scripts.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 3212 |
|
| 3213 |
\newfontscript{Adlam}{adlm} |
| 3214 |
\newfontscript{Ahom}{ahom} |
| 3215 |
\newfontscript{Anatolian~Hieroglyphs}{hluw} |
| 3216 |
\newfontscript{Arabic}{arab} |
| 3217 |
\newfontscript{Armenian}{armn} |
| 3218 |
\newfontscript{Avestan}{avst} |
| 3219 |
\newfontscript{Balinese}{bali} |
| 3220 |
\newfontscript{Bamum}{bamu} |
| 3221 |
\newfontscript{Bassa~Vah}{bass} |
| 3222 |
\newfontscript{Batak}{batk} |
| 3223 |
\newfontscript{Bengali}{bng2,beng} |
| 3224 |
\newfontscript{Bhaiksuki}{bhks} |
| 3225 |
\newfontscript{Bopomofo}{bopo} |
| 3226 |
\newfontscript{Brahmi}{brah} |
| 3227 |
\newfontscript{Braille}{brai} |
| 3228 |
\newfontscript{Buginese}{bugi} |
| 3229 |
\newfontscript{Buhid}{buhd} |
| 3230 |
\newfontscript{Byzantine~Music}{byzm} |
| 3231 |
\newfontscript{Canadian~Syllabics}{cans} |
| 3232 |
\newfontscript{Carian}{cari} |
| 3233 |
\newfontscript{Caucasian~Albanian}{aghb} |
| 3234 |
\newfontscript{Chakma}{cakm} |
| 3235 |
\newfontscript{Cham}{cham} |
| 3236 |
\newfontscript{Cherokee}{cher} |
| 3237 |
\newfontscript{Chorasmian}{chrs} |
| 3238 |
\newfontscript{CJK~Ideographic}{hani} |
| 3239 |
\newfontscript{Coptic}{copt} |
| 3240 |
\newfontscript{Cypriot~Syllabary}{cprt} |
| 3241 |
\newfontscript{Cypro-Minoan}{cpmn} |
| 3242 |
\newfontscript{Cyrillic}{cyrl} |
| 3243 |
\newfontscript{Default}{DFLT} |
| 3244 |
\newfontscript{Deseret}{dsrt} |
| 3245 |
\newfontscript{Devanagari}{dev2,deva} |
| 3246 |
\newfontscript{Dives~Akuru}{diak} |
| 3247 |
\newfontscript{Dogra}{dogr} |
| 3248 |
\newfontscript{Duployan}{dupl} |
| 3249 |
\newfontscript{Egyptian~Hieroglyphs}{egyp} |
| 3250 |
\newfontscript{Elbasan}{elba} |
| 3251 |
\newfontscript{Elymaic}{elym} |
| 3252 |
\newfontscript{Ethiopic}{ethi} |
| 3253 |
\newfontscript{Garay}{gara} |
| 3254 |
\newfontscript{Georgian}{geor} |
| 3255 |
\newfontscript{Glagolitic}{glag} |
| 3256 |
\newfontscript{Gothic}{goth} |
| 3257 |
\newfontscript{Grantha}{gran} |
| 3258 |
\newfontscript{Greek}{grek} |
| 3259 |
\newfontscript{Gujarati}{gjr2,gujr} |
| 3260 |
\newfontscript{Gunjala~Gondi}{gong} |
| 3261 |
\newfontscript{Gurmukhi}{gur2,guru} |
| 3262 |
\newfontscript{Gurung~Khema}{gukh} |
| 3263 |
\newfontscript{Hangul~Jamo}{jamo} |
| 3264 |
\newfontscript{Hangul}{hang} |
| 3265 |
\newfontscript{Hanifi~Rohingya}{rohg} |
| 3266 |
\newfontscript{Hanunoo}{hano} |
| 3267 |
\newfontscript{Hatran}{hatr} |
| 3268 |
\newfontscript{Hebrew}{hebr} |
| 3269 |
\newfontscript{Hiragana~and~Katakana}{kana} |
| 3270 |
\newfontscript{Imperial~Aramaic}{armi} |
| 3271 |
\newfontscript{Inscriptional~Pahlavi}{phli} |
| 3272 |
\newfontscript{Inscriptional~Parthian}{prti} |
| 3273 |
\newfontscript{Javanese}{java} |
| 3274 |
\newfontscript{Kaithi}{kthi} |
| 3275 |
\newfontscript{Kannada}{knd2,knda} |
| 3276 |
\newfontscript{Kawi}{kawi} |
| 3277 |
\newfontscript{Kayah~Li}{kali} |
| 3278 |
\newfontscript{Kharosthi}{khar} |
| 3279 |
\newfontscript{Khitan~Small~Script}{kits} |
| 3280 |
\newfontscript{Khmer}{khmr} |
| 3281 |
\newfontscript{Khojki}{khoj} |
| 3282 |
\newfontscript{Khudawadi}{sind} |
| 3283 |
\newfontscript{Kirat~Rai}{krai} |
| 3284 |
\newfontscript{Lao}{lao~} |
| 3285 |
\newfontscript{Latin}{latn} |
| 3286 |
\newfontscript{Lepcha}{lepc} |
| 3287 |
\newfontscript{Limbu}{limb} |
| 3288 |
\newfontscript{Linear~A}{lina} |
| 3289 |
\newfontscript{Linear~B}{linb} |
| 3290 |
\newfontscript{Lisu}{lisu} |
| 3291 |
\newfontscript{Lycian}{lyci} |
| 3292 |
\newfontscript{Lydian}{lydi} |
| 3293 |
\newfontscript{Mahajani}{mahj} |
| 3294 |
\newfontscript{Makasar}{maka} |
| 3295 |
\newfontscript{Malayalam}{mlm2,mlym} |
| 3296 |
\newfontscript{Mandaic}{mand} |
| 3297 |
\newfontscript{Manichaean}{mani} |
| 3298 |
\newfontscript{Marchen}{marc} |
| 3299 |
\newfontscript{Masaram~Gondi}{gonm} |
| 3300 |
\newfontscript{Math}{math} |
| 3301 |
\newfontscript{Medefaidrin}{medf} |
| 3302 |
\newfontscript{Meitei~Mayek}{mtei} |
| 3303 |
\newfontscript{Mende~Kikakui}{mend} |
| 3304 |
\newfontscript{Meroitic~Cursive}{merc} |
| 3305 |
\newfontscript{Meroitic~Hieroglyphs}{mero} |
| 3306 |
\newfontscript{Miao}{plrd} |
| 3307 |
\newfontscript{Modi}{modi} |
| 3308 |
\newfontscript{Mongolian}{mong} |
| 3309 |
\newfontscript{Mro}{mroo} |
| 3310 |
\newfontscript{Multani}{mult} |
| 3311 |
\newfontscript{Musical~Symbols}{musc} |
| 3312 |
\newfontscript{Myanmar}{mym2,mymr} |
| 3313 |
\newfontscript{N'Ko}{nko~} |
| 3314 |
\newfontscript{Nabataean}{nbat} |
| 3315 |
\newfontscript{Nag~Mundari}{nagm} |
| 3316 |
\newfontscript{Nandinagari}{nand} |
| 3317 |
\newfontscript{Newa}{newa} |
| 3318 |
\newfontscript{Nushu}{nshu} |
| 3319 |
\newfontscript{Nyiakeng~Puachue~Hmong}{hmnp} |
| 3320 |
\newfontscript{Odia}{ory2,orya} |
| 3321 |
\newfontscript{Ogham}{ogam} |
| 3322 |
\newfontscript{Ol~Chiki}{olck} |
| 3323 |
\newfontscript{Ol~Onal}{onao} |
| 3324 |
\newfontscript{Old~Italic}{ital} |
| 3325 |
\newfontscript{Old~Hungarian}{hung} |
| 3326 |
\newfontscript{Old~North~Arabian}{narb} |
| 3327 |
\newfontscript{Old~Permic}{perm} |
| 3328 |
\newfontscript{Old~Persian~Cuneiform}{xpeo} |
| 3329 |
\newfontscript{Old~Sogdian}{sogo} |
| 3330 |
\newfontscript{Old~South~Arabian}{sarb} |
| 3331 |
\newfontscript{Old~Turkic}{orkh} |
| 3332 |
\newfontscript{Old~Uyghur}{ougr} |
| 3333 |
\newfontscript{Osage}{osge} |
| 3334 |
\newfontscript{Osmanya}{osma} |
| 3335 |
\newfontscript{Pahawh~Hmong}{hmng} |
| 3336 |
\newfontscript{Palmyrene}{palm} |
| 3337 |
\newfontscript{Pau~Cin~Hau}{pauc} |
| 3338 |
\newfontscript{Phags-pa}{phag} |
| 3339 |
\newfontscript{Phoenician}{phnx} |
| 3340 |
\newfontscript{Psalter~Pahlavi}{phlp} |
| 3341 |
\newfontscript{Rejang}{rjng} |
| 3342 |
\newfontscript{Runic}{runr} |
| 3343 |
\newfontscript{Samaritan}{samr} |
| 3344 |
\newfontscript{Saurashtra}{saur} |
| 3345 |
\newfontscript{Sharada}{shrd} |
| 3346 |
\newfontscript{Shavian}{shaw} |
| 3347 |
\newfontscript{Siddham}{sidd} |
| 3348 |
\newfontscript{Sign~Writing}{sgnw} |
| 3349 |
\newfontscript{Sinhala}{sinh} |
| 3350 |
\newfontscript{Sogdian}{sogd} |
| 3351 |
\newfontscript{Sora~Sompeng}{sora} |
| 3352 |
\newfontscript{Sumero-Akkadian~Cuneiform}{xsux} |
| 3353 |
\newfontscript{Sundanese}{sund} |
| 3354 |
\newfontscript{Sunuwar}{sunu} |
| 3355 |
\newfontscript{Syloti~Nagri}{sylo} |
| 3356 |
\newfontscript{Syriac}{syrc} |
| 3357 |
\newfontscript{Tagalog}{tglg} |
| 3358 |
\newfontscript{Tagbanwa}{tagb} |
| 3359 |
\newfontscript{Tai~Le}{tale} |
| 3360 |
\newfontscript{Tai~Lu}{talu} |
| 3361 |
\newfontscript{Tai~Tham}{lana} |
| 3362 |
\newfontscript{Tai~Viet}{tavt} |
| 3363 |
\newfontscript{Takri}{takr} |
| 3364 |
\newfontscript{Tamil}{tml2,taml} |
| 3365 |
\newfontscript{Tangsa}{tnsa} |
| 3366 |
\newfontscript{Tangut}{tang} |
| 3367 |
\newfontscript{Telugu}{tel2,telu} |
| 3368 |
\newfontscript{Thaana}{thaa} |
| 3369 |
\newfontscript{Thai}{thai} |
| 3370 |
\newfontscript{Tibetan}{tibt} |
| 3371 |
\newfontscript{Tifinagh}{tfng} |
| 3372 |
\newfontscript{Tirhuta}{tirh} |
| 3373 |
\newfontscript{Todhri}{todr} |
| 3374 |
\newfontscript{Toto}{toto} |
| 3375 |
\newfontscript{Tulu-Tigalari}{tutg} |
| 3376 |
\newfontscript{Ugaritic~Cuneiform}{ugar} |
| 3377 |
\newfontscript{Vai}{vai~} |
| 3378 |
\newfontscript{Vithkuqi}{vith} |
| 3379 |
\newfontscript{Wancho}{wcho} |
| 3380 |
\newfontscript{Warang~Citi}{wara} |
| 3381 |
\newfontscript{Yezidi}{yezi} |
| 3382 |
\newfontscript{Yi}{yi~~} |
| 3383 |
\newfontscript{Zanabazar~Square}{zanb} |
| 3384 |
\newfontscript{CJK}{hani} |
| 3385 |
\newfontscript{Kana}{kana} |
| 3386 |
\newfontscript{Maths}{math} |
| 3387 |
\newfontscript{N'ko}{nko~} |
| 3388 |
\newfontscript{Oriya}{ory2,orya} |
| 3389 |
|
| 3390 |
%%^^A%% fontspec-code-lang.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 3391 |
|
| 3392 |
\newfontlanguage{Abaza}{ABA} |
| 3393 |
\newfontlanguage{Abkhazian}{ABK} |
| 3394 |
\newfontlanguage{Adyghe}{ADY} |
| 3395 |
\newfontlanguage{Afrikaans}{AFK} |
| 3396 |
\newfontlanguage{Afar}{AFR} |
| 3397 |
\newfontlanguage{Agaw}{AGW} |
| 3398 |
\newfontlanguage{Altai}{ALT} |
| 3399 |
\newfontlanguage{Amharic}{AMH} |
| 3400 |
\newfontlanguage{Arabic}{ARA} |
| 3401 |
\newfontlanguage{Aari}{ARI} |
| 3402 |
\newfontlanguage{Arakanese}{ARK} |
| 3403 |
\newfontlanguage{Assamese}{ASM} |
| 3404 |
\newfontlanguage{Athapaskan}{ATH} |
| 3405 |
\newfontlanguage{Avar}{AVR} |
| 3406 |
\newfontlanguage{Awadhi}{AWA} |
| 3407 |
\newfontlanguage{Aymara}{AYM} |
| 3408 |
\newfontlanguage{Azeri}{AZE} |
| 3409 |
\newfontlanguage{Badaga}{BAD} |
| 3410 |
\newfontlanguage{Baghelkhandi}{BAG} |
| 3411 |
\newfontlanguage{Balkar}{BAL} |
| 3412 |
\newfontlanguage{Baule}{BAU} |
| 3413 |
\newfontlanguage{Berber}{BBR} |
| 3414 |
\newfontlanguage{Bench}{BCH} |
| 3415 |
\newfontlanguage{Bible~Cree}{BCR} |
| 3416 |
\newfontlanguage{Belarussian}{BEL} |
| 3417 |
\newfontlanguage{Bemba}{BEM} |
| 3418 |
\newfontlanguage{Bengali}{BEN} |
| 3419 |
\newfontlanguage{Bulgarian}{BGR} |
| 3420 |
\newfontlanguage{Bhili}{BHI} |
| 3421 |
\newfontlanguage{Bhojpuri}{BHO} |
| 3422 |
\newfontlanguage{Bikol}{BIK} |
| 3423 |
\newfontlanguage{Bilen}{BIL} |
| 3424 |
\newfontlanguage{Blackfoot}{BKF} |
| 3425 |
\newfontlanguage{Balochi}{BLI} |
| 3426 |
\newfontlanguage{Balante}{BLN} |
| 3427 |
\newfontlanguage{Balti}{BLT} |
| 3428 |
\newfontlanguage{Bambara}{BMB} |
| 3429 |
\newfontlanguage{Bamileke}{BML} |
| 3430 |
\newfontlanguage{Breton}{BRE} |
| 3431 |
\newfontlanguage{Brahui}{BRH} |
| 3432 |
\newfontlanguage{Braj~Bhasha}{BRI} |
| 3433 |
\newfontlanguage{Burmese}{BRM} |
| 3434 |
\newfontlanguage{Bashkir}{BSH} |
| 3435 |
\newfontlanguage{Beti}{BTI} |
| 3436 |
\newfontlanguage{Catalan}{CAT} |
| 3437 |
\newfontlanguage{Cebuano}{CEB} |
| 3438 |
\newfontlanguage{Chechen}{CHE} |
| 3439 |
\newfontlanguage{Chaha~Gurage}{CHG} |
| 3440 |
\newfontlanguage{Chattisgarhi}{CHH} |
| 3441 |
\newfontlanguage{Chichewa}{CHI} |
| 3442 |
\newfontlanguage{Chukchi}{CHK} |
| 3443 |
\newfontlanguage{Chipewyan}{CHP} |
| 3444 |
\newfontlanguage{Cherokee}{CHR} |
| 3445 |
\newfontlanguage{Chuvash}{CHU} |
| 3446 |
\newfontlanguage{Comorian}{CMR} |
| 3447 |
\newfontlanguage{Coptic}{COP} |
| 3448 |
\newfontlanguage{Cree}{CRE} |
| 3449 |
\newfontlanguage{Carrier}{CRR} |
| 3450 |
\newfontlanguage{Crimean~Tatar}{CRT} |
| 3451 |
\newfontlanguage{Church~Slavonic}{CSL} |
| 3452 |
\newfontlanguage{Czech}{CSY} |
| 3453 |
\newfontlanguage{Danish}{DAN} |
| 3454 |
\newfontlanguage{Dargwa}{DAR} |
| 3455 |
\newfontlanguage{Woods~Cree}{DCR} |
| 3456 |
\newfontlanguage{German}{DEU} |
| 3457 |
\newfontlanguage{Dogri}{DGR} |
| 3458 |
\newfontlanguage{Divehi}{DIV} |
| 3459 |
\newfontlanguage{Djerma}{DJR} |
| 3460 |
\newfontlanguage{Dangme}{DNG} |
| 3461 |
\newfontlanguage{Dinka}{DNK} |
| 3462 |
\newfontlanguage{Dungan}{DUN} |
| 3463 |
\newfontlanguage{Dzongkha}{DZN} |
| 3464 |
\newfontlanguage{Ebira}{EBI} |
| 3465 |
\newfontlanguage{Eastern~Cree}{ECR} |
| 3466 |
\newfontlanguage{Edo}{EDO} |
| 3467 |
\newfontlanguage{Efik}{EFI} |
| 3468 |
\newfontlanguage{Greek}{ELL} |
| 3469 |
\newfontlanguage{English}{ENG} |
| 3470 |
\newfontlanguage{Erzya}{ERZ} |
| 3471 |
\newfontlanguage{Spanish}{ESP} |
| 3472 |
\newfontlanguage{Estonian}{ETI} |
| 3473 |
\newfontlanguage{Basque}{EUQ} |
| 3474 |
\newfontlanguage{Evenki}{EVK} |
| 3475 |
\newfontlanguage{Even}{EVN} |
| 3476 |
\newfontlanguage{Ewe}{EWE} |
| 3477 |
\newfontlanguage{French~Antillean}{FAN} |
| 3478 |
\newfontlanguage{Farsi}{FAR} |
| 3479 |
\newfontlanguage{Parsi}{FAR} |
| 3480 |
\newfontlanguage{Persian}{FAR} |
| 3481 |
\newfontlanguage{Finnish}{FIN} |
| 3482 |
\newfontlanguage{Fijian}{FJI} |
| 3483 |
\newfontlanguage{Flemish}{FLE} |
| 3484 |
\newfontlanguage{Forest~Nenets}{FNE} |
| 3485 |
\newfontlanguage{Fon}{FON} |
| 3486 |
\newfontlanguage{Faroese}{FOS} |
| 3487 |
\newfontlanguage{French}{FRA} |
| 3488 |
\newfontlanguage{Frisian}{FRI} |
| 3489 |
\newfontlanguage{Friulian}{FRL} |
| 3490 |
\newfontlanguage{Futa}{FTA} |
| 3491 |
\newfontlanguage{Fulani}{FUL} |
| 3492 |
\newfontlanguage{Ga}{GAD} |
| 3493 |
\newfontlanguage{Gaelic}{GAE} |
| 3494 |
\newfontlanguage{Gagauz}{GAG} |
| 3495 |
\newfontlanguage{Galician}{GAL} |
| 3496 |
\newfontlanguage{Garshuni}{GAR} |
| 3497 |
\newfontlanguage{Garhwali}{GAW} |
| 3498 |
\newfontlanguage{Ge'ez}{GEZ} |
| 3499 |
\newfontlanguage{Gilyak}{GIL} |
| 3500 |
\newfontlanguage{Gumuz}{GMZ} |
| 3501 |
\newfontlanguage{Gondi}{GON} |
| 3502 |
\newfontlanguage{Greenlandic}{GRN} |
| 3503 |
\newfontlanguage{Garo}{GRO} |
| 3504 |
\newfontlanguage{Guarani}{GUA} |
| 3505 |
\newfontlanguage{Gujarati}{GUJ} |
| 3506 |
\newfontlanguage{Haitian}{HAI} |
| 3507 |
\newfontlanguage{Halam}{HAL} |
| 3508 |
\newfontlanguage{Harauti}{HAR} |
| 3509 |
\newfontlanguage{Hausa}{HAU} |
| 3510 |
\newfontlanguage{Hawaiin}{HAW} |
| 3511 |
\newfontlanguage{Hammer-Banna}{HBN} |
| 3512 |
\newfontlanguage{Hiligaynon}{HIL} |
| 3513 |
\newfontlanguage{Hindi}{HIN} |
| 3514 |
\newfontlanguage{High~Mari}{HMA} |
| 3515 |
\newfontlanguage{Hindko}{HND} |
| 3516 |
\newfontlanguage{Ho}{HO} |
| 3517 |
\newfontlanguage{Harari}{HRI} |
| 3518 |
\newfontlanguage{Croatian}{HRV} |
| 3519 |
\newfontlanguage{Hungarian}{HUN} |
| 3520 |
\newfontlanguage{Armenian}{HYE} |
| 3521 |
\newfontlanguage{Igbo}{IBO} |
| 3522 |
\newfontlanguage{Ijo}{IJO} |
| 3523 |
\newfontlanguage{Ilokano}{ILO} |
| 3524 |
\newfontlanguage{Indonesian}{IND} |
| 3525 |
\newfontlanguage{Ingush}{ING} |
| 3526 |
\newfontlanguage{Inuktitut}{INU} |
| 3527 |
\newfontlanguage{Irish}{IRI} |
| 3528 |
\newfontlanguage{Irish~Traditional}{IRT} |
| 3529 |
\newfontlanguage{Icelandic}{ISL} |
| 3530 |
\newfontlanguage{Inari~Sami}{ISM} |
| 3531 |
\newfontlanguage{Italian}{ITA} |
| 3532 |
\newfontlanguage{Hebrew}{IWR} |
| 3533 |
\newfontlanguage{Javanese}{JAV} |
| 3534 |
\newfontlanguage{Yiddish}{JII} |
| 3535 |
\newfontlanguage{Japanese}{JAN} |
| 3536 |
\newfontlanguage{Judezmo}{JUD} |
| 3537 |
\newfontlanguage{Jula}{JUL} |
| 3538 |
\newfontlanguage{Kabardian}{KAB} |
| 3539 |
\newfontlanguage{Kachchi}{KAC} |
| 3540 |
\newfontlanguage{Kalenjin}{KAL} |
| 3541 |
\newfontlanguage{Kannada}{KAN} |
| 3542 |
\newfontlanguage{Karachay}{KAR} |
| 3543 |
\newfontlanguage{Georgian}{KAT} |
| 3544 |
\newfontlanguage{Kazakh}{KAZ} |
| 3545 |
\newfontlanguage{Kebena}{KEB} |
| 3546 |
\newfontlanguage{Khutsuri~Georgian}{KGE} |
| 3547 |
\newfontlanguage{Khakass}{KHA} |
| 3548 |
\newfontlanguage{Khanty-Kazim}{KHK} |
| 3549 |
\newfontlanguage{Khmer}{KHM} |
| 3550 |
\newfontlanguage{Khanty-Shurishkar}{KHS} |
| 3551 |
\newfontlanguage{Khanty-Vakhi}{KHV} |
| 3552 |
\newfontlanguage{Khowar}{KHW} |
| 3553 |
\newfontlanguage{Kikuyu}{KIK} |
| 3554 |
\newfontlanguage{Kirghiz}{KIR} |
| 3555 |
\newfontlanguage{Kisii}{KIS} |
| 3556 |
\newfontlanguage{Kokni}{KKN} |
| 3557 |
\newfontlanguage{Kalmyk}{KLM} |
| 3558 |
\newfontlanguage{Kamba}{KMB} |
| 3559 |
\newfontlanguage{Kumaoni}{KMN} |
| 3560 |
\newfontlanguage{Komo}{KMO} |
| 3561 |
\newfontlanguage{Komso}{KMS} |
| 3562 |
\newfontlanguage{Kanuri}{KNR} |
| 3563 |
\newfontlanguage{Kodagu}{KOD} |
| 3564 |
\newfontlanguage{Korean~Old~Hangul}{KOH} |
| 3565 |
\newfontlanguage{Konkani}{KOK} |
| 3566 |
\newfontlanguage{Kikongo}{KON} |
| 3567 |
\newfontlanguage{Komi-Permyak}{KOP} |
| 3568 |
\newfontlanguage{Korean}{KOR} |
| 3569 |
\newfontlanguage{Komi-Zyrian}{KOZ} |
| 3570 |
\newfontlanguage{Kpelle}{KPL} |
| 3571 |
\newfontlanguage{Krio}{KRI} |
| 3572 |
\newfontlanguage{Karakalpak}{KRK} |
| 3573 |
\newfontlanguage{Karelian}{KRL} |
| 3574 |
\newfontlanguage{Karaim}{KRM} |
| 3575 |
\newfontlanguage{Karen}{KRN} |
| 3576 |
\newfontlanguage{Koorete}{KRT} |
| 3577 |
\newfontlanguage{Kashmiri}{KSH} |
| 3578 |
\newfontlanguage{Khasi}{KSI} |
| 3579 |
\newfontlanguage{Kildin~Sami}{KSM} |
| 3580 |
\newfontlanguage{Kui}{KUI} |
| 3581 |
\newfontlanguage{Kulvi}{KUL} |
| 3582 |
\newfontlanguage{Kumyk}{KUM} |
| 3583 |
\newfontlanguage{Kurdish}{KUR} |
| 3584 |
\newfontlanguage{Kurukh}{KUU} |
| 3585 |
\newfontlanguage{Kuy}{KUY} |
| 3586 |
\newfontlanguage{Koryak}{KYK} |
| 3587 |
\newfontlanguage{Ladin}{LAD} |
| 3588 |
\newfontlanguage{Lahuli}{LAH} |
| 3589 |
\newfontlanguage{Lak}{LAK} |
| 3590 |
\newfontlanguage{Lambani}{LAM} |
| 3591 |
\newfontlanguage{Lao}{LAO} |
| 3592 |
\newfontlanguage{Latin}{LAT} |
| 3593 |
\newfontlanguage{Laz}{LAZ} |
| 3594 |
\newfontlanguage{L-Cree}{LCR} |
| 3595 |
\newfontlanguage{Ladakhi}{LDK} |
| 3596 |
\newfontlanguage{Lezgi}{LEZ} |
| 3597 |
\newfontlanguage{Lingala}{LIN} |
| 3598 |
\newfontlanguage{Low~Mari}{LMA} |
| 3599 |
\newfontlanguage{Limbu}{LMB} |
| 3600 |
\newfontlanguage{Lomwe}{LMW} |
| 3601 |
\newfontlanguage{Lower~Sorbian}{LSB} |
| 3602 |
\newfontlanguage{Lule~Sami}{LSM} |
| 3603 |
\newfontlanguage{Lithuanian}{LTH} |
| 3604 |
\newfontlanguage{Luba}{LUB} |
| 3605 |
\newfontlanguage{Luganda}{LUG} |
| 3606 |
\newfontlanguage{Luhya}{LUH} |
| 3607 |
\newfontlanguage{Luo}{LUO} |
| 3608 |
\newfontlanguage{Latvian}{LVI} |
| 3609 |
\newfontlanguage{Majang}{MAJ} |
| 3610 |
\newfontlanguage{Makua}{MAK} |
| 3611 |
\newfontlanguage{Malayalam~Traditional}{MAL} |
| 3612 |
\newfontlanguage{Mansi}{MAN} |
| 3613 |
\newfontlanguage{Marathi}{MAR} |
| 3614 |
\newfontlanguage{Marwari}{MAW} |
| 3615 |
\newfontlanguage{Mbundu}{MBN} |
| 3616 |
\newfontlanguage{Manchu}{MCH} |
| 3617 |
\newfontlanguage{Moose~Cree}{MCR} |
| 3618 |
\newfontlanguage{Mende}{MDE} |
| 3619 |
\newfontlanguage{Me'en}{MEN} |
| 3620 |
\newfontlanguage{Mizo}{MIZ} |
| 3621 |
\newfontlanguage{Macedonian}{MKD} |
| 3622 |
\newfontlanguage{Male}{MLE} |
| 3623 |
\newfontlanguage{Malagasy}{MLG} |
| 3624 |
\newfontlanguage{Malinke}{MLN} |
| 3625 |
\newfontlanguage{Malayalam~Reformed}{MLR} |
| 3626 |
\newfontlanguage{Malay}{MLY} |
| 3627 |
\newfontlanguage{Mandinka}{MND} |
| 3628 |
\newfontlanguage{Mongolian}{MNG} |
| 3629 |
\newfontlanguage{Manipuri}{MNI} |
| 3630 |
\newfontlanguage{Maninka}{MNK} |
| 3631 |
\newfontlanguage{Manx~Gaelic}{MNX} |
| 3632 |
\newfontlanguage{Moksha}{MOK} |
| 3633 |
\newfontlanguage{Moldavian}{MOL} |
| 3634 |
\newfontlanguage{Mon}{MON} |
| 3635 |
\newfontlanguage{Moroccan}{MOR} |
| 3636 |
\newfontlanguage{Maori}{MRI} |
| 3637 |
\newfontlanguage{Maithili}{MTH} |
| 3638 |
\newfontlanguage{Maltese}{MTS} |
| 3639 |
\newfontlanguage{Mundari}{MUN} |
| 3640 |
\newfontlanguage{Naga-Assamese}{NAG} |
| 3641 |
\newfontlanguage{Nanai}{NAN} |
| 3642 |
\newfontlanguage{Naskapi}{NAS} |
| 3643 |
\newfontlanguage{N-Cree}{NCR} |
| 3644 |
\newfontlanguage{Ndebele}{NDB} |
| 3645 |
\newfontlanguage{Ndonga}{NDG} |
| 3646 |
\newfontlanguage{Nepali}{NEP} |
| 3647 |
\newfontlanguage{Newari}{NEW} |
| 3648 |
\newfontlanguage{Nagari}{NGR} |
| 3649 |
\newfontlanguage{Norway~House~Cree}{NHC} |
| 3650 |
\newfontlanguage{Nisi}{NIS} |
| 3651 |
\newfontlanguage{Niuean}{NIU} |
| 3652 |
\newfontlanguage{Nkole}{NKL} |
| 3653 |
\newfontlanguage{N'ko}{NKO} |
| 3654 |
\newfontlanguage{Dutch}{NLD} |
| 3655 |
\newfontlanguage{Nogai}{NOG} |
| 3656 |
\newfontlanguage{Norwegian}{NOR} |
| 3657 |
\newfontlanguage{Northern~Sami}{NSM} |
| 3658 |
\newfontlanguage{Northern~Tai}{NTA} |
| 3659 |
\newfontlanguage{Esperanto}{NTO} |
| 3660 |
\newfontlanguage{Nynorsk}{NYN} |
| 3661 |
\newfontlanguage{Oji-Cree}{OCR} |
| 3662 |
\newfontlanguage{Ojibway}{OJB} |
| 3663 |
\newfontlanguage{Oriya}{ORI} |
| 3664 |
\newfontlanguage{Oromo}{ORO} |
| 3665 |
\newfontlanguage{Ossetian}{OSS} |
| 3666 |
\newfontlanguage{Palestinian~Aramaic}{PAA} |
| 3667 |
\newfontlanguage{Pali}{PAL} |
| 3668 |
\newfontlanguage{Punjabi}{PAN} |
| 3669 |
\newfontlanguage{Palpa}{PAP} |
| 3670 |
\newfontlanguage{Pashto}{PAS} |
| 3671 |
\newfontlanguage{Polytonic~Greek}{PGR} |
| 3672 |
\newfontlanguage{Pilipino}{PIL} |
| 3673 |
\newfontlanguage{Palaung}{PLG} |
| 3674 |
\newfontlanguage{Polish}{PLK} |
| 3675 |
\newfontlanguage{Provencal}{PRO} |
| 3676 |
\newfontlanguage{Portuguese}{PTG} |
| 3677 |
\newfontlanguage{Chin}{QIN} |
| 3678 |
\newfontlanguage{Rajasthani}{RAJ} |
| 3679 |
\newfontlanguage{R-Cree}{RCR} |
| 3680 |
\newfontlanguage{Russian~Buriat}{RBU} |
| 3681 |
\newfontlanguage{Riang}{RIA} |
| 3682 |
\newfontlanguage{Rhaeto-Romanic}{RMS} |
| 3683 |
\newfontlanguage{Romanian}{ROM} |
| 3684 |
\newfontlanguage{Romany}{ROY} |
| 3685 |
\newfontlanguage{Rusyn}{RSY} |
| 3686 |
\newfontlanguage{Ruanda}{RUA} |
| 3687 |
\newfontlanguage{Russian}{RUS} |
| 3688 |
\newfontlanguage{Sadri}{SAD} |
| 3689 |
\newfontlanguage{Sanskrit}{SAN} |
| 3690 |
\newfontlanguage{Santali}{SAT} |
| 3691 |
\newfontlanguage{Sayisi}{SAY} |
| 3692 |
\newfontlanguage{Sekota}{SEK} |
| 3693 |
\newfontlanguage{Selkup}{SEL} |
| 3694 |
\newfontlanguage{Sango}{SGO} |
| 3695 |
\newfontlanguage{Shan}{SHN} |
| 3696 |
\newfontlanguage{Sibe}{SIB} |
| 3697 |
\newfontlanguage{Sidamo}{SID} |
| 3698 |
\newfontlanguage{Silte~Gurage}{SIG} |
| 3699 |
\newfontlanguage{Skolt~Sami}{SKS} |
| 3700 |
\newfontlanguage{Slovak}{SKY} |
| 3701 |
\newfontlanguage{Slavey}{SLA} |
| 3702 |
\newfontlanguage{Slovenian}{SLV} |
| 3703 |
\newfontlanguage{Somali}{SML} |
| 3704 |
\newfontlanguage{Samoan}{SMO} |
| 3705 |
\newfontlanguage{Sena}{SNA} |
| 3706 |
\newfontlanguage{Sindhi}{SND} |
| 3707 |
\newfontlanguage{Sinhalese}{SNH} |
| 3708 |
\newfontlanguage{Soninke}{SNK} |
| 3709 |
\newfontlanguage{Sodo~Gurage}{SOG} |
| 3710 |
\newfontlanguage{Sotho}{SOT} |
| 3711 |
\newfontlanguage{Albanian}{SQI} |
| 3712 |
\newfontlanguage{Serbian}{SRB} |
| 3713 |
\newfontlanguage{Saraiki}{SRK} |
| 3714 |
\newfontlanguage{Serer}{SRR} |
| 3715 |
\newfontlanguage{South~Slavey}{SSL} |
| 3716 |
\newfontlanguage{Southern~Sami}{SSM} |
| 3717 |
\newfontlanguage{Suri}{SUR} |
| 3718 |
\newfontlanguage{Svan}{SVA} |
| 3719 |
\newfontlanguage{Swedish}{SVE} |
| 3720 |
\newfontlanguage{Swadaya~Aramaic}{SWA} |
| 3721 |
\newfontlanguage{Swahili}{SWK} |
| 3722 |
\newfontlanguage{Swazi}{SWZ} |
| 3723 |
\newfontlanguage{Sutu}{SXT} |
| 3724 |
\newfontlanguage{Syriac}{SYR} |
| 3725 |
\newfontlanguage{Tabasaran}{TAB} |
| 3726 |
\newfontlanguage{Tajiki}{TAJ} |
| 3727 |
\newfontlanguage{Tamil}{TAM} |
| 3728 |
\newfontlanguage{Tatar}{TAT} |
| 3729 |
\newfontlanguage{TH-Cree}{TCR} |
| 3730 |
\newfontlanguage{Telugu}{TEL} |
| 3731 |
\newfontlanguage{Tongan}{TGN} |
| 3732 |
\newfontlanguage{Tigre}{TGR} |
| 3733 |
\newfontlanguage{Tigrinya}{TGY} |
| 3734 |
\newfontlanguage{Thai}{THA} |
| 3735 |
\newfontlanguage{Tahitian}{THT} |
| 3736 |
\newfontlanguage{Tibetan}{TIB} |
| 3737 |
\newfontlanguage{Turkish}{TRK,TUR} |
| 3738 |
\newfontlanguage{Turkmen}{TKM} |
| 3739 |
\newfontlanguage{Temne}{TMN} |
| 3740 |
\newfontlanguage{Tswana}{TNA} |
| 3741 |
\newfontlanguage{Tundra~Nenets}{TNE} |
| 3742 |
\newfontlanguage{Tonga}{TNG} |
| 3743 |
\newfontlanguage{Todo}{TOD} |
| 3744 |
\newfontlanguage{Tsonga}{TSG} |
| 3745 |
\newfontlanguage{Turoyo~Aramaic}{TUA} |
| 3746 |
\newfontlanguage{Tulu}{TUL} |
| 3747 |
\newfontlanguage{Tuvin}{TUV} |
| 3748 |
\newfontlanguage{Twi}{TWI} |
| 3749 |
\newfontlanguage{Udmurt}{UDM} |
| 3750 |
\newfontlanguage{Ukrainian}{UKR} |
| 3751 |
\newfontlanguage{Urdu}{URD} |
| 3752 |
\newfontlanguage{Upper~Sorbian}{USB} |
| 3753 |
\newfontlanguage{Uyghur}{UYG} |
| 3754 |
\newfontlanguage{Uzbek}{UZB} |
| 3755 |
\newfontlanguage{Venda}{VEN} |
| 3756 |
\newfontlanguage{Vietnamese}{VIT} |
| 3757 |
\newfontlanguage{Wa}{WA} |
| 3758 |
\newfontlanguage{Wagdi}{WAG} |
| 3759 |
\newfontlanguage{West-Cree}{WCR} |
| 3760 |
\newfontlanguage{Welsh}{WEL} |
| 3761 |
\newfontlanguage{Wolof}{WLF} |
| 3762 |
\newfontlanguage{Tai~Lue}{XBD} |
| 3763 |
\newfontlanguage{Xhosa}{XHS} |
| 3764 |
\newfontlanguage{Yakut}{YAK} |
| 3765 |
\newfontlanguage{Yoruba}{YBA} |
| 3766 |
\newfontlanguage{Y-Cree}{YCR} |
| 3767 |
\newfontlanguage{Yi~Classic}{YIC} |
| 3768 |
\newfontlanguage{Yi~Modern}{YIM} |
| 3769 |
\newfontlanguage{Chinese~Hong~Kong}{ZHH} |
| 3770 |
\newfontlanguage{Chinese~Phonetic}{ZHP} |
| 3771 |
\newfontlanguage{Chinese~Simplified}{ZHS} |
| 3772 |
\newfontlanguage{Chinese~Traditional}{ZHT} |
| 3773 |
\newfontlanguage{Zande}{ZND} |
| 3774 |
\newfontlanguage{Zulu}{ZUL} |
| 3775 |
|
| 3776 |
%%^^A%% fontspec-code-feat-aat.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 3777 |
|
| 3778 |
|
| 3779 |
\__fontspec_define_aat_feature_group:n {Ligatures} |
| 3780 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {Required} {1} {0} |
| 3781 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoRequired} {1} {1} |
| 3782 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {Common} {1} {2} |
| 3783 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoCommon} {1} {3} |
| 3784 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {Rare} {1} {4} |
| 3785 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoRare} {1} {5} |
| 3786 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {Discretionary} {1} {4} |
| 3787 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoDiscretionary} {1} {5} |
| 3788 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {Logos} {1} {6} |
| 3789 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoLogos} {1} {7} |
| 3790 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {Rebus} {1} {8} |
| 3791 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoRebus} {1} {9} |
| 3792 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {Diphthong} {1} {10} |
| 3793 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoDiphthong} {1} {11} |
| 3794 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {Squared} {1} {12} |
| 3795 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoSquared} {1} {13} |
| 3796 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {AbbrevSquared} {1} {14} |
| 3797 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoAbbrevSquared} {1} {15} |
| 3798 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {Icelandic} {1} {32} |
| 3799 |
\__fontspec_define_aat_feature:nnnn {Ligatures} {NoIcelandic} {1} {33} |
| 3800 |
\keys_define:nn {fontspec-aat} |
| 3801 |
{ |
| 3802 |
Ligatures / TeX .code:n = |
| 3803 |
{ |
| 3804 |
\tl_set:Nn \l__fontspec_mapping_tl { tex-text } |
| 3805 |
} |
| 3806 |
} |
| 3807 |
\__fontspec_define_aat_feature_group:n {Letters} |
| 3808 |
\__fontspec_define_aat_feature:nnnn {Letters} {Normal} {3} {0} |
| 3809 |
\__fontspec_define_aat_feature:nnnn {Letters} {Uppercase} {3} {1} |
| 3810 |
\__fontspec_define_aat_feature:nnnn {Letters} {Lowercase} {3} {2} |
| 3811 |
\__fontspec_define_aat_feature:nnnn {Letters} {SmallCaps} {3} {3} |
| 3812 |
\__fontspec_define_aat_feature:nnnn {Letters} {InitialCaps} {3} {4} |
| 3813 |
\__fontspec_define_aat_feature_group:n {Numbers} |
| 3814 |
\__fontspec_define_aat_feature:nnnn {Numbers} {Monospaced} {6} {0} |
| 3815 |
\__fontspec_define_aat_feature:nnnn {Numbers} {Proportional} {6} {1} |
| 3816 |
\__fontspec_define_aat_feature:nnnn {Numbers} {Lowercase} {21} {0} |
| 3817 |
\__fontspec_define_aat_feature:nnnn {Numbers} {OldStyle} {21} {0} |
| 3818 |
\__fontspec_define_aat_feature:nnnn {Numbers} {Uppercase} {21} {1} |
| 3819 |
\__fontspec_define_aat_feature:nnnn {Numbers} {Lining} {21} {1} |
| 3820 |
\__fontspec_define_aat_feature:nnnn {Numbers} {SlashedZero} {14} {5} |
| 3821 |
\__fontspec_define_aat_feature:nnnn {Numbers} {NoSlashedZero} {14} {4} |
| 3822 |
\__fontspec_define_aat_feature_group:n {Contextuals} |
| 3823 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {WordInitial} {8} {0} |
| 3824 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {NoWordInitial} {8} {1} |
| 3825 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {WordFinal} {8} {2} |
| 3826 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {NoWordFinal} {8} {3} |
| 3827 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {LineInitial} {8} {4} |
| 3828 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {NoLineInitial} {8} {5} |
| 3829 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {LineFinal} {8} {6} |
| 3830 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {NoLineFinal} {8} {7} |
| 3831 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {Inner} {8} {8} |
| 3832 |
\__fontspec_define_aat_feature:nnnn {Contextuals} {NoInner} {8} {9} |
| 3833 |
\__fontspec_define_aat_feature_group:n {Diacritics} |
| 3834 |
\__fontspec_define_aat_feature:nnnn {Diacritics} {Show} {9} {0} |
| 3835 |
\__fontspec_define_aat_feature:nnnn {Diacritics} {Hide} {9} {1} |
| 3836 |
\__fontspec_define_aat_feature:nnnn {Diacritics} {Decompose} {9} {2} |
| 3837 |
\__fontspec_define_aat_feature_group:n {VerticalPosition} |
| 3838 |
\__fontspec_define_aat_feature:nnnn {VerticalPosition} {Normal} {10} {0} |
| 3839 |
\__fontspec_define_aat_feature:nnnn {VerticalPosition} {Superior} {10} {1} |
| 3840 |
\__fontspec_define_aat_feature:nnnn {VerticalPosition} {Inferior} {10} {2} |
| 3841 |
\__fontspec_define_aat_feature:nnnn {VerticalPosition} {Ordinal} {10} {3} |
| 3842 |
\__fontspec_define_aat_feature_group:n {Fractions} |
| 3843 |
\__fontspec_define_aat_feature:nnnn {Fractions} {On} {11} {1} |
| 3844 |
\__fontspec_define_aat_feature:nnnn {Fractions} {Off} {11} {0} |
| 3845 |
\__fontspec_define_aat_feature:nnnn {Fractions} {Diagonal} {11} {2} |
| 3846 |
\__fontspec_define_aat_feature_group:n { Alternate } |
| 3847 |
\keys_define:nn {fontspec-aat} |
| 3848 |
{ |
| 3849 |
Alternate .default:n = {0} , |
| 3850 |
Alternate / unknown .code:n = |
| 3851 |
{ |
| 3852 |
\clist_map_inline:nn {#1} |
| 3853 |
{ |
| 3854 |
\__fontspec_make_AAT_feature:nn {17}{##1} |
| 3855 |
} |
| 3856 |
} |
| 3857 |
} |
| 3858 |
\__fontspec_define_aat_feature_group:n {Variant} |
| 3859 |
\keys_define:nn {fontspec-aat} |
| 3860 |
{ |
| 3861 |
Variant .default:n = {0} , |
| 3862 |
Variant / unknown .code:n = |
| 3863 |
{ |
| 3864 |
\clist_map_inline:nn {#1} |
| 3865 |
{ \__fontspec_make_AAT_feature:nn {18}{##1} } |
| 3866 |
} |
| 3867 |
} |
| 3868 |
\aliasfontfeature{Variant}{StylisticSet} |
| 3869 |
\__fontspec_define_aat_feature_group:n {Vertical} |
| 3870 |
\keys_define:nn {fontspec-aat} |
| 3871 |
{ |
| 3872 |
Vertical .choice: , |
| 3873 |
Vertical / RotatedGlyphs .code:n = |
| 3874 |
{ |
| 3875 |
\__fontspec_update_featstr:n {vertical} |
| 3876 |
} |
| 3877 |
} |
| 3878 |
\__fontspec_define_aat_feature_group:n {Style} |
| 3879 |
\__fontspec_define_aat_feature:nnnn {Style} {Italic} {32} {2} |
| 3880 |
\__fontspec_define_aat_feature:nnnn {Style} {Ruby} {28} {2} |
| 3881 |
\__fontspec_define_aat_feature:nnnn {Style} {Display} {19} {1} |
| 3882 |
\__fontspec_define_aat_feature:nnnn {Style} {Engraved} {19} {2} |
| 3883 |
\__fontspec_define_aat_feature:nnnn {Style} {Titling} {19} {4} |
| 3884 |
\__fontspec_define_aat_feature:nnnn {Style} {TitlingCaps} {19} {4} % backwards compat |
| 3885 |
\__fontspec_define_aat_feature:nnnn {Style} {TallCaps} {19} {5} |
| 3886 |
\__fontspec_define_aat_feature_group:n {CJKShape} |
| 3887 |
\__fontspec_define_aat_feature:nnnn {CJKShape} {Traditional} {20} {0} |
| 3888 |
\__fontspec_define_aat_feature:nnnn {CJKShape} {Simplified} {20} {1} |
| 3889 |
\__fontspec_define_aat_feature:nnnn {CJKShape} {JIS1978} {20} {2} |
| 3890 |
\__fontspec_define_aat_feature:nnnn {CJKShape} {JIS1983} {20} {3} |
| 3891 |
\__fontspec_define_aat_feature:nnnn {CJKShape} {JIS1990} {20} {4} |
| 3892 |
\__fontspec_define_aat_feature:nnnn {CJKShape} {Expert} {20} {10} |
| 3893 |
\__fontspec_define_aat_feature:nnnn {CJKShape} {NLC} {20} {13} |
| 3894 |
\__fontspec_define_aat_feature_group:n {CharacterWidth} |
| 3895 |
\__fontspec_define_aat_feature:nnnn {CharacterWidth} {Proportional} {22} {0} |
| 3896 |
\__fontspec_define_aat_feature:nnnn {CharacterWidth} {Full} {22} {1} |
| 3897 |
\__fontspec_define_aat_feature:nnnn {CharacterWidth} {Half} {22} {2} |
| 3898 |
\__fontspec_define_aat_feature:nnnn {CharacterWidth} {Third} {22} {3} |
| 3899 |
\__fontspec_define_aat_feature:nnnn {CharacterWidth} {Quarter} {22} {4} |
| 3900 |
\__fontspec_define_aat_feature:nnnn {CharacterWidth} {AlternateProportional} {22} {5} |
| 3901 |
\__fontspec_define_aat_feature:nnnn {CharacterWidth} {AlternateHalf} {22} {6} |
| 3902 |
\__fontspec_define_aat_feature:nnnn {CharacterWidth} {Default} {22} {7} |
| 3903 |
\__fontspec_define_aat_feature_group:n {Annotation} |
| 3904 |
\__fontspec_define_aat_feature:nnnn {Annotation} {Off} {24} {0} |
| 3905 |
\__fontspec_define_aat_feature:nnnn {Annotation} {Box} {24} {1} |
| 3906 |
\__fontspec_define_aat_feature:nnnn {Annotation} {RoundedBox} {24} {2} |
| 3907 |
\__fontspec_define_aat_feature:nnnn {Annotation} {Circle} {24} {3} |
| 3908 |
\__fontspec_define_aat_feature:nnnn {Annotation} {BlackCircle} {24} {4} |
| 3909 |
\__fontspec_define_aat_feature:nnnn {Annotation} {Parenthesis} {24} {5} |
| 3910 |
\__fontspec_define_aat_feature:nnnn {Annotation} {Period} {24} {6} |
| 3911 |
\__fontspec_define_aat_feature:nnnn {Annotation} {RomanNumerals} {24} {7} |
| 3912 |
\__fontspec_define_aat_feature:nnnn {Annotation} {Diamond} {24} {8} |
| 3913 |
\__fontspec_define_aat_feature:nnnn {Annotation} {BlackSquare} {24} {9} |
| 3914 |
\__fontspec_define_aat_feature:nnnn {Annotation} {BlackRoundSquare} {24} {10} |
| 3915 |
\__fontspec_define_aat_feature:nnnn {Annotation} {DoubleCircle} {24} {11} |
| 3916 |
|
| 3917 |
%%^^A%% fontspec-code-enc.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 3918 |
|
| 3919 |
\DeclareDocumentCommand \EncodingCommand { m O{} O{} m } |
| 3920 |
{ |
| 3921 |
\bool_if:NF \l__fontspec_defining_encoding_bool |
| 3922 |
{ \__fontspec_error:nn {only-inside-encdef} \EncodingCommand } |
| 3923 |
\DeclareTextCommand{#1}{\UnicodeEncodingName}[#2][#3]{#4} |
| 3924 |
} |
| 3925 |
\DeclareDocumentCommand \EncodingAccent {mm} |
| 3926 |
{ |
| 3927 |
\bool_if:NF \l__fontspec_defining_encoding_bool |
| 3928 |
{ \__fontspec_error:nn {only-inside-encdef} \EncodingAccent } |
| 3929 |
\DeclareTextCommand{#1}{\UnicodeEncodingName}{\add@unicode@accent{#2}} |
| 3930 |
} |
| 3931 |
\DeclareDocumentCommand \EncodingSymbol {mm} |
| 3932 |
{ |
| 3933 |
\bool_if:NF \l__fontspec_defining_encoding_bool |
| 3934 |
{ \__fontspec_error:nn {only-inside-encdef} \EncodingSymbol } |
| 3935 |
\DeclareTextSymbol{#1}{\UnicodeEncodingName}{#2} |
| 3936 |
} |
| 3937 |
\DeclareDocumentCommand \EncodingComposite {mmm} |
| 3938 |
{ |
| 3939 |
\bool_if:NF \l__fontspec_defining_encoding_bool |
| 3940 |
{ \__fontspec_error:nn {only-inside-encdef} \EncodingComposite } |
| 3941 |
\DeclareTextComposite{#1}{\UnicodeEncodingName}{#2}{#3} |
| 3942 |
} |
| 3943 |
\DeclareDocumentCommand \EncodingCompositeCommand {mmm} |
| 3944 |
{ |
| 3945 |
\bool_if:NF \l__fontspec_defining_encoding_bool |
| 3946 |
{ \__fontspec_error:nn {only-inside-encdef} \EncodingCompositeCommand } |
| 3947 |
\DeclareTextCompositeCommand{#1}{\UnicodeEncodingName}{#2}{#3} |
| 3948 |
} |
| 3949 |
\DeclareDocumentCommand \DeclareUnicodeEncoding {mm} |
| 3950 |
{ |
| 3951 |
\DeclareFontEncoding{#1}{}{} |
| 3952 |
\DeclareFontSubstitution{#1}{lmr}{m}{n} |
| 3953 |
\DeclareFontFamily{#1}{lmr}{} |
| 3954 |
|
| 3955 |
\DeclareFontShape{#1}{lmr}{m}{n} |
| 3956 |
{<->\UnicodeFontFile{lmroman10-regular}{\UnicodeFontTeXLigatures}}{} |
| 3957 |
\DeclareFontShape{#1}{lmr}{m}{it} |
| 3958 |
{<->\UnicodeFontFile{lmroman10-italic}{\UnicodeFontTeXLigatures}}{} |
| 3959 |
\DeclareFontShape{#1}{lmr}{m}{sc} |
| 3960 |
{<->\UnicodeFontFile{lmromancaps10-regular}{\UnicodeFontTeXLigatures}}{} |
| 3961 |
\DeclareFontShape{#1}{lmr}{bx}{n} |
| 3962 |
{<->\UnicodeFontFile{lmroman10-bold}{\UnicodeFontTeXLigatures}}{} |
| 3963 |
\DeclareFontShape{#1}{lmr}{bx}{it} |
| 3964 |
{<->\UnicodeFontFile{lmroman10-bolditalic}{\UnicodeFontTeXLigatures}}{} |
| 3965 |
|
| 3966 |
\tl_set_eq:NN \l__fontspec_prev_unicode_name_tl \UnicodeEncodingName |
| 3967 |
\tl_set:Nn \UnicodeEncodingName {#1} |
| 3968 |
\bool_set_true:N \l__fontspec_defining_encoding_bool |
| 3969 |
#2 |
| 3970 |
\bool_set_false:N \l__fontspec_defining_encoding_bool |
| 3971 |
\tl_set_eq:NN \UnicodeEncodingName \l__fontspec_prev_unicode_name_tl |
| 3972 |
} |
| 3973 |
\DeclareDocumentCommand \UndeclareSymbol {m} |
| 3974 |
{ |
| 3975 |
\bool_if:NF \l__fontspec_defining_encoding_bool |
| 3976 |
{ \__fontspec_error:nn {only-inside-encdef} \UndeclareSymbol } |
| 3977 |
\UndeclareTextCommand {#1} {\UnicodeEncodingName} |
| 3978 |
} |
| 3979 |
\DeclareDocumentCommand \UndeclareAccent {m} |
| 3980 |
{ |
| 3981 |
\bool_if:NF \l__fontspec_defining_encoding_bool |
| 3982 |
{ \__fontspec_error:nn {only-inside-encdef} \UndeclareAccent } |
| 3983 |
\UndeclareTextCommand {#1} {\UnicodeEncodingName} |
| 3984 |
} |
| 3985 |
\DeclareDocumentCommand \UndeclareCommand {m} |
| 3986 |
{ |
| 3987 |
\bool_if:NF \l__fontspec_defining_encoding_bool |
| 3988 |
{ \__fontspec_error:nn {only-inside-encdef} \UndeclareCommand } |
| 3989 |
\UndeclareTextCommand {#1} {\UnicodeEncodingName} |
| 3990 |
} |
| 3991 |
\DeclareDocumentCommand \UndeclareComposite {mm} |
| 3992 |
{ |
| 3993 |
\bool_if:NF \l__fontspec_defining_encoding_bool |
| 3994 |
{ \__fontspec_error:nn {only-inside-encdef} \UndeclareComposite } |
| 3995 |
\cs_undefine:c |
| 3996 |
{ \c_backslash_str \UnicodeEncodingName \token_to_str:N #1 - \tl_to_str:n {#2} } |
| 3997 |
} |
| 3998 |
|
| 3999 |
%%^^A%% fontspec-code-math.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 4000 |
\@ifpackageloaded{euler} |
| 4001 |
{ \bool_gset_true:N \g__fontspec_pkg_euler_loaded_bool } |
| 4002 |
{ \bool_gset_false:N \g__fontspec_pkg_euler_loaded_bool } |
| 4003 |
\cs_new:Nn \fontspec_setup_maths: |
| 4004 |
{ |
| 4005 |
\@ifpackageloaded{euler} |
| 4006 |
{ |
| 4007 |
\bool_if:NTF \g__fontspec_pkg_euler_loaded_bool |
| 4008 |
{ \bool_gset_true:N \g__fontspec_math_euler_bool } |
| 4009 |
{ \__fontspec_error:n {euler-too-late} } |
| 4010 |
} |
| 4011 |
{} |
| 4012 |
\@ifpackageloaded{lucbmath}{ \bool_gset_true:N \g__fontspec_math_lucida_bool }{} |
| 4013 |
\@ifpackageloaded{lucidabr}{ \bool_gset_true:N \g__fontspec_math_lucida_bool }{} |
| 4014 |
\@ifpackageloaded{lucimatx}{ \bool_gset_true:N \g__fontspec_math_lucida_bool }{} |
| 4015 |
\DeclareSymbolFont{legacymaths}{OT1}{cmr}{m}{n} |
| 4016 |
\SetSymbolFont{legacymaths}{bold}{OT1}{cmr}{bx}{n} |
| 4017 |
\DeclareMathAccent{\acute} {\mathalpha}{legacymaths}{19} |
| 4018 |
\DeclareMathAccent{\grave} {\mathalpha}{legacymaths}{18} |
| 4019 |
\DeclareMathAccent{\ddot} {\mathalpha}{legacymaths}{127} |
| 4020 |
\DeclareMathAccent{\tilde} {\mathalpha}{legacymaths}{126} |
| 4021 |
\DeclareMathAccent{\bar} {\mathalpha}{legacymaths}{22} |
| 4022 |
\DeclareMathAccent{\breve} {\mathalpha}{legacymaths}{21} |
| 4023 |
\DeclareMathAccent{\check} {\mathalpha}{legacymaths}{20} |
| 4024 |
\DeclareMathAccent{\hat} {\mathalpha}{legacymaths}{94} % too bad, euler |
| 4025 |
\DeclareMathAccent{\dot} {\mathalpha}{legacymaths}{95} |
| 4026 |
\DeclareMathAccent{\mathring}{\mathalpha}{legacymaths}{23} |
| 4027 |
\group_begin: |
| 4028 |
\mathchardef\@tempa="603A \relax |
| 4029 |
\ifx\colon\@tempa |
| 4030 |
\DeclareMathSymbol{\colon}{\mathpunct}{legacymaths}{58} |
| 4031 |
\fi |
| 4032 |
\group_end: |
| 4033 |
\bool_if:NF \g__fontspec_math_euler_bool |
| 4034 |
{ |
| 4035 |
\DeclareMathSymbol{!}{\mathclose}{legacymaths}{33} |
| 4036 |
\DeclareMathSymbol{:}{\mathrel} {legacymaths}{58} |
| 4037 |
\DeclareMathSymbol{;}{\mathpunct}{legacymaths}{59} |
| 4038 |
\DeclareMathSymbol{?}{\mathclose}{legacymaths}{63} |
| 4039 |
\bool_if:NF \g__fontspec_math_lucida_bool |
| 4040 |
{ |
| 4041 |
\DeclareMathSymbol{0}{\mathalpha}{legacymaths}{`0} |
| 4042 |
\DeclareMathSymbol{1}{\mathalpha}{legacymaths}{`1} |
| 4043 |
\DeclareMathSymbol{2}{\mathalpha}{legacymaths}{`2} |
| 4044 |
\DeclareMathSymbol{3}{\mathalpha}{legacymaths}{`3} |
| 4045 |
\DeclareMathSymbol{4}{\mathalpha}{legacymaths}{`4} |
| 4046 |
\DeclareMathSymbol{5}{\mathalpha}{legacymaths}{`5} |
| 4047 |
\DeclareMathSymbol{6}{\mathalpha}{legacymaths}{`6} |
| 4048 |
\DeclareMathSymbol{7}{\mathalpha}{legacymaths}{`7} |
| 4049 |
\DeclareMathSymbol{8}{\mathalpha}{legacymaths}{`8} |
| 4050 |
\DeclareMathSymbol{9}{\mathalpha}{legacymaths}{`9} |
| 4051 |
\DeclareMathSymbol{\Gamma}{\mathalpha}{legacymaths}{0} |
| 4052 |
\DeclareMathSymbol{\Delta}{\mathalpha}{legacymaths}{1} |
| 4053 |
\DeclareMathSymbol{\Theta}{\mathalpha}{legacymaths}{2} |
| 4054 |
\DeclareMathSymbol{\Lambda}{\mathalpha}{legacymaths}{3} |
| 4055 |
\DeclareMathSymbol{\Xi}{\mathalpha}{legacymaths}{4} |
| 4056 |
\DeclareMathSymbol{\Pi}{\mathalpha}{legacymaths}{5} |
| 4057 |
\DeclareMathSymbol{\Sigma}{\mathalpha}{legacymaths}{6} |
| 4058 |
\DeclareMathSymbol{\Upsilon}{\mathalpha}{legacymaths}{7} |
| 4059 |
\DeclareMathSymbol{\Phi}{\mathalpha}{legacymaths}{8} |
| 4060 |
\DeclareMathSymbol{\Psi}{\mathalpha}{legacymaths}{9} |
| 4061 |
\DeclareMathSymbol{\Omega}{\mathalpha}{legacymaths}{10} |
| 4062 |
\DeclareMathSymbol{+}{\mathbin}{legacymaths}{43} |
| 4063 |
\DeclareMathSymbol{=}{\mathrel}{legacymaths}{61} |
| 4064 |
\DeclareMathDelimiter{(}{\mathopen} {legacymaths}{40}{largesymbols}{0} |
| 4065 |
\DeclareMathDelimiter{)}{\mathclose}{legacymaths}{41}{largesymbols}{1} |
| 4066 |
\DeclareMathDelimiter{[}{\mathopen} {legacymaths}{91}{largesymbols}{2} |
| 4067 |
\DeclareMathDelimiter{]}{\mathclose}{legacymaths}{93}{largesymbols}{3} |
| 4068 |
\DeclareMathDelimiter{/}{\mathord}{legacymaths}{47}{largesymbols}{14} |
| 4069 |
\DeclareMathSymbol{\mathdollar}{\mathord}{legacymaths}{36} |
| 4070 |
\renewcommand{\hbar}{{\mathchar"AF\mkern-9mu h}}% TODO: test with other fonts |
| 4071 |
} |
| 4072 |
} |
| 4073 |
\DeclareSymbolFont{operators}\g_fontspec_encoding_tl\g__fontspec_mathrm_tl\mddefault\shapedefault |
| 4074 |
\SetSymbolFont{operators}{normal}\g_fontspec_encoding_tl\g__fontspec_mathrm_tl\mddefault\shapedefault |
| 4075 |
\DeclareSymbolFontAlphabet\mathrm{operators} |
| 4076 |
\SetMathAlphabet\mathit{normal}\g_fontspec_encoding_tl\g__fontspec_mathrm_tl\mddefault\itdefault |
| 4077 |
\SetMathAlphabet\mathbf{normal}\g_fontspec_encoding_tl\g__fontspec_mathrm_tl\bfdefault\shapedefault |
| 4078 |
\SetMathAlphabet\mathsf{normal}\g_fontspec_encoding_tl\g__fontspec_mathsf_tl\mddefault\shapedefault |
| 4079 |
\SetMathAlphabet\mathtt{normal}\g_fontspec_encoding_tl\g__fontspec_mathtt_tl\mddefault\shapedefault |
| 4080 |
\SetSymbolFont{operators}{bold}\g_fontspec_encoding_tl\g__fontspec_mathrm_tl\bfdefault\shapedefault |
| 4081 |
\tl_if_empty:NTF \g__fontspec_bfmathrm_tl |
| 4082 |
{ |
| 4083 |
\SetMathAlphabet\mathit{bold}\g_fontspec_encoding_tl\g__fontspec_mathrm_tl\bfdefault\itdefault |
| 4084 |
} |
| 4085 |
{ |
| 4086 |
\SetMathAlphabet\mathrm{bold}\g_fontspec_encoding_tl\g__fontspec_bfmathrm_tl\mddefault\shapedefault |
| 4087 |
\SetMathAlphabet\mathbf{bold}\g_fontspec_encoding_tl\g__fontspec_bfmathrm_tl\bfdefault\shapedefault |
| 4088 |
\SetMathAlphabet\mathit{bold}\g_fontspec_encoding_tl\g__fontspec_bfmathrm_tl\mddefault\itdefault |
| 4089 |
} |
| 4090 |
\SetMathAlphabet\mathsf{bold}\g_fontspec_encoding_tl\g__fontspec_mathsf_tl\bfdefault\shapedefault |
| 4091 |
\SetMathAlphabet\mathtt{bold}\g_fontspec_encoding_tl\g__fontspec_mathtt_tl\bfdefault\shapedefault |
| 4092 |
} |
| 4093 |
\cs_new:Nn \fontspec_maybe_setup_maths: |
| 4094 |
{ |
| 4095 |
\@ifpackageloaded{anttor} |
| 4096 |
{ |
| 4097 |
\ifx\define@antt@mathversions a\bool_gset_false:N \g__fontspec_math_bool\fi |
| 4098 |
}{} |
| 4099 |
\@ifpackageloaded{arevmath} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4100 |
\@ifpackageloaded{eulervm} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4101 |
\@ifpackageloaded{mathdesign} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4102 |
\@ifpackageloaded{concmath} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4103 |
\@ifpackageloaded{cmbright} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4104 |
\@ifpackageloaded{mathesf} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4105 |
\@ifpackageloaded{gfsartemisia} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4106 |
\@ifpackageloaded{gfsneohellenic} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4107 |
\@ifpackageloaded{iwona} |
| 4108 |
{ |
| 4109 |
\ifx\define@iwona@mathversions a\bool_set_false:N \g__fontspec_math_bool\fi |
| 4110 |
}{} |
| 4111 |
\@ifpackageloaded{kpfonts}{\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4112 |
\@ifpackageloaded{kmath} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4113 |
\@ifpackageloaded{kurier} |
| 4114 |
{ |
| 4115 |
\ifx\define@kurier@mathversions a\bool_set_false:N \g__fontspec_math_bool\fi |
| 4116 |
}{} |
| 4117 |
\@ifpackageloaded{fouriernc} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4118 |
\@ifpackageloaded{fourier} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4119 |
\@ifpackageloaded{lmodern} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4120 |
\@ifpackageloaded{mathpazo} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4121 |
\@ifpackageloaded{mathptmx} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4122 |
\@ifpackageloaded{MinionPro} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4123 |
\@ifpackageloaded{unicode-math} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4124 |
\@ifpackageloaded{breqn} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4125 |
\@ifpackageloaded{pxfonts} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4126 |
\@ifpackageloaded{txfonts} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4127 |
\@ifpackageloaded{newpxmath} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4128 |
\@ifpackageloaded{newtxmath} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4129 |
\@ifpackageloaded{mtpro2} {\bool_gset_false:N \g__fontspec_math_bool}{} |
| 4130 |
\bool_if:NT \g__fontspec_math_bool |
| 4131 |
{ |
| 4132 |
\__fontspec_info:n {setup-math} |
| 4133 |
\fontspec_setup_maths: |
| 4134 |
} |
| 4135 |
} |
| 4136 |
\AtBeginDocument{\fontspec_maybe_setup_maths:} |
| 4137 |
|
| 4138 |
%%^^A%% fontspec-code-closing.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 4139 |
\bool_if:NT \g__fontspec_cfg_bool |
| 4140 |
{ |
| 4141 |
\InputIfFileExists{fontspec.cfg} |
| 4142 |
{} |
| 4143 |
{ \typeout{No~ fontspec.cfg~ file~ found;~ no~ configuration~ loaded.} } |
| 4144 |
} |
| 4145 |
|
| 4146 |
%%^^A%% fontspec-code-xfss.dtx -- part of FONTSPEC <latex3.github.io/fontspec> |
| 4147 |
|
| 4148 |
\providecommand*\scitdefault{\scdefault\itdefault} |
| 4149 |
\providecommand*\scsldefault{\scdefault\sldefault} |
| 4150 |
\providecommand*\scswdefault{\scdefault\swdefault} |
| 4151 |
\cs_new:Nn \__fontspec_shape_merge:nn { c__fontspec_shape_#1_#2_tl } |
| 4152 |
\cs_new:Nn \__fontspec_merge_default_shapes: |
| 4153 |
{ |
| 4154 |
\tl_const:cn { \__fontspec_shape_merge:nn \shapedefault\scdefault } {\scdefault} |
| 4155 |
\tl_const:cn { \__fontspec_shape_merge:nn \itdefault \scdefault } {\scitdefault} |
| 4156 |
\tl_const:cn { \__fontspec_shape_merge:nn \sldefault \scdefault } {\scsldefault} |
| 4157 |
\tl_const:cn { \__fontspec_shape_merge:nn \swdefault \scdefault } {\scswdefault} |
| 4158 |
\tl_const:cn { \__fontspec_shape_merge:nn \scdefault \itdefault } {\scitdefault} |
| 4159 |
\tl_const:cn { \__fontspec_shape_merge:nn \scdefault \sldefault } {\scsldefault} |
| 4160 |
\tl_const:cn { \__fontspec_shape_merge:nn \scdefault \swdefault } {\scswdefault} |
| 4161 |
\tl_const:cn { \__fontspec_shape_merge:nn \scsldefault \itdefault } {\scitdefault} |
| 4162 |
\tl_const:cn { \__fontspec_shape_merge:nn \scitdefault \sldefault } {\scsldefault} |
| 4163 |
\tl_const:cn { \__fontspec_shape_merge:nn \scitdefault \shapedefault } {\scdefault} |
| 4164 |
\tl_const:cn { \__fontspec_shape_merge:nn \scsldefault \shapedefault } {\scdefault} |
| 4165 |
} |
| 4166 |
\__fontspec_merge_default_shapes: |
| 4167 |
\prg_new_conditional:Nnn \__fontspec_if_merge_shape:n {TF} |
| 4168 |
{ |
| 4169 |
\bool_lazy_and:nnTF |
| 4170 |
{ \tl_if_exist_p:c { \__fontspec_shape_merge:nn {\f@shape} {#1} } } |
| 4171 |
{ |
| 4172 |
\cs_if_exist_p:c |
| 4173 |
{ |
| 4174 |
\f@encoding/\f@family/\f@series/ |
| 4175 |
\tl_use:c { \__fontspec_shape_merge:nn {\f@shape} {#1} } |
| 4176 |
} |
| 4177 |
} |
| 4178 |
\prg_return_true: \prg_return_false: |
| 4179 |
} |
| 4180 |
\cs_set_eq:NN \emfontdeclare \DeclareEmphSequence |
| 4181 |
\cs_set_protected:Npn \strongfontdeclare #1 |
| 4182 |
{ |
| 4183 |
\prop_gclear:N \g__fontspec_strong_prop |
| 4184 |
\int_zero:N \l__fontspec_strongdef_int |
| 4185 |
|
| 4186 |
\group_begin: |
| 4187 |
\normalfont |
| 4188 |
\clist_map_inline:nn {\strongreset,#1} |
| 4189 |
{ |
| 4190 |
##1 |
| 4191 |
\prop_gput_if_not_in:NeV \g__fontspec_strong_prop { \f@series } { \l__fontspec_strongdef_int } |
| 4192 |
\prop_gput:Nen \g__fontspec_strong_prop { switch-\int_use:N \l__fontspec_strongdef_int } { ##1 } |
| 4193 |
\int_incr:N \l__fontspec_strongdef_int |
| 4194 |
} |
| 4195 |
\group_end: |
| 4196 |
} |
| 4197 |
\DeclareRobustCommand \strongenv |
| 4198 |
{ |
| 4199 |
\@nomath\strongenv |
| 4200 |
|
| 4201 |
\prop_get:NeNT \g__fontspec_strong_prop { \f@series } \l__fontspec_strong_tmp_tl |
| 4202 |
{ |
| 4203 |
\int_set:Nn \l__fontspec_strong_int { \l__fontspec_strong_tmp_tl } |
| 4204 |
} |
| 4205 |
|
| 4206 |
\int_incr:N \l__fontspec_strong_int |
| 4207 |
|
| 4208 |
\prop_get:NeNTF \g__fontspec_strong_prop { switch-\int_use:N \l__fontspec_strong_int } \l__fontspec_strong_switch_tl |
| 4209 |
{ \l__fontspec_strong_switch_tl } |
| 4210 |
{ |
| 4211 |
\int_zero:N \l__fontspec_strong_int |
| 4212 |
\strongreset |
| 4213 |
} |
| 4214 |
|
| 4215 |
} |
| 4216 |
\DeclareTextFontCommand{\strong}{\strongenv} |
| 4217 |
\cs_set:Npn \strongreset {} |
| 4218 |
\cs_set_protected:Npn \reset@font |
| 4219 |
{ |
| 4220 |
\normalfont |
| 4221 |
\int_zero:N \l__fontspec_strong_int |
| 4222 |
} |
| 4223 |
\strongfontdeclare{\bfseries} |
| 4224 |
|