From 7739a3e6e0ed5a2798a9d43a732cd87d29b6c079 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Mon, 19 Oct 2020 21:12:08 +0000 Subject: xecjk (19oct20) git-svn-id: svn://tug.org/texlive/trunk@56711 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/doc/xelatex/xecjk/xeCJK.pdf | Bin 1291521 -> 1284546 bytes .../doc/xelatex/xecjk/xunicode-symbols.pdf | Bin 292888 -> 293063 bytes Master/texmf-dist/source/xelatex/xecjk/xeCJK.dtx | 82 +++++++++++++-------- .../tex/xelatex/xecjk/xeCJK-listings.sty | 4 +- Master/texmf-dist/tex/xelatex/xecjk/xeCJK.cfg | 4 +- Master/texmf-dist/tex/xelatex/xecjk/xeCJK.sty | 72 +++++++++++------- Master/texmf-dist/tex/xelatex/xecjk/xeCJKfntef.sty | 4 +- .../tex/xelatex/xecjk/xunicode-addon.sty | 4 +- .../tex/xelatex/xecjk/xunicode-extra.def | 4 +- 9 files changed, 105 insertions(+), 69 deletions(-) (limited to 'Master/texmf-dist') diff --git a/Master/texmf-dist/doc/xelatex/xecjk/xeCJK.pdf b/Master/texmf-dist/doc/xelatex/xecjk/xeCJK.pdf index 6c06e28ecf7..3fa0591aa8d 100644 Binary files a/Master/texmf-dist/doc/xelatex/xecjk/xeCJK.pdf and b/Master/texmf-dist/doc/xelatex/xecjk/xeCJK.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/xecjk/xunicode-symbols.pdf b/Master/texmf-dist/doc/xelatex/xecjk/xunicode-symbols.pdf index e1b98105682..937e245b874 100644 Binary files a/Master/texmf-dist/doc/xelatex/xecjk/xunicode-symbols.pdf and b/Master/texmf-dist/doc/xelatex/xecjk/xunicode-symbols.pdf differ diff --git a/Master/texmf-dist/source/xelatex/xecjk/xeCJK.dtx b/Master/texmf-dist/source/xelatex/xecjk/xeCJK.dtx index 0651316e47c..1e1398c4061 100644 --- a/Master/texmf-dist/source/xelatex/xecjk/xeCJK.dtx +++ b/Master/texmf-dist/source/xelatex/xecjk/xeCJK.dtx @@ -194,7 +194,7 @@ Copyright and Licence %<*package|config|fntef|listings|xunicode|xunextra> %\NeedsTeXFormat{LaTeX2e} %\RequirePackage{expl3} -%<+!driver>\GetIdInfo$Id: xeCJK.dtx 6405ee1 2020-08-23 21:58:40 +0800 Qing Lee $ +%<+!driver>\GetIdInfo$Id: xeCJK.dtx f475abb 2020-10-19 20:24:03 +0800 Qing Lee $ % {Typesetting CJK scripts with XeLaTeX} % {Configuration file for xeCJK package} % {xeCJK font effect} @@ -207,7 +207,7 @@ Copyright and Licence %\ProvidesExplPackage{xeCJK-listings} %\ProvidesExplPackage{xunicode-addon} %\ProvidesExplFile{xunicode-extra.def} -% {\ExplFileDate}{3.8.5}{\ExplFileDescription} +% {\ExplFileDate}{3.8.6}{\ExplFileDescription} % %<*driver> \documentclass{ctxdoc} @@ -287,7 +287,7 @@ Copyright and Licence % \changes{v3.8.0}{2020/02/09}{清理过时的兼容性补丁代码。} % \changes{v3.8.3}{2020/04/07}{删除 \texttt{\_nopar}。} % -% \CheckSum{10905} +% \CheckSum{10926} % \GetFileId{xeCJK.sty} % % \title{\bfseries\pkg{xeCJK} 宏包} @@ -380,8 +380,8 @@ Copyright and Licence % \end{ctexexam} % \end{function} % -% 有些选项或命令后面带有 \exptarget\expstar 号,这表示这 -% 个选项或命令只能在导言区中使用,而 \rexptarget\rexpstar +% 有些选项或命令后面带有 \exptarget\expstar{} 号,这表示这 +% 个选项或命令只能在导言区中使用,而 \rexptarget\rexpstar{} % 号则表示这个选项或命令只能在导言区使用,并且只影响随后定义的 CJK 字体。其余不带特殊标记的 % 选项或命令,如果没有特别说明,可以在导言区或正文中使用。% % 使用粗体来表示 \pkg{xeCJK} 的默认设置。 @@ -4296,6 +4296,7 @@ Copyright and Licence % \changes{v3.6.0}{2018/01/23}{解决标点中间被隔开的禁则与压缩问题。} % \changes{v3.7.3}{2019/04/15}{修复 penalty 数值错误。} % \changes{v3.8.3}{2020/04/27}{修复 \opt{xCJKecglue} 选项。} +% \changes{v3.8.6}{2020/10/18}{正确还原标点符号后的 penalty 状态。} % % \begin{macro}{\xeCJK_if_last_punct:TF} % \changes{v3.6.1}{2018/02/25}{细化判断。} @@ -4362,7 +4363,13 @@ Copyright and Licence \int_compare:nNnTF \tex_lastnodetype:D = { 11 } { \@@_if_last_punct_glue:TF { \use_i:nn } } { \use:n } - { \tex_penalty:D \l_@@_last_penalty_int \use_ii:nn } + { \@@_last_punct_penalty_false:nn } + } +\cs_new_protected:Npn \@@_last_punct_penalty_false:nn #1#2 + { + \bool_set_false:N \l_@@_last_penalty_bool + \tex_penalty:D \l_@@_last_penalty_int + #2 } \cs_new_protected:Npn \@@_if_last_punct_auxi:TF { @@ -8469,6 +8476,8 @@ Copyright and Licence % \changes{v3.1.1}{2012/12/13}{对于与 \pkg{xltxtra} 的冲突给出错误警告。} % \changes{v3.8.0}{2020/02/09}{删除 \pkg{realscripts} 补丁。} % +% \changes{v3.8.6}{2020/10/17}{兼容 \LaTeX\ 2020/10/01 的 \pkg{NFSS} 钩子机制。} +% % \begin{macro}[int]{\fontfamily} % \begin{macro}[int]{\xeCJK@fontfamily,\xeCJK@family} % \changes{v3.1.1}{2012/12/06}{修改主要 \texttt{CJK} 字体族的自动更新方式。} @@ -8477,40 +8486,51 @@ Copyright and Licence % {将族名参数完全展开,以解决与 \pkg{fontspec} 2017/01/24 v2.5d 的兼容问题。} % 对于 \LaTeXe\ 2020/02/02 之前的版本,修改 \tn{fontfamily}, % 使主要 |CJK| 字体族能随西文主要字体更新,之后的版本可以使用 \tn{@rmfamilyhook} 等新钩子处理。 +% \LaTeXe\ 2020/10/01 提供了新的的 \pkg{NFSS} 钩子。 % \begin{macrocode} -\cs_if_exist:NTF \@rmfamilyhook +\@ifl@t@r \fmtversion { 2020/10/01 } { \cs_set_eq:NN \xeCJK@family \xeCJK_switch_family:x - \g@addto@macro \@rmfamilyhook { \xeCJK@family { \CJKrmdefault } } - \g@addto@macro \@sffamilyhook { \xeCJK@family { \CJKsfdefault } } - \g@addto@macro \@ttfamilyhook { \xeCJK@family { \CJKttdefault } } - \exp_args:Nc \g@addto@macro - { - \cs_if_exist:NTF \@defaultfamilyhook - { @defaultfamilyhook } { normalfont ~ } - } - { \xeCJK@family { \CJKfamilydefault } } + \AddToHook { rmfamily } { \xeCJK@family { \CJKrmdefault } } + \AddToHook { sffamily } { \xeCJK@family { \CJKsfdefault } } + \AddToHook { ttfamily } { \xeCJK@family { \CJKttdefault } } + \AddToHook { normalfont } { \xeCJK@family { \CJKfamilydefault } } } { - \RenewDocumentCommand \fontfamily { m } - { - \tl_set:Nx \f@family {#1} - \xeCJK@fontfamily {#1} - } - \cs_new_protected:Npn \xeCJK@fontfamily #1 + \cs_if_exist:NTF \@rmfamilyhook { - \str_if_eq:nnTF {#1} { \familydefault } - { \xeCJK_switch_family:x { \CJKfamilydefault } } - { \@@_update_family_aux: } + \cs_set_eq:NN \xeCJK@family \xeCJK_switch_family:x + \g@addto@macro \@rmfamilyhook { \xeCJK@family { \CJKrmdefault } } + \g@addto@macro \@sffamilyhook { \xeCJK@family { \CJKsfdefault } } + \g@addto@macro \@ttfamilyhook { \xeCJK@family { \CJKttdefault } } + \exp_args:Nc \g@addto@macro + { + \cs_if_exist:NTF \@defaultfamilyhook + { @defaultfamilyhook } { normalfont ~ } + } + { \xeCJK@family { \CJKfamilydefault } } } - \cs_new_protected:Npn \@@_update_family_aux: { - \str_case_e:nn { \f@family } + \RenewDocumentCommand \fontfamily { m } { - { \rmdefault } { \xeCJK_switch_family:x { \CJKrmdefault } } - { \sfdefault } { \xeCJK_switch_family:x { \CJKsfdefault } } - { \ttdefault } { \xeCJK_switch_family:x { \CJKttdefault } } - { \familydefault } { \xeCJK_switch_family:x { \CJKfamilydefault } } + \tl_set:Nx \f@family {#1} + \xeCJK@fontfamily {#1} + } + \cs_new_protected:Npn \xeCJK@fontfamily #1 + { + \str_if_eq:nnTF {#1} { \familydefault } + { \xeCJK_switch_family:x { \CJKfamilydefault } } + { \@@_update_family_aux: } + } + \cs_new_protected:Npn \@@_update_family_aux: + { + \str_case_e:nn { \f@family } + { + { \rmdefault } { \xeCJK_switch_family:x { \CJKrmdefault } } + { \sfdefault } { \xeCJK_switch_family:x { \CJKsfdefault } } + { \ttdefault } { \xeCJK_switch_family:x { \CJKttdefault } } + { \familydefault } { \xeCJK_switch_family:x { \CJKfamilydefault } } + } } } } diff --git a/Master/texmf-dist/tex/xelatex/xecjk/xeCJK-listings.sty b/Master/texmf-dist/tex/xelatex/xecjk/xeCJK-listings.sty index 9742f0f48a3..c31fd581761 100644 --- a/Master/texmf-dist/tex/xelatex/xecjk/xeCJK-listings.sty +++ b/Master/texmf-dist/tex/xelatex/xecjk/xeCJK-listings.sty @@ -29,10 +29,10 @@ %% \NeedsTeXFormat{LaTeX2e} \RequirePackage{expl3} -\GetIdInfo$Id: xeCJK.dtx 6405ee1 2020-08-23 21:58:40 +0800 Qing Lee $ +\GetIdInfo$Id: xeCJK.dtx f475abb 2020-10-19 20:24:03 +0800 Qing Lee $ {xeCJK patch file for listings} \ProvidesExplPackage{xeCJK-listings} - {\ExplFileDate}{3.8.5}{\ExplFileDescription} + {\ExplFileDate}{3.8.6}{\ExplFileDescription} \DeclareOption* { \PassOptionsToPackage { \CurrentOption } { xeCJK } } \ProcessOptions \scan_stop: \RequirePackage { xeCJK } diff --git a/Master/texmf-dist/tex/xelatex/xecjk/xeCJK.cfg b/Master/texmf-dist/tex/xelatex/xecjk/xeCJK.cfg index f9ecbd90008..d26c3b5dce9 100644 --- a/Master/texmf-dist/tex/xelatex/xecjk/xeCJK.cfg +++ b/Master/texmf-dist/tex/xelatex/xecjk/xeCJK.cfg @@ -6,10 +6,10 @@ %% %% xeCJK.dtx (with options: `config') %% -\GetIdInfo$Id: xeCJK.dtx 6405ee1 2020-08-23 21:58:40 +0800 Qing Lee $ +\GetIdInfo$Id: xeCJK.dtx f475abb 2020-10-19 20:24:03 +0800 Qing Lee $ {Configuration file for xeCJK package} \ProvidesExplFile{\ExplFileName.cfg} - {\ExplFileDate}{3.8.5}{\ExplFileDescription} + {\ExplFileDate}{3.8.6}{\ExplFileDescription} %% %% diff --git a/Master/texmf-dist/tex/xelatex/xecjk/xeCJK.sty b/Master/texmf-dist/tex/xelatex/xecjk/xeCJK.sty index 6bb521e33d4..25623ab698d 100644 --- a/Master/texmf-dist/tex/xelatex/xecjk/xeCJK.sty +++ b/Master/texmf-dist/tex/xelatex/xecjk/xeCJK.sty @@ -29,10 +29,10 @@ %% \NeedsTeXFormat{LaTeX2e} \RequirePackage{expl3} -\GetIdInfo$Id: xeCJK.dtx 6405ee1 2020-08-23 21:58:40 +0800 Qing Lee $ +\GetIdInfo$Id: xeCJK.dtx f475abb 2020-10-19 20:24:03 +0800 Qing Lee $ {Typesetting CJK scripts with XeLaTeX} \ProvidesExplPackage{\ExplFileName} - {\ExplFileDate}{3.8.5}{\ExplFileDescription} + {\ExplFileDate}{3.8.6}{\ExplFileDescription} \msg_new:nnn { xeCJK } { Require-XeTeX } { The~xeCJK~package~requires~XeTeX~to~function.\\\\ @@ -1614,7 +1614,13 @@ \int_compare:nNnTF \tex_lastnodetype:D = { 11 } { \__xeCJK_if_last_punct_glue:TF { \use_i:nn } } { \use:n } - { \tex_penalty:D \l__xeCJK_last_penalty_int \use_ii:nn } + { \__xeCJK_last_punct_penalty_false:nn } + } +\cs_new_protected:Npn \__xeCJK_last_punct_penalty_false:nn #1#2 + { + \bool_set_false:N \l__xeCJK_last_penalty_bool + \tex_penalty:D \l__xeCJK_last_penalty_int + #2 } \cs_new_protected:Npn \__xeCJK_if_last_punct_auxi:TF { @@ -4626,39 +4632,49 @@ \__xeCJK_math_robust:N \endmath } \__xeCJK_math_robust:N \ensuremath -\cs_if_exist:NTF \@rmfamilyhook +\@ifl@t@r \fmtversion { 2020/10/01 } { \cs_set_eq:NN \xeCJK@family \xeCJK_switch_family:x - \g@addto@macro \@rmfamilyhook { \xeCJK@family { \CJKrmdefault } } - \g@addto@macro \@sffamilyhook { \xeCJK@family { \CJKsfdefault } } - \g@addto@macro \@ttfamilyhook { \xeCJK@family { \CJKttdefault } } - \exp_args:Nc \g@addto@macro - { - \cs_if_exist:NTF \@defaultfamilyhook - { @defaultfamilyhook } { normalfont ~ } - } - { \xeCJK@family { \CJKfamilydefault } } + \AddToHook { rmfamily } { \xeCJK@family { \CJKrmdefault } } + \AddToHook { sffamily } { \xeCJK@family { \CJKsfdefault } } + \AddToHook { ttfamily } { \xeCJK@family { \CJKttdefault } } + \AddToHook { normalfont } { \xeCJK@family { \CJKfamilydefault } } } { - \RenewDocumentCommand \fontfamily { m } - { - \tl_set:Nx \f@family {#1} - \xeCJK@fontfamily {#1} - } - \cs_new_protected:Npn \xeCJK@fontfamily #1 + \cs_if_exist:NTF \@rmfamilyhook { - \str_if_eq:nnTF {#1} { \familydefault } - { \xeCJK_switch_family:x { \CJKfamilydefault } } - { \__xeCJK_update_family_aux: } + \cs_set_eq:NN \xeCJK@family \xeCJK_switch_family:x + \g@addto@macro \@rmfamilyhook { \xeCJK@family { \CJKrmdefault } } + \g@addto@macro \@sffamilyhook { \xeCJK@family { \CJKsfdefault } } + \g@addto@macro \@ttfamilyhook { \xeCJK@family { \CJKttdefault } } + \exp_args:Nc \g@addto@macro + { + \cs_if_exist:NTF \@defaultfamilyhook + { @defaultfamilyhook } { normalfont ~ } + } + { \xeCJK@family { \CJKfamilydefault } } } - \cs_new_protected:Npn \__xeCJK_update_family_aux: { - \str_case_e:nn { \f@family } + \RenewDocumentCommand \fontfamily { m } + { + \tl_set:Nx \f@family {#1} + \xeCJK@fontfamily {#1} + } + \cs_new_protected:Npn \xeCJK@fontfamily #1 + { + \str_if_eq:nnTF {#1} { \familydefault } + { \xeCJK_switch_family:x { \CJKfamilydefault } } + { \__xeCJK_update_family_aux: } + } + \cs_new_protected:Npn \__xeCJK_update_family_aux: { - { \rmdefault } { \xeCJK_switch_family:x { \CJKrmdefault } } - { \sfdefault } { \xeCJK_switch_family:x { \CJKsfdefault } } - { \ttdefault } { \xeCJK_switch_family:x { \CJKttdefault } } - { \familydefault } { \xeCJK_switch_family:x { \CJKfamilydefault } } + \str_case_e:nn { \f@family } + { + { \rmdefault } { \xeCJK_switch_family:x { \CJKrmdefault } } + { \sfdefault } { \xeCJK_switch_family:x { \CJKsfdefault } } + { \ttdefault } { \xeCJK_switch_family:x { \CJKttdefault } } + { \familydefault } { \xeCJK_switch_family:x { \CJKfamilydefault } } + } } } } diff --git a/Master/texmf-dist/tex/xelatex/xecjk/xeCJKfntef.sty b/Master/texmf-dist/tex/xelatex/xecjk/xeCJKfntef.sty index 2ba36ebc832..57e3071bc89 100644 --- a/Master/texmf-dist/tex/xelatex/xecjk/xeCJKfntef.sty +++ b/Master/texmf-dist/tex/xelatex/xecjk/xeCJKfntef.sty @@ -29,10 +29,10 @@ %% \NeedsTeXFormat{LaTeX2e} \RequirePackage{expl3} -\GetIdInfo$Id: xeCJK.dtx 6405ee1 2020-08-23 21:58:40 +0800 Qing Lee $ +\GetIdInfo$Id: xeCJK.dtx f475abb 2020-10-19 20:24:03 +0800 Qing Lee $ {xeCJK font effect} \ProvidesExplPackage{xeCJKfntef} - {\ExplFileDate}{3.8.5}{\ExplFileDescription} + {\ExplFileDate}{3.8.6}{\ExplFileDescription} \PassOptionsToPackage { normalem } { ulem } \DeclareOption* { \PassOptionsToPackage { \CurrentOption } { ulem } } \ProcessOptions \scan_stop: diff --git a/Master/texmf-dist/tex/xelatex/xecjk/xunicode-addon.sty b/Master/texmf-dist/tex/xelatex/xecjk/xunicode-addon.sty index f882bf810e7..e693fd232ce 100644 --- a/Master/texmf-dist/tex/xelatex/xecjk/xunicode-addon.sty +++ b/Master/texmf-dist/tex/xelatex/xecjk/xunicode-addon.sty @@ -29,10 +29,10 @@ %% \NeedsTeXFormat{LaTeX2e} \RequirePackage{expl3} -\GetIdInfo$Id: xeCJK.dtx 6405ee1 2020-08-23 21:58:40 +0800 Qing Lee $ +\GetIdInfo$Id: xeCJK.dtx f475abb 2020-10-19 20:24:03 +0800 Qing Lee $ {addon file for xunicode} \ProvidesExplPackage{xunicode-addon} - {\ExplFileDate}{3.8.5}{\ExplFileDescription} + {\ExplFileDate}{3.8.6}{\ExplFileDescription} \bool_lazy_or:nnF { \sys_if_engine_xetex_p: } { \sys_if_engine_luatex_p: } diff --git a/Master/texmf-dist/tex/xelatex/xecjk/xunicode-extra.def b/Master/texmf-dist/tex/xelatex/xecjk/xunicode-extra.def index efddf0397ee..17a4c4dbc8f 100644 --- a/Master/texmf-dist/tex/xelatex/xecjk/xunicode-extra.def +++ b/Master/texmf-dist/tex/xelatex/xecjk/xunicode-extra.def @@ -27,10 +27,10 @@ %% %% ---------------------------------------------------------------------- %% -\GetIdInfo$Id: xeCJK.dtx 6405ee1 2020-08-23 21:58:40 +0800 Qing Lee $ +\GetIdInfo$Id: xeCJK.dtx f475abb 2020-10-19 20:24:03 +0800 Qing Lee $ {extra definition for xunicode} \ProvidesExplFile{xunicode-extra.def} - {\ExplFileDate}{3.8.5}{\ExplFileDescription} + {\ExplFileDate}{3.8.6}{\ExplFileDescription} \DeclareUTFSymbol\texthyphenationpoint{"2027} \DeclareUTFSymbol\texttwoemdash{"2E3A} \DeclareUTFComposite\textsuperscript -- cgit v1.2.3