diff options
author | Karl Berry <karl@freefriends.org> | 2009-04-12 23:15:36 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2009-04-12 23:15:36 +0000 |
commit | 1a87640a25a3cf2bf77b1cb9c69e3c90f2b3811b (patch) | |
tree | 5a6eb1ac516775c93f354fba92bddca5de94c078 /Master/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty | |
parent | b4c2a162bb8aa0937f3c029e5e103055f55ae3ae (diff) |
oberdiek update (12apr09)
git-svn-id: svn://tug.org/texlive/trunk@12705 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty')
-rw-r--r-- | Master/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty | 30 |
1 files changed, 23 insertions, 7 deletions
diff --git a/Master/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty b/Master/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty index 6ff76866446..59a32176aac 100644 --- a/Master/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty +++ b/Master/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty @@ -78,6 +78,9 @@ \else \def\x#1#2[#3]{\endgroup #2[{#3}]% + \ifx#1\@undefined + \xdef#1{#3}% + \fi \ifx#1\relax \xdef#1{#3}% \fi @@ -85,7 +88,7 @@ \fi \expandafter\x\csname ver@pdftexcmds.sty\endcsname \ProvidesPackage{pdftexcmds}% - [2007/12/12 v0.3 LuaTeX support for pdfTeX utility functions (HO)] + [2009/04/10 v0.4 LuaTeX support for pdfTeX utility functions (HO)] \begingroup \catcode123 1 % { \catcode125 2 % } @@ -127,15 +130,18 @@ \TMP@EnsureCode{62}{12}% > \TMP@EnsureCode{94}{7}% ^ (superscript) \TMP@EnsureCode{95}{12}% _ (other) +\TMP@EnsureCode{96}{12}% ` \TMP@EnsureCode{126}{12}% ~ (other) \begingroup\expandafter\expandafter\expandafter\endgroup \expandafter\ifx\csname RequirePackage\endcsname\relax \input infwarerr.sty\relax + \input ifluatex.sty\relax \else \RequirePackage{infwarerr}[2007/09/09]% + \RequirePackage{ifluatex}[2009/04/10]% \fi -\begingroup\expandafter\expandafter\expandafter\endgroup -\expandafter\ifx\csname directlua\endcsname\relax +\ifluatex +\else \@PackageInfo{pdftexcmds}{LuaTeX not detected}% \def\pdftexcmds@nopdftex{% \@PackageInfoNoLine{pdftexcmds}{pdfTeX >= 1.30 not detected}% @@ -191,13 +197,18 @@ \pdftexcmds@AtEnd \expandafter\endinput \fi +\ifnum\luatexversion<36 % + \def\pdftexcmds@directlua{\directlua0 }% +\else + \let\pdftexcmds@directlua\directlua +\fi \begingroup\expandafter\expandafter\expandafter\endgroup \expandafter\ifx\csname RequirePackage\endcsname\relax \input luatex-loader.sty\relax \else - \RequirePackage{luatex-loader}[2007/12/12]% + \RequirePackage{luatex-loader}[2009/04/10]% \fi -\directlua0{% +\pdftexcmds@directlua{% require("oberdiek.pdftexcmds")% } \begingroup\expandafter\expandafter\expandafter\endgroup @@ -206,6 +217,10 @@ \else \csname newtoks\endcsname\pdftexcmds@toks \fi +\ifnum\luatexversion<36 % +\else + \catcode`\0=9 % +\fi \long\def\pdf@strcmp#1#2{% \directlua0{% oberdiek.pdftexcmds.strcmp("\luaescapestring{#1}",% @@ -303,8 +318,9 @@ oberdiek.pdftexcmds.lastsystemexit()% }% } +\catcode`\0=12 % \ifnum0% - \directlua0{% + \pdftexcmds@directlua{% if io.popen then % tex.write("1")% end% @@ -312,7 +328,7 @@ =1 % \def\pdf@pipe#1{% \the\expandafter\pdftexcmds@toks - \directlua0{% + \pdftexcmds@directlua{% oberdiek.pdftexcmds.toks="pdftexcmds@toks"% oberdiek.pdftexcmds.pipe("\luaescapestring{#1}")% }% |