diff options
author | Hans Hagen <pragma@wxs.nl> | 2009-05-28 11:23:00 +0200 |
---|---|---|
committer | Hans Hagen <pragma@wxs.nl> | 2009-05-28 11:23:00 +0200 |
commit | 1d3090326210c6e6f7ec5432799ded25b75bba46 (patch) | |
tree | c5921203789ec669e6bccaba4bd56f9c072dc56b /tex/context/base/syst-str.mkiv | |
parent | 94d83f84758766511c5e324721e39fea6ab71dae (diff) | |
download | context-1d3090326210c6e6f7ec5432799ded25b75bba46.tar.gz |
beta 2009.05.28 11:23
Diffstat (limited to 'tex/context/base/syst-str.mkiv')
-rw-r--r-- | tex/context/base/syst-str.mkiv | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tex/context/base/syst-str.mkiv b/tex/context/base/syst-str.mkiv index db3389ec0..57d76dc03 100644 --- a/tex/context/base/syst-str.mkiv +++ b/tex/context/base/syst-str.mkiv @@ -13,8 +13,17 @@ \unprotect +% nb: these macros might go away ! +% % todo: escape special chars in expr (\luaescapeexpression) +%D I got tired of making dedicated clean up macros using the +%D same mechanism again and again, so now we have: +%D +%D \starttyping +%D \def\xxxx{abc.d} \replacecharacters\xxxx{a.}{-} \xxxx +%D \stoptyping + \def\replacecharacters#1#2#3% macro characters replacement {\dodoglobal\edef#1{\ctxlua{tex.sprint((string.gsub(\!!bs#1\!!es,\!!bs#2\!!es,"#3")))}}} |