From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/65438 Path: news.gmane.org!not-for-mail From: Peter Rolf Newsgroups: gmane.comp.tex.context Subject: Re: metafun- how to pass array as an argument Date: Mon, 24 Jan 2011 13:50:02 +0100 Message-ID: <4D3D757A.8040307@gmx.net> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1295873413 14989 80.91.229.12 (24 Jan 2011 12:50:13 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 24 Jan 2011 12:50:13 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Mon Jan 24 13:50:07 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 1PhLrz-0000Qn-7v for gctc-ntg-context-518@m.gmane.org; Mon, 24 Jan 2011 13:50:07 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id B37A1CA952; Mon, 24 Jan 2011 13:50:06 +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 gRrbTQS5g7jZ; Mon, 24 Jan 2011 13:50:04 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 4410FCA955; Mon, 24 Jan 2011 13:50:04 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 75168CA955 for ; Mon, 24 Jan 2011 13:50:03 +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 rcV6MQCM--9D for ; Mon, 24 Jan 2011 13:50:01 +0100 (CET) Original-Received: from filter1-til.mf.surf.net (filter1-til.mf.surf.net [194.171.167.217]) by balder.ntg.nl (Postfix) with ESMTP id 528CFCA952 for ; Mon, 24 Jan 2011 13:50:01 +0100 (CET) Original-Received: from mailout-de.gmx.net (mailout-de.gmx.net [213.165.64.22]) by filter1-til.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with SMTP id p0OCnxFg020010 for ; Mon, 24 Jan 2011 13:49:59 +0100 Original-Received: (qmail invoked by alias); 24 Jan 2011 12:49:59 -0000 Original-Received: from ip-178-200-60-214.unitymediagroup.de (EHLO [192.168.178.3]) [178.200.60.214] by mail.gmx.net (mp048) with SMTP; 24 Jan 2011 13:49:59 +0100 X-Authenticated: #24293357 X-Provags-ID: V01U2FsdGVkX1/WIPhfApnWQKrdzWGtBjuhPg0QYgUN9f7d97+dKr SnlsOdGSFmzI0i User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.9.2.13) Gecko/20101207 Lightning/1.0b2 Mnenhy/0.8.3 Thunderbird/3.1.7 In-Reply-To: X-Enigmail-Version: 1.1.1 X-Y-GMX-Trusted: 0 X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=213.165.64.22; country=DE; latitude=51.0000; longitude=9.0000; http://maps.google.com/maps?q=51.0000,9.0000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 08DXoNXTv - 6dc32ad44548 - 20110124 X-Scanned-By: CanIt (www . roaringpenguin . com) on 194.171.167.217 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:65438 Archived-At: Am 24.01.2011 13:18, schrieb dalyoung: > \startbuffer[a] > path p; > numeric bwidth, u, lastpoint; > u :=1cm; > p := fullcircle scaled .3u; > lastpoint := 0; > > def draw_balls = %(expr s) def draw_balls(text s) = > draw (0,0) -- (0, u); > for i=3,5,0,2,1,7: for i=s: > for j = 1 upto i: > draw p shifted (lastpoint+.32*j*u,.3u); > endfor; > bwidth := .32i*u+.5u; > draw (lastpoint,0) -- (lastpoint +bwidth,0) -- (lastpoint +bwidth,u); > lastpoint := lastpoint+bwidth; > endfor; > enddef; > > draw_balls; > > \stopbuffer > > \starttext > \processMPbuffer[a] > \stoptext works in mkii, but fails in mkiv. i use an outdated version (31.12.2010) here. ! LuaTeX error
:1: attempt to call field 'feedback' (a nil value) stack traceback:
:1: in main chunk. ....feedback("\currentMPgraphicname ")} \processMPgraphic ...ntMPgraphicformat ", \!!bs #1 ;\!!es , \!!bs \currentMPi... ...feedback("\currentMPgraphicname ")}} \endMPgraphicgroup \secondoftwoarguments #1#2->#2 l.25 \processMPbuffer[a] ? best wishes, Peter ___________________________________________________________________________________ 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 ___________________________________________________________________________________