diff options
author | Manuel Pégourié-Gonnard <mpg@elzevir.fr> | 2010-03-29 19:48:59 +0200 |
---|---|---|
committer | Manuel Pégourié-Gonnard <mpg@elzevir.fr> | 2010-03-29 19:48:59 +0200 |
commit | 303b484243e8600166e79486b564df0988a81c32 (patch) | |
tree | 92ef23343505c1cde0e933f74342785906d0d988 | |
parent | 94007e461a25a356ffb14832aedb91c832e07595 (diff) | |
download | luatexbase-303b484243e8600166e79486b564df0988a81c32.tar.gz |
Fix the way names are exported in mcb.
-rw-r--r-- | Changes | 13 | ||||
-rw-r--r-- | TODO | 2 | ||||
-rw-r--r-- | luatexbase-mcb.dtx | 22 |
3 files changed, 15 insertions, 22 deletions
@@ -1,11 +1,12 @@ Changes in the luatexbase package/bundle Summary of backwards-incompatible interface changes between 0.1 and 0.2: - - the luatex objects are now in table luatexbase, not luatextra - - the Lua tables tex.attributenumber and tex.catcodetablenumber are not + - Lua objects are now in table luatexbase, not luatextra. + - Lua tables tex.attributenumber and tex.catcodetablenumber are not created any more, use their couterparts in luatexbase. - - \luatexsetcatcoderange has been renamed to \setcatcoderange - - renamed luamcallbacks; Lua objects are now in luatexbase.mcb + - \luatexsetcatcoderange has been renamed to \setcatcoderange. + - luamcallbacks has been renamed; Lua objects are now in luatexbase, + no more in callback.* or luamcallbacks.* 2010/03/29 all @@ -23,7 +24,9 @@ Summary of backwards-incompatible interface changes between 0.1 and 0.2: - load lua-compat luamcallbacks -> luatexbase-mcb - rename package - - functions are now in luatexbase.mcb rather than luamcallbacks + - functions are now in luatexbase rather than luamcallbacks, they + are no more copied to callbacks either + - lua objects are now local (except for the public interface) - test file now for plain and latex luatexbase-loader - require"foo.bar" now looks for foo/bar then foo.bar, see doc for @@ -15,8 +15,6 @@ modutils mcallbacks ---------- -- Make more Lua objects local. -- Stop creating functions in the callback table ?! - Incorporate remaining bits from luatextra? - Enhance test file? - General review of code and comments. diff --git a/luatexbase-mcb.dtx b/luatexbase-mcb.dtx index 4b03ed6..e96a447 100644 --- a/luatexbase-mcb.dtx +++ b/luatexbase-mcb.dtx @@ -299,7 +299,7 @@ See source file '\inFileName' for details. % \subsubsection{Module identification} % % \begin{macrocode} -module('luatexbase.mcb', package.seeall) +module('luatexbase', package.seeall) luatexbase.provides_module({ name = "luamcallbacks", version = 0.93, @@ -781,19 +781,11 @@ function priority_in_callback (name, description) end % \end{macrocode} % -% Finally we add some functions to the \texttt{callback} module, and we +% Finally we % overwrite \texttt{callback.register} so that it outputs an error. % % \begin{macrocode} -callback.add = add_to_callback -callback.remove = remove_from_callback -callback.reset = reset_callback -callback.get_priority = priority_in_callback - -callback.create = create_callback -callback.call = call_callback - -callback.register = function (...) +callback.register = function () err("function callback.register has been deleted by luamcallbacks, " .."please use callback.add instead.") end @@ -830,11 +822,11 @@ end return head, true end - callback.add("hpack_filter",one,"my example function one",1) - callback.add("hpack_filter",two,"my example function two",2) - callback.add("hpack_filter",three,"my example function three",1) + luatexbase.add_to_callback("hpack_filter",one,"my sample function one",1) + luatexbase.add_to_callback("hpack_filter",two,"my sample function two",2) + luatexbase.add_to_callback("hpack_filter",three,"my sample function three",1) - callback.remove("hpack_filter","my example function three") + luatexbase.remove_from_callback("hpack_filter","my sample function three") } %</testplain,testlatex> %<testplain>\bye |