diff options
author | Hans Hagen <pragma@wxs.nl> | 2023-01-04 12:09:26 +0100 |
---|---|---|
committer | Context Git Mirror Bot <phg@phi-gamma.net> | 2023-01-04 12:09:26 +0100 |
commit | 705b807c950a697d3c8be592c452a6fb3e561c7e (patch) | |
tree | 82904661aca945d008f07deb568ee7f05b55df4f /tex/context/base/mkxl/mlib-lmp.lmt | |
parent | 62d980c99a617ff260f29ac2d3bdb084049f25b0 (diff) | |
download | context-705b807c950a697d3c8be592c452a6fb3e561c7e.tar.gz |
2023-01-04 11:35:00
Diffstat (limited to 'tex/context/base/mkxl/mlib-lmp.lmt')
-rw-r--r-- | tex/context/base/mkxl/mlib-lmp.lmt | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/tex/context/base/mkxl/mlib-lmp.lmt b/tex/context/base/mkxl/mlib-lmp.lmt index a6d17dd2c..db23fcede 100644 --- a/tex/context/base/mkxl/mlib-lmp.lmt +++ b/tex/context/base/mkxl/mlib-lmp.lmt @@ -216,14 +216,19 @@ do end end) - -- + -- older: - local mpprint = mp.print - local mpquoted = mp.quoted - local getmacro = tokens.getters.macro + registerscript("texvar", function() + if not expandtex(unknown_value,"mpcategoryparameter",true,scanstring()) then + injectnumeric(0) + end + end) - registerscript("texvar", function() mpprint (getmacro(metapost.namespace .. scanstring())) end) - registerscript("texstr", function() mpquoted(getmacro(metapost.namespace .. scanstring())) end) + registerscript("texstr", function() + if not expandtex(string_value,"mpcategoryparameter",true,scanstring()) then + injectstring("") + end + end) end |