Hello, I'm looking for some stuff about calling MP from ConTeXt Lua. The only thing I found is a short reference at http://www.luatex.org/svn/trunk/manual/luatexref-t.pdf, but even when I read some basics (pages 79-83), I don't even know how to draw a line between two points. So I'd like to find a tutorial or examples or a deeper reference about how to call MP via Lua from ConTeXt. - Any idea? Cheers, Lukas
Am 23.09.2010 um 09:53 schrieb Procházka Lukáš:
Hello,
I'm looking for some stuff about calling MP from ConTeXt Lua.
The only thing I found is a short reference at http://www.luatex.org/svn/trunk/manual/luatexref-t.pdf, but even when I read some basics (pages 79-83), I don't even know how to draw a line between two points.
So I'd like to find a tutorial or examples or a deeper reference about how to call MP via Lua from ConTeXt. - Any idea?
You don’t have to think so complicated: \starttext \startluacode context.startMPpage() context("draw fullcircle scaled 2cm;") context.stopMPpage \stopluacode \stoptext See also http://pragma-ade.com/show-man-44.htm Wolfgang
On 2010-09-23 <09:53:38>, Procházka Lukáš wrote:
So I'd like to find a tutorial or examples or a deeper reference about how to call MP via Lua from ConTeXt. - Any idea?
Hi Lukáš, this doesn't seem to be implemented yet, cf. this post: http://archive.contextgarden.net/message/20100805.225554.4212c0c8.en.html for now, as Wolfgang suggested, the “building strings and passing them to context.MPdrawing()” method works acceptably if you define yourself some wrapper functions. But maybe Hans already has some prototype for a Metapost-Context interface in his drawer … Regards, Philipp -- () ascii ribbon campaign - against html e-mail /\ www.asciiribbon.org - against proprietary attachments
Thanks for the answers to all...
It seems that I'm trying to do similar things as someone else was trying before -
- use of "context.MPdrawing()" looks best at the moment. Maybe it will become "deprecated" as soon as Lua involves MP.
Best,
Lukas
On Thu, 23 Sep 2010 10:20:23 +0200, Philipp Gesang
On 2010-09-23 <09:53:38>, Procházka Lukáš wrote:
So I'd like to find a tutorial or examples or a deeper reference about how to call MP via Lua from ConTeXt. - Any idea?
Hi Lukáš,
this doesn't seem to be implemented yet, cf. this post: http://archive.contextgarden.net/message/20100805.225554.4212c0c8.en.html for now, as Wolfgang suggested, the “building strings and passing them to context.MPdrawing()” method works acceptably if you define yourself some wrapper functions.
But maybe Hans already has some prototype for a Metapost-Context interface in his drawer …
Regards, Philipp
On 23-9-2010 10:35, Procházka Lukáš wrote:
Thanks for the answers to all...
It seems that I'm trying to do similar things as someone else was trying before -
- use of "context.MPdrawing()" looks best at the moment. Maybe it will become "deprecated" as soon as Lua involves MP.
it is unlikely to become deprecated Hans ----------------------------------------------------------------- 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 -----------------------------------------------------------------
participants (5)
-
Hans Hagen
-
luigi scarso
-
Philipp Gesang
-
Procházka Lukáš
-
Wolfgang Schuster