diff options
Diffstat (limited to 'Master/texmf-dist/source/latex/fontspec')
34 files changed, 190 insertions, 368 deletions
diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-api.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-api.dtx index 09340f273fb..b0b6b0a87de 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-api.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-api.dtx @@ -356,7 +356,7 @@ { \tl_if_eq:ccTF { \f@encoding/\f@family/\f@series/\l_@@_smcp_shape_tl } - { \f@encoding/\f@family/\f@series/\updefault } + { \f@encoding/\f@family/\f@series/\shapedefault } { \prg_return_false: } { \prg_return_true: } } @@ -378,7 +378,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-closing.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-closing.dtx index 17fb823eefd..4dca137a7dc 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-closing.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-closing.dtx @@ -32,7 +32,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-enc.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-enc.dtx index 1508176e32e..8969c1be9cc 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-enc.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-enc.dtx @@ -147,7 +147,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-feat-aat.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-feat-aat.dtx index 7fc1e382b7a..4c60399a22e 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-feat-aat.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-feat-aat.dtx @@ -230,7 +230,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-feat-opentype.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-feat-opentype.dtx index 706ea238542..80a85795bc0 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-feat-opentype.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-feat-opentype.dtx @@ -569,7 +569,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-fontload.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-fontload.dtx index 88a107896f6..ac403028e18 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-fontload.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-fontload.dtx @@ -124,7 +124,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-graphite.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-graphite.dtx index a39cfe36aa1..c840d2af604 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-graphite.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-graphite.dtx @@ -116,7 +116,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-interfaces.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-interfaces.dtx index 2962d2e49d8..b5c909fcfcc 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-interfaces.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-interfaces.dtx @@ -284,7 +284,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-internal.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-internal.dtx index 50ae7498cd3..7e159a1e105 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-internal.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-internal.dtx @@ -233,14 +233,14 @@ %<debug>\typeout{Set~ base~ font~ for~ preliminary~ analysis: \@@_construct_font_call:nn { \l_@@_fontname_up_tl } {} } \@@_primitive_font_set:NnnF \l_@@_test_font - { \@@_construct_font_call:nn { \l_@@_fontname_up_tl } {} } + { \@@_construct_font_call:nn { \l_@@_fontname_up_tl } { \l_@@_pre_feat_sclist } } { \f@size pt - 2sp } { \@@_error:nx {font-not-found} {\l_@@_fontname_up_tl} } %<debug>\typeout{Set~ base~ font~ properly: \@@_construct_font_call:nn { \l_@@_fontname_up_tl } {} } \@@_set_font_type:N \l_@@_test_font \@@_primitive_font_gset:Onn \l_@@_fontface_cs_tl - { \@@_construct_font_call:nn { \l_@@_fontname_up_tl } {} } + { \@@_construct_font_call:nn { \l_@@_fontname_up_tl } { \l_@@_pre_feat_sclist } } { \f@size pt } \l_@@_fontface_cs_tl % this is necessary for LuaLaTeX to check the scripts properly @@ -496,13 +496,12 @@ % \begin{macrocode} \cs_new:Nn \@@_set_faces: { - \@@_add_nfssfont:nnnn \mddefault \updefault \l_fontspec_fontname_tl \l_@@_fontfeat_up_clist - \@@_add_nfssfont:nnnn \bfdefault \updefault \l_@@_fontname_bf_tl \l_@@_fontfeat_bf_clist - \@@_add_nfssfont:nnnn \mddefault \itdefault \l_@@_fontname_it_tl \l_@@_fontfeat_it_clist - \@@_add_nfssfont:nnnn \mddefault \sldefault \l_@@_fontname_sl_tl \l_@@_fontfeat_sl_clist - \@@_add_nfssfont:nnnn \bfdefault \itdefault \l_@@_fontname_bfit_tl \l_@@_fontfeat_bfit_clist - \@@_add_nfssfont:nnnn \bfdefault \sldefault \l_@@_fontname_bfsl_tl \l_@@_fontfeat_bfsl_clist - + \@@_add_nfssfont:nnnn \mddefault \shapedefault \l_fontspec_fontname_tl \l_@@_fontfeat_up_clist + \@@_add_nfssfont:nnnn \bfdefault \shapedefault \l_@@_fontname_bf_tl \l_@@_fontfeat_bf_clist + \@@_add_nfssfont:nnnn \mddefault \itdefault \l_@@_fontname_it_tl \l_@@_fontfeat_it_clist + \@@_add_nfssfont:nnnn \mddefault \sldefault \l_@@_fontname_sl_tl \l_@@_fontfeat_sl_clist + \@@_add_nfssfont:nnnn \bfdefault \itdefault \l_@@_fontname_bfit_tl \l_@@_fontfeat_bfit_clist + \@@_add_nfssfont:nnnn \bfdefault \sldefault \l_@@_fontname_bfsl_tl \l_@@_fontfeat_bfsl_clist \prop_map_inline:Nn \l_@@_nfssfont_prop { \@@_set_faces_aux:nnnnn ##2 } } % \end{macrocode} @@ -646,8 +645,8 @@ \prg_new_conditional:Nnn \@@_if_autofont:nn {T,TF} { \group_begin: - \@@_primitive_font_set:Nnn \l_@@_tmpa_font { \@@_construct_font_call:nn {#1} {} } { \f@size pt + 1sp } - \@@_primitive_font_set:Nnn \l_@@_tmpb_font { \@@_construct_font_call:nn {#1#2} {} } { \f@size pt + 1sp } + \@@_primitive_font_set:Nnn \l_@@_tmpa_font { \@@_construct_font_call:nn {#1} { \l_@@_pre_feat_sclist } } { \f@size pt + 1sp } + \@@_primitive_font_set:Nnn \l_@@_tmpb_font { \@@_construct_font_call:nn {#1#2} { \l_@@_pre_feat_sclist } } { \f@size pt + 1sp } \str_if_eq:eeTF { \@@_primitive_font_get_name:N \l_@@_tmpa_font } { \@@_primitive_font_get_name:N \l_@@_tmpb_font } { \group_end: \prg_return_false: } { \group_end: \prg_return_true: } @@ -683,7 +682,7 @@ { \clist_clear:N \l_@@_fontopts_clist } \keys_set_groups:nnV {fontspec/fontname} {getfontname} \l_@@_fontopts_clist \@@_primitive_font_set:OnnF \l_@@_fontface_cs_tl - { \@@_construct_font_call:nn {#1} {} } { \f@size pt } + { \@@_construct_font_call:nn {#1} { \l_@@_pre_feat_sclist } } { \f@size pt } { \@@_error:nx {font-not-found} {#2} } } % \end{macrocode} @@ -882,8 +881,8 @@ \exp_not:n { \\ } -~ \exp_not:N \str_case:nn {#1/#2} { - {\mddefault/\updefault} {'normal'~} - {\bfdefault/\updefault} {'bold'~} + {\mddefault/\shapedefault} {'normal'~} + {\bfdefault/\shapedefault} {'bold'~} {\mddefault/\itdefault} {'italic'~} {\mddefault/\sldefault} {'slanted'~} {\bfdefault/\itdefault} {'bold~ italic'~} @@ -896,10 +895,10 @@ { {\mddefault/\scdefault} {'small~ caps'~} {\bfdefault/\scdefault} {'bold~ small~ caps'~} - {\mddefault/\itscdefault} {'italic~ small~ caps'~} - {\bfdefault/\itscdefault} {'bold~ italic~ small~ caps'~} - {\mddefault/\slscdefault} {'slanted~ small~ caps'~} - {\bfdefault/\slscdefault} {'bold~ slanted~ small~ caps'~} + {\mddefault/\scitdefault} {'italic~ small~ caps'~} + {\bfdefault/\scitdefault} {'bold~ italic~ small~ caps'~} + {\mddefault/\scsldefault} {'slanted~ small~ caps'~} + {\bfdefault/\scsldefault} {'bold~ slanted~ small~ caps'~} }~( #1 / \@@_combo_sc_shape:n {#2} )~ with~ NFSS~ spec.:~ \l_@@_nfss_sc_tl @@ -1184,7 +1183,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-keyval.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-keyval.dtx index d7d0f15688d..ad8e0629b58 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-keyval.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-keyval.dtx @@ -99,7 +99,7 @@ \keys_define:nn {fontspec-renderer} { Renderer .choices:nn = - {AAT,ICU,OpenType,Graphite,Full,Basic,Node,Base,Harfbuzz} + {AAT,ICU,OpenType,Graphite,Full,Basic,Node,Base,HarfBuzz,Harfbuzz} { \int_compare:nTF {\l_keys_choice_int <= 4} { @@ -111,7 +111,7 @@ \tl_gset:Nx \g_@@_single_feat_tl { \l_@@_renderer_tl } } { - \@@_warning:nx {only-luatex-feature} {Renderer=Full/Basic/Node/Base/Harfbuzz} + \@@_warning:nx {only-luatex-feature} {Renderer=Full/Basic/Node/Base/HarfBuzz} } } } @@ -120,18 +120,18 @@ \keys_define:nn {fontspec-renderer} { Renderer .choices:nn = - {Full,Node,Basic,Base,Harfbuzz,OpenType,AAT,Graphite} + {Full,Node,Basic,Base,HarfBuzz,Harfbuzz,OpenType,AAT,Graphite} { \int_compare:nT {\l_keys_choice_int >= 5} { \bool_set_true:N \l_@@_harfbuzz_bool } \tl_set:Nx \l_@@_mode_tl { - \int_case:nn \l_keys_choice_int { 1 {node} 2 {node} 3 {base} 4 {base} 5 {harf} 6 {harf} 7 {harf} 8 {harf} } + \int_case:nn \l_keys_choice_int { 1 {node} 2 {node} 3 {base} 4 {base} 5 {harf} 6 {harf} 7 {harf} 8 {harf} 9 {harf}} } \tl_set:Nx \l_@@_shaper_tl { - \int_case:nn \l_keys_choice_int { 1 {} 2 {} 3 {} 4 {} 5 {} 6 {ot} 7 {coretext_aat} 8 {graphite2} } + \int_case:nn \l_keys_choice_int { 1 {} 2 {} 3 {} 4 {} 5 {} 6 {} 7 {ot} 8 {coretext_aat} 9 {graphite2} } } %<debug>\typeout{Mode:~"\l_@@_mode_tl"~/~Shaper:~"\l_@@_shaper_tl"} @@ -379,6 +379,15 @@ } % \end{macrocode} % +% A hack to fix a test, needs to be investigated why necessary! +% \begin{macrocode} +\@@_keys_define_code:nnn {fontspec-opentype} {UprightFont} {} +\@@_keys_define_code:nnn {fontspec-opentype} {ItalicFont} {} +\@@_keys_define_code:nnn {fontspec-opentype} {BoldFont} {} +\@@_keys_define_code:nnn {fontspec-opentype} {BoldItalicFont} {} +% \end{macrocode} + +% % % % \subsection{General font-independent features} @@ -883,7 +892,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-lang.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-lang.dtx index 7b7acfc921a..f9ea7f6cd70 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-lang.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-lang.dtx @@ -407,7 +407,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-load.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-load.dtx index 93b25e92e3a..7d0501b89e1 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-load.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-load.dtx @@ -60,7 +60,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-math.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-math.dtx index dd6dfdad05f..bbe70ef437c 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-math.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-math.dtx @@ -159,25 +159,25 @@ % as per usual with \cmd\setboldmathrm, which stores the appropriate % family name in \cmd\g_@@_bfmathrm_tl. % \begin{macrocode} - \DeclareSymbolFont{operators}\g_fontspec_encoding_tl\g_@@_mathrm_tl\mddefault\updefault - \SetSymbolFont{operators}{normal}\g_fontspec_encoding_tl\g_@@_mathrm_tl\mddefault\updefault + \DeclareSymbolFont{operators}\g_fontspec_encoding_tl\g_@@_mathrm_tl\mddefault\shapedefault + \SetSymbolFont{operators}{normal}\g_fontspec_encoding_tl\g_@@_mathrm_tl\mddefault\shapedefault \DeclareSymbolFontAlphabet\mathrm{operators} \SetMathAlphabet\mathit{normal}\g_fontspec_encoding_tl\g_@@_mathrm_tl\mddefault\itdefault - \SetMathAlphabet\mathbf{normal}\g_fontspec_encoding_tl\g_@@_mathrm_tl\bfdefault\updefault - \SetMathAlphabet\mathsf{normal}\g_fontspec_encoding_tl\g_@@_mathsf_tl\mddefault\updefault - \SetMathAlphabet\mathtt{normal}\g_fontspec_encoding_tl\g_@@_mathtt_tl\mddefault\updefault - \SetSymbolFont{operators}{bold}\g_fontspec_encoding_tl\g_@@_mathrm_tl\bfdefault\updefault + \SetMathAlphabet\mathbf{normal}\g_fontspec_encoding_tl\g_@@_mathrm_tl\bfdefault\shapedefault + \SetMathAlphabet\mathsf{normal}\g_fontspec_encoding_tl\g_@@_mathsf_tl\mddefault\shapedefault + \SetMathAlphabet\mathtt{normal}\g_fontspec_encoding_tl\g_@@_mathtt_tl\mddefault\shapedefault + \SetSymbolFont{operators}{bold}\g_fontspec_encoding_tl\g_@@_mathrm_tl\bfdefault\shapedefault \tl_if_empty:NTF \g_@@_bfmathrm_tl { \SetMathAlphabet\mathit{bold}\g_fontspec_encoding_tl\g_@@_mathrm_tl\bfdefault\itdefault } { - \SetMathAlphabet\mathrm{bold}\g_fontspec_encoding_tl\g_@@_bfmathrm_tl\mddefault\updefault - \SetMathAlphabet\mathbf{bold}\g_fontspec_encoding_tl\g_@@_bfmathrm_tl\bfdefault\updefault + \SetMathAlphabet\mathrm{bold}\g_fontspec_encoding_tl\g_@@_bfmathrm_tl\mddefault\shapedefault + \SetMathAlphabet\mathbf{bold}\g_fontspec_encoding_tl\g_@@_bfmathrm_tl\bfdefault\shapedefault \SetMathAlphabet\mathit{bold}\g_fontspec_encoding_tl\g_@@_bfmathrm_tl\mddefault\itdefault } - \SetMathAlphabet\mathsf{bold}\g_fontspec_encoding_tl\g_@@_mathsf_tl\bfdefault\updefault - \SetMathAlphabet\mathtt{bold}\g_fontspec_encoding_tl\g_@@_mathtt_tl\bfdefault\updefault + \SetMathAlphabet\mathsf{bold}\g_fontspec_encoding_tl\g_@@_mathsf_tl\bfdefault\shapedefault + \SetMathAlphabet\mathtt{bold}\g_fontspec_encoding_tl\g_@@_mathtt_tl\bfdefault\shapedefault } % \end{macrocode} % \end{macro} @@ -248,7 +248,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-msg.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-msg.dtx index 1fb845f7067..f23ec2d85f7 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-msg.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-msg.dtx @@ -268,7 +268,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-opening.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-opening.dtx index ed2a1cba30b..b8fb02e9e8e 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-opening.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-opening.dtx @@ -201,7 +201,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-opentype.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-opentype.dtx index 2a2f2703e3e..ad9413eca44 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-opentype.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-opentype.dtx @@ -466,7 +466,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-patches.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-patches.dtx index 14037be0757..31a72193e8d 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-patches.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-patches.dtx @@ -6,171 +6,19 @@ %<*fontspec> % \end{macrocode} % -% -% \subsection{Verbatims} -% -% Many thanks to Apostolos Syropoulos for discovering this problem and writing the redefinion of \LaTeX's |verbatim| environment and \cs{verb*} command. -% -% \begin{macro}{\fontspec_visible_space:} -% Print \unichar{2423}{Open box}, which is used to visibly display a space character. -% \begin{macrocode} -\cs_new_protected:Nn \fontspec_visible_space: - { - \@@_primitive_font_glyph_if_exist:NnTF \font {"2423} - { \char"2423\scan_stop: } - { \fontspec_visible_space_fallback: } - } -% \end{macrocode} -% \end{macro} -% -% \begin{macro}{\fontspec_visible_space_fallback:} -% If the current font doesn't have \unichar{2423}{Open box}, use Latin Modern Mono instead. -% \begin{macrocode} -\cs_new_protected:Nn \fontspec_visible_space_fallback: - { - { - \usefont{\g_fontspec_encoding_tl}{lmtt}{\f@series}{\f@shape} - \textvisiblespace - } - } -% \end{macrocode} -% \end{macro} -% -% \begin{macro}{\fontspec_print_visible_spaces:} -% Helper macro to turn spaces (\verb|^^20|) active and print visible space instead. -% \begin{macrocode} -\group_begin: -\char_set_catcode_active:n{"20}% -\cs_gset:Npn\fontspec_print_visible_spaces:{% -\char_set_catcode_active:n{"20}% -\cs_set_eq:NN^^20\fontspec_visible_space:% -}% -\group_end: -% \end{macrocode} -% \end{macro} -% -% In 2019 there will be a new kernel-supported command for generalising `verbatim visible spaces'. -% For now we check if the new command is defined and disable all patching if so. -% In 2020, I suppose, I'll remove all the patching code here. -% -% \begin{macrocode} -\AtBeginDocument - { - \cs_if_exist:NF \verbvisiblespace - { - \@@_patch_verb: - \@@_patch_verbatim: - \@@_patch_moreverb: - \@@_patch_fancyvrb: - \@@_patch_listings: - } - } -% \end{macrocode} -% -% -% \begin{macro}{\verb} -% \begin{macro}{\verb*} -% Redefine \cmd\verb\ to use \cmd\fontspec_print_visible_spaces:. -% \begin{macrocode} -\cs_new_protected:Npn \@@_patch_verb: - { - \def\verb - { - \relax\ifmmode\hbox\else\leavevmode\null\fi - \bgroup - \verb@eol@error \let\do\@makeother \dospecials - \verbatim@font\@noligs - \@ifstar\@@sverb\@verb - } - \def\@@sverb{\fontspec_print_visible_spaces:\@sverb} - } -% \end{macrocode} -% \end{macro} -% \end{macro} -% -% -% \begin{environment}{verbatim*} -% With the \pkg{verbatim} package. -% \begin{macrocode} -\cs_new_protected:Npn \@@_patch_verbatim: - { - \@ifpackageloaded{verbatim} - { - \cs_set:cpn {verbatim*} - { - \group_begin: \@verbatim \fontspec_print_visible_spaces: \verbatim@start - } - } -% \end{macrocode} -% This is for vanilla \LaTeX. -% \begin{macrocode} - { - \cs_set:cpn {verbatim*} - { - \@verbatim \fontspec_print_visible_spaces: \@sxverbatim - } - } - } -% \end{macrocode} -% \end{environment} -% -% \begin{environment}{listingcont*} -% This is for \pkg{moreverb}. -% The main |listing*| environment inherits this definition. -% \begin{macrocode} -\cs_new_protected:Npn \@@_patch_moreverb: - { - \@ifpackageloaded{moreverb} - { - \cs_set:cpn {listingcont*} - { - \cs_set:Npn \verbatim@processline - { - \thelisting@line \global\advance\listing@line1\relax - \the\verbatim@line\par - } - \@verbatim \fontspec_print_visible_spaces: \verbatim@start - } - }{} - } -% \end{macrocode} -% \end{environment} -% -% \pkg{listings} and \pkg{fancvrb} make things nice and easy: -% \begin{macrocode} -\cs_new_protected:Npn \@@_patch_fancyvrb: - { - \@ifpackageloaded{fancyvrb} - { - \cs_set_eq:NN \FancyVerbSpace \fontspec_visible_space: - }{} - } -% \end{macrocode} -% -% \begin{macrocode} -\cs_new_protected:Npn \@@_patch_listings: - { - \@ifpackageloaded{listings} - { - \cs_set_eq:NN \lst@visiblespace \fontspec_visible_space: - }{} - } -% \end{macrocode} -% -% +% Nothing here right now. % % \begin{macrocode} %</fontspec> % \end{macrocode} - \endinput % /© % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-scripts.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-scripts.dtx index 23f4b1794f9..32e861f5660 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-scripts.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-scripts.dtx @@ -182,7 +182,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-user.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-user.dtx index 7cbafbf8b05..aa739b4dee8 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-user.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-user.dtx @@ -27,6 +27,25 @@ % \end{macrocode} % \end{macro} % +% \begin{macro}{\rmfamily} +% \begin{macro}{\sffamily} +% \begin{macro}{\ttfamily} +% Add an encoding switch to the three family commands. +% \begin{macrocode} +\tl_replace_all:cnn { rmfamily~ } { \fontfamily } + { \fontencoding \l_@@_rmfamily_encoding_tl \fontfamily } +\tl_replace_all:cnn { sffamily~ } { \fontfamily } + { \fontencoding \l_@@_sffamily_encoding_tl \fontfamily } +\tl_replace_all:cnn { ttfamily~ } { \fontfamily } + { \fontencoding \l_@@_ttfamily_encoding_tl \fontfamily } +\tl_set_eq:NN \l_@@_rmfamily_encoding_tl \g_fontspec_encoding_tl +\tl_set_eq:NN \l_@@_sffamily_encoding_tl \g_fontspec_encoding_tl +\tl_set_eq:NN \l_@@_ttfamily_encoding_tl \g_fontspec_encoding_tl +% \end{macrocode} +% \end{macro} +% \end{macro} +% \end{macro} +% % \begin{macro}{\setmainfont} % The following three macros perform equivalent operations setting % the default font for a particular family: `roman', sans serif, or typewriter @@ -39,18 +58,10 @@ { \fontspec_set_family:Nnn \l_@@_rmfamily_family_tl {#1} {#2} \tl_set_eq:NN \rmdefault \l_@@_rmfamily_family_tl - \use:x - { - \exp_not:n { \DeclareRobustCommand \rmfamily } - { - \exp_not:N \fontencoding { \g_@@_nfss_enc_tl } - \exp_not:N \fontfamily { \exp_not:N \rmdefault } - \exp_not:N \selectfont - } - } + \tl_set_eq:NN \l_@@_rmfamily_encoding_tl \g_@@_nfss_enc_tl \str_if_eq:eeT {\familydefault} {\rmdefault} { \tl_set_eq:NN \encodingdefault \g_@@_nfss_enc_tl } - \@@_setmainfont_hook:nn {#1} {#2} + \@@_setmainfont_hook:nn {#1} {#2} % for unicode-math only \normalfont } % \end{macrocode} @@ -63,18 +74,10 @@ { \fontspec_set_family:Nnn \l_@@_sffamily_family_tl {#1} {#2} \tl_set_eq:NN \sfdefault \l_@@_sffamily_family_tl - \use:x - { - \exp_not:n { \DeclareRobustCommand \sffamily } - { - \exp_not:N \fontencoding { \g_@@_nfss_enc_tl } - \exp_not:N \fontfamily { \exp_not:N \sfdefault } - \exp_not:N \selectfont - } - } + \tl_set_eq:NN \l_@@_sffamily_encoding_tl \g_@@_nfss_enc_tl \str_if_eq:eeT {\familydefault} {\sfdefault} { \tl_set_eq:NN \encodingdefault \g_@@_nfss_enc_tl } - \@@_setsansfont_hook:nn {#1} {#2} + \@@_setsansfont_hook:nn {#1} {#2} % for unicode-math only \normalfont } % \end{macrocode} @@ -87,18 +90,10 @@ { \fontspec_set_family:Nnn \l_@@_ttfamily_family_tl {#1} {#2} \tl_set_eq:NN \ttdefault \l_@@_ttfamily_family_tl - \use:x - { - \exp_not:n { \DeclareRobustCommand \ttfamily } - { - \exp_not:N \fontencoding { \g_@@_nfss_enc_tl } - \exp_not:N \fontfamily { \exp_not:N \ttdefault } - \exp_not:N \selectfont - } - } + \tl_set_eq:NN \l_@@_ttfamily_encoding_tl \g_@@_nfss_enc_tl \str_if_eq:eeT {\familydefault} {\ttdefault} { \tl_set_eq:NN \encodingdefault \g_@@_nfss_enc_tl } - \@@_setmonofont_hook:nn {#1} {#2} + \@@_setmonofont_hook:nn {#1} {#2} % for unicode-math only \normalfont } % \end{macrocode} @@ -118,7 +113,7 @@ { %<XE> \fontspec_gset_family:Nnn \g_@@_mathrm_tl {#1} {#2} %<LU> \fontspec_gset_family:Nnn \g_@@_mathrm_tl {Renderer=Basic,#1} {#2} - \@@_setmathrm_hook:nn {#1} {#2} + \@@_setmathrm_hook:nn {#1} {#2} % for unicode-math only } % \end{macrocode} % \end{macro} @@ -129,7 +124,7 @@ { %<XE> \fontspec_gset_family:Nnn \g_@@_bfmathrm_tl {#1} {#2} %<LU> \fontspec_gset_family:Nnn \g_@@_bfmathrm_tl {Renderer=Basic,#1} {#2} - \@@_setboldmathrm_hook:nn {#1} {#2} + \@@_setboldmathrm_hook:nn {#1} {#2} % for unicode-math only } % \end{macrocode} % \end{macro} @@ -140,7 +135,7 @@ { %<XE> \fontspec_gset_family:Nnn \g_@@_mathsf_tl {#1} {#2} %<LU> \fontspec_gset_family:Nnn \g_@@_mathsf_tl {Renderer=Basic,#1} {#2} - \@@_setmathsf_hook:nn {#1} {#2} + \@@_setmathsf_hook:nn {#1} {#2} % for unicode-math only } % \end{macrocode} % \end{macro} @@ -151,7 +146,7 @@ { %<XE> \fontspec_gset_family:Nnn \g_@@_mathtt_tl {#1} {#2} %<LU> \fontspec_gset_family:Nnn \g_@@_mathtt_tl {Renderer=Basic,#1} {#2} - \@@_setmathtt_hook:nn {#1} {#2} + \@@_setmathtt_hook:nn {#1} {#2} % for unicode-math only } % \end{macrocode} % \end{macro} @@ -528,7 +523,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-vars.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-vars.dtx index ae5132b95cb..75f316f23b0 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-vars.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-vars.dtx @@ -303,6 +303,9 @@ \tl_new:N \l_@@_rmfamily_family_tl \tl_new:N \l_@@_sffamily_family_tl \tl_new:N \l_@@_ttfamily_family_tl +\tl_new:N \l_@@_rmfamily_encoding_tl +\tl_new:N \l_@@_sffamily_encoding_tl +\tl_new:N \l_@@_ttfamily_encoding_tl % \end{macrocode} % % @@ -320,7 +323,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code-xfss.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-code-xfss.dtx index 4f1bdd2d564..fef300a078b 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code-xfss.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code-xfss.dtx @@ -9,54 +9,28 @@ % % \subsection{Italic small caps and so on} \label{sec:sishape} % -% \begin{macro}{\sishape} -% \begin{macro}{\textsi} -% These commands for actually selecting italic small caps have been defined for many years; I'm inclined to drop them. -% They're probably used very infrequently; I personally prefer just writing -% |\textit{\textsc{...}}| instead. -% % \begin{macrocode} -\providecommand*\itscdefault{\itdefault\scdefault} -\providecommand*\slscdefault{\sldefault\scdefault} -\DeclareRobustCommand{\sishape} - { - \not@math@alphabet\sishape\relax - \fontshape{\itscdefault}\selectfont - } -\DeclareTextFontCommand{\textsi}{\sishape} +\providecommand*\scitdefault{\scdefault\itdefault} +\providecommand*\scsldefault{\scdefault\sldefault} % \end{macrocode} -% \end{macro} \end{macro} -% % \LaTeX's `shape' font axis needs to be overloaded to support italic small caps and slanted small caps. % These are the combinations to support: % \begin{macrocode} \cs_new:Nn \@@_shape_merge:nn { c_@@_shape_#1_#2_tl } \cs_new:Nn \@@_merge_default_shapes: { - \tl_const:cn { \@@_shape_merge:nn \itdefault \scdefault } {\itscdefault} - \tl_const:cn { \@@_shape_merge:nn \sldefault \scdefault } {\slscdefault} - \tl_const:cn { \@@_shape_merge:nn \scdefault \itdefault } {\itscdefault} - \tl_const:cn { \@@_shape_merge:nn \scdefault \sldefault } {\slscdefault} - \tl_const:cn { \@@_shape_merge:nn \slscdefault \itdefault } {\itscdefault} - \tl_const:cn { \@@_shape_merge:nn \itscdefault \sldefault } {\slscdefault} - \tl_const:cn { \@@_shape_merge:nn \itscdefault \updefault } {\scdefault} - \tl_const:cn { \@@_shape_merge:nn \slscdefault \updefault } {\scdefault} + \tl_const:cn { \@@_shape_merge:nn \itdefault \scdefault } {\scitdefault} + \tl_const:cn { \@@_shape_merge:nn \sldefault \scdefault } {\scsldefault} + \tl_const:cn { \@@_shape_merge:nn \scdefault \itdefault } {\scitdefault} + \tl_const:cn { \@@_shape_merge:nn \scdefault \sldefault } {\scsldefault} + \tl_const:cn { \@@_shape_merge:nn \scsldefault \itdefault } {\scitdefault} + \tl_const:cn { \@@_shape_merge:nn \scitdefault \sldefault } {\scsldefault} + \tl_const:cn { \@@_shape_merge:nn \scitdefault \shapedefault } {\scdefault} + \tl_const:cn { \@@_shape_merge:nn \scsldefault \shapedefault } {\scdefault} } \@@_merge_default_shapes: % \end{macrocode} % -% \begin{macro}{\@@_merge_shape:n} -% These macros enable the overload on the |\..shape| commands. -% First, a shape `new+current' (prefix) or `current+new' (suffix) is tried. -% If not found, fall back on the `new' shape. -% \begin{macrocode} -\cs_new:Nn \@@_merge_shape:n - { - \@@_if_merge_shape:nTF {#1} - { \fontshape { \tl_use:c { \@@_shape_merge:nn {\f@shape} {#1} } } \selectfont } - { \fontshape {#1} \selectfont } - } -% \end{macrocode} % The following is rather specific; it only returns true if the merged shape exists, % but more importantly also if the merged shape is defined for the current font. % \begin{macrocode} @@ -74,6 +48,45 @@ \prg_return_true: \prg_return_false: } % \end{macrocode} +% +% +% \begin{macrocode} +\cs_if_exist:NTF \DeclareFontSeriesChangeRule +{ + \cs_set_eq:NN \emfontdeclare \DeclareEmphSequence +} +{ +% \end{macrocode} +% +% \begin{macro}{\sishape} +% \begin{macro}{\textsi} +% These commands for actually selecting italic small caps have been defined for many years; I'm inclined to drop them. +% They're probably used very infrequently; I personally prefer just writing +% |\textit{\textsc{...}}| instead. +% +% \begin{macrocode} +\DeclareRobustCommand{\sishape} + { + \not@math@alphabet\sishape\relax + \fontshape{\scitdefault}\selectfont + } +\DeclareTextFontCommand{\textsi}{\sishape} +% \end{macrocode} +% \end{macro} \end{macro} +% +% +% \begin{macro}{\@@_merge_shape:n} +% These macros enable the overload on the |\..shape| commands. +% First, a shape `new+current' (prefix) or `current+new' (suffix) is tried. +% If not found, fall back on the `new' shape. +% \begin{macrocode} +\cs_new:Nn \@@_merge_shape:n + { + \@@_if_merge_shape:nTF {#1} + { \fontshape { \tl_use:c { \@@_shape_merge:nn {\f@shape} {#1} } } \selectfont } + { \fontshape {#1} \selectfont } + } +% \end{macrocode} % \end{macro} % % \begin{macro}{\itshape} \begin{macro}{\scshape} \begin{macro}{\upshape} \begin{macro}{\slshape} @@ -108,7 +121,7 @@ % % \begin{macro}{\emfontdeclare} % \begin{macrocode} -\cs_new_protected:Npn \emfontdeclare #1 +\cs_set_protected:Npn \emfontdeclare #1 { \prop_gclear:N \g_@@_em_prop \int_zero:N \l_@@_emdef_int @@ -183,13 +196,22 @@ % \end{macro} % \end{macro} % +% \begin{macrocode} +\emfontdeclare{ \emshape, \eminnershape } +\cs_new:Nn \fontspec_set_em_level:n { \int_set:Nn \l_@@_em_int {#1} } +% \end{macrocode} +% +% \begin{macrocode} +} +% \end{macrocode} +% % % % \subsection{Strong emphasis} % % \begin{macro}{\strongfontdeclare} % \begin{macrocode} -\cs_new_protected:Npn \strongfontdeclare #1 +\cs_set_protected:Npn \strongfontdeclare #1 { \prop_gclear:N \g_@@_strong_prop \int_zero:N \l_@@_strongdef_int @@ -257,14 +279,12 @@ % % Programmer's interface for setting nesting levels: % \begin{macrocode} -\cs_new:Nn \fontspec_set_em_level:n { \int_set:Nn \l_@@_em_int {#1} } \cs_new:Nn \fontspec_set_strong_level:n { \int_set:Nn \l_@@_strong_int {#1} } % \end{macrocode} % % Defaults: % \begin{macrocode} \strongfontdeclare{ \bfseries } -\emfontdeclare{ \emshape, \eminnershape } % \end{macrocode} % % \begin{macrocode} @@ -278,7 +298,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-code.ltx b/Master/texmf-dist/source/latex/fontspec/fontspec-code.ltx index c164175b5fa..1dcdea07cbb 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-code.ltx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-code.ltx @@ -30,7 +30,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-api.tex b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-api.tex index ed85ad9fa5c..e5f11e3503a 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-api.tex +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-api.tex @@ -7,7 +7,7 @@ \part{Customisation and programming interface} -This is the beginning of some work to provide some hooks that use +This chapter describes the current interfaces and hooks that use \pkg{fontspec} for various macro programming purposes. @@ -179,7 +179,7 @@ The raw \TeX\ font that is defined from the `base' font in the family is stored \DescribeMacro{\g_fontspec_encoding_tl} Package authors who need to load fonts with legacy \LaTeX\ \NFSS\ commands may also need to know what the default font encoding is. -Since this has changed from \texttt{EU1}/\texttt{EU2} to \texttt{TU}, it is best to use the variables \cs{g_fontspec_encoding_tl} or \cs{UTFencname} instead. +Since this has changed from \texttt{EU1}/\texttt{EU2} to \texttt{TU}, it is best to use the variable \cs{g_fontspec_encoding_tl} instead. \subsection{Functions for loading new fonts and families} @@ -331,7 +331,7 @@ OpenType language tag |#1|. % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-enc.tex b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-enc.tex index 42a30d41f51..2a706a6252c 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-enc.tex +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-enc.tex @@ -204,7 +204,7 @@ the process of defining Unicode font range encodings: % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-featset.tex b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-featset.tex index d6aa8af2f1b..dac017ae148 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-featset.tex +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-featset.tex @@ -544,7 +544,7 @@ to zero, no optical size font substitution is performed. Latin Modern optical sizes \end{Lexample} -The \feat{SizeFeatures} feature (\vref*{sec:sizefeature}) can be +The \feat{SizeFeatures} feature (\vref{sec:sizefeature}) can be used to specify exactly which optical sizes will be used for ranges of font size. For example, something like: \begin{Verbatim} @@ -602,7 +602,7 @@ The letter spacing parameter is a normalised additive factor (not a scaling fact This functionality is not generally used for lowercase text in modern typesetting but does have historic precedent in a variety of situations. In particular, small amounts of letter spacing can be very useful, when setting small caps or all caps titles. -Also see the OpenType \opt{Uppercase} option of the \feat{Letters} feature (\vref*{sec:letters}). +Also see the OpenType \opt{Uppercase} option of the \feat{Letters} feature (\vref{sec:letters}). \end{document} @@ -610,7 +610,7 @@ Also see the OpenType \opt{Uppercase} option of the \feat{Letters} feature (\vre % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-fontsel.tex b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-fontsel.tex index df3996c3084..884dd409b87 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-fontsel.tex +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-fontsel.tex @@ -53,7 +53,7 @@ The |set| command never checks; use at your own risk. } The plain \cs{fontspec} command is not generally recommended for document use. It is an -ad hoc commands best suited for testing and loading fonts on a one-off basis. +ad hoc command best suited for testing and loading fonts on a one-off basis. All of the commands listed above accept comma-separated \meta{font feature}=\meta{option} lists; these are described later: @@ -177,8 +177,8 @@ in the filesystem must be specified with the |Path| feature: ... ] \end{Verbatim} Note that \XeTeX\ and \LuaTeX\ are able to load the font without giving an -extension, but \pkg{fontspec} must know to search for the file; this can can -be indicated by using the |Path| feature without an argument: +extension, but \pkg{fontspec} must know to search for the file; this can be +indicated by using the |Path| feature without an argument: \begin{Verbatim} \setmainfont{texgyrepagella-regular}[ Path, BoldFont = texgyrepagella-bold, @@ -276,7 +276,7 @@ E.g.: \IfFontExistsTF{/Users/will/Library/Fonts/CODE2000.TTF}{T}{F} \end{Verbatim} -The \cs{IfFontExistsTF} command is a synonym for the programming interface function \cs{fontspec_font_if_exist:nTF} (\vref*{sec:api}). +The \cs{IfFontExistsTF} command is a synonym for the programming interface function \cs{fontspec_font_if_exist:nTF} (\vref{sec:api}). @@ -452,7 +452,7 @@ which is essentially the same as writing |\verbatimfont|, or to go back to the o \end{Verbatim} Only use this feature when necessary; the in-built font switching commands that \pkg{fontspec} generates (such as |\verbatimfont| in the example above) are recommended in all other cases. -If you don't wish to explicitly set the \NFSS\ family but you would like to know what it is, an alternative mechanism for package writers is introduced as part of the \pkg{fontspec} programming interface; see the function \cs{fontspec_set_family:Nnn} for details (\vref*{sec:api}). +If you don't wish to explicitly set the \NFSS\ family but you would like to know what it is, an alternative mechanism for package writers is introduced as part of the \pkg{fontspec} programming interface; see the function \cs{fontspec_set_family:Nnn} for details (\vref{sec:api}). \subsection{Choosing additional \NFSS\ font faces} @@ -475,16 +475,15 @@ Multiple \feat{FontFace} commands may be used in a single declaration to specify As an example: \begin{Verbatim} \setmainfont{font1.otf}[ - FontFace = {c}{\updefault}{ font2.otf } , + FontFace = {c}{\shapedefault}{ font2.otf } , FontFace = {c}{m}{ Font = font3.otf , Color = red } ] \end{Verbatim} Writing |\fontseries{c}\selectfont| will result in |font2| being selected, which then followed by |\fontshape{m}\selectfont| will result in |font3| being selected (in red). -A font face that is defined in terms of a different series but an upright shape (|\updefault|, as shown above) will attempt to find a matching small caps feature and define that face as well. +A font face that is defined in terms of a different series but an upright shape (|\shapedefault|, as shown above) will attempt to find a matching small caps feature and define that face as well. Conversely, a font face defined in terms of a non-standard font shape will not. -There are some standards for choosing shape and series codes; the \LaTeXe\ font selection guide\footnote{\texttt{texdoc fntguide}} lists series |m| for medium, |b| for bold, |bx| for bold extended, |sb| for semi-bold, and |c| for condensed. -A far more comprehensive listing is included in Appendix~A of Philipp Lehman's `The Font Installation Guide'\footnote{\texttt{texdoc fontinstallationguide}} covering 14 separate weights and 12 separate widths. +There are some standards for choosing shape and series codes; the \LaTeXe\ font selection guide\footnote{\texttt{texdoc fntguide}} has a comprehensive listing. The \feat{FontFace} command also interacts properly with the \feat{SizeFeatures} command as follows: (nonsense set of font selection choices) \begin{Verbatim} @@ -627,7 +626,7 @@ if it were a `naked' control sequence; \eg, `|M. \fontspec{...} N|' and % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-intro.tex b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-intro.tex index 28b8a003384..7f32adb0099 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-intro.tex +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-intro.tex @@ -78,16 +78,13 @@ Package options will be introduced below; some preliminary details are discussed \subsection{Font encodings} -The 2016 release of \pkg{fontspec} initiated some changes for font encodings and the loading of \pkg{xunicode}. -The 2017 release rolls out those changes as default. -The now-default \texttt{tuenc} package option switches the \textsc{nfss} font encoding to \texttt{TU}. +The (default) \texttt{tuenc} package option switches the \textsc{nfss} font encoding to \texttt{TU}. \texttt{TU} is a new Unicode font encoding, intended for both \XeTeX\ and \LuaTeX\ engines, and automatically contains support for symbols covered by \LaTeX's traditional \texttt{T1} and \texttt{TS1} font encodings (for example, |\%|, |\textbullet|, |\"u|, and so on). -As a result, with this package option, Ross Moore's \pkg{xunicode} package is \textbf{not} loaded. -Some new, experimental, features are now provided to customise some encoding details; see Part~\vref{part:enc} for further details. +Some additional features are provided by \pkg{fontspec} to customise some encoding details; see Part~\vref{part:enc} for further details. Pre-2017 behaviour can be achieved with the \texttt{euenc} package option. -This selects the \texttt{EU1} or \texttt{EU2} encoding (\XeTeX/\LuaTeX, resp.) and loads the \pkg{xunicode} package. +This selects the \texttt{EU1} or \texttt{EU2} encoding (\XeTeX/\LuaTeX, resp.) and loads the \pkg{xunicode} package for symbol support. Package authors and users who have referred explicitly to the encoding names \texttt{EU1} or \texttt{EU2} should update their code or documents. (See internal variable names described in \vref{sec:api} for how to do this properly.) @@ -132,22 +129,6 @@ This section documents some areas of adjustment that \pkg{fontspec} makes to improve default behaviour with \LaTeXe\ and third-party packages. -\subsection{Verbatim} -\label{sec:verb} - -Many verbatim mechanisms assume the existence of a `visible space' character that exists in the \textsc{ascii} space slot of the typewriter font. This character is known in Unicode as \unichar{2423}{box open}, which looks like this: `\verb*| |'. - -When a Unicode typewriter font is used, \LaTeX\ no longer prints visible spaces for the |verbatim*| environment and |\verb*| command. -This problem is fixed by using the correct Unicode glyph, and the following packages are patched to do the same: -\pkg{listings}, \pkg{fancyvrb}, \pkg{moreverb}, and \pkg{verbatim}. - -In the case that the typewriter font does not contain `\verb*| |', the Latin Modern Mono font is used as a fallback. - -In 2019, \LaTeX\ will use a new command \cs{verbvisiblespace} for internal commands and for -third party packages. If this new command is defined, \pkg{fontspec}'s patching code here -will be entirely disabled and the packages listed above should no longer rely on \pkg{fontspec} -to redefine their internals. - \subsection{Commands for old-style and lining numbers} @@ -162,44 +143,12 @@ the reverse for \cs{liningnums}\marg{text}. \subsection{Italic small caps} -\DescribeMacro{\itshape} -\DescribeMacro{\slshape} -\DescribeMacro{\scshape} -Note that this package redefines the \cs{itshape}, \cs{slshape}, and \cs{scshape} commands in order to allow them to select italic small caps in conjunction. -With these changes, writing |\itshape\scshape| will lead to italic small caps, and |\upshape| subsequently then moves back to small caps only. |\upshape| again returns from small caps to upright regular. -(And similarly for for |\slshape|. In addition, once italic small caps are selected then |\slshape| will switch to slanted small caps, and vice versa.) +Support now provided by \LaTeXe\ in 2020. \subsection{Emphasis and nested emphasis} -\DescribeMacro{\eminnershape} -\LaTeXe\ allows you to specify the behaviour of \cs{emph} nested within \cs{emph} by setting the \cs{eminnershape} command. -For example, -\begin{Verbatim} - \renewcommand\eminnershape{\upshape\scshape} -\end{Verbatim} -will produce small caps within |\emph{\emph{...}}|. - -\DescribeMacro{\emfontdeclare} -The \pkg{fontspec} package takes this idea one step further to allow arbitrary font shape changes and arbitrary levels of nesting within emphasis. -This is performed using the |\emfontdeclare| command, which takes a comma-separated list of font switches corresponding to increasing levels of emphasis. -An example: -\begin{enumerate} -\item |\emfontdeclare{\itshape,\upshape\scshape,\itshape}| will lead to `italics', `small caps', then `italic small caps' as the level of emphasis increases, as long as italic small caps are defined for the font. - Note that |\upshape| is required because the font changes are cascading. -\end{enumerate} -The implementation of this feature tries to be `smart' and guess what level of emphasis to use in the case of manual font changing. -This is reliable only if you use shape-changing commands in \cs{emfontdeclare}. -For example: -\begin{Verbatim} - \emfontdeclare{\itshape,\upshape\scshape,\itshape} - ... - \scshape small caps \emph{hello} -\end{Verbatim} -Here, the emphasised text `hello' will be printed in italic small caps since |\emph| can detect that the current font shape is already in the second `mode' of emphasis. - -\DescribeMacro{\emreset} -Finally, if you have so much nested emphasis that |\emfontdeclare| runs out of options, it will insert |\emreset| (by default just |\upshape|) and start again from the beginning. +Support now provided by \LaTeXe\ in 2020. \subsection{Strong emphasis} @@ -235,7 +184,7 @@ An example for setting up a font family for use with \cs{strong} is discussed in % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-luatex.tex b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-luatex.tex index e6f752d6e92..7365160b498 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-luatex.tex +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-luatex.tex @@ -81,7 +81,7 @@ Please refer to the \LuaTeX/\pkg{luaotfload} documentation for more details. % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-opentype.tex b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-opentype.tex index 3afdd09e435..a21d7f80cf3 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-opentype.tex +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-opentype.tex @@ -806,7 +806,7 @@ interface to around half of them. Full documentation will be presented in the following sections, including how to enable and disable individual features, and how they interact. -A brief reference is provided (\vref*{tab:all-ot}) but note that this is an incomplete +A brief reference is provided (\vref{tab:all-ot}) but note that this is an incomplete listing --- only the `enable' keys are shown, and where alternative interfaces are provided for convenience only the first is shown. (E.g., |Numbers=OldStyle| is the same as |Numbers=Lowercase|.) @@ -1466,7 +1466,7 @@ however; please get in touch if there are improvements that could be made. % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-xetex.tex b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-xetex.tex index 0dc5e48cace..5d28095dfde 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-doc-xetex.tex +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-doc-xetex.tex @@ -368,7 +368,7 @@ options: \opt{Off}, % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec-lua.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec-lua.dtx index 4f04001f1f7..fdbe11e9d18 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec-lua.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec-lua.dtx @@ -89,7 +89,7 @@ end % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec.dtx b/Master/texmf-dist/source/latex/fontspec/fontspec.dtx index 4705540d206..e1c377b6560 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec.dtx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec.dtx @@ -71,7 +71,7 @@ \ProvidesExplFile{fontspec.dtx} %</dtx> %<*fontspec> - {2019/10/19}{2.7d}{Font selection for XeLaTeX and LuaLaTeX} + {2020/01/09}{2.7e}{Font selection for XeLaTeX and LuaLaTeX} %</fontspec> % \end{macrocode} % @@ -90,8 +90,8 @@ %<lua>local fontspec = fontspec %<lua>fontspec.module = { %<lua> name = "fontspec", -%<lua> version = "2.7d", -%<lua> date = "2019/10/19", +%<lua> version = "2.7e", +%<lua> date = "2020/01/09", %<lua> description = "Font selection for XeLaTeX and LuaLaTeX", %<lua> author = "Khaled Hosny, Philipp Gesang, Will Robertson", %<lua> copyright = "Khaled Hosny, Philipp Gesang, Will Robertson", @@ -105,7 +105,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec.ins b/Master/texmf-dist/source/latex/fontspec/fontspec.ins index bd49db003ba..adace502d2f 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec.ins +++ b/Master/texmf-dist/source/latex/fontspec/fontspec.ins @@ -48,7 +48,7 @@ the conditions of the LaTeX Project Public License, version 1.3c or higher % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright diff --git a/Master/texmf-dist/source/latex/fontspec/fontspec.ltx b/Master/texmf-dist/source/latex/fontspec/fontspec.ltx index 7ee948df547..b4979486961 100644 --- a/Master/texmf-dist/source/latex/fontspec/fontspec.ltx +++ b/Master/texmf-dist/source/latex/fontspec/fontspec.ltx @@ -28,7 +28,7 @@ % ------------------------------------------------ % The FONTSPEC package <wspr.io/fontspec> % ------------------------------------------------ -% Copyright 2004-2019 Will Robertson, LPPL "maintainer" +% Copyright 2004-2020 Will Robertson, LPPL "maintainer" % Copyright 2009-2015 Khaled Hosny % Copyright 2013 Philipp Gesang % Copyright 2013-2016 Joseph Wright |