diff options
author | Karl Berry <karl@freefriends.org> | 2015-09-12 21:24:44 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2015-09-12 21:24:44 +0000 |
commit | d501b4397bbc0f4389add919be80ccfca5b3863e (patch) | |
tree | 41af122e914676e41bc048a14128468bdfa83f6d | |
parent | af6faae1a8553e2c55f7980152d84d8cf4ac5a96 (diff) |
l3 (12sep15)
git-svn-id: svn://tug.org/texlive/trunk@38360 c570f23f-e606-0410-a88d-b1316a301751
71 files changed, 1359 insertions, 516 deletions
diff --git a/Master/texmf-dist/doc/latex/l3experimental/README.md b/Master/texmf-dist/doc/latex/l3experimental/README.md index 3e2caa7eb4e..e843f68e93d 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/README.md +++ b/Master/texmf-dist/doc/latex/l3experimental/README.md @@ -1,24 +1,12 @@ +Experimental LaTeX3 Concepts +============================ - Experimental LaTeX3 High-Level Concepts - ======================================= +Released 2015/09/11 - 2011/08/14 - - -WHERE TO GET IT ---------------- - -The files in this distribution represent a snapshot of selected files -from the Subversion (SVN) repository of the LaTeX3 Project. - -To obtain current versions of the files, visit -<http://www.latex-project.org/code.html> which contains further -instructions. - -OVERVIEW +Overview -------- -The l3experimental packages are a collection of experimental implementations +The `l3experimental` packages are a collection of experimental implementations for aspects of the LaTeX3 kernel, dealing with higher-level ideas such as the Designer Interface. Some of them work as stand alone packages, providing new functionality, and can be used on top of LaTeX2e with no changes to the @@ -26,45 +14,51 @@ existing kernel. Others go further, and redefine LaTeX2e internals to provide better methods for managing certain constructs. The packages in the collection are under active development and the interfaces may change. +All of the material in the collection requires the LaTeX3 base layer package +[`l3kernel`](http://ctan.org/pkg/l3kernel). The two packages must be installed +in matching versions: if you update `l3experimental`, make sure that `l3kernel` is +updated at the same time. + Currently included in the CTAN release of l3experimental are the following bundles: - * l3sort - * l3str - * xcoffins - * xgalley + * `l3sort` + * `l3str` + * `xcoffins` + * `xgalley` -l3sort ------- +`l3sort` +-------- -Ordered variables content (in tl, clist or seq variables) may be sorted -in a flexible manner using the l3sort module. The definition of how to sort +Ordered variables content (in `tl`, `clist` or `seq` variables) may be sorted +in a flexible manner using the `l3sort` module. The definition of how to sort two items is provided by the programmer at the point at which the sort is carried out. Internally, the sorting algorithm is designed to take advantage of TeX token registers to allow a high performance and scalable sort. -l3str ------ +`l3str` +------- A 'string' in TeX terms is a token list in which all of the tokens have category code 12 ('other'), with the exception of spaces which have the -category code 10 ('space'). The l3str bundle consists of two parts. The -first is l3str itself. This is a collection of functions to act on strings, +category code 10 ('space'). The `l3str` bundle consists of two parts. The +first is `l3str` itself. This is a collection of functions to act on strings, including for manipulations such as UTF8 mappings in pdfTeX. The second -part of the bundle is l3regex, a regular expression search-and-replace -implementation written in TeX primitives. The regex module works on a string -basis, ignoring category codes. +part of the bundle is `l3regex`, a regular expression search-and-replace +implementation written in TeX primitives. The regex module works on token +lists, and is part of `l3str` (currently) for historical reasons: the team +anticipate splitting the two in the future. -xcoffins --------- +`xcoffins` +---------- A _coffin_ is a 'box with handles': a data structure which comprises both a TeX box and associated information to allow controlled typesetting. -The xcoffins package provides a high-level interface for manipulating -coffins. This is supported by the lower-level l3coffins package, which +The `xcoffins` package provides a high-level interface for manipulating +coffins. This is supported by the lower-level `l3coffins` package, which provides the data structure. -xgalley -------- +`xgalley` +--------- In LaTeX3 terminology a galley is a rectangular area which receives text and other material filling it from top. The vertically extend of @@ -75,29 +69,63 @@ there are ways to control or change its behaviour. The xgalley module provides a mechanism for filling galleys and controlling the spacing, hyphenation and justification within them. -DISCUSSION +Discussion ---------- Discussion concerning the approach, suggestions for improvements, -changes, additions, etc. should be addressed to the list LaTeX-L. +changes, additions, _etc._ should be addressed to the list +[LaTeX-L](http://news.gmane.org/group/gmane.comp.tex.latex.latex3). You can subscribe to this list by sending mail to - listserv@urz.uni-heidelberg.de + listserv@urz.uni-heidelberg.de with the body containing - subscribe LATEX-L <Your-First-Name> <Your-Second-Name> + subscribe LATEX-L <Your-First-Name> <Your-Second-Name> + +Issues +------ + +The issue tracker for LaTeX3 is currently located at + + https://github.com/latex3/latex3/issues -BUGS ----- +Please report specific issues with LaTeX3 code there; more general +discussion should be directed to the [LaTeX-L list](#Discussion). -The issue tracker for LaTeX3 bugs is currently located at +The LaTeX3 Project +------------------ - https://github.com/latex3/latex3/issues +Development of LaTeX3 is carried out by +[The LaTeX3 Project](http://www.latex-project.org/latex3.html). Currently, +the team members are -Please report specific issues with LaTeX3 code there. More general -discussion should be directed to the LaTeX-L lists. + * Johannes Braams + * David Carlisle + * Robin Fairbairns + * Morten Høgholm + * Bruno Le Floch + * Thomas Lotze + * Frank Mittelbach + * Will Robertson + * Chris Rowley + * Rainer Schöpf + * Joseph Wright + +Former members of The LaTeX3 Project team were + + * Michael Downes + * Denys Duchier + * Alan Jeffrey + * Martin Schröder + +The development team can be contacted +by e-mail: <latex-team@latex-project.org>; for general LaTeX3 discussion +the [LaTeX-L list](#Discussion) should be used. + +----- ---- Copyright 1998 -- 2011 - The LaTeX3 Project. All rights reserved --- +<p>Copyright (C) 1998-2011,2015 The LaTeX3 Project <br /> +<a href="http://latex-project.org/">http://latex-project.org/</a> <br /> +All rights reserved.</p> diff --git a/Master/texmf-dist/doc/latex/l3experimental/l3sort/l3sort.pdf b/Master/texmf-dist/doc/latex/l3experimental/l3sort/l3sort.pdf Binary files differindex f9d179aeb54..797da4cae3e 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/l3sort/l3sort.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/l3sort/l3sort.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3flag.pdf b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3flag.pdf Binary files differindex 61abc223f25..61fd18802fb 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3flag.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3flag.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3regex.pdf b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3regex.pdf Binary files differindex 1f24dbe24ab..565edcb5068 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3regex.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3regex.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-convert.pdf b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-convert.pdf Binary files differindex 00729108192..c4e96c9ddad 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-convert.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-convert.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-expl.pdf b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-expl.pdf Binary files differindex 0265abfc56c..52e065fc76d 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-expl.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-expl.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-format.pdf b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-format.pdf Binary files differindex 279948ceab8..e2a0349fe3e 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-format.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3str-format.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3tl-analysis.pdf b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3tl-analysis.pdf Binary files differindex 7096c141088..53571442520 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3tl-analysis.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3tl-analysis.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3tl-build.pdf b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3tl-build.pdf Binary files differindex a99f80bf833..2f2fffe31c4 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/l3str/l3tl-build.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/l3str/l3tl-build.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/xcoffins/xcoffins.pdf b/Master/texmf-dist/doc/latex/l3experimental/xcoffins/xcoffins.pdf Binary files differindex 88a5daa5b75..abb6fd5860a 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/xcoffins/xcoffins.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/xcoffins/xcoffins.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/xgalley/l3galley.pdf b/Master/texmf-dist/doc/latex/l3experimental/xgalley/l3galley.pdf Binary files differindex cc26c985823..9e166e0cc15 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/xgalley/l3galley.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/xgalley/l3galley.pdf diff --git a/Master/texmf-dist/doc/latex/l3experimental/xgalley/xgalley.pdf b/Master/texmf-dist/doc/latex/l3experimental/xgalley/xgalley.pdf Binary files differindex 3e85609cf51..4c24ea86f43 100644 --- a/Master/texmf-dist/doc/latex/l3experimental/xgalley/xgalley.pdf +++ b/Master/texmf-dist/doc/latex/l3experimental/xgalley/xgalley.pdf diff --git a/Master/texmf-dist/doc/latex/l3kernel/README.md b/Master/texmf-dist/doc/latex/l3kernel/README.md index d83695aa636..805819330ad 100644 --- a/Master/texmf-dist/doc/latex/l3kernel/README.md +++ b/Master/texmf-dist/doc/latex/l3kernel/README.md @@ -1,6 +1,8 @@ LaTeX3 Programming Conventions ============================== +Released 2015/09/11 + Overview -------- @@ -48,21 +50,21 @@ changes, additions, _etc._ should be addressed to the list You can subscribe to this list by sending mail to - listserv@urz.uni-heidelberg.de + listserv@urz.uni-heidelberg.de with the body containing - subscribe LATEX-L <Your-First-Name> <Your-Second-Name> + subscribe LATEX-L <Your-First-Name> <Your-Second-Name> -Bugs ----- +Issues +------ -The issue tracker for LaTeX3 bugs is currently located at +The issue tracker for LaTeX3 is currently located at - https://github.com/latex3/latex3/issues + https://github.com/latex3/latex3/issues -Please report specific issues with LaTeX3 code there. More general -discussion should be directed to the LaTeX-L lists. +Please report specific issues with LaTeX3 code there; more general +discussion should be directed to the [LaTeX-L list](#Discussion). The LaTeX3 Project ------------------ @@ -92,10 +94,10 @@ Former members of The LaTeX3 Project team were The development team can be contacted by e-mail: <latex-team@latex-project.org>; for general LaTeX3 discussion -the [LaTeX-L list](http://news.gmane.org/group/gmane.comp.tex.latex.latex3) -should be used. +the [LaTeX-L list](#Discussion) should be used. ----- -Copyright (C) 1998-2012 The LaTeX3 Project -All rights reserved +<p>Copyright (C) 1998-2012,2015 The LaTeX3 Project <br /> +<a href="http://latex-project.org/">http://latex-project.org/</a> <br /> +All rights reserved.</p> diff --git a/Master/texmf-dist/doc/latex/l3kernel/expl3.pdf b/Master/texmf-dist/doc/latex/l3kernel/expl3.pdf Binary files differindex d85d051cf9f..3a1fac84e6d 100644 --- a/Master/texmf-dist/doc/latex/l3kernel/expl3.pdf +++ b/Master/texmf-dist/doc/latex/l3kernel/expl3.pdf diff --git a/Master/texmf-dist/doc/latex/l3kernel/interface3.pdf b/Master/texmf-dist/doc/latex/l3kernel/interface3.pdf Binary files differindex 1ad63f013eb..af83501f041 100644 --- a/Master/texmf-dist/doc/latex/l3kernel/interface3.pdf +++ b/Master/texmf-dist/doc/latex/l3kernel/interface3.pdf diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3docstrip.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3docstrip.pdf Binary files differindex 533a90f1517..54f92d362f4 100644 --- a/Master/texmf-dist/doc/latex/l3kernel/l3docstrip.pdf +++ b/Master/texmf-dist/doc/latex/l3kernel/l3docstrip.pdf diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.pdf Binary files differindex 5cc45329f9d..1652f555cf6 100644 --- a/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.pdf +++ b/Master/texmf-dist/doc/latex/l3kernel/l3styleguide.pdf diff --git a/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.pdf b/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.pdf Binary files differindex daf8e09960d..f65e76046a5 100644 --- a/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.pdf +++ b/Master/texmf-dist/doc/latex/l3kernel/l3syntax-changes.pdf diff --git a/Master/texmf-dist/doc/latex/l3kernel/source3.pdf b/Master/texmf-dist/doc/latex/l3kernel/source3.pdf Binary files differindex 23f7558d822..4ec3f18b9a7 100644 --- a/Master/texmf-dist/doc/latex/l3kernel/source3.pdf +++ b/Master/texmf-dist/doc/latex/l3kernel/source3.pdf diff --git a/Master/texmf-dist/doc/latex/l3kernel/source3body.tex b/Master/texmf-dist/doc/latex/l3kernel/source3body.tex index 111ea1b94ac..260d0248d4c 100644 --- a/Master/texmf-dist/doc/latex/l3kernel/source3body.tex +++ b/Master/texmf-dist/doc/latex/l3kernel/source3body.tex @@ -453,6 +453,7 @@ used on top of \LaTeXe{} if \cs{outer} tokens are used in the arguments. \ExplSyntaxOff \DocInput{l3candidates.dtx} +\DocInput{l3sys.dtx} \DocInput{l3luatex.dtx} \DocInput{l3drivers.dtx} diff --git a/Master/texmf-dist/doc/latex/l3packages/README.md b/Master/texmf-dist/doc/latex/l3packages/README.md index 5a155d9be1b..84e929500cb 100644 --- a/Master/texmf-dist/doc/latex/l3packages/README.md +++ b/Master/texmf-dist/doc/latex/l3packages/README.md @@ -1,6 +1,8 @@ LaTeX3 High-Level Concepts ========================== +Released 2015/09/11 + Overview -------- @@ -13,7 +15,7 @@ to a stand-alone LaTeX3 format. All of the material in the collection requires the LaTeX3 base layer package [`l3kernel`](http://ctan.org/pkg/l3kernel). The two packages must be installed -in matching versions: if you update l3packages, make sure that `l3kernel` is +in matching versions: if you update `l3packages`, make sure that `l3kernel` is updated at the same time. Currently included in the CTAN release of `l3packages` are the following @@ -63,21 +65,21 @@ changes, additions, _etc._ should be addressed to the list You can subscribe to this list by sending mail to - listserv@urz.uni-heidelberg.de + listserv@urz.uni-heidelberg.de with the body containing - subscribe LATEX-L <Your-First-Name> <Your-Second-Name> + subscribe LATEX-L <Your-First-Name> <Your-Second-Name> -Bugs ----- +Issues +------ -The issue tracker for LaTeX3 bugs is currently located at +The issue tracker for LaTeX3 is currently located at - https://github.com/latex3/latex3/issues + https://github.com/latex3/latex3/issues -Please report specific issues with LaTeX3 code there. More general -discussion should be directed to the LaTeX-L lists. +Please report specific issues with LaTeX3 code there; more general +discussion should be directed to the [LaTeX-L list](#Discussion). The LaTeX3 Project ------------------ @@ -107,8 +109,10 @@ Former members of The LaTeX3 Project team were The development team can be contacted by e-mail: <latex-team@latex-project.org>; for general LaTeX3 discussion -the [LaTeX-L list](http://news.gmane.org/group/gmane.comp.tex.latex.latex3) -should be used. +the [LaTeX-L list](#Discussion) should be used. + +----- ---- Copyright 1998-2011 - The LaTeX3 Project. All rights reserved --- +<p>Copyright (C) 1998-2011,2015 The LaTeX3 Project <br /> +<a href="http://latex-project.org/">http://latex-project.org/</a> <br /> +All rights reserved.</p> diff --git a/Master/texmf-dist/doc/latex/l3packages/l3keys2e/l3keys2e.pdf b/Master/texmf-dist/doc/latex/l3packages/l3keys2e/l3keys2e.pdf Binary files differindex 31191da5995..808130a6ba5 100644 --- a/Master/texmf-dist/doc/latex/l3packages/l3keys2e/l3keys2e.pdf +++ b/Master/texmf-dist/doc/latex/l3packages/l3keys2e/l3keys2e.pdf diff --git a/Master/texmf-dist/doc/latex/l3packages/xfrac/xfrac.pdf b/Master/texmf-dist/doc/latex/l3packages/xfrac/xfrac.pdf Binary files differindex a86b1e74c77..ea4b18dba9d 100644 --- a/Master/texmf-dist/doc/latex/l3packages/xfrac/xfrac.pdf +++ b/Master/texmf-dist/doc/latex/l3packages/xfrac/xfrac.pdf diff --git a/Master/texmf-dist/doc/latex/l3packages/xparse/xparse.pdf b/Master/texmf-dist/doc/latex/l3packages/xparse/xparse.pdf Binary files differindex 0b1f1062b73..5ed995487ea 100644 --- a/Master/texmf-dist/doc/latex/l3packages/xparse/xparse.pdf +++ b/Master/texmf-dist/doc/latex/l3packages/xparse/xparse.pdf diff --git a/Master/texmf-dist/doc/latex/l3packages/xtemplate/xtemplate.pdf b/Master/texmf-dist/doc/latex/l3packages/xtemplate/xtemplate.pdf Binary files differindex 5b9e948594e..052658f844f 100644 --- a/Master/texmf-dist/doc/latex/l3packages/xtemplate/xtemplate.pdf +++ b/Master/texmf-dist/doc/latex/l3packages/xtemplate/xtemplate.pdf diff --git a/Master/texmf-dist/source/latex/l3experimental/l3sort/l3sort.dtx b/Master/texmf-dist/source/latex/l3experimental/l3sort/l3sort.dtx index a304a9110c1..9e60a5a0040 100644 --- a/Master/texmf-dist/source/latex/l3experimental/l3sort/l3sort.dtx +++ b/Master/texmf-dist/source/latex/l3experimental/l3sort/l3sort.dtx @@ -37,8 +37,8 @@ %<*driver|package> % The version of expl3 required is tested as early as possible, as % some really old versions do not define \ProvidesExplPackage. -\RequirePackage{expl3}[2015/09/06] -%<package>\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +%<package>\@ifpackagelater{expl3}{2015/09/11} %<package> {} %<package> {% %<package> \PackageError{l3sort}{Support package l3kernel too old} @@ -50,7 +50,7 @@ %<package> }% %<package> \endinput %<package> } -\GetIdInfo$Id: l3sort.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3sort.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental sorting functions} %</driver|package> %<*driver> @@ -199,7 +199,7 @@ % registers, totalling $2^{N-1}+2^{N-2}+2^{N-2}=2^{N}$ registers. % \begin{macrocode} \int_const:Nn \c_@@_max_length_int - { \luatex_if_engine:TF { 49152 } { 24576 } } + { \sys_if_engine_luatex:TF { 49152 } { 24576 } } % \end{macrocode} % \end{variable} % diff --git a/Master/texmf-dist/source/latex/l3experimental/l3str/l3flag.dtx b/Master/texmf-dist/source/latex/l3experimental/l3str/l3flag.dtx index e95fd602974..4192826a6c4 100644 --- a/Master/texmf-dist/source/latex/l3experimental/l3str/l3flag.dtx +++ b/Master/texmf-dist/source/latex/l3experimental/l3str/l3flag.dtx @@ -36,8 +36,8 @@ %<*driver|package> % The version of expl3 required is tested as early as possible, as % some really old versions do not define \ProvidesExplPackage. -\RequirePackage{expl3}[2015/09/06] -%<package>\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +%<package>\@ifpackagelater{expl3}{2015/09/11} %<package> {} %<package> {% %<package> \PackageError{l3flag}{Support package l3kernel too old} @@ -49,7 +49,7 @@ %<package> }% %<package> \endinput %<package> } -\GetIdInfo$Id: l3flag.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3flag.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental flags} %</driver|package> %<*driver> diff --git a/Master/texmf-dist/source/latex/l3experimental/l3str/l3regex.dtx b/Master/texmf-dist/source/latex/l3experimental/l3str/l3regex.dtx index 81c2751ada7..5af1c4864ea 100644 --- a/Master/texmf-dist/source/latex/l3experimental/l3str/l3regex.dtx +++ b/Master/texmf-dist/source/latex/l3experimental/l3str/l3regex.dtx @@ -36,8 +36,8 @@ %<*driver|package> % The version of expl3 required is tested as early as possible, as % some really old versions do not define \ProvidesExplPackage. -\RequirePackage{expl3}[2015/09/06] -%<package>\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +%<package>\@ifpackagelater{expl3}{2015/09/11} %<package> {} %<package> {% %<package> \PackageError{l3regex}{Support package l3kernel too old} @@ -49,7 +49,7 @@ %<package> }% %<package> \endinput %<package> } -\GetIdInfo$Id: l3regex.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3regex.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental regular expressions} %</driver|package> %<*driver> diff --git a/Master/texmf-dist/source/latex/l3experimental/l3str/l3str-convert.dtx b/Master/texmf-dist/source/latex/l3experimental/l3str/l3str-convert.dtx index 0635e17f2d7..c964ec55822 100644 --- a/Master/texmf-dist/source/latex/l3experimental/l3str/l3str-convert.dtx +++ b/Master/texmf-dist/source/latex/l3experimental/l3str/l3str-convert.dtx @@ -35,7 +35,7 @@ % %<*driver|package> \RequirePackage{expl3} -\GetIdInfo$Id: l3str-convert.dtx 5659 2015-07-14 18:58:00Z joseph $ +\GetIdInfo$Id: l3str-convert.dtx 5998 2015-09-11 19:51:00Z joseph $ {L3 Experimental string encoding conversions} %</driver|package> %<*driver> @@ -318,7 +318,15 @@ % $1114111$ for other engines. % \begin{macrocode} \int_const:Nn \c_max_char_int - { \pdftex_if_engine:TF { "FF } { "10FFFF } } + { + \bool_if:nTF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } + { "10FFFF } + { "FF } + } % \end{macrocode} % \end{variable} % @@ -1033,13 +1041,16 @@ % % \begin{macro}[int, rEXP]{\@@_filter_bytes:n} % \begin{macro}[aux, rEXP]{\@@_filter_bytes_aux:N} -% In the case of pdf\TeX{}, every character is a byte. For +% In the case of 8-bit engines, every character is a byte. For % Unicode-aware engines, test the character code; non-bytes cause us % to raise the flag \texttt{str_byte}. Spaces have already been given % the correct category code when this function is called. % \begin{macrocode} -\pdftex_if_engine:TF - { \cs_new_eq:NN \@@_filter_bytes:n \use:n } +\bool_if:nTF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } { \cs_new:Npn \@@_filter_bytes:n #1 { @@ -1058,6 +1069,7 @@ \@@_filter_bytes_aux:N } } + { \cs_new_eq:NN \@@_filter_bytes:n \use:n } % \end{macrocode} % \end{macro} % \end{macro} @@ -1067,8 +1079,11 @@ % The simplest unescaping method removes non-bytes from % \cs{g_@@_result_tl}. % \begin{macrocode} -\pdftex_if_engine:TF - { \cs_new_protected_nopar:Npn \@@_convert_unescape_: { } } +\bool_if:nTF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } { \cs_new_protected_nopar:Npn \@@_convert_unescape_: { @@ -1078,6 +1093,7 @@ \@@_if_flag_error:nnx { str_byte } { non-byte } { bytes } } } + { \cs_new_protected_nopar:Npn \@@_convert_unescape_: { } } \cs_new_eq:NN \@@_convert_unescape_bytes: \@@_convert_unescape_: % \end{macrocode} % \end{macro} @@ -1116,42 +1132,12 @@ % \begin{macrocode} \group_begin: \char_set_catcode_other:n { 0 } - \pdftex_if_engine:TF -% \end{macrocode} -% \begin{macro}[aux, EXP]{\@@_encode_native_char:n} -% Since pdf\TeX{} only supports 8-bit characters, and we have a table -% of all bytes, the conversion can be done in linear time within an -% \texttt{x}-expanding assignment. Look out for character codes larger -% than $255$, those characters are replaced by |?|, and raise a flag, -% which then triggers a pdf\TeX{}-specific error. -% \begin{macrocode} + \bool_if:nTF { - \cs_new_protected_nopar:Npn \@@_convert_encode_: - { - \flag_clear:n { str_error } - \@@_convert_gmap_internal:N \@@_encode_native_char:n - \@@_if_flag_error:nnx { str_error } - { pdfTeX-native-overflow } { } - } - \cs_new:Npn \@@_encode_native_char:n #1 - { - \if_int_compare:w #1 < \c_two_hundred_fifty_six - \@@_output_byte:n {#1} - \else: - \flag_raise:n { str_error } - ? - \fi: - } - \__msg_kernel_new:nnnn { str } { pdfTeX-native-overflow } - { Character~code~too~large~for~pdfTeX. } - { - The~pdfTeX~engine~only~supports~8-bit~characters:~ - valid~character~codes~are~in~the~range~[0,255].~ - To~manipulate~arbitrary~Unicode,~use~LuaTeX~or~XeTeX. - } + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: } % \end{macrocode} -% \end{macro} % \begin{macro}[aux]{\@@_encode_native_loop:w} % \begin{macro}[aux]{\@@_encode_native_flush:} % \begin{macro}[aux, rEXP]{\@@_encode_native_filter:N} @@ -1186,6 +1172,40 @@ } } % \end{macrocode} +% \begin{macro}[aux, EXP]{\@@_encode_native_char:n} +% Since pdf\TeX{} only supports 8-bit characters, and we have a table +% of all bytes, the conversion can be done in linear time within an +% \texttt{x}-expanding assignment. Look out for character codes larger +% than $255$, those characters are replaced by |?|, and raise a flag, +% which then triggers a pdf\TeX{}-specific error. +% \begin{macrocode} + { + \cs_new_protected_nopar:Npn \@@_convert_encode_: + { + \flag_clear:n { str_error } + \@@_convert_gmap_internal:N \@@_encode_native_char:n + \@@_if_flag_error:nnx { str_error } + { pdfTeX-native-overflow } { } + } + \cs_new:Npn \@@_encode_native_char:n #1 + { + \if_int_compare:w #1 < \c_two_hundred_fifty_six + \@@_output_byte:n {#1} + \else: + \flag_raise:n { str_error } + ? + \fi: + } + \__msg_kernel_new:nnnn { str } { pdfTeX-native-overflow } + { Character~code~too~large~for~pdfTeX. } + { + The~pdfTeX~engine~only~supports~8-bit~characters:~ + valid~character~codes~are~in~the~range~[0,255].~ + To~manipulate~arbitrary~Unicode,~use~LuaTeX~or~XeTeX. + } + } +% \end{macrocode} +% \end{macro} % \end{macro} % \end{macro} % \end{macro} @@ -1423,11 +1443,15 @@ % % Message used when the \enquote{bytes} unescaping fails because the % string given to \cs{str_set_convert:Nnnn} contains a non-byte. This -% cannot happen for the pdf\TeX{} engine, since that engine only -% supports 8-bit characters. Messages used for other escapings and +% cannot happen for the -8-bit engines. +% Messages used for other escapings and % encodings are defined in each definition file. % \begin{macrocode} -\pdftex_if_engine:F +\bool_if:nT + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } { \__msg_kernel_new:nnnn { str } { non-byte } { String~invalid~in~escaping~'#1':~it~may~only~contain~bytes. } diff --git a/Master/texmf-dist/source/latex/l3experimental/l3str/l3str-expl.dtx b/Master/texmf-dist/source/latex/l3experimental/l3str/l3str-expl.dtx index ffb0ebb92f0..95ef2a826ed 100644 --- a/Master/texmf-dist/source/latex/l3experimental/l3str/l3str-expl.dtx +++ b/Master/texmf-dist/source/latex/l3experimental/l3str/l3str-expl.dtx @@ -36,8 +36,8 @@ %<*driver|package> % The version of expl3 required is tested as early as possible, as % some really old versions do not define \ProvidesExplPackage. -\RequirePackage{expl3}[2015/09/06] -%<package>\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +%<package>\@ifpackagelater{expl3}{2015/09/11} %<package> {} %<package> {% %<package> \PackageError{l3str}{Support package l3kernel too old} @@ -49,7 +49,7 @@ %<package> }% %<package> \endinput %<package> } -\GetIdInfo$Id: l3str-expl.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3str-expl.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental strings} \def\ExplFileName{l3str} %</driver|package> diff --git a/Master/texmf-dist/source/latex/l3experimental/xgalley/l3galley.dtx b/Master/texmf-dist/source/latex/l3experimental/xgalley/l3galley.dtx index ed9db8b5920..305a91b629d 100644 --- a/Master/texmf-dist/source/latex/l3experimental/xgalley/l3galley.dtx +++ b/Master/texmf-dist/source/latex/l3experimental/xgalley/l3galley.dtx @@ -38,8 +38,8 @@ %<*driver|package> % The version of expl3 required is tested as early as possible, as % some really old versions do not define \ProvidesExplPackage. -\RequirePackage{expl3}[2015/09/06] -%<package>\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +%<package>\@ifpackagelater{expl3}{2015/09/11} %<package> {} %<package> {% %<package> \PackageError{l3galley}{Support package l3kernel too old} @@ -51,7 +51,7 @@ %<package> }% %<package> \endinput %<package> } -\GetIdInfo$Id: l3galley.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3galley.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental galley code} %</driver|package> %<*driver> @@ -735,7 +735,7 @@ % % Settings for application by the galley respect the usual \TeX{} grouping and % so are all local variables. -% +% % \begin{variable} % {\l_@@_cutout_left_indent_seq, \l_@@_cutout_right_indent_seq} % Essentially scratch space, used when setting up a cutout in a paragrph, @@ -1183,7 +1183,7 @@ % operation. Once the paragraph has been typeset, the number of lines is % added to the running total. It's possible that the conceptual paragraph % contains display-like material, and simply setting the number of lines -% equal to \cs{tex_prevgraf:D} would lose these. +% equal to \cs{tex_prevgraf:D} would lose these. % \begin{macrocode} { \g_galley_par_end_hook_tl @@ -1772,7 +1772,7 @@ % \end{macro} % % \subsection{Setting the primitive paragraph shape} -% +% % \begin{macro}[int]{\@@_parshape_set:} % \begin{macro}[aux] % { @@ -1814,7 +1814,7 @@ % Setting the margins is simple. Either they are zero, using the full measure, % or they are not. This is always set even if there are other elements to % apply as these settings are very fast, so it is not worth doing a check -% at this stage for further parts to apply. +% at this stage for further parts to apply. % \begin{macrocode} \cs_new_protected_nopar:Npn \@@_parshape_set_margins: { @@ -1945,7 +1945,7 @@ } % \end{macrocode} % Grab the last entry of the shorter sequence and repeat it to match -% the length of the longer. +% the length of the longer. % \begin{macrocode} \cs_new_protected:Npn \@@_parshape_set_cutouts:N #1 { diff --git a/Master/texmf-dist/source/latex/l3kernel/expl3.dtx b/Master/texmf-dist/source/latex/l3kernel/expl3.dtx index 69518ad2ae1..b0dbaa76993 100644 --- a/Master/texmf-dist/source/latex/l3kernel/expl3.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/expl3.dtx @@ -36,8 +36,8 @@ %<*driver|generic|package> \def\ExplFileName{expl3} \def\ExplFileDescription{L3 programming layer} -\def\ExplFileDate{2015/09/06} -\def\ExplFileVersion{5925} +\def\ExplFileDate{2015/09/11} +\def\ExplFileVersion{6002} %</driver|generic|package> %<*driver> \documentclass[full]{l3doc} @@ -948,7 +948,8 @@ % are driver-dependent. Options available are % \begin{itemize}[font = \texttt] % \item[auto] Let \LaTeX3 determine the correct driver. With DVI output, this -% will select the \texttt{dvips} back-end. This is the standard setting. +% will select the \texttt{dvips} back-end for \pdfTeX{} and \LuaTeX{}, and +% \texttt{dvipdfmx} for \pTeX{} and \upTeX{}. This is the standard setting. % \item[latex2e] Use the \pkg{graphics} package to select the driver, rather % than \LaTeX3 code. % \item[dvips] Use the \texttt{dvips} driver. @@ -993,7 +994,7 @@ % \end{itemize} % Any engine which defines |\pdfoutput| (\emph{i.e.}~allows direct production % of a PDF file without a DVI intermediate) must also provide |\pdfliteral|. -% +% % Practically, these requirements are met by the engines % \begin{itemize} % \item \pdfTeX{} v1.30 or later. @@ -1003,7 +1004,7 @@ % \end{itemize} % of which the first three engines are currently officially supported by % the team. -% +% % Additional modules beyond the core of \pkg{expl3} may require additional % primitives. In particular, third-party authors may significantly % extend the primitive coverage requirements. @@ -1323,19 +1324,27 @@ { \tl_set:Nx \l__expl_driver_tl { - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { xdvipdfmx } { \__expl_if_pdf:TF { pdfmode } - { dvips } + { + \bool_if:nTF + { + \sys_if_engine_pdftex_p: || + \sys_if_engine_luatex_p: + } + { dvips } + { dvipdfmx } + } } } }, driver / dvipdfmx .code:n = { \tl_set:Nn \l__expl_driver_tl { dvipdfmx } - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { \__msg_kernel_error:nnnn { expl } { wrong-driver } { dvipdfmx } { xdvipdfmx } @@ -1353,7 +1362,7 @@ driver / dvips .code:n = { \tl_set:Nn \l__expl_driver_tl { dvips } - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { \__msg_kernel_error:nnnn { expl } { wrong-driver } { dvips } { xdvipdfmx } @@ -1373,7 +1382,7 @@ driver / pdfmode .code:n = { \tl_set:Nn \l__expl_driver_tl { pdfmode } - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { \__msg_kernel_error:nnnn { expl } { wrong-driver } { pdfmode } { xdvipdfmx } @@ -1391,7 +1400,7 @@ driver / xdvipdfmx .code:n = { \tl_set:Nn \l__expl_driver_tl { xdvipdfmx } - \xetex_if_engine:F + \sys_if_engine_xetex:F { \__expl_if_pdf:TF { @@ -1735,7 +1744,7 @@ } \tex_input:D l3 - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { xdvipdfmx } { \bool_if:nTF diff --git a/Master/texmf-dist/source/latex/l3kernel/l3.ins b/Master/texmf-dist/source/latex/l3kernel/l3.ins index ac8b3aa7b9d..2876e8968b6 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3.ins +++ b/Master/texmf-dist/source/latex/l3kernel/l3.ins @@ -76,6 +76,7 @@ Do not distribute a modified version of this file. \from{l3coffins.dtx} {package} \from{l3color.dtx} {package} \from{l3candidates.dtx} {package} + \from{l3sys.dtx} {package} \from{l3luatex.dtx} {package} } } diff --git a/Master/texmf-dist/source/latex/l3kernel/l3alloc.dtx b/Master/texmf-dist/source/latex/l3kernel/l3alloc.dtx index cd79e4469d9..16009950b33 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3alloc.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3alloc.dtx @@ -1,6 +1,6 @@ % \iffalse meta-comment % -%% File: l3alloc.dtx Copyright (C) 1990-2012,2014 The LaTeX3 Project +%% File: l3alloc.dtx Copyright (C) 1990-2012,2014,2015 The LaTeX3 Project %% %% It may be distributed and/or modified under the conditions of the %% LaTeX Project Public License (LPPL), either version 1.3c of this @@ -35,7 +35,7 @@ % %<*driver> \documentclass[full]{l3doc} -\GetIdInfo$Id: l3alloc.dtx 5363 2014-08-24 19:57:56Z joseph $ +\GetIdInfo$Id: l3alloc.dtx 5952 2015-09-08 16:10:05Z joseph $ {L3 Register allocation} \begin{document} \DocInput{\jobname.dtx} @@ -184,7 +184,7 @@ % need to have their allocators set up \enquote{early}. It therefore % makes sense to collect most of them together here. % \begin{macrocode} -\luatex_if_engine:TF +\cs_if_exist:NTF \luatex_luatexversion:D { \@@_new:nnnN { box } \c_zero \c_max_register_int \tex_chardef:D } { \@@_new:nnnN { box } \c_zero \c_max_register_int \tex_mathchardef:D } \@@_new:nnnN { dim } \c_zero \c_max_register_int \tex_dimendef:D diff --git a/Master/texmf-dist/source/latex/l3kernel/l3basics.dtx b/Master/texmf-dist/source/latex/l3kernel/l3basics.dtx index 63bde464f33..058c99aba53 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3basics.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3basics.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3basics.dtx 5897 2015-08-28 09:06:29Z joseph $ +\GetIdInfo$Id: l3basics.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Basic definitions} %</driver|package> %<*driver> @@ -1088,29 +1088,6 @@ % \cs{cs_if_exist:N}). % \end{function} % -% \subsection{Engine-specific conditionals} -% -% \begin{function}[updated = 2011-09-06,EXP,pTF]{\luatex_if_engine:} -% \begin{syntax} -% \cs{luatex_if_engine:TF} \Arg{true code} \Arg{false code} -% \end{syntax} -% Detects is the document is being compiled using \LuaTeX{}. -% \end{function} -% -% \begin{function}[updated = 2011-09-06,EXP,pTF]{\pdftex_if_engine:} -% \begin{syntax} -% \cs{pdftex_if_engine:TF} \Arg{true code} \Arg{false code} -% \end{syntax} -% Detects is the document is being compiled using \pdfTeX{}. -% \end{function} -% -% \begin{function}[updated = 2011-09-06,EXP,pTF]{\xetex_if_engine:} -% \begin{syntax} -% \cs{xetex_if_engine:TF} \Arg{true code} \Arg{false code} -% \end{syntax} -% Detects is the document is being compiled using \XeTeX{}. -% \end{function} -% % \subsection{Primitive conditionals} % % The \eTeX{} engine itself provides many different conditionals. Some @@ -2142,7 +2119,7 @@ % for the boolean. For example, % |\__cs_split_function:NN \foo_bar:cnx \use_i:nnn| as input % becomes |\use_i:nnn {foo_bar} {cnx} \c_true_bool|. -% +% % We cannot use |:| directly as it has the wrong category code so % an |x|-type expansion is used to force the conversion. % @@ -2971,50 +2948,6 @@ % \end{macrocode} % \end{macro} % -% \subsection{Engine specific definitions} -% -% \begin{macro}[pTF, EXP] -% {\xetex_if_engine:, \luatex_if_engine:, \pdftex_if_engine:} -% In some cases it will be useful to know which engine we're running. -% This can all be hard-coded for speed. -% \begin{macrocode} -\cs_new_eq:NN \luatex_if_engine:T \use_none:n -\cs_new_eq:NN \luatex_if_engine:F \use:n -\cs_new_eq:NN \luatex_if_engine:TF \use_ii:nn -\cs_new_eq:NN \pdftex_if_engine:T \use:n -\cs_new_eq:NN \pdftex_if_engine:F \use_none:n -\cs_new_eq:NN \pdftex_if_engine:TF \use_i:nn -\cs_new_eq:NN \xetex_if_engine:T \use_none:n -\cs_new_eq:NN \xetex_if_engine:F \use:n -\cs_new_eq:NN \xetex_if_engine:TF \use_ii:nn -\cs_new_eq:NN \luatex_if_engine_p: \c_false_bool -\cs_new_eq:NN \pdftex_if_engine_p: \c_true_bool -\cs_new_eq:NN \xetex_if_engine_p: \c_false_bool -\cs_if_exist:NT \xetex_XeTeXversion:D - { - \cs_gset_eq:NN \pdftex_if_engine:T \use_none:n - \cs_gset_eq:NN \pdftex_if_engine:F \use:n - \cs_gset_eq:NN \pdftex_if_engine:TF \use_ii:nn - \cs_gset_eq:NN \xetex_if_engine:T \use:n - \cs_gset_eq:NN \xetex_if_engine:F \use_none:n - \cs_gset_eq:NN \xetex_if_engine:TF \use_i:nn - \cs_gset_eq:NN \pdftex_if_engine_p: \c_false_bool - \cs_gset_eq:NN \xetex_if_engine_p: \c_true_bool - } -\cs_if_exist:NT \luatex_directlua:D - { - \cs_gset_eq:NN \luatex_if_engine:T \use:n - \cs_gset_eq:NN \luatex_if_engine:F \use_none:n - \cs_gset_eq:NN \luatex_if_engine:TF \use_i:nn - \cs_gset_eq:NN \pdftex_if_engine:T \use_none:n - \cs_gset_eq:NN \pdftex_if_engine:F \use:n - \cs_gset_eq:NN \pdftex_if_engine:TF \use_ii:nn - \cs_gset_eq:NN \luatex_if_engine_p: \c_true_bool - \cs_gset_eq:NN \pdftex_if_engine_p: \c_false_bool - } -% \end{macrocode} -% \end{macro} -% % \subsection{Doing nothing functions} % % \begin{macro}[EXP]{\prg_do_nothing:} diff --git a/Master/texmf-dist/source/latex/l3kernel/l3bootstrap.dtx b/Master/texmf-dist/source/latex/l3kernel/l3bootstrap.dtx index 9de367fc7ea..29d0a01caa8 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3bootstrap.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3bootstrap.dtx @@ -145,7 +145,7 @@ % \end{macro} % \end{macro} % \end{macro} -\GetIdInfo$Id: l3bootstrap.dtx 5729 2015-07-31 05:56:12Z joseph $ +\GetIdInfo$Id: l3bootstrap.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Bootstrap code} %</driver|package> %<*driver> @@ -318,11 +318,11 @@ end end end - tex.enableprimitives("", t) + tex.enableprimitives("", t) }% \fi \endgroup -%</package> +%</package> % \end{macrocode} % % \subsection{The \tn{pdfstrcmp} primitive with \XeTeX{} and \LuaTeX{}} @@ -387,7 +387,73 @@ \global\everyjob\expandafter {% \the\expandafter\everyjob - \expandafter\luatex_directlua:D\expandafter{\tempa}% + \expandafter\lua_now_x:n\expandafter{\tempa}% + } + \fi + \fi + \fi +\endgroup +% \end{macrocode} +% +% \subsection{Emulating \tn{Ucharchar} in \LuaTeX{}} +% +% Expandably creating character tokens can be done in macros but for the +% full Unicode range requires engine support in practical terms. That is +% available in \XeTeX{} as \tn{Ucharcat} but in \LuaTeX{} some Lua code +% is required. That is set up here, following the model above. Note that +% we do not try to emulate the syntax of the primitive (doable with \LuaTeX{} +% 0.80 or later, but not required by our use case). +% +% One minor wrinkle is that a catcode table is needed to return values. +% For format mode, long-term we can simply take an arbitrary one and make +% sure this is never allocated. In package mode use the same approach +% (and table) as \pkg{ucharcat}: look for an allocator and use it if available, +% or use a table unlikely to clash with any other use. We use the same table +% as \pkg{ucharcat} but as this is \enquote{disposable} we are safe. +% \begin{macrocode} +\begingroup + \expandafter\ifx\csname directlua\endcsname\relax + \else + \ifnum\luatexversion<70 % + \else +%<*initex> + % TEMP + \catcode`\@=11 % + \chardef\ucharcat@table="8000 % +%</initex> +%<*package> + \begingroup\expandafter\expandafter\expandafter\endgroup + \expandafter\ifx\csname newcatcodetable\endcsname\relax + \directlua{tex.enableprimitives("",{"initcatcodetable"})} + \chardef\ucharcat@table"7000 % + \initcatcodetable\ucharcat@table + \else + \newcatcodetable\ucharcat@table + \fi +%</package> + \catcode`\_=11 % + \catcode`\:=11 % + \def\tempa + {% + l3kernel = l3kernel or { } + local utf8_char = unicode.utf8.char + function l3kernel.charcat(charcode, catcode) + tex.setcatcode(\number\ucharcat@table, charcode, catcode) + tex.sprint(\number\ucharcat@table, utf8_char(charcode)) + end + } + \directlua{\tempa} + \ifnum 0% + \directlua + {% + if status.ini_version then + tex.write("1") + end + }>0 % + \global\everyjob\expandafter + {% + \the\expandafter\everyjob + \expandafter\lua_now_x:n\expandafter{\tempa}% } \fi \fi @@ -458,7 +524,7 @@ \endgroup \noexpand\endinput }% -%</package> +%</package> \fi \next % \end{macrocode} diff --git a/Master/texmf-dist/source/latex/l3kernel/l3candidates.dtx b/Master/texmf-dist/source/latex/l3kernel/l3candidates.dtx index 3b8cf3368c5..f5ad9fc0a00 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3candidates.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3candidates.dtx @@ -38,7 +38,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3candidates.dtx 5911 2015-09-03 08:24:00Z joseph $ +\GetIdInfo$Id: l3candidates.dtx 6002 2015-09-11 22:13:30Z joseph $ {L3 Experimental additions to l3kernel} %</driver|package> %<*driver> @@ -822,7 +822,7 @@ % letter-like characters which can also be case-changed). Begin-group and % end-group characters in the \meta{tokens} are normalized and become |{| % and |}|, respectively. -% +% % Importantly, notice that these functions are intended for working with % user text for typesetting. For case changing programmatic data see the % \pkg{l3str} module and discussion there of \cs{str_lower_case:n}, @@ -833,7 +833,7 @@ % input in the form of token lists or expandable functions will be expanded % \emph{unless} it falls within one of the special handling classes described % below. This expansion approach means that in general the result of case -% changing will match the \enquote{natural} outcome expected from a +% changing will match the \enquote{natural} outcome expected from a % \enquote{functional} approach to case modification. For example % \begin{verbatim} % \tl_set:Nn \l_tmpa_tl { hello } @@ -859,7 +859,7 @@ % \end{verbatim} % Material inside math mode is left entirely unchanged: in particular, no % expansion is undertaken. -% +% % Detection of math mode is controlled by the list of tokens in % \cs{l_tl_case_change_math_tl}, which should be in open--close pairs. In % package mode the standard settings is @@ -875,7 +875,7 @@ % the case changing functions are intended to apply to this should not be % an issue. % \end{variable} -% +% % \begin{variable}{\l_tl_case_change_exclude_tl} % Case changing can be prevented by using any command on the list % \cs{l_tl_case_change_exclude_tl}. Each entry should be a function @@ -902,7 +902,7 @@ % and |\ref| are automatically included in the list for exclusion from % case changing. % \end{variable} -% +% % In package mode, the case change system will also % convert text stored using the \LaTeXe{} \enquote{LICR} approach. This % will upper/lower case tokens as implemented for the font encodings @@ -926,12 +926,12 @@ % \end{verbatim} % When finding the first \enquote{letter} for this process, any content in % math mode or covered by \cs{l_tl_case_change_exclude_tl} is ignored. -% +% % (Note that the Unicode Consortium describe this as \enquote{title case}, but % that in English title case applies on a word-by-word basis. The % \enquote{mixed} case implemented here is a lower level concept needed for % both \enquote{title} and \enquote{sentence} casing of text.) -% +% % \begin{variable}{\l_tl_mixed_case_ignore_tl} % The list of characters to ignore when searching for the first % \enquote{letter} in mixed-casing is determined by @@ -1040,7 +1040,7 @@ % \cs{char_set_active_eq:NN} \meta{char} \meta{function} % \end{syntax} % Sets the behaviour of the \meta{char} in situations where it is -% active (category code $13$) to be equivalent to that of the +% active (category code $13$) to be equivalent to that of the % \meta{function}. The category code of the \meta{char} is % \emph{unchanged} by this process. The \meta{function} may itself % be an active character. @@ -1059,6 +1059,31 @@ % be an active character. % \end{function} % +% \begin{function}[EXP, added = 2015-09-09]{\char_generate:nn} +% \begin{syntax} +% \cs{char_generate:nn} \Arg{charcode} \Arg{catcode} +% \end{syntax} +% Generates a character token of the given \meta{charcode} and \meta{catcode} +% (both of which may be integer expressions). The \meta{catcode} may be +% one of +% \begin{itemize} +% \item $1$ (begin group) +% \item $2$ (end group) +% \item $3$ (math toggle) +% \item $4$ (alignment) +% \item $6$ (parameter) +% \item $7$ (math superscript) +% \item $8$ (math subscript) +% \item $11$ (letter) +% \item $12$ (other) +% \end{itemize} +% and other values will raise an error. +% +% The \meta{catcode} may be any one valid for the engine in use. Note +% however that for \XeTeX{} releases prior to 0.99992 only the 8-bit +% range ($0$ to $255$) is accepted due to engine limitations. +% \end{function} +% % \begin{function}[TF, updated = 2012-12-20]{\peek_N_type:} % \begin{syntax} % \cs{peek_N_type:TF} \Arg{true code} \Arg{false code} @@ -2969,7 +2994,7 @@ \cs_generate_variant:Nn \tl_if_head_eq_catcode:nNTF { o } % \end{macrocode} % \end{macro} -% +% % \begin{macro}[EXP]{\tl_lower_case:n, \tl_upper_case:n, \tl_mixed_case:n} % \begin{macro}[EXP]{\tl_lower_case:nn, \tl_upper_case:nn, \tl_mixed_case:nn} % The user level functions here are all wrappers around the internal @@ -3269,7 +3294,7 @@ % a string then examining the first four characters. For Cyrillic, the % fourth character can be used for a second split based on the character % code. -% +% % Note that as this is dependent on \LaTeXe{}, in format mode the code % goes straight to the final phase of handling control sequences. % \begin{macrocode} @@ -3308,8 +3333,8 @@ \cs_new:Npn \@@_change_case_cs_cyr:NnNNNNw #1#2#3#4#5#6#7 \q_stop { \@@_change_case_cs_type:Nnnnn #1 - { cyrillic } - { + { cyrillic } + { #2 _ \int_to_roman:n { @@ -3437,7 +3462,7 @@ % \end{macro} % \end{macro} % \end{macro} -% +% % \begin{macro}[aux, EXP]{\@@_change_case_lower_sigma:Nnw} % \begin{macro}[aux, EXP]{\@@_change_case_lower_sigma:w} % \begin{macro}[aux, EXP]{\@@_change_case_lower_sigma:Nw} @@ -3742,7 +3767,7 @@ % to generic routines, but at the cost of making the process rather opaque. % Instead, the approach taken here is to use a dedicated set of functions % which keep the different loop requirements clearly separate. -% +% % The main loop looks for the first \enquote{real} char in the input % (skipping any pre-letter chars). Once one is found, it is case changed to % upper case but first checking that there is not an entry in the exceptions @@ -3837,7 +3862,7 @@ \@@_change_case_cs:Nnnn #1 { upper } { \@@_change_case_loop:wnn - #2 \q_recursion_stop { lower } {#3} + #2 \q_recursion_stop { lower } {#3} } { \@@_change_case_cs:N #1 @@ -3991,7 +4016,7 @@ %</package> % \end{macrocode} % \end{variable} -% +% % \begin{variable}{\l_tl_mixed_case_ignore_tl} % Characters to skip over when finding the first letter in a word to be % mixed cased. @@ -4132,7 +4157,7 @@ \cyrishrt \CYRISHRT \cyrishrtdsc \CYRISHRTDSC \cyrizh \CYRIZH - \cyrje \CYRJE + \cyrje \CYRJE \cyrk \CYRK \cyrkbeak \CYRKBEAK \cyrkdsc \CYRKDSC @@ -4200,7 +4225,7 @@ \cyrz \CYRZ \cyrzdsc \CYRZDSC \cyrzh \CYRZH - \cyrzhdsc \CYRZHDSC + \cyrzhdsc \CYRZHDSC } { \q_recursion_tail } \@@_change_case_setup:nnnn @@ -4255,7 +4280,7 @@ \accdialytikatonos { \exp_stop_f: \LGR@accDialytika } \accdialytikavaria { \exp_stop_f: \LGR@accDialytika } \accdialytikaperispomeni { \exp_stop_f: \LGR@accDialytika } - \accperispomeni { \exp_stop_f: \LGR@accdropped } + \accperispomeni { \exp_stop_f: \LGR@accdropped } } \tl_const:Nn \c_@@_change_case_acc_lower_tl { } \tl_const:Nn \c_@@_change_case_misc_upper_tl @@ -4340,6 +4365,208 @@ % \end{macrocode} % \end{macro} % +% \begin{macro}[EXP]{\char_generate:nn} +% \begin{macro}[EXP, aux]{\@@_generate_aux:nn} +% \begin{macro}[EXP, aux]{\@@_generate_aux:nnw} +% \begin{variable}{\l_@@_tmp_tl} +% \begin{variable}{\c_@@_max_int} +% \begin{macro}[EXP, aux]{\@@_generate_invalid_catcode:} +% The aim here is to generate characters of (broadly) arbitrary category +% code. Where possible, that is done using engine support (\XeTeX{}, +% \LuaTeX{}). There are though various issues which are covered below. At +% the interface layer, turn the two arguments into integers up-front so +% this is only done once. +% \begin{macrocode} +\cs_new:Npn \char_generate:nn #1#2 + { + \exp:w \exp_after:wN \@@_generate_aux:w + \int_use:N \__int_eval:w #1 \exp_after:wN ; + \int_use:N \__int_eval:w #2 ; + } +% \end{macrocode} +% Before doing any actual conversion, first some special case filtering. +% The \tn{Ucharcat} primitive cannot make active chars, so that is turned +% off here: if the primitive gets altered then the code is already in +% place for 8-bit engines and will kick in for \LuaTeX{} too. Spaces +% are also banned here as \LuaTeX{} emulation only makes normal (charcode +% $32$ spaces. However, |^^@| is filtered out separately as that can't be +% done with macro emulation either, so is flagged up separately. That +% done, hand off to the engine-dependent part. +% \begin{macrocode} +\cs_new:Npn \@@_generate_aux:w #1 ; #2 ; + { + \if_int_compare:w #2 = \c_thirteen + \__msg_kernel_expandable_error:nn { kernel } { char-active } + \else: + \if_int_compare:w #2 = \c_ten + \if_int_compare:w #1 = \c_zero + \__msg_kernel_expandable_error:nn { kernel } { char-null-space } + \else: + \__msg_kernel_expandable_error:nn { kernel } { char-space } + \fi: + \else: + \if_int_odd:w 0 + \if_int_compare:w #2 < \c_one 1 \fi: + \if_int_compare:w #2 = \c_five 1 \fi: + \if_int_compare:w #2 = \c_nine 1 \fi: + \if_int_compare:w #2 > \c_thirteen 1 \fi: \exp_stop_f: + \__msg_kernel_expandable_error:nn { kernel } + { char-invalid-catcode } + \else: + \if_int_odd:w 0 + \if_int_compare:w #1 < \c_zero 1 \fi: + \if_int_compare:w #1 > \c_@@_max_int 1 \fi: \exp_stop_f: + \__msg_kernel_expandable_error:nn { kernel } + { char-out-of-range } + \else: + \@@_generate_aux:nnw {#1} {#2} + \fi: + \fi: + \fi: + \fi: + \exp_end: + } +\tl_new:N \l_@@_tmp_tl +% \end{macrocode} +% Engine-dependent definitions are now needed for the implementation. For +% \LuaTeX{} and recent \XeTeX{} releases there is engine-level support. +% They can do cases that macro emulation can't. All of those are filtered +% out here using a primitive-based boolean expression for speed. +% The final level is the basic definition at the engine level: the arguments +% here are integers so there is no need to worry about them too much. +% \begin{macrocode} +\group_begin: +%<*package> + \cs_set_nopar:Npn ^^L { } +%</package> + \char_set_catcode_other:n { 0 } + \if_int_odd:w 0 + \cs_if_exist:NT \luatex_directlua:D { 1 } + \cs_if_exist:NT \utex_charcat:D { 1 } \exp_stop_f: + \int_const:Nn \c_@@_max_int { 1114111 } + \cs_if_exist:NTF \luatex_directlua:D + { + \cs_new:Npn \@@_generate_aux:nnw #1#2#3 \exp_end: + { + #3 + \exp_after:wN \exp_end: + \luatex_directlua:D { l3kernel.charcat(#1, #2) } + } + } + { + \cs_new:Npn \@@_generate_aux:nnw #1#2#3 \exp_end: + { + #3 + \exp_after:wN \exp_end: + \utex_charcat:D #1 ~ #2 ~ + } + } + \else: +% \end{macrocode} +% For engines where \tn{Ucharcat} isn't available (or emulated) then we have +% to work in macros, and cover only the $8$-bit range. The first stage is +% to build up a |tl| containing |^^@| with each category code that can +% be accessed in this way, with an error set up for the other cases. This +% is all done such that it can be quickly accessed using a |\if_case:w| +% low-level conditional. There are a few things to notice here. +% As |^^L| is |\outer| we need to locally set it to avoid a problem. +% To get open/close braces into the list, they are set up using |\if_false:| +% pairing here and will later be |x|-type expanded into the desired form. +% For making spaces, there needs to be an |o|-type expansion of a |\use:n| +% (or some other tokenization) to avoid dropping the space. We also +% set up active tokens although they are (currently) filtered out by the +% interface layer (\tn{Ucharcat} cannot make active tokens). +% \begin{macrocode} + \int_const:Nn \c_@@_max_int { 255 } + \tl_set:Nn \l_@@_tmp_tl { \exp_not:N \or: } + \char_set_catcode_group_begin:n { 0 } % { + \tl_put_right:Nn \l_@@_tmp_tl { ^^@ \if_false: } } + \char_set_catcode_group_end:n { 0 } + \tl_put_right:Nn \l_@@_tmp_tl { { \fi: \exp_not:N \or: ^^@ } % } + \tl_set:Nx \l_@@_tmp_tl { \l_@@_tmp_tl } + \char_set_catcode_math_toggle:n { 0 } + \tl_put_right:Nn \l_@@_tmp_tl { \or: ^^@ } + \char_set_catcode_alignment:n { 0 } + \tl_put_right:Nn \l_@@_tmp_tl { \or: ^^@ } + \tl_put_right:Nn \l_@@_tmp_tl { \or: } + \char_set_catcode_parameter:n { 0 } + \tl_put_right:Nn \l_@@_tmp_tl { \or: ^^@ } + \char_set_catcode_math_superscript:n { 0 } + \tl_put_right:Nn \l_@@_tmp_tl { \or: ^^@ } + \char_set_catcode_math_subscript:n { 0 } + \tl_put_right:Nn \l_@@_tmp_tl { \or: ^^@ } + \tl_put_right:Nn \l_@@_tmp_tl { \or: } + \char_set_catcode_space:n { 0 } + \tl_put_right:No \l_@@_tmp_tl { \use:n { \or: } ^^@ } + \char_set_catcode_letter:n { 0 } + \tl_put_right:Nn \l_@@_tmp_tl { \or: ^^@ } + \char_set_catcode_other:n { 0 } + \tl_put_right:Nn \l_@@_tmp_tl { \or: ^^@ } + \char_set_catcode_active:n { 0 } + \tl_put_right:Nn \l_@@_tmp_tl { \or: ^^@ } +% \end{macrocode} +% Convert the above temporary list into a series of constant token +% lists, one for each character code, using \tn{tex_lowercase:D} to +% convert |^^@| in each case. The \texttt{x}-type expansion deals with +% the |\if_false:| stuff introduced earlier. This is done in three parts +% as |^^L| is awkward. Notice that at this stage |^^@| is active. In +% format mode this is not needed. +% \begin{macrocode} + \cs_set_protected:Npn \@@_tmp:n #1 + { + \char_set_lccode:nn { 0 } {#1} + \char_set_lccode:nn { 32 } {#1} + \exp_args:Nx \tex_lowercase:D + { + \tl_const:cn { c_@@_ \__int_to_roman:w #1 _tl } + { \exp_not:o \l_@@_tmp_tl } + } + } +%<*package> + \int_step_function:nnnN { 0 } { 1 } { 11 } \@@_tmp:n + \group_begin: + \tl_replace_once:Nnn \l_@@_tmp_tl { ^^@ } { \ERROR } + \@@_tmp:n { 12 } + \group_end: + \int_step_function:nnnN { 13 } { 1 } { 255 } \@@_tmp:n +%</package> +%<*initex> + \int_step_function:nnnN { 0 } { 1 } { 255 } \@@_tmp:n +%</initex> + \cs_new:Npn \@@_generate_aux:nnw #1#2#3 \exp_end: + { + #3 + \exp_after:wN \exp_after:wN + \exp_after:wN \exp_end: + \exp_after:wN \exp_after:wN + \if_case:w #2 + \exp_last_unbraced:Nv \exp_stop_f: + { c_@@_ \__int_to_roman:w #1 _tl } + \fi: + } + \fi: +\group_end: +% \end{macrocode} +% Job done, set up a few messages. +% \begin{macrocode} +\__msg_kernel_new:nnn { kernel } { char-active } + { Cannot~generate~active~chars. } +\__msg_kernel_new:nnn { kernel } { char-invalid-catcode } + { Invalid~catcode~for~char~generation. } +\__msg_kernel_new:nnn { kernel } { char-null-space } + { Cannot~generate~null~char~as~a~space. } +\__msg_kernel_new:nnn { kernel } { char-out-of-range } + { Charcode~requested~out~of~engine~range. } +\__msg_kernel_new:nnn { kernel } { char-space } + { Cannot~generate~space~chars. } +% \end{macrocode} +% \end{macro} +% \end{variable} +% \end{variable} +% \end{macro} +% \end{macro} +% \end{macro} +% % \begin{macrocode} %<@@=peek> % \end{macrocode} diff --git a/Master/texmf-dist/source/latex/l3kernel/l3doc.dtx b/Master/texmf-dist/source/latex/l3kernel/l3doc.dtx index 8c02dcb39fc..502eb1a1e4a 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3doc.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3doc.dtx @@ -75,7 +75,7 @@ Do not distribute a modified version of this file. % %<*driver|class> \RequirePackage{expl3,xparse,calc} -\GetIdInfo$Id: l3doc.dtx 5903 2015-09-02 06:03:07Z joseph $ +\GetIdInfo$Id: l3doc.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Experimental documentation class} %</driver|class> % @@ -1255,7 +1255,8 @@ Do not distribute a modified version of this file. } % \end{macrocode} % -% \begin{macro}{\eTeX, \IniTeX, \Lua, \LuaTeX, \pdfTeX, \XeTeX} +% \begin{macro}{\eTeX, \IniTeX, \Lua, \LuaTeX, \pdfTeX, \XeTeX, +% \pTeX, \upTeX, \epTeX, \eupTeX} % Some commands for logos. % \begin{macrocode} \providecommand*\eTeX{\hologo{eTeX}} @@ -1264,6 +1265,10 @@ Do not distribute a modified version of this file. \providecommand*\LuaTeX{\hologo{LuaTeX}} \providecommand*\pdfTeX{\hologo{pdfTeX}} \providecommand*\XeTeX{\hologo{XeTeX}} +\providecommand*\pTeX{p\kern-.2em\hologo{TeX}} +\providecommand*\upTeX{up\kern-.2em\hologo{TeX}} +\providecommand*\epTeX{$\varepsilon$-\pTeX} +\providecommand*\eupTeX{$\varepsilon$-\upTeX} % \end{macrocode} % \end{macro} % diff --git a/Master/texmf-dist/source/latex/l3kernel/l3expan.dtx b/Master/texmf-dist/source/latex/l3kernel/l3expan.dtx index 65105c61736..c96720f149b 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3expan.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3expan.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3expan.dtx 5897 2015-08-28 09:06:29Z joseph $ +\GetIdInfo$Id: l3expan.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Argument expansion} %</driver|package> %<*driver> @@ -240,7 +240,7 @@ % \begin{verbatim} % \tl_set:No \l_tmpa_tl { { \l_tmpa_tl } } % \end{verbatim} -% and +% and % \begin{verbatim} % \tl_set:Nf \l_tmpa_tl { { \l_tmpa_tl } } % \end{verbatim} @@ -650,7 +650,7 @@ % \begin{function}[added=2015-08-23,EXP] % { % \exp:w , -% \exp_end: +% \exp_end: % } % \begin{syntax} % \cs{exp:w} \meta{expandable-tokens} \cs{exp_end:} \\ @@ -680,7 +680,7 @@ % \begin{function}[added=2015-08-23,EXP] % { % \exp:w , -% \exp_end_continue_f:w +% \exp_end_continue_f:w % } % \begin{syntax} % \cs{exp:w} \meta{expandable-tokens} \cs{exp_end_continue_f:w} \meta{further-tokens} @@ -700,7 +700,7 @@ % % % In typical use cases \meta{expandable-tokens} contains no tokens at all, -% e.g., you will see code such as +% e.g., you will see code such as %\begin{verbatim} % \exp_after:wN { \exp:w \exp_end_continue_f:w #2 } %\end{verbatim} @@ -732,7 +732,7 @@ % \begin{function}[added=2015-08-23,EXP] % { % \exp:w , -% \exp_end_continue_f:nw +% \exp_end_continue_f:nw % } % \begin{syntax} % \cs{exp:w} \meta{expandable-tokens} \cs{exp_end_continue_f:nw} \meta{further-tokens} @@ -886,12 +886,12 @@ % \begin{macro}[int, EXP]{\::f} % \begin{macro}{\exp_stop_f:} % This function is used to expand a token list until the first -% unexpandable token is found. This is achieved through \cs{exp:w} +% unexpandable token is found. This is achieved through \cs{exp:w} % \cs{exp_end_continue_f:w} that % expands everything in its way following it. This % scanning procedure is terminated once the expansion hits % something non-expandable or a space. We introduce \cs{exp_stop_f:} -% to mark such an end of expansion marker. +% to mark such an end of expansion marker. % In the example shown earlier the scanning was stopped % once \TeX{} had fully expanded |\cs_set_eq:Nc \aaa { b \l_tmpa_tl b }| % into |\cs_set_eq:NN \aaa = \blurb| which then turned out to contain @@ -1460,7 +1460,7 @@ % \begin{macrocode} \cs_new:Npn ^^@{\expansionERROR} % \end{macrocode} -% +% % \begin{macrocode} \cs_new:Npn \exp_end_continue_f:nw #1 { `^^@ #1 } \tex_catcode:D `\^^@=15 diff --git a/Master/texmf-dist/source/latex/l3kernel/l3format.ins b/Master/texmf-dist/source/latex/l3kernel/l3format.ins index 92825d5b08a..3d967cc7e7d 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3format.ins +++ b/Master/texmf-dist/source/latex/l3kernel/l3format.ins @@ -76,6 +76,7 @@ Do not distribute a modified version of this file. \from{l3coffins.dtx} {initex} \from{l3color.dtx} {initex} \from{l3candidates.dtx} {initex} + \from{l3sys.dtx} {initex} \from{l3luatex.dtx} {initex} % ======== FORMAT ONLY ========= \from{l3final.dtx} {initex} @@ -89,4 +90,4 @@ Do not distribute a modified version of this file. \generate{\file{l3docstrip.tex}{\from{l3docstrip.dtx}{program}}} -\endbatchfile
\ No newline at end of file +\endbatchfile diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-convert.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-convert.dtx index 12af7c088a3..dd30a2f4ff0 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3fp-convert.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-convert.dtx @@ -36,7 +36,7 @@ % %<*driver> \documentclass[full]{l3doc} -\GetIdInfo$Id: l3fp-convert.dtx 5893 2015-08-26 16:16:52Z mittelba $ +\GetIdInfo$Id: l3fp-convert.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Floating-point conversion} \begin{document} \DocInput{\jobname.dtx} @@ -527,7 +527,7 @@ { \exp_not:N \exp_after:wN , \exp_not:N \exp_after:wN \c_space_tl - \exp_not:N \exp:w + \exp_not:N \exp:w \exp_not:N \exp_end_continue_f:w \exp_not:N \@@_to_tl_dispatch:w #1 #2 ; } diff --git a/Master/texmf-dist/source/latex/l3kernel/l3int.dtx b/Master/texmf-dist/source/latex/l3kernel/l3int.dtx index ad438e06a72..cbed3f682f9 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3int.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3int.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3int.dtx 5885 2015-08-24 13:29:14Z mittelba $ +\GetIdInfo$Id: l3int.dtx 5987 2015-09-11 05:44:48Z joseph $ {L3 Integers} %</driver|package> %<*driver> @@ -1167,7 +1167,8 @@ % \UnitTested % As stated, most constants can be defined as \tn{chardef} or % \tn{mathchardef} but that's engine dependent. As a result, there is some -% set up code to determine what can be done. +% set up code to determine what can be done. No full engine testing just yet +% so everything is a little awkward. % \begin{macrocode} \cs_new_protected:Npn \int_const:Nn #1#2 { @@ -1190,15 +1191,20 @@ } } \cs_generate_variant:Nn \int_const:Nn { c } -\pdftex_if_engine:TF - { - \cs_new_eq:NN \@@_constdef:Nw \tex_mathchardef:D - \tex_mathchardef:D \c__max_constdef_int 32 767 ~ - } - { - \cs_new_eq:NN \@@_constdef:Nw \tex_chardef:D - \tex_chardef:D \c__max_constdef_int 1 114 111 ~ - } +\if_int_odd:w 0 + \cs_if_exist:NT \luatex_luatexversion:D { 1 } + \cs_if_exist:NT \uptex_disablecjktoken:D + { \if_int_compare:w \ptex_jis:D "2121 = "3000 ~ 1 \fi: } + \cs_if_exist:NT \xetex_XeTeXversion:D { 1 } + ~ + \cs_if_exist:NTF \uptex_disablecjktoken:D + { \cs_new_eq:NN \@@_constdef:Nw \uptex_kchardef:D } + { \cs_new_eq:NN \@@_constdef:Nw \tex_chardef:D } + \@@_constdef:Nw \c__max_constdef_int 1114111 ~ +\else: + \cs_new_eq:NN \@@_constdef:Nw \tex_mathchardef:D + \tex_mathchardef:D \c__max_constdef_int 32767 ~ +\fi: % \end{macrocode} % \end{variable} % \end{macro} diff --git a/Master/texmf-dist/source/latex/l3kernel/l3keys.dtx b/Master/texmf-dist/source/latex/l3kernel/l3keys.dtx index d29b7134957..6f781667d1e 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3keys.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3keys.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3keys.dtx 5869 2015-08-20 01:19:17Z bruno $ +\GetIdInfo$Id: l3keys.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Key-value interfaces} %</driver|package> %<*driver> @@ -171,7 +171,7 @@ % discussion, each property is illustrated attached to an % arbitrary \meta{key}, which when used may be supplied with a % \meta{value}. All key \emph{definitions} are local. -% +% % Key properties are applied in the reading order and so the ordering % is significant. Key properties which define \enquote{actions}, such % as |.code:n|, |.tl_set:N|, \emph{etc.}, will override one another. @@ -940,7 +940,7 @@ % any braces, another \cs{q_nil} needed before the next phase of the % parser. Finally, loop around for the next item, adding in the % \cs{q_nil}: this happens whatever the nature of the current argument -% as the end-of-recursion will clear up in all cases. +% as the end-of-recursion will clear up in all cases. % \begin{macrocode} \cs_new_protected:Npn \@@_parse_elt:w #1 , { @@ -1444,10 +1444,10 @@ % Auto-generating choices means setting up the root key as a choice, then % defining each choice in turn. % \begin{macrocode} -\cs_new_protected_nopar:Npn \@@_choices_make:nn +\cs_new_protected_nopar:Npn \@@_choices_make:nn { \@@_choices_make:Nnn \@@_choice_make: } -\cs_new_protected_nopar:Npn \@@_multichoices_make:nn - { \@@_choices_make:Nnn \@@_multichoice_make: } +\cs_new_protected_nopar:Npn \@@_multichoices_make:nn + { \@@_choices_make:Nnn \@@_multichoice_make: } \cs_new_protected:Npn \@@_choices_make:Nnn #1#2#3 { #1 diff --git a/Master/texmf-dist/source/latex/l3kernel/l3luatex.dtx b/Master/texmf-dist/source/latex/l3kernel/l3luatex.dtx index 32950238227..20c8535cf38 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3luatex.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3luatex.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3luatex.dtx 5646 2015-06-30 21:19:24Z joseph $ +\GetIdInfo$Id: l3luatex.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Experimental LuaTeX-specific functions} %</driver|package> %<*driver> @@ -74,7 +74,7 @@ % and with it access to the \enquote{internals} of \TeX{}. In order to use % this within the framework provided here, a family of functions is % available. When used with \pdfTeX{} or \XeTeX{} these will raise an -% error: use \cs{luatex_if_engine:T} to avoid this. Details of coding +% error: use \cs{sys_if_engine_luatex:T} to avoid this. Details of coding % the \LuaTeX{} engine are detailed in the \LuaTeX{} manual. % % \begin{function}[EXP, added = 2015-06-29]{\lua_now_x:n, \lua_now:n} @@ -88,7 +88,7 @@ % Each \cs{lua_now:n} block is treated by \Lua{} as a separate chunk. % The \Lua{} interpreter will execute the \meta{\Lua{} input} immediately, % and in an expandable manner. -% +% % In the case of the \cs{lua_now_x:n} version the input is fully expanded % by \TeX{} in an \texttt{x}-type manner \emph{but} the function remains % fully expandable. @@ -112,7 +112,7 @@ % The \Lua{} interpreter will execute the \meta{\Lua{} input} during the % page-building routine: no \TeX{} expansion of the \meta{\Lua{} input} % will occur at this stage. -% +% % In the case of the \cs{lua_shipout_x:n} version the input is fully % expanded by \TeX{} in an \texttt{x}-type manner during the shipout % operation. @@ -130,7 +130,7 @@ % \Lua{}: embedded backslashes, double and single quotes, and newlines % and carriage returns are escaped. This is done by prepending an extra % token consisting of a backslash with category code~$12$, and for the line -% endings, converting them to |\n| and |\r|, respectively. +% endings, converting them to |\n| and |\r|, respectively. % % In the case of the \cs{lua_escape_x:n} version the input is fully expanded % by \TeX{} in an \texttt{x}-type manner \emph{but} the function remains @@ -168,7 +168,7 @@ { \lua_shipout_x:n { \exp_not:n {#1} } } \cs_new:Npn \lua_escape_x:n #1 { \luatex_luaescapestring:D {#1} } \cs_new:Npn \lua_escape:n #1 { \lua_escape_x:n { \exp_not:n {#1} } } -\luatex_if_engine:F +\sys_if_engine_luatex:F { \clist_map_inline:nn { \lua_now_x:n , \lua_now:n , \lua_escape_x:n , \lua_escape:n } diff --git a/Master/texmf-dist/source/latex/l3kernel/l3msg.dtx b/Master/texmf-dist/source/latex/l3kernel/l3msg.dtx index 601d5cf0564..c2591f5a964 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3msg.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3msg.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3msg.dtx 5891 2015-08-25 08:00:59Z mittelba $ +\GetIdInfo$Id: l3msg.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Messages} %</driver|package> %<*driver> @@ -788,7 +788,7 @@ % the \cs{__msg_show_item:nn} and \cs{__msg_show_item_unbraced:nn} versions % for key--value like data structures. % \end{function} -% +% % \begin{variable}{\c__msg_coding_error_text_tl} % The text % \begin{verbatim} diff --git a/Master/texmf-dist/source/latex/l3kernel/l3names.dtx b/Master/texmf-dist/source/latex/l3kernel/l3names.dtx index 71c9f1513ff..d9335665249 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3names.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3names.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3names.dtx 5848 2015-08-17 05:27:13Z joseph $ +\GetIdInfo$Id: l3names.dtx 5939 2015-09-07 21:15:55Z joseph $ {L3 Namespace for primitives} %</driver|package> %<*driver> @@ -1138,6 +1138,15 @@ \tex_let:D \utex_mathcodenum:D \XeTeXmathcodenum \tex_fi:D % \end{macrocode} +% Up to v0.80, \LuaTeX{} defines the \pdfTeX{} version data: rather +% confusing. +% \begin{macrocode} +\etex_ifdefined:D \luatex_luatexversion:D + \tex_let:D \pdftex_pdftexbanner:D \tex_undefined:D + \tex_let:D \pdftex_pdftexbanner:D \tex_undefined:D + \tex_let:D \pdftex_pdftexversion:D \tex_undefined:D +\tex_fi:D +% \end{macrocode} % % For Con\TeX{}t, two tests are needed. Both Mark~II and Mark~IV move several % primitives: these are all covered by the first test, again using \cs{end} diff --git a/Master/texmf-dist/source/latex/l3kernel/l3oldmodules.dtx b/Master/texmf-dist/source/latex/l3kernel/l3oldmodules.dtx index 4d884f8381d..98272b0f9e7 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3oldmodules.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3oldmodules.dtx @@ -122,7 +122,7 @@ %<l3tl>{l3tl} %<l3token>{l3token} % \end{macrocode} -% +% % Then identify the current package: % \begin{macrocode} \ProvidesPackage\old@liii@module@name diff --git a/Master/texmf-dist/source/latex/l3kernel/l3prg.dtx b/Master/texmf-dist/source/latex/l3kernel/l3prg.dtx index d87e58b27af..9acff26f534 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3prg.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3prg.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3prg.dtx 5891 2015-08-25 08:00:59Z mittelba $ +\GetIdInfo$Id: l3prg.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Control structures} %</driver|package> %<*driver> @@ -238,7 +238,7 @@ % All conditional |\bool_| functions except assignments are expandable % and expect the input to also be fully expandable (which will generally % mean being constructed from predicate functions, possibly nested). -% +% % \begin{texnote} % The \texttt{bool} data type is not implemented using the % \tn{iffalse}/\tn{iftrue} primitives, in contrast to \tn{newif}, @@ -1569,7 +1569,7 @@ % \end{macro} % % \subsection{Deprecated functions} -% +% % \begin{macro}[int]{\scan_align_safe_stop:} % Deprecated 2015-08-01 for removal after 2016-12-31. % \begin{macrocode} diff --git a/Master/texmf-dist/source/latex/l3kernel/l3skip.dtx b/Master/texmf-dist/source/latex/l3kernel/l3skip.dtx index e329b9bd45e..4dd4749c814 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3skip.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3skip.dtx @@ -38,7 +38,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3skip.dtx 5893 2015-08-26 16:16:52Z mittelba $ +\GetIdInfo$Id: l3skip.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Dimensions and skips} %</driver|package> %<*driver> @@ -499,7 +499,7 @@ % \end{verbatim} % leaves |0.35277| in the input stream, \emph{i.e.}~the magnitude of % one big point when converted to millimetres. -% +% % Note that this function is not optimised for any particular output % and as such may give different results to \cs{dim_to_decimal_in_bp:n} % or \cs{dim_to_decimal_in_sp:n}. In particular, the latter is able to @@ -1451,7 +1451,7 @@ { \dim_to_decimal:n { ( #1 ) * 800 / 803 } } % \end{macrocode} % \end{macro} -% +% % \begin{macro}[EXP]{\dim_to_decimal_in_sp:n} % Another hard-coded conversion: this one is necessary to avoid things going % off-scale. diff --git a/Master/texmf-dist/source/latex/l3kernel/l3str.dtx b/Master/texmf-dist/source/latex/l3kernel/l3str.dtx index e0787af4833..63129bb4fcb 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3str.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3str.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3str.dtx 5920 2015-09-05 07:55:06Z joseph $ +\GetIdInfo$Id: l3str.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Strings} %</driver|package> %<*driver> @@ -193,7 +193,7 @@ % % \begin{function}[rEXP, added = 2015-03-01] % { -% \str_lower_case:n, \str_lower_case:f, +% \str_lower_case:n, \str_lower_case:f, % \str_upper_case:n, \str_upper_case:f % } % \begin{syntax} @@ -204,7 +204,7 @@ % described for \cs{tl_to_str:n}, and then to the lower or upper % case representation using a one-to-one mapping as described by the % Unicode Consortium file |UnicodeData.txt|. -% +% % These functions are intended for case changing programmatic data in % places where upper/lower case distinctions are meaningful. One example % would be automatically generating a function name from user input where @@ -226,7 +226,7 @@ % would be used to generate a function with an auto-generated name consisting % of the upper case equivalent of the supplied name followed by the lower % case equivalent of the rest of the input. -% +% % These functions should \emph{not} be used for % \begin{itemize} % \item Caseless comparisons: use \cs{str_fold_case:n} for this @@ -393,7 +393,7 @@ % such tokens. % \begin{macrocode} \cs_new:Npn \__str_if_eq_x:nn #1#2 { \pdftex_strcmp:D {#1} {#2} } -\luatex_if_engine:T +\cs_if_exist:NT \luatex_luatexversion:D { \cs_set:Npn \__str_if_eq_x:nn #1#2 { @@ -579,7 +579,7 @@ \cs_generate_variant:Nn \str_upper_case:n { f } \cs_new:Npn \__str_change_case:nn #1 { - \exp_after:wN \__str_change_case_aux:nn \exp_after:wN + \exp_after:wN \__str_change_case_aux:nn \exp_after:wN { \tl_to_str:n {#1} } } \cs_new:Npn \__str_change_case_aux:nn #1#2 diff --git a/Master/texmf-dist/source/latex/l3kernel/l3sys.dtx b/Master/texmf-dist/source/latex/l3kernel/l3sys.dtx new file mode 100755 index 00000000000..baf4bfc8756 --- /dev/null +++ b/Master/texmf-dist/source/latex/l3kernel/l3sys.dtx @@ -0,0 +1,203 @@ +% \iffalse meta-comment +% +%% File: l3sys.dtx Copyright (C) 2015 The LaTeX3 Project +%% +%% It may be distributed and/or modified under the conditions of the +%% LaTeX Project Public License (LPPL), either version 1.3c of this +%% license or (at your option) any later version. The latest version +%% of this license is in the file +%% +%% http://www.latex-project.org/lppl.txt +%% +%% This file is part of the "l3kernel bundle" (The Work in LPPL) +%% and all files in that bundle must be distributed together. +%% +%% The released version of this bundle is available from CTAN. +%% +%% ----------------------------------------------------------------------- +%% +%% The development version of the bundle can be found at +%% +%% http://www.latex-project.org/svnroot/experimental/trunk/ +%% +%% for those people who are interested. +%% +%%%%%%%%%%% +%% NOTE: %% +%%%%%%%%%%% +%% +%% Snapshots taken from the repository represent work in progress and may +%% not work or may contain conflicting material! We therefore ask +%% people _not_ to put them into distributions, archives, etc. without +%% prior consultation with the LaTeX3 Project. +%% +%% ----------------------------------------------------------------------- +% +%<*driver> +\documentclass[full]{l3doc} +%</driver> +%<*driver|package> +\GetIdInfo$Id$ + {L3 Experimental system/runtime functions} +%</driver|package> +%<*driver> +\begin{document} + \DocInput{\jobname.dtx} +\end{document} +%</driver> +% \fi +% +% \title{^^A +% The \pkg{l3sys} package\\System/runtime functions^^A +% \thanks{This file describes v\ExplFileVersion, +% last revised \ExplFileDate.}^^A +% } +% +% \author{^^A +% The \LaTeX3 Project\thanks +% {^^A +% E-mail: +% \href{mailto:latex-team@latex-project.org} +% {latex-team@latex-project.org}^^A +% }^^A +% } +% +% \date{Released \ExplFileDate} +% +% \maketitle +% +% \begin{documentation} +% +% \subsection{Engine-specific conditionals} +% +% \begin{function}[added = 2015-09-07, EXP, pTF]^^A +% {^^A +% \sys_if_engine_luatex:, +% \sys_if_engine_pdftex:, +% \sys_if_engine_ptex: , +% \sys_if_engine_uptex: , +% \sys_if_engine_xetex: +% } +% \begin{syntax} +% \cs{sys_if_engine_pdftex:TF} \Arg{true code} \Arg{false code} +% \end{syntax} +% Conditionals which allow engine-specific code to be used. The names +% follow naturally from those of the engine binaries: note that the +% |(u)ptex| tests are for \epTeX{} and \eupTeX{} as \pkg{expl3} requires +% the \eTeX{} extensions. Each conditional is true for +% \emph{exactly one} supported engine. In particular, +% |\sys_if_engine_ptex_p:| is true for \epTeX{} but false for \eupTeX{}. +% \end{function} +% +% \end{documentation} +% +% \begin{implementation} +% +% \section{\pkg{l3sys} implementation} +% +% \begin{macrocode} +%<*initex|package> +% \end{macrocode} +% +% \subsubsection{Detecting the engine} +% +% \begin{macro}[pTF, EXP]^^A +% {^^A +% \sys_if_engine_luatex:, +% \sys_if_engine_pdftex:, +% \sys_if_engine_ptex:, +% \sys_if_engine_uptex:, +% \sys_if_engine_xetex: +% } +% Set up the engine tests on the basis exactly one test should be true. +% Mainly a case of looking for the appropriate marker primitive. For +% \upTeX{}, there is a complexity in that setting |-kanji-internal=sjis| +% or |-kanji-internal=euc| effective makes it more like \pTeX{}. In those +% cases we therefore report \pTeX{} rather than \upTeX{}. +% \begin{macrocode} +\clist_map_inline:nn { lua , pdf , p , up , xe } + { + \cs_new_eq:cN { sys_if_engine_ #1 tex:T } \use_none:n + \cs_new_eq:cN { sys_if_engine_ #1 tex:F } \use:n + \cs_new_eq:cN { sys_if_engine_ #1 tex:TF } \use_ii:nn + \cs_new_eq:cN { sys_if_engine_ #1 tex_p: } \c_false_bool + } +\cs_if_exist:NT \luatex_luatexversion:D + { + \cs_gset_eq:NN \sys_if_engine_luatex:T \use:n + \cs_gset_eq:NN \sys_if_engine_luatex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_luatex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_luatex_p: \c_true_bool + } +\cs_if_exist:NT \pdftex_pdftexversion:D + { + \cs_gset_eq:NN \sys_if_engine_pdftex:T \use:n + \cs_gset_eq:NN \sys_if_engine_pdftex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_pdftex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_pdftex_p: \c_true_bool + } +\cs_if_exist:NT \ptex_kanjiskip:D + { + \bool_if:nTF + { + \cs_if_exist_p:N \uptex_disablecjktoken:D && + \int_compare_p:nNn { \ptex_jis:D "2121 } = { "3000 } + } + { + \cs_gset_eq:NN \sys_if_engine_uptex:T \use:n + \cs_gset_eq:NN \sys_if_engine_uptex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_uptex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_uptex_p: \c_true_bool + } + { + \cs_gset_eq:NN \sys_if_engine_ptex:T \use:n + \cs_gset_eq:NN \sys_if_engine_ptex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_ptex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_ptex_p: \c_true_bool + } + } +\cs_if_exist:NT \xetex_XeTeXversion:D + { + \cs_gset_eq:NN \sys_if_engine_xetex:T \use:n + \cs_gset_eq:NN \sys_if_engine_xetex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_xetex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_xetex_p: \c_true_bool + } +% \end{macrocode} +% \end{macro} +% +% \subsection{Deprecated functions} +% +% Deprecated 2015-09-07 for removal after 2016-12-31. The older logic supported +% only three engines so that has to be allowed for. +% \begin{macrocode} +\prg_new_eq_conditional:NNn \luatex_if_engine: \sys_if_engine_luatex: + { T , F , TF , p } +\prg_new_eq_conditional:NNn \xetex_if_engine: \sys_if_engine_xetex: + { T , F , TF , p } +\bool_if:nTF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } + { + \cs_new_eq:NN \pdftex_if_engine:T \use_none:n + \cs_new_eq:NN \pdftex_if_engine:F \use:n + \cs_new_eq:NN \pdftex_if_engine:TF \use_ii:nn + \cs_new_eq:NN \pdftex_if_engine_p: \c_false_bool + } + { + \cs_new_eq:NN \pdftex_if_engine:T \use:n + \cs_new_eq:NN \pdftex_if_engine:F \use_none:n + \cs_new_eq:NN \pdftex_if_engine:TF \use_i:nn + \cs_new_eq:NN \pdftex_if_engine_p: \c_true_bool + } +% \end{macrocode} +% +% \begin{macrocode} +%</initex|package> +% \end{macrocode} +% +%\end{implementation} +% +%\PrintIndex diff --git a/Master/texmf-dist/source/latex/l3kernel/l3tl.dtx b/Master/texmf-dist/source/latex/l3kernel/l3tl.dtx index 59d0b161e94..77673fbd8ef 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3tl.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3tl.dtx @@ -37,7 +37,7 @@ \documentclass[full]{l3doc} %</driver> %<*driver|package> -\GetIdInfo$Id: l3tl.dtx 5908 2015-09-02 14:50:27Z joseph $ +\GetIdInfo$Id: l3tl.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Token lists} %</driver|package> %<*driver> @@ -326,7 +326,7 @@ % These functions allow the rescanning of tokens: re-apply \TeX{}'s % tokenization process to apply category codes different from those % in force when the tokens were absorbed. Whilst this functionality is -% supported, it is often preferable to find alternative approaches +% supported, it is often preferable to find alternative approaches % to achieving outcomes rather than rescanning tokens (for example % construction of token lists token-by-token with intervening category % code changes). @@ -1526,16 +1526,25 @@ { \@@_set_rescan:NNnn \prg_do_nothing: \use:n } \cs_new_protected:Npn \@@_set_rescan:NNnn #1#2#3#4 { - \group_begin: - \exp_args:No \etex_everyeof:D { \c_@@_rescan_marker_tl \exp_not:N } - \int_compare:nNnT \tex_endlinechar:D = { 32 } - { \tex_endlinechar:D \c_minus_one } - \tex_newlinechar:D \tex_endlinechar:D - #3 \scan_stop: - \exp_args:No \@@_set_rescan:n { \tl_to_str:n {#4} } - \exp_args:NNNo - \group_end: - #1 #2 \l_@@_internal_a_tl + \tl_if_empty:nTF {#4} + { + \group_begin: + #3 + \group_end: + #1 #2 { } + } + { + \group_begin: + \exp_args:No \etex_everyeof:D { \c_@@_rescan_marker_tl \exp_not:N } + \int_compare:nNnT \tex_endlinechar:D = { 32 } + { \tex_endlinechar:D \c_minus_one } + \tex_newlinechar:D \tex_endlinechar:D + #3 \scan_stop: + \exp_args:No \@@_set_rescan:n { \tl_to_str:n {#4} } + \exp_args:NNNo + \group_end: + #1 #2 \l_@@_internal_a_tl + } } \cs_new_protected:Npn \@@_set_rescan_multi:n #1 { diff --git a/Master/texmf-dist/source/latex/l3kernel/l3unicode-data.dtx b/Master/texmf-dist/source/latex/l3kernel/l3unicode-data.dtx index 79fbc2783e6..657e868ae21 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3unicode-data.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3unicode-data.dtx @@ -38,7 +38,7 @@ % plain \TeX{}, set up in generic mode. %<*driver|script> \input expl3-generic\relax -\GetIdInfo$Id: l3unicode-data.dtx 5897 2015-08-28 09:06:29Z joseph $ +\GetIdInfo$Id: l3unicode-data.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Case data script} %</driver|script> % @@ -137,7 +137,7 @@ % \end{macrocode} % % \subsection{Setup} -% +% % \begin{variable}{\l__unicode_tmp_tl} % Scratch space. % \begin{macrocode} @@ -281,7 +281,7 @@ \use:x { \cs_new_protected:Npn - \exp_not:N \__unicode_parse_line:w ##1 - ##2 \tl_to_str:n { .txt } + \exp_not:N \__unicode_parse_line:w ##1 - ##2 \tl_to_str:n { .txt } } #3 \scan_stop: #4 { @@ -340,7 +340,7 @@ %% \__unicode_verb_end: % \end{macrocode} -% +% % \begin{macro}[EXP]{\__unicode_zero_fill:N} % A short piece of reusable code for the header. % \begin{macrocode} @@ -380,8 +380,8 @@ { l3unicode-data.def } ~ { \int_use:N \tex_year:D / - \__unicode_zero_fill:N \tex_month:D / - \__unicode_zero_fill:N \tex_day:D + \__unicode_zero_fill:N \tex_month:D / + \__unicode_zero_fill:N \tex_day:D } ~ { -1 } ~ { L3~Unicode~data } @@ -407,7 +407,11 @@ % range), no-op data is included (as the \emph{output} would be out-of-range). % \begin{macrocode} \__unicode_verb: -\pdftex_if_engine:T +\bool_if:nF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } { \group_begin: \cs_set_protected:Npn \__unicode_tmp:NN #1#2 @@ -687,7 +691,7 @@ % \end{macrocode} % % Saving the data uses a single file, with the two arrays followed by the -% exceptions. +% exceptions. % \begin{macrocode} \tl_map_inline:nn { 0123456789 } { @@ -715,7 +719,7 @@ } } \clist_map_inline:nn - { upper , lower , title } + { upper , lower , title } { \iow_now:Nx \g__unicode_result_iow { @@ -724,7 +728,7 @@ { c__unicode_ \str_if_eq:nnTF {#1} { title } { mixed } {#1} - _exceptions_tl + _exceptions_tl } { \exp_not:v { l__unicode_ #1 _ exceptions_tl } } } @@ -917,4 +921,4 @@ % % \end{implementation} % -% \PrintIndex
\ No newline at end of file +% \PrintIndex diff --git a/Master/texmf-dist/source/latex/l3packages/l3keys2e/l3keys2e.dtx b/Master/texmf-dist/source/latex/l3packages/l3keys2e/l3keys2e.dtx index 8cea3b578f7..b1c5171456a 100644 --- a/Master/texmf-dist/source/latex/l3packages/l3keys2e/l3keys2e.dtx +++ b/Master/texmf-dist/source/latex/l3packages/l3keys2e/l3keys2e.dtx @@ -37,8 +37,8 @@ %<*driver|package> % The version of expl3 required is tested as early as possible, as % some really old versions do not define \ProvidesExplPackage. -\RequirePackage{expl3}[2015/09/06] -%<package>\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +%<package>\@ifpackagelater{expl3}{2015/09/11} %<package> {} %<package> {% %<package> \PackageError{l3keys2e}{Support package l3kernel too old} @@ -50,7 +50,7 @@ %<package> }% %<package> \endinput %<package> } -\GetIdInfo$Id: l3keys2e.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3keys2e.dtx 6001 2015-09-11 21:50:23Z joseph $ {LaTeX2e option processing using LaTeX3 keys} %</driver|package> %<*driver> diff --git a/Master/texmf-dist/source/latex/l3packages/xparse/xparse.dtx b/Master/texmf-dist/source/latex/l3packages/xparse/xparse.dtx index 55d8aec5d41..d204fd20a94 100644 --- a/Master/texmf-dist/source/latex/l3packages/xparse/xparse.dtx +++ b/Master/texmf-dist/source/latex/l3packages/xparse/xparse.dtx @@ -41,8 +41,8 @@ %<*driver|package> % The version of expl3 required is tested as early as possible, as % some really old versions do not define \ProvidesExplPackage. -\RequirePackage{expl3}[2015/09/06] -%<package>\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +%<package>\@ifpackagelater{expl3}{2015/09/11} %<package> {} %<package> {% %<package> \PackageError{xparse}{Support package l3kernel too old} @@ -54,7 +54,7 @@ %<package> }% %<package> \endinput %<package> } -\GetIdInfo$Id: xparse.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: xparse.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental document command parser} %</driver|package> %<*driver> diff --git a/Master/texmf-dist/source/latex/l3packages/xtemplate/xtemplate.dtx b/Master/texmf-dist/source/latex/l3packages/xtemplate/xtemplate.dtx index 9651fe12771..40bc1122621 100644 --- a/Master/texmf-dist/source/latex/l3packages/xtemplate/xtemplate.dtx +++ b/Master/texmf-dist/source/latex/l3packages/xtemplate/xtemplate.dtx @@ -41,8 +41,8 @@ %<*driver|package> % The version of expl3 required is tested as early as possible, as % some really old versions do not define \ProvidesExplPackage. -\RequirePackage{expl3}[2015/09/06] -%<package>\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +%<package>\@ifpackagelater{expl3}{2015/09/11} %<package> {} %<package> {% %<package> \PackageError{xtemplate}{Support package l3kernel too old} @@ -54,7 +54,7 @@ %<package> }% %<package> \endinput %<package> } -\GetIdInfo$Id: xtemplate.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: xtemplate.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental prototype document functions} %</driver|package> %<*driver> @@ -1281,41 +1281,46 @@ % that, the standard delimited argument method is used to separate the % two parts. % \begin{macrocode} -\group_begin: -\char_set_lccode:nn { `\@ } { `\: } -\char_set_catcode_other:N \@ -\tl_to_lowercase:n +\cs_new_protected:Npx \@@_split_keytype:n #1 { - \group_end: - \cs_new_protected:Npn \@@_split_keytype:n #1 + \exp_not:N \bool_set_false:N \exp_not:N \l_@@_error_bool + \tl_set:Nn \exp_not:N \l_@@_tmp_tl {#1} + \tl_remove_all:Nn \exp_not:N \l_@@_tmp_tl { ~ } + \tl_replace_all:Nnn \exp_not:N \l_@@_tmp_tl { : } { \token_to_str:N : } + \tl_if_in:onTF \exp_not:N \l_@@_tmp_tl { \token_to_str:N : } { - \bool_set_false:N \l_@@_error_bool - \tl_set:Nn \l_@@_tmp_tl {#1} - \tl_remove_all:Nn \l_@@_tmp_tl { ~ } - \tl_replace_all:Nnn \l_@@_tmp_tl { : } { @ } - \tl_if_in:onTF \l_@@_tmp_tl { @ } + \exp_not:n { \tl_clear:N \l_@@_key_name_tl \exp_after:wN \@@_split_keytype_aux:w \l_@@_tmp_tl \q_stop } - { - \bool_set_true:N \l_@@_error_bool - \msg_error:nnx { xtemplate } { missing-keytype } {#1} - } } - \cs_new_protected:Npn \@@_split_keytype_aux:w #1 @ #2 \q_stop { - \tl_put_right:Nx \l_@@_key_name_tl { \tl_to_str:n {#1} } - \tl_if_in:nnTF {#2} { @ } + \exp_not:N \bool_set_true:N \exp_not:N \l_@@_error_bool + \msg_error:nnx { xtemplate } { missing-keytype } {#1} + } + } +\use:x + { + \cs_new_protected:Npn \exp_not:N \@@_split_keytype_aux:w + ##1 \token_to_str:N : ##2 \exp_not:N \q_stop + { + \tl_put_right:Nx \exp_not:N \l_@@_key_name_tl + { \exp_not:N \tl_to_str:n {##1} } + \tl_if_in:nnTF {##2} { \token_to_str:N : } { - \tl_put_right:Nn \l_@@_key_name_tl { @ } - \@@_split_keytype_aux:w #2 \q_stop + \tl_put_right:Nn \exp_not:N \l_@@_key_name_tl + { \token_to_str:N : } + \exp_not:N \@@_split_keytype_aux:w ##2 \exp_not:N \q_stop } { - \tl_if_empty:NTF \l_@@_key_name_tl - { \msg_error:nnx { xtemplate } { empty-key-name } { @ #2 } } - { \@@_split_keytype_arg:n {#2} } + \exp_not:N \tl_if_empty:NTF \exp_not:N \l_@@_key_name_tl + { + \msg_error:nnx { xtemplate } { empty-key-name } + { \token_to_str:N : ##2 } + } + { \exp_not:N \@@_split_keytype_arg:n {##2} } } } } diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3sort/l3sort.sty b/Master/texmf-dist/tex/latex/l3experimental/l3sort/l3sort.sty index b2f59ab27cd..18dea9646a4 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3sort/l3sort.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3sort/l3sort.sty @@ -46,8 +46,8 @@ %% %% ----------------------------------------------------------------------- %% -\RequirePackage{expl3}[2015/09/06] -\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +\@ifpackagelater{expl3}{2015/09/11} {} {% \PackageError{l3sort}{Support package l3kernel too old} @@ -59,12 +59,12 @@ }% \endinput } -\GetIdInfo$Id: l3sort.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3sort.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental sorting functions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} \int_const:Nn \c__sort_max_length_int - { \luatex_if_engine:TF { 49152 } { 24576 } } + { \sys_if_engine_luatex:TF { 49152 } { 24576 } } \int_new:N \l__sort_length_int \int_new:N \l__sort_block_int \int_new:N \l__sort_begin_int diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty index 7ba07c8b626..ae812d5afb1 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty @@ -45,8 +45,8 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\RequirePackage{expl3}[2015/09/06] -\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +\@ifpackagelater{expl3}{2015/09/11} {} {% \PackageError{l3flag}{Support package l3kernel too old} @@ -58,7 +58,7 @@ }% \endinput } -\GetIdInfo$Id: l3flag.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3flag.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental flags} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex-trace.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex-trace.sty index e8c92a8efda..da16502dece 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex-trace.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex-trace.sty @@ -45,8 +45,8 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\RequirePackage{expl3}[2015/09/06] -\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +\@ifpackagelater{expl3}{2015/09/11} {} {% \PackageError{l3regex}{Support package l3kernel too old} @@ -58,7 +58,7 @@ }% \endinput } -\GetIdInfo$Id: l3regex.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3regex.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental regular expressions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex.sty index 5d58f570101..199e2dd9d2b 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3regex.sty @@ -45,8 +45,8 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\RequirePackage{expl3}[2015/09/06] -\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +\@ifpackagelater{expl3}{2015/09/11} {} {% \PackageError{l3regex}{Support package l3kernel too old} @@ -58,7 +58,7 @@ }% \endinput } -\GetIdInfo$Id: l3regex.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3regex.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental regular expressions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str-convert.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str-convert.sty index 7ecf6196ed4..e811c9e00a9 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str-convert.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str-convert.sty @@ -46,7 +46,7 @@ %% %% ----------------------------------------------------------------------- \RequirePackage{expl3} -\GetIdInfo$Id: l3str-convert.dtx 5659 2015-07-14 18:58:00Z joseph $ +\GetIdInfo$Id: l3str-convert.dtx 5998 2015-09-11 19:51:00Z joseph $ {L3 Experimental string encoding conversions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -54,7 +54,15 @@ \cs_if_exist:NF \use_ii_i:nn { \cs_new:Npn \use_ii_i:nn #1#2 { #2 #1 } } \int_const:Nn \c_max_char_int - { \pdftex_if_engine:TF { "FF } { "10FFFF } } + { + \bool_if:nTF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } + { "10FFFF } + { "FF } + } \cs_new_protected_nopar:Npn \__str_tmp:w { } \tl_new:N \l__str_internal_tl \int_new:N \l__str_internal_int @@ -399,8 +407,11 @@ \char_set_catcode_comment:N \% \int_set:Nn \tex_endlinechar:D {32} } -\pdftex_if_engine:TF - { \cs_new_eq:NN \__str_filter_bytes:n \use:n } +\bool_if:nTF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } { \cs_new:Npn \__str_filter_bytes:n #1 { @@ -419,8 +430,12 @@ \__str_filter_bytes_aux:N } } -\pdftex_if_engine:TF - { \cs_new_protected_nopar:Npn \__str_convert_unescape_: { } } + { \cs_new_eq:NN \__str_filter_bytes:n \use:n } +\bool_if:nTF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } { \cs_new_protected_nopar:Npn \__str_convert_unescape_: { @@ -430,6 +445,7 @@ \__str_if_flag_error:nnx { str_byte } { non-byte } { bytes } } } + { \cs_new_protected_nopar:Npn \__str_convert_unescape_: { } } \cs_new_eq:NN \__str_convert_unescape_bytes: \__str_convert_unescape_: \cs_new_protected_nopar:Npn \__str_convert_escape_: { } \cs_new_eq:NN \__str_convert_escape_bytes: \__str_convert_escape_: @@ -439,7 +455,28 @@ { #1 \s__tl \__int_value:w `#1 \s__tl } \group_begin: \char_set_catcode_other:n { 0 } - \pdftex_if_engine:TF + \bool_if:nTF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } + { + \cs_new_protected_nopar:Npn \__str_convert_encode_: + { + \__tl_gbuild_x:Nw \g__str_result_tl + \exp_after:wN \__str_encode_native_loop:w + \g__str_result_tl \s__tl { \q_stop \__prg_break: } \s__tl + \__prg_break_point: + \__tl_build_end: + } + \cs_new_protected:Npn \__str_encode_native_loop:w #1 \s__tl #2 \s__tl + { + \use_none_delimit_by_q_stop:w #2 \q_stop + \tex_lccode:D \l__str_internal_int \__int_eval:w #2 \__int_eval_end: + \tl_to_lowercase:n { \__tl_build_one:n { ^^@ } } + \__str_encode_native_loop:w + } + } { \cs_new_protected_nopar:Npn \__str_convert_encode_: { @@ -465,23 +502,6 @@ To~manipulate~arbitrary~Unicode,~use~LuaTeX~or~XeTeX. } } - { - \cs_new_protected_nopar:Npn \__str_convert_encode_: - { - \__tl_gbuild_x:Nw \g__str_result_tl - \exp_after:wN \__str_encode_native_loop:w - \g__str_result_tl \s__tl { \q_stop \__prg_break: } \s__tl - \__prg_break_point: - \__tl_build_end: - } - \cs_new_protected:Npn \__str_encode_native_loop:w #1 \s__tl #2 \s__tl - { - \use_none_delimit_by_q_stop:w #2 \q_stop - \tex_lccode:D \l__str_internal_int \__int_eval:w #2 \__int_eval_end: - \tl_to_lowercase:n { \__tl_build_one:n { ^^@ } } - \__str_encode_native_loop:w - } - } \group_end: \cs_new_protected_nopar:Npn \__str_convert_decode_clist: { @@ -614,7 +634,11 @@ } \__msg_kernel_new:nnn { str } { file-not-found } { File~'l3str-#1.def'~not~found. } -\pdftex_if_engine:F +\bool_if:nT + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } { \__msg_kernel_new:nnnn { str } { non-byte } { String~invalid~in~escaping~'#1':~it~may~only~contain~bytes. } diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str.sty index 645282820f0..db0c177ea56 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3str.sty @@ -45,8 +45,8 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\RequirePackage{expl3}[2015/09/06] -\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +\@ifpackagelater{expl3}{2015/09/11} {} {% \PackageError{l3str}{Support package l3kernel too old} @@ -58,7 +58,7 @@ }% \endinput } -\GetIdInfo$Id: l3str-expl.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3str-expl.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental strings} \def\ExplFileName{l3str} \ProvidesExplPackage diff --git a/Master/texmf-dist/tex/latex/l3experimental/xgalley/l3galley.sty b/Master/texmf-dist/tex/latex/l3experimental/xgalley/l3galley.sty index 129f34e20d2..32b6f0565ee 100644 --- a/Master/texmf-dist/tex/latex/l3experimental/xgalley/l3galley.sty +++ b/Master/texmf-dist/tex/latex/l3experimental/xgalley/l3galley.sty @@ -47,8 +47,8 @@ %% %% ----------------------------------------------------------------------- %% -\RequirePackage{expl3}[2015/09/06] -\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +\@ifpackagelater{expl3}{2015/09/11} {} {% \PackageError{l3galley}{Support package l3kernel too old} @@ -60,7 +60,7 @@ }% \endinput } -\GetIdInfo$Id: l3galley.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3galley.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental galley code} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex b/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex index d6a472cf469..0c0e211dda4 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex +++ b/Master/texmf-dist/tex/latex/l3kernel/expl3-code.tex @@ -38,6 +38,7 @@ %% l3coffins.dtx (with options: `package') %% l3color.dtx (with options: `package') %% l3candidates.dtx (with options: `package') +%% l3sys.dtx (with options: `package') %% l3luatex.dtx (with options: `package') %% %% EXPERIMENTAL CODE @@ -81,8 +82,8 @@ %% ----------------------------------------------------------------------- \def\ExplFileName{expl3} \def\ExplFileDescription{L3 programming layer} -\def\ExplFileDate{2015/09/06} -\def\ExplFileVersion{5925} +\def\ExplFileDate{2015/09/11} +\def\ExplFileVersion{6002} \begingroup \def\next{\endgroup} \expandafter\ifx\csname PackageError\endcsname\relax @@ -241,7 +242,7 @@ } } \endgroup -\GetIdInfo$Id: l3bootstrap.dtx 5729 2015-07-31 05:56:12Z joseph $ +\GetIdInfo$Id: l3bootstrap.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Bootstrap code} \begingroup \expandafter\ifx\csname directlua\endcsname\relax @@ -295,7 +296,48 @@ \global\everyjob\expandafter {% \the\expandafter\everyjob - \expandafter\luatex_directlua:D\expandafter{\tempa}% + \expandafter\lua_now_x:n\expandafter{\tempa}% + } + \fi + \fi + \fi +\endgroup +\begingroup + \expandafter\ifx\csname directlua\endcsname\relax + \else + \ifnum\luatexversion<70 % + \else + \begingroup\expandafter\expandafter\expandafter\endgroup + \expandafter\ifx\csname newcatcodetable\endcsname\relax + \directlua{tex.enableprimitives("",{"initcatcodetable"})} + \chardef\ucharcat@table"7000 % + \initcatcodetable\ucharcat@table + \else + \newcatcodetable\ucharcat@table + \fi + \catcode`\_=11 % + \catcode`\:=11 % + \def\tempa + {% + l3kernel = l3kernel or { } + local utf8_char = unicode.utf8.char + function l3kernel.charcat(charcode, catcode) + tex.setcatcode(\number\ucharcat@table, charcode, catcode) + tex.sprint(\number\ucharcat@table, utf8_char(charcode)) + end + } + \directlua{\tempa} + \ifnum 0% + \directlua + {% + if status.ini_version then + tex.write("1") + end + }>0 % + \global\everyjob\expandafter + {% + \the\expandafter\everyjob + \expandafter\lua_now_x:n\expandafter{\tempa}% } \fi \fi @@ -447,7 +489,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3names.dtx 5848 2015-08-17 05:27:13Z joseph $ +\GetIdInfo$Id: l3names.dtx 5939 2015-09-07 21:15:55Z joseph $ {L3 Namespace for primitives} \let \tex_global:D \global \let \tex_let:D \let @@ -1331,6 +1373,11 @@ \tex_let:D \utex_mathcode:D \XeTeXmathcode \tex_let:D \utex_mathcodenum:D \XeTeXmathcodenum \tex_fi:D +\etex_ifdefined:D \luatex_luatexversion:D + \tex_let:D \pdftex_pdftexbanner:D \tex_undefined:D + \tex_let:D \pdftex_pdftexbanner:D \tex_undefined:D + \tex_let:D \pdftex_pdftexversion:D \tex_undefined:D +\tex_fi:D \etex_ifdefined:D \normalend \tex_let:D \tex_end:D \normalend \tex_let:D \tex_everyjob:D \normaleveryjob @@ -1389,7 +1436,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3basics.dtx 5897 2015-08-28 09:06:29Z joseph $ +\GetIdInfo$Id: l3basics.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Basic definitions} \tex_let:D \if_true: \tex_iftrue:D \tex_let:D \if_false: \tex_iffalse:D @@ -2108,40 +2155,6 @@ { \__msg_show_wrap:n { > ~ \token_to_str:N #1 = \cs_meaning:N #1 } } \cs_new_protected_nopar:Npn \cs_show:c { \group_begin: \exp_args:NNc \group_end: \cs_show:N } -\cs_new_eq:NN \luatex_if_engine:T \use_none:n -\cs_new_eq:NN \luatex_if_engine:F \use:n -\cs_new_eq:NN \luatex_if_engine:TF \use_ii:nn -\cs_new_eq:NN \pdftex_if_engine:T \use:n -\cs_new_eq:NN \pdftex_if_engine:F \use_none:n -\cs_new_eq:NN \pdftex_if_engine:TF \use_i:nn -\cs_new_eq:NN \xetex_if_engine:T \use_none:n -\cs_new_eq:NN \xetex_if_engine:F \use:n -\cs_new_eq:NN \xetex_if_engine:TF \use_ii:nn -\cs_new_eq:NN \luatex_if_engine_p: \c_false_bool -\cs_new_eq:NN \pdftex_if_engine_p: \c_true_bool -\cs_new_eq:NN \xetex_if_engine_p: \c_false_bool -\cs_if_exist:NT \xetex_XeTeXversion:D - { - \cs_gset_eq:NN \pdftex_if_engine:T \use_none:n - \cs_gset_eq:NN \pdftex_if_engine:F \use:n - \cs_gset_eq:NN \pdftex_if_engine:TF \use_ii:nn - \cs_gset_eq:NN \xetex_if_engine:T \use:n - \cs_gset_eq:NN \xetex_if_engine:F \use_none:n - \cs_gset_eq:NN \xetex_if_engine:TF \use_i:nn - \cs_gset_eq:NN \pdftex_if_engine_p: \c_false_bool - \cs_gset_eq:NN \xetex_if_engine_p: \c_true_bool - } -\cs_if_exist:NT \luatex_directlua:D - { - \cs_gset_eq:NN \luatex_if_engine:T \use:n - \cs_gset_eq:NN \luatex_if_engine:F \use_none:n - \cs_gset_eq:NN \luatex_if_engine:TF \use_i:nn - \cs_gset_eq:NN \pdftex_if_engine:T \use_none:n - \cs_gset_eq:NN \pdftex_if_engine:F \use:n - \cs_gset_eq:NN \pdftex_if_engine:TF \use_ii:nn - \cs_gset_eq:NN \luatex_if_engine_p: \c_true_bool - \cs_gset_eq:NN \pdftex_if_engine_p: \c_false_bool - } \cs_new_nopar:Npn \prg_do_nothing: { } \cs_new_eq:NN \__prg_break_point:Nn \use_ii:nn \cs_new:Npn \__prg_map_break:Nn #1#2#3 \__prg_break_point:Nn #4#5 @@ -2187,7 +2200,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3expan.dtx 5897 2015-08-28 09:06:29Z joseph $ +\GetIdInfo$Id: l3expan.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Argument expansion} \cs_new:Npn \__exp_arg_next:nnn #1#2#3 { #2 \::: { #3 {#1} } } \cs_new:Npn \__exp_arg_next:Nnn #1#2#3 { #2 \::: { #3 #1 } } @@ -2667,7 +2680,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3tl.dtx 5908 2015-09-02 14:50:27Z joseph $ +\GetIdInfo$Id: l3tl.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Token lists} \cs_new_protected:Npn \tl_new:N #1 { @@ -2848,16 +2861,25 @@ { \__tl_set_rescan:NNnn \prg_do_nothing: \use:n } \cs_new_protected:Npn \__tl_set_rescan:NNnn #1#2#3#4 { - \group_begin: - \exp_args:No \etex_everyeof:D { \c__tl_rescan_marker_tl \exp_not:N } - \int_compare:nNnT \tex_endlinechar:D = { 32 } - { \tex_endlinechar:D \c_minus_one } - \tex_newlinechar:D \tex_endlinechar:D - #3 \scan_stop: - \exp_args:No \__tl_set_rescan:n { \tl_to_str:n {#4} } - \exp_args:NNNo - \group_end: - #1 #2 \l__tl_internal_a_tl + \tl_if_empty:nTF {#4} + { + \group_begin: + #3 + \group_end: + #1 #2 { } + } + { + \group_begin: + \exp_args:No \etex_everyeof:D { \c__tl_rescan_marker_tl \exp_not:N } + \int_compare:nNnT \tex_endlinechar:D = { 32 } + { \tex_endlinechar:D \c_minus_one } + \tex_newlinechar:D \tex_endlinechar:D + #3 \scan_stop: + \exp_args:No \__tl_set_rescan:n { \tl_to_str:n {#4} } + \exp_args:NNNo + \group_end: + #1 #2 \l__tl_internal_a_tl + } } \cs_new_protected:Npn \__tl_set_rescan_multi:n #1 { @@ -3574,7 +3596,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3str.dtx 5920 2015-09-05 07:55:06Z joseph $ +\GetIdInfo$Id: l3str.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Strings} \cs_new:Npn \str_head:n #1 { @@ -3592,7 +3614,7 @@ } \cs_new:Npn \__str_tail:w #1 X #2 \q_stop { \fi: #1 } \cs_new:Npn \__str_if_eq_x:nn #1#2 { \pdftex_strcmp:D {#1} {#2} } -\luatex_if_engine:T +\cs_if_exist:NT \luatex_luatexversion:D { \cs_set:Npn \__str_if_eq_x:nn #1#2 { @@ -4339,7 +4361,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3int.dtx 5885 2015-08-24 13:29:14Z mittelba $ +\GetIdInfo$Id: l3int.dtx 5987 2015-09-11 05:44:48Z joseph $ {L3 Integers} \cs_new_eq:NN \__int_value:w \tex_number:D \cs_new_eq:NN \__int_eval:w \etex_numexpr:D @@ -4439,15 +4461,20 @@ } } \cs_generate_variant:Nn \int_const:Nn { c } -\pdftex_if_engine:TF - { - \cs_new_eq:NN \__int_constdef:Nw \tex_mathchardef:D - \tex_mathchardef:D \c__max_constdef_int 32 767 ~ - } - { - \cs_new_eq:NN \__int_constdef:Nw \tex_chardef:D - \tex_chardef:D \c__max_constdef_int 1 114 111 ~ - } +\if_int_odd:w 0 + \cs_if_exist:NT \luatex_luatexversion:D { 1 } + \cs_if_exist:NT \uptex_disablecjktoken:D + { \if_int_compare:w \ptex_jis:D "2121 = "3000 ~ 1 \fi: } + \cs_if_exist:NT \xetex_XeTeXversion:D { 1 } + ~ + \cs_if_exist:NTF \uptex_disablecjktoken:D + { \cs_new_eq:NN \__int_constdef:Nw \uptex_kchardef:D } + { \cs_new_eq:NN \__int_constdef:Nw \tex_chardef:D } + \__int_constdef:Nw \c__max_constdef_int 1114111 ~ +\else: + \cs_new_eq:NN \__int_constdef:Nw \tex_mathchardef:D + \tex_mathchardef:D \c__max_constdef_int 32767 ~ +\fi: \cs_new_protected:Npn \int_zero:N #1 { #1 = \c_zero } \cs_new_protected:Npn \int_gzero:N #1 { \tex_global:D #1 = \c_zero } \cs_generate_variant:Nn \int_zero:N { c } @@ -5303,7 +5330,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3prg.dtx 5891 2015-08-25 08:00:59Z mittelba $ +\GetIdInfo$Id: l3prg.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Control structures} %% \cs_new_eq:NN \if_bool:N \tex_ifodd:D @@ -7295,7 +7322,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3msg.dtx 5891 2015-08-25 08:00:59Z mittelba $ +\GetIdInfo$Id: l3msg.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Messages} \tl_new:N \l__msg_internal_tl \tl_const:Nn \c__msg_text_prefix_tl { msg~text~>~ } @@ -8733,7 +8760,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3skip.dtx 5893 2015-08-26 16:16:52Z mittelba $ +\GetIdInfo$Id: l3skip.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Dimensions and skips} \cs_new_eq:NN \if_dim:w \tex_ifdim:D \cs_new_eq:NN \__dim_eval:w \etex_dimexpr:D @@ -9173,7 +9200,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3keys.dtx 5869 2015-08-20 01:19:17Z bruno $ +\GetIdInfo$Id: l3keys.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Key-value interfaces} \int_new:N \g__keyval_level_int \tl_new:N \l__keyval_key_tl @@ -16718,7 +16745,7 @@ %% %% ----------------------------------------------------------------------- %% -\GetIdInfo$Id: l3candidates.dtx 5911 2015-09-03 08:24:00Z joseph $ +\GetIdInfo$Id: l3candidates.dtx 6002 2015-09-11 22:13:30Z joseph $ {L3 Experimental additions to l3kernel} \cs_new_protected_nopar:Npn \cs_log:N { \__msg_log_next: \cs_show:N } @@ -18607,6 +18634,137 @@ \__char_tmp:nN { char_set_active_eq } \cs_set_eq:NN \__char_tmp:nN { char_gset_active_eq } \cs_gset_eq:NN \group_end: +\cs_new:Npn \char_generate:nn #1#2 + { + \exp:w \exp_after:wN \__char_generate_aux:w + \int_use:N \__int_eval:w #1 \exp_after:wN ; + \int_use:N \__int_eval:w #2 ; + } +\cs_new:Npn \__char_generate_aux:w #1 ; #2 ; + { + \if_int_compare:w #2 = \c_thirteen + \__msg_kernel_expandable_error:nn { kernel } { char-active } + \else: + \if_int_compare:w #2 = \c_ten + \if_int_compare:w #1 = \c_zero + \__msg_kernel_expandable_error:nn { kernel } { char-null-space } + \else: + \__msg_kernel_expandable_error:nn { kernel } { char-space } + \fi: + \else: + \if_int_odd:w 0 + \if_int_compare:w #2 < \c_one 1 \fi: + \if_int_compare:w #2 = \c_five 1 \fi: + \if_int_compare:w #2 = \c_nine 1 \fi: + \if_int_compare:w #2 > \c_thirteen 1 \fi: \exp_stop_f: + \__msg_kernel_expandable_error:nn { kernel } + { char-invalid-catcode } + \else: + \if_int_odd:w 0 + \if_int_compare:w #1 < \c_zero 1 \fi: + \if_int_compare:w #1 > \c__char_max_int 1 \fi: \exp_stop_f: + \__msg_kernel_expandable_error:nn { kernel } + { char-out-of-range } + \else: + \__char_generate_aux:nnw {#1} {#2} + \fi: + \fi: + \fi: + \fi: + \exp_end: + } +\tl_new:N \l__char_tmp_tl +\group_begin: + \cs_set_nopar:Npn ^^L { } + \char_set_catcode_other:n { 0 } + \if_int_odd:w 0 + \cs_if_exist:NT \luatex_directlua:D { 1 } + \cs_if_exist:NT \utex_charcat:D { 1 } \exp_stop_f: + \int_const:Nn \c__char_max_int { 1114111 } + \cs_if_exist:NTF \luatex_directlua:D + { + \cs_new:Npn \__char_generate_aux:nnw #1#2#3 \exp_end: + { + #3 + \exp_after:wN \exp_end: + \luatex_directlua:D { l3kernel.charcat(#1, #2) } + } + } + { + \cs_new:Npn \__char_generate_aux:nnw #1#2#3 \exp_end: + { + #3 + \exp_after:wN \exp_end: + \utex_charcat:D #1 ~ #2 ~ + } + } + \else: + \int_const:Nn \c__char_max_int { 255 } + \tl_set:Nn \l__char_tmp_tl { \exp_not:N \or: } + \char_set_catcode_group_begin:n { 0 } % { + \tl_put_right:Nn \l__char_tmp_tl { ^^@ \if_false: } } + \char_set_catcode_group_end:n { 0 } + \tl_put_right:Nn \l__char_tmp_tl { { \fi: \exp_not:N \or: ^^@ } % } + \tl_set:Nx \l__char_tmp_tl { \l__char_tmp_tl } + \char_set_catcode_math_toggle:n { 0 } + \tl_put_right:Nn \l__char_tmp_tl { \or: ^^@ } + \char_set_catcode_alignment:n { 0 } + \tl_put_right:Nn \l__char_tmp_tl { \or: ^^@ } + \tl_put_right:Nn \l__char_tmp_tl { \or: } + \char_set_catcode_parameter:n { 0 } + \tl_put_right:Nn \l__char_tmp_tl { \or: ^^@ } + \char_set_catcode_math_superscript:n { 0 } + \tl_put_right:Nn \l__char_tmp_tl { \or: ^^@ } + \char_set_catcode_math_subscript:n { 0 } + \tl_put_right:Nn \l__char_tmp_tl { \or: ^^@ } + \tl_put_right:Nn \l__char_tmp_tl { \or: } + \char_set_catcode_space:n { 0 } + \tl_put_right:No \l__char_tmp_tl { \use:n { \or: } ^^@ } + \char_set_catcode_letter:n { 0 } + \tl_put_right:Nn \l__char_tmp_tl { \or: ^^@ } + \char_set_catcode_other:n { 0 } + \tl_put_right:Nn \l__char_tmp_tl { \or: ^^@ } + \char_set_catcode_active:n { 0 } + \tl_put_right:Nn \l__char_tmp_tl { \or: ^^@ } + \cs_set_protected:Npn \__char_tmp:n #1 + { + \char_set_lccode:nn { 0 } {#1} + \char_set_lccode:nn { 32 } {#1} + \exp_args:Nx \tex_lowercase:D + { + \tl_const:cn { c__char_ \__int_to_roman:w #1 _tl } + { \exp_not:o \l__char_tmp_tl } + } + } + \int_step_function:nnnN { 0 } { 1 } { 11 } \__char_tmp:n + \group_begin: + \tl_replace_once:Nnn \l__char_tmp_tl { ^^@ } { \ERROR } + \__char_tmp:n { 12 } + \group_end: + \int_step_function:nnnN { 13 } { 1 } { 255 } \__char_tmp:n + \cs_new:Npn \__char_generate_aux:nnw #1#2#3 \exp_end: + { + #3 + \exp_after:wN \exp_after:wN + \exp_after:wN \exp_end: + \exp_after:wN \exp_after:wN + \if_case:w #2 + \exp_last_unbraced:Nv \exp_stop_f: + { c__char_ \__int_to_roman:w #1 _tl } + \fi: + } + \fi: +\group_end: +\__msg_kernel_new:nnn { kernel } { char-active } + { Cannot~generate~active~chars. } +\__msg_kernel_new:nnn { kernel } { char-invalid-catcode } + { Invalid~catcode~for~char~generation. } +\__msg_kernel_new:nnn { kernel } { char-null-space } + { Cannot~generate~null~char~as~a~space. } +\__msg_kernel_new:nnn { kernel } { char-out-of-range } + { Charcode~requested~out~of~engine~range. } +\__msg_kernel_new:nnn { kernel } { char-space } + { Cannot~generate~space~chars. } \group_begin: \char_set_catcode_other:N \O \char_set_catcode_other:N \U @@ -18655,6 +18813,109 @@ { \fp_gset:Nn #1 { \dim_to_fp:n {#2} } } \cs_generate_variant:Nn \fp_set_from_dim:Nn { c } \cs_generate_variant:Nn \fp_gset_from_dim:Nn { c } +%% File: l3sys.dtx Copyright (C) 2015 The LaTeX3 Project +%% +%% It may be distributed and/or modified under the conditions of the +%% LaTeX Project Public License (LPPL), either version 1.3c of this +%% license or (at your option) any later version. The latest version +%% of this license is in the file +%% +%% http://www.latex-project.org/lppl.txt +%% +%% This file is part of the "l3kernel bundle" (The Work in LPPL) +%% and all files in that bundle must be distributed together. +%% +%% The released version of this bundle is available from CTAN. +%% +%% ----------------------------------------------------------------------- +%% +%% The development version of the bundle can be found at +%% +%% http://www.latex-project.org/svnroot/experimental/trunk/ +%% +%% for those people who are interested. +%% +%%%%%%%%%%% +%% NOTE: %% +%%%%%%%%%%% +%% +%% Snapshots taken from the repository represent work in progress and may +%% not work or may contain conflicting material! We therefore ask +%% people _not_ to put them into distributions, archives, etc. without +%% prior consultation with the LaTeX3 Project. +%% +%% ----------------------------------------------------------------------- +\GetIdInfo$Id$ + {L3 Experimental system/runtime functions} +\clist_map_inline:nn { lua , pdf , p , up , xe } + { + \cs_new_eq:cN { sys_if_engine_ #1 tex:T } \use_none:n + \cs_new_eq:cN { sys_if_engine_ #1 tex:F } \use:n + \cs_new_eq:cN { sys_if_engine_ #1 tex:TF } \use_ii:nn + \cs_new_eq:cN { sys_if_engine_ #1 tex_p: } \c_false_bool + } +\cs_if_exist:NT \luatex_luatexversion:D + { + \cs_gset_eq:NN \sys_if_engine_luatex:T \use:n + \cs_gset_eq:NN \sys_if_engine_luatex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_luatex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_luatex_p: \c_true_bool + } +\cs_if_exist:NT \pdftex_pdftexversion:D + { + \cs_gset_eq:NN \sys_if_engine_pdftex:T \use:n + \cs_gset_eq:NN \sys_if_engine_pdftex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_pdftex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_pdftex_p: \c_true_bool + } +\cs_if_exist:NT \ptex_kanjiskip:D + { + \bool_if:nTF + { + \cs_if_exist_p:N \uptex_disablecjktoken:D && + \int_compare_p:nNn { \ptex_jis:D "2121 } = { "3000 } + } + { + \cs_gset_eq:NN \sys_if_engine_uptex:T \use:n + \cs_gset_eq:NN \sys_if_engine_uptex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_uptex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_uptex_p: \c_true_bool + } + { + \cs_gset_eq:NN \sys_if_engine_ptex:T \use:n + \cs_gset_eq:NN \sys_if_engine_ptex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_ptex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_ptex_p: \c_true_bool + } + } +\cs_if_exist:NT \xetex_XeTeXversion:D + { + \cs_gset_eq:NN \sys_if_engine_xetex:T \use:n + \cs_gset_eq:NN \sys_if_engine_xetex:F \use_none:n + \cs_gset_eq:NN \sys_if_engine_xetex:TF \use_i:nn + \cs_gset_eq:NN \sys_if_engine_xetex_p: \c_true_bool + } +\prg_new_eq_conditional:NNn \luatex_if_engine: \sys_if_engine_luatex: + { T , F , TF , p } +\prg_new_eq_conditional:NNn \xetex_if_engine: \sys_if_engine_xetex: + { T , F , TF , p } +\bool_if:nTF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } + { + \cs_new_eq:NN \pdftex_if_engine:T \use_none:n + \cs_new_eq:NN \pdftex_if_engine:F \use:n + \cs_new_eq:NN \pdftex_if_engine:TF \use_ii:nn + \cs_new_eq:NN \pdftex_if_engine_p: \c_false_bool + } + { + \cs_new_eq:NN \pdftex_if_engine:T \use:n + \cs_new_eq:NN \pdftex_if_engine:F \use_none:n + \cs_new_eq:NN \pdftex_if_engine:TF \use_i:nn + \cs_new_eq:NN \pdftex_if_engine_p: \c_true_bool + } %% File: l3luatex.dtx Copyright (C) 2010-2015 The LaTeX3 Project %% %% It may be distributed and/or modified under the conditions of the @@ -18687,7 +18948,7 @@ %% prior consultation with the LaTeX3 Project. %% %% ----------------------------------------------------------------------- -\GetIdInfo$Id: l3luatex.dtx 5646 2015-06-30 21:19:24Z joseph $ +\GetIdInfo$Id: l3luatex.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Experimental LuaTeX-specific functions} \cs_new:Npn \lua_now_x:n #1 { \luatex_directlua:D {#1} } \cs_new:Npn \lua_now:n #1 { \lua_now_x:n { \exp_not:n {#1} } } @@ -18696,7 +18957,7 @@ { \lua_shipout_x:n { \exp_not:n {#1} } } \cs_new:Npn \lua_escape_x:n #1 { \luatex_luaescapestring:D {#1} } \cs_new:Npn \lua_escape:n #1 { \lua_escape_x:n { \exp_not:n {#1} } } -\luatex_if_engine:F +\sys_if_engine_luatex:F { \clist_map_inline:nn { \lua_now_x:n , \lua_now:n , \lua_escape_x:n , \lua_escape:n } diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex b/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex index a5203a71d7e..b06f37d4c6d 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex +++ b/Master/texmf-dist/tex/latex/l3kernel/expl3-generic.tex @@ -47,8 +47,8 @@ %% ----------------------------------------------------------------------- \def\ExplFileName{expl3} \def\ExplFileDescription{L3 programming layer} -\def\ExplFileDate{2015/09/06} -\def\ExplFileVersion{5925} +\def\ExplFileDate{2015/09/11} +\def\ExplFileVersion{6002} \let\ExplLoaderFileVersion\ExplFileVersion \begingroup \def\tempa{LaTeX2e} @@ -116,7 +116,7 @@ } \tex_input:D l3 - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { xdvipdfmx } { \bool_if:nTF diff --git a/Master/texmf-dist/tex/latex/l3kernel/expl3.sty b/Master/texmf-dist/tex/latex/l3kernel/expl3.sty index fc1a2022831..acd8aaf809f 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/expl3.sty +++ b/Master/texmf-dist/tex/latex/l3kernel/expl3.sty @@ -47,8 +47,8 @@ %% ----------------------------------------------------------------------- \def\ExplFileName{expl3} \def\ExplFileDescription{L3 programming layer} -\def\ExplFileDate{2015/09/06} -\def\ExplFileVersion{5925} +\def\ExplFileDate{2015/09/11} +\def\ExplFileVersion{6002} \let\ExplLoaderFileVersion\ExplFileVersion \ProvidesPackage{\ExplFileName} [% @@ -134,19 +134,27 @@ { \tl_set:Nx \l__expl_driver_tl { - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { xdvipdfmx } { \__expl_if_pdf:TF { pdfmode } - { dvips } + { + \bool_if:nTF + { + \sys_if_engine_pdftex_p: || + \sys_if_engine_luatex_p: + } + { dvips } + { dvipdfmx } + } } } }, driver / dvipdfmx .code:n = { \tl_set:Nn \l__expl_driver_tl { dvipdfmx } - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { \__msg_kernel_error:nnnn { expl } { wrong-driver } { dvipdfmx } { xdvipdfmx } @@ -164,7 +172,7 @@ driver / dvips .code:n = { \tl_set:Nn \l__expl_driver_tl { dvips } - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { \__msg_kernel_error:nnnn { expl } { wrong-driver } { dvips } { xdvipdfmx } @@ -184,7 +192,7 @@ driver / pdfmode .code:n = { \tl_set:Nn \l__expl_driver_tl { pdfmode } - \xetex_if_engine:TF + \sys_if_engine_xetex:TF { \__msg_kernel_error:nnnn { expl } { wrong-driver } { pdfmode } { xdvipdfmx } @@ -202,7 +210,7 @@ driver / xdvipdfmx .code:n = { \tl_set:Nn \l__expl_driver_tl { xdvipdfmx } - \xetex_if_engine:F + \sys_if_engine_xetex:F { \__expl_if_pdf:TF { diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls b/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls index 1dd35279f65..c06eb9cbee2 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls +++ b/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls @@ -50,7 +50,7 @@ \let \fileversionOld \ExplFileVersion \let \filedescriptionOld \ExplFileDescription \RequirePackage{expl3,xparse,calc} -\GetIdInfo$Id: l3doc.dtx 5903 2015-09-02 06:03:07Z joseph $ +\GetIdInfo$Id: l3doc.dtx 5983 2015-09-10 18:57:56Z joseph $ {L3 Experimental documentation class} \ProvidesExplClass {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -314,6 +314,10 @@ \providecommand*\LuaTeX{\hologo{LuaTeX}} \providecommand*\pdfTeX{\hologo{pdfTeX}} \providecommand*\XeTeX{\hologo{XeTeX}} +\providecommand*\pTeX{p\kern-.2em\hologo{TeX}} +\providecommand*\upTeX{up\kern-.2em\hologo{TeX}} +\providecommand*\epTeX{$\varepsilon$-\pTeX} +\providecommand*\eupTeX{$\varepsilon$-\upTeX} \DeclareExpandableDocumentCommand \cmd { O{} m } { \__codedoc_cmd:no {#1} { \token_to_str:N #2 } } \DeclareExpandableDocumentCommand \cs { O{} m } diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3unicode-data.def b/Master/texmf-dist/tex/latex/l3kernel/l3unicode-data.def index 399ad3dd390..a08bc0fff3e 100644 --- a/Master/texmf-dist/tex/latex/l3kernel/l3unicode-data.def +++ b/Master/texmf-dist/tex/latex/l3kernel/l3unicode-data.def @@ -12,7 +12,11 @@ %% Generated on 2015-07-20. %% \ProvidesExplFile {l3unicode-data.def} {2015/07/20} {5676} {L3 Unicode data} -\pdftex_if_engine:T +\bool_if:nF + { + \sys_if_engine_luatex_p: || + \sys_if_engine_xetex_p: + } { \group_begin: \cs_set_protected:Npn \__unicode_tmp:NN #1#2 diff --git a/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty b/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty index 7e836dd3dcd..9dffe8d39d6 100644 --- a/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty +++ b/Master/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty @@ -46,8 +46,8 @@ %% %% ----------------------------------------------------------------------- %% -\RequirePackage{expl3}[2015/09/06] -\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +\@ifpackagelater{expl3}{2015/09/11} {} {% \PackageError{l3keys2e}{Support package l3kernel too old} @@ -59,7 +59,7 @@ }% \endinput } -\GetIdInfo$Id: l3keys2e.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: l3keys2e.dtx 6001 2015-09-11 21:50:23Z joseph $ {LaTeX2e option processing using LaTeX3 keys} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty index bde3d90f6db..9c1441858b5 100644 --- a/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty +++ b/Master/texmf-dist/tex/latex/l3packages/xparse/xparse.sty @@ -50,8 +50,8 @@ %% %% ----------------------------------------------------------------------- %% -\RequirePackage{expl3}[2015/09/06] -\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +\@ifpackagelater{expl3}{2015/09/11} {} {% \PackageError{xparse}{Support package l3kernel too old} @@ -63,7 +63,7 @@ }% \endinput } -\GetIdInfo$Id: xparse.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: xparse.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental document command parser} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} diff --git a/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty b/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty index ba9d715489a..c761e58bb88 100644 --- a/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty +++ b/Master/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty @@ -50,8 +50,8 @@ %% %% ----------------------------------------------------------------------- %% -\RequirePackage{expl3}[2015/09/06] -\@ifpackagelater{expl3}{2015/09/06} +\RequirePackage{expl3}[2015/09/11] +\@ifpackagelater{expl3}{2015/09/11} {} {% \PackageError{xtemplate}{Support package l3kernel too old} @@ -63,7 +63,7 @@ }% \endinput } -\GetIdInfo$Id: xtemplate.dtx 5925 2015-09-06 09:25:46Z joseph $ +\GetIdInfo$Id: xtemplate.dtx 6001 2015-09-11 21:50:23Z joseph $ {L3 Experimental prototype document functions} \ProvidesExplPackage {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} @@ -328,41 +328,46 @@ \__xtemplate_parse_keys_elt:n {#1} \use:c { __xtemplate_store_value_ \l__xtemplate_keytype_tl :n } {#2} } -\group_begin: -\char_set_lccode:nn { `\@ } { `\: } -\char_set_catcode_other:N \@ -\tl_to_lowercase:n +\cs_new_protected:Npx \__xtemplate_split_keytype:n #1 { - \group_end: - \cs_new_protected:Npn \__xtemplate_split_keytype:n #1 + \exp_not:N \bool_set_false:N \exp_not:N \l__xtemplate_error_bool + \tl_set:Nn \exp_not:N \l__xtemplate_tmp_tl {#1} + \tl_remove_all:Nn \exp_not:N \l__xtemplate_tmp_tl { ~ } + \tl_replace_all:Nnn \exp_not:N \l__xtemplate_tmp_tl { : } { \token_to_str:N : } + \tl_if_in:onTF \exp_not:N \l__xtemplate_tmp_tl { \token_to_str:N : } { - \bool_set_false:N \l__xtemplate_error_bool - \tl_set:Nn \l__xtemplate_tmp_tl {#1} - \tl_remove_all:Nn \l__xtemplate_tmp_tl { ~ } - \tl_replace_all:Nnn \l__xtemplate_tmp_tl { : } { @ } - \tl_if_in:onTF \l__xtemplate_tmp_tl { @ } + \exp_not:n { \tl_clear:N \l__xtemplate_key_name_tl \exp_after:wN \__xtemplate_split_keytype_aux:w \l__xtemplate_tmp_tl \q_stop } - { - \bool_set_true:N \l__xtemplate_error_bool - \msg_error:nnx { xtemplate } { missing-keytype } {#1} - } } - \cs_new_protected:Npn \__xtemplate_split_keytype_aux:w #1 @ #2 \q_stop { - \tl_put_right:Nx \l__xtemplate_key_name_tl { \tl_to_str:n {#1} } - \tl_if_in:nnTF {#2} { @ } + \exp_not:N \bool_set_true:N \exp_not:N \l__xtemplate_error_bool + \msg_error:nnx { xtemplate } { missing-keytype } {#1} + } + } +\use:x + { + \cs_new_protected:Npn \exp_not:N \__xtemplate_split_keytype_aux:w + ##1 \token_to_str:N : ##2 \exp_not:N \q_stop + { + \tl_put_right:Nx \exp_not:N \l__xtemplate_key_name_tl + { \exp_not:N \tl_to_str:n {##1} } + \tl_if_in:nnTF {##2} { \token_to_str:N : } { - \tl_put_right:Nn \l__xtemplate_key_name_tl { @ } - \__xtemplate_split_keytype_aux:w #2 \q_stop + \tl_put_right:Nn \exp_not:N \l__xtemplate_key_name_tl + { \token_to_str:N : } + \exp_not:N \__xtemplate_split_keytype_aux:w ##2 \exp_not:N \q_stop } { - \tl_if_empty:NTF \l__xtemplate_key_name_tl - { \msg_error:nnx { xtemplate } { empty-key-name } { @ #2 } } - { \__xtemplate_split_keytype_arg:n {#2} } + \exp_not:N \tl_if_empty:NTF \exp_not:N \l__xtemplate_key_name_tl + { + \msg_error:nnx { xtemplate } { empty-key-name } + { \token_to_str:N : ##2 } + } + { \exp_not:N \__xtemplate_split_keytype_arg:n {##2} } } } } |