From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/89301 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: Re: overlay Date: Tue, 25 Nov 2014 06:40:07 +0100 Message-ID: <08544517-7C2E-4C4A-92C8-21270FF13F18@gmail.com> References: <24F8D443-4B30-4BC3-BDBF-D78E96A4BCC1@inradius.net> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Mac OS X Mail 8.1 \(1993\)) Content-Type: multipart/mixed; boundary="===============1128316931==" X-Trace: ger.gmane.org 1416894063 19140 80.91.229.3 (25 Nov 2014 05:41:03 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 25 Nov 2014 05:41:03 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Tue Nov 25 06:40:55 2014 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([5.39.185.229]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Xt8ru-000609-LC for gctc-ntg-context-518@m.gmane.org; Tue, 25 Nov 2014 06:40:54 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 7388E1021F for ; Tue, 25 Nov 2014 06:40:54 +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 pVXcQWEzg8Ky for ; Tue, 25 Nov 2014 06:40:53 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id 4C0AD10239 for ; Tue, 25 Nov 2014 06:40:24 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 55B85101EA for ; Tue, 25 Nov 2014 06:40:20 +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 kU1Jh3ezZIj9 for ; Tue, 25 Nov 2014 06:40:19 +0100 (CET) Original-Received: from filter4-ams.mf.surf.net (filter4-ams.mf.surf.net [192.87.102.72]) by balder.ntg.nl (Postfix) with ESMTP id 8C993101E8 for ; Tue, 25 Nov 2014 06:40:19 +0100 (CET) Original-Received: from mail-wi0-x234.google.com (mail-wi0-x234.google.com [IPv6:2a00:1450:400c:c05::234]) by filter4-ams.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id sAP5eAK0026240 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=NOT) for ; Tue, 25 Nov 2014 06:40:10 +0100 Original-Received: by mail-wi0-f180.google.com with SMTP id n3so188624wiv.13 for ; Mon, 24 Nov 2014 21:40:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:content-type:message-id:mime-version:subject:date:references :to:in-reply-to; bh=SaRajvfWBhThbcGza0/AmzUwznkEpX7tHSnjUvCRwzI=; b=K6FXPnWZyfS3m1gjdF0NSAI6dRHKRo0em5ZR5gUk17sYgP17OKj4+1W7fmXidin1QK Soi9BXL8qYuCkOur/XMdO4z9rHntDafHpiuO2V4/cQafhiTBqnFR9ij3xUSzKZEuorkF nFhjQbnvTt4K0oZK+Bd2BwaMI9RSDfEVKqlt2TAUwD37AW9JZubJwZ8hBtpiHnzz0W3f eokM+WOS+D+slyvTJBWtDH2BM9vf1iqgCH+2iNIeMiZ3MlI9r512BELoEY05CYrnUcJ/ O0cs9KS51NSrv5E8mmXIMIRwRBwyN4XIjicFLI9K3abf3BwZBzE7osI247S71AxLDLhK hzvQ== X-Received: by 10.180.95.37 with SMTP id dh5mr28121017wib.64.1416894010533; Mon, 24 Nov 2014 21:40:10 -0800 (PST) Original-Received: from katsuragi-3.localdomain (x2f365d3.dyn.telefonica.de. [2.243.101.211]) by mx.google.com with ESMTPSA id wz5sm307448wjc.29.2014.11.24.21.40.09 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 24 Nov 2014 21:40:09 -0800 (PST) In-Reply-To: <24F8D443-4B30-4BC3-BDBF-D78E96A4BCC1@inradius.net> X-Mailer: Apple Mail (2.1993) X-Bayes-Prob: 0.0001 (Score 0, tokens from: ntg-context@ntg.nl, base:default, @@RPTN) X-CanIt-Geo: ip=2a00:1450:400c:c05::234; country=IE X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 01NjFEaAb - 169b71cc7c56 - 20141125 (trained as not-spam) X-Scanned-By: CanIt (www . roaringpenguin . com) X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.16 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: "ntg-context" Xref: news.gmane.org gmane.comp.tex.context:89301 Archived-At: --===============1128316931== Content-Type: multipart/alternative; boundary="Apple-Mail=_B574DA2C-9086-47A7-8B7D-0BBADD26B34F" --Apple-Mail=_B574DA2C-9086-47A7-8B7D-0BBADD26B34F Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii > Am 22.11.2014 um 21:32 schrieb John Kitzmiller : >=20 > Given rectangles with text: >=20 > \starttext > Before:\\ > \startMPcode > draw unitsquare xscaled 2cm yscaled 1cm; =20 > \stopMPcode > \\ > After:\\ > \startMPcode > for i=3D0 upto 1: > draw unitsquare scaled 1cm xshifted i*cm; > endfor; > \stopMPcode > \stoptext >=20 > How can a line be drawn connecting the right edges of the rectangles? = I have played with: >=20 > \startuniqueMPgraphic{line} > path a; > a:=3D(0,0)--(0,3cm); > draw a withpen pencircle scaled 3pt withcolor green; > \stopuniqueMPgraphic >=20 > \defineoverlay[line][{\uniqueMPgraphic{line}}] >=20 > and using it in \framed, but placing the line correctly is elusive. Look at chapter 5 in the metafun manual. Wolfgang --Apple-Mail=_B574DA2C-9086-47A7-8B7D-0BBADD26B34F Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii
Am 22.11.2014 um 21:32 schrieb John Kitzmiller <kitz@inradius.net>:

Given = rectangles with text:

\starttext
Before:\\
\startMPcode
  = draw unitsquare xscaled 2cm yscaled 1cm;  
\stopMPcode
\\
After:\\
\startMPcode
  = for i=3D0 upto 1:
  =   draw unitsquare scaled 1cm xshifted i*cm;
  endfor;
\stopMPcode
\stoptext

How can a line be drawn = connecting the right edges of the rectangles? I have played = with:

\startuniqueMPgraphic{line}
  path = a;
 = a:=3D(0,0)--(0,3cm);
  draw a withpen pencircle scaled 3pt = withcolor green;
\stopuniqueMPgraphic

\defineoverlay[line][{\uniqueMPgraphic{line}}]

and using it in \framed, but placing the line correctly is = elusive.

Look at chapter 5 in the metafun = manual.

Wolfgang

= --Apple-Mail=_B574DA2C-9086-47A7-8B7D-0BBADD26B34F-- --===============1128316931== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cDovL3d3dy5udGcubmwvbWFpbG1hbi9s aXN0aW5mby9udGctY29udGV4dAp3ZWJwYWdlICA6IGh0dHA6Ly93d3cucHJhZ21hLWFkZS5ubCAv IGh0dHA6Ly90ZXguYWFuaGV0Lm5ldAphcmNoaXZlICA6IGh0dHA6Ly9mb3VuZHJ5LnN1cGVsZWMu ZnIvcHJvamVjdHMvY29udGV4dHJldi8Kd2lraSAgICAgOiBodHRwOi8vY29udGV4dGdhcmRlbi5u ZXQKX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX18= --===============1128316931==--