From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/14556 Path: main.gmane.org!not-for-mail From: Willi Egger Newsgroups: gmane.comp.tex.context Subject: Strange behaviour? Metapost om connection with MPpage Date: Fri, 16 Jan 2004 23:45:06 +0100 Sender: ntg-context-admin@ntg.nl Message-ID: <40086972.6010608@boede.nl> Reply-To: ntg-context@ntg.nl NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------060601000802000709030508" X-Trace: sea.gmane.org 1074293179 27225 80.91.224.253 (16 Jan 2004 22:46:19 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 16 Jan 2004 22:46:19 +0000 (UTC) Original-X-From: ntg-context-admin@ntg.nl Fri Jan 16 23:46:16 2004 Return-path: Original-Received: from ref.vet.uu.nl ([131.211.172.13] helo=ref.ntg.nl) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AhcjI-0008TZ-00 for ; Fri, 16 Jan 2004 23:46:16 +0100 Original-Received: from ref.ntg.nl (localhost.localdomain [127.0.0.1]) by ref.ntg.nl (Postfix) with ESMTP id 7D96310B21; Fri, 16 Jan 2004 23:45:26 +0100 (MET) Original-Received: from smtpzilla2.xs4all.nl (smtpzilla2.xs4all.nl [194.109.127.138]) by ref.ntg.nl (Postfix) with ESMTP id 8E89210AFC for ; Fri, 16 Jan 2004 23:44:18 +0100 (MET) Original-Received: from boede.nl (a80-126-172-1.adsl.xs4all.nl [80.126.172.1]) by smtpzilla2.xs4all.nl (8.12.10/8.12.10) with ESMTP id i0GMj3VP054369 for ; Fri, 16 Jan 2004 23:45:04 +0100 (CET) User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5) Gecko/20031013 Thunderbird/0.3 X-Accept-Language: en-us, en Original-To: NTG-Context Errors-To: ntg-context-admin@ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.0.13 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.comp.tex.context:14556 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:14556 This is a multi-part message in MIME format. --------------060601000802000709030508 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Hi all, Currently I am preparing a series of figures. I use the approach given in Metafun: \startuseMPgraphic{test} ... code ... \stopuseMPgraphic \starttext \startMPpage \includeMPgraphic{test} \stopMPpage % \useMPgraphic \stoptext The appended code does compile if the MPpage lines are commented. and useMPgraphic is uncommented. Otherwise the following error is given: ! Missing `,' has been inserted. : gluedraw->...me_stripe(height,width,linewidth,\@@: linecolor,angle,\@@:gap,sh... l.248 gluedraw(sq) ; I use currently: ConTeXt ver: 2003.12.18 fmt: 2004.1.13 Could some metafun-literate try the code in both versions and see what happens? Thanks Willi --------------060601000802000709030508 Content-Type: text/plain; name="test.tex" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="test.tex" \setupoutput[pdftex] \setupcolors[state=start] \def\PICT{Test} \startMPenvironment \setupbodyfont[ss,8pt] \stopMPenvironment \setupMPvariables [\PICT] [linecolor=blue, gap=.2\bodyfontsize] \startuseMPgraphic{\PICT}{linecolor,gap} % the following definition is taken from mp-back.mp and adapted % in order to be able to fill a given path with a pattern def some_stripe (expr awidth , aheight , alinewidth , alinecolor , aangle , agap , ashape_path ) = stripe_gap := agap ; stripe_angle := aangle ; drawoptions (withpen pencircle scaled alinewidth withcolor alinecolor) ; path p ; p := ashape_path ; stripe_path_a () (draw) p ; enddef; def gluedraw(expr gluepath)= path shape_path; shape_path := gluepath; some_stripe (height, width, linewidth, \MPvar{linecolor}, angle, \MPvar{gap}, shape_path); enddef ; numeric u; u := 5mm; numeric width; width := 100u; numeric height; height := 50u; numeric angle; angle := 45 ; numeric linewidth; linewidth :=.5pt; path sq; sq = (0,0)--(10u,0)--(12u,5u)--(10u,10u)--(0,10u) --cycle ; fill sq withcolor \MPcolor{red} ; gluedraw(sq); \stopuseMPgraphic \starttext % \startMPpage % \includeMPgraphic{\PICT} % \stopMPpage \useMPgraphic{\PICT} \stoptext --------------060601000802000709030508--