summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/ctex/engine
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-11-22 22:49:28 +0000
committerKarl Berry <karl@freefriends.org>2016-11-22 22:49:28 +0000
commit5bf4853ebb35ad3d6545264980e6d6d600951622 (patch)
treeb53e2e8ff66b55ef455245595e419ee75838adc5 /Master/texmf-dist/tex/latex/ctex/engine
parenta6bdb7927cba3bf14fc67d5d52c4c5b2513fe771 (diff)
ctex (22nov16)
git-svn-id: svn://tug.org/texlive/trunk@42554 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/ctex/engine')
-rw-r--r--Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-aptex.def4
-rw-r--r--Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-luatex.def70
-rw-r--r--Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-pdftex.def4
-rw-r--r--Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-uptex.def4
-rw-r--r--Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-xetex.def4
5 files changed, 56 insertions, 30 deletions
diff --git a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-aptex.def b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-aptex.def
index dfe7d69f8d2..a7605fb0a7a 100644
--- a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-aptex.def
+++ b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-aptex.def
@@ -26,10 +26,10 @@
%%
%% ------------------------------------------------------------------------------
%%
-\GetIdInfo$Id: ctex.dtx 575f038 2016-10-25 17:56:58 +0800 Qing Lee <sobenlee@gmail.com> $
+\GetIdInfo$Id: ctex.dtx 88a59e5 2016-11-22 17:09:10 +0800 Qing Lee <sobenlee@gmail.com> $
{Asian pTeX adapter (CTEX)}
\ProvidesExplFile{ctex-engine-aptex.def}
- {\ExplFileDate}{2.4.5}{\ExplFileDescription}
+ {\ExplFileDate}{2.4.6}{\ExplFileDescription}
\cs_new_protected_nopar:Npn \ctex_set_zhmap:n #1
{
\AtBeginDvi {#1}
diff --git a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-luatex.def b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-luatex.def
index 1d82e05b622..b6b009ba8fe 100644
--- a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-luatex.def
+++ b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-luatex.def
@@ -26,10 +26,10 @@
%%
%% ------------------------------------------------------------------------------
%%
-\GetIdInfo$Id: ctex.dtx 575f038 2016-10-25 17:56:58 +0800 Qing Lee <sobenlee@gmail.com> $
+\GetIdInfo$Id: ctex.dtx 88a59e5 2016-11-22 17:09:10 +0800 Qing Lee <sobenlee@gmail.com> $
{LuaLaTeX adapter (CTEX)}
\ProvidesExplFile{ctex-engine-luatex.def}
- {\ExplFileDate}{2.4.5}{\ExplFileDescription}
+ {\ExplFileDate}{2.4.6}{\ExplFileDescription}
\msg_new:nnn { ctex } { luatexja-loaded }
{
Package~`luatexja'~can~not~be~loaded~before~`ctex'.\\
@@ -353,8 +353,6 @@
}
\group_end:
}
-\cs_new_protected:Npn \ctex_ltj_set_family:xxx #1#2#3
- { \use:x { \ctex_ltj_set_family:nnn {#1} {#2} {#3} } }
\tl_new:N \l__ctex_ltj_base_CJKfamily_tl
\clist_new:N \l__ctex_ltj_font_options_clist
\cs_new_protected_nopar:Npn \__ctex_ltj_use_global_options:N #1
@@ -538,20 +536,41 @@
\token_to_str:N \addCJKfontfeature (s)~ignored.\\
It~cannot~be~used~with~a~font~that~wasn't~selected~by~ctex.
}
-\NewDocumentCommand \setCJKfamilyfont { m O { } m }
- { \ctex_ltj_set_family:xxx {#1} {#2} {#3} }
-\NewDocumentCommand \newCJKfontfamily { o m O { } m }
+\cs_new_protected:Npn \__ctex_ltj_pass_args:nnnn #1#2#3#4
+ {
+ \IfNoValueTF {#2}
+ { \__ctex_ltj_post_arg:w {#1} {#3} {#4} }
+ {
+ \use:x { #1 {#2} {#3} }
+ #4
+ }
+ }
+\NewDocumentCommand \__ctex_ltj_post_arg:w { m m m O { } }
+ {
+ \use:x { #1 {#4} {#2} }
+ #3
+ }
+\NewDocumentCommand \setCJKfamilyfont { m o m }
+ {
+ \__ctex_ltj_pass_args:nnnn
+ { \ctex_ltj_set_family:nnn {#1} } {#2} {#3}
+ { }
+ }
+\NewDocumentCommand \newCJKfontfamily { o m o m }
{
\tl_set:Nx \l__ctex_ltj_tmp_tl
{ \IfNoValueTF {#1} { \cs_to_str:N #2 } {#1} }
\cs_new_protected_nopar:Npx #2
{ \ctex_ltj_switch_family:n { \l__ctex_ltj_tmp_tl } }
- \ctex_ltj_set_family:xxx { \l__ctex_ltj_tmp_tl } {#3} {#4}
+ \__ctex_ltj_pass_args:nnnn
+ { \ctex_ltj_set_family:nnn { \l__ctex_ltj_tmp_tl } } {#3} {#4}
+ { }
}
-\NewDocumentCommand \CJKfontspec { O { } m }
+\NewDocumentCommand \CJKfontspec { o m }
{
- \ctex_ltj_fontspec:xx {#1} {#2}
- \tex_ignorespaces:D
+ \__ctex_ltj_pass_args:nnnn
+ { \ctex_ltj_fontspec:nn } {#1} {#2}
+ { \tex_ignorespaces:D }
}
\NewDocumentCommand \addCJKfontfeatures { m }
{
@@ -559,24 +578,31 @@
\tex_ignorespaces:D
}
\cs_new_eq:NN \addCJKfontfeature \addCJKfontfeatures
-\NewDocumentCommand \setCJKmainfont { O { } m }
+\NewDocumentCommand \setCJKmainfont { o m }
{
- \ctex_ltj_set_family:xxx { \CJKrmdefault } {#1} {#2}
- \normalfont
+ \__ctex_ltj_pass_args:nnnn
+ { \ctex_ltj_set_family:nnn { \CJKrmdefault } } {#1} {#2}
+ { \normalfont }
}
\cs_new_eq:NN \setCJKromanfont \setCJKmainfont
-\NewDocumentCommand \setCJKsansfont { O { } m }
+\NewDocumentCommand \setCJKsansfont { o m }
{
- \ctex_ltj_set_family:xxx { \CJKsfdefault } {#1} {#2}
- \normalfont
+ \__ctex_ltj_pass_args:nnnn
+ { \ctex_ltj_set_family:nnn { \CJKsfdefault } } {#1} {#2}
+ { \normalfont }
}
-\NewDocumentCommand \setCJKmonofont { O { } m }
+\NewDocumentCommand \setCJKmonofont { o m }
{
- \ctex_ltj_set_family:xxx { \CJKttdefault } {#1} {#2}
- \normalfont
+ \__ctex_ltj_pass_args:nnnn
+ { \ctex_ltj_set_family:nnn { \CJKttdefault } } {#1} {#2}
+ { \normalfont }
+ }
+\NewDocumentCommand \setCJKmathfont { o m }
+ {
+ \__ctex_ltj_pass_args:nnnn
+ { \ctex_ltj_set_family:nnn { \c__ctex_ltj_math_tl } } {#1} {#2}
+ { }
}
-\NewDocumentCommand \setCJKmathfont { O { } m }
- { \ctex_ltj_set_family:xxx { \c__ctex_ltj_math_tl } {#1} {#2} }
\NewDocumentCommand \defaultCJKfontfeatures { m }
{ \clist_gset:Nn \g__ctex_ltj_default_features_clist {#1} }
\clist_new:N \g__ctex_ltj_default_features_clist
diff --git a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-pdftex.def b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-pdftex.def
index f74d995772a..a5485a5c7d0 100644
--- a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-pdftex.def
+++ b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-pdftex.def
@@ -26,10 +26,10 @@
%%
%% ------------------------------------------------------------------------------
%%
-\GetIdInfo$Id: ctex.dtx 575f038 2016-10-25 17:56:58 +0800 Qing Lee <sobenlee@gmail.com> $
+\GetIdInfo$Id: ctex.dtx 88a59e5 2016-11-22 17:09:10 +0800 Qing Lee <sobenlee@gmail.com> $
{(pdf)LaTeX adapter (CTEX)}
\ProvidesExplFile{ctex-engine-pdftex.def}
- {\ExplFileDate}{2.4.5}{\ExplFileDescription}
+ {\ExplFileDate}{2.4.6}{\ExplFileDescription}
\cs_new_protected_nopar:Npn \ctex_set_zhmap:n #1
{
\AtBeginDvi {#1}
diff --git a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-uptex.def b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-uptex.def
index b815d511b1a..8d876bc7850 100644
--- a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-uptex.def
+++ b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-uptex.def
@@ -26,10 +26,10 @@
%%
%% ------------------------------------------------------------------------------
%%
-\GetIdInfo$Id: ctex.dtx 575f038 2016-10-25 17:56:58 +0800 Qing Lee <sobenlee@gmail.com> $
+\GetIdInfo$Id: ctex.dtx 88a59e5 2016-11-22 17:09:10 +0800 Qing Lee <sobenlee@gmail.com> $
{upTeX adapter (CTEX)}
\ProvidesExplFile{ctex-engine-uptex.def}
- {\ExplFileDate}{2.4.5}{\ExplFileDescription}
+ {\ExplFileDate}{2.4.6}{\ExplFileDescription}
\cs_new_protected_nopar:Npn \ctex_set_zhmap:n #1
{
\AtBeginDvi {#1}
diff --git a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-xetex.def b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-xetex.def
index 4557cb358ea..72253922102 100644
--- a/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-xetex.def
+++ b/Master/texmf-dist/tex/latex/ctex/engine/ctex-engine-xetex.def
@@ -26,10 +26,10 @@
%%
%% ------------------------------------------------------------------------------
%%
-\GetIdInfo$Id: ctex.dtx 575f038 2016-10-25 17:56:58 +0800 Qing Lee <sobenlee@gmail.com> $
+\GetIdInfo$Id: ctex.dtx 88a59e5 2016-11-22 17:09:10 +0800 Qing Lee <sobenlee@gmail.com> $
{XeLaTeX adapter (CTEX)}
\ProvidesExplFile{ctex-engine-xetex.def}
- {\ExplFileDate}{2.4.5}{\ExplFileDescription}
+ {\ExplFileDate}{2.4.6}{\ExplFileDescription}
\RequirePackage { xeCJK }
\exp_args:Nx \xeCJKsetup
{