diff options
Diffstat (limited to 'Master/texmf-dist/tex/luatex/luatextra/luatextra.sty')
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatextra/luatextra.sty | 57 |
1 files changed, 43 insertions, 14 deletions
diff --git a/Master/texmf-dist/tex/luatex/luatextra/luatextra.sty b/Master/texmf-dist/tex/luatex/luatextra/luatextra.sty index db4acd9aa27..090e821a509 100644 --- a/Master/texmf-dist/tex/luatex/luatextra/luatextra.sty +++ b/Master/texmf-dist/tex/luatex/luatextra/luatextra.sty @@ -25,33 +25,37 @@ \fi \else \RequirePackage{ifluatex} + \NeedsTeXFormat{LaTeX2e} + \ProvidesPackage{luatextra} + [2009/12/16 v0.95 LuaTeX extra low-level macros] + \RequirePackage{etex}[1998/03/26] \fi -\expandafter\ifx\csname ProvidesPackage\endcsname\relax - \ifluatex\else + +\def\LuaTeX{Lua\TeX } +\def\LuaLaTeX{Lua\LaTeX } + + +\ifluatex\else + \expandafter\ifx\csname ProvidesPackage\endcsname\relax \immediate\write16{} - \errmessage{Package luatextra Error: This package must be used with LuaTeX} + \immediate\write16{Package luatextra Warning: this package should be used with LuaTeX.} + \else + \PackageWarning{luatextra}{this package should be used with LuaTeX.} \fi + \expandafter\endinput +\fi + +\expandafter\ifx\csname ProvidesPackage\endcsname\relax \def\luatexRequireModule#1#2{\luadirect{luatextra.require_module([[#1]], [[#2]])}} \else - \ifluatex\else - \PackageError{luatextra}{This package must be used with LuaTeX.} - \fi - \NeedsTeXFormat{LaTeX2e} - \ProvidesPackage{luatextra} - [2009/04/15 v0.93 LuaTeX extra low-level macros] \RequirePackage{environ} \NewEnviron{luacode}{\luadirect{\BODY}} \newcommand\luatexRequireModule[2][0]{\luadirect{luatextra.require_module([[#2]], [[#1]])}} - \RequirePackage{etex}[1998/03/26]% \input luatextra-latex.tex \fi -\def\LuaTeX{Lua\TeX } -\def\LuaLaTeX{Lua\LaTeX } - - \ifnum\luatexversion<36 \def\directlua{\pdfprimitive\directlua0} \def\latelua{\pdfprimitive\latelua0} @@ -189,6 +193,8 @@ See the module #1 documentation for explanation.^^J ...^^J}% \newluatexcatcodetable\CatcodeTableString \newluatexcatcodetable\CatcodeTableOther \newluatexcatcodetable\CatcodeTableLaTeX +\newluatexcatcodetable\CatcodeTableLaTeXAtLetter +\newluatexcatcodetable\CatcodeTableExpl \initluatexcatcodetable\CatcodeTableIniTeX \expandafter\ifx\csname @firstofone\endcsname\relax @@ -215,6 +221,27 @@ See the module #1 documentation for explanation.^^J ...^^J}% \catcode126=13 % tilde \catcode127=15 % \saveluatexcatcodetable\CatcodeTableLaTeX + \catcode64=11 % + \saveluatexcatcodetable\CatcodeTableLaTeXAtLetter + \endgroup + \begingroup + \luatexsetcatcoderange{0}{8}{15}% + \catcode9=9 % tab ignored + \catcode11=15 % + \catcode12=13 % form feed + \luatexsetcatcoderange{14}{31}{15}% + \catcode32=9 % space is ignored + \catcode35=6 % hash mark is macro parameter character + \catcode36=3 % dollar (not so sure about the catcode...) + \catcode38=4 % ampersand + \catcode58=11 % colon letter + \catcode94=7 % circumflex is superscript character + \catcode95=11 % underscore letter + \catcode123=1 % left brace is begin-group character + \catcode125=2 % right brace is end-group character + \catcode126=10 % tilde is a space char. + \catcode127=15 % + \saveluatexcatcodetable\CatcodeTableExpl \endgroup \@makeother{0}% nul \@makeother{13}% carriage return @@ -231,6 +258,8 @@ See the module #1 documentation for explanation.^^J ...^^J}% \ltxtra@AtEnd +\luadirect{luatextra.catcodetable_do_shortcuts()} + \let\newluaattribute\newluatexattribute \let\luaattribute\luatexattribute |