summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2015-11-20 23:16:05 +0000
committerKarl Berry <karl@freefriends.org>2015-11-20 23:16:05 +0000
commitaf275c7f6fca66b476804270863d1a5e971cb956 (patch)
tree2babc0b07e29ab306dabc2d3d53da58f772c3cd5
parentd092745105741bf835e2735a9d93e8775c70d1ce (diff)
ucharcat (20nov15)
git-svn-id: svn://tug.org/texlive/trunk@38907 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/ucharcat/ucharcat.pdfbin159115 -> 159215 bytes
-rw-r--r--Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx16
-rw-r--r--Master/texmf-dist/tex/latex/ucharcat/ucharcat.sty7
3 files changed, 12 insertions, 11 deletions
diff --git a/Master/texmf-dist/doc/latex/ucharcat/ucharcat.pdf b/Master/texmf-dist/doc/latex/ucharcat/ucharcat.pdf
index 10cbd506795..9f6c8f8d37b 100644
--- a/Master/texmf-dist/doc/latex/ucharcat/ucharcat.pdf
+++ b/Master/texmf-dist/doc/latex/ucharcat/ucharcat.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx b/Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx
index 1f8dd13c629..a5b06392c5c 100644
--- a/Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx
+++ b/Master/texmf-dist/source/latex/ucharcat/ucharcat.dtx
@@ -13,7 +13,7 @@
%<driver> \ProvidesFile{ucharcat.drv}
% \fi
% \ProvidesFile{ucharcat.dtx}
- [2015/08/23 v0.02 ucharcat for luaLaTeX (DPC)]
+ [2015/11/19 v0.03 ucharcat for luaLaTeX (DPC)]
%
% \iffalse
%<*driver>
@@ -103,13 +103,12 @@
%
% Note that the current implementation uses |\directlua| and a
% dedicated luatex catcode array. Hans hagen made some useful comments
-% and pointers to alternative implementation using |\lusfunction|
+% and pointers to alternative implementation using |\luafunction|
% in the luatex list thread
% \texttt{http://tug.org/pipermail/luatex/2015-May/005199.html}
% For now keeping with the simpler initial approach as there
% is no built in support for |\luafunction| in the \LaTeX\ format yet.
-% (No allocator macros or hook to save function definition in the
-% format)
+% (No hook to save function definition in the format)
%
% \begin{macrocode}
%<*package>
@@ -132,8 +131,8 @@
\fi
% \end{macrocode}
%
-% If some package has defined an allocator for catcode tables
-% use it, othewise just use one (near) the top of the range (hex 7FFF).
+% Current latex formats (from 2015/11/01) define an allocator for catcode tables
+% otherwise just use one (near) the top of the range (hex 7FFF).
%
% \begin{macrocode}
\ifx\newcatcodetable\@undefined
@@ -149,9 +148,10 @@
% lua print function
% \begin{macrocode}
\directlua{%
+local nt = newtoken or token
function UcharcatLua()
- local mych = newtoken.scan_int()
- local mycat = newtoken.scan_int()
+ local mych = nt.scan_int()
+ local mycat = nt.scan_int()
tex.setcatcode(\the\numexpr\ucharcat@table\relax,mych,mycat)
tex.sprint(\the\numexpr\ucharcat@table\relax,unicode.utf8.char(mych))
end
diff --git a/Master/texmf-dist/tex/latex/ucharcat/ucharcat.sty b/Master/texmf-dist/tex/latex/ucharcat/ucharcat.sty
index 3a1a67fd5e5..e9f4e81396f 100644
--- a/Master/texmf-dist/tex/latex/ucharcat/ucharcat.sty
+++ b/Master/texmf-dist/tex/latex/ucharcat/ucharcat.sty
@@ -13,7 +13,7 @@
%% See README for details.
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{ucharcat}
- [2015/08/23 v0.02 ucharcat for luaLaTeX (DPC)]
+ [2015/11/19 v0.03 ucharcat for luaLaTeX (DPC)]
\ifx\directlua\@undefined
\ifx\Ucharcat\@undefined
\ifx\XeTeXinterchartokenstate\@undefined
@@ -36,9 +36,10 @@
\newcatcodetable\ucharcat@table
\fi
\directlua{%
+local nt = newtoken or token
function UcharcatLua()
- local mych = newtoken.scan_int()
- local mycat = newtoken.scan_int()
+ local mych = nt.scan_int()
+ local mycat = nt.scan_int()
tex.setcatcode(\the\numexpr\ucharcat@table\relax,mych,mycat)
tex.sprint(\the\numexpr\ucharcat@table\relax,unicode.utf8.char(mych))
end