From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/65346 Path: news.gmane.org!not-for-mail From: "Verhaag, G.C.H.M." Newsgroups: gmane.comp.tex.context Subject: Re: How to run Typesetting in MetaPost example (MetaFun)? Date: Wed, 19 Jan 2011 14:35:27 +0100 Message-ID: <4D36E89F.3010208@ziggo.nl> References: <4D359A42.4030209@ziggo.nl> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1295443926 19645 80.91.229.12 (19 Jan 2011 13:32:06 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 19 Jan 2011 13:32:06 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Wed Jan 19 14:32:01 2011 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PfY8l-0006bN-PI for gctc-ntg-context-518@m.gmane.org; Wed, 19 Jan 2011 14:31:59 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id C28DBCAA09; Wed, 19 Jan 2011 14:31:58 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id ejV1pOsQAuFb; Wed, 19 Jan 2011 14:31:47 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 7D2F1CA9C1; Wed, 19 Jan 2011 14:31:47 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 1A33FCA9C1 for ; Wed, 19 Jan 2011 14:31:47 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id byrgLJ7rXILG for ; Wed, 19 Jan 2011 14:31:35 +0100 (CET) Original-Received: from filter2-nij.mf.surf.net (filter2-nij.mf.surf.net [195.169.124.153]) by balder.ntg.nl (Postfix) with ESMTP id 30E3CCA9BC for ; Wed, 19 Jan 2011 14:31:35 +0100 (CET) Original-Received: from smtpq3.tb.mail.iss.as9143.net (smtpq3.tb.mail.iss.as9143.net [212.54.42.166]) by filter2-nij.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id p0JD8p2n001737 for ; Wed, 19 Jan 2011 14:08:52 +0100 Original-Received: from [212.54.42.134] (helo=smtp3.tb.mail.iss.as9143.net) by smtpq3.tb.mail.iss.as9143.net with esmtp (Exim 4.71) (envelope-from ) id 1PfY8M-0004fc-AQ for ntg-context@ntg.nl; Wed, 19 Jan 2011 14:31:34 +0100 Original-Received: from 541c2cdc.cm-5-5a.dynamic.ziggo.nl ([84.28.44.220]) by smtp3.tb.mail.iss.as9143.net with esmtp (Exim 4.71) (envelope-from ) id 1PfY8L-0004jJ-G3 for ntg-context@ntg.nl; Wed, 19 Jan 2011 14:31:33 +0100 User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.8) Gecko/20050513 Debian/1.7.8-1 X-Accept-Language: en In-Reply-To: <4D359A42.4030209@ziggo.nl> X-ZiggoSMTP-MailScanner-Information: Please contact the ISP for more information X-ZiggoSMTP-MailScanner-ID: 1PfY8L-0004jJ-G3 X-ZiggoSMTP-MailScanner: Found to be clean X-ZiggoSMTP-MailScanner-SpamCheck: geen spam, SpamAssassin (niet cached, score=-1.722, vereist 5, ALL_TRUSTED -1.00, BAYES_00 -1.90, HELO_DYNAMIC_DHCP 0.21, RDNS_DYNAMIC 0.98, T_RP_MATCHES_RCVD -0.01) X-ZiggoSMTP-MailScanner-From: verhaaggchm@ziggo.nl X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=212.54.42.166; country=NL; region=05; city=Maastricht; latitude=50.8500; longitude=5.6833; http://maps.google.com/maps?q=50.8500,5.6833&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0aDVp8QF1 - bb43f5b5ef1b - 20110119 X-Scanned-By: CanIt (www . roaringpenguin . com) on 195.169.124.153 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:65346 Archived-At: Verhaag, G.C.H.M. wrote: > Hi, > > I wanted to try (using ConTeXt minimals MkIV) the example on page 228 > of the MetaFun manual, dealing with typesetting in MetaPost. > > The code is given as: > > \resetMPdrawing > \startMPdrawing > picture pic[] ; > numeric wid[], len[], pos[], n ; > wid[0] := len[0] := pos[0] := n := 0 ; > \stopMPdrawing > > \def\whatever#1% > {\appendtoks#1\to\MPtoks > \setbox\MPbox=\hbox{\bfd\the\MPtoks}% > \startMPdrawing > n := n + 1 ; len[n] := \the\wd\MPbox ; > \stopMPdrawing > \startMPdrawing[-] > pic[n] := textext("\bfd\setstrut\strut#1") ; > pic[n] := pic[n] shifted - llcorner pic[n] ; > \stopMPdrawing} > > \handletokens MetaPost is Fun!\with\whatever > > But is won't run. The following message is generated: > > \@@toks ->\MPtoks > > \dodoappendtoks ->\dodoglobal \@@toks > \@EAEAEA {\@EA \the \@EA \@@toks > \the ... > \whatever #1->\appendtoks #1\to \MPtoks > \setbox \MPbox =\hbox {\bfd > \the \MP... > \dodohandletokenstwo *#1->\dododohandletokens {#1} > \dohandletokens > M > etaPost is Fun! > \handletokens ...ndletokens {#2}\dohandletokens #1 > \end > l.96 \handletokens MetaPost is Fun!\with\whatever > > Anybody any idea? > > Regards, > Gerard Verhaag > ___________________________________________________________________________________ > > 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 > ___________________________________________________________________________________ > > Hi, I'm in need of help to get the example as described in the MetaFun manual running, because I want to use text around a path! So, I started reading the chapter about 'Typesetting in METAPOST' and wanted to try the examples as given in that chapter, but without succes! The problem seem to be the MPtoks macro. According to the text in this chapter this low level macro (and MPbox and appendtoks) are already defined, but are they really? The version of context minimals I use at the moment is: MTXrun | current version: 2011.01.18 19:34 Any suggestions are very much welcomed! Thanks in advance! Regards, Gerard ___________________________________________________________________________________ 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 ___________________________________________________________________________________