Re: Two-part @Graphic vs. xsize etc
Jeff Kingston <[email protected]> Fri, 7 Mar 2014 07:22:28 +1100
| Newsgroups | gmane.comp.type-setting.lout |
|---|---|
| Message-ID | <[email protected]> |
> I have stumbled into a problem with two-part left parameter of
> @Graphic. When the second part is emitted the values of xsize etc
> might have been overwritten by nested calls to @Graphic inside the
> right parameter.
Or you could push a dict in the first part and pop it in the
second part. I think it's fair to ask anyone who is using
two-part left parameters of @Graphic to handle this kind of
thing themselves.
Here's what I did in @Diag to get the graphics state of the
left parameter to affect the object to the right, a kind of
opposite of what is wanted here:
# Like @Graphic, but affects the graphics state of right parameter
def @InnerGraphic
left ps
right x
{
{ ps gsave // grestore } @Graphic x
}
Jeff