ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* reusing metapost graphics
@ 2003-03-20  6:26 Matthew Huggett
  2003-03-20  8:53 ` scaling " Patrick Gundlach
  2003-03-20  9:40 ` reusing " Hans Hagen
  0 siblings, 2 replies; 3+ messages in thread
From: Matthew Huggett @ 2003-03-20  6:26 UTC (permalink / raw)


Hi:

I'm designing a year's worth of English lessons for some Japanese kids, 
and I'm using Metapost and ConTeXt to generate flashcards for vocabulary 
training.  I have a few questions:
(1) I want to keep my Metapost figures defined in a ConTeXt environment 
file so that I can recall them as I need in future lessons.  Is there 
anything wrong with this approach?
(2) How do I make a Metapost figure defined in a ConTeXt file reusable? 
 Do I need to wrap the definition of the figure in a macro so that the 
figure is recreated everytime I need it?
(3) With \useMPgraphic, is there any mechanism to scale the image as 
with \useexternalfigure?

If this is all in the documentation, I apologize.  (I would appreciate a 
pointer to the documentation though :-) )

^ permalink raw reply	[flat|nested] 3+ messages in thread

* scaling metapost graphics
  2003-03-20  6:26 reusing metapost graphics Matthew Huggett
@ 2003-03-20  8:53 ` Patrick Gundlach
  2003-03-20  9:40 ` reusing " Hans Hagen
  1 sibling, 0 replies; 3+ messages in thread
From: Patrick Gundlach @ 2003-03-20  8:53 UTC (permalink / raw)


Matthew Huggett <mhuggett@zam.att.ne.jp> writes:

Hello,

let's start with #3

> (3) With \useMPgraphic, is there any mechanism to scale the image as
>     with \useexternalfigure?


\placefigure [right]{none}{\scale[sx=.6,sy=.6]{\useMPgraphic{....}}}


> If this is all in the documentation, I apologize.  (I would appreciate
> a pointer to the documentation though :-) )

it is somewhere I guess ;-)

Patrick

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: reusing metapost graphics
  2003-03-20  6:26 reusing metapost graphics Matthew Huggett
  2003-03-20  8:53 ` scaling " Patrick Gundlach
@ 2003-03-20  9:40 ` Hans Hagen
  1 sibling, 0 replies; 3+ messages in thread
From: Hans Hagen @ 2003-03-20  9:40 UTC (permalink / raw)


At 03:26 PM 3/20/2003 +0900, you wrote:
>Hi:
>
>I'm designing a year's worth of English lessons for some Japanese kids, 
>and I'm using Metapost and ConTeXt to generate flashcards for vocabulary 
>training.  I have a few questions:
>(1) I want to keep my Metapost figures defined in a ConTeXt environment 
>file so that I can recall them as I need in future lessons.  Is there 
>anything wrong with this approach?

sounds ok to me

>(2) How do I make a Metapost figure defined in a ConTeXt file reusable? Do 
>I need to wrap the definition of the figure in a macro so that the figure 
>is recreated everytime I need it?

see patricks answer; in addition to that: external figures are reused by 
default

\startreusableMPgraphic{abc}

\stopreusableMPgraphic

\placefigure{]{\reuseMPgraphic{abc}}

will also be reused

>(3) With \useMPgraphic, is there any mechanism to scale the image as with 
>\useexternalfigure?

see patricks answer

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-03-20  9:40 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-03-20  6:26 reusing metapost graphics Matthew Huggett
2003-03-20  8:53 ` scaling " Patrick Gundlach
2003-03-20  9:40 ` reusing " Hans Hagen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).