On 4/11/2024 5:07 PM, Pablo Rodriguez via ntg-context wrote:
On 4/10/24 21:48, Hans Hagen via ntg-context wrote:
On 4/10/2024 7:49 PM, Pablo Rodriguez via ntg-context wrote:
[...] I wonder whether there is a proper way in the Lua code to avoid [[\luaescapestring{}]] in \ctxlua. [...] context(tokens.scanners.string())
Many thanks for your reply, Hans.
\protected\def\PrintTheThing{\ctxlua{document.print_the_thing()}}
Sorry, but why \protected is required or recommended here?
depends if you want it to be expandable ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl -----------------------------------------------------------------