Re: [NTG-context] Save/Redraw labels as pictures

2012-12-09 Thread Troy Henderson

 vardef J = thelabel(textext(J) scaled 2,origin) enddef ;


That will work!

Troy
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Save/Redraw labels as pictures

2012-12-08 Thread Alan BRASLAU
Hans has be playing with MetaPost instances which got broken.

\startMPpage\stopMPpage got the wrong instance
whereas \startTEXpage\startMPcode\stopMPcode\stopMPpage correctly got
the default instance.

Normally, this was fixed, but your minimal example still does not
work for me either. Something else is at cause...

The reasons Hans has modified MP instances are:
1. we wanted to isolate the chemistry drawing macros from other MP use,
but not from the user, and
2. we uncovered an error with mlib when using a very great number of
MP pictures.

Alan 




On Sat, 8 Dec 2012 05:42:43 -0600
Troy Henderson thend...@gmail.com wrote:

 The following code produces the letter J on the first page, but
 does not draw that same picture on the second page.  I would
 appreciate some advice on how to save and redraw this label in
 subsequence figures.
 
 Thanks,
 
 Troy Henderson
 
 \starttext
 \startMPinclusions[+]
 picture J;
 \stopMPinclusions
 \startMPpage
 J:=thelabel(btex J etex scaled 2,origin);
 draw J;
 \stopMPpage
 \startMPpage
 draw J;
 \stopMPpage
 \stoptext

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Save/Redraw labels as pictures

2012-12-08 Thread Troy Henderson

 Hans has be playing with MetaPost instances which got broken.


Well I am running MKIV included in TeX Live 2012.

Troy
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Save/Redraw labels as pictures

2012-12-08 Thread Hans Hagen

On 12/8/2012 12:42 PM, Troy Henderson wrote:

The following code produces the letter J on the first page, but does
not draw that same picture on the second page.  I would appreciate some
advice on how to save and redraw this label in subsequence figures.

Thanks,

Troy Henderson

\starttext
 \startMPinclusions[+]
 picture J;
 \stopMPinclusions
 \startMPpage
 J:=thelabel(btex J etex scaled 2,origin);
 draw J;
 \stopMPpage
 \startMPpage
 draw J;
 \stopMPpage
\stoptext


\starttext
\startMPinclusions[+]
vardef J = thelabel(textext(J) scaled 2,origin) enddef ;
\stopMPinclusions
\startMPpage
draw J;
\stopMPpage
\startMPpage
draw J;
\stopMPpage
\stoptext

as text in handled at the tex end it is lost after graphic is done; 
imlemeno it ting selective persistence is possible but messy; maybe some 
day i'll do it


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___