diff options
author | Karl Berry <karl@freefriends.org> | 2021-06-20 19:56:11 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2021-06-20 19:56:11 +0000 |
commit | 0e008fd431955e2802ab0abb5220e3bfb78256e6 (patch) | |
tree | 00a71b8590fe7dadb12de99f13729cb46a223dd2 /Master/texmf-dist/tex/latex/ctex/ctex.sty | |
parent | 0dfccc591702a7d52fd4739ddb2622d1769cf422 (diff) |
ctex (20jun21)
git-svn-id: svn://tug.org/texlive/trunk@59654 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/ctex/ctex.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/ctex/ctex.sty | 69 |
1 files changed, 12 insertions, 57 deletions
diff --git a/Master/texmf-dist/tex/latex/ctex/ctex.sty b/Master/texmf-dist/tex/latex/ctex/ctex.sty index 7d3dfb2277d..f15684d290d 100644 --- a/Master/texmf-dist/tex/latex/ctex/ctex.sty +++ b/Master/texmf-dist/tex/latex/ctex/ctex.sty @@ -26,24 +26,10 @@ %% \NeedsTeXFormat{LaTeX2e} \RequirePackage{expl3} -\GetIdInfo$Id: ctex.dtx 07425fe 2021-03-14 16:43:36 +0800 Xiangdong Zeng <xdzeng96@gmail.com> $ +\GetIdInfo$Id: ctex.dtx 6604451 2021-06-20 17:08:49 +0800 Qing Lee <sobenlee@gmail.com> $ {Chinese adapter in LaTeX (CTEX)} \ProvidesExplPackage{\ExplFileName} - {\ExplFileDate}{2.5.6}{\ExplFileDescription} -\tl_const:Nx \c__ctex_version_tl - { \cs_if_exist_use:cF { ver@ \@currname . \@currext } { 9999/99/99 } } -\msg_new:nnnn { ctex } { subpackage-loaded } - { Package~`#1'~can~not~be~loaded~with~`ctex'. } - { - `#1'~is~actually~a~part~of~`ctex'.\\ - It~is~not~necessary~to~load~it~separately. - } -\@ifpackageloaded { ctexsize } - { \msg_error:nnn { ctex } { subpackage-loaded } { ctexsize } } - { \cs_new_eq:cN { ver@ctexsize. \@pkgextension } \c__ctex_version_tl } -\@ifpackageloaded { ctexheading } - { \msg_error:nnn { ctex } { subpackage-loaded } { ctexheading } } - { \cs_new_eq:cN { ver@ctexheading. \@pkgextension } \c__ctex_version_tl } + {\ExplFileDate}{2.5.7}{\ExplFileDescription} \RequirePackage { xparse , l3keys2e } \msg_new:nnnn { ctex } { l3-too-old } { Support~package~`#1'~too~old. } @@ -67,7 +53,14 @@ { \msg_critical:nnx { ctex } { engine-not-supported } { \c__ctex_engine_str } } \RequirePackage { ctexhook , ctexpatch } \RequirePackage { fix-cm } -\RequirePackage { everysel } +\ctex_disable_package:n { ctexsize } +\ctex_disable_package:n { ctexheading } +\ctex_if_format_at_least:nTF { 2021/06/01 } + { \bool_const:Nn \c__ctex_everysel_loaded_bool { \c_false_bool } } + { + \RequirePackage { everysel } + \bool_const:Nn \c__ctex_everysel_loaded_bool { \c_true_bool } + } \tl_clear_new:N \l__ctex_tmp_tl \int_new:N \l__ctex_tmp_int \box_new:N \l__ctex_tmp_box @@ -80,44 +73,6 @@ { \keys_set:nn { ctex } } \cs_new_protected:Npn \ctex_set:nn #1 { \keys_set:nn { ctex / #1 } } -\cs_new_protected:Npn \ctex_file_input:n #1 - { - \ctex_push_file: - \file_input:n {#1} - \ctex_pop_file: - } -\cs_new_protected:Npn \ctex_push_file: - { - \seq_gpush:Nx \g__ctex_file_status_seq - { - { - \bool_if:NTF \l__kernel_expl_bool - { \ExplSyntaxOn } - { \ExplSyntaxOff } - } - { \char_value_catcode:n { 64 } } - { \char_value_catcode:n { 94 } } - { \int_use:N \tex_endlinechar:D } - } - \ExplSyntaxOff - \char_set_catcode_letter:n { 64 } - \char_set_catcode_math_superscript:n { 94 } - \int_set:Nn \tex_endlinechar:D { 13 } - } -\cs_new_protected:Npn \ctex_pop_file: - { - \seq_gpop:NN \g__ctex_file_status_seq \l__ctex_file_status_tl - \exp_after:wN \__ctex_pop_file_aux:nnnn \l__ctex_file_status_tl - } -\cs_new_protected:Npn \__ctex_pop_file_aux:nnnn #1#2#3#4 - { - #1 - \char_set_catcode:nn { 64 } {#2} - \char_set_catcode:nn { 94 } {#3} - \int_set:Nn \tex_endlinechar:D {#4} - } -\tl_new:N \l__ctex_file_status_tl -\seq_new:N \g__ctex_file_status_seq \cs_new_protected:Npn \ctex_scheme_input:n #1 { \ctex_push_file: @@ -740,8 +695,8 @@ { \cs_set_protected:Npn #3 { \@setfontsize #3 {#1} {#2} #4 } } \int_case:nn { \g__ctex_font_size_int } { - { 0 } { \ctex_file_input:n { ctex-c5size.clo } } - { 1 } { \ctex_file_input:n { ctex-cs4size.clo } } + { 0 } { \file_input:n { ctex-c5size.clo } } + { 1 } { \file_input:n { ctex-cs4size.clo } } } \fp_if_nan:nF { \l__ctex_line_spread_fp } { |