ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: luigi scarso <luigi.scarso@gmail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: metapost question (bug?)
Date: Thu, 21 Jul 2011 16:53:13 +0200	[thread overview]
Message-ID: <CAG5iGsAA+xZzcpkP7Bvae_2e1++heo-P14xSQKzF0k+1Gwrt3A@mail.gmail.com> (raw)
In-Reply-To: <20110721143941.GC5493@iram-ha-003840.extra.cea.fr>

On Thu, Jul 21, 2011 at 4:39 PM, Alan Braslau <alan.braslau@cea.fr> 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 ;
>
>        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 ?

-- 
luigi
___________________________________________________________________________________
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
___________________________________________________________________________________

  reply	other threads:[~2011-07-21 14:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-21 14:39 Alan Braslau
2011-07-21 14:53 ` luigi scarso [this message]
2011-07-21 15:39   ` Peter Rolf
2011-07-21 21:21     ` Alan Braslau
2011-07-22  9:35       ` Peter Rolf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAG5iGsAA+xZzcpkP7Bvae_2e1++heo-P14xSQKzF0k+1Gwrt3A@mail.gmail.com \
    --to=luigi.scarso@gmail.com \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).