summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2013-08-08 23:28:29 +0000
committerKarl Berry <karl@freefriends.org>2013-08-08 23:28:29 +0000
commit8615246bec536d5eb6457dbd01308c1766ef7d7e (patch)
treec891af30d907b8f8cacbac0c0129731212ce7708 /Master/texmf-dist/source
parent1cc0c8d0188da1ffc08a7fa8ce625427f36cecc6 (diff)
lualatex-math (8aug13)
git-svn-id: svn://tug.org/texlive/trunk@31389 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source')
-rw-r--r--Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.dtx38
-rw-r--r--Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.ins6
2 files changed, 28 insertions, 16 deletions
diff --git a/Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.dtx b/Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.dtx
index aad394b9896..ce72e35d7d2 100644
--- a/Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.dtx
+++ b/Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.dtx
@@ -244,12 +244,12 @@
%<@@=lltxmath>
\NeedsTeXFormat{LaTeX2e}[2009/09/24]
\RequirePackage{expl3}[2012/08/14]
-\ProvidesExplPackage{lualatex-math}{2013/01/13}{1.2}%
+\ProvidesExplPackage{lualatex-math}{2013/08/03}{1.3}%
{Patches for mathematics typesetting with LuaLaTeX}
\RequirePackage { etoolbox } [ 2007/10/08 ]
\RequirePackage { luatexbase } [ 2010/05/27 ]
\RequirePackage { filehook } [ 2011/03/09 ]
-\RequireLuaModule { lualatex-math } [ 2011/05/05 ]
+\RequireLuaModule { lualatex-math } [ 2013/08/03 ]
% \end{macrocode}
%
% \begin{macro}{\@@_restore_catcode:N}
@@ -935,25 +935,34 @@
%
% \section{Implementation of the \hologo{LuaLaTeX} module}
%
-% For the Lua module, we use the standard \pkg{luatexbase-modutils} template
-% and the \func{module} function.
+% For the Lua module, we use the standard \pkg{luatexbase-modutils} template.
+% \changes{v1.3}{2013/08/03}{Stop using the deprecated \func{module} function}
% \begin{macrocode}
%<*lua>
require("luatexbase.modutils")
require("luatexbase.cctb")
+lualatex = lualatex or {}
+lualatex.math = lualatex.math or {}
local err, warn, info, log = luatexbase.provides_module({
name = "lualatex-math",
- date = "2011/05/05",
- version = 0.1,
+ date = "2013/08/03",
+ version = 1.3,
description = "Patches for mathematics typesetting with LuaLaTeX",
author = "Philipp Stephani",
licence = "LPPL v1.3+"
})
-local unpack = unpack
-local string = string
-local tex = tex
+% \end{macrocode}
+% \begin{function}{unpack}
+% \changes{v1.3}{2013/08/03}{Integrate Philipp Gesang’s patch to make the
+% \func{unpack} function compatible with Lua~5.2}
+% The function \func{unpack} needs to be treated specially as it got moved
+% around in Lua~5.2.
+% \begin{macrocode}
+local unpack = unpack or table.unpack
+% \end{macrocode}
+% \end{function}
+% \begin{macrocode}
local cctb = luatexbase.catcodetables
-module("lualatex.math")
% \end{macrocode}
%
% \begin{function}{print_fam_slot}
@@ -963,7 +972,7 @@ module("lualatex.math")
% \meta{family}\texttt{\textvisiblespace}\meta{slot}, suitable for the
% right-hand side of \eg \verb|\fontcharht\textfont|.
% \begin{macrocode}
-function print_fam_slot(char)
+function lualatex.math.print_fam_slot(char)
local code = tex.getmathcode(char)
local class, family, slot = unpack(code)
local result = string.format("%i %i ", family, slot)
@@ -979,15 +988,18 @@ end
% \meta{class}\texttt{\textvisiblespace}\meta{family}\texttt{\textvisiblespace}\meta{slot},
% suitable for the right-hand side of \cmd{\Umathchardef}.
% \begin{macrocode}
-function print_class_fam_slot(char)
+function lualatex.math.print_class_fam_slot(char)
local code = tex.getmathcode(char)
local class, family, slot = unpack(code)
local result = string.format("%i %i %i ", class, family, slot)
tex.sprint(cctb.string, result)
end
-%</lua>
% \end{macrocode}
% \end{function}
+% \begin{macrocode}
+return lualatex.math
+%</lua>
+% \end{macrocode}
%
%
% \section{Test files}
diff --git a/Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.ins b/Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.ins
index ddb6c0b28be..7424ea3a49e 100644
--- a/Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.ins
+++ b/Master/texmf-dist/source/lualatex/lualatex-math/lualatex-math.ins
@@ -1,5 +1,5 @@
% lualatex-math.ins
-% Copyright 2011, 2012 Philipp Stephani
+% Copyright 2011, 2012, 2013 Philipp Stephani
%
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either
@@ -26,7 +26,7 @@
This is a generated file.
-Copyright 2011, 2012 Philipp Stephani
+Copyright 2011, 2012, 2013 Philipp Stephani
This file may be distributed and/or modified under the
conditions of the LaTeX Project Public License, either
@@ -57,7 +57,7 @@ LaTeX version 2009/09/24 or later.
This is a generated file.
-Copyright 2011, 2012 Philipp Stephani
+Copyright 2011, 2012, 2013 Philipp Stephani
This file may be distributed and/or modified under the
conditions of the LaTeX Project Public License, either