On 2013–02–14 Hans Hagen wrote:
I know that MPinclusions are included only once and MPinitializations are included once for each graphic. But how do MPextensions fit in?
How can I define variables or definitions that are local to a particular MP instance?
by defining a new instance
I guess I didn't make myself clear. \startMPinitializations numeric n; n=4cm; \stopMPinitializations Now I can use “n” in all MP instances (unless switched off for the particular instance). I'd like to define some variables only visible in instance “foo”. Something like \startMPinitializations [foo] numeric n; n=4cm; \stopMPinitializations I tried \startMPcode{foo} numeric n; n=4cm; \stopMPcode but this adds some vertical space and doesn't seem to be the right solution given the face that there are already three other environments to include MetaPost code. Maybe I'm missing the obvious here. Marco