Re: [NTG-context] Reset environment between MetaPost graphics?

2022-01-21 Thread Vincent Hennebert via ntg-context
On Thu, 2022-01-20 at 15:47 +0100, Hans Hagen via ntg-context wrote: > On 1/20/2022 3:26 PM, Aditya Mahajan via ntg-context wrote: > > > AFAIK, there is no in-built support for this. > > FYEO: > > \starttext > > \startMPcode > u = 123; > \stopMPcode > >

Re: [NTG-context] Reset environment between MetaPost graphics?

2022-01-20 Thread Hans Hagen via ntg-context
On 1/20/2022 3:42 PM, Hans Hagen via ntg-context wrote: next upload: \resetMPinstance[metafun:1] but try to avoid this because reloading takes time Hans - Hans Hagen | PRAGMA ADE

Re: [NTG-context] Reset environment between MetaPost graphics?

2022-01-20 Thread Hans Hagen via ntg-context
On 1/20/2022 3:26 PM, Aditya Mahajan via ntg-context wrote: AFAIK, there is no in-built support for this. FYEO: \starttext \startMPcode u = 123; \stopMPcode \ctxlua{metapost.reset("metafun:1")} \startMPcode u = 123; \stopMPcode \stoptext (the instance is reported on the console)

Re: [NTG-context] Reset environment between MetaPost graphics?

2022-01-20 Thread Hans Hagen via ntg-context
On 1/20/2022 2:59 PM, Vincent Hennebert via ntg-context wrote: Hi, Say I’m writing a document containing many independent MetaPost figures. I don’t want to bother with enclosing each and every graphics in a ‘begingroup...endgroup’ with the appropriate ‘save’ statement. But I don’t want

Re: [NTG-context] Reset environment between MetaPost graphics?

2022-01-20 Thread Aditya Mahajan via ntg-context
On Thu, 20 Jan 2022, Vincent Hennebert via ntg-context wrote: > Hi, > > Say I’m writing a document containing many independent MetaPost > figures. I don’t want to bother with enclosing each and every graphics > in a ‘begingroup...endgroup’ with the appropriate ‘save’ statement. But > I don’t

[NTG-context] Reset environment between MetaPost graphics?

2022-01-20 Thread Vincent Hennebert via ntg-context
Hi, Say I’m writing a document containing many independent MetaPost figures. I don’t want to bother with enclosing each and every graphics in a ‘begingroup...endgroup’ with the appropriate ‘save’ statement. But I don’t want variables from previous graphics to leak into following ones either.