From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/70186 Path: news.gmane.org!not-for-mail From: Peter Rolf Newsgroups: gmane.comp.tex.context Subject: Re: metapost question (bug?) Date: Thu, 21 Jul 2011 17:39:48 +0200 Message-ID: <4E284844.6050709@gmx.net> References: <20110721143941.GC5493@iram-ha-003840.extra.cea.fr> 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 1311262816 27092 80.91.229.12 (21 Jul 2011 15:40:16 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 21 Jul 2011 15:40:16 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Thu Jul 21 17:40:11 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 1QjvMA-0006Ox-Qs for gctc-ntg-context-518@m.gmane.org; Thu, 21 Jul 2011 17:40:10 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 902AECAE58; Thu, 21 Jul 2011 17:40:09 +0200 (CEST) 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 T99Edq+CCYoD; Thu, 21 Jul 2011 17:40:05 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 14232CAE5D; Thu, 21 Jul 2011 17:40:05 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 09432CAE5D for ; Thu, 21 Jul 2011 17:40:04 +0200 (CEST) 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 3-I4S5iTo-tM for ; Thu, 21 Jul 2011 17:39:53 +0200 (CEST) Original-Received: from filter4-til.mf.surf.net (filter4-til.mf.surf.net [194.171.167.220]) by balder.ntg.nl (Postfix) with ESMTP id 4EF04CAE58 for ; Thu, 21 Jul 2011 17:39:53 +0200 (CEST) Original-Received: from mailout-de.gmx.net (mailout-de.gmx.net [213.165.64.22]) by filter4-til.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with SMTP id p6LFdqk7005420 for ; Thu, 21 Jul 2011 17:39:52 +0200 Original-Received: (qmail invoked by alias); 21 Jul 2011 15:39:52 -0000 Original-Received: from ip-178-200-248-30.unitymediagroup.de (EHLO [192.168.178.3]) [178.200.248.30] by mail.gmx.net (mp034) with SMTP; 21 Jul 2011 17:39:52 +0200 X-Authenticated: #24293357 X-Provags-ID: V01U2FsdGVkX1+8tc1NxyK8yYl45IQb2ayowZ4greKS/cs0twWYbG vkDf21oj4RzsAX User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:5.0) Gecko/20110624 Thunderbird/5.0 In-Reply-To: X-Enigmail-Version: 1.2 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: 05FaDDQ5W - 747ff71d930f - 20110721 X-Scanned-By: CanIt (www . roaringpenguin . com) on 194.171.167.220 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:70186 Am 21.07.2011 16:53, schrieb luigi scarso: > On Thu, Jul 21, 2011 at 4:39 PM, Alan Braslau wrote: >> Hello, >> >> I have a question for metapost specialists: >> >> I am looking for some sort of effect, built upon a zig-zag line. >> The first graphic in the minimal example below is as I would expect. >> The second graphic seems to be drawn without the point at (0,0). >> (Ignore the asymmetry at the end of the path in the 2nd, this >> is to be expected in this minimal example.) >> >> Is the result correct or is this a bug? >> >> Alan >> >> >> >> \starttext >> >> \startTEXpage >> \startMPcode >> u := 1mm ; >> >> path p[] ; >> p0 := ((0,0)--(1,0)) rotated 45 scaled 20u ; >> pickup pensquare scaled 10u rotated 45 ; >> draw p0 withcolor blue ; >> pickup pensquare yscaled 2u xscaled 5u rotated 45 ; >> draw p0 withcolor yellow ; >> pickup pencircle scaled .1u ; >> draw p0 ; >> \stopMPcode >> \stopTEXpage >> >> \startTEXpage >> \startMPcode >> p1 := ((0,0)--(sqrt(2),0)) rotated -30 scaled 20u >> shifted point infinity of p0 ; >> p2 := p0--p1 ; >> use p2 := p0 & p1; the reason for the 'unexpected' output is, that point 1 and 2 of the path p2 are equal. keep in mind that drawing with an asymmetrical pen has its own (complex) rules. >> pickup pensquare scaled 10u rotated 45 ; >> draw p2 withcolor blue ; >> pickup pensquare yscaled 2u xscaled 5u rotated 45 ; >> draw p2 withcolor yellow ; >> pickup pencircle scaled .1u ; >> draw p2 ; >> \stopMPcode >> \stopTEXpage >> >> \stoptext > You are shifting by a certain amount : what is the net effect of > shifted point infinity of p0 ? > afaik simply the last point of p0. ___________________________________________________________________________________ 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 ___________________________________________________________________________________